Commit Graph

206 Commits

Author SHA1 Message Date
Goffin Simon 47e7f5d9bd [FIX] stock_account, sale_stock: _get_partner_to_invoice
When getting the partner to invoice, the function _get_partner_to_invoice
must check the type of the invoice to create.

opw:658460
2015-12-11 13:13:48 +01:00
Goffin Simon e3b90ba1d4 [FIX] sale_stock: payment_term in supplier invoice
When invoicing a supplier, this is the supplier payment term which
has to be taken into account.

opw:656307
2015-11-17 10:45:17 +01:00
Goffin Simon a6831546c1 [FIX] stock_account: VAT issue
In the case of a move from an out_invoice not linked to a sale order, the customer taxes set on
the product of this move must be taken into account to create the customer invoice line.

opw:645879
2015-08-03 09:01:17 +02:00
Goffin Simon e61970241f [FIX] sale_stock: SO status
When creating a SO with a line without specifying a product, the
workflow didn't allow to pass the SO in Done when the invoice is
paid.

opw:644853
2015-07-16 12:03:24 +02:00
luistorresm 01e4b76f65 [FIX][sale_stock]Added validation in get_partner_to_invoice, to only check sale.orders when the picking that call this method coming from a sale.order 2015-07-01 08:26:06 +02:00
Nicolas Martinelli 1beb4db6c0 [FIX] purchase, sale_stock: make sure to avoid mixing between in and out invoices
When SO/PO invoices are generated on delivery, there might be a mix between
sale and purchase data on the invoice.

opw-634898
2015-05-27 16:11:31 +02:00
Goffin Simon 75b9932451 [FIX] stock_account: VAT for extra moves
If an extra move contains a product which is not initially in the order,
the taxes set on this product must be considered according to the fiscal position
of this order.

opw:634305
2015-05-27 09:03:18 +02:00
Nicolas Martinelli c0deb1f726 [FIX] sale_stock: check if moves are already done when cancelling a SO
It prevents to cancel a SO for which moves are already done.

opw-634415
2015-05-19 14:12:26 +02:00
Nicolas Martinelli 9b2b437df4 [FIX] sale_stock: add check on invoice type during generation of invoice from delivery
If route is set on dropshipping and the PO invoice is generated from picking, the unit price
used in the supplier invoice must be the cost price. In this particular configuration, this was
not the case because the unit price was replaced by the sale price.

opw-634898
2015-05-19 09:48:51 +02:00
Goffin Simon 787a1422d7 [FIX] sale_stock: Additional information on invoice
When invoicing "on delivery", the "additional information" must be passed
from the SO to the invoice. Same behaviour as "on demand".

opw:639590
2015-05-13 14:36:37 +02:00
Nicolas Martinelli 769fc81140 [FIX] stock_account: fix dependencies
Purchase and Sale are not part of the dependencies of stock_account, so purchase_line_id
and sale_line_id might not exist.

Fixes #6619
2015-05-13 12:51:18 +02:00
Guewen Baconnier 3a314780c0 [FIX] sale_*, delivery: more consistent ignore of cancelled SO lines
Sales Order lines have a cancelled state, but this state is not
always considered when looping over lines. This check is
done in some places already and this patch's aim is to do it in the
remaining places.

- Cancel the procurement of a sale line in sale.order.line
instead of sale.order, so a line canceled individually with
sale_order_line.button_cancel will properly cancel it
procurement.
- Sale report: uses the state of lines instead of Sales order,
so canceled lines of not-canceled orders are correctly represented
in the analysis.
- test: do not create invoices lines for canceled sale lines
- test: creation of moves with canceled lines
- test: check if lines are still canceled when sale order is done

Closes #6036
2015-04-24 17:29:51 +02:00
Ravi Gohil a7cb326e5a [FIX] stock_dropshipping: do not warn for dropshipped items non-availibility
When selectiong a dropshipped product in a sale.order, the user should not be
warned that the product is not available in stock (as it never goes to the stock
anyway but directly from the supplier to the customer).
Factorise verification in _check_routing method.
2015-04-24 15:55:56 +02:00
Goffin Simon 7b923b57ba [FIX] sale_stock: supplier invoice
During the creation of an invoice, the partner returned by "_get_master_data" depends on inv_type.
inv_type = "out_invoice" is for customer invoice
inv_type = "in_invoice" is for supplier invoice

