Commit Graph
444 Commits
Author SHA1 Message Date
William Henrotin 56e7bcf0cb [REF] *{stock,mrp}*: rename reserved fields
This commit rename product_uom_qty into reserved_uom_qty and product_qty
into reserved_qty on stock move line to stop mistake them with the stock
move quantities fields.

Task: 2648449
Part-of: odoo/odoo#80434
2021-12-07 16:20:06 +00:00
Touati Djamel (otd) 5646476dbf [FIX] mrp: improve mrp BOM report
Steps to reproduce the bug:
- Create a BOM:
    - set the quantity of the finished product and component as more than 1
    - save > print > BOM Structure

Problem:
The report generated shows the qty and cost for production of 1 unit of product, regardless of the BOM quantity

opw-2691632

closes odoo/odoo#80145

X-original-commit: d08b0abd56a04a23e155b345bf1796a031321f2f
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
Signed-off-by: Djamel Touati (otd) <otd@odoo.com>
2021-11-22 07:49:55 +00:00
roen-odoo f12c91d162 [FIX] mrp : BoM report
Current behavior:
When creating a BOM with quantity different than 1 (here 12) with operation duration 1 minute and work center capacity 23
The BoM Structure & Cost report only changes the time for the operation when the quantity is > 276
However, when planning a MO the expected duration changes to 2 minutes when the quantity is > 23

Expected behavior:
Expected duration should be the same in the MO and BoM report

Steps to reproduce:
- BOM with quantity different than 1 (here 12)
- operation duration 1 minute
- work center capacity 23
- go in BoM report

closes odoo/odoo#80048

X-original-commit: cf90943875da25456cde4faf967ce27d886c0851
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
2021-11-19 09:58:45 +00:00
roen-odoo e1a55d8324 [FIX] mrp : bom report duration for dozens
Current behavior :
When a bom is created with uom set as dozens the report
operations time is not correct. For exemple if the operation
time is 10 minutes. The operation time for a dozen should be
120, but at the moment it's 10 minutes

Steps to reproduce:
Have a product in units.
Create a bill of materials in dozens.
Have a operation where the workstation that has a capacity of 1.
Look at the Bill of material cost and structure even though it uses a dozen it shows
the operation time for one unit.

opw-2669899

closes odoo/odoo#79624

X-original-commit: 11f905737ea73aaf26dc792639abf66549a31864
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
Signed-off-by: Engels Robin (roen) <roen@odoo.com>
2021-11-12 12:49:52 +00:00
Tiffany Chang (tic) b1e2610390 [IMP] mrp: remove obsolete reception report label
In a previous commit, the reception report label was refactored to be
better, making this report obsolete. For migration purposes, we remove
it in this separate commit.

Previous COM PR refactoring: odoo/odoo#76411

closes odoo/odoo#76147

Task: 2632884
Related: odoo/upgrade#2815
Signed-off-by: Arnold Moyaux <arm@odoo.com>
2021-11-09 13:19:51 +00:00
Tiffany Chang (tic) 1c97b75c97 [IMP] mrp,stock: always show product in reception report labels
Previously the reception report > "print labels" would only print the
picking name (or SO if provided) + delivery address (if provided) when
not for a MO. Label has been updated to include the product name.

During this update a few other related improvements were made:
- make the label based on stock.move (so extending is no longer
  needed in MRP)
- formatting of label is improved so now address will be truncated
  instead of wrapping (and potentially losing lines at end of address)
