Commit Graph
1666 Commits
Author SHA1 Message Date
Arnold Moyaux a2a6b099a4 [REF] stock, stock_*: procurement batch by rules's actions
Improve the procurement requests performance. Instead of processing
procurement request one by one, search rules that apply for each of
them and group them by rule's actions.

The main technical change is the record creation order.
E.g. 2 SO lines with pick ship delivery.
-Before this commit:
line1 -> LAUNCH_RULE -> PICK MOVE1 -> MOVE1 CONFIRM -> OUT MOVE1
line2 -> LAUNCH RULE -> PICK MOVE2 -> MOVE2 CONFIRM -> OUT MOVE2
-After this commit:
line1/2 -> LAUNCH RULE -> PICK MOVE1/2 -> MOVE1/2 CONFIRM -> OUT MOVE1/2

Also there is one batch creation by company_id. It implies that values
are group by company_id. Since company_id are passed by previous
procurement or by the rule, it become a required value and it's added to
the procurement arguments (it was already always passed in the values,
no functional modification).

_run_buy is reworked. It receives a bathc of procurements, those
procurements could be merged in the same PO or the same PO lines.
However the PO/PO lines are created (if procurement couldn't be
merged in an existing one) at the end of the method. It implies
that 2 procurements creating a PO and merged inside, would now create
2 distinct PO (same for po lines). _run_buy in order to fix this issue:
- group procurements by PO search domain. If the PO doesn't exist,
create only one.
- Inside the same PO: merge quantities, move_dest_ids for procurements
with the same product and UoM.

Other _run_ methods are just adjusted in order to process batch.

For a pick pack ship scenario, without procurment_jit confirm a SO
containing 500 lines will take 40s instead of 15 minutes.
2019-02-14 10:19:21 +00:00
Prakash Prajapati 30128860da [IMP] sale,purchase,...: Improve description of demo data product
Purpose of the task is some demo data values are not matching with the products
mentioned so update the demo data values with matching product.

Task: 1892754

closes odoo/odoo#28573
2019-02-13 09:20:25 +00:00
Pratima Gupta de97a490f1 [IMP] various: improve applications and categories name
Purpose is to ease understanding of applications / categories and their
links with the access rights labelling.

This commit is related to task 1884968 and PR #29176.
2019-01-30 14:03:33 +00:00
Haresh Shyara 0e6d9863ec [IMP] purchase_requisition: improve test
Create data for all tests in order to speed data test creation. We don't want the test to be demo data dependent
What we are testing in this test case.

-> Check that procurement is creating requisition with correct details or not.
-> Check that purchase order created is consistent when we create it with supplier info.
-> Two blanket orders on different 'make to order' products must generate two different purchase orders.

Task ID : 1851286

closes odoo/odoo#30187
2019-01-17 13:00:59 +00:00
Haresh Shyara 826f927a1e [MOV] purchase_requisition: make requisition services friendly
The purpose of this commit is to make requisition usable with only services. Stock part is extracted in a new module `purchase_requisition_stock` which allows to create requisition based on product availbility or demand, also
we have moved all security access related stock in this bridge module.

Task ID : 1851286
2019-01-17 13:00:21 +00:00
Christophe Simonis d7c5bc02cc [MERGE] forward port branch saas-12.1 up to 8aa8548d8a 2019-01-09 19:59:27 +01:00
Christophe Simonis 8aa8548d8a [MERGE] forward port branch 12.0 up to 3e4138deaa
closes odoo/odoo#30045
2019-01-09 15:56:53 +00:00
Odoo Translation Bot 652cecffde [I18N] Update translation terms from Transifex 2019-01-06 01:32:05 +01:00
Thibault Delavallée b8197ff178 [REF] various: update tracking parameters
Purpose is to clean the use of tracking parameters on fields. Parameters are
merged and is now tracking=<int> or tracking=True.

