2015-01-23 12:18:54 +00:00
[% USE raw %]
2018-04-06 15:02:55 +00:00
[% USE Asset %]
2014-03-19 11:54:15 +00:00
[% USE Koha %]
2015-11-10 17:42:44 +00:00
[% USE KohaDates %]
2024-10-03 08:50:57 +00:00
[% USE TablesSettings %]
Bug 13001: Refactor VAT and price calculation - parcel page
Bug 12969 introduces a subroutine to centralize VAT and prices
calculation.
It should be use in the acqui/parcel.pl script.
Test plan:
1/ Create 4 suppliers with the different configurations
2/ Create a basket and create several orders
3/ Go on the parcel page
4/ You should see, on the "pending orders" table, the same prices as
before this patch.
Note that the prices are now correctly formated.
You could see one change for the supplier configuration 3 (1 0):
If the cost of the item is 82, discount 10% and vat 5%:
The "Order cost" = 140.58 instead of 140.57.
Indeed, before this patch, the order cost was wrong, now you should have
70.29*2 = 140.58
( before: 140.58 + 7.03 = 147.61
now: 140.58 + 7.02 = 147.60 )
5/ Receive the items and return on the parcel page
Now the "Already received" table with the same prices as before this
patch.
Note some differences too:
- There was a td tag missing, the table was badly formated, it's now
fixed (column below the "Cancel receipt" link).
- The prices are now correctly formated.
- For the configuration 2 (1 1), if the cost of the item is 82, discount
10% and vat 5%:
( before: 140.57 + 7.03 = 147.60
now: 140.58 + 7.02 = 147.60 )
Note that 7.03 is the "correct" value, but on all other pages, 7.02 is
displayed.
To be consistent, we should display the same prices everywhere.
Signed-off-by: Paola Rossi <paola.rossi@cineca.it>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
2014-09-26 12:46:21 +00:00
[% USE Price %]
2019-11-06 23:24:13 +00:00
[% PROCESS 'i18n.inc' %]
Bug 19755: Move template JavaScript to the footer: Acquisitions, part 3
This patch modifies even more staff client acquisitions templates so
that JavaScript is included in the footer instead of the header.
To test, apply the patch and test the JavaScript-driven features of the
modified templates: All button controls, DataTables functionality, tabs,
etc.
- Acquisitions -> Vendor -> Vendor details
- Contracts datatable
- Edit vendor
- Add contacts, form validation
- Acquisitions -> Vendor -> Invoices -> Invoice -> "Go to receipt"
- Datatables, MARC and Card previews
- Transfer
- Confirmation of transfer, window closes
- Acquisitions -> Vendor -> Receive shipments
- Datatables, date pickers
- Acquisitions -> Available funds table -> Spent report
- Datatables
- Acquisitions -> Vendor -> Uncertain prices
- Datatables, form validation
- Acquisitions -> Vendor -> Basket -> Add to basket from external source
- Select and clear all on search form
- Search results
- Datatables, MARC and Card previews, in-table pop-up controls
(click any table cell)
Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2017-12-05 18:30:08 +00:00
[% SET footerjs = 1 %]
2011-03-21 07:02:15 +00:00
[% INCLUDE 'doc-head-open.inc' %]
2023-06-06 14:59:36 +00:00
<title>[% FILTER collapse %]
2020-04-14 11:42:22 +00:00
[% IF ( invoiceclosedate ) %]
2023-06-06 14:59:36 +00:00
[% IF ( invoice ) %]
[% tx("Receipt summary for {vendor}, invoice {invoice_number}", { vendor = name, invoice_number = invoice }) | html %]
[% ELSE %]
[% tx("Receipt summary for {vendor}", { vendor = name }) | html %]
[% END %]
2020-04-14 11:42:22 +00:00
[% ELSE %]
2023-06-06 14:59:36 +00:00
[% tx("Receive orders from {vendor}", { vendor = name }) | html %]
[% END %] ›
[% t("Acquisitions") | html %] ›
[% t("Koha") | html %]
[% END %]</title>
2011-03-21 07:02:15 +00:00
[% INCLUDE 'doc-head-close.inc' %]
</head>
Bug 19755: Move template JavaScript to the footer: Acquisitions, part 3
This patch modifies even more staff client acquisitions templates so
that JavaScript is included in the footer instead of the header.
To test, apply the patch and test the JavaScript-driven features of the
modified templates: All button controls, DataTables functionality, tabs,
etc.
- Acquisitions -> Vendor -> Vendor details
- Contracts datatable
- Edit vendor
- Add contacts, form validation
- Acquisitions -> Vendor -> Invoices -> Invoice -> "Go to receipt"
- Datatables, MARC and Card previews
- Transfer
- Confirmation of transfer, window closes
- Acquisitions -> Vendor -> Receive shipments
- Datatables, date pickers
- Acquisitions -> Available funds table -> Spent report
- Datatables
- Acquisitions -> Vendor -> Uncertain prices
- Datatables, form validation
- Acquisitions -> Vendor -> Basket -> Add to basket from external source
- Select and clear all on search form
- Search results
- Datatables, MARC and Card previews, in-table pop-up controls
(click any table cell)
Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2017-12-05 18:30:08 +00:00
2012-03-20 15:41:17 +00:00
<body id="acq_parcel" class="acq">
2022-07-25 14:37:41 +00:00
[% WRAPPER 'header.inc' %]
[% INCLUDE 'acquisitions-search.inc' %]
[% END %]
2011-03-21 07:02:15 +00:00
2022-07-25 14:37:41 +00:00
[% WRAPPER 'sub-header.inc' %]
2023-01-06 11:50:00 +00:00
[% WRAPPER breadcrumbs %]
[% WRAPPER breadcrumb_item %]
2021-03-11 02:40:25 +00:00
<a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a>
2023-01-06 11:50:00 +00:00
[% END %]
2021-03-23 12:01:06 +00:00
[% IF invoiceclosedate %]
2023-01-06 11:50:00 +00:00
[% WRAPPER breadcrumb_item bc_active= 1 %]
2021-03-23 12:01:06 +00:00
[% IF ( invoice ) %]
2023-02-24 12:44:31 +00:00
<span>Receipt summary for <em>[% name | html %] [ [% invoice | html %] ]</em></span>
[% ELSE %]
<span>Receipt summary for <em>[% name | html %]</em></span>
2021-03-23 12:01:06 +00:00
[% END %]
2023-01-06 11:50:00 +00:00
[% END %]
2021-03-23 12:01:06 +00:00
[% ELSE %]
2023-01-06 11:50:00 +00:00
[% WRAPPER breadcrumb_item %]
2021-03-23 12:01:06 +00:00
<a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% booksellerid | uri %]">[% name | html %]</a>
2023-01-06 11:50:00 +00:00
[% END %]
[% WRAPPER breadcrumb_item bc_active= 1 %]
2023-02-24 12:44:31 +00:00
<span>Receive orders from [% name | html %]</span>
2023-01-06 11:50:00 +00:00
[% END %]
2012-01-06 15:51:57 +00:00
[% END %]
2023-01-06 11:50:00 +00:00
[% END #/ WRAPPER breadcrumbs %]
[% END #/ WRAPPER sub-header.inc %]
2011-03-21 07:02:15 +00:00
2018-05-01 15:49:26 +00:00
<div class="main container-fluid">
<div class="row">
2024-01-03 19:33:07 +00:00
<div class="col-md-10 order-md-2 order-sm-2">
2018-05-01 15:49:26 +00:00
<main>
2023-09-21 13:10:48 +00:00
[% INCLUDE 'messages.inc' %]
2018-05-01 15:49:26 +00:00
2020-03-10 19:03:50 +00:00
[% IF ( receive_error ) %]
2024-01-03 19:33:07 +00:00
<div class="alert alert-warning">
2020-03-10 19:03:50 +00:00
<h3>Error adding items:</h3>
<ul>
[% FOREACH error_loo IN error_loop %]
2021-06-09 12:27:29 +00:00
<li>[% error_loo.error_param | html %][% IF ( error_loo.error_duplicate_barcode ) %]Duplicate barcode[% END %] <!-- todo: other error conditions come here. --></li>
2020-03-10 19:03:50 +00:00
[% END %]
</ul>
</div>
[% END %]
2011-03-21 07:02:15 +00:00
<h1>
2020-04-14 11:42:22 +00:00
[% IF ( invoiceclosedate ) %]
2022-02-05 20:43:04 +00:00
<span>Receipt summary for <em>[% name | html %]</em></span> [% IF ( invoice ) %] <em> [ [% invoice | html %] ] </em>[% END %]
2011-03-21 07:02:15 +00:00
[% ELSE %]
2021-11-30 13:54:15 +00:00
<span>Receive orders from [% name | html %]</span>
2011-03-21 07:02:15 +00:00
[% END %]
</h1>
[% IF ( success_delorder ) %]
2024-01-03 19:33:07 +00:00
<div class="alert alert-info">The order has been successfully canceled.</div>
2011-03-21 07:02:15 +00:00
[% ELSE %]
2020-03-10 19:03:50 +00:00
[% IF ( error_delitem ) %]
2024-01-03 19:33:07 +00:00
<div class="alert alert-warning">The order has been canceled, although one or more items could not have been deleted.</div>
2020-03-10 19:03:50 +00:00
[% END %]
[% IF ( error_delbiblio ) %]
2024-01-03 19:33:07 +00:00
<div class="alert alert-warning">The order has been canceled, although the record has not been deleted.</div>
2020-03-10 19:03:50 +00:00
[% END %]
2011-03-21 07:02:15 +00:00
[% END %]
2012-08-08 09:06:45 +00:00
[% IF (error_cancelling_receipt) %]
2024-01-03 19:33:07 +00:00
<div class="alert alert-warning">
2022-07-07 22:45:46 +00:00
<span>Cannot cancel receipt. Possible reasons:</span>
2012-08-08 09:06:45 +00:00
<ul>
<li>
2021-01-25 14:59:57 +00:00
The order line you are trying to cancel was created from a partial receipt
2012-08-13 14:34:35 +00:00
of another order line which is already received. Try to cancel this
one first and retry.
</li>
<li>
2021-01-25 14:59:57 +00:00
The order line you are trying to cancel was created from a partial receipt
2012-08-13 14:34:35 +00:00
of another order line which has been deleted. Cancellation is not
possible.
2012-08-08 09:06:45 +00:00
</li>
</ul>
</div>
[% END %]
2013-05-23 14:42:38 +00:00
[% IF error_invoice_not_known %]
2024-01-03 19:33:07 +00:00
<div class="alert alert-warning">
2013-05-23 14:42:38 +00:00
The invoice referenced by this invoiceid does not exist.
</div>
[% END %]
[% UNLESS no_orders_to_display %]
2011-03-21 07:02:15 +00:00
<div id="acqui_receive_summary">
2024-07-25 22:39:51 +00:00
<p><strong>Invoice number:</strong> <a href="/cgi-bin/koha/acqui/invoice.pl?invoiceid=[% invoiceid | uri %]">[% invoice | html %]</a> <strong>Shipment date:</strong> [% shipmentdate | $KohaDates %]</p>
2011-03-21 07:02:15 +00:00
</div>
2012-01-06 15:51:57 +00:00
[% UNLESS (invoiceclosedate) %]
2022-11-09 16:42:54 +00:00
<div id="acqui_receive_search" class="page-section">
2020-03-10 19:03:50 +00:00
<h3>Pending orders</h3>
<table id="pending_orders" class="table table-bordered table-striped">
<thead>
<tr>
2023-05-13 00:09:57 +00:00
<th></th>
2020-03-10 19:03:50 +00:00
<th>Basket</th>
<th>Basket group</th>
<th>Order line</th>
<th>Summary</th>
2022-03-22 11:25:12 +00:00
<th>View</th>
2020-03-10 19:03:50 +00:00
<th>Replacement price</th>
<th>Quantity</th>
<th>Unit cost</th>
<th>Order cost</th>
<th>Fund</th>
<th> </th>
<th> </th>
2012-01-06 15:51:57 +00:00
</tr>
2020-03-10 19:03:50 +00:00
</thead>
</table>
Bug 8179: Receive multiple orders
This patch implements the code to allow a patron to receive multiple
orders at the same time in /cgi-bin/koha/acqui/orderreceive.pl page
To test:
1. apply all patches
2. updatedatabase
3. Go to system preferences and allow AcqReceiveMultipleOrderLines
4. In acquisitions module, create a vendor if you don't have one and add
3 baskets.. one with create items on ordering, one with create items
on receiving and finally one with create items when cataloguing
5. Fill baskets with orders (There should be at least 15 orders in total). There should be a mix of orders created by suggestions, others by subscriptions and others by neither of those methods.
6. Close all baskets and receive shipment.
CHECK => in /cgi-bin/koha/acqui/parcel.pl page, in top table there is a column with checkboxes, and a button that says "Receive selected"
7. If all orders from all baskets are shown in the table, set the rows per page to 10, so table has more than one page
8. Check some of the checkboxes
CHECK => "Receive selected" button shows how many rows are selected
9. Go to the next page and select some more rows
CHECK => Changing page does not modify how many rows where selected
10. Go back to previous page
CHECK => Previously selected rows are still selected
11. Reload the page to deselect all rows
12. Select only one row and click on "Receive selected" button
CHECK => the page /cgi-bin/koha/acqui/orderreceive.pl behaves just the same as if the "receive" link in the selected row would have been clicked.
13. Click on cancel to go back to parcel.pl page
14. Select all rows (even the ones from the next page of the table) and
click on "Receive selected"
CHECH => In orderreceive.pl page there is a table with all selected rows
15. Ensure table has more than one page, as in step 7
16. Click on the "edit" link in the last row of the current page
CHECK => A modal window is displayed with 4 tabs within: Info,
Accounting, Receipt history and Items
CHECK => Modal has 4 buttons at the bottom, 'Previous' to go to previos
order, 'Cancel' to close the modal without keeping modifications, 'Save'
to close modal keeping modifications and 'Next' to go to the next order
CHECK => Even that we are at the end of the current page, 'Next' button
is still available
17. Click on 'Next' button
CHECK => The table behind the modal now displays the next page, and the modal was not closed
18. Click on 'Previous'
CHECK => The table behind the modal went back to the first page, and the modal was not closed
19. Click on 'Previous' button till you reach the first row of the first
page
CHECK => Only when you reach the first row of the first page 'Previous'
button gets disabled
20. Click on 'Next' button till you reach the last row of the last page
CHECK => Only when you reach the last button of the last page 'Next'
button gets disabled
21. Check that behaviour for the different types of order are still the
same
a. For orders that where created through suggestion, check that the
suggestion info is present in Info tab. If when suggestion was accepted
you set a reason, a dropdown to change the reason shoul display also.
b. For orders that where created through subscriptions, check that
the Items tab is disabled, and the Receipt history is enabled. On
accounting tab you should be able to change quantity ordered. If there
were less items received than ordered, the next time you receive this
order the child order generated from this one shoul appear in receipt
history.
c. For orders that don't come from subscription and creates there items on ordering, Receipt history
should be disabled, and a table with prefilled items shold appear in the
Items tab. You can edit them and the changes should appear in the item's
row.
d. For orders that don't come from subscription and creates there
items on receiving, Receipt history should be disabled, and a form to
create the items should appear in Items tab. When you add an item a
table should appear.
e. For orders that don't come from subscription and creates there
ites on cataloguing, Receipt history and Items tabs should be disabled.
f. Any changes made in quantity (received or ordered) or funds in the modal should be
reflected in the table if you click save from the modal.
22. Once you've done all you checking and verifications click save
23. While saving a progress bar should appear
24. If no error was detected, you should be redirected back to parcel.pl
page
25. If an error or warning was detected (like there is an order with 0
items to receive) the save button should be disabled and warnings
are dispayed.
26. prove t/db_dependent/Koha/Acquisition/Fund.t t/db_dependent/Koha/Acquisitoin/Order.t t/db_dependent/Koha/Item.t
Sponsored-by: Virginia Polytechnic Institute and State University
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2020-10-09 20:15:31 +00:00
<fieldset class="action">
<button id="select_multiple" class="btn btn-primary"></button>
</fieldset>
2020-03-10 19:03:50 +00:00
</div>
2012-01-06 15:51:57 +00:00
[% ELSE %]
<p>
2021-11-30 13:54:15 +00:00
<span>Invoice is closed, so you can't receive orders anymore.</span>
2019-12-10 19:03:28 +00:00
[% IF CAN_user_acquisition_reopen_closed_invoices %]
<a href="/cgi-bin/koha/acqui/invoice.pl?op=reopen&invoiceid=[% invoiceid | uri %]&referer=/cgi-bin/koha/acqui/parcel.pl%3Finvoiceid=[% invoiceid | uri %]">Reopen it</a>.
[% END %]
2012-01-06 15:51:57 +00:00
</p>
[% END %]
2022-11-09 16:42:54 +00:00
<div id="acqui_receive_receivelist" class="page-section">
2012-04-03 18:22:42 +00:00
<h3>Already received</h3>
2011-03-21 07:02:15 +00:00
[% IF ( loop_received ) %]
<form action="/cgi-bin/koha/acqui/parcel.pl" method="get" name="orderform">
<table id="receivedt">
2013-07-25 07:25:21 +00:00
<thead>
<tr>
<th>Basket</th>
<th>Basket group</th>
<th>Order line</th>
2017-12-14 12:03:39 +00:00
<th title="Item holds / Total holds">Holds</th>
2013-07-25 07:25:21 +00:00
<th>Summary</th>
2015-06-16 08:05:16 +00:00
<th>More</th>
2017-12-29 16:16:23 +00:00
<th>Replacement price</th>
2013-07-25 07:25:21 +00:00
<th>Quantity</th>
<th>Fund</th>
<th>Est cost</th>
<th>Actual cost</th>
<th>TOTAL</th>
<th></th>
</tr>
</thead>
2012-06-07 10:45:05 +00:00
<tfoot>
2015-01-21 08:51:18 +00:00
[% FOREACH key IN subtotal_for_funds.keys.sort %]
2012-03-28 17:33:36 +00:00
<tr>
2015-01-21 08:56:42 +00:00
[% IF invoiceincgst %]
<td colspan="6" class="total">(Tax inc.)</td>
[% ELSE %]
<td colspan="6" class="total">(Tax exc.)</td>
[% END %]
2020-08-06 17:29:54 +00:00
<td colspan="3"><em>Subtotal for</em> [% key | html %]</td>
2018-09-29 16:12:38 +00:00
<td>[% subtotal_for_funds.$key.ecost | $Price %]</td>
<td>[% subtotal_for_funds.$key.unitprice | $Price %]</td>
2012-03-28 17:33:36 +00:00
<td> </td>
<td> </td>
</tr>
[% END %]
2012-02-24 15:24:05 +00:00
<tr>
2018-09-07 11:33:44 +00:00
<th colspan="11" class="total">Total tax exc.</th>
2018-09-29 16:12:38 +00:00
<th>[% total_tax_excluded | $Price %]</th>
2012-02-24 15:24:05 +00:00
<th></th>
</tr>
[% FOREACH book_foot IN book_foot_loop %]
<tr>
2018-09-07 11:33:44 +00:00
<th colspan="11">Total (GST [% book_foot.tax_rate * 100 | html %]%)</th>
2018-09-29 16:12:38 +00:00
<th>[% book_foot.tax_value | $Price %]</th>
2012-02-24 15:24:05 +00:00
<th></th>
</tr>
[% END %]
<tr>
2018-09-07 11:33:44 +00:00
<th colspan="11" class="total">Total tax inc.</th>
2018-09-29 16:12:38 +00:00
<th>[% total_tax_included | $Price %]</th>
2012-02-24 15:24:05 +00:00
<th></th>
</tr>
2011-03-21 07:02:15 +00:00
</tfoot>
2013-04-26 07:30:23 +00:00
<tbody class="filterclass">
2013-07-25 07:25:21 +00:00
[% FOREACH order IN loop_received %]
2011-03-21 07:02:15 +00:00
<tr>
2019-04-17 05:20:23 +00:00
<td><a href="/cgi-bin/koha/acqui/basket.pl?basketno=[% order.basketno | uri %]"> [% order.basketname | html %] ([% order.basketno | html %])</a></td>
2013-10-22 12:05:48 +00:00
<td>
2013-07-25 07:25:21 +00:00
[% IF order.basketgroupid %]
2019-04-17 05:20:23 +00:00
<a href="/cgi-bin/koha/acqui/basketgroup.pl?op=add&booksellerid=[% booksellerid | uri %]">[% order.basketgroupname | html %] ([% order.basketgroupid | html %])</a>
2013-10-22 12:05:48 +00:00
[% ELSE %]
No basket group
[% END %]
</td>
2013-07-25 07:38:24 +00:00
<td>
2018-10-15 22:44:51 +00:00
<a href="neworderempty.pl?ordernumber=[% order.ordernumber | uri %]&booksellerid=[% booksellerid | uri %]">[% order.ordernumber | html %]</a>
2013-07-25 07:38:24 +00:00
[% IF (order.parent_ordernumber && (order.parent_ordernumber != order.ordernumber)) %]
2018-10-15 22:44:51 +00:00
(<a href="neworderempty.pl?ordernumber=[% order.parent_ordernumber | uri %]&booksellerid=[% booksellerid | uri %]" title="Original order line">[% order.parent_ordernumber | html %]</a>)
2013-07-25 07:38:24 +00:00
[% END %]
</td>
2013-10-25 12:27:10 +00:00
<td>
2017-12-14 12:03:39 +00:00
[% IF order.total_holds > 0 %]
[% IF order.item_holds > 0 %]
2018-10-15 22:44:51 +00:00
<span class="error"><a href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% order.biblionumber | uri %]">[% order.item_holds | html %]</a></span>
2017-12-14 12:03:39 +00:00
[% ELSE %]
0
[% END %]
/
2018-10-15 22:44:51 +00:00
<span class="error"><a href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% order.biblionumber | uri %]">[% order.total_holds | html %]</a></span>
2013-10-25 12:27:10 +00:00
[% ELSE %]
0
[% END %]
</td>
2021-03-29 14:57:22 +00:00
<td>
[% INCLUDE 'biblio-title.inc' biblio=order link = 1 %]
2015-01-23 12:18:54 +00:00
[% IF ( order.author ) %] / [% order.author | html %][% END %]
[% IF ( order.isbn ) %] - [% order.isbn | html %][% END %]
Bug 11122 - publisher code and publication year not fetched in acq orders
In acquisition, several templates try to display publisher code and publication year : invoice.tt, parcel.tt, transferorder.tt.
Thoses pages use C4::Acquisition methods GetPendingOrders or GetInvoiceDetails.
The bug is that in the SQL query of those methods, biblioitems.publishercode and biblioitems.publicationyear.
In uncertainprice.pl those datas are fetch using GetBiblioData.
It whould be better to fetch them in GetPendingOrders and GetInvoiceDetails.
This patch changes SQL queries to fetch wanted datas : aqorders.*,biblio.title,biblio.author,biblioitems.isbn,biblioitems.publishercode,biblioitems.publicationyear. GetInvoiceDetails also needs : biblio.seriestitle,biblioitems.volume.
This patch also unifies the way biblio datas are displayed :
<a href="link to catalog using biblionumber">[title]</a> <em>by</em> [author] – [isbn]
<em>Publisher:</em> [publishercode], [publicationyear]
Test plan :
- Choose a biblio record containing a data in :
biblio.title,
biblio.author,
biblioitems.isbn,
biblioitems.publishercode,
biblioitems.publicationyear,
biblio.seriestitle,
biblioitems.volume.
- Create an order using this biblio.
- Look at this order in pages : parcel.pl, transferorder.pl, uncertainprice.pl
=> You see publisher code and publication year
- Look at this order in page : invoice.pl
=> You see publisher code, publication year, series title and volume
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2013-10-23 10:05:23 +00:00
[% IF ( order.publishercode ) %]
2015-01-23 12:18:54 +00:00
<br />Publisher: [% order.publishercode | html %]
[%- IF ( order.publicationyear > 0) -%], [% order.publicationyear | html %]
[%- ELSIF ( order.copyrightdate > 0) -%] [% order.copyrightdate | html %]
2015-04-20 00:28:21 +00:00
[% END %]
Bug 11122 - publisher code and publication year not fetched in acq orders
In acquisition, several templates try to display publisher code and publication year : invoice.tt, parcel.tt, transferorder.tt.
Thoses pages use C4::Acquisition methods GetPendingOrders or GetInvoiceDetails.
The bug is that in the SQL query of those methods, biblioitems.publishercode and biblioitems.publicationyear.
In uncertainprice.pl those datas are fetch using GetBiblioData.
It whould be better to fetch them in GetPendingOrders and GetInvoiceDetails.
This patch changes SQL queries to fetch wanted datas : aqorders.*,biblio.title,biblio.author,biblioitems.isbn,biblioitems.publishercode,biblioitems.publicationyear. GetInvoiceDetails also needs : biblio.seriestitle,biblioitems.volume.
This patch also unifies the way biblio datas are displayed :
<a href="link to catalog using biblionumber">[title]</a> <em>by</em> [author] – [isbn]
<em>Publisher:</em> [publishercode], [publicationyear]
Test plan :
- Choose a biblio record containing a data in :
biblio.title,
biblio.author,
biblioitems.isbn,
biblioitems.publishercode,
biblioitems.publicationyear,
biblio.seriestitle,
biblioitems.volume.
- Create an order using this biblio.
- Look at this order in pages : parcel.pl, transferorder.pl, uncertainprice.pl
=> You see publisher code and publication year
- Look at this order in page : invoice.pl
=> You see publisher code, publication year, series title and volume
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2013-10-23 10:05:23 +00:00
[% END %]
2013-07-25 07:25:21 +00:00
[% IF ( order.suggestionid ) %]
2012-01-18 13:16:16 +00:00
<br/>
2015-01-23 12:18:54 +00:00
Suggested by: [% order.surnamesuggestedby | html %][% IF ( order.firstnamesuggestedby ) %], [% order.firstnamesuggestedby | html %] [% END %]
2018-10-15 22:44:51 +00:00
(<a href="/cgi-bin/koha/suggestion/suggestion.pl?suggestionid=[% order.suggestionid | uri %]&op=show">suggestion #[% order.suggestionid | html %]</a>)
2012-01-18 13:16:16 +00:00
[% END %]
2019-02-06 12:13:12 +00:00
<br />
[% IF ( order.order_internalnote ) %]
<p class="ordernote"><strong>Internal note: </strong>[% order.order_internalnote | html %] [<a href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber=[% order.ordernumber | uri %]&referrer=/cgi-bin/koha/acqui/parcel.pl%3Finvoiceid=[% invoiceid | uri %]&type=internal">Change internal note</a>]</p>
[% ELSE %]
[<a href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber=[% order.ordernumber | uri %]&referrer=/cgi-bin/koha/acqui/parcel.pl%3Finvoiceid=[% invoiceid | uri %]&type=internal">Add internal note</a>]
[% END %]
[% IF ( order.order_vendornote ) %]
<p class="ordernote"><strong>Vendor note: </strong>[% order.order_vendornote | html %]</p>
[% ELSE %]
[<a href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber=[% order.ordernumber | uri %]&referrer=/cgi-bin/koha/acqui/parcel.pl%3Finvoiceid=[% invoiceid | uri %]&type=vendor">Add vendor note</a>]
[% END %]
2011-03-21 07:02:15 +00:00
</td>
2015-06-16 08:05:16 +00:00
<td>
2019-11-06 23:24:13 +00:00
<a href="/cgi-bin/koha/acqui/showorder.pl?ordernumber=[% order.ordernumber | uri %]" class="previewData">[% tp('noun', 'Order') | html %]</a><br>
2018-10-15 22:44:51 +00:00
<a href="/cgi-bin/koha/catalogue/showmarc.pl?id=[% order.biblionumber | uri %]" class="previewData">MARC</a><br>
<a href="/cgi-bin/koha/catalogue/showmarc.pl?viewas=card&id=[% order.biblionumber | uri %]" class="previewData">Card</a>
2015-06-16 08:05:16 +00:00
</td>
2018-09-29 16:12:38 +00:00
<td>[% order.replacementprice | $Price %]</td>
2015-01-23 12:18:54 +00:00
<td>[% order.quantityreceived | html %]</td>
<td>[% order.budget.budget_name | html %]</td>
2018-09-29 16:12:38 +00:00
<td>[% order.ecost | $Price %]</td>
<td>[% order.unitprice | $Price %]</td>
<td>[% order.total | $Price %]</td>
2012-08-13 14:34:35 +00:00
<td>
2016-01-28 22:01:24 +00:00
[% IF loop_receive.cannot_cancel or ( order.basket.effective_create_items == "receiving" and loop_receive.holds > 0 ) %]
2014-03-19 11:54:15 +00:00
[% IF loop_receive.cannot_cancel %]
2018-07-19 21:24:10 +00:00
[% span_title = BLOCK %]
2021-11-30 13:54:15 +00:00
<span>Cannot cancel receipt of this order line because it
2012-08-13 14:34:35 +00:00
was created from a partial receipt of order line no.
2015-01-23 12:18:54 +00:00
[% order.parent_ordernumber | html %], which is
2012-08-13 14:34:35 +00:00
already received. Try cancelling this one first and
2021-11-30 13:54:15 +00:00
retry.</span>
2012-08-13 14:34:35 +00:00
[% END %]
2014-03-19 11:54:15 +00:00
[% ELSE %]
[%# FIXME Here we block the cancellation if holds exist. Actually it could be possible if items will be exist after the deletion %]
[%# Some additional checks should be added in the pl file %]
2018-07-19 21:24:10 +00:00
[% span_title = BLOCK %]
2022-05-17 12:04:41 +00:00
<span>Cannot cancel receipt of this order line because at least one hold exists on the records.</span>
2014-03-19 11:54:15 +00:00
[% END %]
[% END %]
2015-01-23 12:18:54 +00:00
<span title="[% span_title | collapse | html %]">
2014-03-19 11:54:15 +00:00
Can't cancel receipt
</span>
2012-08-13 14:34:35 +00:00
[% ELSE %]
2024-03-04 22:37:34 +00:00
<a href="#" class="cancel_receipt" data-ordernumber="[% order.ordernumber | html %]">Cancel receipt</a>
2012-08-13 14:34:35 +00:00
[% END %]
</td>
2011-03-21 07:02:15 +00:00
</tr>
2020-03-10 19:03:50 +00:00
[% END %]
</tbody>
2011-03-21 07:02:15 +00:00
</table>
</form>
2024-03-05 16:21:31 +00:00
<form id="cancel_receipt" method="post" action="/cgi-bin/koha/acqui/parcel.pl">
[% INCLUDE 'csrf-token.inc' %]
<input type="hidden" name="op" value="cud-cancelreceipt" />
<input type="hidden" name="ordernumber" id="cancel_ordernumber" value="" />
<input type="hidden" name="invoiceid" value="[% invoiceid | html %]" />
</form>
2016-05-26 11:26:33 +00:00
2020-03-10 19:03:50 +00:00
[% ELSE %]There are no received orders.[% END %]
2011-03-21 07:02:15 +00:00
</div>
2022-03-22 11:25:12 +00:00
<div class="modal" id="dataPreview" tabindex="-1" role="dialog" aria-labelledby="dataPreviewLabel">
2024-01-03 19:33:07 +00:00
<div class="modal-dialog modal-xl">
2022-03-22 11:25:12 +00:00
<div class="modal-content">
<div class="modal-header">
2024-01-03 19:33:07 +00:00
<h1 class="modal-title" id="dataPreviewLabel">MARC previews</h1>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
2022-03-22 11:25:12 +00:00
</div>
<div class="modal-body">
<div id="loading"> <img src="[% interface | html %]/[% theme | html %]/img/spinner-small.gif" alt="" /> Loading </div>
</div>
<div class="modal-footer">
2024-01-03 19:33:07 +00:00
<button class="btn btn-default" data-bs-dismiss="modal">Close</button>
2022-03-22 11:25:12 +00:00
</div>
</div> <!-- /.modal-content -->
</div> <!-- /.modal-dialog -->
</div> <!-- /.modal -->
2016-05-26 11:26:33 +00:00
2012-09-20 08:19:19 +00:00
[% IF (invoiceclosedate) %]
2018-10-15 22:44:51 +00:00
<a href="/cgi-bin/koha/acqui/invoice.pl?invoiceid=[% invoiceid | uri %]">View invoice</a>
2012-09-20 08:19:19 +00:00
[% ELSE %]
<form action="/cgi-bin/koha/acqui/invoice.pl" method="get">
2015-01-23 12:18:54 +00:00
<input type="hidden" name="invoiceid" value="[% invoiceid | html %]" />
2012-09-20 08:19:19 +00:00
<fieldset class="action">
2022-11-02 11:43:32 +00:00
<input type="submit" class="btn btn-primary" value="Finish receiving" />
2012-09-20 08:19:19 +00:00
</fieldset>
</form>
[% END %]
2011-08-05 13:47:16 +00:00
2013-05-23 14:42:38 +00:00
[% END %]
2018-05-01 15:49:26 +00:00
</main>
2024-01-03 19:33:07 +00:00
</div> <!-- /.col-md-10.order-md-2 -->
2013-05-23 14:42:38 +00:00
2024-01-03 19:33:07 +00:00
<div class="col-md-2 order-sm-2 order-md-1">
2018-05-01 15:49:26 +00:00
<aside>
2013-05-23 14:42:38 +00:00
2011-03-21 07:02:15 +00:00
[% INCLUDE 'acquisitions-menu.inc' %]
2018-05-01 15:49:26 +00:00
</aside>
2024-01-03 19:33:07 +00:00
</div> <!-- /.col-md-2.order-md-1 -->
2018-05-01 15:49:26 +00:00
</div> <!-- /.row -->
Bug 19755: Move template JavaScript to the footer: Acquisitions, part 3
This patch modifies even more staff client acquisitions templates so
that JavaScript is included in the footer instead of the header.
To test, apply the patch and test the JavaScript-driven features of the
modified templates: All button controls, DataTables functionality, tabs,
etc.
- Acquisitions -> Vendor -> Vendor details
- Contracts datatable
- Edit vendor
- Add contacts, form validation
- Acquisitions -> Vendor -> Invoices -> Invoice -> "Go to receipt"
- Datatables, MARC and Card previews
- Transfer
- Confirmation of transfer, window closes
- Acquisitions -> Vendor -> Receive shipments
- Datatables, date pickers
- Acquisitions -> Available funds table -> Spent report
- Datatables
- Acquisitions -> Vendor -> Uncertain prices
- Datatables, form validation
- Acquisitions -> Vendor -> Basket -> Add to basket from external source
- Select and clear all on search form
- Search results
- Datatables, MARC and Card previews, in-table pop-up controls
(click any table cell)
Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2017-12-05 18:30:08 +00:00
[% MACRO jsinclude BLOCK %]
2015-01-23 12:18:54 +00:00
[% Asset.js("js/acquisitions-menu.js") | $raw %]
Bug 19755: Move template JavaScript to the footer: Acquisitions, part 3
This patch modifies even more staff client acquisitions templates so
that JavaScript is included in the footer instead of the header.
To test, apply the patch and test the JavaScript-driven features of the
modified templates: All button controls, DataTables functionality, tabs,
etc.
- Acquisitions -> Vendor -> Vendor details
- Contracts datatable
- Edit vendor
- Add contacts, form validation
- Acquisitions -> Vendor -> Invoices -> Invoice -> "Go to receipt"
- Datatables, MARC and Card previews
- Transfer
- Confirmation of transfer, window closes
- Acquisitions -> Vendor -> Receive shipments
- Datatables, date pickers
- Acquisitions -> Available funds table -> Spent report
- Datatables
- Acquisitions -> Vendor -> Uncertain prices
- Datatables, form validation
- Acquisitions -> Vendor -> Basket -> Add to basket from external source
- Select and clear all on search form
- Search results
- Datatables, MARC and Card previews, in-table pop-up controls
(click any table cell)
Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2017-12-05 18:30:08 +00:00
[% INCLUDE 'datatables.inc' %]
2015-01-23 12:18:54 +00:00
[% Asset.js("lib/jquery/plugins/jquery.dataTables.columnFilter.js") | $raw %]
Bug 8179: Receive multiple orders
This patch implements the code to allow a patron to receive multiple
orders at the same time in /cgi-bin/koha/acqui/orderreceive.pl page
To test:
1. apply all patches
2. updatedatabase
3. Go to system preferences and allow AcqReceiveMultipleOrderLines
4. In acquisitions module, create a vendor if you don't have one and add
3 baskets.. one with create items on ordering, one with create items
on receiving and finally one with create items when cataloguing
5. Fill baskets with orders (There should be at least 15 orders in total). There should be a mix of orders created by suggestions, others by subscriptions and others by neither of those methods.
6. Close all baskets and receive shipment.
CHECK => in /cgi-bin/koha/acqui/parcel.pl page, in top table there is a column with checkboxes, and a button that says "Receive selected"
7. If all orders from all baskets are shown in the table, set the rows per page to 10, so table has more than one page
8. Check some of the checkboxes
CHECK => "Receive selected" button shows how many rows are selected
9. Go to the next page and select some more rows
CHECK => Changing page does not modify how many rows where selected
10. Go back to previous page
CHECK => Previously selected rows are still selected
11. Reload the page to deselect all rows
12. Select only one row and click on "Receive selected" button
CHECK => the page /cgi-bin/koha/acqui/orderreceive.pl behaves just the same as if the "receive" link in the selected row would have been clicked.
13. Click on cancel to go back to parcel.pl page
14. Select all rows (even the ones from the next page of the table) and
click on "Receive selected"
CHECH => In orderreceive.pl page there is a table with all selected rows
15. Ensure table has more than one page, as in step 7
16. Click on the "edit" link in the last row of the current page
CHECK => A modal window is displayed with 4 tabs within: Info,
Accounting, Receipt history and Items
CHECK => Modal has 4 buttons at the bottom, 'Previous' to go to previos
order, 'Cancel' to close the modal without keeping modifications, 'Save'
to close modal keeping modifications and 'Next' to go to the next order
CHECK => Even that we are at the end of the current page, 'Next' button
is still available
17. Click on 'Next' button
CHECK => The table behind the modal now displays the next page, and the modal was not closed
18. Click on 'Previous'
CHECK => The table behind the modal went back to the first page, and the modal was not closed
19. Click on 'Previous' button till you reach the first row of the first
page
CHECK => Only when you reach the first row of the first page 'Previous'
button gets disabled
20. Click on 'Next' button till you reach the last row of the last page
CHECK => Only when you reach the last button of the last page 'Next'
button gets disabled
21. Check that behaviour for the different types of order are still the
same
a. For orders that where created through suggestion, check that the
suggestion info is present in Info tab. If when suggestion was accepted
you set a reason, a dropdown to change the reason shoul display also.
b. For orders that where created through subscriptions, check that
the Items tab is disabled, and the Receipt history is enabled. On
accounting tab you should be able to change quantity ordered. If there
were less items received than ordered, the next time you receive this
order the child order generated from this one shoul appear in receipt
history.
c. For orders that don't come from subscription and creates there items on ordering, Receipt history
should be disabled, and a table with prefilled items shold appear in the
Items tab. You can edit them and the changes should appear in the item's
row.
d. For orders that don't come from subscription and creates there
items on receiving, Receipt history should be disabled, and a form to
create the items should appear in Items tab. When you add an item a
table should appear.
e. For orders that don't come from subscription and creates there
ites on cataloguing, Receipt history and Items tabs should be disabled.
f. Any changes made in quantity (received or ordered) or funds in the modal should be
reflected in the table if you click save from the modal.
22. Once you've done all you checking and verifications click save
23. While saving a progress bar should appear
24. If no error was detected, you should be redirected back to parcel.pl
page
25. If an error or warning was detected (like there is an order with 0
items to receive) the save button should be disabled and warnings
are dispayed.
26. prove t/db_dependent/Koha/Acquisition/Fund.t t/db_dependent/Koha/Acquisitoin/Order.t t/db_dependent/Koha/Item.t
Sponsored-by: Virginia Polytechnic Institute and State University
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2020-10-09 20:15:31 +00:00
<style>fieldset.action { margin-bottom: 20px }</style>
2018-05-01 15:49:26 +00:00
<script>
Bug 19755: Move template JavaScript to the footer: Acquisitions, part 3
This patch modifies even more staff client acquisitions templates so
that JavaScript is included in the footer instead of the header.
To test, apply the patch and test the JavaScript-driven features of the
modified templates: All button controls, DataTables functionality, tabs,
etc.
- Acquisitions -> Vendor -> Vendor details
- Contracts datatable
- Edit vendor
- Add contacts, form validation
- Acquisitions -> Vendor -> Invoices -> Invoice -> "Go to receipt"
- Datatables, MARC and Card previews
- Transfer
- Confirmation of transfer, window closes
- Acquisitions -> Vendor -> Receive shipments
- Datatables, date pickers
- Acquisitions -> Available funds table -> Spent report
- Datatables
- Acquisitions -> Vendor -> Uncertain prices
- Datatables, form validation
- Acquisitions -> Vendor -> Basket -> Add to basket from external source
- Select and clear all on search form
- Search results
- Datatables, MARC and Card previews, in-table pop-up controls
(click any table cell)
Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2017-12-05 18:30:08 +00:00
dt_overwrite_html_sorting_localeCompare();
Bug 8179: Receive multiple orders
This patch implements the code to allow a patron to receive multiple
orders at the same time in /cgi-bin/koha/acqui/orderreceive.pl page
To test:
1. apply all patches
2. updatedatabase
3. Go to system preferences and allow AcqReceiveMultipleOrderLines
4. In acquisitions module, create a vendor if you don't have one and add
3 baskets.. one with create items on ordering, one with create items
on receiving and finally one with create items when cataloguing
5. Fill baskets with orders (There should be at least 15 orders in total). There should be a mix of orders created by suggestions, others by subscriptions and others by neither of those methods.
6. Close all baskets and receive shipment.
CHECK => in /cgi-bin/koha/acqui/parcel.pl page, in top table there is a column with checkboxes, and a button that says "Receive selected"
7. If all orders from all baskets are shown in the table, set the rows per page to 10, so table has more than one page
8. Check some of the checkboxes
CHECK => "Receive selected" button shows how many rows are selected
9. Go to the next page and select some more rows
CHECK => Changing page does not modify how many rows where selected
10. Go back to previous page
CHECK => Previously selected rows are still selected
11. Reload the page to deselect all rows
12. Select only one row and click on "Receive selected" button
CHECK => the page /cgi-bin/koha/acqui/orderreceive.pl behaves just the same as if the "receive" link in the selected row would have been clicked.
13. Click on cancel to go back to parcel.pl page
14. Select all rows (even the ones from the next page of the table) and
click on "Receive selected"
CHECH => In orderreceive.pl page there is a table with all selected rows
15. Ensure table has more than one page, as in step 7
16. Click on the "edit" link in the last row of the current page
CHECK => A modal window is displayed with 4 tabs within: Info,
Accounting, Receipt history and Items
CHECK => Modal has 4 buttons at the bottom, 'Previous' to go to previos
order, 'Cancel' to close the modal without keeping modifications, 'Save'
to close modal keeping modifications and 'Next' to go to the next order
CHECK => Even that we are at the end of the current page, 'Next' button
is still available
17. Click on 'Next' button
CHECK => The table behind the modal now displays the next page, and the modal was not closed
18. Click on 'Previous'
CHECK => The table behind the modal went back to the first page, and the modal was not closed
19. Click on 'Previous' button till you reach the first row of the first
page
CHECK => Only when you reach the first row of the first page 'Previous'
button gets disabled
20. Click on 'Next' button till you reach the last row of the last page
CHECK => Only when you reach the last button of the last page 'Next'
button gets disabled
21. Check that behaviour for the different types of order are still the
same
a. For orders that where created through suggestion, check that the
suggestion info is present in Info tab. If when suggestion was accepted
you set a reason, a dropdown to change the reason shoul display also.
b. For orders that where created through subscriptions, check that
the Items tab is disabled, and the Receipt history is enabled. On
accounting tab you should be able to change quantity ordered. If there
were less items received than ordered, the next time you receive this
order the child order generated from this one shoul appear in receipt
history.
c. For orders that don't come from subscription and creates there items on ordering, Receipt history
should be disabled, and a table with prefilled items shold appear in the
Items tab. You can edit them and the changes should appear in the item's
row.
d. For orders that don't come from subscription and creates there
items on receiving, Receipt history should be disabled, and a form to
create the items should appear in Items tab. When you add an item a
table should appear.
e. For orders that don't come from subscription and creates there
ites on cataloguing, Receipt history and Items tabs should be disabled.
f. Any changes made in quantity (received or ordered) or funds in the modal should be
reflected in the table if you click save from the modal.
22. Once you've done all you checking and verifications click save
23. While saving a progress bar should appear
24. If no error was detected, you should be redirected back to parcel.pl
page
25. If an error or warning was detected (like there is an order with 0
items to receive) the save button should be disabled and warnings
are dispayed.
26. prove t/db_dependent/Koha/Acquisition/Fund.t t/db_dependent/Koha/Acquisitoin/Order.t t/db_dependent/Koha/Item.t
Sponsored-by: Virginia Polytechnic Institute and State University
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2020-10-09 20:15:31 +00:00
var PENDING_MULTI_SELECTION = _("Receive selected (%s)");
2020-11-06 18:16:00 +00:00
var columns_filter = {};
Bug 19755: Move template JavaScript to the footer: Acquisitions, part 3
This patch modifies even more staff client acquisitions templates so
that JavaScript is included in the footer instead of the header.
To test, apply the patch and test the JavaScript-driven features of the
modified templates: All button controls, DataTables functionality, tabs,
etc.
- Acquisitions -> Vendor -> Vendor details
- Contracts datatable
- Edit vendor
- Add contacts, form validation
- Acquisitions -> Vendor -> Invoices -> Invoice -> "Go to receipt"
- Datatables, MARC and Card previews
- Transfer
- Confirmation of transfer, window closes
- Acquisitions -> Vendor -> Receive shipments
- Datatables, date pickers
- Acquisitions -> Available funds table -> Spent report
- Datatables
- Acquisitions -> Vendor -> Uncertain prices
- Datatables, form validation
- Acquisitions -> Vendor -> Basket -> Add to basket from external source
- Select and clear all on search form
- Search results
- Datatables, MARC and Card previews, in-table pop-up controls
(click any table cell)
Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2017-12-05 18:30:08 +00:00
$(document).ready(function(){
2020-03-10 19:03:50 +00:00
2024-03-04 22:37:34 +00:00
$(".cancel_receipt").on( 'click', function(e){
e.preventDefault();
2024-03-05 16:21:31 +00:00
$('#cancel_ordernumber').val( $(this).data('ordernumber') );
$('#cancel_receipt').submit();
2024-03-04 22:37:34 +00:00
});
2020-03-10 19:03:50 +00:00
if ( $("#receivedt").length ) {
var receivedt = $("#receivedt").dataTable($.extend(true, {}, dataTablesDefaults, {
2024-10-03 08:44:01 +00:00
"stateSave": true, // We do not have table settings on this table
2023-09-28 17:43:32 +00:00
"pageLength": 10,
"lengthMenu": [[5, 10, 20, 50, 100, -1], [5, 10, 20, 50, 100, _("All")]],
"columnDefs": [
{ "targets": [ 5, -1 ], "orderable": false, "searchable": false },
2020-03-10 19:03:50 +00:00
],
2023-09-28 17:43:32 +00:00
"columns": [
{ "type": "html" },
{ "type": "html" },
{ "type": "html" },
{ "type": "num-html" },
{ "type": "anti-the" },
2020-03-10 19:03:50 +00:00
null,
null,
null,
null,
null,
null,
null,
null
],
2023-09-28 17:43:32 +00:00
"pagingType": "full"
2020-03-10 19:03:50 +00:00
}));
}
Bug 8179: Receive multiple orders
This patch implements the code to allow a patron to receive multiple
orders at the same time in /cgi-bin/koha/acqui/orderreceive.pl page
To test:
1. apply all patches
2. updatedatabase
3. Go to system preferences and allow AcqReceiveMultipleOrderLines
4. In acquisitions module, create a vendor if you don't have one and add
3 baskets.. one with create items on ordering, one with create items
on receiving and finally one with create items when cataloguing
5. Fill baskets with orders (There should be at least 15 orders in total). There should be a mix of orders created by suggestions, others by subscriptions and others by neither of those methods.
6. Close all baskets and receive shipment.
CHECK => in /cgi-bin/koha/acqui/parcel.pl page, in top table there is a column with checkboxes, and a button that says "Receive selected"
7. If all orders from all baskets are shown in the table, set the rows per page to 10, so table has more than one page
8. Check some of the checkboxes
CHECK => "Receive selected" button shows how many rows are selected
9. Go to the next page and select some more rows
CHECK => Changing page does not modify how many rows where selected
10. Go back to previous page
CHECK => Previously selected rows are still selected
11. Reload the page to deselect all rows
12. Select only one row and click on "Receive selected" button
CHECK => the page /cgi-bin/koha/acqui/orderreceive.pl behaves just the same as if the "receive" link in the selected row would have been clicked.
13. Click on cancel to go back to parcel.pl page
14. Select all rows (even the ones from the next page of the table) and
click on "Receive selected"
CHECH => In orderreceive.pl page there is a table with all selected rows
15. Ensure table has more than one page, as in step 7
16. Click on the "edit" link in the last row of the current page
CHECK => A modal window is displayed with 4 tabs within: Info,
Accounting, Receipt history and Items
CHECK => Modal has 4 buttons at the bottom, 'Previous' to go to previos
order, 'Cancel' to close the modal without keeping modifications, 'Save'
to close modal keeping modifications and 'Next' to go to the next order
CHECK => Even that we are at the end of the current page, 'Next' button
is still available
17. Click on 'Next' button
CHECK => The table behind the modal now displays the next page, and the modal was not closed
18. Click on 'Previous'
CHECK => The table behind the modal went back to the first page, and the modal was not closed
19. Click on 'Previous' button till you reach the first row of the first
page
CHECK => Only when you reach the first row of the first page 'Previous'
button gets disabled
20. Click on 'Next' button till you reach the last row of the last page
CHECK => Only when you reach the last button of the last page 'Next'
button gets disabled
21. Check that behaviour for the different types of order are still the
same
a. For orders that where created through suggestion, check that the
suggestion info is present in Info tab. If when suggestion was accepted
you set a reason, a dropdown to change the reason shoul display also.
b. For orders that where created through subscriptions, check that
the Items tab is disabled, and the Receipt history is enabled. On
accounting tab you should be able to change quantity ordered. If there
were less items received than ordered, the next time you receive this
order the child order generated from this one shoul appear in receipt
history.
c. For orders that don't come from subscription and creates there items on ordering, Receipt history
should be disabled, and a table with prefilled items shold appear in the
Items tab. You can edit them and the changes should appear in the item's
row.
d. For orders that don't come from subscription and creates there
items on receiving, Receipt history should be disabled, and a form to
create the items should appear in Items tab. When you add an item a
table should appear.
e. For orders that don't come from subscription and creates there
ites on cataloguing, Receipt history and Items tabs should be disabled.
f. Any changes made in quantity (received or ordered) or funds in the modal should be
reflected in the table if you click save from the modal.
22. Once you've done all you checking and verifications click save
23. While saving a progress bar should appear
24. If no error was detected, you should be redirected back to parcel.pl
page
25. If an error or warning was detected (like there is an order with 0
items to receive) the save button should be disabled and warnings
are dispayed.
26. prove t/db_dependent/Koha/Acquisition/Fund.t t/db_dependent/Koha/Acquisitoin/Order.t t/db_dependent/Koha/Item.t
Sponsored-by: Virginia Polytechnic Institute and State University
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2020-10-09 20:15:31 +00:00
var options = {
2020-03-10 19:03:50 +00:00
"ajax": {
2021-01-11 14:42:18 +00:00
"url": '/api/v1/acquisitions/orders?only_active=1'
2020-03-10 19:03:50 +00:00
},
"embed": [
"basket.basket_group",
2024-02-21 14:39:00 +00:00
"biblio.uncancelled_orders+count",
2020-03-10 19:03:50 +00:00
"biblio.holds+count",
"biblio.items+count",
"biblio.suggestions.suggester",
"fund",
"current_item_level_holds+count",
"items"
2017-12-29 16:16:23 +00:00
],
2020-03-10 19:03:50 +00:00
"columns": [
{ "data": "basket.name",
Bug 8179: Receive multiple orders
This patch implements the code to allow a patron to receive multiple
orders at the same time in /cgi-bin/koha/acqui/orderreceive.pl page
To test:
1. apply all patches
2. updatedatabase
3. Go to system preferences and allow AcqReceiveMultipleOrderLines
4. In acquisitions module, create a vendor if you don't have one and add
3 baskets.. one with create items on ordering, one with create items
on receiving and finally one with create items when cataloguing
5. Fill baskets with orders (There should be at least 15 orders in total). There should be a mix of orders created by suggestions, others by subscriptions and others by neither of those methods.
6. Close all baskets and receive shipment.
CHECK => in /cgi-bin/koha/acqui/parcel.pl page, in top table there is a column with checkboxes, and a button that says "Receive selected"
7. If all orders from all baskets are shown in the table, set the rows per page to 10, so table has more than one page
8. Check some of the checkboxes
CHECK => "Receive selected" button shows how many rows are selected
9. Go to the next page and select some more rows
CHECK => Changing page does not modify how many rows where selected
10. Go back to previous page
CHECK => Previously selected rows are still selected
11. Reload the page to deselect all rows
12. Select only one row and click on "Receive selected" button
CHECK => the page /cgi-bin/koha/acqui/orderreceive.pl behaves just the same as if the "receive" link in the selected row would have been clicked.
13. Click on cancel to go back to parcel.pl page
14. Select all rows (even the ones from the next page of the table) and
click on "Receive selected"
CHECH => In orderreceive.pl page there is a table with all selected rows
15. Ensure table has more than one page, as in step 7
16. Click on the "edit" link in the last row of the current page
CHECK => A modal window is displayed with 4 tabs within: Info,
Accounting, Receipt history and Items
CHECK => Modal has 4 buttons at the bottom, 'Previous' to go to previos
order, 'Cancel' to close the modal without keeping modifications, 'Save'
to close modal keeping modifications and 'Next' to go to the next order
CHECK => Even that we are at the end of the current page, 'Next' button
is still available
17. Click on 'Next' button
CHECK => The table behind the modal now displays the next page, and the modal was not closed
18. Click on 'Previous'
CHECK => The table behind the modal went back to the first page, and the modal was not closed
19. Click on 'Previous' button till you reach the first row of the first
page
CHECK => Only when you reach the first row of the first page 'Previous'
button gets disabled
20. Click on 'Next' button till you reach the last row of the last page
CHECK => Only when you reach the last button of the last page 'Next'
button gets disabled
21. Check that behaviour for the different types of order are still the
same
a. For orders that where created through suggestion, check that the
suggestion info is present in Info tab. If when suggestion was accepted
you set a reason, a dropdown to change the reason shoul display also.
b. For orders that where created through subscriptions, check that
the Items tab is disabled, and the Receipt history is enabled. On
accounting tab you should be able to change quantity ordered. If there
were less items received than ordered, the next time you receive this
order the child order generated from this one shoul appear in receipt
history.
c. For orders that don't come from subscription and creates there items on ordering, Receipt history
should be disabled, and a table with prefilled items shold appear in the
Items tab. You can edit them and the changes should appear in the item's
row.
d. For orders that don't come from subscription and creates there
items on receiving, Receipt history should be disabled, and a form to
create the items should appear in Items tab. When you add an item a
table should appear.
e. For orders that don't come from subscription and creates there
ites on cataloguing, Receipt history and Items tabs should be disabled.
f. Any changes made in quantity (received or ordered) or funds in the modal should be
reflected in the table if you click save from the modal.
22. Once you've done all you checking and verifications click save
23. While saving a progress bar should appear
24. If no error was detected, you should be redirected back to parcel.pl
page
25. If an error or warning was detected (like there is an order with 0
items to receive) the save button should be disabled and warnings
are dispayed.
26. prove t/db_dependent/Koha/Acquisition/Fund.t t/db_dependent/Koha/Acquisitoin/Order.t t/db_dependent/Koha/Item.t
Sponsored-by: Virginia Polytechnic Institute and State University
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2020-10-09 20:15:31 +00:00
"searchable": true,
2020-03-10 19:03:50 +00:00
"orderable": true,
"render": function(data, type, row, meta) {
2021-03-11 14:22:54 +00:00
if (type != 'display') return escape_str(data);
return "<a href=\"/cgi-bin/koha/acqui/basket.pl?basketno=" + encodeURIComponent(row.basket.basket_id) + "\">" + escape_str(data) + " (" + escape_str(row.basket.basket_id) + ")</a>";
2020-03-10 19:03:50 +00:00
}
},
{ "data": "basket.basket_group.name",
"orderable": true,
"render": function(data, type, row, meta) {
if ( type != 'display' ) {
2021-03-11 14:22:54 +00:00
return escape_str(data);
2020-03-10 19:03:50 +00:00
}
if ( row.basket.basket_group_id == null ) {
return _("No basket group");
}
else {
return "<a href=\"/cgi-bin/koha/acqui/basketgroup.pl?op=add&booksellerid="
2021-01-07 19:45:36 +00:00
+ encodeURIComponent(row.basket.vendor_id) + "&basketgroupid="
+ encodeURIComponent(row.basket.basket_group_id) + "\">"
2021-03-11 14:22:54 +00:00
+ escape_str(row.basket.basket_group.name) + " (" + escape_str(row.basket.basket_group_id) + ")</a>";
2020-03-10 19:03:50 +00:00
}
}
},
{
"data": "order_id",
"render": function(data, type, row, meta) {
2021-03-11 14:22:54 +00:00
if (type != 'display') return escape_str(data);
return "<a href=\"neworderempty.pl?ordernumber="+encodeURIComponent(data)+"&booksellerid="+encodeURIComponent(row.basket.vendor_id)+"\">"+escape_str(data)+"</a>";
2020-03-10 19:03:50 +00:00
}
},
{
2022-02-02 20:10:36 +00:00
[% SET summary_fields = "biblio.title:biblio.author:biblio.isbn:biblio.publisher:me.internal_note:me.vendor_note" %]
2021-01-28 08:08:22 +00:00
[% IF Koha.Preference('marcflavour')=='UNIMARC' %][% SET summary_fields = summary_fields _ ":biblio.ean" %][% END %]
2021-02-01 09:24:47 +00:00
"data": "[% summary_fields | html %]",
2021-01-11 14:42:18 +00:00
"render": function(data, type, row, meta) {
2020-03-10 19:03:50 +00:00
var result = '';
2021-01-11 14:42:18 +00:00
if ( row && row.biblio_id != null ) {
2021-03-11 14:22:54 +00:00
result = "<p><a href=\"/cgi-bin/koha/catalogue/detail.pl?biblionumber="+encodeURIComponent(row.biblio_id)+"\">"+escape_str(row.biblio.title)+"</a>";
2020-03-10 19:03:50 +00:00
if ( row.biblio.author != null )
2021-03-11 14:22:54 +00:00
result += _(" by ") + escape_str(row.biblio.author);
2020-03-10 19:03:50 +00:00
if ( row.biblio.isbn != null )
2021-03-11 14:22:54 +00:00
result += " – " + escape_str(row.biblio.isbn);
2021-01-13 10:17:48 +00:00
[% IF Koha.Preference('marcflavour')=='UNIMARC' %]
if ( row.biblio.ean != null )
2021-03-11 14:22:54 +00:00
result += " – EAN:" + escape_str(row.biblio.ean);
2021-01-13 10:17:48 +00:00
[% END %]
2020-03-10 19:03:50 +00:00
if ( row.biblio.publisher != null ) {
2021-03-11 14:22:54 +00:00
result += "<br/>" + _("Publisher: ") + escape_str(row.biblio.publisher);
2020-03-10 19:03:50 +00:00
if ( row.biblio.publication_year != null ) {
2021-03-11 14:22:54 +00:00
result += ", " + escape_str(row.biblio.publication_year);
2020-03-10 19:03:50 +00:00
}
else if ( row.biblio.copyright_date != null ) {
2021-03-11 14:22:54 +00:00
result += escape_str(row.biblio.copyright_date);
2020-03-10 19:03:50 +00:00
}
}
var suggestions = row.biblio.suggestions;
if ( suggestions != null && suggestions.length > 0 ) {
var suggestion = suggestions[0];
if ( suggestion.suggester != null ) {
var suggester = suggestion.suggester;
var suggested_by = [];
if ( suggester.surname != null ) {
2021-03-11 14:22:54 +00:00
suggested_by.push(escape_str(suggester.surname));
2020-03-10 19:03:50 +00:00
}
if ( suggester.firstname != null ) {
2021-03-11 14:22:54 +00:00
suggested_by.push(escape_str(suggester.firstname));
2020-03-10 19:03:50 +00:00
}
result += "<br/>" + _("Suggested by: ") +
'<a href="/cgi-bin/koha/suggestion/suggestion.pl?suggestionid='
+ encodeURIComponent(suggestion.suggestionid)
+ '&op=show">'
+ suggested_by.join(", ")
2021-03-11 14:22:54 +00:00
+ " (#" + escape_str(suggestions[0].suggestionid) + ")</a>"; // FIXME: could be changed if we allow matching multiple suggestions
2020-03-10 19:03:50 +00:00
}
}
result += '</p>';
}
var internal_note = row.internal_note;
if ( internal_note != null && internal_note != '' ) {
result += '<p class="ordernote"><strong>'
+ _("Internal note: ")
2021-03-11 14:22:54 +00:00
+ '</strong>' + escape_str(internal_note)
2020-03-10 19:03:50 +00:00
+ ' [<a href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber='
+ encodeURIComponent(row.order_id) + '&referrer=/cgi-bin/koha/acqui/parcel.pl%3Finvoiceid=[% invoiceid | uri %]'
+ '&type=internal">' + _("Change internal note") + '</a>]</p>';
}
else {
result += ' [<a href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber='
+ encodeURIComponent(row.order_id) + '&referrer=/cgi-bin/koha/acqui/parcel.pl%3Finvoiceid=[% invoiceid | uri %]'
+ '&type=internal">' + _("Add internal note") + '</a>]';
}
var vendor_note = row.vendor_note;
if ( vendor_note != null && vendor_note != '' ) {
result += '<p class="ordernote"><strong>'
+ _("Vendor note: ")
2021-03-11 14:22:54 +00:00
+ '</strong>' + escape_str(vendor_note) + '</p>';
2020-03-10 19:03:50 +00:00
}
else {
result += ' [<a href="/cgi-bin/koha/acqui/modordernotes.pl?ordernumber='
+ encodeURIComponent(row.order_id) + '&referrer=/cgi-bin/koha/acqui/parcel.pl%3Finvoiceid=[% invoiceid | uri %]'
+ '&type=vendor">' + _("Add vendor note") + '</a>]';
}
return result;
},
2022-02-02 20:10:36 +00:00
"orderable": true,
2020-03-10 19:03:50 +00:00
},
{
2021-01-11 14:42:18 +00:00
"data": "",
"render": function(data, type, row, meta) {
2022-03-22 11:25:12 +00:00
var result = '<div class="btn-group dropup">';
2024-01-03 19:33:07 +00:00
result += '<button id="view' + row.order_id + '" type="button" class="btn btn-default btn-xs">' + _("View") + '</button>';
result += '<button type="button" class="btn btn-default btn-xs dropdown-toggle dropdown-toggle-split" data-bs-toggle="dropdown" aria-expanded="false"><span class="visually-hidden">Toggle dropdown</span></button>';
2022-03-22 11:25:12 +00:00
result += '<ul class="dropdown-menu" aria-labelledby="view' + row.order_id + '">';
2024-08-29 10:41:27 +00:00
result += '<li><a class="dropdown-item previewData" href="/cgi-bin/koha/acqui/showorder.pl?ordernumber=' + encodeURIComponent(row.order_id) + '">[% tp("noun", "Order") | html %]</a></li>';
result += '<li><a class="dropdown-item previewData" href="/cgi-bin/koha/catalogue/showmarc.pl?id=' + encodeURIComponent(row.biblio_id) + '">' + _("MARC") + '</a></li>';
result += '<li><a class="dropdown-item previewData" href="/cgi-bin/koha/catalogue/showmarc.pl?viewas=card&id=' + encodeURIComponent(row.biblio_id) + '">' + _("Card") + '</a></li>';
2022-03-22 11:25:12 +00:00
result += '</ul>';
result += '</div>';
2020-03-10 19:03:50 +00:00
return result;
},
2021-01-11 14:42:18 +00:00
"orderable": false,
"searchable": false
2020-03-10 19:03:50 +00:00
},
{
2021-01-28 15:07:29 +00:00
"data": "replacement_price",
"render": function(data, type, row, meta) {
2021-03-11 14:22:54 +00:00
return escape_price(row.replacement_price);
2021-01-28 15:07:29 +00:00
},
2020-03-10 19:03:50 +00:00
},
{
"data": "quantity",
"orderable": true
},
{
2021-01-28 15:07:29 +00:00
"data": "ecost",
"render": function(data, type, row, meta) {
2021-03-11 14:22:54 +00:00
return escape_price(row.ecost);
2021-01-28 15:07:29 +00:00
},
2020-03-10 19:03:50 +00:00
},
{
2021-01-11 14:42:18 +00:00
"data": "",
"render": function(data, type, row, meta) {
2021-03-11 14:22:54 +00:00
return escape_price(row.quantity * row.ecost);
2020-03-10 19:03:50 +00:00
},
2021-01-11 14:42:18 +00:00
"orderable": false, // FIXME: How can we do it in DBIC?
"searchable": false
2020-03-10 19:03:50 +00:00
},
{
2021-01-08 14:04:32 +00:00
"data": "fund.name",
2020-03-10 19:03:50 +00:00
"render": function(data, type, row, meta) {
2021-03-11 14:22:54 +00:00
if (type != 'display') return escape_str(data);
return escape_str(row.fund.name);
2020-03-10 19:03:50 +00:00
}
},
{
2021-01-11 14:42:18 +00:00
"data": "",
"render": function(data, type, row, meta) {
Bug 8179: Receive multiple orders
This patch implements the code to allow a patron to receive multiple
orders at the same time in /cgi-bin/koha/acqui/orderreceive.pl page
To test:
1. apply all patches
2. updatedatabase
3. Go to system preferences and allow AcqReceiveMultipleOrderLines
4. In acquisitions module, create a vendor if you don't have one and add
3 baskets.. one with create items on ordering, one with create items
on receiving and finally one with create items when cataloguing
5. Fill baskets with orders (There should be at least 15 orders in total). There should be a mix of orders created by suggestions, others by subscriptions and others by neither of those methods.
6. Close all baskets and receive shipment.
CHECK => in /cgi-bin/koha/acqui/parcel.pl page, in top table there is a column with checkboxes, and a button that says "Receive selected"
7. If all orders from all baskets are shown in the table, set the rows per page to 10, so table has more than one page
8. Check some of the checkboxes
CHECK => "Receive selected" button shows how many rows are selected
9. Go to the next page and select some more rows
CHECK => Changing page does not modify how many rows where selected
10. Go back to previous page
CHECK => Previously selected rows are still selected
11. Reload the page to deselect all rows
12. Select only one row and click on "Receive selected" button
CHECK => the page /cgi-bin/koha/acqui/orderreceive.pl behaves just the same as if the "receive" link in the selected row would have been clicked.
13. Click on cancel to go back to parcel.pl page
14. Select all rows (even the ones from the next page of the table) and
click on "Receive selected"
CHECH => In orderreceive.pl page there is a table with all selected rows
15. Ensure table has more than one page, as in step 7
16. Click on the "edit" link in the last row of the current page
CHECK => A modal window is displayed with 4 tabs within: Info,
Accounting, Receipt history and Items
CHECK => Modal has 4 buttons at the bottom, 'Previous' to go to previos
order, 'Cancel' to close the modal without keeping modifications, 'Save'
to close modal keeping modifications and 'Next' to go to the next order
CHECK => Even that we are at the end of the current page, 'Next' button
is still available
17. Click on 'Next' button
CHECK => The table behind the modal now displays the next page, and the modal was not closed
18. Click on 'Previous'
CHECK => The table behind the modal went back to the first page, and the modal was not closed
19. Click on 'Previous' button till you reach the first row of the first
page
CHECK => Only when you reach the first row of the first page 'Previous'
button gets disabled
20. Click on 'Next' button till you reach the last row of the last page
CHECK => Only when you reach the last button of the last page 'Next'
button gets disabled
21. Check that behaviour for the different types of order are still the
same
a. For orders that where created through suggestion, check that the
suggestion info is present in Info tab. If when suggestion was accepted
you set a reason, a dropdown to change the reason shoul display also.
b. For orders that where created through subscriptions, check that
the Items tab is disabled, and the Receipt history is enabled. On
accounting tab you should be able to change quantity ordered. If there
were less items received than ordered, the next time you receive this
order the child order generated from this one shoul appear in receipt
history.
c. For orders that don't come from subscription and creates there items on ordering, Receipt history
should be disabled, and a table with prefilled items shold appear in the
Items tab. You can edit them and the changes should appear in the item's
row.
d. For orders that don't come from subscription and creates there
items on receiving, Receipt history should be disabled, and a form to
create the items should appear in Items tab. When you add an item a
table should appear.
e. For orders that don't come from subscription and creates there
ites on cataloguing, Receipt history and Items tabs should be disabled.
f. Any changes made in quantity (received or ordered) or funds in the modal should be
reflected in the table if you click save from the modal.
22. Once you've done all you checking and verifications click save
23. While saving a progress bar should appear
24. If no error was detected, you should be redirected back to parcel.pl
page
25. If an error or warning was detected (like there is an order with 0
items to receive) the save button should be disabled and warnings
are dispayed.
26. prove t/db_dependent/Koha/Acquisition/Fund.t t/db_dependent/Koha/Acquisitoin/Order.t t/db_dependent/Koha/Item.t
Sponsored-by: Virginia Polytechnic Institute and State University
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2020-10-09 20:15:31 +00:00
return '<a href="orderreceive.pl?multiple_orders='
2020-03-10 19:03:50 +00:00
+ encodeURIComponent(row.order_id) + '&invoiceid=[% invoiceid | uri %]' + '">'
+ _("Receive") + '</a><br/>'
2021-03-11 14:22:54 +00:00
+ '<a href="#" onclick="transfer_order_popup(' + escape_str(row.order_id) + '); return false;">'
2020-03-10 19:03:50 +00:00
+ _("Transfer") + '</a>';
},
2021-01-11 14:42:18 +00:00
"orderable": false,
"searchable": false
2020-03-10 19:03:50 +00:00
},
{
2021-01-11 14:42:18 +00:00
"data": "",
"render": function(data, type, row, meta) {
2020-03-10 19:03:50 +00:00
var result = "";
if ( row.current_holds_count > 0 ) {
result += '<span class="button" title="'
2021-03-11 14:22:54 +00:00
+ _("Can't cancel order, (%s) holds are linked with this order. Cancel holds first").format( escape_str(row.holds_count) ) + '">'
2020-03-10 19:03:50 +00:00
+ _("Can't cancel order") + '</span><br/>';
}
else {
result += '<a href="/cgi-bin/koha/acqui/cancelorder.pl?ordernumber='
+ encodeURIComponent(row.order_id)
+ '&biblionumber=' + encodeURIComponent(row.biblio_id)
+ '&referrer=/cgi-bin/koha/acqui/parcel.pl?invoiceid=[% invoiceid | uri %]">'
+ _("Cancel order") + '</a><br/>';
}
if ( row.biblio != null ) {
if ( row.biblio.items_count - row.items.length > 0 ||
2024-02-21 14:39:00 +00:00
row.biblio.uncancelled_orders_count > 1 ||
2020-03-10 19:03:50 +00:00
row.biblio.subscriptions_count > 0 ||
row.biblio.holds_count > 0 ) { // biblio can be deleted
result += '<span class="button" title="'
+ _("Can't delete catalog record, see constraints below") + '">'
+ _("Can't cancel order and delete catalog record") + '</span><br>';
}
else {
result += '<a href="/cgi-bin/koha/acqui/cancelorder.pl?ordernumber='
+ encodeURIComponent(row.order_id) + '&biblionumber=' + encodeURIComponent(row.biblio_id)
+ '&del_biblio=1&referrer="/cgi-bin/koha/acqui/parcel.pl?invoiceid=[$ invoiceid | uri ]">'
+ _("Cancel order and catalog record") + '</a><br/>';
}
if ( row.biblio.items_count - row.items.length > 0 ) {
result += '<strong title="'
+ _("Can't delete catalog record, because of %s existing item(s)").format(row.items.length)
+'">' + (row.biblio.items_count - row.items.length) + _(" item(s) left") + '</strong><br/>';
}
2024-02-21 14:39:00 +00:00
if ( row.biblio.uncancelled_orders_count > 1 ) {
2020-03-10 19:03:50 +00:00
result += '<strong title="'
+ _("Can't delete catalog record, delete other orders linked to it first") + '">'
2024-02-21 14:39:00 +00:00
+ (row.biblio.uncancelled_orders_count - 1) + _(" order(s) left") + '</strong><br/>';
2020-03-10 19:03:50 +00:00
}
if ( row.biblio.subscriptions_count > 0 ) {
result += '<strong title="' + _("Can't delete catalog record, delete subscriptions first") + '">'
+ _("%s subscription(s) left").format(row.biblio.subscriptions_count)
+ '</strong><br>';
}
if ( row.biblio.holds_count > 0 ) {
result += '<strong title="' + _("Can't delete catalog record or order, cancel holds first") + '">'
+ _("%s hold(s) left").format(row.biblio.holds_count) + '</strong>';
}
}
return result;
},
2021-01-11 14:42:18 +00:00
"orderable": false,
"searchable": false
2020-03-10 19:03:50 +00:00
}
2017-12-29 16:16:23 +00:00
]
Bug 8179: Receive multiple orders
This patch implements the code to allow a patron to receive multiple
orders at the same time in /cgi-bin/koha/acqui/orderreceive.pl page
To test:
1. apply all patches
2. updatedatabase
3. Go to system preferences and allow AcqReceiveMultipleOrderLines
4. In acquisitions module, create a vendor if you don't have one and add
3 baskets.. one with create items on ordering, one with create items
on receiving and finally one with create items when cataloguing
5. Fill baskets with orders (There should be at least 15 orders in total). There should be a mix of orders created by suggestions, others by subscriptions and others by neither of those methods.
6. Close all baskets and receive shipment.
CHECK => in /cgi-bin/koha/acqui/parcel.pl page, in top table there is a column with checkboxes, and a button that says "Receive selected"
7. If all orders from all baskets are shown in the table, set the rows per page to 10, so table has more than one page
8. Check some of the checkboxes
CHECK => "Receive selected" button shows how many rows are selected
9. Go to the next page and select some more rows
CHECK => Changing page does not modify how many rows where selected
10. Go back to previous page
CHECK => Previously selected rows are still selected
11. Reload the page to deselect all rows
12. Select only one row and click on "Receive selected" button
CHECK => the page /cgi-bin/koha/acqui/orderreceive.pl behaves just the same as if the "receive" link in the selected row would have been clicked.
13. Click on cancel to go back to parcel.pl page
14. Select all rows (even the ones from the next page of the table) and
click on "Receive selected"
CHECH => In orderreceive.pl page there is a table with all selected rows
15. Ensure table has more than one page, as in step 7
16. Click on the "edit" link in the last row of the current page
CHECK => A modal window is displayed with 4 tabs within: Info,
Accounting, Receipt history and Items
CHECK => Modal has 4 buttons at the bottom, 'Previous' to go to previos
order, 'Cancel' to close the modal without keeping modifications, 'Save'
to close modal keeping modifications and 'Next' to go to the next order
CHECK => Even that we are at the end of the current page, 'Next' button
is still available
17. Click on 'Next' button
CHECK => The table behind the modal now displays the next page, and the modal was not closed
18. Click on 'Previous'
CHECK => The table behind the modal went back to the first page, and the modal was not closed
19. Click on 'Previous' button till you reach the first row of the first
page
CHECK => Only when you reach the first row of the first page 'Previous'
button gets disabled
20. Click on 'Next' button till you reach the last row of the last page
CHECK => Only when you reach the last button of the last page 'Next'
button gets disabled
21. Check that behaviour for the different types of order are still the
same
a. For orders that where created through suggestion, check that the
suggestion info is present in Info tab. If when suggestion was accepted
you set a reason, a dropdown to change the reason shoul display also.
b. For orders that where created through subscriptions, check that
the Items tab is disabled, and the Receipt history is enabled. On
accounting tab you should be able to change quantity ordered. If there
were less items received than ordered, the next time you receive this
order the child order generated from this one shoul appear in receipt
history.
c. For orders that don't come from subscription and creates there items on ordering, Receipt history
should be disabled, and a table with prefilled items shold appear in the
Items tab. You can edit them and the changes should appear in the item's
row.
d. For orders that don't come from subscription and creates there
items on receiving, Receipt history should be disabled, and a form to
create the items should appear in Items tab. When you add an item a
table should appear.
e. For orders that don't come from subscription and creates there
ites on cataloguing, Receipt history and Items tabs should be disabled.
f. Any changes made in quantity (received or ordered) or funds in the modal should be
reflected in the table if you click save from the modal.
22. Once you've done all you checking and verifications click save
23. While saving a progress bar should appear
24. If no error was detected, you should be redirected back to parcel.pl
page
25. If an error or warning was detected (like there is an order with 0
items to receive) the save button should be disabled and warnings
are dispayed.
26. prove t/db_dependent/Koha/Acquisition/Fund.t t/db_dependent/Koha/Acquisitoin/Order.t t/db_dependent/Koha/Item.t
Sponsored-by: Virginia Polytechnic Institute and State University
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2020-10-09 20:15:31 +00:00
};
var selected_rows = {};
2023-05-11 15:11:40 +00:00
$('#select_multiple').click(function () {
var ids = Object.keys(selected_rows);
if (!ids.length) return;
location.href = 'orderreceive.pl?multiple_orders=' + ids.join(',') + '&invoiceid=[% invoiceid | uri %]';
Bug 8179: Receive multiple orders
This patch implements the code to allow a patron to receive multiple
orders at the same time in /cgi-bin/koha/acqui/orderreceive.pl page
To test:
1. apply all patches
2. updatedatabase
3. Go to system preferences and allow AcqReceiveMultipleOrderLines
4. In acquisitions module, create a vendor if you don't have one and add
3 baskets.. one with create items on ordering, one with create items
on receiving and finally one with create items when cataloguing
5. Fill baskets with orders (There should be at least 15 orders in total). There should be a mix of orders created by suggestions, others by subscriptions and others by neither of those methods.
6. Close all baskets and receive shipment.
CHECK => in /cgi-bin/koha/acqui/parcel.pl page, in top table there is a column with checkboxes, and a button that says "Receive selected"
7. If all orders from all baskets are shown in the table, set the rows per page to 10, so table has more than one page
8. Check some of the checkboxes
CHECK => "Receive selected" button shows how many rows are selected
9. Go to the next page and select some more rows
CHECK => Changing page does not modify how many rows where selected
10. Go back to previous page
CHECK => Previously selected rows are still selected
11. Reload the page to deselect all rows
12. Select only one row and click on "Receive selected" button
CHECK => the page /cgi-bin/koha/acqui/orderreceive.pl behaves just the same as if the "receive" link in the selected row would have been clicked.
13. Click on cancel to go back to parcel.pl page
14. Select all rows (even the ones from the next page of the table) and
click on "Receive selected"
CHECH => In orderreceive.pl page there is a table with all selected rows
15. Ensure table has more than one page, as in step 7
16. Click on the "edit" link in the last row of the current page
CHECK => A modal window is displayed with 4 tabs within: Info,
Accounting, Receipt history and Items
CHECK => Modal has 4 buttons at the bottom, 'Previous' to go to previos
order, 'Cancel' to close the modal without keeping modifications, 'Save'
to close modal keeping modifications and 'Next' to go to the next order
CHECK => Even that we are at the end of the current page, 'Next' button
is still available
17. Click on 'Next' button
CHECK => The table behind the modal now displays the next page, and the modal was not closed
18. Click on 'Previous'
CHECK => The table behind the modal went back to the first page, and the modal was not closed
19. Click on 'Previous' button till you reach the first row of the first
page
CHECK => Only when you reach the first row of the first page 'Previous'
button gets disabled
20. Click on 'Next' button till you reach the last row of the last page
CHECK => Only when you reach the last button of the last page 'Next'
button gets disabled
21. Check that behaviour for the different types of order are still the
same
a. For orders that where created through suggestion, check that the
suggestion info is present in Info tab. If when suggestion was accepted
you set a reason, a dropdown to change the reason shoul display also.
b. For orders that where created through subscriptions, check that
the Items tab is disabled, and the Receipt history is enabled. On
accounting tab you should be able to change quantity ordered. If there
were less items received than ordered, the next time you receive this
order the child order generated from this one shoul appear in receipt
history.
c. For orders that don't come from subscription and creates there items on ordering, Receipt history
should be disabled, and a table with prefilled items shold appear in the
Items tab. You can edit them and the changes should appear in the item's
row.
d. For orders that don't come from subscription and creates there
items on receiving, Receipt history should be disabled, and a form to
create the items should appear in Items tab. When you add an item a
table should appear.
e. For orders that don't come from subscription and creates there
ites on cataloguing, Receipt history and Items tabs should be disabled.
f. Any changes made in quantity (received or ordered) or funds in the modal should be
reflected in the table if you click save from the modal.
22. Once you've done all you checking and verifications click save
23. While saving a progress bar should appear
24. If no error was detected, you should be redirected back to parcel.pl
page
25. If an error or warning was detected (like there is an order with 0
items to receive) the save button should be disabled and warnings
are dispayed.
26. prove t/db_dependent/Koha/Acquisition/Fund.t t/db_dependent/Koha/Acquisitoin/Order.t t/db_dependent/Koha/Item.t
Sponsored-by: Virginia Polytechnic Institute and State University
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2020-10-09 20:15:31 +00:00
}).html(PENDING_MULTI_SELECTION.format('0'))
options.order = [[1, 'asc']];
options.columns.unshift({
2023-05-11 15:11:40 +00:00
"data": function (row, type, val, meta) {
return '<input type="checkbox" class="selOrder" />';
},
"searchable": false,
"orderable": false
Bug 8179: Receive multiple orders
This patch implements the code to allow a patron to receive multiple
orders at the same time in /cgi-bin/koha/acqui/orderreceive.pl page
To test:
1. apply all patches
2. updatedatabase
3. Go to system preferences and allow AcqReceiveMultipleOrderLines
4. In acquisitions module, create a vendor if you don't have one and add
3 baskets.. one with create items on ordering, one with create items
on receiving and finally one with create items when cataloguing
5. Fill baskets with orders (There should be at least 15 orders in total). There should be a mix of orders created by suggestions, others by subscriptions and others by neither of those methods.
6. Close all baskets and receive shipment.
CHECK => in /cgi-bin/koha/acqui/parcel.pl page, in top table there is a column with checkboxes, and a button that says "Receive selected"
7. If all orders from all baskets are shown in the table, set the rows per page to 10, so table has more than one page
8. Check some of the checkboxes
CHECK => "Receive selected" button shows how many rows are selected
9. Go to the next page and select some more rows
CHECK => Changing page does not modify how many rows where selected
10. Go back to previous page
CHECK => Previously selected rows are still selected
11. Reload the page to deselect all rows
12. Select only one row and click on "Receive selected" button
CHECK => the page /cgi-bin/koha/acqui/orderreceive.pl behaves just the same as if the "receive" link in the selected row would have been clicked.
13. Click on cancel to go back to parcel.pl page
14. Select all rows (even the ones from the next page of the table) and
click on "Receive selected"
CHECH => In orderreceive.pl page there is a table with all selected rows
15. Ensure table has more than one page, as in step 7
16. Click on the "edit" link in the last row of the current page
CHECK => A modal window is displayed with 4 tabs within: Info,
Accounting, Receipt history and Items
CHECK => Modal has 4 buttons at the bottom, 'Previous' to go to previos
order, 'Cancel' to close the modal without keeping modifications, 'Save'
to close modal keeping modifications and 'Next' to go to the next order
CHECK => Even that we are at the end of the current page, 'Next' button
is still available
17. Click on 'Next' button
CHECK => The table behind the modal now displays the next page, and the modal was not closed
18. Click on 'Previous'
CHECK => The table behind the modal went back to the first page, and the modal was not closed
19. Click on 'Previous' button till you reach the first row of the first
page
CHECK => Only when you reach the first row of the first page 'Previous'
button gets disabled
20. Click on 'Next' button till you reach the last row of the last page
CHECK => Only when you reach the last button of the last page 'Next'
button gets disabled
21. Check that behaviour for the different types of order are still the
same
a. For orders that where created through suggestion, check that the
suggestion info is present in Info tab. If when suggestion was accepted
you set a reason, a dropdown to change the reason shoul display also.
b. For orders that where created through subscriptions, check that
the Items tab is disabled, and the Receipt history is enabled. On
accounting tab you should be able to change quantity ordered. If there
were less items received than ordered, the next time you receive this
order the child order generated from this one shoul appear in receipt
history.
c. For orders that don't come from subscription and creates there items on ordering, Receipt history
should be disabled, and a table with prefilled items shold appear in the
Items tab. You can edit them and the changes should appear in the item's
row.
d. For orders that don't come from subscription and creates there
items on receiving, Receipt history should be disabled, and a form to
create the items should appear in Items tab. When you add an item a
table should appear.
e. For orders that don't come from subscription and creates there
ites on cataloguing, Receipt history and Items tabs should be disabled.
f. Any changes made in quantity (received or ordered) or funds in the modal should be
reflected in the table if you click save from the modal.
22. Once you've done all you checking and verifications click save
23. While saving a progress bar should appear
24. If no error was detected, you should be redirected back to parcel.pl
page
25. If an error or warning was detected (like there is an order with 0
items to receive) the save button should be disabled and warnings
are dispayed.
26. prove t/db_dependent/Koha/Acquisition/Fund.t t/db_dependent/Koha/Acquisitoin/Order.t t/db_dependent/Koha/Item.t
Sponsored-by: Virginia Polytechnic Institute and State University
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2020-10-09 20:15:31 +00:00
});
2024-10-03 08:50:57 +00:00
let table_settings = [% TablesSettings.GetTableSettings( 'acqui', 'parcel', 'pending_orders', 'json' ) | $raw %];
var pending_orders_table = $("#pending_orders").kohaTable(options, table_settings, 1, { "basket.vendor_id": [% booksellerid | html %] });
Bug 8179: Receive multiple orders
This patch implements the code to allow a patron to receive multiple
orders at the same time in /cgi-bin/koha/acqui/orderreceive.pl page
To test:
1. apply all patches
2. updatedatabase
3. Go to system preferences and allow AcqReceiveMultipleOrderLines
4. In acquisitions module, create a vendor if you don't have one and add
3 baskets.. one with create items on ordering, one with create items
on receiving and finally one with create items when cataloguing
5. Fill baskets with orders (There should be at least 15 orders in total). There should be a mix of orders created by suggestions, others by subscriptions and others by neither of those methods.
6. Close all baskets and receive shipment.
CHECK => in /cgi-bin/koha/acqui/parcel.pl page, in top table there is a column with checkboxes, and a button that says "Receive selected"
7. If all orders from all baskets are shown in the table, set the rows per page to 10, so table has more than one page
8. Check some of the checkboxes
CHECK => "Receive selected" button shows how many rows are selected
9. Go to the next page and select some more rows
CHECK => Changing page does not modify how many rows where selected
10. Go back to previous page
CHECK => Previously selected rows are still selected
11. Reload the page to deselect all rows
12. Select only one row and click on "Receive selected" button
CHECK => the page /cgi-bin/koha/acqui/orderreceive.pl behaves just the same as if the "receive" link in the selected row would have been clicked.
13. Click on cancel to go back to parcel.pl page
14. Select all rows (even the ones from the next page of the table) and
click on "Receive selected"
CHECH => In orderreceive.pl page there is a table with all selected rows
15. Ensure table has more than one page, as in step 7
16. Click on the "edit" link in the last row of the current page
CHECK => A modal window is displayed with 4 tabs within: Info,
Accounting, Receipt history and Items
CHECK => Modal has 4 buttons at the bottom, 'Previous' to go to previos
order, 'Cancel' to close the modal without keeping modifications, 'Save'
to close modal keeping modifications and 'Next' to go to the next order
CHECK => Even that we are at the end of the current page, 'Next' button
is still available
17. Click on 'Next' button
CHECK => The table behind the modal now displays the next page, and the modal was not closed
18. Click on 'Previous'
CHECK => The table behind the modal went back to the first page, and the modal was not closed
19. Click on 'Previous' button till you reach the first row of the first
page
CHECK => Only when you reach the first row of the first page 'Previous'
button gets disabled
20. Click on 'Next' button till you reach the last row of the last page
CHECK => Only when you reach the last button of the last page 'Next'
button gets disabled
21. Check that behaviour for the different types of order are still the
same
a. For orders that where created through suggestion, check that the
suggestion info is present in Info tab. If when suggestion was accepted
you set a reason, a dropdown to change the reason shoul display also.
b. For orders that where created through subscriptions, check that
the Items tab is disabled, and the Receipt history is enabled. On
accounting tab you should be able to change quantity ordered. If there
were less items received than ordered, the next time you receive this
order the child order generated from this one shoul appear in receipt
history.
c. For orders that don't come from subscription and creates there items on ordering, Receipt history
should be disabled, and a table with prefilled items shold appear in the
Items tab. You can edit them and the changes should appear in the item's
row.
d. For orders that don't come from subscription and creates there
items on receiving, Receipt history should be disabled, and a form to
create the items should appear in Items tab. When you add an item a
table should appear.
e. For orders that don't come from subscription and creates there
ites on cataloguing, Receipt history and Items tabs should be disabled.
f. Any changes made in quantity (received or ordered) or funds in the modal should be
reflected in the table if you click save from the modal.
22. Once you've done all you checking and verifications click save
23. While saving a progress bar should appear
24. If no error was detected, you should be redirected back to parcel.pl
page
25. If an error or warning was detected (like there is an order with 0
items to receive) the save button should be disabled and warnings
are dispayed.
26. prove t/db_dependent/Koha/Acquisition/Fund.t t/db_dependent/Koha/Acquisitoin/Order.t t/db_dependent/Koha/Item.t
Sponsored-by: Virginia Polytechnic Institute and State University
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2020-10-09 20:15:31 +00:00
var api = pending_orders_table.api();
2023-05-11 15:11:40 +00:00
api.on('draw', function () {
api.rows().every(function () {
var row = this;
var data = row.data();
$('.selOrder', row.node()).on('click', function (event) {
if ($(this).prop('checked')) {
selected_rows[data.order_id] = data;
} else {
delete selected_rows[data.order_id];
}
$('#select_multiple').html(PENDING_MULTI_SELECTION.format(Object.keys(selected_rows).length));
});
if (selected_rows[data.order_id]) {
$('.selOrder', row.node()).prop('checked', true);
}
Bug 8179: Receive multiple orders
This patch implements the code to allow a patron to receive multiple
orders at the same time in /cgi-bin/koha/acqui/orderreceive.pl page
To test:
1. apply all patches
2. updatedatabase
3. Go to system preferences and allow AcqReceiveMultipleOrderLines
4. In acquisitions module, create a vendor if you don't have one and add
3 baskets.. one with create items on ordering, one with create items
on receiving and finally one with create items when cataloguing
5. Fill baskets with orders (There should be at least 15 orders in total). There should be a mix of orders created by suggestions, others by subscriptions and others by neither of those methods.
6. Close all baskets and receive shipment.
CHECK => in /cgi-bin/koha/acqui/parcel.pl page, in top table there is a column with checkboxes, and a button that says "Receive selected"
7. If all orders from all baskets are shown in the table, set the rows per page to 10, so table has more than one page
8. Check some of the checkboxes
CHECK => "Receive selected" button shows how many rows are selected
9. Go to the next page and select some more rows
CHECK => Changing page does not modify how many rows where selected
10. Go back to previous page
CHECK => Previously selected rows are still selected
11. Reload the page to deselect all rows
12. Select only one row and click on "Receive selected" button
CHECK => the page /cgi-bin/koha/acqui/orderreceive.pl behaves just the same as if the "receive" link in the selected row would have been clicked.
13. Click on cancel to go back to parcel.pl page
14. Select all rows (even the ones from the next page of the table) and
click on "Receive selected"
CHECH => In orderreceive.pl page there is a table with all selected rows
15. Ensure table has more than one page, as in step 7
16. Click on the "edit" link in the last row of the current page
CHECK => A modal window is displayed with 4 tabs within: Info,
Accounting, Receipt history and Items
CHECK => Modal has 4 buttons at the bottom, 'Previous' to go to previos
order, 'Cancel' to close the modal without keeping modifications, 'Save'
to close modal keeping modifications and 'Next' to go to the next order
CHECK => Even that we are at the end of the current page, 'Next' button
is still available
17. Click on 'Next' button
CHECK => The table behind the modal now displays the next page, and the modal was not closed
18. Click on 'Previous'
CHECK => The table behind the modal went back to the first page, and the modal was not closed
19. Click on 'Previous' button till you reach the first row of the first
page
CHECK => Only when you reach the first row of the first page 'Previous'
button gets disabled
20. Click on 'Next' button till you reach the last row of the last page
CHECK => Only when you reach the last button of the last page 'Next'
button gets disabled
21. Check that behaviour for the different types of order are still the
same
a. For orders that where created through suggestion, check that the
suggestion info is present in Info tab. If when suggestion was accepted
you set a reason, a dropdown to change the reason shoul display also.
b. For orders that where created through subscriptions, check that
the Items tab is disabled, and the Receipt history is enabled. On
accounting tab you should be able to change quantity ordered. If there
were less items received than ordered, the next time you receive this
order the child order generated from this one shoul appear in receipt
history.
c. For orders that don't come from subscription and creates there items on ordering, Receipt history
should be disabled, and a table with prefilled items shold appear in the
Items tab. You can edit them and the changes should appear in the item's
row.
d. For orders that don't come from subscription and creates there
items on receiving, Receipt history should be disabled, and a form to
create the items should appear in Items tab. When you add an item a
table should appear.
e. For orders that don't come from subscription and creates there
ites on cataloguing, Receipt history and Items tabs should be disabled.
f. Any changes made in quantity (received or ordered) or funds in the modal should be
reflected in the table if you click save from the modal.
22. Once you've done all you checking and verifications click save
23. While saving a progress bar should appear
24. If no error was detected, you should be redirected back to parcel.pl
page
25. If an error or warning was detected (like there is an order with 0
items to receive) the save button should be disabled and warnings
are dispayed.
26. prove t/db_dependent/Koha/Acquisition/Fund.t t/db_dependent/Koha/Acquisitoin/Order.t t/db_dependent/Koha/Item.t
Sponsored-by: Virginia Polytechnic Institute and State University
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2020-10-09 20:15:31 +00:00
});
});
2024-01-03 19:33:07 +00:00
$("#dataPreview").on("hidden.bs.modal", function(){
$("#dataPreviewLabel").html("");
$("#dataPreview .modal-body").html("<div id=\"loading\"><img src=\"[% interface | html %]/[% theme | html %]/img/spinner-small.gif\" alt=\"\" /> "+_("Loading")+"</div>");
});
2020-03-10 19:03:50 +00:00
2024-01-03 19:33:07 +00:00
$("body").on("click", ".previewData", function(e){
Bug 19755: Move template JavaScript to the footer: Acquisitions, part 3
This patch modifies even more staff client acquisitions templates so
that JavaScript is included in the footer instead of the header.
To test, apply the patch and test the JavaScript-driven features of the
modified templates: All button controls, DataTables functionality, tabs,
etc.
- Acquisitions -> Vendor -> Vendor details
- Contracts datatable
- Edit vendor
- Add contacts, form validation
- Acquisitions -> Vendor -> Invoices -> Invoice -> "Go to receipt"
- Datatables, MARC and Card previews
- Transfer
- Confirmation of transfer, window closes
- Acquisitions -> Vendor -> Receive shipments
- Datatables, date pickers
- Acquisitions -> Available funds table -> Spent report
- Datatables
- Acquisitions -> Vendor -> Uncertain prices
- Datatables, form validation
- Acquisitions -> Vendor -> Basket -> Add to basket from external source
- Select and clear all on search form
- Search results
- Datatables, MARC and Card previews, in-table pop-up controls
(click any table cell)
Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2017-12-05 18:30:08 +00:00
e.preventDefault();
var ltitle = $(this).text();
var page = $(this).attr("href");
$("#dataPreviewLabel").text(ltitle);
$("#dataPreview .modal-body").load(page + " div");
2022-03-22 11:25:12 +00:00
$('#dataPreview').modal("show");
Bug 19755: Move template JavaScript to the footer: Acquisitions, part 3
This patch modifies even more staff client acquisitions templates so
that JavaScript is included in the footer instead of the header.
To test, apply the patch and test the JavaScript-driven features of the
modified templates: All button controls, DataTables functionality, tabs,
etc.
- Acquisitions -> Vendor -> Vendor details
- Contracts datatable
- Edit vendor
- Add contacts, form validation
- Acquisitions -> Vendor -> Invoices -> Invoice -> "Go to receipt"
- Datatables, MARC and Card previews
- Transfer
- Confirmation of transfer, window closes
- Acquisitions -> Vendor -> Receive shipments
- Datatables, date pickers
- Acquisitions -> Available funds table -> Spent report
- Datatables
- Acquisitions -> Vendor -> Uncertain prices
- Datatables, form validation
- Acquisitions -> Vendor -> Basket -> Add to basket from external source
- Select and clear all on search form
- Search results
- Datatables, MARC and Card previews, in-table pop-up controls
(click any table cell)
Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2017-12-05 18:30:08 +00:00
});
2020-03-10 19:03:50 +00:00
});
// Case-insensitive version of jquery's contains function
jQuery.extend(jQuery.expr[':'], {
icontains : "jQuery(a).text().toUpperCase().indexOf(m[3].toUpperCase())>=0"
});
Bug 19755: Move template JavaScript to the footer: Acquisitions, part 3
This patch modifies even more staff client acquisitions templates so
that JavaScript is included in the footer instead of the header.
To test, apply the patch and test the JavaScript-driven features of the
modified templates: All button controls, DataTables functionality, tabs,
etc.
- Acquisitions -> Vendor -> Vendor details
- Contracts datatable
- Edit vendor
- Add contacts, form validation
- Acquisitions -> Vendor -> Invoices -> Invoice -> "Go to receipt"
- Datatables, MARC and Card previews
- Transfer
- Confirmation of transfer, window closes
- Acquisitions -> Vendor -> Receive shipments
- Datatables, date pickers
- Acquisitions -> Available funds table -> Spent report
- Datatables
- Acquisitions -> Vendor -> Uncertain prices
- Datatables, form validation
- Acquisitions -> Vendor -> Basket -> Add to basket from external source
- Select and clear all on search form
- Search results
- Datatables, MARC and Card previews, in-table pop-up controls
(click any table cell)
Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2017-12-05 18:30:08 +00:00
2020-03-10 19:03:50 +00:00
// Contains exactly function
jQuery.extend(jQuery.expr[':'], {
containsExactly: "$(a).text() == m[3]"
Bug 19755: Move template JavaScript to the footer: Acquisitions, part 3
This patch modifies even more staff client acquisitions templates so
that JavaScript is included in the footer instead of the header.
To test, apply the patch and test the JavaScript-driven features of the
modified templates: All button controls, DataTables functionality, tabs,
etc.
- Acquisitions -> Vendor -> Vendor details
- Contracts datatable
- Edit vendor
- Add contacts, form validation
- Acquisitions -> Vendor -> Invoices -> Invoice -> "Go to receipt"
- Datatables, MARC and Card previews
- Transfer
- Confirmation of transfer, window closes
- Acquisitions -> Vendor -> Receive shipments
- Datatables, date pickers
- Acquisitions -> Available funds table -> Spent report
- Datatables
- Acquisitions -> Vendor -> Uncertain prices
- Datatables, form validation
- Acquisitions -> Vendor -> Basket -> Add to basket from external source
- Select and clear all on search form
- Search results
- Datatables, MARC and Card previews, in-table pop-up controls
(click any table cell)
Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2017-12-05 18:30:08 +00:00
});
2020-03-10 19:03:50 +00:00
function transfer_order_popup(ordernumber) {
var url = "/cgi-bin/koha/acqui/transferorder.pl?"
+ "ordernumber=" + ordernumber
window.open(url, 'TransferOrder');
}
Bug 19755: Move template JavaScript to the footer: Acquisitions, part 3
This patch modifies even more staff client acquisitions templates so
that JavaScript is included in the footer instead of the header.
To test, apply the patch and test the JavaScript-driven features of the
modified templates: All button controls, DataTables functionality, tabs,
etc.
- Acquisitions -> Vendor -> Vendor details
- Contracts datatable
- Edit vendor
- Add contacts, form validation
- Acquisitions -> Vendor -> Invoices -> Invoice -> "Go to receipt"
- Datatables, MARC and Card previews
- Transfer
- Confirmation of transfer, window closes
- Acquisitions -> Vendor -> Receive shipments
- Datatables, date pickers
- Acquisitions -> Available funds table -> Spent report
- Datatables
- Acquisitions -> Vendor -> Uncertain prices
- Datatables, form validation
- Acquisitions -> Vendor -> Basket -> Add to basket from external source
- Select and clear all on search form
- Search results
- Datatables, MARC and Card previews, in-table pop-up controls
(click any table cell)
Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2017-12-05 18:30:08 +00:00
</script>
[% END %]
2011-03-21 07:02:15 +00:00
[% INCLUDE 'intranet-bottom.inc' %]