[Bug 26597] New: Transfer informations from guarantor when adding a guarantor to an existing patron
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Bug ID: 26597 Summary: Transfer informations from guarantor when adding a guarantor to an existing patron Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Patrons Assignee: koha-bugs@lists.koha-community.org Reporter: maryse.simard@inlibro.com QA Contact: testopia@bugs.koha-community.org CC: gmcharlt@gmail.com, kyle.m.hall@gmail.com When creating a new guarantee from the guarantor, the preference PrefillGuaranteeField dictates some fields to be transfered from guarantor to guarantee. We want to transfer those informations also when adding a new guarantor relationship to an existing patron. Note: This was first introduced as part of Bug 12446, but ultimately was split into it's own bug. -- 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=26597 Maryse Simard <maryse.simard@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- 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=26597 --- Comment #1 from Maryse Simard <maryse.simard@inlibro.com> --- Created attachment 111054 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=111054&action=edit Bug 26597: Transfer informations from guarantor when adding a guarantor to an existing patron When creating a new guarantee from the guarantor, the preference PrefillGuaranteeField dictates some fields to be transfered from guarantor to guarantee. This patch makes it so those informations are also transfered when adding a new guarantor relationship to an existing patron. To test: 1) Apply patch 2) Search PrefillGuaranteeField preference and make sure some fields are selected 3) Select a user that can have a guarantor 4) In the edit form, click on "Search to add" in "Patron guarantor" fieldset 5) Choose a patron who has at least one of the fields in 1) set 6) Click "Select" 7) Confirm guarantee's information is filled from the guarantor's record 8) Check that any preexisting information is not overwritten -- 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=26597 Maryse Simard <maryse.simard@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |caroline.cyr-la-rose@inlibr | |o.com, | |philippe.blouin@inlibro.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |maryse.simard@inlibro.com |ity.org | -- 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=26597 David Nind <david@davidnind.com> 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=26597 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #111054|0 |1 is obsolete| | --- Comment #2 from David Nind <david@davidnind.com> --- Created attachment 111319 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=111319&action=edit Bug 26597: Transfer informations from guarantor when adding a guarantor to an existing patron When creating a new guarantee from the guarantor, the preference PrefillGuaranteeField dictates some fields to be transfered from guarantor to guarantee. This patch makes it so those informations are also transfered when adding a new guarantor relationship to an existing patron. To test: 1) Apply patch 2) Search PrefillGuaranteeField preference and make sure some fields are selected 3) Select a user that can have a guarantor 4) In the edit form, click on "Search to add" in "Patron guarantor" fieldset 5) Choose a patron who has at least one of the fields in 1) set 6) Click "Select" 7) Confirm guarantee's information is filled from the guarantor's record 8) Check that any preexisting information is not overwritten Signed-off-by: David Nind <david@davidnind.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Transfer informations from |Transfer information from |guarantor when adding a |guarantor when adding a |guarantor to an existing |guarantor to an existing |patron |patron -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Kyle M Hall <kyle@bywatersolutions.com> 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=26597 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #111319|0 |1 is obsolete| | --- Comment #3 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 112196 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=112196&action=edit Bug 26597: Transfer informations from guarantor when adding a guarantor to an existing patron When creating a new guarantee from the guarantor, the preference PrefillGuaranteeField dictates some fields to be transfered from guarantor to guarantee. This patch makes it so those informations are also transfered when adding a new guarantor relationship to an existing patron. To test: 1) Apply patch 2) Search PrefillGuaranteeField preference and make sure some fields are selected 3) Select a user that can have a guarantor 4) In the edit form, click on "Search to add" in "Patron guarantor" fieldset 5) Choose a patron who has at least one of the fields in 1) set 6) Click "Select" 7) Confirm guarantee's information is filled from the guarantor's record 8) Check that any preexisting information is not overwritten Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kyle@bywatersolutions.com --- Comment #4 from Kyle M Hall <kyle@bywatersolutions.com> --- RM Note: We might possibly want a way to *not* transfer info to existing patrons when guaranteeing them ( possibly another syspref, or a checkbox when adding a guarantor ). The feature does leave existing fields untouched. I will leave that decision to the RM. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jonathan.druart@bugs.koha-c | |ommunity.org Status|Passed QA |In Discussion --- Comment #5 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- I have the feeling that the path you chose is way too complicated for what you tried to implement. The "PrefillGuaranteeField" notion should not appear in the DT patron search module (C4:Utils::DataTables::Members). A more elegant implementation would be to retrieve the patron's data using the REST API route and keep the logic of "prefilling" JS-side. What do you think? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #6 from Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> --- What can we do to take this out of the "In Discussion" limbo? It was already signed off twice. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #7 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to Caroline Cyr La Rose from comment #6)
What can we do to take this out of the "In Discussion" limbo? It was already signed off twice.
An answer to my comment? :) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #8 from Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> --- Your comment is to redo the patch completely. I was asking because it was already signed off and PQA as it is. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #9 from Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> --- Sorry, not PQA, I was mistaking it for another one -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 geraud.frappier@inlibro.com changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #112196|0 |1 is obsolete| | --- Comment #10 from geraud.frappier@inlibro.com --- Created attachment 142443 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=142443&action=edit Bug 26597: Transfer informations from guarantor when adding a guarantor to an existing patron When creating a new guarantee from the guarantor, the preference PrefillGuaranteeField dictates some fields to be transfered from guarantor to guarantee. This patch makes it so those informations are also transfered when adding a new guarantor relationship to an existing patron. To test: 1) Apply patch 2) Search PrefillGuaranteeField preference and make sure some fields are selected 3) Select a user that can have a guarantor 4) In the edit form, click on "Search to add" in "Patron guarantor" fieldset 5) Choose a patron who has at least one of the fields in 1) set 6) Click "Select" 7) Confirm guarantee's information is filled from the guarantor's record 8) Check that any preexisting information is not overwritten Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Emmi Takkinen <emmi.takkinen@koha-suomi.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |emmi.takkinen@koha-suomi.fi -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Hammat wele <hammat.wele@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|maryse.simard@inlibro.com |hammat.wele@inlibro.com CC| |hammat.wele@inlibro.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Hammat wele <hammat.wele@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #142443|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #11 from Hammat wele <hammat.wele@inlibro.com> --- Created attachment 144475 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=144475&action=edit Bug 26597: Transfer informations from guarantor when adding a guarantor to an existing patron When creating a new guarantee from the guarantor, the preference PrefillGuaranteeField dictates some fields to be transfered from guarantor to guarantee. This patch makes it so those informations are also transfered when adding a new guarantor relationship to an existing patron. To test: 1) Apply patch 2) Search PrefillGuaranteeField preference and make sure some fields are selected 3) Select a user that can have a guarantor 4) In the edit form, click on 'Search to add' in 'Patron guarantor' fieldset 5) Choose a patron who has at least one of the fields in 1) set 6) Click 'Select' 7) Confirm guarantee's information is filled from the guarantor's record 8) Check that any preexisting information is not overwritten -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Hammat wele <hammat.wele@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|In Discussion |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |lucas@bywatersolutions.com --- Comment #12 from Lucas Gass <lucas@bywatersolutions.com> --- For me this is not working. In PrefillGuaranteeField I am adding every Alternate address field. Then I make sure my gaurantor has each of those fields filled out. If I then "Add gaurantee" the normal way it works. But when I go into the Guarantee record, search for a gaurantor , and add them. None of the fields are populated. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #13 from Hammat wele <hammat.wele@inlibro.com> --- Created attachment 144560 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=144560&action=edit Bug 26597: Fixing the populate of fields when using the REST API route This attachment correct the populate of fields by using the api mapping. Now All fields are populated following the selected PrefillGuaranteeField options -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Laura Escamilla <Laura.escamilla@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |Laura.escamilla@bywatersolu | |tions.com --- Comment #14 from Laura Escamilla <Laura.escamilla@bywatersolutions.com> --- For me this is not working either. In PrefillGuaranteeField I am adding every Alternate address field. When I search for a guarantor, and then add them to the guarantee, the fields do not populate. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #15 from Hammat wele <hammat.wele@inlibro.com> --- Created attachment 148564 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=148564&action=edit Bug 26597: (follow-up) Add disabling / enabled the save button while waiting from api to respond I've updated the test plan since the REST API route takes a little time to respond To test: 1) Apply patch 2) Search PrefillGuaranteeField preference and make sure some fields are selected 3) Select a user that can have a guarantor 4) In the edit form, click on "Search to add" in "Patron guarantor" fieldset 5) Choose a patron who has at least one of the fields in 1) set 6) Click Select 7) Wait until save button is enabled 8) Confirm guarantee's information is filled from the guarantor's record 9) Check that any preexisting information is not overwritten -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #16 from Hammat wele <hammat.wele@inlibro.com> --- (In reply to Laura Escamilla from comment #14)
For me this is not working either. In PrefillGuaranteeField I am adding every Alternate address field. When I search for a guarantor, and then add them to the guarantee, the fields do not populate.
Hi Laura, thank you for testing. I've updated the test plan since the guarantee's information take a little time to be filled -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 PTFS Europe Sandboxes <sandboxes@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #144475|0 |1 is obsolete| | --- Comment #17 from PTFS Europe Sandboxes <sandboxes@ptfs-europe.com> --- Created attachment 148597 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=148597&action=edit Bug 26597: Transfer informations from guarantor when adding a guarantor to an existing patron When creating a new guarantee from the guarantor, the preference PrefillGuaranteeField dictates some fields to be transfered from guarantor to guarantee. This patch makes it so those informations are also transfered when adding a new guarantor relationship to an existing patron. To test: 1) Apply patch 2) Search PrefillGuaranteeField preference and make sure some fields are selected 3) Select a user that can have a guarantor 4) In the edit form, click on 'Search to add' in 'Patron guarantor' fieldset 5) Choose a patron who has at least one of the fields in 1) set 6) Click 'Select' 7) Confirm guarantee's information is filled from the guarantor's record 8) Check that any preexisting information is not overwritten Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 PTFS Europe Sandboxes <sandboxes@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #144560|0 |1 is obsolete| | --- Comment #18 from PTFS Europe Sandboxes <sandboxes@ptfs-europe.com> --- Created attachment 148598 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=148598&action=edit Bug 26597: Fixing the populate of fields when using the REST API route This attachment correct the populate of fields by using the api mapping. Now All fields are populated following the selected PrefillGuaranteeField options Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 PTFS Europe Sandboxes <sandboxes@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #148564|0 |1 is obsolete| | --- Comment #19 from PTFS Europe Sandboxes <sandboxes@ptfs-europe.com> --- Created attachment 148599 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=148599&action=edit Bug 26597: (follow-up) Add disabling / enabled the save button while waiting from api to respond I've updated the test plan since the REST API route takes a little time to respond To test: 1) Apply patch 2) Search PrefillGuaranteeField preference and make sure some fields are selected 3) Select a user that can have a guarantor 4) In the edit form, click on "Search to add" in "Patron guarantor" fieldset 5) Choose a patron who has at least one of the fields in 1) set 6) Click Select 7) Wait until save button is enabled 8) Confirm guarantee's information is filled from the guarantor's record 9) Check that any preexisting information is not overwritten Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Sally <sally.healey@cheshiresharedservices.gov.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off CC| |sally.healey@cheshireshared | |services.gov.uk --- Comment #20 from Sally <sally.healey@cheshiresharedservices.gov.uk> --- Works as described, thanks for the patch. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact|testopia@bugs.koha-communit |m.de.rooy@rijksmuseum.nl |y.org | Status|Signed Off |BLOCKED CC| |m.de.rooy@rijksmuseum.nl --- Comment #21 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Looking here -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|BLOCKED |Failed QA --- Comment #22 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- FAIL koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt FAIL filters missing_filter at line 1921 ( guarantor_attributes = [% To.json(guarantor_attributes) %];) missing_filter at line 1924 ( to_api_mapping = [% To.json(to_api_mapping) %];) Please fix. + error:function(){ + $('#saverecord').prop('disabled', false); Shouldnt we do more than that ? koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc: select_user( borrowernumber, JSON.parse(borrower_data) ); koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc: function select_user(borrowernumber, data) { koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc: p.select_user(borrowernumber, data); koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqbudgets.tt: function select_user(borrowernumber, borrower) { It seems that we are overloading this function name already. So no blocker for this report. Just noting. But might be a chance to rename in members.js? The name is quite obscure for copying guarantor information. koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt: select_user( '[% g.patron.borrowernumber | html %]', [% To.json( g.patron.unblessed ) | $raw %], '[% g.relationship | html %]' ); koha-tmpl/intranet-tmpl/prog/js/members.js:function select_user(borrowernumber, borrower, relationship) { [% IF new_guarantors %] [% FOREACH g IN new_guarantors %] select_user( '[% g.patron.borrowernumber | html %]', [% To.json( g.patron.unblessed ) | $raw %], '[% g.relationship | html %]' ); [% END %] [% END %] Please explain why whe should do an ajax GET in select_user when we pass the borrower unblessed hash to this function? This does not look good. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #23 from Hammat wele <hammat.wele@inlibro.com> --- Created attachment 151850 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=151850&action=edit Bug 26597: (Fix) remove REST API call and retrieve the patron's data from borrower_data input This patch remove the REST API call in select_user function and retrieve the patron's data from borrower_data To test: 1) Apply patch 2) Search PrefillGuaranteeField preference and make sure some fields are selected 3) Select a user that can have a guarantor 4) In the edit form, click on "Search to add" in "Patron guarantor" fieldset 5) Choose a patron who has at least one of the fields in 1) set 6) Click Select 7) Confirm guarantee's information is filled from the guarantor's record 8) Check that any preexisting information is not overwritten -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #24 from Hammat wele <hammat.wele@inlibro.com> --- Created attachment 151851 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=151851&action=edit Bug 26597: (QA follow-up) Remane select_user and add missing filters -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Hammat wele <hammat.wele@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Needs Signoff --- Comment #25 from Hammat wele <hammat.wele@inlibro.com> --- (In reply to Marcel de Rooy from comment #22)
FAIL koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt FAIL filters missing_filter at line 1921 ( guarantor_attributes = [% To.json(guarantor_attributes) %];) missing_filter at line 1924 ( to_api_mapping = [% To.json(to_api_mapping) %];) Please fix. Missing_filters added
for this report. Just noting. But might be a chance to rename in members.js? The name is quite obscure for copying guarantor information.
I've rename the function to add_guarantor
Please explain why whe should do an ajax GET in select_user when we pass the borrower unblessed hash to this function? This does not look good.
It was a suggestion in the comment 5 but you are right, there is no need to use the REST API to retrieve data from the guarantor since we can get it from the borrower hidden input, it is fixed in this patch. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #26 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- (In reply to Hammat wele from comment #24)
Created attachment 151851 [details] [review] Bug 26597: (QA follow-up) Remane select_user and add missing filters
This is wrong. You are mixing different things. select_user in patron-search.inc cannot be renamed, it's a generic function that is used in other places. If you rename it you are going to break other patron searches. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #27 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- If you are removing the REST API fetch I don't see why you are still passing and using to_api_mapping. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #28 from Hammat wele <hammat.wele@inlibro.com> --- (In reply to Jonathan Druart from comment #27)
If you are removing the REST API fetch I don't see why you are still passing and using to_api_mapping.
With borrower, I get all the guarantor's data i need but it is not associated with the name of the fields of the form. the to_api_mapping allows me to retrieve the name of the fields to be filled. the data received from borrower is like { ... "altaddress_address": "addressvalue", "altaddress_address2": "address2value", "altaddress_city": "addressCityvalue", "altaddress_country": "addresscontryvalue", "altaddress_email": "email@example.com", ... } to be able to fill the form with these data i need to get the name of the fields to be filled in and the to_api_mapping help me to get it { B_address => 'altaddress_address', } -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Hammat wele <hammat.wele@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #151851|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #29 from Hammat wele <hammat.wele@inlibro.com> --- Created attachment 151878 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=151878&action=edit Bug 26597: (QA follow-up) Add missing filters -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Emmi Takkinen <emmi.takkinen@koha-suomi.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #148597|0 |1 is obsolete| | --- Comment #30 from Emmi Takkinen <emmi.takkinen@koha-suomi.fi> --- Created attachment 154501 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=154501&action=edit Bug 26597: Transfer informations from guarantor when adding a guarantor to an existing patron When creating a new guarantee from the guarantor, the preference PrefillGuaranteeField dictates some fields to be transfered from guarantor to guarantee. This patch makes it so those informations are also transfered when adding a new guarantor relationship to an existing patron. To test: 1) Apply patch 2) Search PrefillGuaranteeField preference and make sure some fields are selected 3) Select a user that can have a guarantor 4) In the edit form, click on 'Search to add' in 'Patron guarantor' fieldset 5) Choose a patron who has at least one of the fields in 1) set 6) Click 'Select' 7) Confirm guarantee's information is filled from the guarantor's record 8) Check that any preexisting information is not overwritten Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk> Signed-off-by: Emmi Takkinen <emmi.takkinen@koha-suomi.fi> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Emmi Takkinen <emmi.takkinen@koha-suomi.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #148598|0 |1 is obsolete| | --- Comment #31 from Emmi Takkinen <emmi.takkinen@koha-suomi.fi> --- Created attachment 154503 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=154503&action=edit Bug 26597: Fixing the populate of fields when using the REST API route This attachment correct the populate of fields by using the api mapping. Now All fields are populated following the selected PrefillGuaranteeField options Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk> Signed-off-by: Emmi Takkinen <emmi.takkinen@koha-suomi.fi> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Emmi Takkinen <emmi.takkinen@koha-suomi.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #148599|0 |1 is obsolete| | --- Comment #32 from Emmi Takkinen <emmi.takkinen@koha-suomi.fi> --- Created attachment 154504 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=154504&action=edit Bug 26597: (follow-up) Add disabling / enabled the save button while waiting from api to respond I've updated the test plan since the REST API route takes a little time to respond To test: 1) Apply patch 2) Search PrefillGuaranteeField preference and make sure some fields are selected 3) Select a user that can have a guarantor 4) In the edit form, click on "Search to add" in "Patron guarantor" fieldset 5) Choose a patron who has at least one of the fields in 1) set 6) Click Select 7) Wait until save button is enabled 8) Confirm guarantee's information is filled from the guarantor's record 9) Check that any preexisting information is not overwritten Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk> Signed-off-by: Emmi Takkinen <emmi.takkinen@koha-suomi.fi> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Emmi Takkinen <emmi.takkinen@koha-suomi.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #151850|0 |1 is obsolete| | --- Comment #33 from Emmi Takkinen <emmi.takkinen@koha-suomi.fi> --- Created attachment 154505 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=154505&action=edit Bug 26597: (Fix) remove REST API call and retrieve the patron's data from borrower_data input This patch remove the REST API call in select_user function and retrieve the patron's data from borrower_data To test: 1) Apply patch 2) Search PrefillGuaranteeField preference and make sure some fields are selected 3) Select a user that can have a guarantor 4) In the edit form, click on "Search to add" in "Patron guarantor" fieldset 5) Choose a patron who has at least one of the fields in 1) set 6) Click Select 7) Confirm guarantee's information is filled from the guarantor's record 8) Check that any preexisting information is not overwritten Signed-off-by: Emmi Takkinen <emmi.takkinen@koha-suomi.fi> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Emmi Takkinen <emmi.takkinen@koha-suomi.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #151878|0 |1 is obsolete| | --- Comment #34 from Emmi Takkinen <emmi.takkinen@koha-suomi.fi> --- Created attachment 154506 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=154506&action=edit Bug 26597: (QA follow-up) Add missing filters Signed-off-by: Emmi Takkinen <emmi.takkinen@koha-suomi.fi> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Emmi Takkinen <emmi.takkinen@koha-suomi.fi> 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=26597 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA --- Comment #35 from Kyle M Hall <kyle@bywatersolutions.com> --- This looks good but the system preference description ( and possibly the name ) needs to be updated to reflect that the information copying will now work in both directions. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Émily-Rose Francoeur <emily-rose.francoeur@inLibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |emily-rose.francoeur@inLibr | |o.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #36 from Émily-Rose Francoeur <emily-rose.francoeur@inLibro.com> --- Created attachment 158119 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=158119&action=edit Bug 26597: Update the description of the PrefillGuaranteeField system preference I updated the system preference description so that we now know this option is working from both the guarantee and guarantor forms. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Émily-Rose Francoeur <emily-rose.francoeur@inLibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Emmi Takkinen <emmi.takkinen@koha-suomi.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #158119|0 |1 is obsolete| | --- Comment #37 from Emmi Takkinen <emmi.takkinen@koha-suomi.fi> --- Created attachment 158300 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=158300&action=edit Bug 26597: Update the description of the PrefillGuaranteeField system preference I updated the system preference description so that we now know this option is working from both the guarantee and guarantor forms. Signed-off-by: Emmi Takkinen <emmi.takkinen@koha-suomi.fi> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Emmi Takkinen <emmi.takkinen@koha-suomi.fi> 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=26597 Kyle M Hall <kyle@bywatersolutions.com> 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=26597 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #154501|0 |1 is obsolete| | Attachment #154503|0 |1 is obsolete| | Attachment #154504|0 |1 is obsolete| | Attachment #154505|0 |1 is obsolete| | Attachment #154506|0 |1 is obsolete| | Attachment #158300|0 |1 is obsolete| | --- Comment #38 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 161510 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=161510&action=edit Bug 26597: Transfer informations from guarantor when adding a guarantor to an existing patron When creating a new guarantee from the guarantor, the preference PrefillGuaranteeField dictates some fields to be transfered from guarantor to guarantee. This patch makes it so those informations are also transfered when adding a new guarantor relationship to an existing patron. To test: 1) Apply patch 2) Search PrefillGuaranteeField preference and make sure some fields are selected 3) Select a user that can have a guarantor 4) In the edit form, click on 'Search to add' in 'Patron guarantor' fieldset 5) Choose a patron who has at least one of the fields in 1) set 6) Click 'Select' 7) Confirm guarantee's information is filled from the guarantor's record 8) Check that any preexisting information is not overwritten Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk> Signed-off-by: Emmi Takkinen <emmi.takkinen@koha-suomi.fi> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #39 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 161511 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=161511&action=edit Bug 26597: Fixing the populate of fields when using the REST API route This attachment correct the populate of fields by using the api mapping. Now All fields are populated following the selected PrefillGuaranteeField options Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk> Signed-off-by: Emmi Takkinen <emmi.takkinen@koha-suomi.fi> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #40 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 161512 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=161512&action=edit Bug 26597: (follow-up) Add disabling / enabled the save button while waiting from api to respond I've updated the test plan since the REST API route takes a little time to respond To test: 1) Apply patch 2) Search PrefillGuaranteeField preference and make sure some fields are selected 3) Select a user that can have a guarantor 4) In the edit form, click on "Search to add" in "Patron guarantor" fieldset 5) Choose a patron who has at least one of the fields in 1) set 6) Click Select 7) Wait until save button is enabled 8) Confirm guarantee's information is filled from the guarantor's record 9) Check that any preexisting information is not overwritten Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk> Signed-off-by: Emmi Takkinen <emmi.takkinen@koha-suomi.fi> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #41 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 161513 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=161513&action=edit Bug 26597: (Fix) remove REST API call and retrieve the patron's data from borrower_data input This patch remove the REST API call in select_user function and retrieve the patron's data from borrower_data To test: 1) Apply patch 2) Search PrefillGuaranteeField preference and make sure some fields are selected 3) Select a user that can have a guarantor 4) In the edit form, click on "Search to add" in "Patron guarantor" fieldset 5) Choose a patron who has at least one of the fields in 1) set 6) Click Select 7) Confirm guarantee's information is filled from the guarantor's record 8) Check that any preexisting information is not overwritten Signed-off-by: Emmi Takkinen <emmi.takkinen@koha-suomi.fi> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #42 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 161514 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=161514&action=edit Bug 26597: (QA follow-up) Add missing filters Signed-off-by: Emmi Takkinen <emmi.takkinen@koha-suomi.fi> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #43 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 161515 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=161515&action=edit Bug 26597: Update the description of the PrefillGuaranteeField system preference I updated the system preference description so that we now know this option is working from both the guarantee and guarantor forms. Signed-off-by: Emmi Takkinen <emmi.takkinen@koha-suomi.fi> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #44 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 161516 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=161516&action=edit Bug 26597: (QA follow-up) Tidy code Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #45 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- I am not sure why, but I am seeing sha1 errors much more often recently. If someone has an idea how to help avoid them, I am all ears. Right now it's only the last patch here that has the issue: Patch failed at 0001 Bug 26597: (QA follow-up) Tidy code hint: Use 'git am --show-current-patch=diff' to see the failed patch When you have resolved this problem run "git bz apply --continue". If you would prefer to skip this patch, instead run "git bz apply --skip". To restore the original branch and stop patching run "git bz apply --abort". Patch left in /tmp/Bug-26597-QA-follow-up-Tidy-code-ol81ve_8.patch I tidied the patch inline. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to master Version(s)| |24.05.00 released in| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 --- Comment #46 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Pushed for 24.05! Well done everyone, thank you! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to master |Needs documenting CC| |fridolin.somers@biblibre.co | |m --- Comment #47 from Fridolin Somers <fridolin.somers@biblibre.com> --- Enhancement not pushed to 23.11.x -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26597 Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Documentation| |Caroline Cyr La Rose contact| | Resolution|--- |FIXED Status|Needs documenting |RESOLVED Documentation| |https://gitlab.com/koha-com submission| |munity/koha-manual/-/merge_ | |requests/1036 -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org