https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22123

            Bug ID: 22123
           Summary: Hardcoded values in subfield constraint visibility
 Change sponsored?: ---
           Product: Koha
           Version: unspecified
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P5 - low
         Component: Templates
          Assignee: [email protected]
          Reporter: [email protected]
        QA Contact: [email protected]
  Target Milestone: ---

The MARC subfield constraint editor shows checkboxes for the subfield
visibility (OPAC, Intranet, Editor, Collapsed, Flagged). The state of these
checkboxes is encoded in the database as a single integer, and the conversion
is done in marc_subfields_structure.js via hardcoded magic values:

    if ( flagged_checked ) {
        hidden_value='-8';
    } else if ( opac_checked && ! intranet_checked && ! editor_checked &&
collapsed_checked ) {
        hidden_value='-7';
    } else if ( opac_checked && intranet_checked && ! editor_checked && !
collapsed_checked) {
        hidden_value='-6';


etc.

These should be moved into the database, perhaps as authorised values.

-- 
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[email protected]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to