From 946d5bcdd2ccaefaba2596b8be1278781d1cc482 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Fri, 19 Jan 2018 14:13:48 -0300 Subject: [PATCH] Bug 19289: Use jQuery validate plugin This is quite dirty but rewrite the JS checks is out of the scope of this bug report. Signed-off-by: Katrin Fischer Signed-off-by: Jonathan Druart --- .../prog/en/modules/acqui/neworderempty.tt | 32 +++++++++++-------- 1 file changed, 18 insertions(+), 14 deletions(-) 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 9c5d689f2a..99955bb417 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt @@ -68,7 +68,7 @@ [% END %] -
+
Patrons @@ -121,8 +121,8 @@ Title [% title |html %] [% ELSE %] - - + + Required [% END %] @@ -545,11 +545,6 @@ _alertString +="-------------------------------------------------------------------\n\n"; - if ( isNull(ff.title,1) && isNull(ff.entertitle,1) ){ - ok=1; - _alertString += "\n- " + _("Title cannot be empty"); - } - if(isNull(ff.budget_id,1)){ ok=1; _alertString += "\n- "+ _("You must select a fund"); @@ -707,20 +702,24 @@ [% INCLUDE 'intranet-bottom.inc' %] [% BLOCK display_subfield %] - [% IF field.mandatory %] - - [% ELSE %] - - [% END %] + [% IF field.authorised_value %] [% SWITCH field.authorised_value %] [% CASE 'branches' %] + [% IF field.mandatory %] + + [% END %] [% PROCESS options_for_libraries libraries => Branches.all( selected => "FIXME" ) %] [% CASE 'itemtypes' %] + [% IF field.mandatory %] + + [% END %] [% PROCESS options_for_itemtypes itemtypes => ItemTypes.Get(), selected_itemtype => "FIXME" %] @@ -729,7 +728,12 @@ [% PROCESS 'av-build-dropbox.inc' name="bib_field_value", category=field.authorised_value, default="FIXME" %] [% END %] [% ELSE %] - + [% IF field.mandatory %] + + [% ELSE %] + + [% END %] + [% END %] -- 2.39.5