Bugzilla – Attachment 6878 Details for
Bug 4158
cannot create list whose title is '0'
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patched to check for '0' entered as a list name.
0001-Added-check-for-0-as-a-list-name-bug-4158.patch (text/plain), 2.01 KB, created by
Duncan
on 2011-12-20 02:58:56 UTC
(
hide
)
Description:
Patched to check for '0' entered as a list name.
Filename:
MIME Type:
Creator:
Duncan
Created:
2011-12-20 02:58:56 UTC
Size:
2.01 KB
patch
obsolete
>From fae38489c0d4e687e6bcb17facef24d9c1126e34 Mon Sep 17 00:00:00 2001 >From: Duncan Tyler <duncan@catalyst.net.nz> >Date: Tue, 20 Dec 2011 15:48:54 +1300 >Subject: [PATCH] Added check for 0 as a list name - bug 4158 > >--- > .../prog/en/modules/virtualshelves/shelves.tt | 9 +++++++-- > .../opac-tmpl/prog/en/modules/opac-shelves.tt | 4 +++- > 2 files changed, 10 insertions(+), 3 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt >index b432020..5e9c175 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt >@@ -94,14 +94,19 @@ function placeHold () { > function Check(f) { > var _alertString=""; > var alertString2; >+ >+ if($("#addshelf").val() == "0"){ >+ alert("The number 0 is not a valid name for a list, please enter another name."); >+ } > >- if($("#shelfname").val() == ""){ >+ if($("#addshelf").val() == ""){ > _alertString += _("- You must enter a List Name") + "\n"; > } > > if (_alertString.length==0) { > f.submit(); >- } else { >+ } >+ else { > alertString2 = _("Form not submitted because of the following problem(s)"); > alertString2 += "\n------------------------------------------------------------------------------------\n\n"; > alertString2 += _alertString; >diff --git a/koha-tmpl/opac-tmpl/prog/en/modules/opac-shelves.tt b/koha-tmpl/opac-tmpl/prog/en/modules/opac-shelves.tt >index 391037f..abf78b4 100644 >--- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-shelves.tt >+++ b/koha-tmpl/opac-tmpl/prog/en/modules/opac-shelves.tt >@@ -121,7 +121,9 @@ $(function() { > if(f.addshelf.value.length ==0){ > _alertString += _("- You must enter a List Name") + "\n"; > } >- >+ else if(f.addshelf.value == "0"){ >+ alert("The number '0' is not a valid name for a list, please enter another name."); >+ } > if (_alertString.length==0) { > f.submit(); > } else { >-- >1.7.5.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 4158
: 6878 |
7303