Bugzilla – Attachment 116088 Details for
Bug 27321
Make excluded database columns in system preferences more clearly disabled
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 27321: Make disabled DB columns clearly disabled visually
Bug-27321-Make-disabled-DB-columns-clearly-disable.patch (text/plain), 2.71 KB, created by
David Nind
on 2021-01-30 02:16:28 UTC
(
hide
)
Description:
Bug 27321: Make disabled DB columns clearly disabled visually
Filename:
MIME Type:
Creator:
David Nind
Created:
2021-01-30 02:16:28 UTC
Size:
2.71 KB
patch
obsolete
>From 9aff899e395516d0d16fa8f9a474411c120dace5 Mon Sep 17 00:00:00 2001 >From: Lucas Gass <lucas@bywatersolutions.com> >Date: Tue, 12 Jan 2021 23:42:27 +0000 >Subject: [PATCH] Bug 27321: Make disabled DB columns clearly disabled visually > >To test: >1. Apply patch and its dependency (bug 17364) >2. Rebuild the CSS (https://wiki.koha-community.org/wiki/Working_with_SCSS_in_the_OPAC_and_staff_client) >3. Go the system pref BorroweUnwantedFields >4. branchcode should cleary stand out as disabled (#cccccc) > >Signed-off-by: David Nind <david@davidnind.com> >--- > koha-tmpl/intranet-tmpl/prog/css/src/staff-global.scss | 5 +++++ > koha-tmpl/intranet-tmpl/prog/js/pages/preferences.js | 5 ++++- > 2 files changed, 9 insertions(+), 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/css/src/staff-global.scss b/koha-tmpl/intranet-tmpl/prog/css/src/staff-global.scss >index a46c61d051..e250462415 100644 >--- a/koha-tmpl/intranet-tmpl/prog/css/src/staff-global.scss >+++ b/koha-tmpl/intranet-tmpl/prog/css/src/staff-global.scss >@@ -3324,6 +3324,11 @@ label { > display: block; > margin: .5em 0; > } >+ >+ &.disabled { >+ color: #CCC; >+ cursor: not-allowed; >+ } > } > > .radio { >diff --git a/koha-tmpl/intranet-tmpl/prog/js/pages/preferences.js b/koha-tmpl/intranet-tmpl/prog/js/pages/preferences.js >index c25854b619..e7d8dad01a 100644 >--- a/koha-tmpl/intranet-tmpl/prog/js/pages/preferences.js >+++ b/koha-tmpl/intranet-tmpl/prog/js/pages/preferences.js >@@ -233,6 +233,7 @@ $( document ).ready( function () { > $.getJSON( themelang + "/modules/admin/preferences/" + datasource + ".json", function( data ){ > var items = []; > var checked = ""; >+ var style = ""; > $.each( data, function( key, val ){ > if( prefs.indexOf( val ) >= 0 ){ > checked = ' checked="checked" '; >@@ -240,12 +241,14 @@ $( document ).ready( function () { > checked = ""; > } > if( exclusions.indexOf( val ) >= 0 ){ >+ style = "disabled"; > disabled = ' disabled="disabled" '; > checked = ""; > } else { >+ style = ""; > disabled = ""; > } >- items.push('<label><input class="dbcolumn_selection" type="checkbox" id="' + key + '"' + checked + disabled + ' name="pref" value="' + val + '" /> ' + key + '</label>'); >+ items.push('<label class="' + style +'"><input class="dbcolumn_selection" type="checkbox" id="' + key + '"' + checked + disabled + ' name="pref" value="' + val + '" /> ' + key + '</label>'); > }); > $("<div/>", { > "class": "columns-2", >-- >2.11.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 27321
:
114761
|
114763
|
115045
|
115103
|
116088
|
116118