opw:632392, 632583
2015-04-21 08:47:06 +02:00
Goffin Simon 79ac324ca1 [FIX] stock_account: Invoicing on incoming shipment
When an extra line is added on an incoming shipment, the resulting
invoice must consider the tax of the product.

opw:630758, 630778
2015-04-01 09:28:48 +02:00
Nicolas Martinelli 3d05ddab50 [FIX] sale_stock: Cancel all procurements linked to a sale order
During the creation of a Sale Order containing a product for which 'Make To Order' is activated
in the Procurements, two procurements are created:
- one for 'Partner Locations/Customers' location
- one for 'WH/Stock' location

If the Sale Order if cancelled, the user must first cancel the picking (delivery order).
This will trigger the cancellation of the procurement with the 'Partner Locations/Customers'
location.

The new behavior is to cancel the procurements linked to the Sale Order, which will trigger
the cancellation of the picking.

opw: 630170
issue: https://github.com/odoo/odoo/issues/3805
2015-03-17 16:37:24 +01:00
Olivier Dony 3a8ce072cd [FIX] sale_stock: context is generally frozen in 8.0 2015-03-09 15:03:19 +01:00
Christophe Simonis 416f0246ac [MERGE] forward port of branch saas-3 up to 4a3c471 2015-03-09 12:03:22 +01:00
Christophe Simonis 4a3c4713e9 [MERGE] forward port of branch 7.0 up to 209ce6f 2015-03-09 11:24:32 +01:00
Josse Colpaert 872a80c419 [IMP] Stock: Not only service products can be invoiced after shipment, but also lines without product
Purchase lines or sale order lines without product should have the same behaviour
when invoicing based on shipments as those with services
2015-03-05 18:09:11 +01:00
Lionel Sausin (Numérigraphe) 5be3ac1fd0 [FIX] sale_stock: use current product's UoM to check availability
When selecting a product in a sale.order, the asked quantity is verified against
the available quantity.
If the user changes the UoM or the onchange from super call changes it,
the context should be updated accordingly.
Fixes #2559
2015-02-25 18:32:26 +05:30
Josse Colpaert d416492259 [IMP] To determine the invoice we put extra moves in, it is better to take the values from the sale order / purchase order if we can find it through the picking
[IMP] Add comments

[IMP] Simplify code
2015-02-25 10:30:36 +01:00
Josse Colpaert cb6e27c992 [IMP] When invoicing from multiple pickings, services should be checked for all purchases/sales
[FIX] Should make sure purchase order lines are not invoiced twice
2015-02-25 10:29:50 +01:00
Josse Colpaert 6ea0cc41b9 [FIX] Drop shipping invoice correction
When invoicing from dropshipping picking, choose the correct partner.
Also, change the partner on the picking to be the partner of the purchase.
Change the picking report to include the destination partner or the warehouse address on the right.

[IMP] Only put partner_id on move from purchase when really necessary

[FIX] Default value of partner on stock move should be False
2015-01-06 15:21:35 +01:00
Guewen Baconnier 7ede1bc1c6 [FIX] sale: copy sales team on the invoice from a sale order
Follows 31a01ea, propagation of some fields from sales orders to invoices (when
created on deliveries) have been added but it missed the section_id field (Sales Team).
Fixes #4155
2014-12-10 16:30:08 +01:00
Alexis de Lattre 31a01ea772 Fixes #3851 Create invoice from picking copies some parameters from the order to the invoice 2014-12-03 17:53:25 +01:00
Adrien Peiffer def9222bd9 [FIX] Fix wrong unit price on invoice genereted by stock picking when uos is used
[IMP] Rounding not necessary
2014-12-03 16:23:56 +01:00
Alexandre Fayolle 817e459d43 use warehouse._get_mto_route to get the MTO route
instead of using a custom lookup with a different implementation
closes #2608

pass context as a named argument
2014-09-30 10:31:33 +02:00
Bhumi Patel c707c61f8d [FIX] sale_stock: packaging was given a product instead of a product template id, leading to possible crash or incoherent values. 2014-09-17 15:31:19 +02:00
Josse Colpaert ae2eb43e30 [IMP] Implement comments on pull request 2014-09-12 13:49:42 +02:00
Josse Colpaert 064b1a3a40 [IMP] Old hack where uom_id had to be empty in on_change
[IMP] Add purchase order origin on picking

