It would nice if libraries could edit the 'Order number must appear on all related correspondence, shipping papers and invoices. Notify us immediately if you are unable to supply item(s).' line in the English 1-page order PDF to wording relevant to their library.
Created attachment 149076 [details] [review] Bug 33393: Add system preference Sponsored-by: Pymble Ladies' College
Created attachment 149077 [details] [review] Bug 33393: Enable libraries to configure their own text in the 1-Page order PDF Test plan: 1) Apply patches and restart services 2) Upgrade Koha schema: sudo koha-upgrade-schema <instance> 3) Go to Koha Administration -> Libraries. Ensure Library A has an address, phone and fax. 4) Go to Koha Administration -> System preferences. Search for OrderPdfFormat. Set this to English 1-page layout option. 5) Go to Acquisitions. Use an existing vendor or create a new one. Ensure the vendor has a postal address, phone, fax and accout number. 6) Create a basket for this vendor. Add many orders to this basket, for example 25 items (this is to make the Order PDF cover multiple pages). 7) Close the basket and add it to a basket group of the same name. 8) Edit the basket group. Add an address in the delivery place, and a delivery comment. Check the box to close the basket group and Save. 9) Click the button to Export as PDF. 10) View the exported PDF. Confirm the PDF is multiple pages long. If it is not then re-open the basketgroup and add more orders to the basket and repeat steps 7, 8, and 9 11) If the PDF is multiple pages long then confirm: - The text "Order number must appear on all related correspondence, shipping papers and invoices. Notify us immediately if you are unable to supply item(s)." appears above the order table. - The page numbers at the bottom of the first page are not obscured by the order table. - That the order table starts near the top of the second page, and not half way down. 12) Change content in the '1PageOrderPDFText' syspref (use the Enter key to split text over multiple lines) and save 13) Back in the Acquisitions module click the button to Export as PDF 14) View the exported PDF. Confirm the following: - Text text above the order table has changed. - The page numbers at the bottom of the first page are not obscrued by the order table. - That the order table starts near the top of the second page and not halfway down. Sponsored-by: Pymble Ladies' College
Created attachment 149078 [details] [review] Bug 33393: Enable libraries to configure their own text in the 1-Page order PDF Test plan: 1) Apply patches and restart services 2) Upgrade Koha schema: sudo koha-upgrade-schema <instance> 3) Go to Koha Administration -> Libraries. Ensure Library A has an address, phone and fax. 4) Go to Koha Administration -> System preferences. Search for OrderPdfFormat. Set this to English 1-page layout option. 5) Go to Acquisitions. Use an existing vendor or create a new one. Ensure the vendor has a postal address, phone, fax and accout number. 6) Create a basket for this vendor. Add many orders to this basket, for example 25 items (this is to make the Order PDF cover multiple pages). 7) Close the basket and add it to a basket group of the same name. 8) Edit the basket group. Add an address in the delivery place, and a delivery comment. Check the box to close the basket group and Save. 9) Click the button to Export as PDF. 10) View the exported PDF. Confirm the PDF is multiple pages long. If it is not then re-open the basketgroup and add more orders to the basket and repeat steps 7, 8, and 9 11) If the PDF is multiple pages long then confirm: - The text "Order number must appear on all related correspondence, shipping papers and invoices. Notify us immediately if you are unable to supply item(s)." appears above the order table. - The page numbers at the bottom of the first page are not obscured by the order table. - That the order table starts near the top of the second page, and not half way down. 12) Change content in the '1PageOrderPDFText' syspref (use the Enter key to split text over multiple lines) and save 13) Back in the Acquisitions module click the button to Export as PDF 14) View the exported PDF. Confirm the following: - The text above the order table is what you saved in the 1PageOrderPDFText system preference - The page numbers at the bottom of the first page are not obscrued by the order table. - That the order table starts near the top of the second page and not halfway down. 15) Empty the 1PageOrderPDFText system preference and save 16) Back in the Acquisitions module click te button to Export as PDF 17) View the exported PDF and confirm the line of text between the Tel/Fax line and the order table has been removed. Sponsored-by: Pymble Ladies' College
Created attachment 149079 [details] Custom text (highlighted yellow) that can be set in the 1PageOrderPDFText syspref with bug 33393 applied
Created attachment 149106 [details] [review] Bug 33393: Enable libraries to configure their own text in the 1-Page order PDF Test plan: 1) Apply patches and restart services 2) Upgrade Koha schema: sudo koha-upgrade-schema <instance> 3) Go to Koha Administration -> Libraries. Ensure Library A has an address, phone and fax. 4) Go to Koha Administration -> System preferences. Search for OrderPdfFormat. Set this to English 1-page layout option. 5) Go to Acquisitions. Use an existing vendor or create a new one. Ensure the vendor has a postal address, phone, fax and accout number. 6) Create a basket for this vendor. Add many orders to this basket, for example 25 items (this is to make the Order PDF cover multiple pages). 7) Close the basket and add it to a basket group of the same name. 8) Edit the basket group. Add an address in the delivery place, and a delivery comment. Check the box to close the basket group and Save. 9) Click the button to Export as PDF. 10) View the exported PDF. Confirm the PDF is multiple pages long. If it is not then re-open the basketgroup and add more orders to the basket and repeat steps 7, 8, and 9 11) If the PDF is multiple pages long then confirm: - The text "Order number must appear on all related correspondence, shipping papers and invoices. Notify us immediately if you are unable to supply item(s)." appears above the order table. - The page numbers at the bottom of the first page are not obscured by the order table. - That the order table starts near the top of the second page, and not half way down. 12) Change content in the '1PageOrderPDFText' syspref (use the Enter key to split text over multiple lines) and save 13) Back in the Acquisitions module click the button to Export as PDF 14) View the exported PDF. Confirm the following: - The text above the order table is what you saved in the 1PageOrderPDFText system preference - The page numbers at the bottom of the first page are not obscrued by the order table. - That the order table starts near the top of the second page and not halfway down. 15) Empty the 1PageOrderPDFText system preference and save 16) Back in the Acquisitions module click te button to Export as PDF 17) View the exported PDF and confirm the line of text between the Tel/Fax line and the order table has been removed. Sponsored-by: Pymble Ladies' College Signed-off-by: David Nind <david@davidnind.com>
Hi Alex. This works well. My only comment would be to add a hint or note to the 1PageOrderPDFText system preference about the length of the text. I added multiple long paragraphs and the text was cut off where the order table starts, and does not display the delivery comment. David
(In reply to David Nind from comment #6) > Hi Alex. > > This works well. > > My only comment would be to add a hint or note to the 1PageOrderPDFText > system preference about the length of the text. > > I added multiple long paragraphs and the text was cut off where the order > table starts, and does not display the delivery comment. > > David Hi David, That is a great idea. Thanks for that. I will add a follow-up patch with that addition. Alex
Created attachment 150497 [details] [review] Bug 33393: Add note to system preference explaining text length Sponsored-by: Pymble Ladies' College
Hi David, I have attached a patchset adding a note to the system preference description noting to keep the text length to 3 lines. Is that what you had in mind? Thanks, Alex
Created attachment 150524 [details] [review] Bug 33393: Add system preference Sponsored-by: Pymble Ladies' College Signed-off-by: David Nind <david@davidnind.com>
Created attachment 150525 [details] [review] Bug 33393: Enable libraries to configure their own text in the 1-Page order PDF Test plan: 1) Apply patches and restart services 2) Upgrade Koha schema: sudo koha-upgrade-schema <instance> 3) Go to Koha Administration -> Libraries. Ensure Library A has an address, phone and fax. 4) Go to Koha Administration -> System preferences. Search for OrderPdfFormat. Set this to English 1-page layout option. 5) Go to Acquisitions. Use an existing vendor or create a new one. Ensure the vendor has a postal address, phone, fax and accout number. 6) Create a basket for this vendor. Add many orders to this basket, for example 25 items (this is to make the Order PDF cover multiple pages). 7) Close the basket and add it to a basket group of the same name. 8) Edit the basket group. Add an address in the delivery place, and a delivery comment. Check the box to close the basket group and Save. 9) Click the button to Export as PDF. 10) View the exported PDF. Confirm the PDF is multiple pages long. If it is not then re-open the basketgroup and add more orders to the basket and repeat steps 7, 8, and 9 11) If the PDF is multiple pages long then confirm: - The text "Order number must appear on all related correspondence, shipping papers and invoices. Notify us immediately if you are unable to supply item(s)." appears above the order table. - The page numbers at the bottom of the first page are not obscured by the order table. - That the order table starts near the top of the second page, and not half way down. 12) Change content in the '1PageOrderPDFText' syspref (use the Enter key to split text over multiple lines) and save 13) Back in the Acquisitions module click the button to Export as PDF 14) View the exported PDF. Confirm the following: - The text above the order table is what you saved in the 1PageOrderPDFText system preference - The page numbers at the bottom of the first page are not obscrued by the order table. - That the order table starts near the top of the second page and not halfway down. 15) Empty the 1PageOrderPDFText system preference and save 16) Back in the Acquisitions module click te button to Export as PDF 17) View the exported PDF and confirm the line of text between the Tel/Fax line and the order table has been removed. Sponsored-by: Pymble Ladies' College Signed-off-by: David Nind <david@davidnind.com>
Created attachment 150526 [details] [review] Bug 33393: Add note to system preference explaining text length Sponsored-by: Pymble Ladies' College Signed-off-by: David Nind <david@davidnind.com>
(In reply to Alex Buckley from comment #9) > Hi David, > > I have attached a patchset adding a note to the system preference > description noting to keep the text length to 3 lines. > > Is that what you had in mind? > > Thanks, > Alex That looks fine to me. Thanks Alex!
(In reply to David Nind from comment #13) > (In reply to Alex Buckley from comment #9) > > Hi David, > > > > I have attached a patchset adding a note to the system preference > > description noting to keep the text length to 3 lines. > > > > Is that what you had in mind? > > > > Thanks, > > Alex > > That looks fine to me. Thanks Alex! Thanks so much David!
+ my $ordersentences = C4::Context->preference("1PageOrderPDFText"); Sorry, Alex. But we should not add text blocks into preferences. We now have HTML blocks etc. to do this better and allow for translation. Failed QA
(In reply to Marcel de Rooy from comment #15) > + my $ordersentences = C4::Context->preference("1PageOrderPDFText"); > > Sorry, Alex. But we should not add text blocks into preferences. We now have > HTML blocks etc. to do this better and allow for translation. > > Failed QA To be fair: the PDF files are one language only, they aren't tanslatable and you only use one at a time per global preference. And the WYSIWG editor could create issues with the PDF.
(In reply to Katrin Fischer from comment #16) > (In reply to Marcel de Rooy from comment #15) > > + my $ordersentences = C4::Context->preference("1PageOrderPDFText"); > > > > Sorry, Alex. But we should not add text blocks into preferences. We now have > > HTML blocks etc. to do this better and allow for translation. > > > > Failed QA > > To be fair: the PDF files are one language only, they aren't tanslatable and > you only use one at a time per global preference. And the WYSIWG editor > could create issues with the PDF. Well, you can solve it in several ways. Small template file? But we should not add a preference imo.
(In reply to Marcel de Rooy from comment #17) > (In reply to Katrin Fischer from comment #16) > > (In reply to Marcel de Rooy from comment #15) > > > + my $ordersentences = C4::Context->preference("1PageOrderPDFText"); > > > > > > Sorry, Alex. But we should not add text blocks into preferences. We now have > > > HTML blocks etc. to do this better and allow for translation. > > > > > > Failed QA > > > > To be fair: the PDF files are one language only, they aren't tanslatable and > > you only use one at a time per global preference. And the WYSIWG editor > > could create issues with the PDF. > > Well, you can solve it in several ways. Small template file? But we should > not add a preference imo. A server side file won't really work for the use case. I am not a fan of "enhancing" the PDF templates - I think it's a dead end. But I don't see as we haven't formally deprecated them, how it can block this and a preference makes the most sense. You can't use TT or anything there, it's all very custom as the text and contents are placed by the .pm in an .odt template.
Well, let me step aside for this QA turn :)
Alex, maybe we (I...) should let you argue this one.
(In reply to Katrin Fischer from comment #20) > Alex, maybe we (I...) should let you argue this one. Moving this to In discussion. And inviting Alex to reply on earlier comments.
Hi Marcel and Katrin, Thanks both for your comments. I have thought on both of them. I agree that I am not a fan of enhancing the PDF files, especially since it is possible for the user to add a message much too long for the PDF file, and get the problem that David noted in comment #6 However, if a library wants to change the wording of the pdf, as is the use case her, I don't see what other options there are. I agree with Katrin that trying to use the HTML customisations WYSIWG editor could create problems with the pdf - for example if users try to add tables, images, fonts. I suppose one possible workaround could be to shift this to being a notice and so it could be edited from the notices and slips interface. What are your thoughts on that? Then no WYSIWG editor is involved. Alex
My current thought would be: I do not oppose this as a workaround with commitment to follow up and improve.
(In reply to Marcel de Rooy from comment #23) > My current thought would be: I do not oppose this as a workaround with > commitment to follow up and improve. Hi Marcel, what would you ask for as follow-up/improvements here in order to pass?
(In reply to Katrin Fischer from comment #24) > (In reply to Marcel de Rooy from comment #23) > > My current thought would be: I do not oppose this as a workaround with > > commitment to follow up and improve. > > Hi Marcel, what would you ask for as follow-up/improvements here in order to > pass? Hi Katrin and Marcel, Thanks for your replies. Yes, Marcel if you wouldn't mind noting what you would want as follow-ups/improvements here that would be helpful so we can raise them with our sponsoring library. Thanks so much, Alex
(In reply to Katrin Fischer from comment #24) > (In reply to Marcel de Rooy from comment #23) > > My current thought would be: I do not oppose this as a workaround with > > commitment to follow up and improve. > > Hi Marcel, what would you ask for as follow-up/improvements here in order to > pass? Actually nothing here. See comment23.
Back to Signed Off
(In reply to Alex Buckley from comment #25) > Yes, Marcel if you wouldn't mind noting what you would want as > follow-ups/improvements here that would be helpful so we can raise them with > our sponsoring library. Please reconstruct from earlier discussion. Not having this sharp right now.
(In reply to Marcel de Rooy from comment #28) > (In reply to Alex Buckley from comment #25) > > Yes, Marcel if you wouldn't mind noting what you would want as > > follow-ups/improvements here that would be helpful so we can raise them with > > our sponsoring library. > > Please reconstruct from earlier discussion. Not having this sharp right now. Thanks will reconstruct.
Created attachment 163214 [details] [review] Bug 33393: Add system preference Sponsored-by: Pymble Ladies' College Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Created attachment 163215 [details] [review] Bug 33393: Enable libraries to configure their own text in the 1-Page order PDF Test plan: 1) Apply patches and restart services 2) Upgrade Koha schema: sudo koha-upgrade-schema <instance> 3) Go to Koha Administration -> Libraries. Ensure Library A has an address, phone and fax. 4) Go to Koha Administration -> System preferences. Search for OrderPdfFormat. Set this to English 1-page layout option. 5) Go to Acquisitions. Use an existing vendor or create a new one. Ensure the vendor has a postal address, phone, fax and accout number. 6) Create a basket for this vendor. Add many orders to this basket, for example 25 items (this is to make the Order PDF cover multiple pages). 7) Close the basket and add it to a basket group of the same name. 8) Edit the basket group. Add an address in the delivery place, and a delivery comment. Check the box to close the basket group and Save. 9) Click the button to Export as PDF. 10) View the exported PDF. Confirm the PDF is multiple pages long. If it is not then re-open the basketgroup and add more orders to the basket and repeat steps 7, 8, and 9 11) If the PDF is multiple pages long then confirm: - The text "Order number must appear on all related correspondence, shipping papers and invoices. Notify us immediately if you are unable to supply item(s)." appears above the order table. - The page numbers at the bottom of the first page are not obscured by the order table. - That the order table starts near the top of the second page, and not half way down. 12) Change content in the '1PageOrderPDFText' syspref (use the Enter key to split text over multiple lines) and save 13) Back in the Acquisitions module click the button to Export as PDF 14) View the exported PDF. Confirm the following: - The text above the order table is what you saved in the 1PageOrderPDFText system preference - The page numbers at the bottom of the first page are not obscrued by the order table. - That the order table starts near the top of the second page and not halfway down. 15) Empty the 1PageOrderPDFText system preference and save 16) Back in the Acquisitions module click te button to Export as PDF 17) View the exported PDF and confirm the line of text between the Tel/Fax line and the order table has been removed. Sponsored-by: Pymble Ladies' College Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Created attachment 163216 [details] [review] Bug 33393: Add note to system preference explaining text length Sponsored-by: Pymble Ladies' College Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Created attachment 163217 [details] [review] Bug 33393: tidy layout1page.pm Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
While I tend to agree PDF generation isn't the greatest, this is a minor enhancement and it was far too onerous to ask to replace an entire subsystem to add such a small enhancement. Let's get this in!
(In reply to Kyle M Hall from comment #34) > While I tend to agree PDF generation isn't the greatest, this is a minor > enhancement and it was far too onerous to ask to replace an entire subsystem > to add such a small enhancement. Let's get this in! Thank you very much Kyle.
I am going to push this as is with a tiny follow up to explain that this only works for English 1-page. I think it would have been great to adapt all the available notices as this won't be usable for libraries relying on the German or French translations. Maybe I can persuade you to do a follow-up?
I think we should also not set a text on update - this would be a surprising change. Updated the database update accordingly.
Pushed for 24.05! Well done everyone, thank you!
(In reply to Katrin Fischer from comment #36) > I am going to push this as is with a tiny follow up to explain that this > only works for English 1-page. I think it would have been great to adapt all > the available notices as this won't be usable for libraries relying on the > German or French translations. Maybe I can persuade you to do a follow-up? Hi Katrin, Sorry for my delayed reply, I have been on leave. Firstly, thank you for pushing this enhancement. I have contacted our partner library who sponsored this enhancement to see if they would like to sponsor your suggested follow-up. I'll be in touch if they would like to proceed. Thanks, Alex
Not backported to 23.11.x