Koha/koha-tmpl/intranet-tmpl/prog/js
Owen Leonard 0117c6da8e Bug 22844: Simplify the process of selecting database columns for system preferences
This patch introduces a new way for users to select database columns for
system preferences like BorrowerMandatoryField, which currently
require hand-typing of database names.

This new system uses a JSON file containing label:column pairs for
database columns which are relevant to preferences which reference
borrower table columns. My intention was to have user-friendly values as
the labels, but embedding English strings in JSON would make them
untranslatable.

The following preferences are affected:

 - BorrowerMandatoryField
 - BorrowerUnwantedField
 - PatronSelfModificationBorrowerUnwantedField
 - PatronSelfRegistrationBorrowerMandatoryField
 - PatronSelfRegistrationBorrowerUnwantedField

== Test plan ==
 - apply the patches
 - regenerate the staff client CSS (yarn build)
 - updatedatabase
 - dbic
 - flush_memcached
 - restart_all to make sure the updated .pref file is used

 - Go to Administration -> System preferences, and search for
   "PatronSelf"
 - The input fields for PatronSelfModificationBorrowerUnwantedField,
   PatronSelfRegistrationBorrowerMandatoryField, and
   PatronSelfRegistrationBorrowerUnwantedField should appear as "locked"
   (read-only) inputs.
 - Clicking the input field should trigger a modal window with
   checkboxes for each available column from the borrowers table.
 - Test that the "select all" and "clear all" links work correctly.
 - Test that the "cancel" link closes the modal without saving your
   selections.
 - Test that the "Save" button closes the modal, copies your selections
   to the form field, and triggers the preference-saving function (this
   eliminates the need to click a save button again after closing the
   modal).
   - Test this process by making modifications to all three different
     preferences, confirming that the right data is preselected each
     time the modal is shown and the right data is saved to the right
     field each time.

Signed-off-by: Hayley Mapley <hayleymapley@catalyst.net.nz>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2020-07-20 16:08:22 +02:00
..
pages Bug 22844: Simplify the process of selecting database columns for system preferences 2020-07-20 16:08:22 +02:00
acq.js
acquisitions-menu.js
additem.js
addorderiso2709.js Bug 25563: (bug 24386 follow-up) Don't disable submit button if form has not been submitted yet 2020-05-22 09:07:02 +01:00
admin-menu.js
ajax.js
audio_alerts.js
auth-finder-search.js
automatic_item_modification_by_age.js
background-job-progressbar.js
basket.js Bug 24522: Show alert when trying to add nothing to a list in staff 2020-05-04 09:44:42 +01:00
basketgroup.js
biblio_framework.js
cart.js
catalog.js
cataloging.js Bug 11446: Use encodeURIComponent on search terms in authority lookup plugin 2020-05-18 15:25:54 +01:00
cataloging_additem.js
categories.js
charts.js
checkouts.js Bug 25293: Don't call escapeHtml on null 2020-07-20 14:05:21 +02:00
circ-patron-search-results.js
datatables.js Bug 25287: Make the strings from .js translatable 2020-06-24 15:15:41 +02:00
file-upload.js
funds_sorts.js
holds.js
ill-availability-partner.js Bug 23173: (follow-up) Display available partners 2020-04-06 11:04:59 +01:00
ill-availability.js
ill-list-table.js Bug 24043: (QA follow-up) Fix another TypeError when retrieving status name 2020-05-01 08:10:35 +01:00
item_search_fields.js
letter.js
localcovers.js
mana.js
marc_modification_templates.js
marc_subfields_structure.js Bug 25471: Add DataTables to MARC subfield structure admin page 2020-06-24 15:05:02 +02:00
members-menu.js
members.js
merge-record.js
messaging-preference-form.js
offlinecirc.js
onboarding.js
rotating-collections.js
serials-toolbar.js
showpredictionpattern.js
sms_providers.js
staff-global.js Bug 25363: Merge common.js with staff-global.js 2020-06-15 11:53:36 +02:00
subscription-add.js
suggestions.js Bug 24819: (follow-up) Rename suggestor to suggester 2020-04-20 13:36:42 +01:00
table_filters.js
tools-menu.js
viewlog.js Bug 25250: (bug 24982 follow-up) Don't disable checkboxes if modification log 2020-04-27 11:41:38 +01:00
xmlControlfield.js
z3950_search.js Bug 25702: Actions button on Search results from Z39.50 is displayed incorrectly 2020-06-23 10:15:03 +02:00