Bug 15077: Fix Fast Add framework to pass test

This patch fixes tab location for FA frameworks.
Not all subfields belongs to tab 0.

To test:
1) On current master, with default and fasadd fw loaded,
go to Home > Administration > MARC bibliographic framework test
it fails

2) Apply the patch
3) Delete all fw, reload all, or just default (bib & auth) and
fast add
4) Repeat 1, now test must pass

This is only on master, so no need to database update.

Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as advertised. MARC bibliographic framework test passed Ok.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This commit is contained in:
Bernardo Gonzalez Kriegel 2015-10-29 08:44:54 -03:00 committed by Tomas Cohen Arazi
parent c104977582
commit b44ac38ce6
1 changed files with 2 additions and 1 deletions

View File

@ -7,7 +7,7 @@ WHERE frameworkcode = '' AND
tagfield IN ('000', '008', '010', '020', '022', '050', '082', '090', '099', '100', '245', '250', '260', '300', '500', '942', '952', '999');
INSERT IGNORE INTO marc_subfield_structure (tagfield, tagsubfield, liblibrarian, libopac, repeatable, mandatory, kohafield, tab, authorised_value, authtypecode, value_builder, isurl, hidden, frameworkcode, seealso, link, defaultvalue)
SELECT tagfield, tagsubfield, liblibrarian, libopac, repeatable, mandatory, kohafield, 0, authorised_value, authtypecode, value_builder, isurl, hidden, 'FA', seealso, link, defaultvalue
SELECT tagfield, tagsubfield, liblibrarian, libopac, repeatable, mandatory, kohafield, tab, authorised_value, authtypecode, value_builder, isurl, hidden, 'FA', seealso, link, defaultvalue
FROM marc_subfield_structure
WHERE frameworkcode = '' AND
tagfield IN ('000', '008', '010', '020', '022', '050', '082', '090', '099', '100', '245', '250', '260', '300', '500', '942', '952', '999');
@ -16,6 +16,7 @@ tagfield IN ('000', '008', '010', '020', '022', '050', '082', '090', '099', '100
-- REVERT HIDDEN FIELD TO ORIGINAL (pre copy ) VALUES
-- **************************************************
UPDATE marc_subfield_structure SET tab = 0 WHERE tagfield IN ('100','245','250','260','300','500','942') AND frameworkcode = 'FA';
UPDATE marc_subfield_structure SET hidden ='0' WHERE tagfield = '010' AND tagsubfield = '8' AND frameworkcode = 'FA';
UPDATE marc_subfield_structure SET hidden ='0' WHERE tagfield = '010' AND tagsubfield = 'b' AND frameworkcode = 'FA';
UPDATE marc_subfield_structure SET hidden ='0' WHERE tagfield = '010' AND tagsubfield = 'z' AND frameworkcode = 'FA';