diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/branches.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/branches.tt index 2275f57c57..887b81ffd6 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/branches.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/branches.tt @@ -24,6 +24,18 @@ "iDisplayLength": 10, "sPaginationType": "four_button" })); + + [% IF ( heading_branches_add_branch_p ) %] + $("#Aform").on("submit", function( event ) { + if ( $("#branchcode").val().match(/\s/) ) { + event.preventDefault(); + alert(_("The library code entered contains whitespace characters. Please remove any whitespace characters from the library code")); + return false; + } else { + return true; + } + }); + [% END %] }); tinyMCE.init({ mode : "textareas", @@ -62,7 +74,7 @@ tinyMCE.init({
- +
@@ -247,7 +259,7 @@ tinyMCE.init({ [% ELSE %]
There are no libraries defined. Start defining libraries.
[% END %] - + [% IF ( branchcategories ) %] [% FOREACH branchcategorie IN branchcategories %]

Group(s): [% IF ( branchcategorie.properties ) %]Properties[% ELSE %][% IF ( branchcategorie.searchdomain ) %]Search domain[% END %][% END %]

@@ -297,7 +309,7 @@ tinyMCE.init({ [% END %]
- +
  1. [% IF ( categorycode ) %] Category code: @@ -344,7 +356,7 @@ tinyMCE.init({ [% IF ( delete_category ) %] [% UNLESS ( MESSAGE8 ) %] -
    +
    Confirm delete: