Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ADD] purchase_packaging_uom: Added module. #16

Merged
merged 1 commit into from
Feb 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions purchase_packaging_uom/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# purchase_packaging_uom

This is the README for purchase_packaging_uom.
1 change: 1 addition & 0 deletions purchase_packaging_uom/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import models
16 changes: 16 additions & 0 deletions purchase_packaging_uom/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Copyright 2020 Camptocamp SA
# Copyright 2020 ForgeFlow, S.L.
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl)
{
"name": "Purchase Packaging UoM",
"summary": "Adds purchase uom to product packaging",
"version": "16.0.1.0.0",
"category": "Purchase",
"website": "https://github.com/OCA/purchase-workflow",
"author": "Ametras, Odoo Community Association (OCA)",
"license": "AGPL-3",
"application": False,
"installable": True,
"depends": ["product"],
"data": ["views/product_packaging.xml"],
}
1 change: 1 addition & 0 deletions purchase_packaging_uom/models/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import product_packaging
13 changes: 13 additions & 0 deletions purchase_packaging_uom/models/product_packaging.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Copyright 2021 Ametras
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl)
from odoo import fields, models


class ProductPackaging(models.Model):
_inherit = "product.packaging"

product_uom_po_id = fields.Many2one(
"uom.uom",
related="product_id.uom_po_id",
readonly=True,
)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Loading