Skip to content
Health
80/100
good
  • Security25/25
    No findings
  • Activity25/25
    Last human commit 6 months ago
  • Required by5/25
    0 modules depend on it
  • Maturity25/25
    In 10 Odoo series since 10.0

Heuristic over the facts below, not an audit · How it's computed

Security findings
Grave / minor (static analysis)
Required by
0
Modules depending on it
External deps
0 pip · 0 bin
Python packages / system binaries
License
AGPL-3
No conflicts with its dependencies
Folder size
0.21 MB
Module directory on disk
Code analysis 0 migration notes 5 models 7 views 0 HTTP endpoints

Description

This module automatically generate Product Reference (default_code) according to attributes data with a configurable behavior.

It defines a reference mask on the product templates so the variants references are automatically set. For example:

  • Product template: Jacket
  • Attributes:
    • Color: White, Black
    • Size: M, L
  • Reference mask: JKT01-[Color]-[Size]
  • Reference on variants:
    • JKT01-Wh-M Jacket White M
    • JKT01-Bl-M Jacket Black M
    • JKT01-Wh-L Jacket White L
    • JKT01-Bl-L Jacket Black L

Dependencies

Odoo dependencies
odoo/odoo:
- web
- bus
- uom
Python dependencies
None
System dependencies
None
Required by
None

Code analysis

Extracted from the source by best-effort static analysis (no code is executed); details may be incomplete.

Views touched 7

XML IDNameModelTypeStatus
attribute_tree_view product.attribute tree Inherits product.attribute_tree_view
product_normal_form_view product.product form Inherits product.product_normal_form_view
product_template_only_form_view product.template form Inherits product.product_template_only_form_view
product_variant_easy_edit_view product.product Inherits product.product_variant_easy_edit_view
view_general_configuration res.config.settings form Inherits base_setup.res_config_settings_view_form
view_product_attribute_form product.attribute form Inherits product.product_attribute_view_form
view_product_attribute_search product.attribute search New

HTTP endpoints 0

No HTTP endpoints found for this module.

Models touched 5

New fields (1)
  • code Char
    string='Attribute Code'
Public methods (0)

No public methods.

New fields (1)
  • code Char
    compute='_compute_code' readonly=False store=True string='Attribute Value Code'
Public methods (0)

No public methods.

New fields (2)
  • default_code Char
    compute='_compute_default_code' inverse='_inverse_default_code' readonly=False store=True
  • manual_code Boolean
    default=False string='Manual Reference'
Public methods (0)

No public methods.

New fields (3)
  • code_prefix Char
    help='Add prefix to product variant reference (default code)' string='Reference Prefix'
  • reference_mask Char
    compute='_compute_reference_mask' copy=False help='Reference mask for building internal references of a variant generated from this template.\nExample:\nA product named ABC with 2 attributes: Size and Color:\nProduct: ABC\nColor: Red(r), Yellow(y), Black(b) #Red, Yellow, Black are the attribute value, `r`, `y`, `b` are the corresponding code\nSize: L (l), XL(x)\nWhen setting Variant reference mask to `[Color]-[Size]`, the default code on the variants will be something like `r-l` `b-l` `r-x` ...\nIf you like, You can even have the attribute name appear more than once in the mask. Such as,`fancyA/[Size]~[Color]~[Size]`\n When saved, the default code on variants will be something like \n `fancyA/l~r~l` (for variant with Color "Red" and Size "L") `fancyA/x~y~x` (for variant with Color "Yellow" and Size "XL")\nNote: make sure characters "[,]" do not appear in your attribute name' inverse='_inverse_reference_mask' store=True string='Variant reference mask'
  • variant_default_code_error Text
    compute='_compute_variant_default_code_error'
Public methods (2)
  • create(self, vals_list)
    @api.model_create_multi
  • is_automask(self)

New fields (2)
  • group_product_default_code_manual_mask Boolean
    default=False help='Set behaviour of codes. Default: Automask (depends on variant use: see Sales/Purchases configuration)' implied_group='product_variant_default_code.group_product_default_code_manual_mask' string='Product Default Code Manual Mask'
  • prefix_as_default_code Boolean
    config_parameter='product_variant_default_code.prefix_as_default_code' default=False string='Reference Prefix as default Reference'
Public methods (0)

No public methods.

Loading…

Loading…

Loading…

Loading…

Loading…

Loading…

Loading…

Loading…

Loading…