Commit Graph
111277 Commits
Author SHA1 Message Date
Pierre Masereel b15918416a [FIX] mrp: traceback on bom structure and cost reports
Since the refactoring of report in rev: https://github.com/odoo/odoo/commit/e80238042c9d93d492ea8b06b0041aced0d81dcd
2017-08-10 10:42:19 +02:00
qdp-odoo 35b3617667 [FIX] account: payment onchange in multi currencies
Computation of the field 'Difference amount' was wrong as it was converting amounts in base currency in the following use case:
- company currency USD
- invoice currency EUR
- payment's journal currency USD but payment's currency EUR
- invoice of 100€, payment of 20€: difference was not 80€ because it was converting to USD
2017-08-10 10:31:51 +02:00
qdp-odoo 5641372532 [FIX] account: show payments in multi currencies with the rate of the invoice date instead of the payment date (so that we can see a meaningful residual)
Without this patch, the residual of the invoice doesn't correspond to the real residual of the invoice's receivable/payable line(s)
2017-08-10 10:29:38 +02:00
Simon Lejeune dda4491461 [REF] stock: action_assign performance
Also remo `_check_entire_pack` logic, as all moves run it
on their picking it's useless to use it on picking himself.
2017-08-09 17:18:35 +02:00
amoyaux 4b72966ea8 [FIX] stock : Stock user should be able to create a picking.
A stock user is not allowed to save a picking. It happens
because the picking view use the field show_operations that is
a related to stock.picking.type.show_operations. Since stock user
do not have right to write on picking type it will fail.

This commit add a readonly on show_operation on the picking view
(already invisible). With that change the field will not be send
to the server and thus not writed.
2017-08-09 14:31:33 +02:00
Pierre Masereel fa9ad1563a [FIX] stock: traceability order of quant and move lines
When a mix of quants and move lines is displayed in traceability report,
they are not correctly ordered by date.

To fix this we sort them after having all quants and move lines
2017-08-09 13:31:23 +02:00
Pierre Masereel 783f5f54da [FIX] mrp, stock: adapt traceability for mrp unbuild 2017-08-09 13:31:23 +02:00
amoyaux 0c8ebe05d7 [REF] stock : remove old/useless function
This commit remove the _filter_closed_move function that is no
more used since the refactoring introduced in saas-17
2017-08-09 11:08:51 +02:00
amoyaux f438a11099 [FIX] stock : return serial number
When an operation has the check for create new lots/serial numbers
activated and it exists a return that use this operation. The return
with serial number is not possible since it will display the view for
creating new serial number while we are returning some of them.

Trying to add the serial number name will fail due to the constraint
that ensure maximum one specific serial number by product.

This commit change the context before calling the view in order to
always display the many2one lot_id if the move is a return.
2017-08-09 11:08:25 +02:00
amoyaux 010b4a1000 [FIX] purchase : pickibng should be removed if there is no move line.
Use case to reproduce the bug:
- Create a PO line with 10 product -> validate the picking
- Edit the PO line and add 10 product -> it creates a new picking with a move line
- Edit the PO line and remove the 10 products
-> There still an empty picking that is not linked to the PO.

This happens because the _create_or_update_picking in purchase
only remove the stock move if it is empty but do not check anything
on the picking.

This commit add a check on the picking if there is no move inside,
delete it.
2017-08-08 17:01:42 +02:00
amoyaux cb1d516365 [REF] mrp : remove stock.quant inherit.
The field created by this inherit are no more used
anymore. The logic of produced/consumed has been move
on stock_move_line by this commit 0469d2e712
2017-08-07 16:13:26 +02:00
amoyaux 01429dc29b [FIX] mrp : Unbuild manually and with lot
Since refactoring in saas-17 quant_ids are removed and
the logic is instead locate on stock_move_line. This commit
adapt the method by trying to undo the created move_line
during the MO.

This commit also add a default_uom_id in the view's context in order
to remove a traceback. Since 0469d2e
uom is mandatory on stock_move_line.

It also add a bunch of tests in order to check the behavior of unbuild
with 4 test: without tracking, consumed product tracking, produced product
tracking and everything tracking.

Know limitation of this commit:
-> No warning message when unbuild more than in stock.
-> Wrong result if trying to unbuild twice the same MO
with consumed product tracked with different lot/SN
2017-08-07 16:13:13 +02:00
amoyaux 4ea8af066c [FIX] mrp : error when using a lot on a MO
Trying to set multiple lines with different lot on a MO
will raise an odoo server error with the field product_uom
on model stock.move.line.

This bug is linked to stock refactoring commit 0469d2e712
where the uom become required on move line. In order to get a default
value on create call the uom should be pass in the view's context.
2017-08-07 16:12:41 +02:00
amoyaux 5a78462f90 [IMP] mrp : usability for produce wizard
On the production wizard when you are using a product tracked
by SN/lot and another not tracked as consumed element. You edit
the form view by settings the correct quantity -> Use the produce
wizard. It will display the tracked product (you can see the details
you entered before) -> validate. It will double the quantity done
for the not tracked product.