This commit is linked to task ID 1903814 and PR #28430.
2019-01-04 11:46:14 +00:00
Martin Trigaux af69902ecc [I18N] export saas-12.1 source terms
closes odoo/odoo#29730
2018-12-24 11:07:31 +00:00
Odoo Translation Bot 91382f691d [I18N] Update translation terms from Transifex 2018-12-30 01:30:16 +01:00
Swapnesh Shah 595209a3e8 [FIX] purchase_requisition: Use correct field to access state
closes odoo/odoo#29715
2018-12-21 19:31:30 +00:00
Christophe Simonis f351dd8cab [MERGE] forward port branch 12.0 up to 047e2b28de 2018-12-12 11:38:25 +01:00
Odoo Translation Bot 47aae6faba [I18N] Update translation terms from Transifex 2018-12-23 01:29:13 +01:00
Odoo Translation Bot ec4ee14c89 [I18N] Update translation terms from Transifex 2018-12-09 01:16:26 +01:00
William Henrotin 33a6649aa4 [FIX] purchase_requisition: incorrect field
Before the fix we were requiring for product.supplierinfo.requisition_id
which is a non existing field of the model 'product.supplierinfo'. I
just change it then to purchase_requisition_id which is the required
field.

This triggered an error when you add a product selled by the defined
vendor for an aggreement type defined as 'Blanket order'.

opw-1914712

closes odoo/odoo#29342
2018-12-07 16:38:28 +00:00
Martin Trigaux fa98749154 [I18N] export 12.0 source terms
Update to reflect the recent code changes

closes odoo/odoo#29636
2018-12-19 08:50:10 +00:00
Odoo Translation Bot 1208ac6ce3 [I18N] Update translation terms from Transifex 2018-12-02 01:25:05 +01:00
Christophe Simonis f5c3dafb04 [MERGE] forward port branch saas-11.3 up to c0eef42711 2018-11-29 18:38:55 +01:00
Christophe Simonis efe7ca16b7 [MERGE] forward port branch 11.0 up to bb6f6c57f9 2018-11-28 17:44:46 +01:00
Christophe Simonis e1f9499d26 [MERGE] forward port branch 12.0 up to 053bb45706 2018-12-05 18:46:15 +01:00
Prakash Prajapati 679cf0d83f [FIX] purchase_requisition: Request Approval on exclusive requisition
Usecase to reproduce:
- Enable 'Managers must approve orders'
- Set agreement type as 'exclusive'
- Connect as purchase user
- Create a requisition and an RFQ linked to it
- Confirm the RFQ

It raises a usererror that ask to close other PO linked
to requisition.

It happens because the purchase requisition code do not take
care of double validation on PO. It will try to close the requisition
once button_confirm is called. However it will only write 'to approve'
on PO state and thus trigger the requistion error will be raise since
all linked PO are not 'done' or 'cancel'.

In order to fix it, the action_done on requisition should be call
on button_approve instead of button_confirm. (button_approve is
automatically called when double validation is not enable).

Task: #1884410
Closes #28068

closes odoo/odoo#29049
2018-11-28 04:51:02 +00:00
Christophe Simonis ce4cc24621 [MERGE] forward port branch 12.0 up to 82a1e1dcc3 2018-11-29 20:06:16 +01:00
Nimesh Jethva b0a6f3398d [IMP] *: add next activities on all modules
*: account, event, mrp, purchase_requisition, stock_landed_cost, stock_picking_batch

Add activity on below models:
account.payment
event.event
event.registration
mrp.workorder
purchase.requisition
stock.landed.cost
stock.picking.batch

Related Task ID : 1867620

closes odoo/odoo#26092
2018-11-26 12:28:19 +00:00
Christophe Simonis 7a0243ec15 [MERGE] forward port branch 12.0 up to b3052b690f 2018-11-23 12:11:32 +01:00
Odoo Translation Bot c487d2c26c [I18N] Update translation terms from Transifex 2018-11-21 09:40:22 +01:00
Odoo Translation Bot b60f9bb739 [I18N] Update translation terms from Transifex 2018-11-18 01:28:38 +01:00
Christophe Simonis 4b8bd36219 [MERGE] forward port branch saas-11.3 up to bab2a191d2 2018-11-16 15:39:02 +01:00
Christophe Simonis 15f686eef6 [MERGE] forward port branch 11.0 up to 468dab6748 2018-11-15 20:39:10 +01:00
jem-odoo 8fc246da31 [MOV] purchase_requisition: split models and views files
This commit simply move code into the right file.
The goal is here to fit the guidelines and prepare
the module for some changes. This will ease the
reading of module code.

