[% USE raw %]
+[% USE Koha %]
[% USE Asset %]
+[% PROCESS 'i18n.inc' %]
[% SET footerjs = 1 %]
[% INCLUDE 'doc-head-open.inc' %]
-<title>Koha › Administration › EDI accounts
+<title>
[% IF acct_form %]
- [% IF account %]
- › Modify account
- [% ELSE %]
- › Add new account
- [% END %]
-[% END %]
+ [% IF account %]
+ Modify account
+ [% ELSE %]
+ Add new account
+ [% END %] › [% END %]
[% IF delete_confirm %]
- › Confirm deletion of account
-[% END %]
+ Confirm deletion of account › [% END %]
+EDI accounts › Administration › Koha
</title>
[% INCLUDE 'doc-head-close.inc' %]
</head>
<body id="admin_edi_acct" class="admin">
-[% INCLUDE 'header.inc' %]
-[% INCLUDE 'prefs-admin-search.inc' %]
-
-<div id="breadcrumbs">
-<a href="/cgi-bin/koha/mainpage.pl">Home</a>
-› <a href="/cgi-bin/koha/admin/admin-home.pl">Administration</a>
- [% IF acct_form %]
- [% IF account %]
- › <a href="/cgi-bin/koha/admin/edi_accounts.pl">EDI accounts</a> › Modify account
- [% ELSE %]
- › <a href="/cgi-bin/koha/admin/edi_accounts.pl">EDI accounts</a> › Add new account
- [% END %]
-[% ELSIF delete_confirm %]
- › <a href="/cgi-bin/koha/admin/edi_accounts.pl">EDI accounts</a> › Confirm deletion of account
-[% ELSE %]
- › EDI accounts
+[% WRAPPER 'header.inc' %]
+ [% INCLUDE 'prefs-admin-search.inc' %]
[% END %]
-</div>
-<div id="doc3" class="yui-t2">
+[% WRAPPER 'sub-header.inc' %]
+ [% WRAPPER breadcrumbs %]
+ [% WRAPPER breadcrumb_item %]
+ <a href="/cgi-bin/koha/admin/admin-home.pl">Administration</a>
+ [% END %]
+
+ [% IF acct_form || delete_confirm %]
+ [% WRAPPER breadcrumb_item %]
+ <a href="/cgi-bin/koha/admin/edi_accounts.pl">EDI accounts</a>
+ [% END %]
+ [% ELSE %]
+ [% WRAPPER breadcrumb_item bc_active= 1 %]
+ <span>EDI accounts</span>
+ [% END %]
+ [% END %]
+
+ [% IF acct_form %]
+ [% IF account %]
+ [% WRAPPER breadcrumb_item bc_active= 1 %]
+ <span>Modify account</span>
+ [% END %]
+ [% ELSE %]
+ [% WRAPPER breadcrumb_item bc_active= 1 %]
+ <span>Add new account</span>
+ [% END %]
+ [% END %]
+
+ [% ELSIF delete_confirm %]
+ [% WRAPPER breadcrumb_item bc_active= 1 %]
+ <span>Confirm deletion of account</span>
+ [% END %]
+ [% END %]
+ [% END #/ WRAPPER breadcrumbs %]
+[% END #/ WRAPPER sub-header.inc %]
+
+<div class="main container-fluid">
+ <div class="row">
+ <div class="col-sm-10 col-sm-push-2">
+ <main>
+
+
+[% UNLESS Koha.Preference('EDIFACT') %]
+ <div class="dialog message">
+ EDIFACT is currently disabled
+ </div>
+[% END %]
-<div id="bd">
-<div id="yui-main">
-<div class="yui-b">
[% IF display %]
<div id="toolbar" class="btn-toolbar">
- <a class="btn btn-default btn-sm" id="newediacct" href="/cgi-bin/koha/admin/edi_accounts.pl?op=acct_form">
+ <a class="btn btn-default" id="newediacct" href="/cgi-bin/koha/admin/edi_accounts.pl?op=acct_form">
<i class="fa fa-plus"></i>
New account
</a>
[% END %]
<fieldset class="rows">
<legend>
- [% IF account %]
- Modify account
- [% ELSE %]
- New account
- [% END %]
+ <h1>
+ [% IF account %]
+ Modify account
+ [% ELSE %]
+ New account
+ [% END %]
+ </h1>
</legend>
<ol>
[% END %]
</select>
</li>
- [% IF plugins_enabled %]
+ [% IF plugins %]
<li>
<label for="plugin">Plugin: </label>
<select name="plugin" id="plugin">
<input type="text" name="san" id="san" size="20" maxlength="20" value="[% account.san | html %]" />
</li>
<li>
+ <label for="standard">Standard:</label>
+ <select name="standard" id="standard">
+ [% FOREACH standard IN standards %]
+ [% IF standard == 'BIC' %]
+ [% SET description = 'BiC' %]
+ [% ELSE %]
+ [% SET description = 'EDItEUR' %]
+ [% END %]
+ [% IF standard == account.standard %]
+ <option value="[% standard | html %]" selected="selected">
+ [% description | html %]
+ </option>
+ [% ELSE %]
+ <option value="[% standard | html %]">
+ [% description | html %]
+ </option>
+ [% END %]
+ [% END %]
+ </select>
+ </li>
+ <li>
<label for="quotes_enabled">Quotes enabled: </label>
[% IF account.quotes_enabled %]
- <input type="checkbox" name="quotes_enabled" id="quotes_enabled" value="[% account.quotes_enabled | html %]" checked="checked" />
+ <input type="checkbox" name="quotes_enabled" id="quotes_enabled" value="1" checked="checked" />
[% ELSE %]
- <input type="checkbox" name="quotes_enabled" id="quotes_enabled" value="[% account.quotes_enabled | html %]" />
+ <input type="checkbox" name="quotes_enabled" id="quotes_enabled" value="1" />
[% END %]
</li>
<li>
<label for="orders_enabled">Orders enabled: </label>
[% IF account.orders_enabled %]
- <input type="checkbox" name="orders_enabled" id="orders_enabled" value="[% account.orders_enabled | html %]" checked="checked" />
+ <input type="checkbox" name="orders_enabled" id="orders_enabled" value="1" checked="checked" />
[% ELSE %]
- <input type="checkbox" name="orders_enabled" id="orders_enabled" value="[% account.orders_enabled | html %]" />
+ <input type="checkbox" name="orders_enabled" id="orders_enabled" value="1" />
[% END %]
</li>
<li>
<label for="invoices_enabled">Invoices enabled: </label>
[% IF account.invoices_enabled %]
- <input type="checkbox" name="invoices_enabled" id="invoices_enabled" value="[% account.invoices_enabled | html %]" checked="checked" />
+ <input type="checkbox" name="invoices_enabled" id="invoices_enabled" value="1" checked="checked" />
[% ELSE %]
- <input type="checkbox" name="invoices_enabled" id="invoices_enabled" value="[% account.invoices_enabled | html %]" />
+ <input type="checkbox" name="invoices_enabled" id="invoices_enabled" value="1" />
[% END %]
</li>
<li>
<label for="responses_enabled">Responses enabled: </label>
[% IF account.responses_enabled %]
- <input type="checkbox" name="responses_enabled" id="responses_enabled" value="[% account.responses_enabled | html %]" checked="checked" />
+ <input type="checkbox" name="responses_enabled" id="responses_enabled" value="1" checked="checked" />
[% ELSE %]
- <input type="checkbox" name="responses_enabled" id="responses_enabled" value="[% account.responses_enabled | html %]" />
+ <input type="checkbox" name="responses_enabled" id="responses_enabled" value="1" />
[% END %]
</li>
<li>
<label for="auto_orders">Automatic ordering: </label>
[% IF account.auto_orders %]
- <input type="checkbox" name="auto_orders" id="auto_orders" value="[% account.auto_orders | html %]" checked="checked" />
+ <input type="checkbox" name="auto_orders" id="auto_orders" value="1" checked="checked" />
[% ELSE %]
- <input type="checkbox" name="auto_orders" id="auto_orders" value="[% account.auto_orders | html %]" />
+ <input type="checkbox" name="auto_orders" id="auto_orders" value="1" />
[% END %]
<div class="hint">
With automatic ordering quotes generate orders without staff intervention.
</fieldset>
<fieldset class="action">
- <input type="submit" value="Submit" />
+ <input type="submit" class="btn btn-primary" value="Submit" />
<a href="/cgi-bin/koha/admin/edi_accounts.pl" class="cancel">Cancel</a>
</fieldset>
</form>
[% END %]
[% IF delete_confirm %]
<div class="dialog alert">
-<h3>Delete this account?</h3>
+<h1>Delete this account?</h1>
<table>
<tr>
<th>Vendor</th>
[% END %]
[% IF display %]
[% IF ( ediaccounts ) %]
-<h2>Vendor EDI accounts</h2>
-
+<h1>Vendor EDI accounts</h1>
+<div class="page-section">
<table>
<tr>
<th>ID</th>
<th>Upload directory</th>
<th>Qualifier</th>
<th>SAN</th>
- <th>Quotes</th>
+ <th>Standard</th>
+ <th>[% tp('EDIFACT message QUOTE', 'Quotes') | html %]</th>
<th>Orders</th>
<th>Invoices</th>
<th>Responses</th>
<th>Auto ordering</th>
- <th>Actions</th>
+ <th class="noExport">Actions</th>
</tr>
[% FOREACH account IN ediaccounts %]
<tr>
<td>[% account.id | html %]</td>
- <td><a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% account.vendor_id | html %]">[% account.vendor.name | html %]</a></td>
+ <td><a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% account.vendor_id | uri %]">[% account.vendor.name | html %]</a></td>
<td>[% account.description | html %]</td>
<td>[% account.transport | html %]</td>
<td>[% account.host | html %]</td>
([% account.id_code_qualifier | html %])
</td>
<td>[% account.san | html %]</td>
+ <td>[% IF account.standard == 'BIC' %]BiC[% ELSE %]EDItEUR[% END %]</td>
[% IF account.quotes_enabled %]
- <td>Y</td>
+ <td>Yes</td>
[% ELSE %]
- <td>N</td>
+ <td>No</td>
[% END %]
[% IF account.orders_enabled %]
- <td>Y</td>
+ <td>Yes</td>
[% ELSE %]
- <td>N</td>
+ <td>No</td>
[% END %]
[% IF account.invoices_enabled %]
- <td>Y</td>
+ <td>Yes</td>
[% ELSE %]
- <td>N</td>
+ <td>No</td>
[% END %]
[% IF account.responses_enabled %]
- <td>Y</td>
+ <td>Yes</td>
[% ELSE %]
- <td>N</td>
+ <td>No</td>
[% END %]
[% IF account.auto_orders %]
- <td>Y</td>
+ <td>Yes</td>
[% ELSE %]
- <td>N</td>
+ <td>No</td>
[% END %]
<td class="actions">
<a class="btn btn-default btn-xs" href="/cgi-bin/koha/admin/edi_accounts.pl?op=acct_form&id=[% account.id | html %]"><i class="fa fa-pencil"></i> Edit</a> <a class="btn btn-default btn-xs" href="/cgi-bin/koha/admin/edi_accounts.pl?op=delete_confirm&id=[% account.id | html %]"><i class="fa fa-trash"></i> Delete</a>
</tr>
[% END %]
</table>
+</div> <!-- /.page-section -->
[% ELSE %]
<div class="dialog message">
There are no EDI accounts.
[% END %]
[% END %]
-</div>
-</div>
-<div class="yui-b">
- [% INCLUDE 'admin-menu.inc' %]
-</div>
-</div>
+ </main>
+ </div> <!-- /.col-sm-10.col-sm-push-2 -->
+
+ <div class="col-sm-2 col-sm-pull-10">
+ <aside>
+ [% INCLUDE 'admin-menu.inc' %]
+ </aside>
+ </div> <!-- /.col-sm-2.col-sm-pull-10 -->
+ </div> <!-- /.row -->
[% MACRO jsinclude BLOCK %]
[% Asset.js("js/admin-menu.js") | $raw %]