This commit will change the wizard behavior by only set the quantity
done on untracked product if it is not already set.
2017-08-07 16:11:59 +02:00
Pierre Masereel a251afccbe [FIX] stock: traceability downstream order and date
The traceability report in downstream was looking for newer move lines
instead of older ones, which leads to not showing all related traceable
moves.

We also changed the sort order of the move_lines in downstream
2017-08-07 14:41:24 +02:00
Pierre Masereel 7b4129d1ee [FIX] stock: move_line date default value
introduced in rev: https://github.com/odoo-dev/odoo/commit/0469d2e7126c46e019ed5f4233ef7b20d3499a0e
2017-08-07 14:28:25 +02:00
Simon Lejeune e1cea2640f [REF] stock: create quants in every location
The purpose of this is to help stock manager in their quants analysis.
An overview of quants can be accessed via inventory menu and for specific
lot/SN via the locate button.

This commit add quants in every location (only internal location previously)
The purpose is to introduce a double entry for quant (add quants to a destination
location will always remove quant from a source location).

Quants in customers/suppliers location are shared between all customers/suppliers.
In order to know the amount of product that come from a specific customer/supplier
the tracability report should be used.
2017-08-07 12:10:13 +02:00
Simon Lejeune f55a2aa9df [FIX] stock: action_done
There was an issue if you make a backorder for a reserved move while not
having any quantity done on it. The 0 move will have its `picking_id`
field set to the backorder, but not its move lines, and the result was
that a stock move could be considered `assigned` while not having any
move lines.

The test that could show this issue did not fail because of an unwanted
call to `_free_reservation` that would call `_recompute_state` on the
inconsistent stock move.
2017-08-07 11:18:34 +02:00
Pierre Masereel 7a9dd47ae5 [REF] stock, mrp, mrp_repair: implement mrp and mrp_repair traceability
The traceability report didn't take yet in consideration the consumed
and produced lines generated by manufacturing orders and repair orders.
2017-08-04 15:06:19 +02:00
Richard Mathot 310e3dadd0 [FIX] delivery: adapt weight computation to new stock 2017-08-03 16:01:07 +02:00
Richard Mathot ea0127000d [FIX] delivery: package_ids computation should not ignore packages with no packagings
Since shippers than handle multipackaging always have a fallback default
packaging
2017-08-03 14:09:19 +02:00
Yannick Tivisse ee5ebbadab [FIX] base/module: Use a correct env to load next action on install
Bug introduced in https://github.com/odoo/odoo/commit/c8601f4384e0c95abc92d1f0b3092cfe2cb2a79d

Purpose
=======

If a module installation is supposed to load an action (example: a wizard like in l10n_eu_service) and if the related action is defined in this module (example: l10n_eu_service.wizard), currently we're using the environment defined on self, which is not updated after the module install, and the key is not defined in the registry.

Specification
=============

Instead of using the environment on self, let's use the new environment created after the cursor commit.
2017-08-02 12:32:24 +02:00
Christophe Simonis a445548f07 [MERGE] forward port branch saas-16 up to 211961c374 2017-08-02 12:18:41 +02:00
Jérome Maes 04c5aa3125 [FIX] hr_timesheet_sheet: remove all remaining file
Some files were still present (or reintroduced) after module deletion.
2017-08-02 09:49:34 +02:00
Martin Geubelle 211961c374 [FIX] web: handle mutexify in standalone widgets
The rev. https://github.com/odoo/odoo/commit/99ae418bf24171fbc6bb27584059c27efb857e77
introduced a trigger_up `mutexify` when quick creating a record in a many2one ;
this broke the behaviour when the many2one was standalone (because it has no
BasicController and mutexify is handled in the latter).

