Bugzilla – Attachment 72785 Details for
Bug 10442
Remove references to non-standard "error" class
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 10442: Remove references to non-standard "error" class
Bug-10442-Remove-references-to-non-standard-error-.patch (text/plain), 10.91 KB, created by
Owen Leonard
on 2018-03-13 14:50:47 UTC
(
hide
)
Description:
Bug 10442: Remove references to non-standard "error" class
Filename:
MIME Type:
Creator:
Owen Leonard
Created:
2018-03-13 14:50:47 UTC
Size:
10.91 KB
patch
obsolete
>From 61a83a961669502f3a0ba9af8627ab313a8d3fcd Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Tue, 13 Mar 2018 10:12:20 +0000 >Subject: [PATCH] Bug 10442: Remove references to non-standard "error" class > >The CSS for <div class="error"> is obsolete and should not be used. This >patch removes the definition from the main CSS file and corrects >instances of its use in the templates to the standard <div class="dialog >alert">. > >To test: > >- In Acquisitions -> Late orders, locate an order from a vendor which > doesn't have an email address. Selecting that order and clicking > "Claim" should trigger an error dialog, "This vendor has no email." It > should be styled correctly. > >- With AcqCreateItem set to "when placing an order," add to an existing > order using the "From a new (empty) record" option. Add two items with > identical barcodes and submit the form. A error should show at > the top of the page. > >- With AcqCreateItem set to "when receiving an order," receive an order > and add two items with identical barcodes. Submitting the form should > trigger an error message at the top of the page. > >With the remaining cases I don't know how to trigger the errors in >question, so a visual check of the changes may be required: > >- Administration -> Funds -> "You are not authorized to modify this > fund" >- Administration -> Search engine configuration > (/admin/searchengine/elasticsearch/mappgings.pl) -> Various > modification errors. >- With the AutoEmailOpacUser preference set to "send," adding a patron > without an email address can trigger an error, "This member has no > email." >- With plugins enabled, and installed, there are error messages > displayed under various circumstances. >--- > koha-tmpl/intranet-tmpl/prog/css/staff-global.css | 7 ------- > koha-tmpl/intranet-tmpl/prog/en/modules/acqui/lateorders.tt | 6 +++--- > koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt | 2 +- > koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt | 2 +- > koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqbudgets.tt | 2 +- > .../en/modules/admin/searchengine/elasticsearch/mappings.tt | 6 +++--- > .../intranet-tmpl/prog/en/modules/members/memberentrygen.tt | 4 ++-- > .../intranet-tmpl/prog/en/modules/plugins/plugins-home.tt | 8 ++++++-- > koha-tmpl/intranet-tmpl/prog/js/additem.js | 10 +++++----- > 9 files changed, 22 insertions(+), 25 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/css/staff-global.css b/koha-tmpl/intranet-tmpl/prog/css/staff-global.css >index 3ab9d7e..4f5fa47 100644 >--- a/koha-tmpl/intranet-tmpl/prog/css/staff-global.css >+++ b/koha-tmpl/intranet-tmpl/prog/css/staff-global.css >@@ -971,13 +971,6 @@ ul.fa-ul li { > list-style-type: none; > } > >-div.error { >- border : 2px dashed #990000; >- background-color : #FFFF99; >- padding : .5em; >- margin : 1em; >-} >- > input.alert { > background-color : #FFFF99; > border-color: #900; >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/lateorders.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/lateorders.tt >index 4c142a1..cb8333e 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/lateorders.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/lateorders.tt >@@ -25,11 +25,11 @@ > > [% IF error_claim %] > [% IF ( error_claim == "no_email" ) %] >- <div class="error">This vendor has no email</div> >+ <div class="dialog alert">This vendor has no email</div> > [% ELSIF ( error_claim == "no_order_selected" ) %] >- <div class="error">No order selected</div> >+ <div class="dialog alert">No order selected</div> > [% ELSE %] >- <div class="error">[% error_claim %]</div> >+ <div class="dialog alert">[% error_claim %]</div> > [% END %] > [% END %] > [% IF info_claim %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt >index f9b4a15..eaf09f6 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt >@@ -27,7 +27,7 @@ > [% END %] > </h2> > >-<div class="error" style="display:none"></div> >+<div class="dialog alert order_error" style="display:none"></div> > > [% IF ( basketno ) %] > <div id="acqui_basket_summary" class="yui-g"> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt >index 8ec42ad..d079928 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt >@@ -25,7 +25,7 @@ > <form action="/cgi-bin/koha/acqui/finishreceive.pl" method="post" onsubmit="return Check(this);"> > <div class="yui-g"> > <div class="yui-u first"> >- <div class="error" style="display:none"></div> >+ <div class="dialog alert order_error" style="display:none"></div> > > <fieldset class="rows"> > <legend>Catalog details</legend> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqbudgets.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqbudgets.tt >index e64c9e9..b0cae88 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqbudgets.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqbudgets.tt >@@ -32,7 +32,7 @@ > [% UNLESS op == 'delete_confirm' %][% INCLUDE 'budgets-admin-toolbar.inc' %][% END %] > > [% IF (error_not_authorised_to_modify) %] >- <div class="error"> >+ <div class="dialog alert"> > <p>You are not authorized to modify this fund</p> > </div> > [% END %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/searchengine/elasticsearch/mappings.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/searchengine/elasticsearch/mappings.tt >index 24327c5..3573e40 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/searchengine/elasticsearch/mappings.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/searchengine/elasticsearch/mappings.tt >@@ -87,11 +87,11 @@ a.add, a.delete { > [% END %] > > <h1>Search engine configuration</h1> >- <div class="warning"> >- Warning: Any modification in these configurations will need a total reindexation to be fully taken into account ! >+ <div class="dialog message"> >+ <strong>Warning:</strong> Any modification in these configurations will need a total reindexation to be fully taken into account ! > </div> > [% IF errors %] >- <div class="error"> >+ <div class="dialog alert"> > Errors occurred, Modifications does not apply. Please check following values: > <ul> > [% FOREACH e IN errors %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt >index cbd3784..5ec2d19 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt >@@ -22,9 +22,9 @@ > <div class="yui-b"> > [% IF error_alert %] > [% IF ( error_alert == "no_email" ) %] >- <div class="error">This member has no email</div> >+ <div class="dialog alert">This member has no email</div> > [% ELSE %] >- <div class="error">[% error_alert %]</div> >+ <div class="dialog alert">[% error_alert %]</div> > [% END %] > [% END %] > [% IF info_alert %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/plugins/plugins-home.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/plugins/plugins-home.tt >index a2c91d4..e7e7812 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/plugins/plugins-home.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/plugins/plugins-home.tt >@@ -76,11 +76,15 @@ > [% plugin.metadata.description %] > > [% IF ( plugin.metadata.minimum_version && koha_version < plugin.metadata.minimum_version ) %] >- <div class="error">Warning: This report was written for a newer version of Koha. Run at your own risk.</div> >+ <div class="dialog alert"> >+ Warning: This report was written for a newer version of Koha. Run at your own risk. >+ </div> > [% END %] > > [% IF ( plugin.metadata.maximum_version && koha_version > plugin.metadata.maximum_version ) %] >- <div class="error">Warning: This report was written for an older version of Koha. Run at your own risk.</div> >+ <div class="dialog alert"> >+ Warning: This report was written for an older version of Koha. Run at your own risk. >+ </div> > [% END %] > </td> > <td>[% plugin.metadata.author %]</td> >diff --git a/koha-tmpl/intranet-tmpl/prog/js/additem.js b/koha-tmpl/intranet-tmpl/prog/js/additem.js >index 6e4bf33..78b5780 100644 >--- a/koha-tmpl/intranet-tmpl/prog/js/additem.js >+++ b/koha-tmpl/intranet-tmpl/prog/js/additem.js >@@ -249,7 +249,7 @@ function check_additem(unique_item_fields) { > data['field'] = new Array(); > data['value'] = new Array(); > var array_fields = unique_item_fields.split(' '); >- $(".error").empty(); // Clear error div >+ $(".order_error").empty(); // Clear error div > > // Check if a value is duplicated in form > for ( field in array_fields ) { >@@ -270,7 +270,7 @@ function check_additem(unique_item_fields) { > var sorted_arr = values.sort(); > for (var i = 0; i < sorted_arr.length - 1; i += 1) { > if (sorted_arr[i + 1] == sorted_arr[i]) { >- $(".error").append( >+ $(".order_error").append( > fieldname + " '" + sorted_arr[i] + "' " > + (window.MSG_ADDITEM_JS_IS_DUPLICATE || "is duplicated") > + "<br/>"); >@@ -281,7 +281,7 @@ function check_additem(unique_item_fields) { > > // If there is a duplication, we raise an error > if ( success == false ) { >- $(".error").show(); >+ $(".order_error").show(); > return false; > } > >@@ -295,7 +295,7 @@ function check_additem(unique_item_fields) { > success = false; > for (var i=0; i < data[field].length; i++) { > var value = data[field][i]; >- $(".error").append( >+ $(".order_error").append( > field + " '" + value + "' " > + (window.MSG_ADDITEM_JS_ALREADY_EXISTS_IN_DB > || "already exists in database") >@@ -307,7 +307,7 @@ function check_additem(unique_item_fields) { > }); > > if ( success == false ) { >- $(".error").show(); >+ $(".order_error").show(); > } > return success; > } >-- >2.1.4
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 10442
:
18824
|
19281
|
19296
|
72785
|
77022
|
77742
|
78413
|
81615
|
81646