[Bug 14366] New: Units doesn't get saved usefully for patroncards
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 Bug ID: 14366 Summary: Units doesn't get saved usefully for patroncards Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: minor Priority: P5 - low Component: Label/patron card printing Assignee: cnighswonger@foundations.edu Reporter: dcook@prosentient.com.au QA Contact: testopia@bugs.koha-community.org "Units" gets saved into "layout_xml" for patroncards, but not into "units" in the `creator_layouts` table, so when you edit a layout for the patroncards, it'll always say "PostScript Points". It looks like the code could use a good clean-up... but I have a small fix which sets it right so not going to refactor unnecessarily... -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff Patch complexity|--- |Small patch -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 --- Comment #1 from David Cook <dcook@prosentient.com.au> --- Created attachment 40010 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=40010&action=edit Bug 14366 - Units doesn't get saved usefully for patroncards This patch causes the "Units" to be saved and displayed correctly for the "Edit layout" screen in Patroncards. _TEST PLAN_ Before applying: 0) Create a new layout 1) Edit the layout, change the units, and click Save 2) Edit the layout again, and notice the units are still "PostScript Points" Apply the patch: 3) Edit the layout again, change the units, and click Save 4) Edit the layout again, note that the units have changed to your selection 5) Rejoice -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 --- Comment #2 from David Cook <dcook@prosentient.com.au> --- Of course... I'm not sure that the actual label creator is using the different units... that's fun... -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 --- Comment #3 from Chris Nighswonger <cnighswonger@foundations.edu> --- (In reply to David Cook from comment #2)
Of course... I'm not sure that the actual label creator is using the different units... that's fun...
User selected units are converted to postscript points before rendering. Postscript points are the common denominator. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |derrynj@gmail.com --- Comment #4 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- *** Bug 8602 has been marked as a duplicate of this bug. *** -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 Nick Clemens <nick@quecheelibrary.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 --- Comment #5 from Nick Clemens <nick@quecheelibrary.org> --- Created attachment 40085 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=40085&action=edit [SIGNED OFF] Bug 14366 - Units doesn't get saved usefully for patroncards This patch causes the "Units" to be saved and displayed correctly for the "Edit layout" screen in Patroncards. _TEST PLAN_ Before applying: 0) Create a new layout 1) Edit the layout, change the units, and click Save 2) Edit the layout again, and notice the units are still "PostScript Points" Apply the patch: 3) Edit the layout again, change the units, and click Save 4) Edit the layout again, note that the units have changed to your selection 5) Rejoice Signed-off-by: Nick Clemens <nick@quecheelibrary.org> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 --- Comment #6 from David Cook <dcook@prosentient.com.au> --- (In reply to Chris Nighswonger from comment #3)
(In reply to David Cook from comment #2)
Of course... I'm not sure that the actual label creator is using the different units... that's fun...
User selected units are converted to postscript points before rendering. Postscript points are the common denominator.
Are you certain? I tried changing a label by 1cm but it looks like it only changed by 1pt. I haven't had time to look into this yet, unfortunately :/. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 --- Comment #7 from Chris Nighswonger <cnighswonger@foundations.edu> --- (In reply to David Cook from comment #6)
(In reply to Chris Nighswonger from comment #3)
(In reply to David Cook from comment #2)
Of course... I'm not sure that the actual label creator is using the different units... that's fun...
User selected units are converted to postscript points before rendering. Postscript points are the common denominator.
Are you certain? I tried changing a label by 1cm but it looks like it only changed by 1pt.
I haven't had time to look into this yet, unfortunately :/.
Point conversions are done here: http://tinyurl.com/o99ve52 This bug is addressing the fact that labels do not save the user's preferred UOM, which explains the phenomena you are describing. The real fix is for the labels code to be refactored to save templates as xml as patroncard code does. That was my long-term intention when I wrote the patroncard feature. Of course, even the best of intentions never materialize at times. :-P -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 --- Comment #8 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 40168 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=40168&action=edit Bug 14366 - Units doesn't get saved usefully for patroncards This patch causes the "Units" to be saved and displayed correctly for the "Edit layout" screen in Patroncards. _TEST PLAN_ Before applying: 0) Create a new layout 1) Edit the layout, change the units, and click Save 2) Edit the layout again, and notice the units are still "PostScript Points" Apply the patch: 3) Edit the layout again, change the units, and click Save 4) Edit the layout again, note that the units have changed to your selection 5) Rejoice Signed-off-by: Nick Clemens <nick@quecheelibrary.org> Signed-off-by: Jonathan Druart <jonathan.druart@koha-community.org> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jonathan.druart@biblibre.co | |m Attachment #40085|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #40010|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to Master CC| |tomascohen@gmail.com --- Comment #9 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Patch pushed to master. Thanks David! -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |chris@bigballofwax.co.nz Status|Pushed to Master |Pushed to Stable --- Comment #10 from Chris Cormack <chris@bigballofwax.co.nz> --- Pushed to 3.20.x will be in 3.20.2 -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14366 Mason James <mtj@kohaaloha.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |mtj@kohaaloha.com --- Comment #11 from Mason James <mtj@kohaaloha.com> --- Pushed to 3.16.x, will be in 3.16.13 -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org