[Koha-bugs] [Bug 13465] Fields controlled by authorized values cannot be unset (Lost, damaged, not for loan status, ...)

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Thu Dec 18 11:45:56 CET 2014


http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=13465

Mirko Tietgen <mirko at abunchofthings.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #34508|0                           |1
        is obsolete|                            |

--- Comment #9 from Mirko Tietgen <mirko at abunchofthings.net> ---
Created attachment 34511
  -->
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=34511&action=edit
Bug 13465: Correct the field prefix ambiguity

This is introduced by Bug 12874.

Without this patch, it's not possible to clear (set to an empty string)
an item field.
This appended for field linked to an AV list but even if it's not.

The regex tried to prefix 'my_field' with 'items.' to have
'items.my_field'. It wanted to take care of the case where the prefix
already exists (Actually only 1: 'items.cn_source').
The regex is changed to: "add the prefix only if the string does not
contain a dot".

Moreover an ambiguity existed on the prefix: in marc_subfield_structure,
the kohafield is prefixed, but not in the key of the hash sent to
ModItemFromMarc.

Test plan:
- edit an item, set a status that is controlled by an authorized value
examples tested: damaged, not for loan
- check the status saved correctly
- edit the item again, reset the status to empty
- check the status saved correctly
- edit the item again, reset fields, edit fields
- check the fields saved correctly

Signed-off-by: Mirko Tietgen <mirko at abunchofthings.net>

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list