Sometimes you may want to have a report optionally limit to an itemtype or branch etc. It would be nice to have an 'All' option in the report dropdowns
Created attachment 91848 [details] [review] Bug 23389: Add 'All' option to report dropdowns This patch adds and 'all' option t rpeort dropdowns Note you will need to use 'LIKE' instead of '=' to allow 'All' to work To test: 1 - Write a report: SELECT branchname FROM branches WHERE branchcode LIKE <<Branch|branches>> 2 - Run it 3 - Select a branch 4 - You get one branch info 5 - Note you cannot select all 6 - Apply patch 7 - Run report 8 - Select 'All' 9 - You get all branches 10 - Select one branch 11 - You get one branch
I like the idea, but I have some reports that, if my staff were to run with "All" as the option, would overload our system. Is there a way you can write this so that "All" is optional? Like if you could add some kind of flag after a second pipe or something that. Something like "<<Branch|branches>>" doesn't give you the "All" option but "<<Branch|branches|all>>" does give you the "All" option?
Created attachment 91881 [details] [review] Bug 23389: Add 'All' option to report dropdowns This patch optionally adds an 'all' option to report dropdowns Note you will need to use 'LIKE' instead of '=' to allow 'All' to work To test: 1 - Write a report: SELECT branchname FROM branches WHERE branchcode LIKE <<Branch|branches>> 2 - Run it 3 - Select a branch 4 - You get one branch info 5 - Note you cannot select all 6 - Apply patch 7 - Run report 8 - No change 9 - Update report like: SELECT branchname FROM branches WHERE branchcode LIKE <<Branch|branches:all>> 10 - Run report 11 - Select 'All' 12 - You get all branches 13 - Select one branch 14 - You get one branch 15 - Test with other authorised categories (itemtypes, YES_NO, etc.) 16 - Confirm it works as expected 17 - Prove -v t/db_dependent/Reports/Guided.t
Created attachment 91887 [details] [review] Bug 23389: Add 'All' option to report dropdowns This patch optionally adds an 'all' option to report dropdowns Note you will need to use 'LIKE' instead of '=' to allow 'All' to work To test: 1 - Write a report: SELECT branchname FROM branches WHERE branchcode LIKE <<Branch|branches>> 2 - Run it 3 - Select a branch 4 - You get one branch info 5 - Note you cannot select all 6 - Apply patch 7 - Run report 8 - No change 9 - Update report like: SELECT branchname FROM branches WHERE branchcode LIKE <<Branch|branches:all>> 10 - Run report 11 - Select 'All' 12 - You get all branches 13 - Select one branch 14 - You get one branch 15 - Test with other authorised categories (itemtypes, YES_NO, etc.) 16 - Confirm it works as expected 17 - Prove -v t/db_dependent/Reports/Guided.t Signed-off-by: Lisette Scheer <lisetteslatah@gmail.com>
I came here to change to signed off and realized I totally skipped the prove step, which I don't believe I can do on the sandboxes. Lisette
Hi Lisette, that's ok - we can take care of that step in QA. Please switch :)
Created attachment 93555 [details] [review] Bug 23389: Add 'All' option to report dropdowns This patch optionally adds an 'all' option to report dropdowns Note you will need to use 'LIKE' instead of '=' to allow 'All' to work To test: 1 - Write a report: SELECT branchname FROM branches WHERE branchcode LIKE <<Branch|branches>> 2 - Run it 3 - Select a branch 4 - You get one branch info 5 - Note you cannot select all 6 - Apply patch 7 - Run report 8 - No change 9 - Update report like: SELECT branchname FROM branches WHERE branchcode LIKE <<Branch|branches:all>> 10 - Run report 11 - Select 'All' 12 - You get all branches 13 - Select one branch 14 - You get one branch 15 - Test with other authorised categories (itemtypes, YES_NO, etc.) 16 - Confirm it works as expected 17 - Prove -v t/db_dependent/Reports/Guided.t Signed-off-by: Lisette Scheer <lisetteslatah@gmail.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Love!
Nice work! Pushed to master for 19.11.00
backported to 19.05.x for 19.05.06
Backported to 18.11.x for 18.11.12