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

(-)a/Koha/ILL/Backend/intra-includes/cancel.inc (-16 lines)
Lines 1-16 Link Here
1
[% IF whole.error %]
2
<p>Unhandled error</p>
3
[% END %]
4
5
[% IF whole.stage == "confirm" %]
6
<h2>Cancel manual request</h2>
7
<p>Proceeding with this action will set this request to 'Cancelled'.</p>
8
<p>This means that actions have been taken to cancel this request at the source with whom the request was placed.</p>
9
<p>If you can confirm this has been done, please proceed.</p>
10
<p>
11
  [% base_url = "/cgi-bin/koha/ill/ill-requests.pl" %]
12
  [% proceed_url = base_url _ "?method=cancel&stage=confirm" _ "&illrequest_id=" _ request.illrequest_id %]
13
  <a class="btn btn-sm btn-primary" href="[% proceed_url | url %]">Revert request</a>
14
  <a class="btn btn-sm btn-default cancel" href="[% base_url | url %]">Cancel</a>
15
</p>
16
[% END %]
(-)a/Koha/ILL/Backend/intra-includes/confirm.inc (-18 lines)
Lines 1-18 Link Here
1
[% IF whole.error %]
2
<p>Unhandled error</p>
3
[% END %]
4
5
[% IF whole.stage == "confirm" %]
6
<h2>Confirm manual request</h2>
7
<p>Proceeding with this action will set this request to 'Requested'.</p>
8
<p>This means that actions have been taken to request this request from a source.</p>
9
<p>If you can confirm this has been done, please proceed.</p>
10
<p>
11
  [% base_url = "/cgi-bin/koha/ill/ill-requests.pl" %]
12
  [% proceed_url = base_url _ "?method=confirm&stage=confirm" _ "&illrequest_id=" _ request.illrequest_id %]
13
  <a class="btn btn-sm btn-primary" href="[% proceed_url | url %]">Confirm request</a>
14
  <a class="btn btn-sm btn-default cancel" href="[% base_url | url %]">Cancel</a>
15
</p>
16
[% ELSE %]
17
<p>Unknown stage.  This should not have happened.
18
[% END %]
(-)a/Koha/ILL/Backend/intra-includes/edititem.inc (-94 lines)
Lines 1-94 Link Here
1
[% cwd = whole.cwd %]
2
[% PROCESS "${cwd}/shared-includes/form_input_helpers.inc" %]
3
[% IF whole.error %]
4
[% IF whole.status == 'missing_type' %]
5
<p><em>Please note:</em> Mandatory field 'type' is missing.</p>
6
[% ELSE %]
7
<p>Unhandled error</p>
8
[% END %]
9
[% END %]
10
11
[% IF whole.stage == "form" %]
12
  <h2>Edit a manual ILL request</h2>
13
  <form id="standard_edit_form" method="POST" action="">
14
    [% INCLUDE 'csrf-token.inc' %]
15
    <fieldset class="rows">
16
      <legend>General details</legend>
17
      <ol id="general-standard-fields">
18
        <li>
19
          <label class="required" for="type">Type:</label>
20
          <select name="type" id="type">
21
            <option value=""/>
22
            [% IF whole.value.other.type.lower == "book" %]
23
            <option value="book" selected="selected">Book</option>
24
            [% ELSE %]
25
            <option value="book">Book</option>
26
            [% END %]
27
            [% IF whole.value.other.type.lower == "chapter" %]
28
            <option value="chapter" selected="selected">Chapter</option>
29
            [% ELSE %]
30
            <option value="chapter">Chapter</option>
31
            [% END %]
32
            [% IF whole.value.other.type.lower == "journal" %]
33
            <option value="journal" selected="selected">Journal</option>
34
            [% ELSE %]
35
            <option value="journal">Journal</option>
36
            [% END %]
37
            [% IF whole.value.other.type.lower == "article" %]
38
            <option value="article" selected="selected">Journal article</option>
39
            [% ELSE %]
40
            <option value="article">Journal article</option>
41
            [% END %]
42
            [% IF whole.value.other.type.lower == "thesis" %]
43
            <option value="thesis" selected="selected">Thesis</option>
44
            [% ELSE %]
45
            <option value="thesis">Thesis</option>
46
            [% END %]
47
            [% IF whole.value.other.type.lower == "conference" %]
48
            <option value="conference" selected="selected">Conference</option>
49
            [% ELSE %]
50
            <option value="conference">Conference</option>
51
            [% END %]
52
            [% IF whole.value.other.type.lower == "dvd" %]
53
            <option value="dvd" selected="selected">DVD</option>
54
            [% ELSE %]
55
            <option value="dvd">DVD</option>
56
            [% END %]
57
            [% IF whole.value.other.type.lower == "other" %]
58
            <option value="other" selected="selected">Other</option>
59
            [% ELSE %]
60
            <option value="other">Other</option>
61
            [% END %]
62
            [% IF whole.value.other.type.lower == "resource" %]
63
            <option value="resource" selected="selected">Generic resource</option>
64
            [% ELSE %]
65
            <option value="resource">Generic resource</option>
66
            [% END %]
67
          </select>
68
        </li>
69
      </ol>
70
    </fieldset>
71
    [% type = whole.value.other.type %]
72
    [% IF type %]
73
        [% INCLUDE "${cwd}/shared-includes/forms/${type}.inc" %]
74
    [% END %]
75
    [% INCLUDE "${cwd}/shared-includes/custom_fields.inc" %]
76
    <fieldset class="action">
77
      <input id="ill-submit" class="btn btn-primary" type="submit" value="Update"/>
78
      <a class="cancel" href="/cgi-bin/koha/ill/ill-requests.pl">Cancel</a>
79
    </fieldset>
80
    <input type="hidden" name="illrequest_id" value="[% whole.value.other.illrequest_id | html %]" />
81
    <input type="hidden" name="op" value="cud-edititem" />
82
    <input type="hidden" name="stage" value="form" />
83
    <input type="hidden" name="backend" value="Standard" />
84
  </form>
85
  [% BLOCK backend_jsinclude %]
86
  <script>
87
      // <![CDATA[]
88
      [% INCLUDE "${cwd}/shared-includes/shared.js" %]
89
      // ]]>
90
  </script>
91
  [% END %]
92
[% ELSE %]
93
  <p>Unknown stage.  This should not have happened.
94
[% END %]
(-)a/Koha/ILL/Backend/intra-includes/migrate.inc (-123 lines)
Lines 1-123 Link Here
1
[% IF whole.error %]
2
[% IF whole.status == 'missing_identifier' %]
3
<p><em>Please note:</em> Mandatory field Identifier is missing.</p>
4
[% ELSIF whole.status == 'missing_branch' %]
5
<p><em>Please note:</em> Library is a mandatory field.</p>
6
[% ELSIF whole.status == 'invalid_borrower' %]
7
<p><em>Please note:</em> The patrons details you entered are invalid.</p>
8
[% ELSIF whole.status == 'invalid_branch' %]
9
<p><em>Please note:</em> The library you chose is invalid.</p>
10
[% ELSE %]
11
<p>Unhandled error</p>
12
[% END %]
13
[% END %]
14
15
[% IF whole.stage == "form" %]
16
<h2>Migrating an ILL request</h2>
17
<form id="standard_migrate_form" method="POST" action="">
18
  <fieldset class="rows">
