Bug 20913 - Allow multiple if/unless statements in MARC modification template actions by adding AND/OR qualifiers
Summary: Allow multiple if/unless statements in MARC modification template actions by ...
Status: NEW
Alias: None
Product: Koha
Classification: Unclassified
Component: Cataloging (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-06-12 05:37 UTC by Hugh Rundle
Modified: 2023-04-16 00:26 UTC (History)
2 users (show)

See Also:
GIT URL:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Hugh Rundle 2018-06-12 05:37:13 UTC
Actions in MARC Modification templates have the following syntax:

[action] all/first [field] (plus optionally... if/unless [field] [conditional])

But there is only the option for one if/unless. This is usually enough, but sometimes it would be useful to be able to add another qualifier linked with and/or.

For example, libraries importing embedded items might want to apply a different shelf location or call number depending on the home location. In this case, they would want to do something like:

Add/Update field '952c' with value 'Animals' 
IF field '984c' matches /^(57+[0-9]+.?.*)/
AND 
IF field '952a' matches 'Main'