Commit Graph
150 Commits
Author SHA1 Message Date
Robin Heinz bc67e6bf55 [IMP] point_of_sale: Add serial number on pos invoice
When we make an invoice with the point of sale, we now include the serial numbers on the invoice template if the option is ticked.

closes odoo/odoo#59516

Task-id: 2349339
Related: odoo/upgrade#1830
Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
2020-10-23 09:28:34 +00:00
Swapnesh Shah b07f2d31d2 [FIX] *: update document links
Before this commit, links to the documentation were referenced the
previous version, 13.0, instead of the current one, 14.0.

Eventhough there is a redirection done by NGINX of a "versionless" URL
to the latest one (e.g. /documentation/user/general/auth/google.html
-> /documentation/user/14.0/general/auth/google.html as of today), the
goal is to keep links owrking for users that will still be using the
14.0 in three years (and should not endup on the 17.0 doc).

closes odoo/odoo#60228

X-original-commit: 7ac08486d91d0ff0151abeeda057ffa6beda72e8
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2020-10-19 07:03:01 +00:00
yhu-odoo 81f86adf1f [IMP] stock,mrp,product,pruchase,repair: improve empty screen
Improve empty screen, add sample data.

Task 2310494
PR #55910

X-original-commit: 762457f1edd84208f43bd85de6be7316cfd20780
2020-09-09 10:15:32 +00:00
Yannick Tivisse a5874da269 [IMP] purchase,stock_account: Improve account properties display
Purpose
=======

https://github.com/odoo/odoo/pull/52351 already improved the display
by hiding some account properties if it wasn't really neeeded on manual
inventory valuation.

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

Keep the Account Properties section visible in any cases. The price
difference account is the only field of the section which is only
used in automated valuation.

closes odoo/odoo#54210

Taskid: 2232026
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2020-07-08 11:04:09 +00:00
Didier (did) 8add388db6 [IMP] Full Story Misc Usability improvements
Hide sections "Account Properties" & "Account Stock Properties" if the inventory
valuation (property_valuation) is set to manual.

task-2232026

closes odoo/odoo#52351

Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2020-06-29 11:21:26 +00:00
Nicolas Martinelli 2269a66251 [FIX] stock_account: add total value
Add the Total Value in the Inventory Valuation tree view.

opw-2254718

closes odoo/odoo#51385

X-original-commit: c3dd38de2d60a40b61f364f1daa004f67b3d5137
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2020-05-18 08:03:01 +00:00
Nicolas Martinelli bde92f013f [FIX] stock_account: hide SVL of consumable
- Create a consumable product
- Assign a FIFO product category, automated valuation
- Purchase some units
- Go to the Inventory Valuation report

The product appears in the list, while consumable should not.

We only show products linked to stockable products.

opw-2153840

X-original-commit: 8fa2440e8c055ca80bce27e33d5678745712fe53
2020-04-30 08:37:41 +00:00
Rémy Baranx (bar) bbd4391c15 [IMP] various: update of documentation links in res.config
Purpose
=======

- Change the font-awesome icon from fa-book to fa-question.
- Change the icon color to text-secondary (the same than the multi-company
  icon).
- Adjust the icon size to the uppercase text size.

closes odoo/odoo#47210

Taskid: 2209062
Related: odoo/enterprise#9116
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2020-03-18 09:53:15 +00:00
yhu-odoo b08e3d114a [REF] stock,stock_account: archived products and quantities
PURPOSE

Keep consistent behavior of the stat buttons and the different stock
reports when archiving a product

SPECIFICATION

Currently, you can archive a product but the behavior of the different
stock reports, stat buttons isn't coherent afterwards. Here are the
different behaviors that should be improved:
1.Keep quantity on hand and forecasted quantity visible (in the stat
button + when opening it)
2.Automatically (un)archive RR and BOM if the product is (un)archived
3.Valuation report: show the archived products without the "archived"
filter (behaves already this way in the inventory and forecast reports)
4.When a product has been archived and still has quantity in stock,
include it in inventory adjustments for which counted quantity = default
to stock on hand (dont do so for archived exhausted products).

Also, revert #47478 since we don't have active field.

LINKS

Task 2178269
PR #45586
Fixes #41634

