From 02fd7edf85f330e3f5cdeeafc88bd018eee7729d Mon Sep 17 00:00:00 2001 From: Nicole Engard Date: Fri, 5 Feb 2010 21:46:29 -0500 Subject: [PATCH] bug 4150 require title in new list on staff client Signed-off-by: Galen Charlton --- .../en/modules/virtualshelves/shelves.tmpl | 24 +++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tmpl b/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tmpl index ff5edb06ea..64f9d674cd 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tmpl +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tmpl @@ -88,6 +88,26 @@ function placeHold () { $("#hold_form").submit(); return false; } + /** + * This function checks to make sure a list title is assigned + */ + function Check(f) { + var _alertString=""; + var alertString2; + + if(f.addshelf.value.length ==0){ + _alertString += _("- You must enter a List Name\n"); + } + + if (_alertString.length==0) { + document.Aform.submit(); + } else { + alertString2 = _("Form not submitted because of the following problem(s)\n"); + alertString2 += "------------------------------------------------------------------------------------\n\n"; + alertString2 += _alertString; + alert(alertString2); + } + } //]]> @@ -242,7 +262,7 @@ function placeHold () { Create a new List
    -
  1. +
  2. Owner: " />
  3. Cancel +
    Cancel
    -- 2.39.5