[WIP] Picking type on move for location on routing

[IMP] Provide extra function for custom buttons on picking

[IMP] Action assign optim

[IMP] Push apply should take invoice_state into account.  Propagation of cancel of stock moves should depend on procurement rule
2014-09-12 13:49:41 +02:00
Josse Colpaert 86b8e73482 [IMP] Clean need_procurement and add partner on procurement for Phantom with service 2014-09-03 19:18:16 +02:00
Josse Colpaert 6553e22306 [WIP] Create procurement when Phantom 2014-09-03 19:18:16 +02:00
Nicolas Seinlet c2b7bca486 - Fix #1253
- avoid using sale objects in stock_account module
- check the purchase side
2014-09-03 19:18:16 +02:00
Thibault Delavallée dea05e6a84 [FIX] sale_stock: product_id_change_with_wh should not call another method (product_id_change) using super, but self. Otherwise some overrides are lost, leading to issues with event-related products. 2014-08-08 16:57:32 +02:00
Olivier Dony f1d5dfa85b [IMP] sale_stock: do not verify inventory for non-stockable products (sale.order.line onchange) 2014-08-08 14:37:14 +02:00
Jitendra Prajapati 240e042363 [FIX] sale_stock: invoice createde from picking was not using the prive list from the bom components 2014-08-05 09:49:42 +02:00
Josse Colpaert 3b636a5df0 [WIP] Simplify procurement check and sales order workflow and that way phantom boms will work 2014-07-15 18:38:06 +02:00
Raphael Collet 33eb3dffb2 [REM] models: remove the magic methods signal_XXX() 2014-07-07 11:50:30 +02:00
Raphael Collet cbe2dbb672 [MERGE] new v8 api by rco
A squashed merge is required as the conversion of the apiculture branch from
bzr to git was not correctly done. The git history contains irrelevant blobs
and commits. This branch brings a lot of changes and fixes, too many to list
exhaustively.

- New orm api, objects are now used instead of ids
- Environements to encapsulates cr uid context while maintaining backward compatibility
- Field compute attribute is a new object oriented way to define function fields
- Shared browse record cache
- New onchange protocol
- Optional copy flag on fields
- Documentation update
- Dead code cleanup
- Lots of fixes
2014-07-06 17:05:41 +02:00
Josse Colpaert eb13d3ee5f [IMP] Make sure there is a link between purchase order invoice and purchase order 2014-06-16 16:04:04 +02:00
Olivier Dony 9f0ecb3572 [MERGE] Forward-port of 7.0 bugfixes up to 4d3a5df 2014-06-12 13:49:32 +02:00
Denis Ledoux 4d3a5df001 [FIX] sale_order: set state field track_visibility
sale_order module override state field of sale.oder (sale.sale.py) and forgot to reset the track_visibility, therefore sale orders state changes are no longer tracked once this module installed.
2014-06-12 12:37:11 +02:00
Christophe Matthieu 36cdac48b7 [IMP] product: move product packaging field from product.product to product.template 2014-06-03 11:53:41 +02:00
Christophe Simonis a756b82372 [MERGE] forward port of branch saas-4 up to revid bb26dea 2014-05-20 20:19:55 +02:00
Martin Trigaux 583fe74ba2 Forward-port of latest saas-3, up to revision 9455 (rev-id mat@openerp.com-20140514080416-m4t23y0rxx2ot7y6) 2014-05-14 10:37:54 +02:00
Martin Trigaux 8ea4f581ed Forward-port of latest 7.0, up to rev. 10046 (rev-id: launchpad_translations_on_behalf_of_openerp-20140514062049-vjclnuxlkbto0tsj) 2014-05-14 10:04:16 +02:00
Martin Trigaux 7dbfcede36 [FIX] sale_stock: when checkign the available quantity, do not include uom as it is already present in the context and will be included in the computation of product_obj.virtual_available (opw 607150)
fixing error message that does not match chosen units when not enough stock
2014-05-13 17:02:13 +02:00
Anael Closson 5bc76f63e9 [FIX] sale_stock: error message does not match chosen units when not enough stock. 2014-05-13 14:19:45 +02:00
Anael Closson 11a9c2d409 [FIX] sale_stock: new product uom is done twice in sale order line on change - opw 607150
[FIX] sale_stock: comparing stock and sale order line qty is always done with default uom rounding precision
2014-05-13 14:00:06 +02:00