Related: odoo/upgrade#811
Related: odoo/enterprise#8513
Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2020-03-13 08:37:26 +00:00
Rémy Voet (ryv) 7c55c20fce [IMP] stock_account: add button to create manual stock valuation layers
Add a way to create a munual stock valuation layer, create
a stock valuation layers implies :
- Change the stardard price with the new valuation by product unit in case of AVCO.
- Create a manual stock valuation layer with the added value.
- Update the remaining value of current valuation layer.
- If the Inventory Valuation of the product category is automated, create
related account move.

task-2123752
2020-03-04 16:07:40 +00:00
Rémy Voet (ryv) aaa3ead686 [REF] stock_account: merge/clean views of stock.valuation.layer
The views of stock.valuation.layer model
were in the wrong file,
move it, and merge duplicate search views. Also
remove the unused action 'action_stock_inventory_valuation'.

task-2123752
2020-03-04 15:44:53 +00:00
Rémy Baranx (bar) 7485177be1 [IMP] various: add documentation links in res.config
Purpose
=======

A 'book icon' link to the documentation of a feature has been
added in its settings panel, when it is useful (complex feature).

Add a nightly test that parses all the res_config_settings views
from the base one and checks that all documentation links are still valid.

Add the o_doc_link class to all documentation links to be able to easily
catch them if needed.

closes odoo/odoo#45813

Taskid: 2180574
Related: odoo/enterprise#8601
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2020-02-28 10:47:15 +00:00
Hemali Bhimani caa0e52d4b [IMP] *: add Archived filter in models with active field
task:2026285
closes:#45779

closes odoo/odoo#45779

Related: odoo/enterprise#8581
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2020-02-26 10:01:05 +00:00
Adrian Torres 97a5093117 [FIX] *: specify at least one field in search views
Without at least one field, performing a search in these models' search
view is outright impossible.

closes odoo/odoo#45177

X-original-commit: 0aabfbff3ce5d68bf37e1734ba7aa43f62803f3a
Related: odoo/enterprise#8379
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2020-02-12 11:09:05 +00:00
rso-odoo f648ab94eb [IMP] stock, stock_account: locations views and filters
- add a filter "production locations" on stock location
- add an action returning the production stock locations
- display a link to this action in the product category views in stock
  account so users can easily set the correct accounts on these
  locations
- set valuation journal an account before the others in the product
  category form

Task-2161057

closes odoo/odoo#43762

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2020-02-05 16:14:27 +00:00
wan d8c5cc1335 [IMP] account: add a readonly group
Task 2092079
Accounting firms that want to give access to their customers avoiding
mistakes and risks will love this profile that can't do anything
wrong... Maybe as well as companies auditors..?

closes odoo/odoo#39860

Related: odoo/enterprise#6576
Signed-off-by: Quentin De Paoli (qdp) <qdp@openerp.com>
2020-01-22 11:23:16 +00:00
yhu-odoo c87275a69f [FIX]stock_account: stock manager group not inherit account bill group
The inheritance of account billing group gives stock managers the access
to account module.
This commit is to remove this inheritance. When we need to access
account.move model, check if the user is a stock manager. If so, use
sudo() to get the access.

PR #43186
Task 2062611
2020-01-15 09:01:45 +00:00
Pratima Gupta a431865301 [FIX] stock_account: valuation details feedback
In this -
1) Modified the label of the accounting entries which take place when
receiving/delivering/producing with products in automated inventory
valuation so that it includes information about the source document
(MO/Transfer) and the the product about which the entry is.
like - (WH/MO/0001 - Finished product)

2) Hide the Valuation stat button shown on transfer while not in debug mode.

3) on landed costs, if no valuation layer created, don't display the button.

4) default groupby is missing on the main valuation report.

Task-2153155

closes odoo/odoo#42464

X-original-commit: abd8e56e10bfc58c2f777b5aeeeb0b6b7360629f
Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-12-30 10:20:01 +00:00
Yenthe666 7876af3ad0 [IMP] *: set name on page elements
page is an element that is often used for xpath

closes odoo/odoo#41718

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-12-16 15:10:24 +00:00
Kevin Baptiste 6cbe824871 [REV] web: reverts update to fontawesome 5.11.2
This reverts commit ff1c35513a.

