[Bug 33289] New: Vue - Add API client class to interact with svc/config/systempreferences
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 Bug ID: 33289 Summary: Vue - Add API client class to interact with svc/config/systempreferences Change sponsored?: --- Product: Koha Version: unspecified Hardware: All OS: All Status: ASSIGNED Severity: enhancement Priority: P5 - low Component: Architecture, internals, and plumbing Assignee: jonathan.druart+koha@gmail.com Reporter: jonathan.druart+koha@gmail.com QA Contact: testopia@bugs.koha-community.org
From Vue components.
-- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 Jonathan Druart <jonathan.druart+koha@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |33290 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33290 [Bug 33290] Incorrect variable used in http-client.js -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 Jonathan Druart <jonathan.druart+koha@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=33289 --- Comment #1 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- Created attachment 148442 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=148442&action=edit Bug 33289: Add API client class to interact with svc/config/systempreferences On bug 30708 we will need to modify sysprefs from the UI (Vue app), it could be useful for other developments as well and so it is moved on its own bug report. Test plan: It can be tested independently of bug 30708 using the following code: const client = APIClient.sysprefs client.sysprefs .update( "CardnumberLength", "42" ) Sponsored-by: BULAC - http://www.bulac.fr/ -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 Jonathan Druart <jonathan.druart+koha@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |30708 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=30708 [Bug 30708] Creation of a new 'Preservation' module -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 Pedro Amorim <pedro.amorim@ptfs-europe.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=33289 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #148442|0 |1 is obsolete| | --- Comment #2 from Pedro Amorim <pedro.amorim@ptfs-europe.com> --- Created attachment 148596 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=148596&action=edit Bug 33289: Add API client class to interact with svc/config/systempreferences On bug 30708 we will need to modify sysprefs from the UI (Vue app), it could be useful for other developments as well and so it is moved on its own bug report. Test plan: It can be tested independently of bug 30708 using the following code: const client = APIClient.sysprefs client.sysprefs .update( "CardnumberLength", "42" ) Sponsored-by: BULAC - http://www.bulac.fr/ Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 Jonathan Druart <jonathan.druart+koha@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |33408 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33408 [Bug 33408] Fetch sysprefs from svc/config/systempreferences -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 --- Comment #3 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Sorry, the test plan is not detailed enough for me - can you please add some more info? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 --- Comment #4 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- (In reply to Katrin Fischer from comment #3)
Sorry, the test plan is not detailed enough for me - can you please add some more info?
You need to play with the code, or test a follow-up bug. The code I pasted in the commit message is enough to test the change. You can pick a place in a Vue component ('script' part), add the change, hit the page when the component is mounted, then confirm that the syspref value has been changed in DB. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 --- Comment #5 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- (In reply to Jonathan Druart from comment #4)
(In reply to Katrin Fischer from comment #3)
Sorry, the test plan is not detailed enough for me - can you please add some more info?
You need to play with the code, or test a follow-up bug.
The code I pasted in the commit message is enough to test the change. You can pick a place in a Vue component ('script' part), add the change, hit the page when the component is mounted, then confirm that the syspref value has been changed in DB.
I only understood half of that, probably because I have not even basic knowledge of how Vue works. I'll leave this to someone more knowledgeable. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 --- Comment #6 from Pedro Amorim <pedro.amorim@ptfs-europe.com> --- Created attachment 149525 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=149525&action=edit Bug 33289: DO NOT PUSH - test plan only -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |pedro.amorim@ptfs-europe.co | |m --- Comment #7 from Pedro Amorim <pedro.amorim@ptfs-europe.com> --- @Katrin: Before applying patches: * Verify that 'cardnumberlength' is empty in the system preferences Apply both patches: * Visit /cgi-bin/koha/erm/agreements (it will run the test code to change a syspref value from the api-client.js + http-client.js) * Go back to the system preferences and verify that 'cardnumberlength' now has a value of 42 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #148596|0 |1 is obsolete| | --- Comment #8 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 149526 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=149526&action=edit Bug 33289: Add API client class to interact with svc/config/systempreferences On bug 30708 we will need to modify sysprefs from the UI (Vue app), it could be useful for other developments as well and so it is moved on its own bug report. Test plan: It can be tested independently of bug 30708 using the following code: const client = APIClient.sysprefs client.sysprefs .update( "CardnumberLength", "42" ) Sponsored-by: BULAC - http://www.bulac.fr/ Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA CC| |martin.renvoize@ptfs-europe | |.com --- Comment #9 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Clear and simple code all working as expected. Passing QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #149525|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=33289 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to master Version(s)| |23.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=33289 --- Comment #10 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Pushed to master for 23.05. Nice work everyone, thanks! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to master |Pushed to stable Version(s)|23.05.00 |23.05.00,22.11.05 released in| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 --- Comment #11 from Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com> --- Nice work everyone! Pushed to stable for 22.11.x -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 Bug 33289 depends on bug 33290, which changed state. Bug 33290 Summary: Incorrect variable used in http-client.js https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33290 What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to stable |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to stable |RESOLVED Resolution|--- |FIXED CC| |lucas@bywatersolutions.com --- Comment #12 from Lucas Gass <lucas@bywatersolutions.com> --- Missing dependencies for 22.05.x backport. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33289 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dcook@prosentient.com.au See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=34369 -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org