Jonathan Druart
beb6bd8667
The aqorders.subscriptionid info is not sent to the template when the order is edited. Which means we lose this link. Test plan: Create an order from a subscription Edit the order => Without this patch, the aqorders.subscriptionid value is set to NULL and items are created when receiving serial. => With this patch applied the link is preserved and expected behaviors are preserved during all the acquisition workflow You should also try and create several orders from the same subscription Sponsored-by: BULAC - http://www.bulac.fr/ Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr> Signed-off-by: Julian Maurice <julian.maurice@biblibre.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
132 lines
6.1 KiB
Text
132 lines
6.1 KiB
Text
[% USE Asset %]
|
|
[% USE KohaDates %]
|
|
[% USE Branches %]
|
|
[% USE Koha %]
|
|
[% SET footerjs = 1 %]
|
|
[% INCLUDE 'doc-head-open.inc' %]
|
|
<title>Koha › Serials [% biblionumber %]</title>
|
|
[% Asset.css("css/datatables.css") %]
|
|
[% INCLUDE 'doc-head-close.inc' %]
|
|
</head>
|
|
|
|
<body id="acq_newordersubscription" class="acq">
|
|
[% INCLUDE 'header.inc' %]
|
|
[% INCLUDE 'acquisitions-search.inc' %]
|
|
|
|
<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a> › <a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% booksellerid %]">[% booksellername %]</a> › <a href="/cgi-bin/koha/acqui/basket.pl?basketno=[% basketno %]">Basket [% basketno %]</a> › Add order from a subscription</div>
|
|
|
|
<div id="doc3" class="yui-t2">
|
|
<div id="bd">
|
|
<div id="yui-main">
|
|
<div class="yui-b">
|
|
<h2>Serials subscriptions</h2>
|
|
[% IF (done_searched) %]
|
|
<label for="show_only_renewed">
|
|
<input type="checkbox" style="vertical-align: middle;" id="show_only_renewed" />
|
|
Show only renewed
|
|
</label>
|
|
[% IF (subs_loop) %]
|
|
<table id="srlt">
|
|
<thead>
|
|
<tr>
|
|
<th>ISSN</th>
|
|
<th class="anti-the">Title</th>
|
|
<th> Notes </th>
|
|
<th>Vendor</th>
|
|
<th>Library</th>
|
|
<th>Call number</th>
|
|
<th class="title-string">Expiration date</th>
|
|
<th class="NoSort"></th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
[% FOREACH sub IN subs_loop %]
|
|
<tr data-reneweddate="[% sub.reneweddate %]" >
|
|
<td>[% sub.issn %]</td>
|
|
<td><a href="/cgi-bin/koha/serials/subscription-detail.pl?subscriptionid=[% sub.subscriptionid %]" class="button" title="subscription detail">[% IF (sub.title) %][% sub.title |html %][% ELSE %]
|
|
---
|
|
[% END %][% IF (sub.unititle) %], [% sub.unititle %][% END %]</a>
|
|
</td>
|
|
<td>[% IF (sub.publicnotes) %][% sub.publicnotes %][% END %]
|
|
[% IF (sub.internalnotes) %]([% sub.internalnotes %])[% END %]
|
|
</td>
|
|
<td>
|
|
[% IF (sub.vendorname) %][% sub.vendorname %][% END %]
|
|
</td>
|
|
<td>
|
|
[% IF (sub.branchcode) %][% Branches.GetName( sub.branchcode ) %][% END %]
|
|
</td>
|
|
<td>
|
|
[% IF (sub.callnumber) %][% sub.callnumber %][% END %]
|
|
</td>
|
|
<td>
|
|
[% IF (sub.enddate) %]
|
|
<span title="[% sub.enddate %]">[% sub.enddate | $KohaDates %]</span>
|
|
[% ELSE %]
|
|
<span title="0000-00-00"></span>
|
|
[% END %]
|
|
</td>
|
|
<td>
|
|
[% IF (sub.alreadyOnOrder) %]
|
|
Outstanding order (only one order per subscription is allowed)
|
|
[% ELSIF not sub.aqbooksellerid || booksellerid == sub.aqbooksellerid%]
|
|
<a href="/cgi-bin/koha/acqui/neworderempty.pl?booksellerid=[% booksellerid %]&basketno=[% basketno %]&biblionumber=[% sub.biblionumber %]&from_subscriptionid=[% sub.subscriptionid %]" title="Order this one">
|
|
Order
|
|
</a>
|
|
[% ELSE %]
|
|
<a title="This subscription depends on another supplier" style="cursor:help">Cannot be ordered</a>
|
|
[% END %]
|
|
</td>
|
|
</tr>
|
|
[% END %]
|
|
</tbody>
|
|
</table>
|
|
[% ELSE %]
|
|
<p>Sorry, there is no result for your search.</p>
|
|
[% END %]
|
|
[% ELSE %]
|
|
<p>Use the search form on the left to find subscriptions.</p>
|
|
[% END %]
|
|
</div>
|
|
</div>
|
|
|
|
<div class="yui-b">
|
|
[% INCLUDE 'subscriptions-search.inc' %]
|
|
[% INCLUDE 'acquisitions-menu.inc' %]
|
|
</div>
|
|
</div>
|
|
|
|
[% MACRO jsinclude BLOCK %]
|
|
[% Asset.js("js/acquisitions-menu.js") %]
|
|
[% INCLUDE 'datatables.inc' %]
|
|
<script type="text/javascript">
|
|
function updateRowsVisibility(show_only_renewed) {
|
|
if ( show_only_renewed ) {
|
|
$("#srlt [data-reneweddate='']").hide();
|
|
} else {
|
|
$("#srlt > tbody > tr").show();
|
|
}
|
|
}
|
|
|
|
$(document).ready(function() {
|
|
$("#srlt").dataTable($.extend(true, {}, dataTablesDefaults, {
|
|
"aoColumnDefs": [
|
|
{ "bSortable": false, "bSearchable": false, 'aTargets': [ 'NoSort' ] },
|
|
{ "sType": "anti-the", "aTargets" : [ "anti-the" ] },
|
|
{ "sType": "title-string", "aTargets" : [ "title-string" ] }
|
|
],
|
|
"sPaginationType": "four_button"
|
|
}));
|
|
|
|
$("#show_only_renewed").click(function(){
|
|
updateRowsVisibility( $(this).is(":checked") );
|
|
});
|
|
$("#show_only_renewed").prop('checked', false);
|
|
updateRowsVisibility(false);
|
|
|
|
$("#advsearch_form").show();
|
|
});
|
|
</script>
|
|
[% END %]
|
|
|
|
[% INCLUDE 'intranet-bottom.inc' %]
|