4 [% INCLUDE 'doc-head-open.inc' %]
5 <title>Koha › Acquisitions › EDIFACT messages</title>
6 [% Asset.css("css/datatables.css") %]
7 [% INCLUDE 'doc-head-close.inc' %]
8 <style type="text/css">
9 #EDI_modal { width : 80%; } @media (max-width: 767px) { #EDI_modal { margin: 0; width : auto; } }
13 <body id="acq_edifactmsgs" class="acq">
14 [% INCLUDE 'header.inc' %]
15 [% INCLUDE 'acquisitions-search.inc' %]
16 <div id="breadcrumbs">
17 <a href="/cgi-bin/koha/mainpage.pl">Home</a>
18 › <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a>
19 › <a href="/cgi-bin/koha/acqui/edifactmsgs.pl">EDIFACT messages</a>
22 <div id="doc3" class="yui-t2">
29 <h1>EDIFACT messages</h1>
30 <div id="acqui_edifactmsgs">
37 <th class="title-string">Transferred</th>
46 [% FOREACH msg IN messages %]
48 <td>[% msg.message_type %]</td>
49 <td><span title="[% msg.transfer_date %]">[% msg.transfer_date | $KohaDates %]</span></td>
50 <td>[% msg.status %]</td>
52 <a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% msg.vendor_id %]">
57 [% IF msg.message_type == 'QUOTE' || msg.message_type == 'ORDERS' %]
59 <a href="/cgi-bin/koha/acqui/basket.pl?basketno=[% msg.basketno.basketno %]">
60 Basket: [% msg.basketno.basketno %]
64 <!-- Assuming invoices -->
65 <a href="/cgi-bin/koha/acqui/invoices.pl?message_id=[% msg.id %]">
70 <td>[% msg.filename %]</td>
73 <a class="btn btn-default btn-xs view_message" target="_blank" href="/cgi-bin/koha/acqui/edimsg.pl?id=[% msg.id %]"><i class="fa fa-search"></i> View message</a>
74 <a class="btn btn-default btn-xs delete_msg" href="/cgi-bin/koha/acqui/edifactmsgs.pl?op=delete&message_id=[% msg.id %]"><i class="fa fa-trash"></i> Delete</a>
82 <!-- Modal to display EDIFACT messages -->
83 <div class="modal" id="EDI_modal" tabindex="-1" role="dialog" aria-labelledby="EDI_modal_label" aria-hidden="true">
84 <div class="modal-dialog">
85 <div class="modal-content">
86 <div class="modal-header">
87 <button type="button" class="closebtn" data-dismiss="modal" aria-hidden="true">×</button>
88 <h3 id="EDI_modal_label">EDIFACT message</h3>
90 <div class="modal-body">
91 <div id="loading"> <img src="[% interface %]/[% theme %]/img/spinner-small.gif" alt="" /> Loading </div>
93 <div class="modal-footer">
94 <button class="btn btn-default" data-dismiss="modal" aria-hidden="true">Close</button>
102 <div class="dialog message">There are no EDIFACT messages.</div>
109 [% INCLUDE 'acquisitions-menu.inc' %]
113 [% MACRO jsinclude BLOCK %]
114 [% Asset.js("js/acquisitions-menu.js") %]
115 [% INCLUDE 'datatables.inc' %]
116 <script type="text/javascript">
117 $(document).ready(function() {
118 $('#edi_msgs').dataTable($.extend(true, {}, dataTablesDefaults, {
119 'aaSorting': [[1, "desc" ]],
120 'sPaginationType': "four_button",
122 { "aTargets": [ -1 ], "bSortable": false, "bSearchable": false },
123 { "sType": "title-string", "aTargets" : [ "title-string" ] }
127 var EDIModal = $("#EDI_modal");
128 var EDIModalBody = $("#EDI_modal .modal-body");
130 $(".view_message").on("click", function(e){
132 var page = $(this).attr("href");
133 EDIModalBody.load(page + " #edimsg");
134 EDIModal.modal("show");
136 EDIModal.on("click",".closebtn",function(e){
138 EDIModal.modal("hide");
140 EDIModal.on("hidden", function(){
141 EDIModalBody.html("<div id=\"loading\"><img src=\"[% interface %]/[% theme %]/img/spinner-small.gif\" alt=\"\" /> "+_("Loading")+"</div>");
143 $(".delete_msg").on("click",function(){
144 return confirm(_("Are you sure you want to delete this message?"));
150 [% INCLUDE 'intranet-bottom.inc' %]