Lines 35-48
Link Here
|
35 |
<h1>Enter a new purchase suggestion</h1> |
35 |
<h1>Enter a new purchase suggestion</h1> |
36 |
|
36 |
|
37 |
<p>Please fill out this form to make a purchase suggestion. You will receive an email when the library processes your suggestion</p> |
37 |
<p>Please fill out this form to make a purchase suggestion. You will receive an email when the library processes your suggestion</p> |
38 |
<p>Only the title is required, but the more information you enter the easier it will be for the librarians to find the title you're requesting. The "Notes" field can be used to provide any additional information.</p> |
38 |
<p>Only certain fields (marked in red) are required, but the more information you enter the easier it will be for the librarians to find the title you're requesting. The "Notes" field can be used to provide any additional information.</p> |
39 |
|
39 |
|
40 |
<form action="/cgi-bin/koha/opac-suggestions.pl" method="post"> |
40 |
<form action="/cgi-bin/koha/opac-suggestions.pl" method="post" id="add_suggestion_form"> |
41 |
<fieldset class="rows"> |
41 |
<fieldset class="rows"> |
42 |
<ol> |
42 |
<ol> |
43 |
<li><label class="required" for="title">Title:</label><input type="text" id="title" name="title" class="span6" maxlength="255" /></li> |
43 |
<li><label for="title">Title:</label><input type="text" id="title" name="title" class="span6" maxlength="255" /></li> |
44 |
<li><label for="author">Author:</label><input type="text" id="author" name="author" class="span6" maxlength="80" /></li> |
44 |
<li><label for="author">Author:</label><input type="text" id="author" name="author" class="span6" maxlength="80" /></li> |
45 |
<li><label for="copyrightdate">Copyright date:</label><input type="text" id="copyrightdate" name="copyrightdate" size="4" maxlength="4" /></li> |
45 |
<li><label for="copyrightdate">Copyright date:</label><input type="text" id="copyrightdate" name="copyrightdate" pattern="[12][0-9\-\?]{3}" size="4" maxlength="4" /></li> |
46 |
<li><label for="isbn">Standard number (ISBN, ISSN or other):</label><input type="text" id="isbn" name="isbn" maxlength="80" /></li> |
46 |
<li><label for="isbn">Standard number (ISBN, ISSN or other):</label><input type="text" id="isbn" name="isbn" maxlength="80" /></li> |
47 |
<li><label for="publishercode">Publisher:</label><input type="text" id="publishercode" name="publishercode" class="span6" maxlength="80" /></li> |
47 |
<li><label for="publishercode">Publisher:</label><input type="text" id="publishercode" name="publishercode" class="span6" maxlength="80" /></li> |
48 |
<li><label for="collectiontitle">Collection title:</label><input type="text" id="collectiontitle" name="collectiontitle" class="span6" maxlength="80" /></li> |
48 |
<li><label for="collectiontitle">Collection title:</label><input type="text" id="collectiontitle" name="collectiontitle" class="span6" maxlength="80" /></li> |
Lines 89-95
Link Here
|
89 |
<fieldset class="action"> |
89 |
<fieldset class="action"> |
90 |
<input type="hidden" name="suggested_by_anyone" value="[% suggested_by_anyone %]" /> |
90 |
<input type="hidden" name="suggested_by_anyone" value="[% suggested_by_anyone %]" /> |
91 |
<input type="hidden" name="op" value="add_confirm" /> |
91 |
<input type="hidden" name="op" value="add_confirm" /> |
92 |
<input type="submit" onclick="Check(this.form); return false;" class="btn" value="Submit your suggestion" /> <a class="action" href="/cgi-bin/koha/opac-suggestions.pl">Cancel</a> |
92 |
<input type="submit" class="btn" value="Submit your suggestion" /> <a class="action" href="/cgi-bin/koha/opac-suggestions.pl">Cancel</a> |
93 |
</fieldset> |
93 |
</fieldset> |
94 |
</form> |
94 |
</form> |
95 |
[% END %] |
95 |
[% END %] |
Lines 337-361
Link Here
|
337 |
return true; |
337 |
return true; |
338 |
}); |
338 |
}); |
339 |
[% END %] |
339 |
[% END %] |
340 |
}); |
340 |
[% IF ( op_add && mandatoryfields ) %] |
341 |
|
341 |
{ |
342 |
function Check(f) { |
342 |
var FldsRequired = [[% mandatoryfields %]]; |
343 |
var _alertString=""; |
343 |
for (var i = 0; i < FldsRequired.length; i++) { |
344 |
var alertString2; |
344 |
var rq_input = $('#' + FldsRequired[i]); |
345 |
|
345 |
if (rq_input.length != 1) continue; |
346 |
if(f.title.value.length ==0){ |
346 |
$(rq_input).attr("required", "required"); |
347 |
_alertString += _("- You must enter a Title") + "\n"; |
347 |
var rq_label = $("label[for=" + rq_input.attr("id") + "]"); |
348 |
} |
348 |
if (rq_label.length != 1) continue; |
349 |
|
349 |
$(rq_label).addClass('required'); |
350 |
if (_alertString.length==0) { |
350 |
} |
351 |
f.submit(); |
|
|
352 |
} else { |
353 |
alertString2 = _("Form not submitted because of the following problem(s)"); |
354 |
alertString2 += "\n------------------------------------------------------------------------------------\n\n"; |
355 |
alertString2 += _alertString; |
356 |
alert(alertString2); |
357 |
} |
351 |
} |
358 |
} |
352 |
[% END %] |
|
|
353 |
}); |
359 |
//]]> |
354 |
//]]> |
360 |
</script> |
355 |
</script> |
361 |
[% END %] |
356 |
[% END %] |