Summary: | Convert RoutingListNote system preference to additional contents | ||
---|---|---|---|
Product: | Koha | Reporter: | Owen Leonard <oleonard> |
Component: | Serials | Assignee: | Owen Leonard <oleonard> |
Status: | Pushed to main --- | QA Contact: | Testopia <testopia> |
Severity: | enhancement | ||
Priority: | P5 - low | CC: | david, jonathan.druart, julian.maurice, lucas, nick, testopia |
Version: | Main | Keywords: | release-notes-needed |
Hardware: | All | ||
OS: | All | ||
Change sponsored?: | --- | Patch complexity: | Small patch |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: |
This enhancement converts the RoutingListNote system preference to an HTML customization, making it possible to have language- and library-specific content.
NOTE: This removes the default content that was previously used in the RoutingListNote system preference. The RoutingSerials system preference was updated to mention the RoutingListNote HTML customization option.
|
Version(s) released in: |
25.05.00
|
Circulation function: | |||
Bug Depends on: | 31383, 35151 | ||
Bug Blocks: | 26050 | ||
Attachments: |
Bug 35152: Convert RoutingListNote system preference to additional contents
Bug 35152: Convert RoutingListNote system preference to additional contents Bug 35152: Convert RoutingListNote system preference to additional contents Bug 35152: Convert RoutingListNote system preference to additional contents Bug 35152: Convert RoutingListNote system preference to additional contents Bug 35152: Convert RoutingListNote system preference to additional contents Bug 35152: Convert RoutingListNote system preference to additional contents Bug 35152: Convert RoutingListNote system preference to additional contents Bug 35152: Display 'syspref removed' success only if removed |
Description
Owen Leonard
2023-10-25 17:23:01 UTC
Created attachment 158747 [details] [review] Bug 35152: Convert RoutingListNote system preference to additional contents This patch moves the RoutingListNote system preference into HTML customizations, making it possible to have language- and library-specific content. To test you should have some content in the RoutingListNote system preference before applying the patch. Apply the patch and run the database update process. - In the staff client, go to Tools -> HTML customizations and verify that the content from RoutingListNote is now stored there. - The HTML customization entry form should offer RoutingListNote as a choice under "Display location." - Update and reinstall active translations (for instance fr-FR): - perl misc/translator/translate update fr-FR - perl misc/translator/translate install fr-FR - Enable the translation if necessary under Administration -> System preferences -> language. - Edit the RoutingListNote HTML customization and add unique content to the "fr-FR" tab. - Go to Serials and create a subscription if necessary. - From the subscription detail page, click "Create routing list" in the left-hand sidebar. - Add one or more recipients to the list and click "Save". - On the "Preview routing list" page click "Save and preview routing slip". - In the pop-up window with the routing list preview you should see the content you added to the RoutingListNote HTML customization. - Switch to your updated translation and confirm that the content you added for your translation shows up correctly. - Go to Administration -> System preferences and search for "RoutingListNote." It should return no results. NOTE: This patch does not keep the default content which was stored by the RoutingListNote system preference. Having a default value for that kind of preference is not standard. Instead I have updated the description of the RoutingSerials preference to add a mention of the RoutingListNote HTML customization option. Created attachment 159718 [details] [review] Bug 35152: Convert RoutingListNote system preference to additional contents This patch moves the RoutingListNote system preference into HTML customizations, making it possible to have language- and library-specific content. To test you should have some content in the RoutingListNote system preference before applying the patch. Apply the patch and run the database update process. - In the staff client, go to Tools -> HTML customizations and verify that the content from RoutingListNote is now stored there. - The HTML customization entry form should offer RoutingListNote as a choice under "Display location." - Update and reinstall active translations (for instance fr-FR): - perl misc/translator/translate update fr-FR - perl misc/translator/translate install fr-FR - Enable the translation if necessary under Administration -> System preferences -> language. - Edit the RoutingListNote HTML customization and add unique content to the "fr-FR" tab. - Go to Serials and create a subscription if necessary. - From the subscription detail page, click "Create routing list" in the left-hand sidebar. - Add one or more recipients to the list and click "Save". - On the "Preview routing list" page click "Save and preview routing slip". - In the pop-up window with the routing list preview you should see the content you added to the RoutingListNote HTML customization. - Switch to your updated translation and confirm that the content you added for your translation shows up correctly. - Go to Administration -> System preferences and search for "RoutingListNote." It should return no results. NOTE: This patch does not keep the default content which was stored by the RoutingListNote system preference. Having a default value for that kind of preference is not standard. Instead I have updated the description of the RoutingSerials preference to add a mention of the RoutingListNote HTML customization option. Signed-off-by: David Nind <david@davidnind.com> I can see one minor issue: if RoutingListNote preference still have its default value (which is: To change this note edit <a href="/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=RoutingListNote#jumped">RoutingListNote</a> system preference.) it's copied over to the HTML customization and it now contains a link to a removed preference. I'm not sure of what should be done about it. Should we rewrite it in the db update ? Should we remove it ? (In reply to Julian Maurice from comment #3) > I can see one minor issue: if RoutingListNote preference still have its > default value Did the database update not take care of this? (In reply to Julian Maurice from comment #4) > Is this bug really dependent on bug 35151 ? Probably not... I was trying to make each one of these HTML customization patches dependent on the previous one to avoid conflicts. (In reply to Owen Leonard from comment #5) > (In reply to Julian Maurice from comment #3) > > I can see one minor issue: if RoutingListNote preference still have its > > default value > > Did the database update not take care of this? The database update moves RoutingListNote preference content to a new HTML customization, but does nothing to detect if it still has its default value Please QA - it's blocking other dependent bugs! Doesn't apply, and comment 6 needs an update I think just: if ($routinglistnote) { $routinglistnote = "You can edit this note in the HTML customizations section of Koha <link> to the page" if $routinglistnote eq q{To change this note edit <a href=\"/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=RoutingListNote#jumped\">RoutingListNote</a> system preference.} Created attachment 167241 [details] [review] Bug 35152: Convert RoutingListNote system preference to additional contents This patch moves the RoutingListNote system preference into HTML customizations, making it possible to have language- and library-specific content. To test you should have some content in the RoutingListNote system preference before applying the patch. Apply the patch and run the database update process. - In the staff client, go to Tools -> HTML customizations and verify that the content from RoutingListNote is now stored there. - The HTML customization entry form should offer RoutingListNote as a choice under "Display location." - Update and reinstall active translations (for instance fr-FR): - perl misc/translator/translate update fr-FR - perl misc/translator/translate install fr-FR - Enable the translation if necessary under Administration -> System preferences -> language. - Edit the RoutingListNote HTML customization and add unique content to the "fr-FR" tab. - Go to Serials and create a subscription if necessary. - From the subscription detail page, click "Create routing list" in the left-hand sidebar. - Add one or more recipients to the list and click "Save". - On the "Preview routing list" page click "Save and preview routing slip". - In the pop-up window with the routing list preview you should see the content you added to the RoutingListNote HTML customization. - Switch to your updated translation and confirm that the content you added for your translation shows up correctly. - Go to Administration -> System preferences and search for "RoutingListNote." It should return no results. NOTE: This patch does not keep the default content which was stored by the RoutingListNote system preference. Having a default value for that kind of preference is not standard. Instead I have updated the description of the RoutingSerials preference to add a mention of the RoutingListNote HTML customization option. Signed-off-by: David Nind <david@davidnind.com> Created attachment 168011 [details] [review] Bug 35152: Convert RoutingListNote system preference to additional contents This patch moves the RoutingListNote system preference into HTML customizations, making it possible to have language- and library-specific content. To test you should have some content in the RoutingListNote system preference before applying the patch. Apply the patch and run the database update process. - In the staff client, go to Tools -> HTML customizations and verify that the content from RoutingListNote is now stored there. - The HTML customization entry form should offer RoutingListNote as a choice under "Display location." - Update and reinstall active translations (for instance fr-FR): - perl misc/translator/translate update fr-FR - perl misc/translator/translate install fr-FR - Enable the translation if necessary under Administration -> System preferences -> language. - Edit the RoutingListNote HTML customization and add unique content to the "fr-FR" tab. - Go to Serials and create a subscription if necessary. - From the subscription detail page, click "Create routing list" in the left-hand sidebar. - Add one or more recipients to the list and click "Save". - On the "Preview routing list" page click "Save and preview routing slip". - In the pop-up window with the routing list preview you should see the content you added to the RoutingListNote HTML customization. - Switch to your updated translation and confirm that the content you added for your translation shows up correctly. - Go to Administration -> System preferences and search for "RoutingListNote." It should return no results. NOTE: This patch does not keep the default content which was stored by the RoutingListNote system preference. Having a default value for that kind of preference is not standard. Instead I have updated the description of the RoutingSerials preference to add a mention of the RoutingListNote HTML customization option. Signed-off-by: David Nind <david@davidnind.com> Created attachment 170713 [details] [review] Bug 35152: Convert RoutingListNote system preference to additional contents This patch moves the RoutingListNote system preference into HTML customizations, making it possible to have language- and library-specific content. To test you should have some content in the RoutingListNote system preference before applying the patch. Apply the patch and run the database update process. - In the staff client, go to Tools -> HTML customizations and verify that the content from RoutingListNote is now stored there. - The HTML customization entry form should offer RoutingListNote as a choice under "Display location." - Update and reinstall active translations (for instance fr-FR): - perl misc/translator/translate update fr-FR - perl misc/translator/translate install fr-FR - Enable the translation if necessary under Administration -> System preferences -> language. - Edit the RoutingListNote HTML customization and add unique content to the "fr-FR" tab. - Go to Serials and create a subscription if necessary. - From the subscription detail page, click "Create routing list" in the left-hand sidebar. - Add one or more recipients to the list and click "Save". - On the "Preview routing list" page click "Save and preview routing slip". - In the pop-up window with the routing list preview you should see the content you added to the RoutingListNote HTML customization. - Switch to your updated translation and confirm that the content you added for your translation shows up correctly. - Go to Administration -> System preferences and search for "RoutingListNote." It should return no results. NOTE: This patch does not keep the default content which was stored by the RoutingListNote system preference. Having a default value for that kind of preference is not standard. Instead I have updated the description of the RoutingSerials preference to add a mention of the RoutingListNote HTML customization option. Signed-off-by: David Nind <david@davidnind.com> Created attachment 171030 [details] [review] Bug 35152: Convert RoutingListNote system preference to additional contents This patch moves the RoutingListNote system preference into HTML customizations, making it possible to have language- and library-specific content. To test you should have some content in the RoutingListNote system preference before applying the patch. Apply the patch and run the database update process. - In the staff client, go to Tools -> HTML customizations and verify that the content from RoutingListNote is now stored there. - The HTML customization entry form should offer RoutingListNote as a choice under "Display location." - Update and reinstall active translations (for instance fr-FR): - perl misc/translator/translate update fr-FR - perl misc/translator/translate install fr-FR - Enable the translation if necessary under Administration -> System preferences -> language. - Edit the RoutingListNote HTML customization and add unique content to the "fr-FR" tab. - Go to Serials and create a subscription if necessary. - From the subscription detail page, click "Create routing list" in the left-hand sidebar. - Add one or more recipients to the list and click "Save". - On the "Preview routing list" page click "Save and preview routing slip". - In the pop-up window with the routing list preview you should see the content you added to the RoutingListNote HTML customization. - Switch to your updated translation and confirm that the content you added for your translation shows up correctly. - Go to Administration -> System preferences and search for "RoutingListNote." It should return no results. NOTE: This patch does not keep the default content which was stored by the RoutingListNote system preference. Having a default value for that kind of preference is not standard. Instead I have updated the description of the RoutingSerials preference to add a mention of the RoutingListNote HTML customization option. Signed-off-by: David Nind <david@davidnind.com> If I have the default content it is still being carried over. I don't see a mechanism in the patch that would remove it. Created attachment 176460 [details] [review] Bug 35152: Convert RoutingListNote system preference to additional contents This patch moves the RoutingListNote system preference into HTML customizations, making it possible to have language- and library-specific content. To test you should have some content in the RoutingListNote system preference before applying the patch. Apply the patch and run the database update process. - In the staff client, go to Tools -> HTML customizations and verify that the content from RoutingListNote is now stored there. - The HTML customization entry form should offer RoutingListNote as a choice under "Display location." - Update and reinstall active translations (for instance fr-FR): - perl misc/translator/translate update fr-FR - perl misc/translator/translate install fr-FR - Enable the translation if necessary under Administration -> System preferences -> language. - Edit the RoutingListNote HTML customization and add unique content to the "fr-FR" tab. - Go to Serials and create a subscription if necessary. - From the subscription detail page, click "Create routing list" in the left-hand sidebar. - Add one or more recipients to the list and click "Save". - On the "Preview routing list" page click "Save and preview routing slip". - In the pop-up window with the routing list preview you should see the content you added to the RoutingListNote HTML customization. - Switch to your updated translation and confirm that the content you added for your translation shows up correctly. - Go to Administration -> System preferences and search for "RoutingListNote." It should return no results. NOTE: This patch does not keep the default content which was stored by the RoutingListNote system preference. Having a default value for that kind of preference is not standard. Instead I have updated the description of the RoutingSerials preference to add a mention of the RoutingListNote HTML customization option. Sponsored-by: Athens County Public Libraries Signed-off-by: David Nind <david@davidnind.com> (In reply to Lucas Gass (lukeg) from comment #13) > If I have the default content it is still being carried over. I don't see a > mechanism in the patch that would remove it. I think I didn't explain well... You're correct that the patch automatically copies over the contents of the RoutingListNote whether or not the preference contains the default value. When I say that the patch doesn't keep the default content I mean that in a new installation there will be no default content for the RoutingListNote additional contents entry. Created attachment 176644 [details] [review] Bug 35152: Convert RoutingListNote system preference to additional contents This patch moves the RoutingListNote system preference into HTML customizations, making it possible to have language- and library-specific content. To test you should have some content in the RoutingListNote system preference before applying the patch. Apply the patch and run the database update process. - In the staff client, go to Tools -> HTML customizations and verify that the content from RoutingListNote is now stored there. - The HTML customization entry form should offer RoutingListNote as a choice under "Display location." - Update and reinstall active translations (for instance fr-FR): - perl misc/translator/translate update fr-FR - perl misc/translator/translate install fr-FR - Enable the translation if necessary under Administration -> System preferences -> language. - Edit the RoutingListNote HTML customization and add unique content to the "fr-FR" tab. - Go to Serials and create a subscription if necessary. - From the subscription detail page, click "Create routing list" in the left-hand sidebar. - Add one or more recipients to the list and click "Save". - On the "Preview routing list" page click "Save and preview routing slip". - In the pop-up window with the routing list preview you should see the content you added to the RoutingListNote HTML customization. - Switch to your updated translation and confirm that the content you added for your translation shows up correctly. - Go to Administration -> System preferences and search for "RoutingListNote." It should return no results. NOTE: This patch does not keep the default content which was stored by the RoutingListNote system preference. Having a default value for that kind of preference is not standard. Instead I have updated the description of the RoutingSerials preference to add a mention of the RoutingListNote HTML customization option. Sponsored-by: Athens County Public Libraries Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Created attachment 176645 [details] [review] Bug 35152: Display 'syspref removed' success only if removed Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Pushed for 25.05! Well done everyone, thank you! |