[Bug 35646] New: Allow using the publication date parts for serial numbering
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Bug ID: 35646 Summary: Allow using the publication date parts for serial numbering Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Serials Assignee: koha-bugs@lists.koha-community.org Reporter: nick@bywatersolutions.com QA Contact: testopia@bugs.koha-community.org Sometimes libraries want date fields based on publication date included in the numbering, say for a weekly serial -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 --- Comment #1 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 160275 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=160275&action=edit Bgg 35646: Allow use of publication date fields in serial numbering pattern This patch extends the numbering pattern field to accept subsitituations for: {Year} {Day} {DayName} {Month} {MonthName} These fields are based on the publication date for the serial issue. To test: 0 - Apply patch 1 - Setup a enw numbering pattern Serials->Manage numbering patterns + New numbering pattern 2 - In the numbering formula enter: {X} {Y} {Z} {Year} {Month} {Day} {MonthName} {DayName} 3 - Populate X/Y/Z in the table as you wish, these should be unaffected by patch 4 - Set a Frequency / First issue plublication date / Subscription length 5 - Click 'Test pattern' 6 - Confirm the dates in the Number match the publication date values 7 - Try with different frequencies to confirm they match 8 - Save the pattern 9 - Create a new subscription and use the new pattern 10 - Confirm it works as expected -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |nick@bywatersolutions.com |ity.org | See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=22188 -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #160275|0 |1 is obsolete| | --- Comment #2 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 160276 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=160276&action=edit Bug 35646: Allow use of publication date fields in serial numbering pattern This patch extends the numbering pattern field to accept subsitituations for: {Year} {Day} {DayName} {Month} {MonthName} These fields are based on the publication date for the serial issue. To test: 0 - Apply patch 1 - Setup a enw numbering pattern Serials->Manage numbering patterns + New numbering pattern 2 - In the numbering formula enter: {X} {Y} {Z} {Year} {Month} {Day} {MonthName} {DayName} 3 - Populate X/Y/Z in the table as you wish, these should be unaffected by patch 4 - Set a Frequency / First issue plublication date / Subscription length 5 - Click 'Test pattern' 6 - Confirm the dates in the Number match the publication date values 7 - Try with different frequencies to confirm they match 8 - Save the pattern 9 - Create a new subscription and use the new pattern 10 - Confirm it works as expected -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 --- Comment #3 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 160277 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=160277&action=edit Bug 35646: Unit tests -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |katrin.fischer@bsz-bw.de -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Lucas Gass <lucas@bywatersolutions.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=35646 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #160276|0 |1 is obsolete| | --- Comment #4 from Lucas Gass <lucas@bywatersolutions.com> --- Created attachment 160297 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=160297&action=edit Bug 35646: Allow use of publication date fields in serial numbering pattern This patch extends the numbering pattern field to accept subsitituations for: {Year} {Day} {DayName} {Month} {MonthName} These fields are based on the publication date for the serial issue. To test: 0 - Apply patch 1 - Setup a enw numbering pattern Serials->Manage numbering patterns + New numbering pattern 2 - In the numbering formula enter: {X} {Y} {Z} {Year} {Month} {Day} {MonthName} {DayName} 3 - Populate X/Y/Z in the table as you wish, these should be unaffected by patch 4 - Set a Frequency / First issue plublication date / Subscription length 5 - Click 'Test pattern' 6 - Confirm the dates in the Number match the publication date values 7 - Try with different frequencies to confirm they match 8 - Save the pattern 9 - Create a new subscription and use the new pattern 10 - Confirm it works as expected Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #160277|0 |1 is obsolete| | --- Comment #5 from Lucas Gass <lucas@bywatersolutions.com> --- Created attachment 160298 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=160298&action=edit Bug 35646: Unit tests Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 lthorrat@cuyahogalibrary.org <lthorrat@cuyahogalibrary.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |lthorrat@cuyahogalibrary.or | |g -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Dani Elder <danielle.elder@law.utexas.edu> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |danielle.elder@law.utexas.e | |du -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=33039 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |m.de.rooy@rijksmuseum.nl QA Contact|testopia@bugs.koha-communit |m.de.rooy@rijksmuseum.nl |y.org | --- Comment #6 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- subsitituations ? Are these events related to using substitutions? Like when I was in a subsitituation the other day ;) + my $dt = dt_from_string( $subscription->{firstaquidate} ); Could be me, but looks like a typo. + firstaquidate => '1970-11-01', -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #160297|0 |1 is obsolete| | Attachment #160298|0 |1 is obsolete| | --- Comment #7 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 165088 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=165088&action=edit Bug 35646: Allow use of publication date fields in serial numbering pattern This patch extends the numbering pattern field to accept subsititutions for: {Year} {Day} {DayName} {Month} {MonthName} These fields are based on the publication date for the serial issue. To test: 0 - Apply patch 1 - Setup a enw numbering pattern Serials->Manage numbering patterns + New numbering pattern 2 - In the numbering formula enter: {X} {Y} {Z} {Year} {Month} {Day} {MonthName} {DayName} 3 - Populate X/Y/Z in the table as you wish, these should be unaffected by patch 4 - Set a Frequency / First issue plublication date / Subscription length 5 - Click 'Test pattern' 6 - Confirm the dates in the Number match the publication date values 7 - Try with different frequencies to confirm they match 8 - Save the pattern 9 - Create a new subscription and use the new pattern 10 - Confirm it works as expected Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 --- Comment #8 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 165089 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=165089&action=edit Bug 35646: Unit tests Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 --- Comment #9 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 165090 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=165090&action=edit Bug 35646: (follow-up) Correct firstaquidate type -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA Patch complexity|--- |Small patch -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #165088|0 |1 is obsolete| | --- Comment #10 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 165093 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=165093&action=edit Bug 35646: Allow use of publication date fields in serial numbering pattern This patch extends the numbering pattern field to accept subsititutions for: {Year} {Day} {DayName} {Month} {MonthName} These fields are based on the publication date for the serial issue. To test: 0 - Apply patch 1 - Setup a enw numbering pattern Serials->Manage numbering patterns + New numbering pattern 2 - In the numbering formula enter: {X} {Y} {Z} {Year} {Month} {Day} {MonthName} {DayName} 3 - Populate X/Y/Z in the table as you wish, these should be unaffected by patch 4 - Set a Frequency / First issue plublication date / Subscription length 5 - Click 'Test pattern' 6 - Confirm the dates in the Number match the publication date values 7 - Try with different frequencies to confirm they match 8 - Save the pattern 9 - Create a new subscription and use the new pattern 10 - Confirm it works as expected Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #165089|0 |1 is obsolete| | --- Comment #11 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 165094 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=165094&action=edit Bug 35646: Unit tests Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #165090|0 |1 is obsolete| | --- Comment #12 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 165095 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=165095&action=edit Bug 35646: (follow-up) Correct firstaquidate type Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |additional_work_needed, | |release-notes-needed --- Comment #13 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- I do like {Year} {Month} {Day}. I struggle with: {MonthName} {DayName} These don't seem to take the Locale set into account - so maybe English only or will use the interface language? Ideally it should follow the locale setting. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)| |24.05.00 released in| | Status|Passed QA |Pushed to main -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 --- Comment #14 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=35646 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |fridolin.somers@biblibre.co | |m --- Comment #15 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=35646 --- Comment #16 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- (In reply to Katrin Fischer from comment #13)
I do like {Year} {Month} {Day}.
I struggle with: {MonthName} {DayName} These don't seem to take the Locale set into account - so maybe English only or will use the interface language? Ideally it should follow the locale setting.
NICK! *tries to get attention* -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Text to go in the| |This adds some new release notes| |placeholders to be used | |within the numbering | |pattern of a subscription: | |{Year}, {Day}, {DayName}, | |{Month}, {MonthName}. They | |will be automatically | |replaced with the | |corresponding value derived | |from the publication date | |of the issue when its | |received. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords|release-notes-needed | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 --- Comment #17 from Nick Clemens (kidclamp) <nick@bywatersolutions.com> --- (In reply to Katrin Fischer from comment #16)
(In reply to Katrin Fischer from comment #13)
I do like {Year} {Month} {Day}.
I struggle with: {MonthName} {DayName} These don't seem to take the Locale set into account - so maybe English only or will use the interface language? Ideally it should follow the locale setting.
NICK! *tries to get attention*
I think it doesn't work because we don't set Locale for the DateTime objects we create in Koha::DateUtils: https://metacpan.org/pod/DateTime#Locales We could easily pass through the 'locale' from the Serial (subscription table) however, I spot tested and got an error for 'Ethiopic'/'gez' though it is listed here: https://metacpan.org/pod/DateTime::Locale::Catalog Our list comes from here: https://www.loc.gov/standards/iso639-2/php/code_list.php Maybe our datetime modules need an update? Here is a full list of ones that throw an error: Invalid locale code or name: akk Invalid locale code or name: tut Invalid locale code or name: grc Invalid locale code or name: ave Invalid locale code or name: bnt Invalid locale code or name: bra Invalid locale code or name: cel Invalid locale code or name: chp Invalid locale code or name: cho Invalid locale code or name: chu Invalid locale code or name: syc Invalid locale code or name: cop Invalid locale code or name: cre Invalid locale code or name: prs Invalid locale code or name: dgr Invalid locale code or name: egy Invalid locale code or name: gez Invalid locale code or name: gem Invalid locale code or name: got Invalid locale code or name: gwi Invalid locale code or name: her Invalid locale code or name: hit Invalid locale code or name: inc Invalid locale code or name: iku Invalid locale code or name: ipk Invalid locale code or name: ira Invalid locale code or name: jrb Invalid locale code or name: csb Invalid locale code or name: lad Invalid locale code or name: lat Invalid locale code or name: myn Invalid locale code or name: dum Invalid locale code or name: enm Invalid locale code or name: frm Invalid locale code or name: gmh Invalid locale code or name: mga Invalid locale code or name: mul Invalid locale code or name: nah Invalid locale code or name: zxx Invalid locale code or name: nya Invalid locale code or name: arc Invalid locale code or name: ang Invalid locale code or name: fro Invalid locale code or name: goh Invalid locale code or name: peo Invalid locale code or name: pro Invalid locale code or name: ota Invalid locale code or name: pal Invalid locale code or name: pli Invalid locale code or name: pbr Invalid locale code or name: pra Invalid locale code or name: roa Invalid locale code or name: rom Invalid locale code or name: sam Invalid locale code or name: sem Invalid locale code or name: den Invalid locale code or name: sla Invalid locale code or name: wen Invalid locale code or name: sux Invalid locale code or name: syr Invalid locale code or name: tgl Invalid locale code or name: tet Invalid locale code or name: uga Invalid locale code or name: mis -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Nick Clemens (kidclamp) <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |37001 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37001 [Bug 37001] Locale ignored for serial numbering when using {MonthName} {DayName} substitutions -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 --- Comment #18 from Nick Clemens (kidclamp) <nick@bywatersolutions.com> --- Filed a new bug for this issue - can we remove addition_work from this one? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords|additional_work_needed | --- Comment #19 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- (In reply to Nick Clemens (kidclamp) from comment #18)
Filed a new bug for this issue - can we remove addition_work from this one?
Yep, I used it so we would not forget about this loose end. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Phil Ringnalda <phil@chetcolibrary.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to main |Needs documenting CC| |phil@chetcolibrary.org --- Comment #20 from Phil Ringnalda <phil@chetcolibrary.org> --- (In reply to Fridolin Somers from comment #15)
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=35646 Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs documenting |RESOLVED Resolution|--- |FIXED CC| |caroline.cyr-la-rose@inlibr | |o.com Documentation| |Caroline Cyr La Rose contact| | Documentation| |https://gitlab.com/koha-com submission| |munity/koha-manual/-/merge_ | |requests/995 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Michelle Spinney <mspinney@clamsnet.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |mspinney@clamsnet.org -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Esther Melander <esther.melander@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |esther.melander@bywatersolu | |tions.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35646 Nick Clemens (kidclamp) <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |41387 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41387 [Bug 41387] Add option for 2 digit month to serial patterns -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org