From 9d4ec4d054858368d21a1efc9f58f1fbd080baaf Mon Sep 17 00:00:00 2001 From: stephanchrst Date: Mon, 2 Jan 2023 11:28:12 +0700 Subject: change logic for po status and add table for product spec trusco --- indoteknik_custom/models/product_spec.py | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 indoteknik_custom/models/product_spec.py (limited to 'indoteknik_custom/models/product_spec.py') diff --git a/indoteknik_custom/models/product_spec.py b/indoteknik_custom/models/product_spec.py new file mode 100644 index 00000000..161438b6 --- /dev/null +++ b/indoteknik_custom/models/product_spec.py @@ -0,0 +1,19 @@ +from odoo import fields, models, api +from datetime import datetime, timedelta +import logging + +_logger = logging.getLogger(__name__) + + +class ProductTemplateSpec(models.Model): + _name = 'product.template.spec' + product_tmpl_id = fields.Many2one('product.template', string='Product Template') + attribute = fields.Char(string='Attribute', help='Attribute of Product') + value = fields.Char(string='Values', help='Value of Attribute') + + +class ProductVariantSpec(models.Model): + _name = 'product.variant.spec' + product_variant_id = fields.Many2one('product.product', string='Product Variant') + attribute = fields.Char(string='Attribute', help='Attribute of Product') + value = fields.Char(string='Values', help='Value of Attribute') -- cgit v1.2.3