- line padding is reduced so we can fit more lines in the label
- "Print Labels" button at source level will now be enabled when its
  corresponding "Assign All" button is pushed (previously only the
  "Print Label"s of each moves' line was enabled.

Part of Task: 2632884

X-original-commit: 9774c1ab1d68cf095b64a82b56f100d747fc8a56
Part-of: odoo/odoo#79408
2021-11-05 13:48:50 +00:00
Florian Damhaut 425ff940da [FIX] mrp : Remove operations from production template when the module is disabled
Current Behaviour :
1. Enable Work Orders
2. Add an operation to a BOM
3. Disable Work Orders
4. Create a manufacturing order for this product and finish the manufacturing.
5. Print the production order

What is the current behavior that you observe?
The production order has the operations in it even though the work order option has been disabled. This is because disabling the work order option just hides the operations and does not remove it from the BOM.

What would be your expected behavior in this case?
The printed production should not show the operation.

opw-2660545

closes odoo/odoo#78544

X-original-commit: d73752c5fe983ce6a9147721e732396394a77cc4
Signed-off-by: William Henrotin <Whenrow@users.noreply.github.com>
2021-10-18 12:45:47 +00:00
Rémy Voet (ryv) 6aa8b7dd67 [IMP] mrp_subcontracting: improve mrp bom report
- The "BoM Structure & Cost" takes now in account
the subcontracting cost.
The subcontracting cost depends of the best supplier info in product
and subcontractor register in the BoM.
- Also add this subcontracting cost (to the cost field) when we click on
"Compute Price from BoM" in the product view.

task-2486811

Part-of: odoo/odoo#75041
2021-09-03 10:37:46 +00:00
Rémy Voet (ryv) 10c6f4e837 [REF] mrp: simplify the bom strucure report
Add `_get_extra_column_count` to extend and clean
extention for mrp_plm and mrp_subcontracting.

See enterprise commit.

task-2486811

Part-of: odoo/odoo#75041
2021-09-03 10:37:46 +00:00
Tiffany Chang (tic) fd52760266 [IMP] mrp(_account): include byproduct cost share in BoM/MO
For improved cost analysis, byproducts can now have a "cost share" (out
of 100%) indicated. This cost share will by multiplied by the total BoM
cost (i.e. components + operations costs) and reflected in the stock
valuation. The final product will also have the byproducts cost
subtracted from its final stock valuation. This is of course only
applies when costing methods are appropriate (i.e. non-standard price).

Additionally, we can now "Compute Price from BoM" for byproducts (via
its product form) and the BoMs that it is a byproduct of are now counted
towards its # BoMs smart button (we will now also see these BoMs when
clicking on the smart button). Of course when there is no cost share for
byproducts then clicking on "Compute Price for BoM" will not change the
a byproduct's cost and if there are multiple BoMs the prodcut is a
byproduct of, the calculation will only be based on the first BoM it
finds (i.e. same as current logic for manufactured products).

BoM Cost report has been updated to include byproducts with cost shares
(byproducts with cost share = 0 will not show up in report).
Additionally we update the report to display operations only costs now
that BoMs are allowed to have no components in them.

Part 1 of Task: 2440068
Upgrade PR: odoo/upgrade#2727
Related ENT PR: odoo/enterprise#20169

Part-of: odoo/odoo#74951
2021-08-26 11:34:35 +00:00
Tiffany Chang (tic) 53cc41016f [IMP] mrp, product, {purchase_, sale_}stock{_picking_batch}: add reception report
New reception report added for non-outgoing transfers. This is intended
to support easier stock allocations by allowing dynamic MTO
assignment/unassignment, e.g. if we have an incoming transfer with
products we want to assign to an existing outgoing transfer, then we can
use the report to create a MTO link to the specific outgoing moves. To
support this assignment flow, the report also allows printing of labels
to place on the product so stock workers know which transfer/MO the
product has been assigned to.

Expected use case is when a product is purchased to fulfil a sale.
Demo data has been added so reception report can be immediately
seen/used for this flow.

Implementation Notes:
- Report has been made flexible to work with batch transfers.
- Only done moves can be assigned to moves that already have quants
  reserved (prevents undesired behavior + this makes sense logically)
- Confirmed (+ Done and everything inbetween) moves can be assigned to
  any confirmed moves that are not already assigned.
