Merge lp:~julie-w/unifield-server/US-4756 into lp:unifield-server

Proposed by jftempo
Status: Merged
Merged at revision: 4967
Proposed branch: lp:~julie-w/unifield-server/US-4756
Merge into: lp:unifield-server
Diff against target: 32 lines (+7/-7)
1 file modified
bin/addons/register_accounting/purchase.py (+7/-7)
To merge this branch: bzr merge lp:~julie-w/unifield-server/US-4756
Reviewer Review Type Date Requested Status
UniField Reviewer Team Pending
Review via email: mp+349122@code.launchpad.net
To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'bin/addons/register_accounting/purchase.py'
--- bin/addons/register_accounting/purchase.py 2017-11-27 15:38:38 +0000
+++ bin/addons/register_accounting/purchase.py 2018-07-09 08:35:51 +0000
@@ -52,13 +52,13 @@
5252
53 To be 100% invoiced, a PO should have some linked invoiced that are validated ('open' state or 'paid' state) and that sum of amount is greater or equal to PO total amount. So to find PO that are not 100% invoiced, you should find those from which all invoice are not created or which amount is inferior to PO total amount.53 To be 100% invoiced, a PO should have some linked invoiced that are validated ('open' state or 'paid' state) and that sum of amount is greater or equal to PO total amount. So to find PO that are not 100% invoiced, you should find those from which all invoice are not created or which amount is inferior to PO total amount.
5454
55 BKLG-51: new filters55 BKLG-51 / US-3782: new filters
56 1) On PO state: only allow "confirmed" or "confirmed (waiting)" POs to be selected in the wizard56 1) On PO LINE state: only allow PO having at least one line in Confirmed State, or Closed State if the related
57 (keeping 'done' for not completly invoiced)57 invoice is still in Draft state or Cancelled
58 2) On PO type: only allow regular, purchase list and direct purchase order PO types58 2) On PO type: only allow regular and "purchase list" purchase order types
59 3) Make sure that RFQs or tenders can not be linked to down payments59 3) Make sure that RFQs or tenders can not be linked to down payments
60 1) state 'confirm_waiting' + 'approved' + 'done' (done tolerated if partially invoiced)60 1) line state 'confirmed' + 'done' (done tolerated if invoice still in Draft state)
61 2) order_type 'regular', 'purchase_list', 'direct'61 2) order_type 'regular', 'purchase_list'
62 3) rfq_ok != True62 3) rfq_ok != True
6363
64 US-1064: new rule: as soon as all goods are received on a PO (state 'done') no new Down Payment is possible64 US-1064: new rule: as soon as all goods are received on a PO (state 'done') no new Down Payment is possible
@@ -81,7 +81,7 @@
81 where pir.invoice_id = inv.id AND inv.state not in ('draft', 'cancel') 81 where pir.invoice_id = inv.id AND inv.state not in ('draft', 'cancel')
82 group by pir.purchase_id) inv on inv.purchase_id = po.id 82 group by pir.purchase_id) inv on inv.purchase_id = po.id
83 LEFT JOIN product_pricelist as prod ON (po.pricelist_id = prod.id AND prod.currency_id = %s) 83 LEFT JOIN product_pricelist as prod ON (po.pricelist_id = prod.id AND prod.currency_id = %s)
84 LEFT JOIN (select pol1.order_id, sum(pol1.price_unit * pol1.product_qty) as total 84 INNER JOIN (select pol1.order_id, sum(pol1.price_unit * pol1.product_qty) as total
85 from purchase_order_line pol1 85 from purchase_order_line pol1
86 where pol1.state in ('confirmed', 'done') group by pol1.order_id) pol on pol.order_id=po.id 86 where pol1.state in ('confirmed', 'done') group by pol1.order_id) pol on pol.order_id=po.id
87 WHERE po.pricelist_id = prod.id 87 WHERE po.pricelist_id = prod.id

Subscribers

People subscribed via source and target branches