closes odoo/odoo#41480

X-original-commit: 116057b26e71db4692280463669f3e80d813ddcc
Related: odoo/enterprise#7110
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2019-12-09 10:33:36 +00:00
Yenthe666 78ae3da902 [IMP] *: set name element on main containers in configuration views
This will improve the extendibility of view inheritance

closes odoo/odoo#41398

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-12-09 10:38:59 +00:00
Debauche Stéphane 42d3a82a80 [IMP] stock_account: remove the wizard which change the `standard_price`
Overwrite the method ``write`` of the model ``product.product``.

When we write on ``standard_price``, if
- the context key ``disable_auto_svl`` is not set
- the ``cost_method`` is not "fifo"
We automatically compute ``stock.valuation.layer``

(before we needed to manually call ``_change_standard_price``)

Task #2031422

closes odoo/odoo#41265

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-12-06 10:58:03 +00:00
Kevin Baptiste ff1c35513a [IMP] web: update to fontawesome 4.7.0 to 5.11.2
FontAwesome 5 introduced new names for some icons as described on
https://fontawesome.com/how-to-use/on-the-web/setup/upgrading-from-version-4#name-changes

This commit replaces the old names to the new ones.

closes odoo/odoo#35826

Taskid: 2050241
Related: odoo/enterprise#5180
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2019-11-28 10:05:12 +00:00
svs-odoo 2980369e0b [IMP] product, stock_account: editable prod. tmpl.
Makes the product.template list view multi-editable.
Sets field `standard_price` readonly when stock_account is installed.

Task #2078163

closes odoo/odoo#37697

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-10-01 14:24:02 +00:00
Simon Lejeune fae07f3bd5 [REF] stock_account: filters on valuation layer
closes odoo/odoo#37701

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-10-01 12:28:52 +00:00
William Henrotin 6b49fcb6aa [FIX] stock_account: always show update cost button on product
With this commit, the 'update cost' button is always displayed on product.product
whatever the variant count

closes odoo/odoo#37328

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-09-24 13:05:17 +00:00
Jinal Patel 0b59822825 [FIX] stock_account: avoid to display two 'Update Cost' button
In this commit, instead of change the whole button using XPATH
only change the attributes of button.
After this commit, displayed only one 'Update Cost' button.

task-2067787

closes odoo/odoo#36535

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-09-09 05:07:30 +00:00
Simon Lejeune d43d25020e [REF] stock_account: multi company
Ensure proper domains are applied and enforced on relation fields thanks
to the `check_company` attributes.

Adapt `_compute_value_svl` to return the valuation for a specific
company.

Every time a property is read, make sure `force_company` is properly in
the context.

Fixed the ir.rule.

task-1985992
2019-09-03 15:05:03 +00:00
Sébastien Theys 22a11a6f4d [REF] product, *: save product.template.attribute.value on variants
* account, hr_expense, mrp, sale, sale_product_configurator, stock_account,
  website_sale, website_sale_comparison

Before this commit, the `product.attribute.value` were stored on the variants.
This required filtering of attribute lines to find the appropriate matching
`product.template.attribute.value` that were used in most of the business code,
such as when computing the `price_extra`.

This also prevented to have multiple attribute lines for the same attribute,
which is needed to handle use cases such as grape varieties for wine products.
This will be done in the following commit.

After this commit, the combination of `product.template.attribute.value` will be
directly stored on the product variant.

Other changes
=============

Add `combination_indices` on product, which allows to quickly find a variant
matching a combination (1 simple indexed equality query as opposed to 1 query
with as many joins as there are attribute lines), and to add an easy
SQL constraint to ensure active combination uniqueness.

Add active field on `product.template.attribute.line` and
`product.template.attribute.value`, with the same behavior as variants:

They become archived if they can't be unlinked. This allows to keep the database
consistent, such as archived variants correctly keeping all their values, sales
order lines keeping their custom and no_variant. This is done with the help of
`ondelete=restrict` on the corresponding m2m fields, and the `unlink` methods
falling back to archiving when `unlink` is restricted.

Part of task-1912579

