Bug 27947: Add cancellation reason to article request
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / admin / edi_ean_accounts.tt
1 [% USE raw %]
2 [% USE Asset %]
3 [% SET footerjs = 1 %]
4 [% INCLUDE 'doc-head-open.inc' %]
5 <title>
6 [% IF ean_form %]
7     [% IF ean %]
8         Modify library EAN
9     [% ELSE %]
10         Add new library EAN
11     [% END %] &rsaquo; [% END %]
12 [% IF delete_confirm %]
13     Confirm deletion of EAN &rsaquo; [% END %]
14 Library EANs &rsaquo; Administration &rsaquo; Koha
15 </title>
16 [% INCLUDE 'doc-head-close.inc' %]
17 </head>
18 <body id="admin_edi_ean" class="admin">
19 [% INCLUDE 'header.inc' %]
20 [% INCLUDE 'prefs-admin-search.inc' %]
21
22 <nav id="breadcrumbs" aria-label="Breadcrumb" class="breadcrumb">
23     <ol>
24         <li>
25             <a href="/cgi-bin/koha/mainpage.pl">Home</a>
26         </li>
27         <li>
28             <a href="/cgi-bin/koha/admin/admin-home.pl">Administration</a>
29         </li>
30
31         [% IF ean_form %]
32             <li>
33                 <a href="/cgi-bin/koha/admin/edi_ean_accounts.pl">Library EANs</a>
34             </li>
35             <li>
36                 <a href="#" aria-current="page">
37                     [% IF ean %]
38                         Modify library EAN
39                     [% ELSE %]
40                         Add new library EAN
41                     [% END %]
42                 </a>
43             </li>
44
45         [% ELSIF delete_confirm %]
46             <li>
47                 <a href="/cgi-bin/koha/admin/edi_ean_accounts.pl">Library EANs</a>
48             </li>
49             <li>
50                 <a href="#" aria-current="page">
51                     Confirm deletion of EAN
52                 </a>
53             </li>
54
55         [% ELSE %]
56             <li>
57                 <a href="#" aria-current="page">
58                     Library EANs
59                 </a>
60             </li>
61         [% END %]
62     </ol>
63 </nav>
64
65 <div class="main container-fluid">
66     <div class="row">
67         <div class="col-sm-10 col-sm-push-2">
68             <main>
69
70 [% IF display %]
71     <div id="toolbar" class="btn-toolbar">
72     <a class="btn btn-default" id="newediean" href="/cgi-bin/koha/admin/edi_ean_accounts.pl?op=ean_form">
73          <i class="fa fa-plus"></i>
74          New EAN
75     </a>
76     </div>
77 [% END %]
78
79 [% IF ean_form %]
80 <form action="/cgi-bin/koha/admin/edi_ean_accounts.pl" name="Eanform" method="post">
81   <input type="hidden" name="op" value="save" />
82   [% IF ean %]
83       <input type="hidden" name="oldbranchcode" value="[% ean.branch.branchcode | html %]" />
84       <input type="hidden" name="id" value="[% ean.id | html %]" />
85   [% END %]
86
87   <fieldset class="rows">
88       <legend>
89           [% IF ean %]
90              Modify EAN
91           [% ELSE %]
92             New EAN
93           [% END %]
94       </legend>
95
96       <ol>
97           <li>
98              <label for="branchcode">Library: </label>
99              <select name="branchcode" id="branchcode">
100                 <option value="">All libraries</option>
101                 [% FOREACH branch IN branches %]
102                     [% IF branch.branchcode == ean.branch.branchcode %]
103                        <option value="[% branch.branchcode | html %]" selected="selected">[% branch.branchname | html %]</option>
104                     [% ELSE %]
105                        <option value="[% branch.branchcode | html %]">[% branch.branchname | html %]</option>
106                     [% END %]
107                 [% END %]
108               </select>
109           </li>
110           <li>
111              <label for="description">Description: </label>
112              <input type="text" name="description" id="description" size="30" maxlength="128" value="[% ean.description | html %]" />
113           </li>
114           <li>
115              <label for="ean">EAN: </label>
116              <input type="text" name="ean" id="ean" size="20" maxlength="15" value="[% ean.ean | html %]" />
117           </li>
118           <li>
119              <label for="id_code_qualifier">Qualifier: </label>
120              <select name="id_code_qualifier" id="id_code_qualifier">
121                  [% FOREACH qualifier IN code_qualifiers %]
122                     [% IF qualifier.code == ean.id_code_qualifier %]
123                        <option value="[% qualifier.code | html %]" selected="selected">
124                            [% qualifier.description | html %] ([% qualifier.code | html %])
125                        </option>
126                     [% ELSE %]
127                        <option value="[% qualifier.code | html %]">
128                           [% qualifier.description | html %] ([% qualifier.code | html %])
129                        </option>
130                     [% END %]
131                  [% END %]
132              </select>
133           </li>
134       </ol>
135   </fieldset>
136
137   <fieldset class="action">
138     <input type="submit" value="Submit"/>
139     <a href="/cgi-bin/koha/admin/edi_ean_accounts.pl" class="cancel">Cancel</a>
140   </fieldset>
141 </form>
142 [% END %]
143
144 [% IF delete_confirm %]
145 <div class="dialog alert">
146 <h3>Delete EAN [% ean.ean | html %] for [% ean.branch.branchname | html %]?</h3>
147 <form action="/cgi-bin/koha/admin/edi_ean_accounts.pl" method="post">
148     <input type="hidden" name="op" value="delete_confirmed" />
149     <input type="hidden" name="id" value="[% ean.id | html %]" />
150     <button type="submit" class="approve"><i class="fa fa-fw fa-check"></i> Yes, delete</button>
151 </form>
152 <form action="/cgi-bin/koha/admin/edi_ean_accounts.pl" method="get">
153     <button type="submit" class="deny"><i class="fa fa-fw fa-remove"></i> No, do not delete</button>
154 </form>
155 </div>
156 [% END %]
157
158 [% IF display %]
159 [% IF ( eans ) %]
160     <h2>Library EANs</h2>
161     <table>
162         <tr>
163             <th>Library</th>
164             <th>Description</th>
165             <th>EAN</th>
166             <th>Qualifier</th>
167             <th class="noExport">Actions</th>
168         </tr>
169         [% FOREACH ean IN eans %]
170             <tr>
171                 [% IF ean.branch %]
172                 <td>[% ean.branch.branchname | html %]</td>
173                 [% ELSE %]
174                 <td>All libraries</td>
175                 [% END %]
176                 <td>[% ean.description | html %]</td>
177                 <td>[% ean.ean | html %]</td>
178                 <td>
179                  [% FOREACH qualifier IN code_qualifiers %]
180                     [% IF qualifier.code == ean.id_code_qualifier %]
181                         [% qualifier.description | html %] ([% qualifier.code | html %])
182                     [% END %]
183                  [% END %]
184                 </td>
185                 <td class="actions">
186                     <a class="btn btn-default btn-xs" href="/cgi-bin/koha/admin/edi_ean_accounts.pl?op=ean_form&id=[% ean.id | html %]"><i class="fa fa-pencil"></i> Edit</a>
187                     <a class="btn btn-default btn-xs" href="/cgi-bin/koha/admin/edi_ean_accounts.pl?op=delete_confirm&id=[% ean.id | html %]"><i class="fa fa-trash"></i> Delete</a>
188                 </td>
189             </tr>
190         [% END %]
191     </table>
192 [% ELSE %]
193     <div class="dialog message">
194         There are no library EANs.
195     </div>
196 [% END %]
197 [% END %]
198
199             </main>
200         </div> <!-- /.col-sm-10.col-sm-push-2 -->
201
202         <div class="col-sm-2 col-sm-pull-10">
203             <aside>
204                 [% INCLUDE 'admin-menu.inc' %]
205             </aside>
206         </div> <!-- /.col-sm-2.col-sm-pull-10 -->
207      </div> <!-- /.row -->
208
209 [% MACRO jsinclude BLOCK %]
210     [% Asset.js("js/admin-menu.js") | $raw %]
211 [% END %]
212 [% INCLUDE 'intranet-bottom.inc' %]