View | Details | Raw Unified | Return to bug 11766
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/authtypes.tt (-37 / +7 lines)
Lines 7-44 Link Here
7
[% END %]
7
[% END %]
8
</title>
8
</title>
9
[% INCLUDE 'doc-head-close.inc' %]
9
[% INCLUDE 'doc-head-close.inc' %]
10
<script type="text/javascript">
11
//<![CDATA[
12
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////
13
function isNotNull(f,noalert) {
14
	if (f.value.length ==0) {
15
		return false;
16
	}
17
	return true;
18
}
19
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////
20
function Check(f) {
21
	var _alertString="";
22
	var alertString2;
23
	if (f.authtypecode.value.length==0) {
24
		_alertString += "\n- " + _("Authority type : code missing");
25
	}
26
	if (!(isNotNull(window.document.Aform.authtypetext,1))) {
27
		_alertString += "\n- " + _("Description missing");
28
	}
29
	if (_alertString.length==0) {
30
		document.Aform.submit();
31
	} else {
32
		alertString2  = _("Form not submitted because of the following problem(s)");
33
		alertString2 += "\n------------------------------------------------------------------------------------\n";
34
		alertString2 += _alertString;
35
		alert(alertString2);
36
	}
37
}
38
39
//]]>
40
</script>
41
</head>
10
</head>
11
42
<body id="admin_authtypes" class="admin">
12
<body id="admin_authtypes" class="admin">
43
[% INCLUDE 'header.inc' %]
13
[% INCLUDE 'header.inc' %]
44
[% INCLUDE 'cat-search.inc' %]
14
[% INCLUDE 'cat-search.inc' %]
Lines 61-67 function Check(f) { Link Here
61
31
62
[% IF ( add_form ) %]
32
[% IF ( add_form ) %]
63
33
64
    <form action="[% script_name %]" name="Aform" method="post">
34
    <form action="[% script_name %]" name="Aform" method="post" class="validated">
65
    <fieldset class="rows">
35
    <fieldset class="rows">
66
    <legend>
36
    <legend>
67
    [% IF ( authtypecode ) %]
37
    [% IF ( authtypecode ) %]
Lines 78-88 function Check(f) { Link Here
78
            <input type="hidden" name="checked" value="0" />
48
            <input type="hidden" name="checked" value="0" />
79
            <input type="hidden" name="authtypecode" value="[% authtypecode %]" />[% authtypecode %]
49
            <input type="hidden" name="authtypecode" value="[% authtypecode %]" />[% authtypecode %]
80
    [% ELSE %]
50
    [% ELSE %]
81
            <label for="authtypecode">Authority type: </label>
51
            <label for="authtypecode" class="required">Authority type: </label>
82
            <input id="authtypecode" type="text" name="authtypecode" size="10" maxlength="10" onblur="toUC(this)" />
52
            <input id="authtypecode" type="text" class="required" required="required" name="authtypecode" size="10" maxlength="10" onblur="toUC(this)" />
83
    [% END %]
53
    [% END %]
84
        </li>
54
        </li>
85
		<li><label for="authtypetext">Description: </label><input type="text" id="authtypetext" name="authtypetext" size="40" maxlength="80" value="[% authtypetext |html %]" /></li>
55
        <li><label for="authtypetext" class="required">Description: </label><input type="text" id="authtypetext" name="authtypetext" size="40" maxlength="80" value="[% authtypetext |html %]" class="required" required="required" /></li>
86
		<li><label for="summary">Summary: </label><textarea id="summary" name="summary" cols="55" rows="7">[% summary %]</textarea></li>
56
		<li><label for="summary">Summary: </label><textarea id="summary" name="summary" cols="55" rows="7">[% summary %]</textarea></li>
87
		<li>
57
		<li>
88
		<p class="tip">Note: for 'Authority field to copy', enter the authority field that should be copied from the authority record to the bibliographic record. E.g., in MARC21, field 100 in the authority record should be copied to field 100 in the bibliographic record</p>
58
		<p class="tip">Note: for 'Authority field to copy', enter the authority field that should be copied from the authority record to the bibliographic record. E.g., in MARC21, field 100 in the authority record should be copied to field 100 in the bibliographic record</p>
Lines 94-100 function Check(f) { Link Here
94
        </li>
64
        </li>
95
    </ol>
65
    </ol>
96
	</fieldset>
66
	</fieldset>
97
	<fieldset class="action"><input type="submit" value="Submit" onclick="Check(this.form); return false;" />
67
    <fieldset class="action">
68
        <input type="submit" value="Submit" />
98
        <a class="cancel" href="[% script_name %]">Cancel</a>
69
        <a class="cancel" href="[% script_name %]">Cancel</a>
99
    </fieldset>
70
    </fieldset>
100
	</form>
71
	</form>
101
- 

Return to bug 11766