19
    <legend>General details</legend>
20
    <ol id="general-standard-fields">
21
      <li>
22
        <label class="required" for="type">Type:</label>
23
        <select class="form-select" name="type" id="type">
24
          <option value=""></option>
25
          [% IF whole.value.other.type.lower == "book" %]
26
          <option value="book" selected="selected">Book</option>
27
          [% ELSE %]
28
          <option value="book">Book</option>
29
          [% END %]
30
          [% IF whole.value.other.type.lower == "chapter" %]
31
          <option value="chapter" selected="selected">Chapter</option>
32
          [% ELSE %]
33
          <option value="chapter">Chapter</option>
34
          [% END %]
35
          [% IF whole.value.other.type.lower == "journal" %]
36
          <option value="journal" selected="selected">Journal</option>
37
          [% ELSE %]
38
          <option value="journal">Journal</option>
39
          [% END %]
40
          [% IF whole.value.other.type.lower == "article" %]
41
          <option value="article" selected="selected">Journal article</option>
42
          [% ELSE %]
43
          <option value="article">Journal article</option>
44
          [% END %]
45
          [% IF whole.value.other.type.lower == "thesis" %]
46
          <option value="thesis" selected="selected">Thesis</option>
47
          [% ELSE %]
48
          <option value="thesis">Thesis</option>
49
          [% END %]
50
          [% IF whole.value.other.type.lower == "conference" %]
51
          <option value="conference" selected="selected">Conference</option>
52
          [% ELSE %]
53
          <option value="conference">Conference</option>
54
          [% END %]
55
          [% IF whole.value.other.type.lower == "dvd" %]
56
          <option value="dvd" selected="selected">DVD/option>
57
          [% ELSE %]
58
          <option value="dvd">DVD</option>
59
          [% END %]
60
          [% IF whole.value.other.type.lower == "other" %]
61
          <option value="other" selected="selected">Other</option>
62
          [% ELSE %]
63
          <option value="other">Other</option>
64
          [% END %]
65
          [% IF whole.value.other.type.lower == "resource" %]
66
          <option value="resource" selected="selected">Generic resource</option>
67
          [% ELSE %]
68
          <option value="resource">Generic resource</option>
69
          [% END %]
70
        </select>
71
        [% IF required %]
72
            <div class="required_label required">Required</div>
73
        [% END %]
74
      </li>
75
    </ol>
76
  </fieldset>
77
  [% cwd = whole.cwd %]
78
  [% type = whole.value.other.type %]
79
  [% IF type %]
80
      [% INCLUDE "${cwd}/shared-includes/forms/${type}.inc" %]
81
  [% END %]
82
  [% INCLUDE "${cwd}/shared-includes/custom_fields.inc" %]
83
  <fieldset class="rows">
84
    <legend>Patron options</legend>
85
    <ol>
86
      <li>
87
        <label class="required" for="cardnumber">
88
          Card number or surname:
89
        </label>
90
        <input type="text" name="cardnumber" id="cardnumber" type="text" value="" />
91
            <div class="required_label required">Required</div>
92
      </li>
93
      <li>
94
        <label class="required" for="branchcode">Destination library:</label>xxx
95
        <select id="branchcode" name="branchcode">
96
          <option value=""></option>
97
          [% FOREACH branch IN branches %]
98
            <option value="[% branch.branchcode | html %]">
99
              [% branch.branchname | html %]
100
            </option>
101
          [% END %]
102
        </select>
103
            <div class="required_label required">Required</div>
104
      </li>
105
    </ol>
106
  </fieldset>
107
  <fieldset class="action">
108
    <input id="ill-submit" type="submit" value="Migrate"/>
109
    <a class="cancel" href="/cgi-bin/koha/ill/ill-requests.pl">Cancel</a>
110
  </fieldset>
111
</form>
112
[% BLOCK backend_jsinclude %]
113
<script>
114
    // <![CDATA[]
115
    [% INCLUDE "${cwd}/shared-includes/shared.js" %]
116
    // ]]>
117
</script>
118
[% END %]
119
120
[% ELSE %]
121
<p>Unknown stage.  This should not have happened.
122
123
[% END %]
(-)a/Koha/ILL/Backend/opac-includes/create.inc (-159 lines)
Lines 1-159 Link Here
1
[% USE Koha %]
2
[% PROCESS 'i18n.inc' %]
3
[% cwd = whole.cwd %]
4
[% PROCESS "${cwd}/shared-includes/form_input_helpers.inc" %]
5
[% IF whole.error %]
6
[% IF whole.status == 'missing_identifier' %]
7
    <div class="alert alert-warning">
8
        <strong>Please note:</strong> Mandatory field Identifier is missing.
9
    </div>
10
[% ELSIF whole.status == 'missing_type' %]
11
    <div class="alert alert-warning">
12
        <strong>Please note:</strong> Type is a mandatory field.
13
    </div>
14
[% ELSIF whole.status == 'missing_unauth_data' %]
15
    <div class="alert alert-warning">
16
        <strong>Please note:</strong> Patron data (first name, last name and e-mail) are mandatory fields.
17
    </div>
18
[% ELSIF whole.status == 'missing_branch' %]
19
    <div class="alert alert-warning">
20
        <strong>Please note:</strong> Library is a mandatory field.
21
    </div>
22
[% ELSIF whole.status == 'invalid_borrower' %]
23
    <div class="alert alert-warning">
24
        <strong>Please note:</strong> The patron details you entered are invalid.
25
    </div>
26
[% ELSIF whole.status == 'invalid_branch' %]
27
    <div class="alert alert-warning">
28
        <strong>Please note:</strong> The library you chose is invalid.
29
    </div>
30
[% ELSIF whole.status == 'failed_captcha' %]
31
    <div class="alert alert-warning">You typed in the wrong characters in the box before submitting. Please try again.</div>
32
[% ELSE %]
33
<p>Unhandled error</p>
34
[% END %]
35
[% END %]
36
[% SET opac = whole.value.other.opac %]
37
38
[% IF whole.stage == "form" %]
39
<h2>Create an ILL request</h2>
40
<form id="create_form" method="POST" action="">
41
  [% INCLUDE 'csrf-token.inc' %]
42
    <fieldset class="rows">
43
    <legend>Patron options</legend>
44
    <ol>
45
        [% IF unauthenticated_ill && !logged_in_user%]
46
          [% PROCESS ill_text_input_field required = 1 id = 'unauthenticated_first_name' label = t('First name') value = whole.value.other.unauthenticated_first_name %]
47
          [% PROCESS ill_text_input_field required = 1 id = 'unauthenticated_last_name' label = t('Last name') value = whole.value.other.unauthenticated_last_name %]
