Bugzilla – Attachment 151758 Details for
Bug 33783
Populate actual cost with estimated cost if actual cost not set when receiving (bug 8179 follow-up)
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 33783: (bug 8179 follow-up) Populate actual cost with ecost during receiving if not set
Bug-33783-bug-8179-follow-up-Populate-actual-cost-.patch (text/plain), 1.98 KB, created by
Nick Clemens (kidclamp)
on 2023-05-26 12:52:18 UTC
(
hide
)
Description:
Bug 33783: (bug 8179 follow-up) Populate actual cost with ecost during receiving if not set
Filename:
MIME Type:
Creator:
Nick Clemens (kidclamp)
Created:
2023-05-26 12:52:18 UTC
Size:
1.98 KB
patch
obsolete
>From d98aaa1c6272604b9117c84993a264a7985120a8 Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Fri, 26 May 2023 12:50:41 +0000 >Subject: [PATCH] Bug 33783: (bug 8179 follow-up) Populate actual cost with > ecost during receiving if not set > >This restores behavior prior to 8179 to use the estimated cost when receiving if the >actual cost is not set. > >We set the unitprice in the table row so that it will be used when editing and will be saved even if not adjusted > >To test: >1 - Add some orders to a basket, do not set actual cost field >2 - Close basket, receive orders >3 - Note actual cost field is blank >4 - Cancel receipt >5 - Apply patch >6 - Receive again >7 - Note actual cost is populated >8 - Complete receipt and confirm actual cost correctly saved >--- > koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt >index 829c031e3d..25534a1c57 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt >@@ -690,7 +690,7 @@ > var effective_create_items = row.basket.create_items || AcqCreateItem; > params['tax_rate'] = (effective_create_items == 'receiving')?row.tax_rate_on_receiving:row.tax_rate_on_ordering; > params['replacementprice'] = row.replacement_price; >- params['unitprice'] = invoiceincgst=="1"?row.unit_price_tax_included:row.unit_price_tax_excluded; >+ params['unitprice'] = ( invoiceincgst=="1" ) ? ( row.unit_price_tax_included || row.ecost_tax_included ) : ( row.unit_price_tax_excluded || row.ecost_tax_excluded ); > params['order_internalnote'] = row.internal_note; > if(effective_create_items == 'receiving') { > Object.keys(row.items).forEach(function(key) { >-- >2.30.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 33783
:
151469
|
151758
|
151761
|
151789
|
151794
|
151795
|
151817