PR: #32946
2019-08-26 13:01:13 +00:00
Arnaud Baes b7e37fe608 [IMP] stock: inventory view cleanup
closes odoo/odoo#35719

Signed-off-by: Xavier Dollé (xdo) <xdo@odoo.com>
2019-08-14 13:12:58 +00:00
Arnaud Baes ced76bddab [IMP] stock, stock_account: move views cleanup 2019-08-14 12:27:05 +00:00
Arnaud Baes 9410e0ce00 [MOV] stock, stock_barcode: barcode fields in views 2019-08-14 12:27:04 +00:00
Simon Lejeune bc628b320d [REF] stock_landed_costs: usability changes
- update label for account_journal_id
- remove cost lines explanation
- label of the LC name
- remove former cost per unit
- auto compute cost line when validating
- rename former cost into original value
- remove additional landed cost form the tree view
- stock_landed_costs: rename cost line into additional costs
- add a final value field (Lucky day: the field I had to add was already
  defined but not used.)
- use monetary field
- make weight and volume optional
- journal entry visible only if posted
- landed costs wording in settings
- raise of no transfers are defined before validating

task-59011
2019-08-07 14:11:21 +00:00
Prakash Prajapati 16db6d8fd0 [IMP] stock(_*): set optional field to simplify the tree view
* = stock_account, stock_picking_batch, stock_product_expiry, delivery

Purpose of the commit is to set the new attribute OPTIONAL = SHOW/Hide on tree
view so the user can easily hide/show the optional fields on the tree view.

Update string date field from incoming products tree view.

Update string virtual_available field from product tree view.

task-1997453
Closes #33888
2019-07-30 08:53:05 +00:00
svs-odoo 088a1709f4 [FIX] stock_account,mrp_account: align Update Cost button
Task #2039731
2019-07-26 11:51:02 +00:00
svs-odoo 13e30d581a [IMP] stock_account: inventory valuation groupby product
In the Inventory Valuation report, values must be grouped by product_id.

Task #2039731
2019-07-26 11:51:02 +00:00
Simon Lejeune 112a4f309e [REF] stock_account: display update cost button on variants
The button wasn't displayed when going through a template's variants
stat button. It was missing an inherit on this view. We also try to
align them the best we can.

task-2029011

closes odoo/odoo#34682

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-07-16 15:02:32 +00:00
Arnold Moyauxandsvs-odoo ec02ca9176 [IMP] stock, stock_account: inventory at date
Usability improvement because when the user click on inventory
report it's mainly in order to edit/check its current stock since
commit da33eb36b8

This change redirect the user directly on stock.quant tree view
and add an inventory at date button in the control panel. This
button will open the same wizard than previously and ask for a
date. The same principle is used for valuation layer.

Co-authored-by: svs-odoo <svs@odoo.com>

Task: 1880379
2019-07-12 11:37:13 +00:00
Arnold Moyaux c861edefaa [IMP] stock_account: value on quant
This commit introduces back the value by location feature dropped in v11.
The feature was dropped because we implement financial fifo, thus the
value by location does not make sense for this cost method.

This commit introduces an estimation of the value by location in fifo.

Task: 1880379
2019-07-12 11:37:13 +00:00
Hiral Bhavsar 3cd7ed07a2 [IMP] *: remove 'view_type' on window actions.
The old tree views don't really exist anymore, this odd pseudo-flag to
dispatch between "list" and "tree" tree views has no reason to remain.

Task 1937686

closes odoo/odoo#31243

Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
2019-06-17 11:34:17 +00:00
Simon Lejeune 68d8e49f2f [REF] stock_landed_costs: adapt to valuation layers
We need to increment the value of another layer. We don't  want to write
on this layer in place as we used to do for multiple reasons:
- valuation at date: before the application of an lc, the value should
  not change
- if the layer was consumed, we would need to adapt the consumers and
  if one day we would have needed to understand what happened in the
  fifo stack it would be hell

So we allow to create a valuation layer linked to another valuation
layer through a simple M2O O2M. At the time it is only used on the
landed costs to add value and no quantity so the code expects it would
be the case and it is not enforced. We adapt `_run_fifo` to use the full
value.

We also add a stat button on the landed cost to access the valuation
layers, like what is done for the picking and manufacturing orders.