- Report does not affect quant reservation/unreservation at all. It
  works only with linking moves (i.e. move_orig_id/move_dest_id) so
  move/transfer linkage traceability is stored within db (i.e. this
  isn't possible with quants)

Limitations: To keep code simple for now, this assignment flow will
  break in certain cases:
1. Done amount of an assigned move is less than the Demand amount
   (linked move will not autoreserve correctly when assigned move is
   validated, same issue already occurs in multi-step transfer).
2. If a linked move is unreserved after its assigned move is
   validated, then another move can reserve its quants and its
   assignment link will not be accurate.
3. Already reserved SNs + assign move, may lead to mismatching SNs
   between report and what's actually reserved.
4. Changing a linked move's Demand amount after a move is assigned to
   it.
5. Potential moves to assign to are only checked for being in same
   warehouse, not in a matching source location to destination location.
   User is expected to make this match on their own.

Task: 2500844
ENT PR: odoo/enterprise#18268
Upgrade PR: odoo/upgrade#2731

closes odoo/odoo#70669

Signed-off-by: Arnold Moyaux <amoyaux@users.noreply.github.com>
2021-08-17 11:42:23 +00:00
Rémy Voet (ryv) 7b7f65d504 [IMP] mrp: improve bom filter line by variant feature
On BoM, a component line can be filter out depending
of the product variant to manufacture
(with "Apply on Variant" field).

Extend this feature to operation and byproduct line.

task-2614126

closes odoo/odoo#74973

Signed-off-by: William Henrotin <Whenrow@users.noreply.github.com>
2021-08-16 07:20:03 +00:00
Touati Djamel (otd) 5e998efe5e [FIX] mrp: fix BOM structure & cost
Steps to reproduce the bug:
- Install manufacturing app
- Create a product “A”
- Create a Bill of Materials for product A > add any product > save
- Create another Product “B” > Create a BOM and add the product “A” in quantity “0” > save
- Click on “BOM Structure & Cost” for product “B” > open the sublevel BOM dropdown of the product “A”

Problem:
An error is triggered because the quantity of the product is "None"

opw-2585033

closes odoo/odoo#73323

X-original-commit: 06c172746f2d2dc8235c6e607342506bf9ef1551
Signed-off-by: Anh Thao PHAM <kitan191@users.noreply.github.com>
Signed-off-by: Djamel Touati <DjamelTouati@users.noreply.github.com>
2021-07-06 15:08:26 +00:00
William Henrotin dfb8c1b9e7 [FIX] mrp: print bom structure per variants
Commit 044c5c2c81 removed the context key
`variant` of the bom structure report. This implies to always print
every variant in case a BoM has no product_id.
This commit fix this issue to print only the variant selected in the
report. It also adds a new button to print the report with all variants
in case for some customers this behavior was "not a bug but a feature".

Task : 2504524

closes odoo/odoo#70444

X-original-commit: 8da349e785b5b461ea19874df9686f8cd26af8ad
Signed-off-by: William Henrotin <Whenrow@users.noreply.github.com>
2021-05-06 07:57:05 +00:00
Swapnesh Shah e710db21fd [FIX] mrp: correct report name
Before this commit,
It was always displaying `BoM Structure & Cost` for BoM Structure and
BoM Structure & Cost report.

With this commit, we are displaying correct report name based on report type.

closes odoo/odoo#69595

X-original-commit: e47f7db5ead8719d76f5fe1afd451f0ce113864b
Signed-off-by: Arnold Moyaux <amoyaux@users.noreply.github.com>
2021-04-21 10:08:27 +00:00
Goffin Simon ca3dfec135 [FIX] mrp: Print BOM / BOM structure & cost
Steps to reproduce the bug:

- Install manufacturing app
- Create a product A
- Create a Bill of Materials for product A
- Archive Product A (Only the final product not any of the components)
- Print BOM or Print BOM Structure & Cost

Bug:

A traceback was raised

opw:2447514

closes odoo/odoo#68116

X-original-commit: 81ee677bd52db388e29c26e255ccab27a286cf94
Related: odoo/enterprise#17186
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
2021-03-18 17:17:01 +00:00
Tiffany Chang (tic) 0d61d3fccb [IMP] mrp, stock: update reservation logic
This commit adds 2 small feature additions to reservation logic:

1. Add another # days parameter for reserve "before scheduled date"
   option for priority moves (i.e. so they can be marked for reservation
   earlier)
2. Add Reserve button in the forecast report

It also cleans up some auto-reserving logic:
- 'at confirm' now has a reservation_date = day of confirmation:
  - removes need to check `reservation_method` when doing automated
    _action_assign (i.e. in scheduler + completed incoming move).
  - allows ordering by reservation_date during automated _action_assign
    for more consistent and logical reservations.

Task: 2418907
Upgrade PR: odoo/upgrade#2143
2021-03-29 06:54:30 +00:00
Tiffany Chang (tic) 9effef7087 [FIX] mrp: use bom quantity in bom report
This commit makes it so when the bom structure report (Structure & Cost
smartbutton) is opened the product quantity defaults to the BoM's
`product_qty` amount rather than 1.

Steps to reproduce:
- Create/open a BoM
- Set `product_qty` to any value greater than 1
- Click on "Structure & Cost" button.

Expected result: product quantities scaled to the `product_qty`
Actual result: product quantities scaled to Quantity = 1

closes odoo/odoo#65747

Task: 2429885
X-original-commit: 30c05ad99bcf5884e071ebfa41adc6b44f23ba1e
Signed-off-by: Arnold Moyaux <amoyaux@users.noreply.github.com>
2021-02-08 16:33:36 +00:00
Christophe Monniez 2949138a7d [IMP] various: use the barcode qweb widget whenever possible
When using the route `/report/barcode/...` in a report, wkhtmltopdf
makes htpps requests on the server to retrieve the barcode image.
If a lot of barcodes have to be printed, this can overload the server
with too much requests and makes wkhtml crashes.

With this commit, the qweb barcode widget is used to include the barcode
as an img tag with inline barcode image as base64 data.

closes odoo/odoo#64211

Related: odoo/enterprise#15619
Signed-off-by: Christophe Monniez (moc) <moc@odoo.com>
2021-01-12 12:50:23 +00:00
Thibault Delavallée 03c4eae63b [MOV][IMP] mrp, repair: reorganize qweb / jinja templates used for mailing
PURPOSE

Clean organization of templates in odoo apps: mail.template records in data,
qweb templates (views) used directly in code, notably using post with view.
Purpose is to ease future improvements in posting based on templates.

SPECIFICATIONS

  * move those templates in their own file to ease their discovering and
    maintenance;
  * put them into data (as those are not views even if it contains qweb)
  * guidelines are now :

    -> Qweb templates should be in data/mail_templates.xml;
    -> mail.template records should be in data/mail_template_data.xml;

  * put their declaration in no update when not done if template has no
    technical code or complex dependency on underlying code;
  * move found mail data (mail.message.subtype or mail.activity.type) records
    in a mail_data file that should contain only "core" records linked to mail;

LINKS

Task ID-2375767
COM PR odoo/odoo#61814
ENT PR odoo/enterprise#14775
UPG PR odoo/upgrade#1936
2020-11-25 12:31:09 +00:00
Josean Soroa 0959a7e7ea [FIX] mrp: float formatting
Correctly format the `product_uom_qty` with the appropriate widget.

opw-2382517

closes odoo/odoo#62085

X-original-commit: 042298f8c949fba470eda6ad90f94c95ca291030
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2020-11-20 11:14:49 +00:00
JF Aubert c6847d9110 [IMP] stock: add priority star in forecasted report
see and set priority on sales orders and manufacturing orders in forecasted report
without having to go to the SO/MO

add the priority star icon in front of the SO/MO reference
changing priority should reload the page with reordered SO's/Mo
add a unreserve button next to 'reserved from stock' in the replenishment column
add total order and customer amount in used by column
remove time in delivery/receipt dates
change column headers (Quantity -> the UoM of the product, Expected Receipt -> Receipt, Expected Delivery -> Delivery)
change 'Draft SO' -> 'Quotations' and 'Draft PO' -> 'Requests for quotation' and add links
mobile view: display KPI's on new line
check decimals on quantities, must be 2

closes odoo/odoo#60578

Task: 2349142
Signed-off-by: Arnold Moyaux <amoyaux@users.noreply.github.com>
2020-11-09 16:44:18 +00:00
Swapnesh Shah 73be30d3a3 [FIX] mrp: hide Unit Cost on BoM Structure report
Before this commit, Label *Unit Cost* was displayed in the footer for *BoM Structure* report which is not displaying any cost Information.

With this commit we hide *Unit Cost* on  *BoM Structure* report.

closes odoo/odoo#59356

X-original-commit: 9ec465e7d3937450bad795cdb69eae52b540b994
Signed-off-by: Arnold Moyaux <amoyaux@users.noreply.github.com>
2020-10-07 09:22:10 +00:00
Rémy Voet (ryv) 9a9080363f [IMP] (sale_)stock,mrp: improve forcasted report.
- Add a minus before quanity if it describes a output move.
- Remove intermediate section "Pending Incoming Documents" and
"Pending Outgoing Documents". Change other label to be more descriptive.
- "Current Stock" in "Inventory On hand".
- Add line "Inventory On Hand - 0" If no other line
specific it explicitly.

task-2324039
2020-09-15 08:11:51 +00:00
Victor Feyens fdb23e282b [IMP] *: wrong any() usage
Replace wrong usages of any(list|recordset), by any(generator)
to speed up computations, avoiding list creations and/or looping twice on a recordset
for nothing.

any([generator]) => any(generator)
any(filtered) => any(generator)

closes odoo/odoo#55768

Related: odoo/enterprise#12360
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2020-08-14 09:56:10 +00:00
svs-odoo 832af92115 [IMP] mrp: extend replenishment report for mrp
Adds the Manufacturing Order as replenishment/consuming document for the
replenishment report.

task-2058495
2020-07-31 12:36:54 +00:00
Xavier Morel 6835aeb0de [REM] core, *: deprecate <act_window> and <report>
Convert deprecated tags through the codebase.
2020-07-28 13:03:13 +00:00
Tiffany Chang (tic) a60527bde7 [IMP] delivery, mrp, stock: group delivery slips by kit
This commit extends the delivery slip so that products added as a kit
component to a stock.picking are grouped together by kit (or non-kit)
when at least 1 kit exists. Kit grouping occurs for products from a kit
without a package assigned. Non-kit section appears only when no
packages are assigned.

Implementation notes:
- Sub-kits (i.e. kits within kits) of kits are purposely not included
- Duplicate product names with different BOMs will be merged into one
  since there is no straightforward way to distinguish them within
  current db structure
- There are some cases where this doesn't work as expected and may lead
  to components being grouped together under the same kit even if they
  are from different kits (e.g. kit1 has bolts and so does kit2 => on
  slip bolts will only show under kit1 section). Two cases where this
  happens is when kits are added before 'Operation Type' is specified
  and 'Operation Type = Manufacturing'

This completes subsection 1 of overall Improve delivery slip task.

Task: 2039720
2020-07-03 11:54:08 +00:00
Andrea Grazioso (agr-odoo) 4ca452aacf [FIX] mrp: fix BoM Structure & Cost Report print
Create some attributes with "create dynamically" set
Create a product template using these attributes (=> product variants
should not be created)
Set this product as manufactured, and create an associated BOM with some
components
Try to print the BOM

User will face a traceback due to the product_id being non existant

opw-2283649

closes odoo/odoo#53872

X-original-commit: 4d77ada68fb4d8113a5fbf95f20ccb49d0611fc5
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2020-06-30 12:51:08 +00:00
Simon Lejeune c660770ebd [REF] mrp: remove routing model
Set the operations directly on the Bill of Material.
Duplicate the demo data where a routing was shared.
Adapt the tests.

Remove the following feature:
    - set the same routing on parent and kit child bom
    - when planning, if the component of the kit have the same operation
      than a component of the parent bom, merge these operations

task-2241471
2020-06-15 16:59:40 +02:00
Martin Trigaux d9287caf94 [IMP] *: convert to private methods
render, render_template, load, activity_schedule_with_view,
get_website_pages should all be private:
It should not be possible to render an aribtrary template only with
its name or id

Still need to render some qweb views from js so the method
render_template is kept public.
This explains why the website editor still need read access on
ir.ui.view as we want to allow any snippet to be rendered.
2020-05-14 13:59:10 +02:00
Nicolas Martinelli bc129637bb [FIX] mrp: False barcode
- Create a MO for a product tracked by S/N
- Perform the MO
- Print the 'Finished Product Label (PDF)'

The barcode printed is `False`.

If the S/N is not set on the `move_line`, we should fall back on
`lot_id.name`.

opw-2228337

closes odoo/odoo#48949

X-original-commit: fb69b5a99becd92ee0ee7698709da05a0b33850f
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2020-04-03 09:41:23 +00:00
Mitali Patel 6f247d799a [IMP] stock, sale_stock, mrp, purchase_stock: transfer the custom variant information
Allow to propagate custom information to upper document. It could be
usefull in many buisness that do custom stuff for people
(t-shirt with user defined text, poster with own pictures...)

The customes values are pass throught procurements'values and are
display on MO or purchase order line.

Task: 1970476
2020-03-05 14:31:13 +00:00
Nicolas Martinelli d1a0601660 [FIX] mrp: display human readable lot
Display the readable value of lot name in the Production Order report.

opw-2178868

closes odoo/odoo#43990

X-original-commit: 7e82b77a80fe70da45676fd87a458ffe9948e48d
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2020-01-27 10:52:58 +00:00
jdoutreloux 52ed0be17e [IMP] uom : remove 'measure_type' field
This removes the measure_type field which has become unused and
causes issues when users try to add new uom categories.

Task-2043927

closes odoo/odoo#41056

Related: odoo/enterprise#6945
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2020-01-13 11:19:17 +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
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
Victor Feyens 9215e73fa2 [IMP] * : replace with_context(force_company=c) by with_company(c) 2019-11-18 12:25:05 +00:00
Nicolas Martinelli 46ef76555f [FIX] mrp: print barcodes
- Create a product A with a barcode, UOM as 'Unit(s)' with a BOM
- Create a MO for A with more than one unit, validate
- Print the 'Finished Product Label (PDF)'

A single label is printed for all units, although it is not logical: a
label should be printed for each unit, as already done for the Zebra
labels.

In case the product UOM is 'Unit(s)', we print a label per unit. To do
so, we use a template similar to `label_transfer_template_view_pdf`.

opw-2091663

closes odoo/odoo#39311

Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2019-10-24 09:34:11 +00:00
Dharmraj Jhala 30b1af7937 [IMP] * : enable static string edition using report editor
*:
	delivery
	hr_timesheet
	mrp
	sale
	sale_coupon
	stock

This commit makes the static strings / labels editable with studio
by wrapping them in appropriate tag (mostly span) whenever needed.

Task-Id 2030430

closes odoo/odoo#34685

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2019-10-17 09:39:01 +00:00
Simon Lejeune 96406dc2a9 [REF] mrp: multi company
Ensure proper domains are applied and enforced on relation fields thanks
to the `check_company` attributes.

Make sure unbuild have proper sequence for each companies.

The produce wizard and workorders company is the one of the production.
The BoM line company_id is the one of its bom_id.
Added some tests.

task-1985992
2019-09-03 15:05:03 +00:00
Kaushalya Mandaliya 03c2083890 [FIX] mrp: traceback while printing BOM structure report
From the commit: 36b976ccee
A traceback is generated while printing BOM structure
report, which is fixed in this commit.

task-2024247
closes: #34899

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-07-30 10:33:16 +00:00
Arnold Moyaux dc35b88411 [DEL] stock, mrp: remove report forecast
It will be replaced by an easier report that will
dispaly the cumulative forecast and the planned in/out
moves.
2019-07-16 08:26:54 +00:00
Christophe Simonis 5548029fb7 [MERGE] forward port branch saas-12.4 up to 5e81b18e24 2019-06-27 20:51:59 +02:00
Christophe Simonis 5e81b18e24 [MERGE] forward port branch saas-12.3 up to 0247d2f35f 2019-06-27 20:45:52 +02:00
Christophe Simonis 465909f0fd [MERGE] forward port branch 12.0 up to cd21c016b0 2019-06-27 18:01:07 +02:00
Jorge Pinna Puissant 044c5c2c81 [FIX] mrp: BoM structure report with variants
1. Setup a few variants for a product;
2. Create a BoM for each of the variants with different
components/quantities, make sure to specify the product variant field;
3. Go to any of the variants and click Print BoM Structure.

Before this commit, it will print the BoM structure for all variants and
not only the one selected. Also, it will print in all the variants the
same BoM structure. If multiples BoM were selected to print, each
variant of the product was printed with each of the BoM structure
selected.

Now, if you select one BoM, only this is printed. If multiples BoM are
printed, each product, and product variant are correctly related to
their respective BoM structure.

opw-2007939

closes odoo/odoo#34353

Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
2019-06-25 08:42:27 +00:00
Ankita Raval 5a34d64a44 [FIX] mrp: bom structure report
The "BoM Structure report" should not include the cost of the products
as it is often shared with third parties. We now only display the cost
on the "BoM Structure and Cost report" and remove the "BoM Cost report"
as it is redundant with the former.

Task Id: 1969709

closes odoo/odoo#33323

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-06-11 12:39:15 +00:00
Yannick Tivisse f5dfe4727c [IMP] api.py: Rename company_id/company_ids into company/companies
The goal is to be coherent with the user property.

Actually, company_id and company_ids on the environment are no fields.

Calling env.company_id returns a browse record, not an id.
2019-05-29 08:09:15 +00:00
Arnold Moyaux 2843dcfaa0 [FIX] mrp: print selected quantity
When using the print unfolded button, it will print only 1 product
and not the selected quantity on the report.

Task: 1939278

closes odoo/odoo#32340

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-06-11 12:44:51 +00:00