[Bug 17016] New: Button to clear all fields in budget planning
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 Bug ID: 17016 Summary: Button to clear all fields in budget planning Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: System Administration Assignee: koha-bugs@lists.koha-community.org Reporter: aleishaamohia@hotmail.com QA Contact: testopia@bugs.koha-community.org CC: gmcharlt@gmail.com Currently there is an auto-fill button, but if you want to undo this, now all fields are filled. There should be a clear option. -- 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=17016 Aleisha Amohia <aleishaamohia@hotmail.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=17016 --- Comment #1 from Aleisha Amohia <aleishaamohia@hotmail.com> --- Created attachment 53872 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=53872&action=edit Bug 17016: Button to clear all fields in budget planning I have used the function from admin --> circ and fines rules To test: 1) Go to Admin --> Budgets 2) Click a budget 3) Click Planning -> any option 4) Test the Auto-fill button to see what it does 5) Apply patch and refresh page 6) Should now be a Clear button. Both buttons should show as font-awesome buttons with appropriate icons 7) Click Clear button. Confirm it clears all fields, which then refresh to have 0.00 etc. (default values) Sponsored-by: Catalyst IT -- 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=17016 Aleisha Amohia <aleishaamohia@hotmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Change sponsored?|--- |Sponsored Assignee|koha-bugs@lists.koha-commun |aleishaamohia@hotmail.com |ity.org | -- 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=17016 Claire Gravely <c.gravely@arts.ac.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |c.gravely@arts.ac.uk --- Comment #2 from Claire Gravely <c.gravely@arts.ac.uk> --- Hi, After applying the patch both buttons appear. After clicking on the auto-fill button the fields briefly populate, but then the page refeshes and they clear back to 0.00 again. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Failed QA --- Comment #3 from Owen Leonard <oleonard@myacpl.org> ---
After clicking on the auto-fill button the fields briefly populate, but then the page refreshes and they clear back to 0.00 again.
I get this too. Could you please try to rework the patch so that it doesn't use an inline event attribute? We shouldn't be adding new code which uses things attributes "onclick." The "edit_row" ID on the <tr> is problematic because it is repeated for each row in the table, thus it isn't unique. If you're looking for a hook to target each individual row you could so something like <tr id="edit_row_[% budget_line.budget_id %]"> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 Aleisha Amohia <aleisha@catalyst.net.nz> 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=17016 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #53872|0 |1 is obsolete| | --- Comment #4 from Aleisha Amohia <aleisha@catalyst.net.nz> --- Created attachment 98049 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=98049&action=edit Bug 17016: Button to clear all fields in budget planning I have used the function from admin --> circ and fines rules To test: 1) Go to Admin --> Budgets 2) Click a budget 3) Click Planning -> any option 4) Test the Auto-fill button to see what it does 5) Apply patch and refresh page 6) Should now be a Clear button 7) Auto-fill the row then click Clear button. Confirm it clears all fields and sets the fund remaining back to the original amount and styles. 8) Add another fund and confirm that this still works with multiple funds. Sponsored-by: Catalyst IT -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 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=17016 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #98049|0 |1 is obsolete| | --- Comment #5 from David Nind <david@davidnind.com> --- Created attachment 98060 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=98060&action=edit Bug 17016: Button to clear all fields in budget planning I have used the function from admin --> circ and fines rules To test: 1) Go to Admin --> Budgets 2) Click a budget 3) Click Planning -> any option 4) Test the Auto-fill button to see what it does 5) Apply patch and refresh page 6) Should now be a Clear button 7) Auto-fill the row then click Clear button. Confirm it clears all fields and sets the fund remaining back to the original amount and styles. 8) Add another fund and confirm that this still works with multiple funds. Sponsored-by: Catalyst IT 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=17016 Bouzid Fergani <bouzid.fergani@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #98060|0 |1 is obsolete| | --- Comment #6 from Bouzid Fergani <bouzid.fergani@inlibro.com> --- Created attachment 99047 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=99047&action=edit Bug 17016: Button to clear all fields in budget planning I have used the function from admin --> circ and fines rules To test: 1) Go to Admin --> Budgets 2) Click a budget 3) Click Planning -> any option 4) Test the Auto-fill button to see what it does 5) Apply patch and refresh page 6) Should now be a Clear button 7) Auto-fill the row then click Clear button. Confirm it clears all fields and sets the fund remaining back to the original amount and styles. 8) Add another fund and confirm that this still works with multiple funds. Sponsored-by: Catalyst IT Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Bouzid Fergani <bouzid.fergani@inlibro.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 Bouzid Fergani <bouzid.fergani@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |bouzid.fergani@inlibro.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 --- Comment #7 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Comment on attachment 99047 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=99047 Bug 17016: Button to clear all fields in budget planning Review of attachment 99047: --> (https://bugs.koha-community.org/bugzilla3/page.cgi?id=splinter.html&bug=17016&attachment=99047) ----------------------------------------------------------------- ::: koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqplan.tt @@ +6,5 @@
<title>Koha › Administration › Budgets › Funds › Planning for [% budget_period_description | html %] by [% authcat | html %]</title> [% INCLUDE 'doc-head-close.inc' %] <style>td.locked { background-image: url('[% interface | html %]/[% theme | html %]/img/locked.png'); padding-left : 20px; background-repeat: no-repeat; background-position: 5px 5px; } a.control { font-size:85%;text-decoration:none; } .plan_entry { text-align: right; width:90%; }</style> +<script> +</script>
Not needed. @@ +317,5 @@
+ if (type != "button" && type != "submit" ) { + $(this).val(""); + $(this).prop('disabled', false); + } + if ( type == "checkbox" ) {
When is it a checkbox? I always see text inputs. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA CC| |jonathan.druart@bugs.koha-c | |ommunity.org -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |ASSIGNED -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 Aleisha Amohia <aleisha@catalyst.net.nz> 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=17016 --- Comment #8 from Aleisha Amohia <aleisha@catalyst.net.nz> --- Created attachment 99552 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=99552&action=edit Bug 17016: (follow-up) Removing unnecessary code -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 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=17016 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #99047|0 |1 is obsolete| | --- Comment #9 from David Nind <david@davidnind.com> --- Created attachment 99557 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=99557&action=edit Bug 17016: Button to clear all fields in budget planning I have used the function from admin --> circ and fines rules To test: 1) Go to Admin --> Budgets 2) Click a budget 3) Click Planning -> any option 4) Test the Auto-fill button to see what it does 5) Apply patch and refresh page 6) Should now be a Clear button 7) Auto-fill the row then click Clear button. Confirm it clears all fields and sets the fund remaining back to the original amount and styles. 8) Add another fund and confirm that this still works with multiple funds. Sponsored-by: Catalyst IT Signed-off-by: Bouzid Fergani <bouzid.fergani@inlibro.com> 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=17016 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #99552|0 |1 is obsolete| | --- Comment #10 from David Nind <david@davidnind.com> --- Created attachment 99558 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=99558&action=edit Bug 17016: (follow-up) Removing unnecessary code 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=17016 --- Comment #11 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 99569 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=99569&action=edit Bug 17016: Clear with 0.00 instead of blank -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 --- Comment #12 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Aleisha, David, what about clearing with the previous value 0.00, instead of blank? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch complexity|--- |Small patch 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=17016 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #99557|0 |1 is obsolete| | Attachment #99558|0 |1 is obsolete| | Attachment #99569|0 |1 is obsolete| | --- Comment #13 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 99842 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=99842&action=edit Bug 17016: Button to clear all fields in budget planning Currently there is no way to undo the 'auto-fill'. This patch adds a 'clear' option that resets the row. To test: 1) Go to Admin --> Budgets 2) Click a budget 3) Click Planning -> any option 4) Test the Auto-fill button to see what it does 5) Apply patch and refresh page 6) Should now be a Clear button 7) Auto-fill the row then click Clear button. Confirm it clears all fields and sets the fund remaining back to the original amount and styles. 8) Add another fund and confirm that this still works with multiple funds. Sponsored-by: Catalyst IT Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Bouzid Fergani <bouzid.fergani@inlibro.com> Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 --- Comment #14 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 99843 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=99843&action=edit Bug 17016: (follow-up) Removing unnecessary code Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 --- Comment #15 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 99844 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=99844&action=edit Bug 17016: Clear with 0.00 instead of blank Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 --- Comment #16 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 99876 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=99876&action=edit Bug 17016: (follow-up) Clear with 0.00 instead of blank (Use Price) Using Price, to formatted it correctly if needed So far it will not do anything as 'on_editing => 1' we keep 0.00, but it must be improved later (when we will handle that) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |martin.renvoize@ptfs-europe | |.com --- Comment #17 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Thanks for the quick followup Jonathan :) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to master Version(s)| |20.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=17016 --- Comment #18 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Nice work everyone! Pushed to master for 20.05 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17016 Joy Nelson <joy@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |joy@bywatersolutions.com --- Comment #19 from Joy Nelson <joy@bywatersolutions.com> --- enhancement not backported to 19.11.x -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org