task-1875873
2019-06-10 20:43:00 +00:00
Simon Lejeune 6fd05759e7 [REF] stock_account: remove old valuation code
The new code was sitting next to the old one, now that everything is
adapted (minus the cost method changes), we can remove the old one.

We also adapt the valuation wizard to use the stock valuation layer
action, now that the others are removed.

task-1875873
2019-06-10 20:42:59 +00:00
Simon Lejeune 6127608cae [REF] stock_account: standard cost method with valuation layers
Valuation of standard move: We introduce _create_in_svl and
_create_out_svl and call these method in _action_done only on the
standard move, the other valuation methods still use the old code. We
hijack _account_entry_move to create journal entries anyway for the
valuation layer with a minimal diff. Helpers for the valuation layers
creation are added on the product because we will need to create similar
layer without stock move later on when we'll implement changes of cost
method. We also make a first implementation of the edition in the past
to make some tests pass, it will be completed with other cost method
implementation

Change of standard price: Before this commit, the wizard to change the
standard price was only displayed in perpetual, because it was used to
create accountign entries. We also use this wizard in manual now,
because we want to create a stock valuation layer. Fortunetaly, the
accounting fields of this wizard are not required if the product has a
manual valuation. And the new method is private.

We adapt the existing tests as well as we can and include the start of a
new battery of tests: test_stockvaluationlayer.py

task-1875873
2019-06-09 14:11:36 +00:00
Simon Lejeune 2c77efb05c [ADD] stock_account: stock valuation layer
This commit brings the model, views and compute method for the value and
the quantity valued. An ir rule prevents to read the value of another
company. Stat button are added on done picking to access the generated
layers.

Further commits will adapt one by one the cost method to actually use
the stock valuation layer when

As the goal is to move the valuation fields away from the stock move, we
set the necessary fields on the layer. Note the absence of `remaining_value`.

task-1875873
2019-06-09 14:11:36 +00:00
Simon Lejeune 72693c1d0a [REF] stock_account: make property_stock_journal required in the view
As journal_id is required on an account move, this field should not be
treated differently as the other accounting fields on this view.

task-1875873
2019-06-09 14:11:36 +00:00
svs-odoo cc9324f740 [IMP] *: usability of Inventory Adjustment
Change the use of Inventory Adjustment, notable changes are:

    - Removed filter field: When user creates a new inventory
    adjustment, he can set one or multiple locations and/or products.
    An inventory adjustment will worry only about defined
    locations/products, but if neither product or location was set,
    it'll manage all stock.

    - Inventory Adjustment Lines have their own view instead of be
    listed on the Inventory Adjustment form view.
    Inventory adjustment lines have new color legend:
        - Red: The quantity is outdated.
        - Blue: There is difference between the on hand quantity and the
        counted quantity.
    New inventory lines created by the user are written in bold.

    - User can't modify already existing inventory lines, except for the
    counted quantity.

    - When an inventory line is outdated, the user has the possibility
    to select and update it, that'll recompute the on hand quantity.

    - When an inventory adjustment is validated, it will take in account
    only the difference between the theoretical quantity ('On Hand
    Quantity') and the counted quantity to adjust the quants.

    - When an inventory adjustment is canceled, it will keep its
    inventory lines and won't regenerate them when re-started.

    - When an Inventory Adjustment generates Account Moves, user can now
    find them in a stat button in the Inventory Adjustment form view.

Also, made some changes in demo data to match new requirement.

Task #1935921
2019-05-29 14:03:29 +00:00
Christophe Simonis e145f2b0c8 [MERGE] forward port branch saas-12.2 up to 2694174b41 2019-04-10 15:10:24 +02:00
Christophe Simonis c9e1deb496 [MERGE] forward port branch saas-12.1 up to af313858b4 2019-04-09 20:48:01 +02:00
Christophe Simonis af313858b4 [MERGE] forward port branch 12.0 up to c1c322dd40 2019-04-09 20:43:35 +02:00
Nicolas Martinelli 719b0ab683 [FIX] stock_account: standard price currency
Oversight during forward-port of 950d0f1849

closes odoo/odoo#32488

Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2019-04-08 10:09:10 +00:00