Task-1851286

closes odoo/odoo#28795
2018-11-19 12:52:07 +00:00
Christophe Simonis 6faad524cf [MERGE] forward port branch 12.0 up to bc744a1da4 2018-11-16 19:30:20 +01:00
Goffin Simon 6123cc912c [FIX]purchase_requisition: Creating requistions from OP
Steps to reproduce the bug:

- Create a product : stockable + purchase : propose a call for tenders + reordering rule (qty min 0, max 0, multiple 1)
- Create a SO for that product.
- Run the scheduler once : a requistion is generated (Purchases > Purchase > Purchase Agreements), which is normal behavior
- Run the scheduler a second time

Bug:

A new requistion was generated for the same product, by the same reordering rule

opw:1892950

closes odoo/odoo#28611
2018-11-13 15:08:20 +00:00
Christophe Simonis 99d0e1b80e [MERGE] forward port branch 12.0 up to a403155dec 2018-11-12 13:06:48 +01:00
Odoo Translation Bot 8d77288a8c [I18N] Update translation terms from Transifex 2018-11-11 03:16:11 +01:00
Odoo Translation Bot dcc077afc5 [I18N] Update translation terms from Transifex 2018-11-11 01:26:46 +01:00
Christophe Simonis f66a9cdbcf [MERGE] forward port branch 11.0 up to bab5ccfdd7 2018-11-05 17:51:04 +01:00
Christophe Simonis bab5ccfdd7 [MERGE] forward port branch saas-15 up to ca2b46c2d1 2018-11-05 15:52:38 +01:00
Christophe Simonis ca2b46c2d1 [MERGE] forward port branch saas-14 up to 03a35392da 2018-11-05 15:09:30 +01:00
Christophe Simonis 03a35392da [MERGE] forward port branch 10.0 up to d3b86ab930 2018-11-05 14:11:40 +01:00
Andreas Perhab d3b86ab930 [FIX] purchase_requision: fix syntax error
payment_term.id, creates a tuple wich works if payment_term.id is set
in case payment_term.id is False this creates the tuple (False,) which
is then converted by the Odoo ORM to a account.payment.term(False, )
record set, which in term may cause weird behaviour as this value does
not eval to false in cases like `if self.payment_term_id:`

Closes odoo/odoo#28397
2018-11-05 13:06:33 +01:00
Odoo Translation Bot 79b701230d [I18N] Update translation terms from Transifex 2018-11-04 03:16:30 +01:00
Odoo Translation Bot 1da3ff5a0a [I18N] Update translation terms from Transifex 2018-11-18 03:15:42 +01:00
Odoo Translation Bot e2afb0755d [I18N] Update translation terms from Transifex 2018-11-01 02:44:41 +01:00
Christophe Simonis 3b3a65bef0 [MERGE] forward port branch saas-11.4 up to dc35de9d30 2018-11-06 14:12:51 +01:00
Christophe Simonis dc35de9d30 [MERGE] forward port branch saas-11.3 up to f66a9cdbcf 2018-11-06 10:16:30 +01:00
Christophe Simonis b106b7ce0b [MERGE] forward port branch 12.0 up to dd70c68426 2018-11-06 16:40:07 +01:00
Christophe Simonis a299517f83 [MERGE] forward port branch saas-11.3 up to 6136f0c02e 2018-10-29 11:56:32 +01:00
Christophe Simonis cc8e8237bf [MERGE] forward port branch 11.0 up to 84500c27b1 2018-10-25 13:59:45 +02:00
David Arnold cbc72dba18 [FIX] purchase_requisition: traceback on validate
The subsequent code strongly suggests that pick_in can be None,
however, the raise_if_not_found has not been set properly.

closes odoo/odoo#27397
2018-10-20 21:22:37 +00:00
Odoo Translation Bot 98ee84e976 [I18N] Update translation terms from Transifex 2018-10-21 03:22:16 +02:00