Lines 22-44
Link Here
|
22 |
[% END %] |
22 |
[% END %] |
23 |
[% END %] |
23 |
[% END %] |
24 |
|
24 |
|
25 |
[% IF acct_form || delete_confirm %] |
25 |
[% IF op == 'add_form' %] |
26 |
[% WRAPPER breadcrumb_item %] |
26 |
[% WRAPPER breadcrumb_item %] |
27 |
<a href="/cgi-bin/koha/admin/marc_order_accounts.pl">MARC order accounts</a> |
27 |
<a href="/cgi-bin/koha/admin/marc_order_accounts.pl">MARC order accounts</a> |
28 |
[% END %] |
28 |
[% END %] |
|
|
29 |
[% WRAPPER breadcrumb_item bc_active = 1 %] |
30 |
[% IF account.id %] |
31 |
[% tx("Modify account '{account}'", { account = account.id }) | html %] |
32 |
[% ELSE %] |
33 |
<span>New account</span> |
34 |
[% END %] |
35 |
[% END %] |
36 |
[% ELSIF op == 'delete_confirm' %] |
37 |
[% WRAPPER breadcrumb_item %] |
38 |
<a href="/cgi-bin/koha/admin/marc_order_accounts.pl">MARC order accounts</a> |
39 |
[% END %] |
40 |
[% WRAPPER breadcrumb_item bc_active = 1 %] |
41 |
[% tx("Confirm deletion of account '{account}'", { account = account.id }) | html %] |
42 |
[% END %] |
29 |
[% ELSE %] |
43 |
[% ELSE %] |
30 |
[% WRAPPER breadcrumb_item bc_active= 1 %] |
44 |
[% WRAPPER breadcrumb_item bc_active = 1 %] |
31 |
<span>MARC order accounts</span> |
45 |
<span>MARC order accounts</span> |
32 |
[% END %] |
46 |
[% END %] |
33 |
[% END %] |
47 |
[% END #/IF op = add_form %] |
34 |
[% END #/ WRAPPER breadcrumbs %] |
48 |
[% END #/ WRAPPER breadcrumbs %] |
35 |
[% END #/ WRAPPER sub-header.inc %] |
49 |
[% END #/ WRAPPER sub-header.inc %] |
36 |
|
50 |
|
37 |
[% WRAPPER 'main-container.inc' aside='admin-menu' %] |
51 |
[% WRAPPER 'main-container.inc' aside='admin-menu' %] |
|
|
52 |
[% FOR m IN messages %] |
53 |
<div class="alert alert-[% m.type | html %]"> |
54 |
[% SWITCH m.code %] |
55 |
[% CASE 'error_on_update' %] |
56 |
<span>An error occurred when updating this account. Perhaps it already exists.</span> |
57 |
[% CASE 'error_on_insert' %] |
58 |
<span>An error occurred when adding this account. The account ID might already exist.</span> |
59 |
[% CASE 'error_on_delete' %] |
60 |
<span>An error occurred when deleting this account. Check the logs for details.</span> |
61 |
[% CASE 'success_on_update' %] |
62 |
<span>Account updated successfully.</span> |
63 |
[% CASE 'success_on_insert' %] |
64 |
<span>Account added successfully.</span> |
65 |
[% CASE 'success_on_delete' %] |
66 |
<span>Account deleted successfully.</span> |
67 |
[% CASE 'already_exists' %] |
68 |
<span>This account already exists.</span> |
69 |
[% CASE %] |
70 |
<span>[% m.code | html %]</span> |
71 |
[% END %] |
72 |
</div> |
73 |
[% END %] |
38 |
|
74 |
|
39 |
[% IF display %] |
75 |
[% IF op == 'list' %] |
40 |
<div id="toolbar" class="btn-toolbar"> |
76 |
<div id="toolbar" class="btn-toolbar"> |
41 |
<a class="btn btn-default" id="newmarcorderacct" href="/cgi-bin/koha/admin/marc_order_accounts.pl?op=acct_form"> |
77 |
<a class="btn btn-default" id="newmarcorderacct" href="/cgi-bin/koha/admin/marc_order_accounts.pl?op=add_form"> |
42 |
<i class="fa fa-plus"></i> |
78 |
<i class="fa fa-plus"></i> |
43 |
New account |
79 |
New account |
44 |
</a> |
80 |
</a> |
Lines 63-70
Link Here
|
63 |
<td>[% account.description | html %]</td> |
99 |
<td>[% account.description | html %]</td> |
64 |
<td>[% account.download_directory | html %]</td> |
100 |
<td>[% account.download_directory | html %]</td> |
65 |
<td class="actions"> |
101 |
<td class="actions"> |
66 |
<a class="btn btn-default btn-xs" href="/cgi-bin/koha/admin/marc_order_accounts.pl?op=acct_form&id=[% account.id | html %]"><i class="fa fa-pencil-alt"></i> Edit</a> |
102 |
<a class="btn btn-default btn-xs" href="/cgi-bin/koha/admin/marc_order_accounts.pl?op=add_form&id=[% account.id | html %]"><i class="fa fa-pencil-alt"></i> Edit</a> |
67 |
<a class="btn btn-default btn-xs" href="/cgi-bin/koha/admin/marc_order_accounts.pl?op=delete_acct&id=[% account.id | html %]"><i class="fa fa-trash-can"></i> Delete</a> |
103 |
<a class="btn btn-default btn-xs" href="/cgi-bin/koha/admin/marc_order_accounts.pl?op=delete_confirm&id=[% account.id | html %]"><i class="fa fa-trash-can"></i> Delete</a> |
68 |
</td> |
104 |
</td> |
69 |
</tr> |
105 |
</tr> |
70 |
[% END %] |
106 |
[% END %] |
Lines 74-80
Link Here
|
74 |
<div class="dialog message"> There are no MARC order accounts. </div> |
110 |
<div class="dialog message"> There are no MARC order accounts. </div> |
75 |
[% END %] |
111 |
[% END %] |
76 |
[% END %] |
112 |
[% END %] |
77 |
[% IF acct_form %] |
113 |
[% IF op == 'add_form' %] |
78 |
<h1> |
114 |
<h1> |
79 |
[% IF account %] |
115 |
[% IF account %] |
80 |
Modify account |
116 |
Modify account |
Lines 257-264
Link Here
|
257 |
</fieldset> |
293 |
</fieldset> |
258 |
</form> |
294 |
</form> |
259 |
[% END %] |
295 |
[% END %] |
260 |
[% IF delete_acct %] |
296 |
[% IF op == 'delete_confirm' %] |
261 |
<div class="dialog alert"> |
297 |
<div class="alert alert-warning"> |
262 |
<h1>Delete this account?</h1> |
298 |
<h1>Delete this account?</h1> |
263 |
<table> |
299 |
<table> |
264 |
<tr> |
300 |
<tr> |
Lines 272-278
Link Here
|
272 |
</table> |
308 |
</table> |
273 |
<form action="/cgi-bin/koha/admin/marc_order_accounts.pl" method="post"> |
309 |
<form action="/cgi-bin/koha/admin/marc_order_accounts.pl" method="post"> |
274 |
[% INCLUDE 'csrf-token.inc' %] |
310 |
[% INCLUDE 'csrf-token.inc' %] |
275 |
<input type="hidden" name="op" value="cud-delete_acct" /> |
311 |
<input type="hidden" name="op" value="cud-delete_confirmed" /> |
276 |
<input type="hidden" name="id" value="[% account.id | html %]" /> |
312 |
<input type="hidden" name="id" value="[% account.id | html %]" /> |
277 |
<button type="submit" class="approve"><i class="fa fa-fw fa-check"></i> Yes, delete</button> |
313 |
<button type="submit" class="approve"><i class="fa fa-fw fa-check"></i> Yes, delete</button> |
278 |
</form> |
314 |
</form> |
279 |
- |
|
|