[Bug 34082] New: Cut some redundancy in OPAC JavaScript string translations
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34082 Bug ID: 34082 Summary: Cut some redundancy in OPAC JavaScript string translations Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: ASSIGNED Severity: enhancement Priority: P5 - low Component: Templates Assignee: oleonard@myacpl.org Reporter: oleonard@myacpl.org QA Contact: testopia@bugs.koha-community.org CC: testopia@bugs.koha-community.org Depends on: 34035 A few templates in the OPAC still define a string in one place and then use the string in another. If the string is used only once I don't think it's necessary to separate the definition from the use. Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34035 [Bug 34035] Move translatable strings out of opac-bottom.inc: Tags -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34082 Bug 34082 depends on bug 34035, which changed state. Bug 34035 Summary: Move translatable strings out of opac-bottom.inc: Tags https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34035 What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to master |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=34082 --- Comment #1 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Hi Owen, you did a lot of work on moving the JS/template strings lately, is this one still needed? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34082 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch complexity|--- |Small patch 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=34082 --- Comment #2 from Owen Leonard <oleonard@myacpl.org> --- Created attachment 159521 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=159521&action=edit Bug 34082: Cut some redundancy in OPAC JavaScript string translations This patch consolidates some JS code so that we're not defining a string ine one place and using it once elsewhere. With JS-friendly translations tools we don't need this workaround. To test, apply the patch and go to Administration -> Circulation and fine rules. - Configure an item type rule with the "OPAC item level holds" setting set to "Force." - Log in to the OPAC and locate a record with that item type and multiple items. An example in the sample data: /cgi-bin/koha/opac-detail.pl?biblionumber=12 - Place a hold on the item. - The holds screen should show a table of items. - Open your browser's developer tools. - In the Console tab, paste in this code and hit ENTER. - All radio buttons in the table of items should be cleared. - Click the "Confirm hold" button. You should get an alert: "Expecting a specific item selection." - Log in to the OPAC and click the "Search history" tab from the user summary page. - Check one or more checkboxes next to search history items and click the "Remove selected searches." - You should get an alert: "Are you sure you want to delete selected search history entries?" - Log in to the OPAC, create a new list if necessary, and add some titles to the list. - Test that confirmation messages show correctly: - Deleting a single title by clicking the "Remove from this list" link. - Deleting multiple titles by checking boxes and clicking "Remove from list." - Deleting a list. - In Administration -> System preferences, enable TagsEnabled if necessary. - Log in to the OPAC and tag one or more items. - From the Tag cloud page, check one or more boxes for your tags, and click the "Delete selected tags" button at the bottom of the page. - The confirmation message should display correctly. - To test the change to opac-account.tt you have to install a payment plugin, e.g. https://gitlab.com/thekesolutions/plugins/koha-plugin-pay-via-paypal, and attempt to submit a payment which is below the minimum payment threshold set in the plugin's configuration. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34082 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |david@davidnind.com --- Comment #3 from David Nind <david@davidnind.com> --- Two things I couldn't test: 1. Circulation and fine rules: "In the Console tab, paste in this code and hit ENTER." There is no code provided to enter into the console. 2. Payment plugin: in the current master, the PayPal plugin doesn't work - if you go to configure, you get a screen with nothing in the content area, you can no longer click on any navigation links, and there are errors in the console.[1] Is there another payment plugin to try? [1] Errors in the console: GET http://127.0.0.1:8081/api/v1/contrib/paypal/static/_nuxt/77c7724cb7b76d9c6f1... [HTTP/1.1 404 Not Found 333ms] GET http://127.0.0.1:8081/api/v1/contrib/paypal/static/_nuxt/b50d36cd3cebca67473... [HTTP/1.1 404 Not Found 1594ms] GET http://127.0.0.1:8081/api/v1/contrib/paypal/static/_nuxt/595ecd6949576550739... [HTTP/1.1 404 Not Found 1265ms] GET http://127.0.0.1:8081/api/v1/contrib/paypal/static/_nuxt/78ed504e6dbe893d56d... [HTTP/1.1 404 Not Found 2561ms] JQMIGRATE: Migrate is installed, version 3.3.2 jquery-migrate-3.3.2.min_23.1200000.js:2:709 GET http://127.0.0.1:8081/api/v1/contrib/paypal/static/_nuxt/77c7724cb7b76d9c6f1... [HTTP/1.1 404 Not Found 2511ms] Loading failed for the <script> with source “http://127.0.0.1:8081/api/v1/contrib/paypal/static/_nuxt/77c7724cb7b76d9c6f1f.js”. run.pl:783:97 GET http://127.0.0.1:8081/api/v1/contrib/paypal/static/_nuxt/b50d36cd3cebca67473... [HTTP/1.1 404 Not Found 1359ms] Loading failed for the <script> with source “http://127.0.0.1:8081/api/v1/contrib/paypal/static/_nuxt/b50d36cd3cebca67473e.js”. run.pl:783:203 The resource at “http://127.0.0.1:8081/api/v1/contrib/paypal/static/_nuxt/78ed504e6dbe893d56d8.js” preloaded with link preload was not used within a few seconds. Make sure all attributes of the preload tag are set correctly. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34082 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Failed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34082 Owen Leonard <oleonard@myacpl.org> 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=34082 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #159521|0 |1 is obsolete| | --- Comment #4 from Owen Leonard <oleonard@myacpl.org> --- Created attachment 160147 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=160147&action=edit Bug 34082: Cut some redundancy in OPAC JavaScript string translations This patch consolidates some JS code so that we're not defining a string ine one place and using it once elsewhere. With JS-friendly translations tools we don't need this workaround. To test, apply the patch and go to Administration -> Circulation and fine rules. - Configure an item type rule with the "OPAC item level holds" setting set to "Force." - Log in to the OPAC and locate a record with that item type and multiple items. An example in the sample data: /cgi-bin/koha/opac-detail.pl?biblionumber=12 - Place a hold on the item. - The holds screen should show a table of items. - Open your browser's developer tools. - In the Console tab, paste in this code and hit ENTER: $(".checkitem").prop("checked", false); - All radio buttons in the table of items should be cleared. - Click the "Confirm hold" button. You should get an alert: "Expecting a specific item selection." - Log in to the OPAC and click the "Search history" tab from the user summary page. - Check one or more checkboxes next to search history items and click the "Remove selected searches." - You should get an alert: "Are you sure you want to delete selected search history entries?" - Log in to the OPAC, create a new list if necessary, and add some titles to the list. - Test that confirmation messages show correctly: - Deleting a single title by clicking the "Remove from this list" link. - Deleting multiple titles by checking boxes and clicking "Remove from list." - Deleting a list. - In Administration -> System preferences, enable TagsEnabled if necessary. - Log in to the OPAC and tag one or more items. - From the Tag cloud page, check one or more boxes for your tags, and click the "Delete selected tags" button at the bottom of the page. - The confirmation message should display correctly. - To test the change to opac-account.tt you have to install a payment plugin, e.g. https://gitlab.com/thekesolutions/plugins/koha-plugin-pay-via-paypal, and attempt to submit a payment which is below the minimum payment threshold set in the plugin's configuration. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34082 --- Comment #5 from Owen Leonard <oleonard@myacpl.org> --- (In reply to David Nind from comment #3)
2. Payment plugin: in the current master, the PayPal plugin doesn't work
It works for me with the latest version (v2.5.0). I think you need to restart_all after uploading the plugin. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34082 --- Comment #6 from David Nind <david@davidnind.com> --- (In reply to Owen Leonard from comment #5)
(In reply to David Nind from comment #3)
2. Payment plugin: in the current master, the PayPal plugin doesn't work
It works for me with the latest version (v2.5.0). I think you need to restart_all after uploading the plugin.
That was what I needed to do. Thanks! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34082 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=34082 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #160147|0 |1 is obsolete| | --- Comment #7 from David Nind <david@davidnind.com> --- Created attachment 160170 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=160170&action=edit Bug 34082: Cut some redundancy in OPAC JavaScript string translations This patch consolidates some JS code so that we're not defining a string ine one place and using it once elsewhere. With JS-friendly translations tools we don't need this workaround. To test, apply the patch and go to Administration -> Circulation and fine rules. - Configure an item type rule with the "OPAC item level holds" setting set to "Force." - Log in to the OPAC and locate a record with that item type and multiple items. An example in the sample data: /cgi-bin/koha/opac-detail.pl?biblionumber=12 - Place a hold on the item. - The holds screen should show a table of items. - Open your browser's developer tools. - In the Console tab, paste in this code and hit ENTER: $(".checkitem").prop("checked", false); - All radio buttons in the table of items should be cleared. - Click the "Confirm hold" button. You should get an alert: "Expecting a specific item selection." - Log in to the OPAC and click the "Search history" tab from the user summary page. - Check one or more checkboxes next to search history items and click the "Remove selected searches." - You should get an alert: "Are you sure you want to delete selected search history entries?" - Log in to the OPAC, create a new list if necessary, and add some titles to the list. - Test that confirmation messages show correctly: - Deleting a single title by clicking the "Remove from this list" link. - Deleting multiple titles by checking boxes and clicking "Remove from list." - Deleting a list. - In Administration -> System preferences, enable TagsEnabled if necessary. - Log in to the OPAC and tag one or more items. - From the Tag cloud page, check one or more boxes for your tags, and click the "Delete selected tags" button at the bottom of the page. - The confirmation message should display correctly. - To test the change to opac-account.tt you have to install a payment plugin, e.g. https://gitlab.com/thekesolutions/plugins/koha-plugin-pay-via-paypal, and attempt to submit a payment which is below the minimum payment threshold set in the plugin's configuration. 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=34082 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=34082 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #160170|0 |1 is obsolete| | --- Comment #8 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 164842 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=164842&action=edit Bug 34082: Cut some redundancy in OPAC JavaScript string translations This patch consolidates some JS code so that we're not defining a string ine one place and using it once elsewhere. With JS-friendly translations tools we don't need this workaround. To test, apply the patch and go to Administration -> Circulation and fine rules. - Configure an item type rule with the "OPAC item level holds" setting set to "Force." - Log in to the OPAC and locate a record with that item type and multiple items. An example in the sample data: /cgi-bin/koha/opac-detail.pl?biblionumber=12 - Place a hold on the item. - The holds screen should show a table of items. - Open your browser's developer tools. - In the Console tab, paste in this code and hit ENTER: $(".checkitem").prop("checked", false); - All radio buttons in the table of items should be cleared. - Click the "Confirm hold" button. You should get an alert: "Expecting a specific item selection." - Log in to the OPAC and click the "Search history" tab from the user summary page. - Check one or more checkboxes next to search history items and click the "Remove selected searches." - You should get an alert: "Are you sure you want to delete selected search history entries?" - Log in to the OPAC, create a new list if necessary, and add some titles to the list. - Test that confirmation messages show correctly: - Deleting a single title by clicking the "Remove from this list" link. - Deleting multiple titles by checking boxes and clicking "Remove from list." - Deleting a list. - In Administration -> System preferences, enable TagsEnabled if necessary. - Log in to the OPAC and tag one or more items. - From the Tag cloud page, check one or more boxes for your tags, and click the "Delete selected tags" button at the bottom of the page. - The confirmation message should display correctly. - To test the change to opac-account.tt you have to install a payment plugin, e.g. https://gitlab.com/thekesolutions/plugins/koha-plugin-pay-via-paypal, and attempt to submit a payment which is below the minimum payment threshold set in the plugin's configuration. 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=34082 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kyle@bywatersolutions.com QA Contact|testopia@bugs.koha-communit |kyle@bywatersolutions.com |y.org | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34082 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to main 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=34082 --- Comment #9 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=34082 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |fridolin.somers@biblibre.co | |m Status|Pushed to main |Needs documenting --- Comment #10 from Fridolin Somers <fridolin.somers@biblibre.com> --- Not backported 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=34082 Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |caroline.cyr-la-rose@inlibr | |o.com Status|Needs documenting |RESOLVED Resolution|--- |FIXED --- Comment #11 from Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> --- Architecture change, nothing to add/edit in the Koha manual. -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org