It would make sense to have a "Duplicate" options in guided_reports.pl on the New Report button outside of the "Use saved" phase of the page. Christopher
Created attachment 48785 [details] [review] Bug 16000 - Duplicate a report from the New Reports button This patch creates a combined edit/duplicate/delete toolbar menu option similar to the one on the bibliographic detail page. Also added is the "Schedule" link which was previously only available from the main list of saved reports. Also added is some deletion confirmation JavaScript for deletions initiated from the toolbar. To test, apply the patch and go to Reports -> Saved reports. - Click "Show" in the menu for any saved report. The toolbar which appears on this page should show the new menu items. - Confirm the behavior of all the buttons. - As you check the behavior of the button actions, check that the toolbar is shown and hidden appropriately for each action. - Confirm that the toolbar is correctly shown or hidden when building a guided report. - Confirm that the "Schedule" button is shown or hidden according to the logged-in user's "schedule_tasks" permission. - Confirm that clicking the "Delete" menu option triggers a JS confirmation.
Created attachment 48829 [details] [review] Bug 16000 - Duplicate a report from the New Reports button This patch creates a combined edit/duplicate/delete toolbar menu option similar to the one on the bibliographic detail page. Also added is the "Schedule" link which was previously only available from the main list of saved reports. Also added is some deletion confirmation JavaScript for deletions initiated from the toolbar. To test, apply the patch and go to Reports -> Saved reports. - Click "Show" in the menu for any saved report. The toolbar which appears on this page should show the new menu items. - Confirm the behavior of all the buttons. - As you check the behavior of the button actions, check that the toolbar is shown and hidden appropriately for each action. - Confirm that the toolbar is correctly shown or hidden when building a guided report. - Confirm that the "Schedule" button is shown or hidden according to the logged-in user's "schedule_tasks" permission. - Confirm that clicking the "Delete" menu option triggers a JS confirmation. Signed-off-by: Nicole C Engard <nengard@bywatersolutions.com>
While the menu works, it doesn't deliver. Duplicate just puts me in a new report, not a duplicate. The menu could also be visible when editing. I don't think that would pose any issues. Do you? The other menu items appear to work as expected.
(In reply to Christopher Brannon from comment #3) > While the menu works, it doesn't deliver. Duplicate just puts me in a new > report, not a duplicate. I do not find this to be the case. Have you tried it with more than one report? > The menu could also be visible when editing. I don't think that would pose > any issues. Do you? This is something which I describe in my latest update to the interface patterns page on the wiki: "In this view the toolbar is not displayed, because the user is expected to either submit a completed form or choose the 'Cancel' link to abort the process of creating a new entry." https://wiki.koha-community.org/wiki/Interface_patterns#The_.27New.27_entry_form However, the option of duplicating something might be relevant during an edit process. I wonder if we should have a "Save as new report" option or something like that?
(In reply to Owen Leonard from comment #4) > (In reply to Christopher Brannon from comment #3) > > While the menu works, it doesn't deliver. Duplicate just puts me in a new > > report, not a duplicate. > > I do not find this to be the case. Have you tried it with more than one > report? Yes. You can see this in action here: http://screencast.com/t/TS06SJOhpyY > > The menu could also be visible when editing. I don't think that would pose > > any issues. Do you? > > This is something which I describe in my latest update to the interface > patterns page on the wiki: > > "In this view the toolbar is not displayed, because the user is expected to > either submit a completed form or choose the 'Cancel' link to abort the > process of creating a new entry." > > https://wiki.koha-community.org/wiki/Interface_patterns#The_.27New. > 27_entry_form > > However, the option of duplicating something might be relevant during an > edit process. I wonder if we should have a "Save as new report" option or > something like that? I would suggest a secondary Update button, such as "Update and Duplicate", since we don't use the term Save on the screen.
(In reply to Christopher Brannon from comment #5) > > I do not find this to be the case. Have you tried it with more than one > > report? > > Yes. You can see this in action here: http://screencast.com/t/TS06SJOhpyY I still can't reproduce this problem. Can you please post the SQL of a report which is showing the problem? Does the "Duplicate" option work from the "Actions" menu on the list of saved reports? > I would suggest a secondary Update button, such as "Update and Duplicate", > since we don't use the term Save on the screen. I think that should be its own enhancement request.
(In reply to Owen Leonard from comment #6) > (In reply to Christopher Brannon from comment #5) > > > I do not find this to be the case. Have you tried it with more than one > > > report? > > > > Yes. You can see this in action here: http://screencast.com/t/TS06SJOhpyY > > I still can't reproduce this problem. Can you please post the SQL of a > report which is showing the problem? Does the "Duplicate" option work from > the "Actions" menu on the list of saved reports? The screencast I posted demonstrates me showing the original "Duplicate" working from the list of saved reports. It also shows the SQL report I used.
I have tested again and it is working now. This must be another case of not clearing the cache. I will go ahead and sign off on this.
Patch tested with a sandbox, by Christopher Brannon <cbrannon@cdalibrary.org>
Created attachment 49229 [details] [review] Bug 16000 - Duplicate a report from the New Reports button This patch creates a combined edit/duplicate/delete toolbar menu option similar to the one on the bibliographic detail page. Also added is the "Schedule" link which was previously only available from the main list of saved reports. Also added is some deletion confirmation JavaScript for deletions initiated from the toolbar. To test, apply the patch and go to Reports -> Saved reports. - Click "Show" in the menu for any saved report. The toolbar which appears on this page should show the new menu items. - Confirm the behavior of all the buttons. - As you check the behavior of the button actions, check that the toolbar is shown and hidden appropriately for each action. - Confirm that the toolbar is correctly shown or hidden when building a guided report. - Confirm that the "Schedule" button is shown or hidden according to the logged-in user's "schedule_tasks" permission. - Confirm that clicking the "Delete" menu option triggers a JS confirmation. Signed-off-by: Nicole C Engard <nengard@bywatersolutions.com> Signed-off-by: Christopher Brannon <cbrannon@cdalibrary.org>
(In reply to Christopher Brannon from comment #8) > I have tested again and it is working now. This must be another case of not > clearing the cache. I will go ahead and sign off on this. No it does not :) Owen, to replicate: /reports/guided_reports.pl?phase=Use saved Actions > edit Update SQL Edit > Duplicate Will open an empty form
Created attachment 49247 [details] [review] Bug 16000: Simplify JS code
(In reply to Jonathan Druart from comment #12) > Created attachment 49247 [details] [review] [review] > Bug 16000: Simplify JS code Owen, feel free to embed it into your patch if it's easier for you (i.e. I don't care about the authorship).
Created attachment 49276 [details] [review] Bug 16000 [Revised] Duplicate a report from the New Reports button This patch creates a combined edit/duplicate/delete toolbar menu option similar to the one on the bibliographic detail page. Also added is the "Schedule" link which was previously only available from the main list of saved reports. Also added is some deletion confirmation JavaScript for deletions initiated from the toolbar. To test, apply the patch and go to Reports -> Saved reports. - Click "Show" in the menu for any saved report. The toolbar which appears on this page should show the new menu items. - Confirm the behavior of all the buttons. - As you check the behavior of the button actions, check that the toolbar is shown and hidden appropriately for each action. - Confirm that the toolbar is correctly shown or hidden when building a guided report. - Confirm that the "Schedule" button is shown or hidden according to the logged-in user's "schedule_tasks" permission. - Confirm that clicking the "Delete" menu option triggers a JS confirmation. Revision passes the sql data to the template in the case of the "save_successful" screen.
Created attachment 49277 [details] [review] [SIGNED-OFF] Bug 16000: Simplify JS code Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Sorry, does not apply: Auto-merging koha-tmpl/intranet-tmpl/prog/en/modules/reports/guided_reports_start.tt Auto-merging koha-tmpl/intranet-tmpl/prog/en/includes/reports-toolbar.inc CONFLICT (content): Merge conflict in koha-tmpl/intranet-tmpl/prog/en/includes/reports-toolbar.inc Failed to merge in the changes.
I was having trouble getting it to load in a sandbox yesterday. Sandboxes are not sending me e-mails, so had no clue what was happening. Now we know. Christopher
Created attachment 49541 [details] [review] Bug 16000 [Revised] Duplicate a report from the New Reports button This patch creates a combined edit/duplicate/delete toolbar menu option similar to the one on the bibliographic detail page. Also added is the "Schedule" link which was previously only available from the main list of saved reports. Also added is some deletion confirmation JavaScript for deletions initiated from the toolbar. To test, apply the patch and go to Reports -> Saved reports. - Click "Show" in the menu for any saved report. The toolbar which appears on this page should show the new menu items. - Confirm the behavior of all the buttons. - As you check the behavior of the button actions, check that the toolbar is shown and hidden appropriately for each action. - Confirm that the toolbar is correctly shown or hidden when building a guided report. - Confirm that the "Schedule" button is shown or hidden according to the logged-in user's "schedule_tasks" permission. - Confirm that clicking the "Delete" menu option triggers a JS confirmation. Revision passes the sql data to the template in the case of the "save_successful" screen.
Created attachment 49542 [details] [review] Bug 16000: Simplify JS code Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Created attachment 49543 [details] [review] Bug 16000 [Revised] Duplicate a report from the New Reports button This patch creates a combined edit/duplicate/delete toolbar menu option similar to the one on the bibliographic detail page. Also added is the "Schedule" link which was previously only available from the main list of saved reports. Also added is some deletion confirmation JavaScript for deletions initiated from the toolbar. To test, apply the patch and go to Reports -> Saved reports. - Click "Show" in the menu for any saved report. The toolbar which appears on this page should show the new menu items. - Confirm the behavior of all the buttons. - As you check the behavior of the button actions, check that the toolbar is shown and hidden appropriately for each action. - Confirm that the toolbar is correctly shown or hidden when building a guided report. - Confirm that the "Schedule" button is shown or hidden according to the logged-in user's "schedule_tasks" permission. - Confirm that clicking the "Delete" menu option triggers a JS confirmation. Revision passes the sql data to the template in the case of the "save_successful" screen. Signed-off-by: Christopher Brannon <cbrannon@cdalibrary.org>
Created attachment 49544 [details] [review] Bug 16000: Simplify JS code Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Christopher Brannon <cbrannon@cdalibrary.org>
Showing an existing export, the schedule button appears twice now. (cgi-bin/koha/reports/guided_reports.pl?reports=1&phase=Show%20SQL)
(In reply to Katrin Fischer from comment #23) > Showing an existing export, the schedule button appears twice now. > (cgi-bin/koha/reports/guided_reports.pl?reports=1&phase=Show%20SQL) Yep. I missed that one. :/
Schedule button duplicates after update or save as well.
Rather than resolve the merge errors with Bug 15421, I resolve that my patch is made obsolete by Bug 15421. *** This bug has been marked as a duplicate of bug 15421 ***