[Bug 20444] New: Remove C4::Members::Attributes::GetAttributes
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Bug ID: 20444 Summary: Remove C4::Members::Attributes::GetAttributes Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Architecture, internals, and plumbing Assignee: koha-bugs@lists.koha-community.org Reporter: josef.moravec@gmail.com QA Contact: testopia@bugs.koha-community.org It is not used in the code. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Josef Moravec <josef.moravec@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |20443 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20443 [Bug 20443] Move C4::Members::Attributes to Koha namespace -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Josef Moravec <josef.moravec@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Assignee|koha-bugs@lists.koha-commun |josef.moravec@gmail.com |ity.org | --- Comment #1 from Josef Moravec <josef.moravec@gmail.com> --- (In reply to Josef Moravec from comment #0)
It is not used in the code.
Actually it is used on letter.pl -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Josef Moravec <josef.moravec@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 --- Comment #2 from Josef Moravec <josef.moravec@gmail.com> --- Created attachment 73083 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=73083&action=edit Bug 20444: Use Koha::Patron::Attribute::Types object for getting patron attributes in letter.pl Test plan: 0) Apply the patch 1) Do not have any patron attribute types defined 2) Go to Tools -> Notices and slips 3) Edit any slip/letter which uses table borrower 4) Confirm the editing works, and the slip/letter itself works 5) Add some patron attributes types and define them a value for any patron 6) Go to Tools -> Notices and slips and edit any slip/letter which uses table borrower 7) Confirm, the attributes are listed in available fields 8) Confirm the slip/letter is working when you add a attribute to it -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 --- Comment #3 from Josef Moravec <josef.moravec@gmail.com> --- Created attachment 73084 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=73084&action=edit Bug 20444: Update test 0) Apply this patch 1) prove t/db_dependent/Members/Attributes.t should return green -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 --- Comment #4 from Josef Moravec <josef.moravec@gmail.com> --- Created attachment 73085 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=73085&action=edit Bug 20444: Remove sub GetAttributes 0) Apply this patch 1) git grep GetAttributes should return no occurencies -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 --- Comment #5 from M. Tompsett <mtompset@hotmail.com> --- Comment on attachment 73083 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=73083 Bug 20444: Use Koha::Patron::Attribute::Types object for getting patron attributes in letter.pl Review of attachment 73083: --> (https://bugs.koha-community.org/bugzilla3/page.cgi?id=splinter.html&bug=20444&attachment=73083) ----------------------------------------------------------------- ::: tools/letter.pl @@ +463,4 @@
} } if ($table eq 'borrowers') { + my $attribute_types = Koha::Patron::Attribute::Types->search;
This let's you loop like an array, but it isn't ordered by code as far as I can tell. Feel free to correct me. Does this need to be code equivalent? Or just similar functionally? @@ -462,4 @@
} } if ($table eq 'borrowers') { - if ( my $attributes = C4::Members::Attributes::GetAttributes() ) {
This is a sorted array of codes... -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Josef Moravec <josef.moravec@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on|20443 | Blocks| |20443 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20443 [Bug 20443] Move C4::Members::Attributes to Koha namespace -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Josef Moravec <josef.moravec@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #73083|0 |1 is obsolete| | Attachment #73084|0 |1 is obsolete| | Attachment #73085|0 |1 is obsolete| | --- Comment #6 from Josef Moravec <josef.moravec@gmail.com> --- Created attachment 74788 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74788&action=edit Bug 20444: Use Koha::Patron::Attribute::Types object for getting patron attributes in letter.pl Test plan: 0) Apply the patch 1) Do not have any patron attribute types defined 2) Go to Tools -> Notices and slips 3) Edit any slip/letter which uses table borrower 4) Confirm the editing works, and the slip/letter itself works 5) Add some patron attributes types and define them a value for any patron 6) Go to Tools -> Notices and slips and edit any slip/letter which uses table borrower 7) Confirm, the attributes are listed in available fields 8) Confirm the slip/letter is working when you add a attribute to it -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 --- Comment #7 from Josef Moravec <josef.moravec@gmail.com> --- Created attachment 74789 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74789&action=edit Bug 20444: Update test 0) Apply this patch 1) prove t/db_dependent/Members/Attributes.t should return green -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 --- Comment #8 from Josef Moravec <josef.moravec@gmail.com> --- Created attachment 74790 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74790&action=edit Bug 20444: Remove sub GetAttributes 0) Apply this patch 1) git grep GetAttributes should return no occurencies -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 --- Comment #9 from Josef Moravec <josef.moravec@gmail.com> --- (In reply to M. Tompsett from comment #5)
Comment on attachment 73083 [details] [review] Bug 20444: Use Koha::Patron::Attribute::Types object for getting patron attributes in letter.pl
Review of attachment 73083 [details] [review]: -----------------------------------------------------------------
::: tools/letter.pl @@ +463,4 @@
} } if ($table eq 'borrowers') { + my $attribute_types = Koha::Patron::Attribute::Types->search;
This let's you loop like an array, but it isn't ordered by code as far as I can tell. Feel free to correct me. Does this need to be code equivalent? Or just similar functionally?
@@ -462,4 @@
} } if ($table eq 'borrowers') { - if ( my $attributes = C4::Members::Attributes::GetAttributes() ) {
This is a sorted array of codes...
Fixed for preserving functionality -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Séverine Queune <severine.queune@bulac.fr> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Séverine Queune <severine.queune@bulac.fr> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #74788|0 |1 is obsolete| | --- Comment #10 from Séverine Queune <severine.queune@bulac.fr> --- Created attachment 74793 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74793&action=edit Bug 20444: Use Koha::Patron::Attribute::Types object for getting patron attributes in letter.pl Test plan: 0) Apply the patch 1) Do not have any patron attribute types defined 2) Go to Tools -> Notices and slips 3) Edit any slip/letter which uses table borrower 4) Confirm the editing works, and the slip/letter itself works 5) Add some patron attributes types and define them a value for any patron 6) Go to Tools -> Notices and slips and edit any slip/letter which uses table borrower 7) Confirm, the attributes are listed in available fields 8) Confirm the slip/letter is working when you add a attribute to it Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Séverine Queune <severine.queune@bulac.fr> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #74789|0 |1 is obsolete| | --- Comment #11 from Séverine Queune <severine.queune@bulac.fr> --- Created attachment 74794 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74794&action=edit Bug 20444: Update test 0) Apply this patch 1) prove t/db_dependent/Members/Attributes.t should return green Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Séverine Queune <severine.queune@bulac.fr> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #74790|0 |1 is obsolete| | --- Comment #12 from Séverine Queune <severine.queune@bulac.fr> --- Created attachment 74795 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74795&action=edit Bug 20444: Remove sub GetAttributes 0) Apply this patch 1) git grep GetAttributes should return no occurencies Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Séverine Queune <severine.queune@bulac.fr> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |severine.queune@bulac.fr --- Comment #13 from Séverine Queune <severine.queune@bulac.fr> --- I tried with several notices (predue, suggestion accepted, article request completed) and it always worked. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #74793|0 |1 is obsolete| | --- Comment #14 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 74906 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74906&action=edit Bug 20444: Use Koha::Patron::Attribute::Types object for getting patron attributes in letter.pl Test plan: 0) Apply the patch 1) Do not have any patron attribute types defined 2) Go to Tools -> Notices and slips 3) Edit any slip/letter which uses table borrower 4) Confirm the editing works, and the slip/letter itself works 5) Add some patron attributes types and define them a value for any patron 6) Go to Tools -> Notices and slips and edit any slip/letter which uses table borrower 7) Confirm, the attributes are listed in available fields 8) Confirm the slip/letter is working when you add a attribute to it Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #74794|0 |1 is obsolete| | --- Comment #15 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 74907 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74907&action=edit Bug 20444: Update test 0) Apply this patch 1) prove t/db_dependent/Members/Attributes.t should return green Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #74795|0 |1 is obsolete| | --- Comment #16 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 74908 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=74908&action=edit Bug 20444: Remove sub GetAttributes 0) Apply this patch 1) git grep GetAttributes should return no occurencies Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |m.de.rooy@rijksmuseum.nl QA Contact|testopia@bugs.koha-communit |m.de.rooy@rijksmuseum.nl |y.org | Patch complexity|--- |Small patch -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to Master --- Comment #17 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Pushed to master for 18.05, thanks to everybody involved! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20444 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |martin.renvoize@ptfs-europe | |.com Resolution|--- |FIXED Status|Pushed to Master |RESOLVED -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org