An attempt to fix this issue has been made in the rev. https://github.com/odoo/odoo/commit/e83c3e2678500c9bf2c17b4d23ae9a294ebafaa7
by adding an option `standalone` in the field widget options. In this case,
the action was directly executed instead of the trigger_up. While this correctly
works, this implies that the option needs to be added in every standalone
many2one (and only many2one as the others won't use the option), which is not
very convenient.

An other attempt is made in this rev. by moving the mutexify handler from the
BasicController to the FieldManagerMixin ; as a widget that instantiates a field
widget needs to extend this mixin, both cases will work and we won't need to
specify the option anymore.

This commit thus partially reverts the rev. https://github.com/odoo/odoo/commit/e83c3e2678500c9bf2c17b4d23ae9a294ebafaa7
2017-08-02 08:49:12 +02:00
Christophe Simonis 072411b336 [MERGE] forward port branch saas-16 up to 8d89148d13 2017-08-02 01:08:42 +02:00
Christophe Simonis 8d89148d13 [MERGE] forward port branch saas-15 up to 5e19f28bfc 2017-08-01 23:11:27 +02:00
Christophe Simonis 5e19f28bfc [MERGE] forward port branch saas-14 up to d0ece6cd89 2017-08-01 23:07:22 +02:00
Christophe Simonis d0ece6cd89 [MERGE] forward port branch 10.0 up to afd4b68acc 2017-08-01 23:06:43 +02:00
Christophe Simonis afd4b68acc [FIX] website_crm_partner_assign: mock geolocalisation during tests 2017-08-01 22:39:29 +02:00
Christophe Simonis d1cf4f9672 [MERGE] forward port branch saas-11 up to ed36929265 2017-08-01 22:39:16 +02:00
Christophe Simonis ed36929265 [FIX] core: avoid tests to contact gravatar server 2017-08-01 22:03:39 +02:00
Christophe Simonis a49f637102 [FIX] website_slides: recreate pdf file
PyPDF2 didn't like previous version and threw warnings.
2017-08-01 19:06:40 +02:00
Khoi Nguyen 597d172ff0 [FIX] web: always call 'search_read' when loading calendar
This commit reverts
https://github.com/odoo/odoo/commit/2e2ab4e954cd5da8c0c06d393b334cefc7627315
(which ensures that if all filters are 'inactive' then nothing is shown)
for the following reasons:

- It is not necessary since _getFilterDomain was rewritten (see
  https://github.com/odoo/odoo/commit/4e12edc023dd20d435f5575b5517a3c11deb8421).
  If all filters are inactive, _getFilterDomain does now return an
  "in []" domain.
- It shows an empty calendar when filters yield an empty domain.
2017-08-01 18:03:15 +02:00
Christophe Simonis 6990c28d05 [MERGE] forward port branch saas-16 up to a42b056ca9 2017-08-01 18:00:22 +02:00
Christophe Simonis a42b056ca9 [MERGE] forward port branch saas-15 up to d3154e0ef4 2017-08-01 17:59:16 +02:00
Christophe Simonis d3154e0ef4 [MERGE] forward port branch saas-14 up to af9868bc28 2017-08-01 17:54:09 +02:00
Christophe Simonis af9868bc28 [MERGE] forward port branch 10.0 up to e6ad245634 2017-08-01 17:22:43 +02:00
Goffin Simon 39892cdaa1 [FIX] account: Only 64 characters for the name of an entry
When creating a customer invoice with description/reference with more than
64 characters, the description was cut to generate the name of the account move
lines. But it's possible to create an entry with more than 64 characters as name
by the interface. The limitation is deprecated.

opw:760316
2017-08-01 17:14:28 +02:00
Christophe Simonis e6ad245634 [MERGE] forward port branch saas-11 up to ab0e083ecb 2017-08-01 17:00:03 +02:00
Christophe Simonis ab0e083ecb [MERGE] forward port branch 9.0 up to 587668797e 2017-08-01 16:32:23 +02:00
Christophe Simonis 587668797e [MERGE] forward port branch saas-6 up to b3ddbbd4ba 2017-08-01 16:05:13 +02:00
Christophe Simonis b3ddbbd4ba [MERGE] forward port branch 8.0 up to 40197b38e5 2017-08-01 15:44:24 +02:00
Christophe Simonis e2826028ab [FIX] website_slides: only query google api if info is missing
With demo data, avoid doing requests on external service for
information we can provide.
2017-08-01 15:39:02 +02:00
Nicolas Martinelli 6c3bff8fd3 [FIX] stock: traceability button
- Archive a product
- Click on "Traceability" stat button => crash

opw-760717
2017-08-01 15:06:10 +02:00
amoyaux 657e5c15a3 [FIX] stock : reserve quantity with uom and chained moves
A bug happens in stock move's action_assign method. It tries to get
the quantity done and the reserved quantity from the parent move and
sibling move in order to guess the available quantty.

With uom activatred, the quantity done is not always the same than the quant
quantity and the quantity done on stock move/stock move lines has to be
converted in order to know the real quantity available/

This commit change the quantity done in action assign to the
associate product uom.
2017-08-01 14:50:32 +02:00
Nicolas Lempereur 40197b38e5 [FIX] web: typo css class 69925ca6
opw-760956
closes #18601
2017-08-01 14:05:21 +02:00
Nicolas Lempereur 69925ca6f0 [FIX] web: display prev/next arrow after grouping
On a list view, if we group records the arrows and changing page
feature are disabled. But if then we removed the grouping, the arrows
never reappeared.

note: not necessary as of 9.0 it was already solved in 1280bf251

opw-760956
closes #18596
2017-08-01 13:56:26 +02:00
rar-odoo 435c2eae19 [FIX] Account: account_field field typo
the field data-max is supposed to be stored in the database.
Currently, the arg is 'stored=True' which is not recognised by the orm.
This fix ensures the field is correctly sotred and thus not computed at reading.
2017-08-01 12:46:29 +02:00
Jeremy Kersten 66a6b670e9 [FIX] stock: improve warning to help user to find blocking move.
Add into the warning message the list of stock.move that raise the constraints
error.

When you create an 'Inventory Ajustment' of 1000 lines and see this error,
it is not easy to find which product could cause the problem.

This solution is not perfect since the name is not uniq, but it decrease
drastically the number of record to check manually.

opw-760643
2017-08-01 10:43:36 +02:00