48
          [% PROCESS ill_text_input_field required = 1 id = 'unauthenticated_email' label = t('E-mail address') value = whole.value.other.unauthenticated_email %]
49
        [% END %]
50
        [% WRAPPER ill_select_field required = 1 id = 'branchcode' label = t('Destination library') %]
51
          <option value=""></option>
52
          [% FOREACH branch IN branches %]
53
            [% IF whole.value.other.branchcode && branch.branchcode == whole.value.other.branchcode %]
54
            <option value="[% branch.branchcode | html %]" selected="selected">
55
              [% branch.branchname | html %]
56
            </option>
57
            [% ELSE %]
58
            <option value="[% branch.branchcode | html %]">
59
              [% branch.branchname | html %]
60
            </option>
61
            [% END %]
62
          [% END %]
63
        [% END #ill_select_field %]
64
    </ol>
65
  </fieldset>
66
  <fieldset class="rows">
67
    <legend>General details</legend>
68
    <ol id="general-standard-fields">
69
        [% WRAPPER ill_select_field required = 1 id = 'type' label = t('Type') %]
70
          <option value=""></option>
71
          [% IF whole.value.other.type.lower == "book" %]
72
          <option value="book" selected="selected">Book</option>
73
          [% ELSE %]
74
          <option value="book">Book</option>
75
          [% END %]
76
          [% IF whole.value.other.type.lower == "chapter" %]
77
          <option value="chapter" selected="selected">Chapter</option>
78
          [% ELSE %]
79
          <option value="chapter">Chapter</option>
80
          [% END %]
81
          [% IF whole.value.other.type.lower == "journal" %]
82
          <option value="journal" selected="selected">Journal</option>
83
          [% ELSE %]
84
          <option value="journal">Journal</option>
85
          [% END %]
86
          [% IF whole.value.other.type.lower == "article" %]
87
          <option value="article" selected="selected">Journal article</option>
88
          [% ELSE %]
89
          <option value="article">Journal article</option>
90
          [% END %]
91
          [% IF whole.value.other.type.lower == "thesis" %]
92
          <option value="thesis" selected="selected">Thesis</option>
93
          [% ELSE %]
94
          <option value="thesis">Thesis</option>
95
          [% END %]
96
          [% IF whole.value.other.type.lower == "conference" %]
97
          <option value="conference" selected="selected">Conference</option>
98
          [% ELSE %]
99
          <option value="conference">Conference</option>
100
          [% END %]
101
          [% IF whole.value.other.type.lower == "dvd" %]
102
          <option value="dvd" selected="selected">DVD</option>
103
          [% ELSE %]
104
          <option value="dvd">DVD</option>
105
          [% END %]
106
          [% IF whole.value.other.type.lower == "other" %]
107
          <option value="other" selected="selected">Other</option>
108
          [% ELSE %]
109
          <option value="other">Other</option>
110
          [% END %]
111
          [% IF whole.value.other.type.lower == "resource" %]
112
          <option value="resource" selected="selected">Generic resource</option>
113
          [% ELSE %]
114
          <option value="resource">Generic resource</option>
115
          [% END %]
116
        [% END #ill_select_field %]
117
    </ol>
118
  </fieldset>
119
  [% type = whole.value.other.type %]
120
  [% IF type %]
121
      [% INCLUDE "${cwd}/shared-includes/forms/${type}.inc" %]
122
  [% END %]
123
  [% INCLUDE "${cwd}/shared-includes/custom_fields.inc" %]
124
  [% IF whole.value.other.type && unauthenticated_ill && !logged_in_user%]
125
    <fieldset class="rows" id="illrequest_captcha">
126
        <legend>Verification</legend>
127
        <ol>
128
            <li>
129
                <label for="captcha" class="required">Verification:</label>
130
131
                <input type="text" name="captcha" id="captcha" class="form-control input-fluid" style="text-transform: uppercase;" />
132
                <div class="required_label required">Required</div>
133
                <input type="hidden" name="captcha_digest" value="[% captcha_digest | html %]" />
134
135
                <span class="hint">Please type the following characters into the preceding box: <strong>[% captcha | html %]</strong></span>
136
            </li>
137
        </ol>
138
    </fieldset>
139
  [% END %]
140
  <fieldset class="action">
141
    <input id="ill-submit" class="btn btn-primary" type="submit" value="Create"/>
142
    <a class="cancel" href="/cgi-bin/koha/opac-illrequests.pl">Cancel</a>
143
  </fieldset>
144
  <input type="hidden" name="op" value="cud-create" />
145
  <input type="hidden" name="stage" value="form" />
146
  <input type="hidden" name="backend" value="Standard" />
147
</form>
148
149
[% ELSE %]
150
<p>Unknown stage.  This should not have happened.
151
152
[% END %]
153
[% BLOCK backend_jsinclude %]
154
<script>
155
    // <![CDATA[]
156
    [% INCLUDE "${cwd}/shared-includes/shared.js" %]
157
    // ]]>
158
</script>
159
[% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/ill/backends/Standard/cancel.inc (+16 lines)
Line 0 Link Here
1
[% IF whole.error %]
2
    <p>Unhandled error</p>
3
[% END %]
4
5
[% IF whole.stage == "confirm" %]
6
    <h2>Cancel manual request</h2>
7
    <p>Proceeding with this action will set this request to 'Cancelled'.</p>
8
    <p>This means that actions have been taken to cancel this request at the source with whom the request was placed.</p>
9
    <p>If you can confirm this has been done, please proceed.</p>
10
    <p>
11
        [% base_url = "/cgi-bin/koha/ill/ill-requests.pl" %]
12
        [% proceed_url = base_url _ "?method=cancel&stage=confirm" _ "&illrequest_id=" _ request.illrequest_id %]
13
        <a class="btn btn-sm btn-primary" href="[% proceed_url | url %]">Revert request</a>
14
        <a class="btn btn-sm btn-default cancel" href="[% base_url | url %]">Cancel</a>
15
    </p>
16
[% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/ill/backends/Standard/confirm.inc (+18 lines)
Line 0 Link Here
1
[% IF whole.error %]
2
    <p>Unhandled error</p>
3
[% END %]
4
5
[% IF whole.stage == "confirm" %]
6
    <h2>Confirm manual request</h2>
7
    <p>Proceeding with this action will set this request to 'Requested'.</p>
8
    <p>This means that actions have been taken to request this request from a source.</p>
9
    <p>If you can confirm this has been done, please proceed.</p>
10
    <p>
11
        [% base_url = "/cgi-bin/koha/ill/ill-requests.pl" %]
12
        [% proceed_url = base_url _ "?method=confirm&stage=confirm" _ "&illrequest_id=" _ request.illrequest_id %]
13
        <a class="btn btn-sm btn-primary" href="[% proceed_url | url %]">Confirm request</a>
14
        <a class="btn btn-sm btn-default cancel" href="[% base_url | url %]">Cancel</a>
15
    </p>
16
[% ELSE %]
17
    <p>Unknown stage. This should not have happened. </p>
18
[% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/ill/backends/Standard/edititem.inc (+94 lines)
Line 0 Link Here
1
[% cwd = whole.cwd %]
2
[% PROCESS "${cwd}/shared-includes/form_input_helpers.inc" %]
3
[% IF whole.error %]
4
    [% IF whole.status == 'missing_type' %]
5
        <p><em>Please note:</em> Mandatory field 'type' is missing.</p>
6
    [% ELSE %]
7
        <p>Unhandled error</p>
8
    [% END %]
9
[% END %]
10
11
[% IF whole.stage == "form" %]
12
    <h2>Edit a manual ILL request</h2>
13
    <form id="standard_edit_form" method="POST" action="">
14
        [% INCLUDE 'csrf-token.inc' %]
15
        <fieldset class="rows">
16
            <legend>General details</legend>
17
            <ol id="general-standard-fields">
18
                <li>
19
                    <label class="required" for="type">Type:</label>
20
                    <select name="type" id="type">
21
                        <option value="" />
22
                        [% IF whole.value.other.type.lower == "book" %]
23
                            <option value="book" selected="selected">Book</option>
24
                        [% ELSE %]
25
                            <option value="book">Book</option>
26
                        [% END %]
27
                        [% IF whole.value.other.type.lower == "chapter" %]
28
                            <option value="chapter" selected="selected">Chapter</option>
29
                        [% ELSE %]
30
                            <option value="chapter">Chapter</option>
31
                        [% END %]
32
                        [% IF whole.value.other.type.lower == "journal" %]
33
                            <option value="journal" selected="selected">Journal</option>
34
                        [% ELSE %]
35
                            <option value="journal">Journal</option>
36
                        [% END %]
37
                        [% IF whole.value.other.type.lower == "article" %]
38
                            <option value="article" selected="selected">Journal article</option>
39
                        [% ELSE %]
40
                            <option value="article">Journal article</option>
41
                        [% END %]
42
                        [% IF whole.value.other.type.lower == "thesis" %]
43
                            <option value="thesis" selected="selected">Thesis</option>
44
                        [% ELSE %]
45
                            <option value="thesis">Thesis</option>
46
                        [% END %]
47
                        [% IF whole.value.other.type.lower == "conference" %]
48
                            <option value="conference" selected="selected">Conference</option>
49
                        [% ELSE %]
50
                            <option value="conference">Conference</option>
51
                        [% END %]
52
                        [% IF whole.value.other.type.lower == "dvd" %]
53
                            <option value="dvd" selected="selected">DVD</option>
54
                        [% ELSE %]
55
                            <option value="dvd">DVD</option>
56
                        [% END %]
57
                        [% IF whole.value.other.type.lower == "other" %]
58
                            <option value="other" selected="selected">Other</option>
59
                        [% ELSE %]
60
                            <option value="other">Other</option>
61
                        [% END %]
62
                        [% IF whole.value.other.type.lower == "resource" %]
63
                            <option value="resource" selected="selected">Generic resource</option>
64
                        [% ELSE %]
65
                            <option value="resource">Generic resource</option>
66
                        [% END %]
67
                    </select>
68
                </li>
69
            </ol>
70
        </fieldset>
71
        [% type = whole.value.other.type %]
72
        [% IF type %]
73
            [% INCLUDE "${cwd}/shared-includes/forms/${type}.inc" %]
74
        [% END %]
75
        [% INCLUDE "${cwd}/shared-includes/custom_fields.inc" %]
76
        <fieldset class="action">
77
            <input id="ill-submit" class="btn btn-primary" type="submit" value="Update" />
78
            <a class="cancel" href="/cgi-bin/koha/ill/ill-requests.pl">Cancel</a>
79
        </fieldset>
80
        <input type="hidden" name="illrequest_id" value="[% whole.value.other.illrequest_id | html %]" />
81
        <input type="hidden" name="op" value="cud-edititem" />
82
        <input type="hidden" name="stage" value="form" />
83
        <input type="hidden" name="backend" value="Standard" />
84
    </form>
85
    [% BLOCK backend_jsinclude %]
86
        <script>
87
            // <![CDATA[]
88
            [% INCLUDE "${cwd}/shared-includes/shared.js" %]
89
            // ]]>
90
        </script>
91
    [% END %]
92
[% ELSE %]
93
    <p>Unknown stage. This should not have happened. </p>
94
[% END %]
(-)a/Koha/ILL/Backend/shared-includes/custom_fields.inc (-13 / +11 lines)
Lines 7-36 Link Here
7
        [% FOREACH key IN keys %]
7
        [% FOREACH key IN keys %]
8
            <li class="form-horizontal">
8
            <li class="form-horizontal">
9
                [% IF opac %]
9
                [% IF opac %]
10
                    <input type="text" placeholder="key" class="form-control input-fluid custom-field-input custom-name" name="custom_key" value="[% key | html %]">
10
                    <input type="text" placeholder="key" class="form-control input-fluid custom-field-input custom-name" name="custom_key" value="[% key | html %]" />
11
                    <input type="text" placeholder="value" class="form-control input-fluid custom-field-input" name="custom_value" id="custom-value" value="[% values.$i | html %]">
11
                    <input type="text" placeholder="value" class="form-control input-fluid custom-field-input" name="custom_value" id="custom-value" value="[% values.$i | html %]" />
12
                [% ELSE %]
12
                [% ELSE %]
13
                    <input type="text" placeholder="key" class="custom-name" name="custom_key" value="[% key | html %]">
13
                    <input type="text" placeholder="key" class="custom-name" name="custom_key" value="[% key | html %]" />
14
                    <input type="text" placeholder="value" name="custom_value" id="custom-value" value="[% values.$i | html %]">
14
                    <input type="text" placeholder="value" name="custom_value" id="custom-value" value="[% values.$i | html %]" />
15
                [% END %]
15
                [% END %]
16
                <button value="[% i | html %]" name="custom_delete" type="submit" class="btn btn-danger btn-sm delete-new-field">
16
                <button value="[% i | html %]" name="custom_delete" type="submit" class="btn btn-danger btn-sm delete-new-field"> <span class="fa fa-trash"></span> Delete </button>
17
                    <span class="fa fa-trash"></span> Delete
18
                </button>
19
            </li>
17
            </li>
20
            [% i = i + 1 %]
18
            [% i = i + 1 %]
21
        [% END %]
19
        [% END %]
22
    </ol>
20
    </ol>
23
    <div id="custom-warning" style="display:none;margin:1em;" class="error required"></div>
21
    <div id="custom-warning" style="display:none;margin:1em;" class="error required"></div>
24
        <button type="button" id="add-new-fields" class="btn btn-default">
22
    <button type="button" id="add-new-fields" class="btn btn-default">
25
        <span class="fa fa-plus"></span>
23
        <span class="fa fa-plus"></span>
26
        Add new field
24
        Add new field
27
    </button>
25
    </button>
28
</fieldset>
26
</fieldset>
29
27
30
<style>
28
<style>
31
.custom-field-input {
29
    .custom-field-input {
32
    width: 25%;
30
        width: 25%;
33
    display: inline-block;
31
        display: inline-block;
34
    margin-left: 0.5em;
32
        margin-left: 0.5em;
35
}
33
    }
36
</style>
34
</style>
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/ill/backends/Standard/migrate.inc (+117 lines)
Line 0 Link Here
1
[% IF whole.error %]
2
    [% IF whole.status == 'missing_identifier' %]
3
        <p><em>Please note:</em> Mandatory field Identifier is missing.</p>
4
    [% ELSIF whole.status == 'missing_branch' %]
5
        <p><em>Please note:</em> Library is a mandatory field.</p>
6
    [% ELSIF whole.status == 'invalid_borrower' %]
7
        <p><em>Please note:</em> The patrons details you entered are invalid.</p>
8
    [% ELSIF whole.status == 'invalid_branch' %]
9
        <p><em>Please note:</em> The library you chose is invalid.</p>
10
    [% ELSE %]
11
        <p>Unhandled error</p>
12
    [% END %]
13
[% END %]
14
15
[% IF whole.stage == "form" %]
16
    <h2>Migrating an ILL request</h2>
17
    <form id="standard_migrate_form" method="POST" action="">
18
        <fieldset class="rows">
19
            <legend>General details</legend>
20
            <ol id="general-standard-fields">
21
                <li>
22
                    <label class="required" for="type">Type:</label>
23
                    <select class="form-select" name="type" id="type">
24
                        <option value=""></option>
25
                        [% IF whole.value.other.type.lower == "book" %]
26
                            <option value="book" selected="selected">Book</option>
27
                        [% ELSE %]
28
                            <option value="book">Book</option>
29
                        [% END %]
30
                        [% IF whole.value.other.type.lower == "chapter" %]
31
                            <option value="chapter" selected="selected">Chapter</option>
32
                        [% ELSE %]
33
                            <option value="chapter">Chapter</option>
34
                        [% END %]
35
                        [% IF whole.value.other.type.lower == "journal" %]
36
                            <option value="journal" selected="selected">Journal</option>
37
                        [% ELSE %]
38
                            <option value="journal">Journal</option>
39
                        [% END %]
40
                        [% IF whole.value.other.type.lower == "article" %]
41
                            <option value="article" selected="selected">Journal article</option>
42
                        [% ELSE %]
43
                            <option value="article">Journal article</option>
44
                        [% END %]
45
                        [% IF whole.value.other.type.lower == "thesis" %]
46
                            <option value="thesis" selected="selected">Thesis</option>
47
                        [% ELSE %]
48
                            <option value="thesis">Thesis</option>
49
                        [% END %]
50
                        [% IF whole.value.other.type.lower == "conference" %]
51
                            <option value="conference" selected="selected">Conference</option>
52
                        [% ELSE %]
53
                            <option value="conference">Conference</option>
54
                        [% END %]
55
                        [% IF whole.value.other.type.lower == "dvd" %]
56
                            <option value="dvd" selected="selected">DVD/option> </option>
57
                        [% ELSE %]
58
                            <option value="dvd">DVD</option>
59
                        [% END %]
60
                        [% IF whole.value.other.type.lower == "other" %]
61
                            <option value="other" selected="selected">Other</option>
62
                        [% ELSE %]
63
                            <option value="other">Other</option>
64
                        [% END %]
65
                        [% IF whole.value.other.type.lower == "resource" %]
66
                            <option value="resource" selected="selected">Generic resource</option>
67
                        [% ELSE %]
68
                            <option value="resource">Generic resource</option>
69
                        [% END %]
70
                    </select>
71
                    [% IF required %]
72
                        <div class="required_label required">Required</div>
73
                    [% END %]
74
                </li>
75
            </ol>
76
        </fieldset>
77
        [% cwd = whole.cwd %]
78
        [% type = whole.value.other.type %]
79
        [% IF type %]
80
            [% INCLUDE "${cwd}/shared-includes/forms/${type}.inc" %]
81
        [% END %]
82
        [% INCLUDE "${cwd}/shared-includes/custom_fields.inc" %]
83
        <fieldset class="rows">
84
            <legend>Patron options</legend>
85
            <ol>
86
                <li>
87
                    <label class="required" for="cardnumber"> Card number or surname: </label>
88
                    <input type="text" name="cardnumber" id="cardnumber" type="text" value="" />
89
                    <div class="required_label required">Required</div>
90
                </li>
91
                <li>
92
                    <label class="required" for="branchcode">Destination library:</label>xxx
93
                    <select id="branchcode" name="branchcode">
94
                        <option value=""></option>
95
                        [% FOREACH branch IN branches %]
96
                            <option value="[% branch.branchcode | html %]"> [% branch.branchname | html %] </option>
97
                        [% END %]
98
                    </select>
99
                    <div class="required_label required">Required</div>
100
                </li>
101
            </ol>
102
        </fieldset>
103
        <fieldset class="action">
104
            <input id="ill-submit" type="submit" value="Migrate" />
105
            <a class="cancel" href="/cgi-bin/koha/ill/ill-requests.pl">Cancel</a>
106
        </fieldset>
107
    </form>
108
    [% BLOCK backend_jsinclude %]
109
        <script>
110
            // <![CDATA[]
111
            [% INCLUDE "${cwd}/shared-includes/shared.js" %]
112
            // ]]>
113
        </script>
114
    [% END %]
115
[% ELSE %]
116
    <p>Unknown stage. This should not have happened. </p>
117
[% END %]
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/ill/backends/Standard/create.inc (+141 lines)
Line 0 Link Here
1
[% USE Koha %]
2
[% PROCESS 'i18n.inc' %]
3
[% cwd = whole.cwd %]
4
[% PROCESS "${cwd}/shared-includes/form_input_helpers.inc" %]
5
[% IF whole.error %]
6
    [% IF whole.status == 'missing_identifier' %]
7
        <div class="alert alert-warning"> <strong>Please note:</strong> Mandatory field Identifier is missing. </div>
8
    [% ELSIF whole.status == 'missing_type' %]
9
        <div class="alert alert-warning"> <strong>Please note:</strong> Type is a mandatory field. </div>
10
    [% ELSIF whole.status == 'missing_unauth_data' %]
11
        <div class="alert alert-warning"> <strong>Please note:</strong> Patron data (first name, last name and e-mail) are mandatory fields. </div>
12
    [% ELSIF whole.status == 'missing_branch' %]
13
        <div class="alert alert-warning"> <strong>Please note:</strong> Library is a mandatory field. </div>
14
    [% ELSIF whole.status == 'invalid_borrower' %]
15
        <div class="alert alert-warning"> <strong>Please note:</strong> The patron details you entered are invalid. </div>
16
    [% ELSIF whole.status == 'invalid_branch' %]
17
        <div class="alert alert-warning"> <strong>Please note:</strong> The library you chose is invalid. </div>
18
    [% ELSIF whole.status == 'failed_captcha' %]
19
        <div class="alert alert-warning">You typed in the wrong characters in the box before submitting. Please try again.</div>
20
    [% ELSE %]
21
        <p>Unhandled error</p>
22
    [% END %]
23
[% END %]
24
[% SET opac = whole.value.other.opac %]
25
26
[% IF whole.stage == "form" %]
27
    <h2>Create an ILL request</h2>
28
    <form id="create_form" method="POST" action="">
29
        [% INCLUDE 'csrf-token.inc' %]
30
        <fieldset class="rows">
31
            <legend>Patron options</legend>
32
            <ol>
33
                [% IF unauthenticated_ill && !logged_in_user %]
34
                    [% PROCESS ill_text_input_field required = 1 id = 'unauthenticated_first_name' label = t('First name') value = whole.value.other.unauthenticated_first_name %]
35
                    [% PROCESS ill_text_input_field required = 1 id = 'unauthenticated_last_name' label = t('Last name') value = whole.value.other.unauthenticated_last_name %]
36
                    [% PROCESS ill_text_input_field required = 1 id = 'unauthenticated_email' label = t('E-mail address') value = whole.value.other.unauthenticated_email %]
37
                [% END %]
38
                [% WRAPPER ill_select_field required = 1 id = 'branchcode' label = t('Destination library') %]
39
                    <option value=""></option>
40
                    [% FOREACH branch IN branches %]
41
                        [% IF whole.value.other.branchcode && branch.branchcode == whole.value.other.branchcode %]
42
                            <option value="[% branch.branchcode | html %]" selected="selected"> [% branch.branchname | html %] </option>
43
                        [% ELSE %]
44
                            <option value="[% branch.branchcode | html %]"> [% branch.branchname | html %] </option>
45
                        [% END %]
46
                    [% END %]
47
                [% END #ill_select_field %]
48
            </ol>
49
        </fieldset>
50
        <fieldset class="rows">
51
            <legend>General details</legend>
52
            <ol id="general-standard-fields">
53
                [% WRAPPER ill_select_field required = 1 id = 'type' label = t('Type') %]
54
                    <option value=""></option>
55
                    [% IF whole.value.other.type.lower == "book" %]
56
                        <option value="book" selected="selected">Book</option>
57
                    [% ELSE %]
58
                        <option value="book">Book</option>
59
                    [% END %]
60
                    [% IF whole.value.other.type.lower == "chapter" %]
61
                        <option value="chapter" selected="selected">Chapter</option>
62
                    [% ELSE %]
63
                        <option value="chapter">Chapter</option>
64
                    [% END %]
65
                    [% IF whole.value.other.type.lower == "journal" %]
66
                        <option value="journal" selected="selected">Journal</option>
67
                    [% ELSE %]
68
                        <option value="journal">Journal</option>
69
                    [% END %]
70
                    [% IF whole.value.other.type.lower == "article" %]
71
                        <option value="article" selected="selected">Journal article</option>
72
                    [% ELSE %]
73
                        <option value="article">Journal article</option>
74
                    [% END %]
75
                    [% IF whole.value.other.type.lower == "thesis" %]
76
                        <option value="thesis" selected="selected">Thesis</option>
77
                    [% ELSE %]
78
                        <option value="thesis">Thesis</option>
79
                    [% END %]
80
                    [% IF whole.value.other.type.lower == "conference" %]
81
                        <option value="conference" selected="selected">Conference</option>
82
                    [% ELSE %]
83
                        <option value="conference">Conference</option>
84
                    [% END %]
85
                    [% IF whole.value.other.type.lower == "dvd" %]
86
                        <option value="dvd" selected="selected">DVD</option>
87
                    [% ELSE %]
88
                        <option value="dvd">DVD</option>
89
                    [% END %]
90
                    [% IF whole.value.other.type.lower == "other" %]
91
                        <option value="other" selected="selected">Other</option>
92
                    [% ELSE %]
93
                        <option value="other">Other</option>
94
                    [% END %]
95
                    [% IF whole.value.other.type.lower == "resource" %]
96
                        <option value="resource" selected="selected">Generic resource</option>
97
                    [% ELSE %]
98
                        <option value="resource">Generic resource</option>
99
                    [% END %]
100
                [% END #ill_select_field %]
101
            </ol>
102
        </fieldset>
103
        [% type = whole.value.other.type %]
104
        [% IF type %]
105
            [% INCLUDE "${cwd}/shared-includes/forms/${type}.inc" %]
106
        [% END %]
107
        [% INCLUDE "${cwd}/shared-includes/custom_fields.inc" %]
108
        [% IF whole.value.other.type && unauthenticated_ill && !logged_in_user %]
109
            <fieldset class="rows" id="illrequest_captcha">
110
                <legend>Verification</legend>
111
                <ol>
112
                    <li>
113
                        <label for="captcha" class="required">Verification:</label>
114
115
                        <input type="text" name="captcha" id="captcha" class="form-control input-fluid" style="text-transform: uppercase;" />
116
                        <div class="required_label required">Required</div>
117
                        <input type="hidden" name="captcha_digest" value="[% captcha_digest | html %]" />
118
119
                        <span class="hint">Please type the following characters into the preceding box: <strong>[% captcha | html %]</strong></span>
120
                    </li>
121
                </ol>
122
            </fieldset>
123
        [% END %]
124
        <fieldset class="action">
125
            <input id="ill-submit" class="btn btn-primary" type="submit" value="Create" />
126
            <a class="cancel" href="/cgi-bin/koha/opac-illrequests.pl">Cancel</a>
127
        </fieldset>
128
        <input type="hidden" name="op" value="cud-create" />
129
        <input type="hidden" name="stage" value="form" />
130
        <input type="hidden" name="backend" value="Standard" />
131
    </form>
132
[% ELSE %]
133
    <p>Unknown stage. This should not have happened. </p>
134
[% END %]
135
[% BLOCK backend_jsinclude %]
136
    <script>
137
        // <![CDATA[]
138
        [% INCLUDE "${cwd}/shared-includes/shared.js" %]
139
        // ]]>
140
    </script>
141
[% END %]
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/ill/backends/Standard/inc/custom_fields.inc (+34 lines)
Line 0 Link Here
1
<fieldset class="rows">
2
    <legend>Custom fields</legend>
3
    <ol id="standard-fields">
4
        [% keys = whole.value.other.custom_key.split('\0') %]
5
        [% values = whole.value.other.custom_value.split('\0') %]
6
        [% i = 0 %]
7
        [% FOREACH key IN keys %]
8
            <li class="form-horizontal">
9
                [% IF opac %]
10
                    <input type="text" placeholder="key" class="form-control input-fluid custom-field-input custom-name" name="custom_key" value="[% key | html %]" />
11
                    <input type="text" placeholder="value" class="form-control input-fluid custom-field-input" name="custom_value" id="custom-value" value="[% values.$i | html %]" />
12
                [% ELSE %]
13
                    <input type="text" placeholder="key" class="custom-name" name="custom_key" value="[% key | html %]" />
14
                    <input type="text" placeholder="value" name="custom_value" id="custom-value" value="[% values.$i | html %]" />
15
                [% END %]
16
                <button value="[% i | html %]" name="custom_delete" type="submit" class="btn btn-danger btn-sm delete-new-field"> <span class="fa fa-trash"></span> Delete </button>
17
            </li>
18
            [% i = i + 1 %]
19
        [% END %]
20
    </ol>
21
    <div id="custom-warning" style="display:none;margin:1em;" class="error required"></div>
22
    <button type="button" id="add-new-fields" class="btn btn-default">
23
        <span class="fa fa-plus"></span>
24
        Add new field
25
    </button>
26
</fieldset>
27
28
<style>
29
    .custom-field-input {
30
        width: 25%;
31
        display: inline-block;
32
        margin-left: 0.5em;
33
    }
34
</style>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/ill/backends/Standard/inc/form_input_helpers.inc (+52 lines)
Line 0 Link Here
1
[% BLOCK ill_text_input_field %]
2
    <li>
3
        <label for="[% id | html %]">[% label | html %]:</label>
4
        [% IF opac %]
5
            <input class="form-control input-fluid" type="text" name="[% id | html %]" id="[% id | html%]" value="[% value | html %]" />
6
        [% ELSE %]
7
            <input type="text" name="[% id | html %]" id="[% id | html%]" value="[% value | html %]" />
8
        [% END %]
9
        [% IF required %]
10
            <div class="required_label required">Required</div>
11
        [% END %]
12
        [% SET required = 0 %]
13
    </li>
14
[% END %]
15
16
[% BLOCK ill_select_field %]
17
    <li>
18
        <label for="[% id | html %]">[% label | html %]:</label>
19
        [% IF opac %]
20
            <select class="form-select input-fluid" name="[% id | html %]" id="[% id | html %]">
21
        [% ELSE %]
22
            <select name="[% id | html %]" id="[% id | html %]">
23
        [% END %]
24
            [% content | $raw %]
25
        </select>
26
        [% IF required %]
27
            <div class="required_label required">Required</div>
28
        [% END %]
29
        [% SET required = 0 %]
30
    </li>
31
[% END %]
32
33
[% BLOCK book_text_input_fields %]
34
  [% PROCESS ill_text_input_field id = 'title' label = t('Title') value = whole.value.other.title %]
35
  [% PROCESS ill_text_input_field id = 'author' label = t('Author') value = whole.value.other.author %]
36
  [% PROCESS ill_text_input_field id = 'editor' label = t('Editor') value = whole.value.other.editor %]
37
  [% PROCESS ill_text_input_field id = 'publisher' label = t('Publisher') value = whole.value.other.publisher %]
38
  [% PROCESS ill_text_input_field id = 'published_place' label = t('Place of publication') value = whole.value.other.published_place %]
39
  [% PROCESS ill_text_input_field id = 'year' label = t('Year') value = whole.value.other.year %]
40
  [% PROCESS ill_text_input_field id = 'part_edition' label = t('Part / Edition') value = whole.value.other.part_edition %]
41
  [% PROCESS ill_text_input_field id = 'volume' label = t('Volume') value = whole.value.other.volume %]
42
  [% PROCESS ill_text_input_field id = 'isbn' label = t('ISBN') value = whole.value.other.isbn %]
43
  [% PROCESS ill_text_input_field id = 'doi' label = t('DOI') value = whole.value.other.doi %]
44
[% END %]
45
46
[% BLOCK journal_text_input_fields %]
47
  [% PROCESS ill_text_input_field id = 'title' label = t('Title') value = whole.value.other.title %]
48
  [% PROCESS ill_text_input_field id = 'volume' label = t('Volume') value = whole.value.other.volume %]
49
  [% PROCESS ill_text_input_field id = 'issue' label = t('Issue number') value = whole.value.other.issue %]
50
  [% PROCESS ill_text_input_field id = 'year' label = t('Year') value = whole.value.other.year %]
51
  [% PROCESS ill_text_input_field id = 'issn' label = t('ISSN') value = whole.value.other.issn %]
52
[% END %]
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/ill/backends/Standard/inc/forms/article.inc (+16 lines)
Line 0 Link Here
1
<fieldset id="journal-standard-fieldset" class="rows">
2
    <legend>Journal details</legend>
3
    <ol id="journal-standard-fields">
4
        [% PROCESS journal_text_input_fields %]
5
    </ol>
6
</fieldset>
7
<fieldset id="article-standard-fieldset" class="rows">
8
    <legend>Article details</legend>
9
    <ol id="article-standard-fields">
10
        [% PROCESS ill_text_input_field id = 'article_title' label = t('Article title') value = whole.value.other.article_title %]
11
        [% PROCESS ill_text_input_field id = 'article_author' label = t('Article author') value = whole.value.other.article_author %]
12
        [% PROCESS ill_text_input_field id = 'published_date' label = t('Publication date') value = whole.value.other.published_date %]
13
        [% PROCESS ill_text_input_field id = 'pages' label = t('Pages') value = whole.value.other.pages %]
14
        [% PROCESS ill_text_input_field id = 'doi' label = t('DOI') value = whole.value.other.doi %]
15
    </ol>
16
</fieldset>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/ill/backends/Standard/inc/forms/book.inc (+6 lines)
Line 0 Link Here
1
<fieldset id="book-standard-fieldset" class="rows">
2
    <legend>Book details</legend>
3
    <ol id="publication-standard-fields">
4
        [% PROCESS book_text_input_fields %]
5
    </ol>
6
</fieldset>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/ill/backends/Standard/inc/forms/chapter.inc (+14 lines)
Line 0 Link Here
1
<fieldset id="book-standard-fieldset" class="rows">
2
    <legend>Book details</legend>
3
    <ol id="publication-standard-fields">
4
        [% PROCESS book_text_input_fields %]
5
    </ol>
6
</fieldset>
7
<fieldset id="chapter-standard-fieldset" class="rows">
8
    <legend>Chapter details</legend>
9
    <ol id="chapter-standard-fields">
10
        [% PROCESS ill_text_input_field id = 'chapter_author' label = t('Author') value = whole.value.other.chapter_author %]
11
        [% PROCESS ill_text_input_field id = 'chapter' label = t('Chapter') value = whole.value.other.chapter %]
12
        [% PROCESS ill_text_input_field id = 'pages' label = t('Pages') value = whole.value.other.pages %]
13
    </ol>
14
</fieldset>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/ill/backends/Standard/inc/forms/conference.inc (+16 lines)
Line 0 Link Here
1
<fieldset id="conference-standard-fieldset" class="rows">
2
    <legend>Conference details</legend>
3
    <ol id="conference-standard-fields">
4
        [% PROCESS ill_text_input_field id = 'title' label = t('Conference title') value = whole.value.other.title %]
5
        [% PROCESS ill_text_input_field id = 'publication' label = t('Publication') value = whole.value.other.publication %]
6
        [% PROCESS ill_text_input_field id = 'conference_date' label = t('Conference date') value = whole.value.other.conference_date %]
7
        [% PROCESS ill_text_input_field id = 'venue' label = t('Venue') value = whole.value.other.venue %]
8
        [% PROCESS ill_text_input_field id = 'sponsor' label = t('Sponsor') value = whole.value.other.sponsor %]
9
        [% PROCESS ill_text_input_field id = 'volume' label = t('Volume') value = whole.value.other.volume %]
10
        [% PROCESS ill_text_input_field id = 'isbn' label = t('ISBN') value = whole.value.other.isbn %]
11
        [% PROCESS ill_text_input_field id = 'issn' label = t('ISSN') value = whole.value.other.issn %]
12
        [% PROCESS ill_text_input_field id = 'part_edition' label = t('Part') value = whole.value.other.part_edition %]
13
        [% PROCESS ill_text_input_field id = 'paper_title' label = t('Paper title') value = whole.value.other.paper_title %]
14
        [% PROCESS ill_text_input_field id = 'paper_author' label = t('Paper author') value = whole.value.other.paper_author %]
15
    </ol>
16
</fieldset>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/ill/backends/Standard/inc/forms/dvd.inc (+12 lines)
Line 0 Link Here
1
<fieldset id="dvd-standard-fieldset" class="rows">
2
    <legend>DVD details</legend>
3
    <ol id="dvd-standard-fields">
4
        [% PROCESS ill_text_input_field id = 'title' label = t('Title') value = whole.value.other.title %]
5
        [% PROCESS ill_text_input_field id = 'author' label = t('Author') value = whole.value.other.author %]
6
        [% PROCESS ill_text_input_field id = 'studio' label = t('Studio') value = whole.value.other.studio %]
7
        [% PROCESS ill_text_input_field id = 'genre' label = t('Genre') value = whole.value.other.genre %]
8
        [% PROCESS ill_text_input_field id = 'year' label = t('Year') value = whole.value.other.year %]
9
        [% PROCESS ill_text_input_field id = 'format' label = t('Format') value = whole.value.other.format %]
10
        [% PROCESS ill_text_input_field id = 'language' label = t('Language') value = whole.value.other.language %]
11
    </ol>
12
</fieldset>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/ill/backends/Standard/inc/forms/journal.inc (+7 lines)
Line 0 Link Here
1
<fieldset id="journal-standard-fieldset" class="rows">
2
    <legend>Journal details</legend>
3
    <ol id="journal-standard-fields">
4
        [% PROCESS journal_text_input_fields %]
5
        [% PROCESS ill_text_input_field id = 'doi' label = t('DOI') value = whole.value.other.doi %]
6
    </ol>
7
</fieldset>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/ill/backends/Standard/inc/forms/resource.inc (+17 lines)
Line 0 Link Here
1
<fieldset id="resource-standard-fieldset" class="rows">
2
    <legend>Generic resource details</legend>
3
    <ol id="resource-standard-fields">
4
        [% PROCESS ill_text_input_field id = 'title' label = t('Title') value = whole.value.other.title %]
5
        [% PROCESS ill_text_input_field id = 'author' label = t('Author') value = whole.value.other.author %]
6
        [% PROCESS ill_text_input_field id = 'editor' label = t('Editor') value = whole.value.other.editor %]
7
        [% PROCESS ill_text_input_field id = 'publisher' label = t('Publisher') value = whole.value.other.publisher %]
8
        [% PROCESS ill_text_input_field id = 'published_place' label = t('Place of publication') value = whole.value.other.published_place %]
9
        [% PROCESS ill_text_input_field id = 'year' label = t('Year') value = whole.value.other.year %]
10
        [% PROCESS ill_text_input_field id = 'part_edition' label = t('Part / Edition') value = whole.value.other.part_edition %]
11
        [% PROCESS ill_text_input_field id = 'volume' label = t('Volume') value = whole.value.other.volume %]
12
        [% PROCESS ill_text_input_field id = 'pages' label = t('Pages') value = whole.value.other.pages %]
13
        [% PROCESS ill_text_input_field id = 'isbn' label = t('ISBN') value = whole.value.other.isbn %]
14
        [% PROCESS ill_text_input_field id = 'issn' label = t('ISSN') value = whole.value.other.issn %]
15
        [% PROCESS ill_text_input_field id = 'doi' label = t('DOI') value = whole.value.other.doi %]
16
    </ol>
17
</fieldset>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/ill/backends/Standard/inc/forms/thesis.inc (+10 lines)
Line 0 Link Here
1
<fieldset id="thesis-standard-fieldset" class="rows">
2
    <legend>Thesis details</legend>
3
    <ol id="thesis-standard-fields">
4
        [% PROCESS ill_text_input_field id = 'title' label = t('Title') value = whole.value.other.title %]
5
        [% PROCESS ill_text_input_field id = 'author' label = t('Author') value = whole.value.other.author %]
6
        [% PROCESS ill_text_input_field id = 'institution' label = t('Institution') value = whole.value.other.institution %]
7
        [% PROCESS ill_text_input_field id = 'published_date' label = t('Publication date') value = whole.value.other.published_date %]
8
        [% PROCESS ill_text_input_field id = 'doi' label = t('DOI') value = whole.value.other.doi %]
9
    </ol>
10
</fieldset>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/ill/backends/Standard/inc/shared.js (-1 / +44 lines)
Line 0 Link Here
0
- 
1
var core = [ [% whole.core %] ];
2
var opac = [% opac || 0 %];
3
document.addEventListener('DOMContentLoaded', function() {
4
    $('#add-new-fields').click(function(e) {
5
        e.preventDefault();
6
        var row = '<li class="form-horizontal">' +
7
            '<input type="text" class="custom-name ' +
8
            ( opac ? 'form-control input-fluid custom-field-input' : '') +
9
            '" name="custom_key" placeholder="'+__('key')+'">' +
10
            ' ' +
11
            '<input type="text" id="custom-value" name="custom_value" class="' +
12
            ( opac ? 'form-control input-fluid custom-field-input' : '') +'" placeholder="'+__('value')+'"> ' +
13
            '<button type="button" class="btn btn-danger btn-sm ' +
14
            'delete-new-field">' +
15
            '<span class="fa fa-trash-can"></span> ' +
16
            __('Delete') +
17
            '</button></li>';
18
        $('#standard-fields').append(row);
19
    });
20
    $('#standard-fields').on('click', '.delete-new-field',
21
        function(event) {
22
            event.preventDefault();
23
            $(event.target).parent().remove();
24
        }
25
    );
26
    $('#type').change(function() {
27
        $('#create_form').prepend(
28
            '<input type="hidden" name="change_type" value="1" />'
29
        );
30
        $('#create_form').submit();
31
    });
32
    $('#standard-fields').on('keyup', '.custom-name', function() {
33
        var val = $(this).val();
34
        if (core.indexOf(val.toLowerCase()) > -1) {
35
            $('#custom-warning').text(__("The name '%s' is not permitted").format(val)).show();
36
            $('#ill-submit').attr('disabled', true);
37
            $('#add-new-fields').attr('disabled', true);
38
        } else {
39
            $('#custom-warning').hide();
40
            $('#ill-submit').attr('disabled', false);
41
            $('#add-new-fields').attr('disabled', false);
42
        }
43
    });
44
});

Return to bug 38340