[Bug 11023] New: Toggle new status for items
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Bug ID: 11023 Summary: Toggle new status for items Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: new feature Priority: P5 - low Component: Cataloging Assignee: gmcharlt@gmail.com Reporter: jonathan.druart@biblibre.com QA Contact: testopia@bugs.koha-community.org CC: m.de.rooy@rijksmuseum.nl Some libraries would like to manage a "new" status for items. This status should be removed depending on some conditions. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Assignee|gmcharlt@gmail.com |jonathan.druart@biblibre.co | |m -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #1 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 21926 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=21926&action=edit Bug 11023: Toggle "new" status This patch adds: - a new DB field items.new. - a new page to configure this new status (tools/toggle_new_status.pl). - a new cronjob script (misc/cronjob/toggle_new_status.pl). Why this status is useful for some libraries ? The use cases are: - to know easily what are the new items (with a simple sql query). - to display an icon in the search results. - issuing rules can be adapt for new items. Automatically (using the cronjob script), the status change (depending the configuration) and the item can be issued, for example. - a RSS/Atom feeds can be created on these new items. Test plan: - log in with a librarian having the tools > items_batchmod permission. - navigate to Home > Tools > Toggle new status - click on the edit button - there are 3 "blocks": * duration: the duration during an item is considered as new. * conditions: the status will change only if the conditions are meet. * substitutions: if there is no substitution, no action will be done. You can add some change to apply to the matching items. E.g. ccode=3 new='' If the value is an empty string (in other words, the input does not contain anything), the field will be deleted. You can create as many rules as you want. - test the interface : add/remove rule, conditions, substitutions, submit the form, edit, etc. (There is a looot of JS everywhere, so certainly a looot of bugs...). - when you have your rules defined, you can now launch the cronjob script without any parameter. A report will be displayed with the matching itemnumber and the substitutions to apply. Verify results are consistent. - launch the script with the -c argument and verify values have been modified depending the substitution rules. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #21926|0 |1 is obsolete| | --- Comment #2 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 21932 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=21932&action=edit Bug 11023: Toggle "new" status -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #21932|0 |1 is obsolete| | --- Comment #3 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 21982 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=21982&action=edit Bug 11023: Toggle "new" status -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #21982|0 |1 is obsolete| | --- Comment #4 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 21983 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=21983&action=edit Bug 11023: Toggle "new" status -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #21983|0 |1 is obsolete| | --- Comment #5 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 22004 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=22004&action=edit Bug 11023: Toggle "new" status -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #22004|0 |1 is obsolete| | --- Comment #6 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 22386 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=22386&action=edit Bug 11023: Toggle "new" status This patch adds: - a new DB field items.new. - a new page to configure this new status (tools/toggle_new_status.pl). - a new cronjob script (misc/cronjob/toggle_new_status.pl). Why this status is useful for some libraries ? The use cases are: - to know easily what are the new items (with a simple sql query). - to display an icon in the search results. - issuing rules can be adapt for new items. Automatically (using the cronjob script), the status change (depending the configuration) and the item can be issued, for example. - a RSS/Atom feeds can be created on these new items. Test plan: - log in with a librarian having the tools > items_batchmod permission. - navigate to Home > Tools > Toggle new status - click on the edit button - there are 3 "blocks": * duration: the duration during an item is considered as new. * conditions: the status will change only if the conditions are meet. * substitutions: if there is no substitution, no action will be done. You can add some change to apply to the matching items. E.g. ccode=3 new='' If the value is an empty string (in other words, the input does not contain anything), the field will be deleted. You can create as many rules as you want. - test the interface : add/remove rule, conditions, substitutions, submit the form, edit, etc. (There is a looot of JS everywhere, so certainly a looot of bugs...). - when you have your rules defined, you can now launch the cronjob script without any parameter. A report will be displayed with the matching itemnumber and the substitutions to apply. Verify results are consistent. - launch the script with the -c argument and verify values have been modified depending the substitution rules. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #7 from Jonathan Druart <jonathan.druart@biblibre.com> --- There were been several iterations with Laurence. She found some bugs I fixed. This last patch is the final version. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #8 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 22734 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=22734&action=edit Bug 11023: Add the ability to specify fields from biblioitems table. Test plan: Same as before but try with fields from the biblioitems table. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #9 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 22735 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=22735&action=edit Bug 11023: Add UT for C4::Items::ToggleNewStatus Test plan: prove t/db_dependent/Items/ToggleNewStatus.t -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Nicole C. Engard <nengard@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |nengard@gmail.com -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #22386|0 |1 is obsolete| | Attachment #22734|0 |1 is obsolete| | Attachment #22735|0 |1 is obsolete| | --- Comment #10 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 24068 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=24068&action=edit Bug 11023: Toggle "new" status This patch adds: - a new DB field items.new. - a new page to configure this new status (tools/toggle_new_status.pl). - a new cronjob script (misc/cronjob/toggle_new_status.pl). Why this status is useful for some libraries ? The use cases are: - to know easily what are the new items (with a simple sql query). - to display an icon in the search results. - issuing rules can be adapt for new items. Automatically (using the cronjob script), the status change (depending the configuration) and the item can be issued, for example. - a RSS/Atom feeds can be created on these new items. Test plan: - log in with a librarian having the tools > items_batchmod permission. - navigate to Home > Tools > Toggle new status - click on the edit button - there are 3 "blocks": * duration: the duration during an item is considered as new. * conditions: the status will change only if the conditions are meet. * substitutions: if there is no substitution, no action will be done. You can add some change to apply to the matching items. E.g. ccode=3 new='' If the value is an empty string (in other words, the input does not contain anything), the field will be deleted. You can create as many rules as you want. - test the interface : add/remove rule, conditions, substitutions, submit the form, edit, etc. (There is a looot of JS everywhere, so certainly a looot of bugs...). - when you have your rules defined, you can now launch the cronjob script without any parameter. A report will be displayed with the matching itemnumber and the substitutions to apply. Verify results are consistent. - launch the script with the -c argument and verify values have been modified depending the substitution rules. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #11 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 24069 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=24069&action=edit Bug 11023: Add the ability to specify fields from biblioitems table. Test plan: Same as before but try with fields from the biblioitems table. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #12 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 24070 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=24070&action=edit Bug 11023: Add UT for C4::Items::ToggleNewStatus Test plan: prove t/db_dependent/Items/ToggleNewStatus.t -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #13 from Jonathan Druart <jonathan.druart@biblibre.com> --- rebased patches. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 sandboxes@biblibre.com <sandboxes@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off CC| |sandboxes@biblibre.com --- Comment #14 from sandboxes@biblibre.com <sandboxes@biblibre.com> --- Patch tested with a sandbox, by juliette et rémy <juliette.levast@iepg.fr> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 sandboxes@biblibre.com <sandboxes@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #24068|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=11023 sandboxes@biblibre.com <sandboxes@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #24069|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=11023 sandboxes@biblibre.com <sandboxes@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #24070|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=11023 --- Comment #15 from sandboxes@biblibre.com <sandboxes@biblibre.com> --- Created attachment 24146 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=24146&action=edit Bug 11023: Toggle "new" status This patch adds: - a new DB field items.new. - a new page to configure this new status (tools/toggle_new_status.pl). - a new cronjob script (misc/cronjob/toggle_new_status.pl). Why this status is useful for some libraries ? The use cases are: - to know easily what are the new items (with a simple sql query). - to display an icon in the search results. - issuing rules can be adapt for new items. Automatically (using the cronjob script), the status change (depending the configuration) and the item can be issued, for example. - a RSS/Atom feeds can be created on these new items. Test plan: - log in with a librarian having the tools > items_batchmod permission. - navigate to Home > Tools > Toggle new status - click on the edit button - there are 3 "blocks": * duration: the duration during an item is considered as new. * conditions: the status will change only if the conditions are meet. * substitutions: if there is no substitution, no action will be done. You can add some change to apply to the matching items. E.g. ccode=3 new='' If the value is an empty string (in other words, the input does not contain anything), the field will be deleted. You can create as many rules as you want. - test the interface : add/remove rule, conditions, substitutions, submit the form, edit, etc. (There is a looot of JS everywhere, so certainly a looot of bugs...). - when you have your rules defined, you can now launch the cronjob script without any parameter. A report will be displayed with the matching itemnumber and the substitutions to apply. Verify results are consistent. - launch the script with the -c argument and verify values have been modified depending the substitution rules. Signed-off-by: juliette et r -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #16 from sandboxes@biblibre.com <sandboxes@biblibre.com> --- Created attachment 24147 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=24147&action=edit Bug 11023: Add the ability to specify fields from biblioitems table. Test plan: Same as before but try with fields from the biblioitems table. Signed-off-by: juliette et r -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #17 from sandboxes@biblibre.com <sandboxes@biblibre.com> --- Created attachment 24148 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=24148&action=edit Bug 11023: Add UT for C4::Items::ToggleNewStatus Test plan: prove t/db_dependent/Items/ToggleNewStatus.t Signed-off-by: juliette et r -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA CC| |kyle@bywatersolutions.com --- Comment #18 from Kyle M Hall <kyle@bywatersolutions.com> --- Is there any reason this couldn't be done using dateaccessioned rather than adding a new field to items? I imagine the test for items being 'new' is less than simple in some cases, and I can see a definite advantage in pre-setting items as new rather than determining that on the fly for every item. QA Issue: biblioitems_columns doesn't seem like it belongs in Items.pm, you could easily use DBIx::Class to get the columns names: http://search.cpan.org/~frew/DBIx-Class-0.08121/lib/DBIx/Class/ResultSource.... so no need for a special subroutine! -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #19 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to Kyle M Hall from comment #18)
Is there any reason this couldn't be done using dateaccessioned rather than adding a new field to items? I imagine the test for items being 'new' is less than simple in some cases, and I can see a definite advantage in pre-setting items as new rather than determining that on the fly for every item.
I am not sure to understand: the goal of the cronjob script is to remove the 'new' flag. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #20 from Jonathan Druart <jonathan.druart@biblibre.com> --- And the script is based on the items.dateaccessioned field for the duration value. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #21 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 25767 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=25767&action=edit Bug 11023: FIX - condition on biblioitems table does not work If a rule contains a condition on the biblioitems table, the match won't work. This patch fixes this issue. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #22 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 25833 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=25833&action=edit Bug 11023: Use DBIx-Class to retrieve column names -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #23 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to Kyle M Hall from comment #18)
QA Issue: biblioitems_columns doesn't seem like it belongs in Items.pm, you could easily use DBIx::Class to get the columns names: http://search.cpan.org/~frew/DBIx-Class-0.08121/lib/DBIx/Class/ResultSource. pm#columns so no need for a special subroutine!
Done in the last patch. I kept the subroutines because I use the column names in 2 different places. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Olli-Antti Kivilahti <olli-antti.kivilahti@jns.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |olli-antti.kivilahti@jns.fi --- Comment #24 from Olli-Antti Kivilahti <olli-antti.kivilahti@jns.fi> --- Firstly two merge conflicts: (got it working tho) CONFLICT (content): Merge conflict in koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css CONFLICT (content): Merge conflict in installer/data/mysql/updatedatabase.pl Cronjob seems to work as intended and is a welcome addition. The purpose of the items.new-column is unclear. I didn't manage to get it populated, even if the comments here say that the cronjob's purpose is to empty the new-column. Apparently the new-column is a field, but then again it is a flag, and in the CREATE TABLE directive it is a VARCHAR(32). It is also the (status == new). It is extremely confusing. Apparently we can use it as we want, but then shouldn't it be labeled as such. My suggestion, replace the new-column definition with this: CREATE TABLE... `system_note` VARCHAR(32) DEFAULT NULL, -- You can put whatever free-text information regarding this item here. This field is meant for local modifications only and should not be used in features intended for master ... ; -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #24146|0 |1 is obsolete| | --- Comment #25 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 26817 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=26817&action=edit Bug 11023: Toggle "new" status This patch adds: - a new DB field items.new. - a new page to configure this new status (tools/toggle_new_status.pl). - a new cronjob script (misc/cronjob/toggle_new_status.pl). Why this status is useful for some libraries ? The use cases are: - to know easily what are the new items (with a simple sql query). - to display an icon in the search results. - issuing rules can be adapt for new items. Automatically (using the cronjob script), the status change (depending the configuration) and the item can be issued, for example. - a RSS/Atom feeds can be created on these new items. Test plan: - log in with a librarian having the tools > items_batchmod permission. - navigate to Home > Tools > Toggle new status - click on the edit button - there are 3 "blocks": * duration: the duration during an item is considered as new. * conditions: the status will change only if the conditions are meet. * substitutions: if there is no substitution, no action will be done. You can add some change to apply to the matching items. E.g. ccode=3 new='' If the value is an empty string (in other words, the input does not contain anything), the field will be deleted. You can create as many rules as you want. - test the interface : add/remove rule, conditions, substitutions, submit the form, edit, etc. (There is a looot of JS everywhere, so certainly a looot of bugs...). - when you have your rules defined, you can now launch the cronjob script without any parameter. A report will be displayed with the matching itemnumber and the substitutions to apply. Verify results are consistent. - launch the script with the -c argument and verify values have been modified depending the substitution rules. Signed-off-by: juliette et r -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #24147|0 |1 is obsolete| | --- Comment #26 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 26818 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=26818&action=edit Bug 11023: Add the ability to specify fields from biblioitems table. Test plan: Same as before but try with fields from the biblioitems table. Signed-off-by: juliette et r -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #24148|0 |1 is obsolete| | --- Comment #27 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 26819 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=26819&action=edit Bug 11023: Add UT for C4::Items::ToggleNewStatus Test plan: prove t/db_dependent/Items/ToggleNewStatus.t Signed-off-by: juliette et r -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #25767|0 |1 is obsolete| | --- Comment #28 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 26820 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=26820&action=edit Bug 11023: FIX - condition on biblioitems table does not work If a rule contains a condition on the biblioitems table, the match won't work. This patch fixes this issue. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #25833|0 |1 is obsolete| | --- Comment #29 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 26821 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=26821&action=edit Bug 11023: Use DBIx-Class to retrieve column names -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #30 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 26822 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=26822&action=edit Bug 11023: Update DB field description -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #31 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to Olli-Antti Kivilahti from comment #24) I disagree, this field is created to manage a "new" status, so I think "new" is a good name :) I provided a followup to change the description. Last patches have been rebased against master. Thank you for testing Olli! -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #32 from Olli-Antti Kivilahti <olli-antti.kivilahti@jns.fi> --- We can agree to that :) Good work! -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 paxed <pasi.kallinen@pttk.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |pasi.kallinen@pttk.fi --- Comment #33 from paxed <pasi.kallinen@pttk.fi> --- (In reply to Jonathan Druart from comment #30)
Created attachment 26822 [details] [review] Bug 11023: Update DB field description
Typo: "indented" should be "intended" -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #26822|0 |1 is obsolete| | --- Comment #34 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 26855 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=26855&action=edit Bug 11023: Update DB field description -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA CC| |katrin.fischer@bsz-bw.de --- Comment #35 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Starting with some initial testing and notes on this: 1) I am not sure the 2 specialiced subroutines for getting the columns from items and biblioitems are needed - couldn't this be done in ToggleNewStatus with DBIC? Right now it seems like the patch is using a mix of old and new (see comment 18 from Kyle). +sub columns { +sub ToggleNewStatus { +sub biblioitems_columns { 2) The 'new' column In comment 19 you said the goal of the cronjob was to remove the new flag. I am unsure if I see the use of the new field in the code and the feature. To me it seems just like a new 'notes' field, that is not really accessible without further configuration. a) In order to be able to set the field, you need to add a Koha-2- MARC-Mapping and change the bibliographic frameworks. Only then you will be able to catalog it. The field won't be searchable as there is no index on it. If we want to add an index later, this will be difficult, as we can't tell which mappings people will have used. How will libraries learn about the existance of the new column? b) For a general purpose field varchar(32) seems a bit limited. c) It seems the feature is independend on the existance of the new column. The central column for the feature seems to be the existing dateaccessioned column instead. With the implications of a) I am not sure we should include the 'new' from the beginning without having a clearer definition on how to use it. 4) Features in documentation I think the documentation lists features more like in an ad, than like in a help file. It's not clear to the reader, how to achieve the described functionality. That's what I have come up with: + <li>know easily what are the new items in the catalogue.</li> This still requires SQL, so doesn't seem to depend on the feature. + <li>display an icon in the search results for new items.</li> The only way to do this I can come up with is limited to libraries using biblio level itypes and by switching the itemtype with the script. + <li>configure issuing rules depending the 'new' status.</li> I think this would also require switching the itemtype? + <li>get a RSS/Atom feeds on these new items.</li> I think this would require using a special value in an item column that is searchable with Zebra. So you can build a search in Zebra that can then be used for the RSS feed? 4) biblioitems a) I am worried about some columns that should not be substituted: biblionumber, itemnumber, barcode, totalissues, onloan ... I think those are potentially dangerous and should not be listed. b) To me it seems like the only goal of including biblioitems is the possibility to change the bibliotitems itemtype. As it is now, it also allows changing values like title, pages, etc. which borders on a record batch edit. To me this seems a bit misplaced here. Also, ToggleNewStatus seems to only do ModItem - but you can define substitutions for biblioitems? (see also 6) 5) GUI a) It's not possible to edit a single rule. In order to add a rule or edit a rule, you always have to use 'Edit' and then all rules will display, the form for adding the new rule is at the very bottom. It is not very comfortable. b) There are no mandatory fields, duration is optional, as are conditions and substitions. So you can define an empty rule. c) In all other item related forms we use the names defined for the columns in the default framework (at least that's where I think those come from). But this feature only shows the names of the database columns. I think this is because of 2 a)? 6) Exploding? I defined a mean rule: Duration: 1 (only 1 item in my database has an accessiondate from yesterday) Conditions: no condition Substitutions: biblioitems.publishercode = XXXX biblioitems.url = something biblioitems.itemtype = XXXX items.barcode = xxxx items.materials = xxxx I didn't expect much to happen, but I had misinterpreted the duration. Results: DBD::mysql::st execute failed: Unknown column 'biblioitems.publishercode' in 'field list' at /home/katrin/kohaclone/C4/Items.pm line 2324. ERROR in _koha_modify_item UPDATE items SET biblioitems.publishercode=? WHERE itemnumber=?: Unknown column 'biblioitems.publishercode' in 'field list' at /home/katrin/kohaclone/C4/Items.pm line 2327. DBD::mysql::st execute failed: Unknown column 'biblioitems.url' in 'field list' at /home/katrin/kohaclone/C4/Items.pm line 2324. ERROR in _koha_modify_item UPDATE items SET biblioitems.url=? WHERE itemnumber=?: Unknown column 'biblioitems.url' in 'field list' at /home/katrin/kohaclone/C4/Items.pm line 2327. DBD::mysql::st execute failed: Unknown column 'biblioitems.itemtype' in 'field list' at /home/katrin/kohaclone/C4/Items.pm line 2324. ERROR in _koha_modify_item UPDATE items SET biblioitems.itemtype=? WHERE itemnumber=?: Unknown column 'biblioitems.itemtype' in 'field list' at /home/katrin/kohaclone/C4/Items.pm line 2327. DBD::mysql::st execute failed: Duplicate entry 'xxxx' for key 'itembarcodeidx' at /home/katrin/kohaclone/C4/Items.pm line 2324. ERROR in _koha_modify_item UPDATE items SET items.barcode=? WHERE itemnumber=?: Duplicate entry 'xxxx' for key 'itembarcodeidx' at /home/katrin/kohaclone/C4/Items.pm line 2327. Of course, no all my items have xxxx in materials. I thought initially only those items exactly 1 day old would be touched. But it will change all items older than 1 day. So this potentially will update a lot of items on each run. The SQL also shows that you can't actually update biblioitems columns, although the GUI offers the option. -------- I really like the idea of this, but to me it seems like there is some sort of mismatch between the feature description and how it seems to work. It feels like it needs some more thought. I think maybe this feature 'grew' since its initial specification? An example for a mismatch is also the description of the cronjob: +./toggle_new_status.pl -h + +Toggle recent acquisitions status. +Use this script to delete "new" status for items. There is no mention of the new column in the script. Another problem I see is that the feature as it is now is potentially quite dangerous and substitiutions on biblioitems don't work. Maybe biblioitems should be removed altogether from this. I'd love to hear some more opinions on this. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Laurence Lefaucheur <laurence.lefaucheur@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |laurence.lefaucheur@biblibr | |e.com --- Comment #36 from Laurence Lefaucheur <laurence.lefaucheur@biblibre.com> --- Just some more information on how the dev works before answering more in details to Katrin's notes The goal of the cronjob is to remove a "new" information from items after a given period. What could be a "new" information in the item : 1) a 'new' status added just to inform about the new document : we suppose an item subfield mapped with items.new field. This value can be used in search (if zebra index is configured), for custom rss feeds ; the subfield can be linked to an authorised value (authorised value=1, label=New). The cronjob will delete the value in the 'new' subfield. 2) a 'New' itype (itemtype) so that specific issuing rules can be defined for new items. With this configuration, final itemtype can be defined based on condition in another item subfield (ccode) or in a biblio subfield (mapped with biblioitems.itemtype) or in any items or biblioitems available field. The cronjob will delete the 'New' itype value and replace it by the suitable itype) 3) why not both of 1) and 2) or any item subfield the library wants to have some 'new' information. Only items are modified, the modification of biblio (biblio or biblioitems) is not part of the dev. Biblioitems fields are used only for the condition criteria. The items having dateaccessioned <= Now-duration will be modified by the job. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #37 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to Katrin Fischer from comment #35) Helle Katrin,
Starting with some initial testing and notes on this:
1) I am not sure the 2 specialiced subroutines for getting the columns from items and biblioitems are needed - couldn't this be done in ToggleNewStatus with DBIC? Right now it seems like the patch is using a mix of old and new (see comment 18 from Kyle).
There are 2 calls, 1 in C4::Items::ToggleNewStatus and 1 in the pl script. I don't think it is a good idea to call DBIC directly in pl files.
2) The 'new' column In comment 19 you said the goal of the cronjob was to remove the new flag. I am unsure if I see the use of the new field in the code and the feature. To me it seems just like a new 'notes' field, that is not really accessible without further configuration.
As I tried to explain in the commit message, this feature allows to manage new items as you want. There is no restriction or a "way todo". I listed test case examples, it is how we use this field at BibLibre. This patch is an "introduction" to the idea of manage a "new" status.
a) In order to be able to set the field, you need to add a Koha-2- MARC-Mapping and change the bibliographic frameworks. Only then you will be able to catalog it. The field won't be searchable as there is no index on it. If we want to add an index later, this will be difficult, as we can't tell which mappings people will have used. How will libraries learn about the existance of the new column?
Reading the changelog?
b) For a general purpose field varchar(32) seems a bit limited.
In a lot of cases, we used it as a boolean, so it is enough. What do you suggest, VARCHAR(64), TEXT,...?
c) It seems the feature is independend on the existance of the new column. The central column for the feature seems to be the existing dateaccessioned column instead. With the implications of a) I am not sure we should include the 'new' from the beginning without having a clearer definition on how to use it.
This field is important for the workflow of our users, it is part of the feature.
4) Features in documentation I think the documentation lists features more like in an ad, than like in a help file.
Sorry, it was not the expected goal.
It's not clear to the reader, how to achieve the described functionality. That's what I have come up with:
+ <li>know easily what are the new items in the catalogue.</li>
This still requires SQL, so doesn't seem to depend on the feature.
It depends on the "new" field, so it depends on this feature, no?
+ <li>display an icon in the search results for new items.</li>
The only way to do this I can come up with is limited to libraries using biblio level itypes and by switching the itemtype with the script.
Yes, it is one of the purpose of it.
+ <li>configure issuing rules depending the 'new' status.</li>
I think this would also require switching the itemtype?
Yes.
+ <li>get a RSS/Atom feeds on these new items.</li>
I think this would require using a special value in an item column that is searchable with Zebra. So you can build a search in Zebra that can then be used for the RSS feed?
I don't know how they do that, maybe using a sql query.
4) biblioitems
a) I am worried about some columns that should not be substituted: biblionumber, itemnumber, barcode, totalissues, onloan ... I think those are potentially dangerous and should not be listed.
It is a cronjob script, all of them should be used with full knowledge of the facts. I think it is easier/better to list all fields rather than to limit the possibilities.
b) To me it seems like the only goal of including biblioitems is the possibility to change the bibliotitems itemtype. As it is now, it also allows changing values like title, pages, etc. which borders on a record batch edit. To me this seems a bit misplaced here. Also, ToggleNewStatus seems to only do ModItem - but you can define substitutions for biblioitems? (see also 6)
It seems only conditions on biblioitems have been tested, we don't use biblioitems for substitutions. I will provide a patch to remove the biblioitems fields in the substitution list.
5) GUI
a) It's not possible to edit a single rule. In order to add a rule or edit a rule, you always have to use 'Edit' and then all rules will display, the form for adding the new rule is at the very bottom. It is not very comfortable.
What do you suggest? I tried to do something ergonomic with a quite complicated form. With the actual way, if you have to add several rules, it is useless to save after adding each one, but only once at the end. I chose to edit all rules on the same screen, because they are stored in a syspref and I would prefer not to parse the pref to update the rules.
b) There are no mandatory fields, duration is optional, as are conditions and substitions. So you can define an empty rule.
Yes, it could be possible if you want to mark all items as new. I really want to avoid a long list of follow-ups. I don't want to add all requests in this report. If some reports are opened and linked to this one, and they are relevant, I will provide a patch. Originally, this feature was something like http://git.biblibre.com/?p=koha;a=blob;f=misc/cronjobs/toggle_new_status.pl;... We decided to submit something more flexible and more complete for the community, in order to open the possibilities. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #38 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 27810 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=27810&action=edit Bug 11023: Don't use the biblioitems fields for the subtitution It's dangerous to allow a change on the biblioitems fields with this feature. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Signed Off --- Comment #39 from Jonathan Druart <jonathan.druart@biblibre.com> --- Not sure why this is failed qa, I think it can be back to signoff. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #26817|0 |1 is obsolete| | --- Comment #40 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 29216 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=29216&action=edit Bug 11023: Toggle "new" status This patch adds: - a new DB field items.new. - a new page to configure this new status (tools/toggle_new_status.pl). - a new cronjob script (misc/cronjob/toggle_new_status.pl). Why this status is useful for some libraries ? The use cases are: - to know easily what are the new items (with a simple sql query). - to display an icon in the search results. - issuing rules can be adapt for new items. Automatically (using the cronjob script), the status change (depending the configuration) and the item can be issued, for example. - a RSS/Atom feeds can be created on these new items. Test plan: - log in with a librarian having the tools > items_batchmod permission. - navigate to Home > Tools > Toggle new status - click on the edit button - there are 3 "blocks": * duration: the duration during an item is considered as new. * conditions: the status will change only if the conditions are meet. * substitutions: if there is no substitution, no action will be done. You can add some change to apply to the matching items. E.g. ccode=3 new='' If the value is an empty string (in other words, the input does not contain anything), the field will be deleted. You can create as many rules as you want. - test the interface : add/remove rule, conditions, substitutions, submit the form, edit, etc. (There is a looot of JS everywhere, so certainly a looot of bugs...). - when you have your rules defined, you can now launch the cronjob script without any parameter. A report will be displayed with the matching itemnumber and the substitutions to apply. Verify results are consistent. - launch the script with the -c argument and verify values have been modified depending the substitution rules. Signed-off-by: juliette et rémy <juliette.levast@iepg.fr> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #26818|0 |1 is obsolete| | --- Comment #41 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 29217 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=29217&action=edit Bug 11023: Add the ability to specify fields from biblioitems table. Test plan: Same as before but try with fields from the biblioitems table. Signed-off-by: juliette et rémy <juliette.levast@iepg.fr> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #26819|0 |1 is obsolete| | --- Comment #42 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 29218 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=29218&action=edit Bug 11023: Add UT for C4::Items::ToggleNewStatus Test plan: prove t/db_dependent/Items/ToggleNewStatus.t Signed-off-by: juliette et rémy <juliette.levast@iepg.fr> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #26820|0 |1 is obsolete| | --- Comment #43 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 29219 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=29219&action=edit Bug 11023: FIX - condition on biblioitems table does not work If a rule contains a condition on the biblioitems table, the match won't work. This patch fixes this issue. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #26821|0 |1 is obsolete| | --- Comment #44 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 29220 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=29220&action=edit Bug 11023: Use DBIx-Class to retrieve column names -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #27810|0 |1 is obsolete| | --- Comment #45 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 29221 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=29221&action=edit Bug 11023: Don't use the biblioitems fields for the subtitution It's dangerous to allow a change on the biblioitems fields with this feature. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #46 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 29222 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=29222&action=edit Bug 11023: DB changes -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #26855|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=11023 --- Comment #47 from Jonathan Druart <jonathan.druart@biblibre.com> --- I extracted the DB changes in a new patch. I also added the DBIx changes to it. It fixes a bug: the items.new field was not list in the field list. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #48 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to Jonathan Druart from comment #46)
Created attachment 29222 [details] [review] Bug 11023: DB changes
Note: I don't know why this change has been generated: - on_delete => "CASCADE", + on_delete => "RESTRICT", -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch complexity|--- |Medium patch -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 claire.hernandez@biblibre.com <claire.hernandez@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |claire.hernandez@biblibre.c | |om --- Comment #49 from claire.hernandez@biblibre.com <claire.hernandez@biblibre.com> --- Just to support its integration. We use it a lot in production and for the moment we have to apply it manually, but patchs approved by BibLibre ;) -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA --- Comment #50 from Kyle M Hall <kyle@bywatersolutions.com> --- Issues: 1) Can enter an invalid days value ( for example 'test' rather than '5' ) in the editor 2) It would be better if the rules were listed in a table. The current display is very hard to read. 3) I think "Duration" should be "Age". Duration implies something taking place between now and the future, which isn't the case. I believe it's easier to think in terms of "When this item is 10 days old, do this". 3) I'm not sure if "Toggle new status" is a good name for this feature. Maybe something more along the lines of "Automatic item modifications by age". That's quite a mouthful, but I think it represents the feature better. The feature seems quite powerful, and I think the current name belies that fact. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #51 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 31820 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=31820&action=edit Bug 11023: Rename the duration parameter with 'age' -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #52 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 31821 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=31821&action=edit Bug 11023: The age parameter should be a number The template should check if the age parameter is correctly filled (should be a number). -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #53 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 31822 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=31822&action=edit Bug 11023: Change the name of the feature Originaly this feature only permits to update the "new" field. Now all item fields can be updated. The name of the feature is now "Automatic item modifications by age". -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #54 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to Kyle M Hall from comment #50) Kyle, Thanks to QA this feature!
Issues: 1) Can enter an invalid days value ( for example 'test' rather than '5' ) in the editor
Fixed, it's now a number.
2) It would be better if the rules were listed in a table. The current display is very hard to read.
I am not sure, you can have several conditions and substitutions for 1 rule. I started with a table but I didn't manage to do something clear.
3) I think "Duration" should be "Age". Duration implies something taking place between now and the future, which isn't the case. I believe it's easier to think in terms of "When this item is 10 days old, do this".
Renamed.
3) I'm not sure if "Toggle new status" is a good name for this feature. Maybe something more along the lines of "Automatic item modifications by age". That's quite a mouthful, but I think it represents the feature better.
Renamed. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Patch doesn't apply -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #29216|0 |1 is obsolete| | --- Comment #55 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 33226 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=33226&action=edit Bug 11023: Toggle "new" status This patch adds: - a new DB field items.new. - a new page to configure this new status (tools/toggle_new_status.pl). - a new cronjob script (misc/cronjob/toggle_new_status.pl). Why this status is useful for some libraries ? The use cases are: - to know easily what are the new items (with a simple sql query). - to display an icon in the search results. - issuing rules can be adapt for new items. Automatically (using the cronjob script), the status change (depending the configuration) and the item can be issued, for example. - a RSS/Atom feeds can be created on these new items. Test plan: - log in with a librarian having the tools > items_batchmod permission. - navigate to Home > Tools > Toggle new status - click on the edit button - there are 3 "blocks": * duration: the duration during an item is considered as new. * conditions: the status will change only if the conditions are meet. * substitutions: if there is no substitution, no action will be done. You can add some change to apply to the matching items. E.g. ccode=3 new='' If the value is an empty string (in other words, the input does not contain anything), the field will be deleted. You can create as many rules as you want. - test the interface : add/remove rule, conditions, substitutions, submit the form, edit, etc. (There is a looot of JS everywhere, so certainly a looot of bugs...). - when you have your rules defined, you can now launch the cronjob script without any parameter. A report will be displayed with the matching itemnumber and the substitutions to apply. Verify results are consistent. - launch the script with the -c argument and verify values have been modified depending the substitution rules. Signed-off-by: juliette et rémy <juliette.levast@iepg.fr> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #29217|0 |1 is obsolete| | --- Comment #56 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 33227 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=33227&action=edit Bug 11023: Add the ability to specify fields from biblioitems table. Test plan: Same as before but try with fields from the biblioitems table. Signed-off-by: juliette et rémy <juliette.levast@iepg.fr> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #29218|0 |1 is obsolete| | --- Comment #57 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 33228 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=33228&action=edit Bug 11023: Add UT for C4::Items::ToggleNewStatus Test plan: prove t/db_dependent/Items/ToggleNewStatus.t Signed-off-by: juliette et rémy <juliette.levast@iepg.fr> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #29219|0 |1 is obsolete| | --- Comment #58 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 33229 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=33229&action=edit Bug 11023: FIX - condition on biblioitems table does not work If a rule contains a condition on the biblioitems table, the match won't work. This patch fixes this issue. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #29220|0 |1 is obsolete| | --- Comment #59 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 33230 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=33230&action=edit Bug 11023: Use DBIx-Class to retrieve column names -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #29221|0 |1 is obsolete| | --- Comment #60 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 33231 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=33231&action=edit Bug 11023: Don't use the biblioitems fields for the subtitution It's dangerous to allow a change on the biblioitems fields with this feature. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #29222|0 |1 is obsolete| | --- Comment #61 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 33232 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=33232&action=edit Bug 11023: DB changes -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #31820|0 |1 is obsolete| | --- Comment #62 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 33233 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=33233&action=edit Bug 11023: Rename the duration parameter with 'age' -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #31821|0 |1 is obsolete| | --- Comment #63 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 33234 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=33234&action=edit Bug 11023: The age parameter should be a number The template should check if the age parameter is correctly filled (should be a number). -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #31822|0 |1 is obsolete| | --- Comment #64 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 33235 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=33235&action=edit Bug 11023: Change the name of the feature Originaly this feature only permits to update the "new" field. Now all item fields can be updated. The name of the feature is now "Automatic item modifications by age". -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Patch doesn't apply |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Patch doesn't apply --- Comment #65 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Fixed the first conflict on the tools home page, but then got stuck with a harder conflict: Apply? [(y)es, (n)o, (i)nteractive] i Applying: Bug 11023: Add the ability to specify fields from biblioitems table. Applying: Bug 11023: Add UT for C4::Items::ToggleNewStatus Applying: Bug 11023: FIX - condition on biblioitems table does not work Applying: Bug 11023: Use DBIx-Class to retrieve column names fatal: sha1 information is lacking or useless (C4/Items.pm). Repository lacks necessary blobs to fall back on 3-way merge. Cannot fall back to three-way merge. Patch failed at 0001 Bug 11023: Use DBIx-Class to retrieve column names The copy of the patch that failed is found in: /home/katrin/kohaclone/.git/rebase-apply/patch When you have resolved this problem run "git bz apply --continue". If you would prefer to skip this patch, instead run "git bz apply --skip". To restore the original branch and stop patching run "git bz apply --abort". Patch left in /tmp/Bug-11023-Use-DBIx-Class-to-retrieve-column-names-J9vKlx.patch -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #33226|0 |1 is obsolete| | --- Comment #66 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34782 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34782&action=edit Bug 11023: Toggle "new" status This patch adds: - a new DB field items.new. - a new page to configure this new status (tools/toggle_new_status.pl). - a new cronjob script (misc/cronjob/toggle_new_status.pl). Why this status is useful for some libraries ? The use cases are: - to know easily what are the new items (with a simple sql query). - to display an icon in the search results. - issuing rules can be adapt for new items. Automatically (using the cronjob script), the status change (depending the configuration) and the item can be issued, for example. - a RSS/Atom feeds can be created on these new items. Test plan: - log in with a librarian having the tools > items_batchmod permission. - navigate to Home > Tools > Toggle new status - click on the edit button - there are 3 "blocks": * duration: the duration during an item is considered as new. * conditions: the status will change only if the conditions are meet. * substitutions: if there is no substitution, no action will be done. You can add some change to apply to the matching items. E.g. ccode=3 new='' If the value is an empty string (in other words, the input does not contain anything), the field will be deleted. You can create as many rules as you want. - test the interface : add/remove rule, conditions, substitutions, submit the form, edit, etc. (There is a looot of JS everywhere, so certainly a looot of bugs...). - when you have your rules defined, you can now launch the cronjob script without any parameter. A report will be displayed with the matching itemnumber and the substitutions to apply. Verify results are consistent. - launch the script with the -c argument and verify values have been modified depending the substitution rules. Signed-off-by: juliette et rémy <juliette.levast@iepg.fr> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #33227|0 |1 is obsolete| | --- Comment #67 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34783 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34783&action=edit Bug 11023: Add the ability to specify fields from biblioitems table. Test plan: Same as before but try with fields from the biblioitems table. Signed-off-by: juliette et rémy <juliette.levast@iepg.fr> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #33228|0 |1 is obsolete| | --- Comment #68 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34784 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34784&action=edit Bug 11023: Add UT for C4::Items::ToggleNewStatus Test plan: prove t/db_dependent/Items/ToggleNewStatus.t Signed-off-by: juliette et rémy <juliette.levast@iepg.fr> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #33229|0 |1 is obsolete| | --- Comment #69 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34785 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34785&action=edit Bug 11023: FIX - condition on biblioitems table does not work If a rule contains a condition on the biblioitems table, the match won't work. This patch fixes this issue. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #33230|0 |1 is obsolete| | --- Comment #70 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34786 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34786&action=edit Bug 11023: Use DBIx-Class to retrieve column names -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #33231|0 |1 is obsolete| | --- Comment #71 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34787 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34787&action=edit Bug 11023: Don't use the biblioitems fields for the subtitution It's dangerous to allow a change on the biblioitems fields with this feature. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #33232|0 |1 is obsolete| | --- Comment #72 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34788 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34788&action=edit Bug 11023: DB changes -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #33233|0 |1 is obsolete| | --- Comment #73 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34789 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34789&action=edit Bug 11023: Rename the duration parameter with 'age' -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #33234|0 |1 is obsolete| | --- Comment #74 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34790 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34790&action=edit Bug 11023: The age parameter should be a number The template should check if the age parameter is correctly filled (should be a number). -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #33235|0 |1 is obsolete| | --- Comment #75 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 34791 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34791&action=edit Bug 11023: Change the name of the feature Originaly this feature only permits to update the "new" field. Now all item fields can be updated. The name of the feature is now "Automatic item modifications by age". -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Patch doesn't apply |Signed Off --- Comment #76 from Jonathan Druart <jonathan.druart@biblibre.com> --- Patches rebased. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 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.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #34782|0 |1 is obsolete| | Attachment #34783|0 |1 is obsolete| | Attachment #34784|0 |1 is obsolete| | Attachment #34785|0 |1 is obsolete| | Attachment #34786|0 |1 is obsolete| | Attachment #34787|0 |1 is obsolete| | Attachment #34788|0 |1 is obsolete| | Attachment #34789|0 |1 is obsolete| | Attachment #34790|0 |1 is obsolete| | Attachment #34791|0 |1 is obsolete| | --- Comment #77 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 34870 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34870&action=edit [PASSED QA] Bug 11023: Toggle "new" status This patch adds: - a new DB field items.new. - a new page to configure this new status (tools/toggle_new_status.pl). - a new cronjob script (misc/cronjob/toggle_new_status.pl). Why this status is useful for some libraries ? The use cases are: - to know easily what are the new items (with a simple sql query). - to display an icon in the search results. - issuing rules can be adapt for new items. Automatically (using the cronjob script), the status change (depending the configuration) and the item can be issued, for example. - a RSS/Atom feeds can be created on these new items. Test plan: - log in with a librarian having the tools > items_batchmod permission. - navigate to Home > Tools > Toggle new status - click on the edit button - there are 3 "blocks": * duration: the duration during an item is considered as new. * conditions: the status will change only if the conditions are meet. * substitutions: if there is no substitution, no action will be done. You can add some change to apply to the matching items. E.g. ccode=3 new='' If the value is an empty string (in other words, the input does not contain anything), the field will be deleted. You can create as many rules as you want. - test the interface : add/remove rule, conditions, substitutions, submit the form, edit, etc. (There is a looot of JS everywhere, so certainly a looot of bugs...). - when you have your rules defined, you can now launch the cronjob script without any parameter. A report will be displayed with the matching itemnumber and the substitutions to apply. Verify results are consistent. - launch the script with the -c argument and verify values have been modified depending the substitution rules. Signed-off-by: juliette et remy <juliette.levast@iepg.fr> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #78 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 34871 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34871&action=edit [PASSED QA] Bug 11023: Add the ability to specify fields from biblioitems table. Test plan: Same as before but try with fields from the biblioitems table. Signed-off-by: juliette et remy <juliette.levast@iepg.fr> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #79 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 34872 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34872&action=edit [PASSED QA] Bug 11023: Add UT for C4::Items::ToggleNewStatus Test plan: prove t/db_dependent/Items/ToggleNewStatus.t Signed-off-by: juliette et remy <juliette.levast@iepg.fr> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #80 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 34873 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34873&action=edit [PASSED QA] Bug 11023: FIX - condition on biblioitems table does not work If a rule contains a condition on the biblioitems table, the match won't work. This patch fixes this issue. Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #81 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 34874 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34874&action=edit [PASSED QA] Bug 11023: Use DBIx-Class to retrieve column names Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #82 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 34875 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34875&action=edit [PASSED QA] Bug 11023: Don't use the biblioitems fields for the subtitution It's dangerous to allow a change on the biblioitems fields with this feature. Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #83 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 34876 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34876&action=edit [PASSED QA] Bug 11023: DB changes Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #84 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 34877 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34877&action=edit [PASSED QA] Bug 11023: Rename the duration parameter with 'age' Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #85 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 34878 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34878&action=edit [PASSED QA] Bug 11023: The age parameter should be a number The template should check if the age parameter is correctly filled (should be a number). Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #86 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 34879 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34879&action=edit [PASSED QA] Bug 11023: Change the name of the feature Originaly this feature only permits to update the "new" field. Now all item fields can be updated. The name of the feature is now "Automatic item modifications by age". Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #87 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 34880 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34880&action=edit Bug 11023 [QA Followup] * Update DB version * Fix capitalization error * Rename misc/cronjobs/toggle_new_status.pl to misc/cronjobs/automatic_item_modification_by_age.pl Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #88 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 34881 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34881&action=edit Bug 11023 [QA Followup] - Complete the renaming of "toggle new status" to "automatic item modification by age" Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #34881|0 |1 is obsolete| | --- Comment #89 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 34882 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34882&action=edit Bug 11023 [QA Followup] - Complete the renaming of "toggle new status" to "automatic item modification by age" Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #34882|0 |1 is obsolete| | --- Comment #90 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 34883 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34883&action=edit Bug 11023 [QA Followup] - Complete the renaming of "toggle new status" to "automatic item modification by age" Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #91 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- No intention to block this, but still a bit worried about the possibility of people doing changes that might cause problems. Would people be ok with adding a separate permission for this tool? Currently it's tied to the batch delete permission, but not working with the restricted batch delete: flagsrequired => { tools => 'items_batchmod' }, Offering to write the patch :) -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #92 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to Katrin Fischer from comment #91)
No intention to block this, but still a bit worried about the possibility of people doing changes that might cause problems.
Would people be ok with adding a separate permission for this tool? Currently it's tied to the batch delete permission, but not working with the restricted batch delete:
flagsrequired => { tools => 'items_batchmod' },
Offering to write the patch :)
The items_batchmod permission make sense to me. I would prefer to add the support for items_batchmod_restricted if it makes sense for you too. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #93 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Guess I am still a little worried about people breaking things with this new tool - so that's why I'd have preferred a separate permission. We have a separate permission for every other tool, so it would fit in well. But the combination with the restricted mode makes things more complicated here. Not sure what's best. If we leave it with item batchmod it would make sense to add the restricted behaviour, but also sounds more complicated to do :) Maybe we should open a separate bug? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #94 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to Katrin Fischer from comment #93)
Maybe we should open a separate bug?
It's certainly the best. While people will start to use it, we will get feedback to improve the existing behavior. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #95 from Jonathan Druart <jonathan.druart@biblibre.com> --- s/While/When -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #96 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to Kyle M Hall from comment #90)
Created attachment 34883 [details] [review] Bug 11023 [QA Followup] - Complete the renaming of "toggle new status" to "automatic item modification by age"
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
I am not sure it's a good idea to create files and rename them in the same patch set. Maybe should we squash patches? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #34870|0 |1 is obsolete| | Attachment #34871|0 |1 is obsolete| | Attachment #34872|0 |1 is obsolete| | Attachment #34873|0 |1 is obsolete| | Attachment #34874|0 |1 is obsolete| | Attachment #34875|0 |1 is obsolete| | Attachment #34876|0 |1 is obsolete| | Attachment #34877|0 |1 is obsolete| | Attachment #34878|0 |1 is obsolete| | Attachment #34879|0 |1 is obsolete| | Attachment #34880|0 |1 is obsolete| | Attachment #34883|0 |1 is obsolete| | --- Comment #97 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 35375 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=35375&action=edit Bug 11023: Automatic item modification by age (Was Toggle "new" status") This patch adds: - a new DB field items.new. - a new page to configure this new status (tools/toggle_new_status.pl). - a new cronjob script (misc/cronjobs/automatic_item_modification_by_age.pl was misc/cronjob/toggle_new_status.pl) Why this status is useful for some libraries ? The use cases are: - to know easily what are the new items (with a simple sql query). - to display an icon in the search results. - issuing rules can be adapt for new items. Automatically (using the cronjob script), the status change (depending the configuration) and the item can be issued, for example. - a RSS/Atom feeds can be created on these new items. Test plan: - log in with a librarian having the tools > items_batchmod permission. - navigate to Home > Tools > Automatic item modifications by age (was: Toggle new status) - click on the edit button - there are 3 "blocks": * duration: the duration during an item is considered as new. * conditions: the status will change only if the conditions are meet. * substitutions: if there is no substitution, no action will be done. You can add some change to apply to the matching items. E.g. ccode=3 new='' If the value is an empty string (in other words, the input does not contain anything), the field will be deleted. You can create as many rules as you want. - test the interface : add/remove rule, conditions, substitutions, submit the form, edit, etc. (There is a looot of JS everywhere, so certainly a looot of bugs...). - when you have your rules defined, you can now launch the cronjob script without any parameter. A report will be displayed with the matching itemnumber and the substitutions to apply. Verify results are consistent. - launch the script with the -c argument and verify values have been modified depending the substitution rules. Signed-off-by: juliette et remy <juliette.levast@iepg.fr> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 11023: Add the ability to specify fields from biblioitems table. Test plan: Same as before but try with fields from the biblioitems table. Signed-off-by: juliette et remy <juliette.levast@iepg.fr> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 11023: Add UT for C4::Items::ToggleNewStatus Test plan: prove t/db_dependent/Items/ToggleNewStatus.t Signed-off-by: juliette et remy <juliette.levast@iepg.fr> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 11023: FIX - condition on biblioitems table does not work If a rule contains a condition on the biblioitems table, the match won't work. This patch fixes this issue. Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 11023: Use DBIx-Class to retrieve column names Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 11023: Don't use the biblioitems fields for the subtitution It's dangerous to allow a change on the biblioitems fields with this feature. Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 11023: Rename the duration parameter with 'age' Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 11023: The age parameter should be a number The template should check if the age parameter is correctly filled (should be a number). Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 11023: Change the name of the feature Originaly this feature only permits to update the "new" field. Now all item fields can be updated. The name of the feature is now "Automatic item modifications by age". Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 11023 [QA Followup] * Update DB version * Fix capitalization error * Rename misc/cronjobs/toggle_new_status.pl to misc/cronjobs/automatic_item_modification_by_age.pl Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Bug 11023 [QA Followup] - Complete the renaming of "toggle new status" to "automatic item modification by age" Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #98 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 35376 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=35376&action=edit Bug 11023: DB changes Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #99 from Jonathan Druart <jonathan.druart@biblibre.com> --- (In reply to Jonathan Druart from comment #96)
(In reply to Kyle M Hall from comment #90)
Created attachment 34883 [details] [review] [review] Bug 11023 [QA Followup] - Complete the renaming of "toggle new status" to "automatic item modification by age"
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
I am not sure it's a good idea to create files and rename them in the same patch set. Maybe should we squash patches?
I squashed all patches, except the DB changes. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Toggle new status for items |Automatic item modification | |by age (Was "Toggle new | |status for items") -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Matthias Meusburger <matthias.meusburger@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |matthias.meusburger@biblibr | |e.com Assignee|jonathan.druart@biblibre.co |matthias.meusburger@biblibr |m |e.com -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|matthias.meusburger@biblibr |jonathan.druart@biblibre.co |e.com |m -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Patch doesn't apply CC| |tomascohen@gmail.com --- Comment #100 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Can u please rebase it? I'm willing to test this ASAP. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 claire.hernandez@biblibre.com <claire.hernandez@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|jonathan.druart@bugs.koha-c |julian.maurice@biblibre.com |ommunity.org | -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #101 from claire.hernandez@biblibre.com <claire.hernandez@biblibre.com> --- Tomàs, Jajm should take it today. Thanks. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Julian Maurice <julian.maurice@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #35375|0 |1 is obsolete| | --- Comment #102 from Julian Maurice <julian.maurice@biblibre.com> --- Created attachment 41147 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=41147&action=edit Bug 11023: Automatic item modification by age (Was Toggle "new" status") Rebased on master -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Julian Maurice <julian.maurice@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #35376|0 |1 is obsolete| | --- Comment #103 from Julian Maurice <julian.maurice@biblibre.com> --- Created attachment 41148 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=41148&action=edit Bug 11023: DB changes Rebased on master and Koha/Schema/* files removed from the patch to avoid conflicts -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Julian Maurice <julian.maurice@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Patch doesn't apply |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Julian Maurice <julian.maurice@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=11023 Pierre Angot <tredok.pierre@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |tredok.pierre@gmail.com --- Comment #104 from Pierre Angot <tredok.pierre@gmail.com> --- Hello, Can you tell me if this patch will be compatible with 3.18 ? We are very interested ^^ -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 --- Comment #105 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to Pierre Angot from comment #104)
Hello,
Can you tell me if this patch will be compatible with 3.18 ?
We are very interested ^^
At least one of the previous version was :) It won't be backported, it's an enh. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11023 Heather Braum <hbraum@nekls.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |hbraum@nekls.org -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org