From c5d89cb5c2b1bda54c9df0e7f9eeab3f9f9c1bd0 Mon Sep 17 00:00:00 2001 From: Aleisha Amohia Date: Tue, 23 Jul 2024 02:50:29 +0000 Subject: [PATCH] Bug 31632: Link a suggestion to an existing order This enhancement allows library staff to link an order (in an unclosed basket, or a standing order) to an accepted suggestion. To test: 1) In the staff interface, go to Suggestions and create at least two suggestions. 2) Mark at least two suggestions as Accepted. 3) Go to Acquisitions, create a vendor if you don't have one already. 4) Have or create two baskets - one should be standing, and one not standing (normal). 5) In the normal basket (not standing), add an order from any source but NOT from a suggestion. 6) When you save the order, there should be a new link in the Modify column of the Orders table - "Search for suggestion to link". Click this. 7) Choose one of your suggestions to link to the order. 8) You should be redirected back to the basket. Confirm your order has been correctly linked to the suggestion. Confirm there is no link to "Search for suggestion to link" for this order now that a suggestion has already been linked. 9) Add another order to this basket from any source but NOT from a suggestion. 10) Close the basket. Confirm there is no link to "Search for suggestion to link" because the basket is closed, but you could reopen the basket to link the order if you wanted to. 11) Go to Baskets in the left navigation so you can find your standing basket. 12) Add an order to your standing basket from any source but NOT from a suggestion. 13) Go to the vendor and Receive shipments. Receive your standing order and finish receiving. 14) Go to the standing basket. There should be a new unreceived standing order for the record you just received, with a link to "Search for suggestion to link". Click this. 15) Choose a suggestion to link to the order. 16) You should be redirected back to the basket. Confirm your orders for this record have been correctly linked to the suggestion. Sponsored-by: Pymble Ladies' College Signed-off-by: Tomas Cohen Arazi Signed-off-by: Andrew Fuerste Henry Signed-off-by: Emily Lamancusa --- acqui/newordersuggestion.pl | 9 + .../prog/en/modules/acqui/basket.tt | 1882 ++++++++--------- .../en/modules/acqui/newordersuggestion.tt | 212 +- 3 files changed, 1032 insertions(+), 1071 deletions(-) diff --git a/acqui/newordersuggestion.pl b/acqui/newordersuggestion.pl index e41381f4f40..33fb3fc8d96 100755 --- a/acqui/newordersuggestion.pl +++ b/acqui/newordersuggestion.pl @@ -111,6 +111,7 @@ my $op = $input->param('op'); my $suggestionid = $input->param('suggestionid'); my $duplicateNumber = $input->param('duplicateNumber'); my $uncertainprice = $input->param('uncertainprice'); +my $link_order = $input->param('link_order'); $op = 'else' unless $op; @@ -128,6 +129,13 @@ if ( $op eq 'connectDuplicate' ) { ConnectSuggestionAndBiblio( $suggestionid, $duplicateNumber ); } +if ( $op eq 'link_order' and $link_order ) { + my $order = Koha::Acquisition::Orders->find($link_order); + my $suggestion = Koha::Suggestions->find($suggestionid); + $suggestion->update( { biblionumber => $order->biblionumber } ) if $order->biblionumber; + print $input->redirect( "/cgi-bin/koha/acqui/basket.pl?basketno=" . $basketno ); +} + my $suggestions = [ Koha::Suggestions->search_limited( { @@ -147,6 +155,7 @@ $template->param( booksellerid => $booksellerid, name => $vendor->name, "op_$op" => 1, + link_order => $link_order, ); output_html_with_http_headers $input, $cookie, $template->output; diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt index 454af49caf7..92bfc1e15b0 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt @@ -5,7 +5,7 @@ [% PROCESS 'patron-search.inc' %] [% BLOCK csv_export %]
- Export as CSV + Export as CSV @@ -26,17 +26,14 @@ [% USE TablesSettings %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] -[% FILTER collapse %] - [% tx("Basket {basketname} ({basketnumber}) for {vendor}", { basketname = basketname, basketnumber = basketno, vendor = booksellername }) | html %] - › [% t("Acquisitions") | html %] › [% t("Koha") | html %] - [% END %] +[% FILTER collapse %] + [% tx("Basket {basketname} ({basketnumber}) for {vendor}", { basketname = basketname, basketnumber = basketno, vendor = booksellername }) | html %] › + [% t("Acquisitions") | html %] › + [% t("Koha") | html %] +[% END %] [% INCLUDE 'doc-head-close.inc' %] @@ -70,1026 +67,959 @@ [% END #/ WRAPPER breadcrumbs %] [% END #/ WRAPPER sub-header.inc %] -[% SET asides = ['acquisitions-menu'] %] -[% IF booksellerid %][% asides.unshift('vendor-menu') %][% END %] -[% WRAPPER 'main-container.inc' asides=asides %] +
+
+
+
+ [% INCLUDE 'messages.inc' %] - [% IF (cannot_manage_basket) %] -
You are not authorised to manage this basket.
- [% ELSE %] - - [% IF !confirm_close && !edi_confirm %] - [% UNLESS ( selectbasketg ) %] - [% UNLESS ( closedate ) %] - [% UNLESS ( delete_confirmed ) %] -
- [% IF active %] - - [% END %] - - [% IF CAN_user_acquisition_delete_baskets %] - - [% END %] - [% IF ( unclosable ) %] + [% IF (cannot_manage_basket) %] +
You are not authorised to manage this basket.
+ [% ELSE %] - [% ELSIF ( uncertainprices ) %] - - - [% ELSE %] -
-
- [% INCLUDE 'csrf-token.inc' %] - - - - -
-
- [% END %] + [% IF !confirm_close && !edi_confirm %] + [% UNLESS ( selectbasketg ) %] + [% UNLESS ( closedate ) %] + [% UNLESS ( delete_confirmed ) %] +
+ [% IF active %] + + [% END %] + + [% IF CAN_user_acquisition_delete_baskets %] + + [% END %] + [% IF ( unclosable ) %] + [% ELSIF ( uncertainprices ) %] + + + [% ELSE %] +
+
+ [% INCLUDE 'csrf-token.inc' %] + + + + +
+
+ [% END %] - [% PROCESS csv_export %] + [% PROCESS csv_export %] - [% IF Koha.Preference('EDIFACT') && ediaccount %] - [% UNLESS eans.size %] -
- -
- [% ELSE %] -
- [% IF eans.size == 1 %] - Create EDIFACT order - [% ELSE %] - - +
+ [% END %] [% END %] -
- [% END %] - [% END %] - [% IF ( active && books_loop ) %] -
-
- [% INCLUDE 'csrf-token.inc' %] - - - -
+ [% IF ( active && books_loop ) %] +
+
+ [% INCLUDE 'csrf-token.inc' %] + + + +
+
+ [% END %] +
+ [% END # / UNLESS ( delete_confirmed ) %] + + + + + [% ELSE # UNLESS ( closedate ) %] +
+ [% IF grouped %] + + [% ELSE %] +
+
+ [% INCLUDE 'csrf-token.inc' %] + + + +
+
+ + [% PROCESS csv_export %] + [% END %]
- [% END %] -
- - [% END # / UNLESS ( delete_confirmed ) %] + [% END # /UNLESS ( closedate ) %] + [% END # /UNLESS ( selectbasketg ) %] - - + [% END # /IF ( basketno ) %] - [% IF ( duplinbatch ) %] -
-

Duplicate warning

-

Some records have not been automatically added because they match an existing record in your catalog: Display them

-
- [% END %] + [% IF ( duplinbatch ) %] +
+

Duplicate warning

+

Some records have not been automatically added because they match an existing record in your catalog: Display them

+
+ [% END %] - [% IF ( books_loop ) %] -
-

Orders

- - - - - - - - - - - - - - - - - - - - - - - [% IF Koha.Preference('EDIFACT') && ediaccount %] - - [% END %] - - [% IF ( active && !closedate ) %] - - [% END %] - [% IF !closedate || Koha.Preference('CancelOrdersInClosedBaskets') %] - - [% END %] - - - - [% FOREACH foot_loo IN book_foot_loop %] - - - - - - - - - - - - - - - - - - - - - [% IF Koha.Preference('EDIFACT') && ediaccount %] - - [% END %] - - [% IF ( active && !closedate ) %] - - [% END %] - [% IF !closedate || Koha.Preference('CancelOrdersInClosedBaskets') %] - - [% END %] - - [% END %] - - - - - - - - - - - - - - - - - - - - - [% IF Koha.Preference('EDIFACT') && ediaccount %] - - [% END %] - - [% IF ( active && !closedate ) %] - - [% END %] - [% IF !closedate || Koha.Preference('CancelOrdersInClosedBaskets') %] - - [% END %] - - - + [% IF ( books_loop ) %] +
+

Orders

+
No.[% tp('noun', 'Order') | html %]RRP tax exc.Actual cost tax exc.Budgeted cost tax exc.RRP tax inc.Actual cost tax inc.Budgeted cost tax inc.Replacement priceQty.Total tax exc. ([% currency | html %])Total tax inc. ([% currency | html %])GST %GSTFundEstimated delivery dateStatistic 1Statistic 2InvoiceSupplier reportPlace holdModifyCancel order
Total (GST [% foot_loo.tax_rate * 100 | html %])       [% foot_loo.quantity | html %][% foot_loo.total_tax_excluded | $Price %][% foot_loo.total_tax_included | $Price %] [% foot_loo.tax_value | $Price %]         
Total ([% currency | html %])       [% total_quantity | html %][% total_tax_excluded | $Price %][% total_tax_included | $Price %] [% total_tax_value | $Price %]         
+ + + + + + + + + + + + + + + + + + + + + + [% IF Koha.Preference('EDIFACT') && ediaccount %] + + [% END %] + + [% IF ( active && !closedate ) %] + + [% END %] + [% IF !closedate || Koha.Preference('CancelOrdersInClosedBaskets') %] + + [% END %] + + + + [% FOREACH foot_loo IN book_foot_loop %] + + + + + + + + + + + + + + + + + + + + + [% IF Koha.Preference('EDIFACT') && ediaccount %] + + [% END %] + + [% IF ( active && !closedate ) %] + + [% END %] + [% IF !closedate || Koha.Preference('CancelOrdersInClosedBaskets') %] + + [% END %] + + [% END %] + + + + + + + + + + + + + + + + + + + + + [% IF Koha.Preference('EDIFACT') && ediaccount %] + + [% END %] + + [% IF ( active && !closedate ) %] + + [% END %] + [% IF !closedate || Koha.Preference('CancelOrdersInClosedBaskets') %] + + [% END %] + + + [% FOREACH books_loo IN books_loop %] [% IF ( books_loo.order_received ) %] [% SET tr_class = "disabled" %] [% END %] - - - [% SET zero_regex = "^0{1,}\.?0{1,}[^1-9]" %] [%# 0 or 0.0 or 0.00 or 00 or 00.0 or 00.00 or 0.000 ... %] - [%# FIXME: use of a regexp is not ideal; bugs 9410 and 10929 suggest better way of handling this %] - - - - - - - - - - - - - - - - - + + + [% SET zero_regex = "^0{1,}\.?0{1,}[^1-9]" %] [%# 0 or 0.0 or 0.00 or 00 or 00.0 or 00.00 or 0.000 ... %] + [%# FIXME: use of a regexp is not ideal; bugs 9410 and 10929 suggest better way of handling this %] + + + + + + + + + + + + + + + + + - [% IF Koha.Preference('EDIFACT') && ediaccount %] - - [% END %] - - [% IF ( active && !closedate ) %] - - [% END %] - [% IF ( !closedate || Koha.Preference('CancelOrdersInClosedBaskets') ) %] - [% END %] - [% IF ( books_loo.left_item ) %] - [% books_loo.items | html %] item(s) left
- [% END %] - [% IF ( books_loo.left_biblio ) %] - [% books_loo.biblios | html %] order(s) left
- [% END %] - [% IF ( books_loo.left_subscription ) %] - [% books_loo.subscriptions | html %] subscription(s) left
+ + [% IF ( active && !closedate ) %] + [% END %] - [% IF ( books_loo.left_holds ) %] - [% books_loo.holds | html %] hold(s) left + [% IF ( !closedate || Koha.Preference('CancelOrdersInClosedBaskets') ) %] + [% END %] - [% END %] - - [% END %] - - [% END %] - -
No.[% tp('noun', 'Order') | html %]RRP tax exc.Actual cost tax exc.Budgeted cost tax exc.RRP tax inc.Actual cost tax inc.Budgeted cost tax inc.Replacement priceQty.Total tax exc. ([% currency | html %])Total tax inc. ([% currency | html %])GST %GSTFundEstimated delivery dateStatistic 1Statistic 2InvoiceSupplier reportPlace holdModifyCancel order
Total (GST [% foot_loo.tax_rate * 100 | html %])       [% foot_loo.quantity | html %][% foot_loo.total_tax_excluded | $Price %][% foot_loo.total_tax_included | $Price %] [% foot_loo.tax_value | $Price %]         
Total ([% currency | html %])       [% total_quantity | html %][% total_tax_excluded | $Price %][% total_tax_included | $Price %] [% total_tax_value | $Price %]         
[% books_loo.ordernumber | html %] -

- [% IF ( books_loo.order_received ) %](received)[% END %] - [% IF books_loo.title %] - [% INCLUDE 'biblio-title.inc' biblio=books_loo link = 1 %] - [% IF books_loo.author %]by [% books_loo.author | html %][% END %] - [% ELSIF books_loo.deleted_biblio %] - [% INCLUDE 'biblio-title.inc' biblio=books_loo.deleted_biblio %] -
(Deleted bibliographic record) - [% ELSE %] - Deleted bibliographic record, can't find title
- [%- END %] -
- [%- IF ( books_loo.isbn ) %]- [% books_loo.isbn | html %][% END -%] - [%- IF ( books_loo.issn ) %]- [% books_loo.issn | html %][% END -%] - [%- IF ( books_loo.publishercode ) %], [% books_loo.publishercode | html %][% END -%] - [%- IF ( books_loo.publicationyear ) %] - , [% books_loo.publicationyear | html -%] - [%- ELSIF ( books_loo.copyrightdate ) %] - [% books_loo.copyrightdate | html %] - [% END -%] - [%- IF ( books_loo.editionstatement ) %], [% books_loo.editionstatement | html %][% END -%] - [%- IF ( books_loo.suggestionid ) %] -
- Suggested by: [% books_loo.surnamesuggestedby | html %][% IF ( books_loo.firstnamesuggestedby ) %], [% books_loo.firstnamesuggestedby | html %][% END %] (suggestion #[% books_loo.suggestionid | html %]) - [% END %] -

- [% IF ( books_loo.order_internalnote ) %] -

Internal note: [% books_loo.order_internalnote | html %] - Edit internal note

- [% ELSE %] - Add internal note - [% END %] - [% IF ( books_loo.order_vendornote ) %] -

Vendor note: [% books_loo.order_vendornote | html %] - Edit vendor note

- [% ELSE %] - Add vendor note - [% END %] - [% IF (books_loo.transferred_from) %] - [% basket = books_loo.transferred_from.basket %] - [% bookseller = books_loo.transferred_from.bookseller %] - [% timestamp = books_loo.transferred_from.timestamp %] -

- Transferred from basket: - [% basket.basketname | html %] - ([% bookseller.name | html %]) on - [% timestamp | $KohaDates %] -

- [% END %] - [% SET claims = books_loo.order_object.claims %] - [% IF claims.count %] -

This order has been claimed [% claims.count | html %] times. On [% FOR c IN claims %][% c.claimed_on | $KohaDates %][% UNLESS loop.last %],[% END %][% END %]

- [% END %] -
- [% books_loo.rrp_tax_excluded | $Price %] [% IF ( books_loo.uncertainprice ) %](Uncertain)[% END %] - [% books_loo.unitprice_tax_excluded | $Price %] [% books_loo.ecost_tax_excluded | $Price %] [% books_loo.rrp_tax_included | $Price %] [% books_loo.unitprice_tax_included | $Price %] [% books_loo.ecost_tax_included | $Price %] [% books_loo.replacementprice | $Price %] [% books_loo.quantity | html %] [% books_loo.total_tax_excluded | $Price %] [% books_loo.total_tax_included | $Price %] [% books_loo.tax_rate * 100 | html %] [% books_loo.tax_value | $Price %] [% books_loo.budget_name | html %] - [% books_loo.estimated_delivery_date | $KohaDates %] - [% IF CAN_user_acquisition_order_manage %] - - Edit - [% END %] - [% AuthorisedValues.GetByCode( books_loo.sort1_authcat, books_loo.sort1 ) | html %][% AuthorisedValues.GetByCode( books_loo.sort2_authcat, books_loo.sort2 ) | html %] - [% IF CAN_user_acquisition_edit_invoices %] - [% books_loo.invoice_object.invoicenumber | html %] - [% ELSE %] - [% books_loo.invoice_object.invoicenumber | html %] - [% END %] - + [% books_loo.ordernumber | html %] + +

+ [% IF ( books_loo.order_received ) %] (received)[% END %] + [% IF books_loo.title %] + [% INCLUDE 'biblio-title.inc' biblio=books_loo link = 1 %] [% IF books_loo.author %] by [% books_loo.author | html %][% END %] + [% ELSIF books_loo.deleted_biblio %] + [% INCLUDE 'biblio-title.inc' biblio=books_loo.deleted_biblio %] +
(Deleted bibliographic record) + [% ELSE %] + Deleted bibliographic record, can't find title
+ [%- END %] +
+ [%- IF ( books_loo.isbn ) %] - [% books_loo.isbn | html %][% END -%] + [%- IF ( books_loo.issn ) %] - [% books_loo.issn | html %][% END -%] + [%- IF ( books_loo.publishercode ) %], [% books_loo.publishercode | html %][% END -%] + [%- IF ( books_loo.publicationyear ) %], [% books_loo.publicationyear | html -%] + [%- ELSIF ( books_loo.copyrightdate ) %] [% books_loo.copyrightdate | html %][% END -%] + [%- IF ( books_loo.editionstatement ) %], [% books_loo.editionstatement | html %][% END -%] + [%- IF ( books_loo.suggestionid ) %] +
+ Suggested by: [% books_loo.surnamesuggestedby | html %][% IF ( books_loo.firstnamesuggestedby ) %], [% books_loo.firstnamesuggestedby | html %] [% END %] + (suggestion #[% books_loo.suggestionid | html %]) + [% END %] +

+ [% IF ( books_loo.order_internalnote ) %] +

Internal note: [% books_loo.order_internalnote | html %] Edit internal note

+ [% ELSE %] + Add internal note + [% END %] + [% IF ( books_loo.order_vendornote ) %] +

Vendor note: [% books_loo.order_vendornote | html %] Edit vendor note

+ [% ELSE %] + Add vendor note + [% END %] + [% IF (books_loo.transferred_from) %] + [% basket = books_loo.transferred_from.basket %] + [% bookseller = books_loo.transferred_from.bookseller %] + [% timestamp = books_loo.transferred_from.timestamp %] +

+ Transferred from basket: + [% basket.basketname | html %] + ([% bookseller.name | html %]) + on + [% timestamp | $KohaDates %] + +

+ [% END %] + [% SET claims = books_loo.order_object.claims %] + [% IF claims.count %] +

+ This order has been claimed [% claims.count | html %] times. On [% FOR c IN claims %][% c.claimed_on | $KohaDates %][% UNLESS loop.last %], [% END %][% END %] +

+ [% END %] +
+ [% books_loo.rrp_tax_excluded | $Price %] [% IF ( books_loo.uncertainprice ) %] (Uncertain) [% END %] + + [% books_loo.unitprice_tax_excluded | $Price %] + + [% books_loo.ecost_tax_excluded | $Price %] + + [% books_loo.rrp_tax_included | $Price %] + + [% books_loo.unitprice_tax_included | $Price %] + + [% books_loo.ecost_tax_included | $Price %] + + [% books_loo.replacementprice | $Price %] + + [% books_loo.quantity | html %] + + [% books_loo.total_tax_excluded | $Price %] + + [% books_loo.total_tax_included | $Price %] + + [% books_loo.tax_rate * 100 | html %] + + [% books_loo.tax_value | $Price %] + + [% books_loo.budget_name | html %] + + [% books_loo.estimated_delivery_date | $KohaDates %] + [% IF CAN_user_acquisition_order_manage %] + + Edit + [% END %] + [% AuthorisedValues.GetByCode( books_loo.sort1_authcat, books_loo.sort1 ) | html %][% AuthorisedValues.GetByCode( books_loo.sort2_authcat, books_loo.sort2 ) | html %] + [% IF CAN_user_acquisition_edit_invoices %] + [% books_loo.invoice_object.invoicenumber | html %] + [% ELSE %] + [% books_loo.invoice_object.invoicenumber | html %] + [% END %] + [% books_loo.suppliers_report | html %] - [% IF ( books_loo.biblionumber && CAN_user_reserveforothers_place_holds ) %] - Place hold - [% END %] - - [% UNLESS (books_loo.order_received) %] - Modify -
- Transfer - [% END %] -
- [% IF ( books_loo.orderstatus != "complete") %] - [% IF ( books_loo.left_holds_on_order ) %] - Can't cancel order
- [% ELSE %] - Cancel order
- [% END %] - [% IF ( books_loo.can_del_bib ) %] - Cancel order and delete catalog record
- [% ELSE %] - Can't cancel order and delete catalog record
+ [% IF Koha.Preference('EDIFACT') && ediaccount %] +
[% books_loo.suppliers_report | html %] + [% IF ( books_loo.biblionumber && CAN_user_reserveforothers_place_holds ) %] + + Place hold + + [% END %] + + [% UNLESS (books_loo.order_received) %] + Modify +
+ Transfer +
+ [% END %] + [% UNLESS ( books_loo.suggestionid ) %] + Search for suggestion to link + [% END %] +
+ [% IF ( books_loo.orderstatus != "complete") %] + [% IF ( books_loo.left_holds_on_order ) %] + Can't cancel order
+ [% ELSE %] + Cancel order
+ [% END %] + [% IF ( books_loo.can_del_bib ) %] + Cancel order and delete catalog record
+ [% ELSE %] + Can't cancel order and delete catalog record
+ [% END %] + [% IF ( books_loo.left_item ) %] + [% books_loo.items | html %] item(s) left
+ [% END %] + [% IF ( books_loo.left_biblio ) %] + [% books_loo.biblios | html %] order(s) left
+ [% END %] + [% IF ( books_loo.left_subscription ) %] + [% books_loo.subscriptions | html %] subscription(s) left
+ [% END %] + [% IF ( books_loo.left_holds ) %] + [% books_loo.holds | html %] hold(s) left + [% END %] + [% END %] +
- - [% IF ( listincgst ) %]** Vendor's listings already include tax.[% END %] -
- - [% END # / IF ( books_loop ) %] + + [% END %] + + + [% IF ( listincgst ) %]** Vendor's listings already include tax.[% END %] +
+ [% END # / IF ( books_loop ) %] - [% IF (cancelledorders_loop) %] -
-

Cancelled orders

- - - - - - - - - - - - - - - - - - - - - [% FOREACH order IN cancelledorders_loop %] - - - - - - - - - - - - - - - - - [% END # /FOREACH order %] - -
No.[% tp('noun', 'Order') | html %]RRP tax exc.ecost tax exc.RRP tax inc.ecost tax inc.Replacement priceQty.Total tax exc. ([% currency | html %])Total tax inc. ([% currency | html %])GST %GSTFundDelete order
[% order.ordernumber | html %] -

- [% IF ( order.order_received ) %](received)[% END %] - [% IF (order.title) %] - [% order.title | html %][% IF order.author %]by [% order.author | html %][% END %] - [% ELSIF order.deleted_biblio %] - [% INCLUDE 'biblio-title.inc' biblio=order.deleted_biblio %] -
(Deleted bibliographic record) - [% ELSE %] - Deleted bibliographic record, can't find title - [% END %] -
- [% IF ( order.order_internalnote ) %][% order.order_internalnote | html %][% END %] - [% IF ( order.isbn ) %]- [% order.isbn | html %][% END %] - [% IF ( order.issn ) %]- [% order.issn | html %][% END %] - [% IF ( order.publishercode ) %], [% order.publishercode | html %][% END %] - [% IF ( order.publicationyear ) %] - , [% order.publicationyear | html %] - [% ELSIF ( order.copyrightdate ) %] - [% order.copyrightdate | html %] - [% END %] - [% IF ( books_loo.editionstatement ) %], [% books_loo.editionstatement | html %][% END %] - [% IF ( order.cancellationreason ) %] -
- Cancellation reason: [% AuthorisedValues.GetByCode( 'ORDER_CANCELLATION_REASON', order.cancellationreason ) | html %] + [% IF (cancelledorders_loop) %] +

+

Cancelled orders

+ + + + + + + + + + + + + + + + + + + + + [% FOREACH order IN cancelledorders_loop %] + + + + + + + + + + + + + + + + + [% END # /FOREACH order %] + +
No.[% tp('noun', 'Order') | html %]RRP tax exc.ecost tax exc.RRP tax inc.ecost tax inc.Replacement priceQty.Total tax exc. ([% currency | html %])Total tax inc. ([% currency | html %])GST %GSTFundDelete order
+ [% order.ordernumber | html %] + +

+ [% IF ( order.order_received ) %] (received)[% END %] + [% IF (order.title) %] + [% order.title | html %][% IF order.author %] by [% order.author | html %][% END %] + [% ELSIF order.deleted_biblio %] + [% INCLUDE 'biblio-title.inc' biblio=order.deleted_biblio %] +
(Deleted bibliographic record) + [% ELSE %] + Deleted bibliographic record, can't find title + [% END %] +
+ [% IF ( order.order_internalnote ) %] [% order.order_internalnote | html %][% END %] + [% IF ( order.isbn ) %] - [% order.isbn | html %][% END %] + [% IF ( order.issn ) %] - [% order.issn | html %][% END %] + [% IF ( order.publishercode ) %], [% order.publishercode | html %][% END %] + [% IF ( order.publicationyear ) %] + , [% order.publicationyear | html %] + [% ELSIF ( order.copyrightdate ) %] + [% order.copyrightdate | html %] + [% END %] + [% IF ( books_loo.editionstatement ) %], [% books_loo.editionstatement | html %][% END %] + [% IF ( order.cancellationreason ) %] +
+ Cancellation reason: [% AuthorisedValues.GetByCode( 'ORDER_CANCELLATION_REASON', order.cancellationreason ) | html %] + [% END %] +

+ [% IF order.transferred_to %] + [% basket = order.transferred_to.basket %] + [% bookseller = order.transferred_to.bookseller %] + [% timestamp = order.transferred_to.timestamp %] +

Transferred to basket: + [% basket.basketname | html %] + ([% bookseller.name | html %]) + on + [% timestamp | $KohaDates %] + +

+ [% END %] +
+ [% order.rrp_tax_excluded | $Price %] + [% IF ( order.uncertain ) %] + (Uncertain) + [% END %] + [% order.ecost_tax_excluded | $Price %][% order.rrp_tax_included | $Price %][% order.ecost_tax_included | $Price %][% order.replacementprice | $Price %][% order.quantity | html %][% order.total_tax_excluded | $Price %][% order.total_tax_included | $Price %][% order.tax_rate * 100 | html %][% order.tax_value | $Price %][% order.budget_name | html %] + [% UNLESS closedate %]Delete[% END %] +
+
+ [% INCLUDE 'csrf-token.inc' %] + + + +
+
+ [% END # /IF (cancelledorders_loop) %] +
+ + [% UNLESS ( closedate ) %] + +
- [% order.rrp_tax_excluded | $Price %] - [% IF ( order.uncertain ) %] - (Uncertain) - [% END %] - [% order.ecost_tax_excluded | $Price %][% order.rrp_tax_included | $Price %][% order.ecost_tax_included | $Price %][% order.replacementprice | $Price %][% order.quantity | html %][% order.total_tax_excluded | $Price %][% order.total_tax_included | $Price %][% order.tax_rate * 100 | html %][% order.tax_value | $Price %][% order.budget_name | html %] [% UNLESS closedate %]Delete[% END %]
- -
+
+ +
+
+
+ [% END # /UNLESS ( closedate ) %] + + [% END # /IF ( delete_confirmed ) %] + [% END # /IF ( NO_BOOKSELLER ) %] + [% ELSE %] + + [% END #/IF !confirm_close && !edi_confirm %] + + [% IF ( confirm_close ) %] +
+ + [% INCLUDE 'csrf-token.inc' %] - - +

Are you sure you want to close basket [% basketname | html %]?

+ [% IF ( CAN_user_acquisition_group_manage ) %] +

+ + +

+ [% END %] + + + + + + + +
+
- - [% END # /IF (cancelledorders_loop) %] -
+ [% END # /IF ( confirm_close ) %] - [% UNLESS ( closedate ) %] - - - [% END # /UNLESS ( closedate ) %] - [% END # /IF ( delete_confirmed ) %] - [% END # /IF ( NO_BOOKSELLER ) %] - [% ELSE %] - - [% END #/IF !confirm_close && !edi_confirm %] + [% IF edi_confirm %] +
+
+ [% INCLUDE 'csrf-token.inc' %] +

Are you sure you want to generate an EDIFACT order and close basket [% basketname | html %]?

+ [% IF CAN_user_acquisition_group_manage %] +

+ + +

+ [% END %] + + + + + + + +
+
+ + +
+
+ [% END # /IF edi_confirm %] + [% END # /IF (cannot_manage_basket) %] + + - [% IF ( confirm_close ) %] -
-
- [% INCLUDE 'csrf-token.inc' %] -

Are you sure you want to close basket [% basketname | html %]?

- [% IF ( CAN_user_acquisition_group_manage ) %] -

- - -

- [% END %] - - - - - - -
-
- - -
-
- [% END # /IF ( confirm_close ) %] +
+ +
+ - [% IF edi_confirm %] -
-
- [% INCLUDE 'csrf-token.inc' %] -

Are you sure you want to generate an EDIFACT order and close basket [% basketname | html %]?

- [% IF CAN_user_acquisition_group_manage %] -

- - -

- [% END %] - - - - - - - -
-
- - -
-
- - [% END # /IF edi_confirm %] - [% END # /IF (cannot_manage_basket) %] -[% END %] - - - + + - - - + + [% MACRO jsinclude BLOCK %] [% Asset.js("js/acquisitions-menu.js") | $raw %] @@ -1184,6 +1114,7 @@ }); }); + [% UNLESS ( closedate ) %] + [% INCLUDE 'select2.inc' %] [% SET columns = ['cardnumber','name','category','branch','action'] %] [% SET filter = 'baskets_managers' %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/newordersuggestion.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/newordersuggestion.tt index e3e1c09e742..a1b375b5170 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/newordersuggestion.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/newordersuggestion.tt @@ -1,5 +1,4 @@ [% USE raw %] -[% USE Koha %] [% USE Branches %] [% USE Price %] [% USE Asset %] @@ -38,104 +37,125 @@ [% END #/ WRAPPER breadcrumbs %] [% END #/ WRAPPER sub-header.inc %] -[% WRAPPER 'main-container.inc' aside='acquisitions-menu' %] -

Suggestions

+
+
+
+
+ [% INCLUDE 'messages.inc' %] -
- [% IF suggestions.size %] - Show only mine | Show all suggestions - - - - - - - - - - - - - - - - - - [% FOREACH suggestion IN suggestions %] - - - - - - - - - - - - -
MineSuggestionDocument typeSuggested byAccepted byLibraryFundPriceQuantityTotal 
[% suggestion.managedby | html %] -

[% suggestion.title | html %] - [% suggestion.author | html %]

-

- [% IF ( suggestion.copyrightdate ) %]© [% suggestion.copyrightdate | html %][% END %] - [% IF ( suggestion.volumedesc ) %]volume: [% suggestion.volumedesc | html %][% END %] - [% IF ( suggestion.isbn ) %]ISBN: [% suggestion.isbn | html %][% END %] - [% IF ( suggestion.publishercode ) %]
published by: [% suggestion.publishercode | html %][% END %] - [% IF ( suggestion.publicationyear ) %]in [% suggestion.publicationyear | html %][% END %] - [% IF ( suggestion.place ) %]in [% suggestion.place | html %][% END %] - [% IF ( suggestion.note ) %]

([% suggestion.note | html %])

[% END %] -

-
[% AuthorisedValues.GetByCode( 'SUGGEST_FORMAT', suggestion.itemtype ) | html %][% INCLUDE 'patron-title.inc' patron => suggestion.suggester %][% INCLUDE 'patron-title.inc' patron => suggestion.manager %] [% Branches.GetName(suggestion.branchcode) | html %] [% suggestion.fund.budget_name | html %] [% suggestion.price | $Price %] - [% IF (suggestion.quantity > 0) %] - [% suggestion.quantity | html %] - [% END %] - [% suggestion.total | $Price %] - [% IF ( suggestion.biblionumber ) %] - [% tp('verb', 'Order') | html %] - [% ELSE %] - [% tp('verb', 'Order') | html %] +

Suggestions

+ +
+ [% IF suggestions.size %] + Show only mine | Show all suggestions + + + + + + + + + + + + + + + + + + [% FOREACH suggestion IN suggestions %] + + + + + + + + + + + + + [% END %] - - + +
MineSuggestionDocument typeSuggested byAccepted byLibraryFundPriceQuantityTotal 
[% suggestion.managedby | html %] +

[% suggestion.title | html %] - [% suggestion.author | html %]

+

+ [% IF ( suggestion.copyrightdate ) %]© [% suggestion.copyrightdate | html %][% END %] + [% IF ( suggestion.volumedesc ) %]volume: [% suggestion.volumedesc | html %][% END %] + [% IF ( suggestion.isbn ) %]ISBN: [% suggestion.isbn | html %][% END %] + [% IF ( suggestion.publishercode ) %]
published by: [% suggestion.publishercode | html %][% END %] + [% IF ( suggestion.publicationyear ) %]in [% suggestion.publicationyear | html %][% END %] + [% IF ( suggestion.place ) %]in [% suggestion.place | html %][% END %] + [% IF ( suggestion.note ) %]

([% suggestion.note | html %])

[% END %] +

+
[% AuthorisedValues.GetByCode( 'SUGGEST_FORMAT', suggestion.itemtype ) | html %][% INCLUDE 'patron-title.inc' patron => suggestion.suggester %][% INCLUDE 'patron-title.inc' patron => suggestion.manager %] [% Branches.GetName(suggestion.branchcode) | html %] [% suggestion.fund.budget_name | html %] [% suggestion.price | $Price %] + [% IF (suggestion.quantity > 0) %] + [% suggestion.quantity | html %] + [% END %] + [% suggestion.total | $Price %] + [% IF link_order %] + [% tp('verb', 'Link suggestion') | html %] + [% ELSIF ( suggestion.biblionumber ) %] + [% tp('verb', 'Order') | html %] + [% ELSE %] + [% tp('verb', 'Order') | html %] + [% END %] +
+ [% ELSE %] + There are no outstanding (accepted) suggestions. [% END %] -
- [% ELSE %] - There are no outstanding (accepted) suggestions. - [% END %] +
+ +
+
+ + +
+ +
+
- -[% END %] + -[% MACRO jsinclude BLOCK %] - [% Asset.js("js/acquisitions-menu.js") | $raw %] - [% INCLUDE 'datatables.inc' %] - [% INCLUDE 'calendar.inc' %] - -[% END %] + [% MACRO jsinclude BLOCK %] + [% Asset.js("js/acquisitions-menu.js") | $raw %] + [% INCLUDE 'datatables.inc' %] + [% INCLUDE 'calendar.inc' %] + + [% END %] -[% INCLUDE 'intranet-bottom.inc' %] + [% INCLUDE 'intranet-bottom.inc' %]
-- 2.39.5