Skip to content
Health
85/100
good
  • Security25/25
    No findings
  • Activity20/25
    Last human commit 8 months ago
  • Required by15/25
    1 module depends on it
  • Maturity25/25
    In 11 Odoo series since 9.0

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

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

Description

This module extends Odoo functionality, allowing user to generate barcode depending on a given barcode rule for any Model.

For example, if the barcode pattern is "20.....{NNNDD}":

  • the EAN13 code will begin with '20',
  • followed by 5 digits (named Barcode Base in this module),
  • followed by 5 others digits to define the variable price with 2 decimals,
  • the last digit (the 13rd digit) is the control digit (i.e. the checksum).

With this module, it is possible to:

  • Affect a pattern (barcode.rule) to a model

  • Define a Barcode base:

    • manually, if the base of the barcode must be set by a user (typically an internal code defined in your company).
    • automatically by a sequence, if you want to let Odoo increment a sequence (typical case of a customer number incrementation).
  • Generate a barcode, based on the defined pattern and the barcode base

Dependencies

Odoo dependencies
odoo/odoo:
- web
Python dependencies
python-barcode
System dependencies
None
Required by
barcodes_generator_product

Code analysis

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

Views touched 2

XML IDNameModelTypeStatus
view_barcode_nomenclature_form barcode.nomenclature form Inherits barcodes.view_barcode_nomenclature_form
view_barcode_rule_form barcode.rule form Inherits barcodes.view_barcode_rule_form

HTTP endpoints 0

No HTTP endpoints found for this module.

Models touched 2

New fields (3)
  • barcode_base Integer
    copy=False help='This value is used to generate barcode according to the setting of the barcode rule.'
  • barcode_rule_id Many2one → barcode.rule
    comodel_name='barcode.rule' help='Select a rule to generate a barcode' string='Barcode Rule'
  • generate_type Selection
    related='barcode_rule_id.generate_type'
Public methods (4)
  • create(self, vals_list)
    @api.model_create_multi
    It creates a new barcode if automation is active.
  • generate_barcode(self)
  • generate_base(self)
  • write(self, vals)
    Generate new barcodes if a barcode rule with automation is applied.

New fields (5)
  • generate_automate Boolean
    help='Check this to automatically generate a base and a barcode if this rule is selected.' string='Automatic Generation'
  • generate_model Selection
    help="If 'Generate Type' is set, mention the model related to this rule." selection=[]
  • generate_type Selection
    default='no' help="Allow to generate barcode, including a number (a base) in the final barcode.\n\n - 'Base Set Manually' : User should set manually the value of the barcode base\n - 'Base managed by Sequence': System will generate the base via a sequence" required=True selection=_GENERATE_TYPE
  • padding Integer
    compute='_compute_padding' readonly=True store=True
  • sequence_id Many2one → ir.sequence
    comodel_name='ir.sequence' string='Generation Sequence'
Public methods (4)
  • create(self, vals_list)
    @api.model_create_multi
  • generate_sequence_if_required(self)
  • onchange_generate_type(self)
    @api.onchange('generate_type')
  • write(self, vals)

Loading…

Loading…

Loading…

Loading…

Loading…

Loading…

Loading…

Loading…

Loading…

Loading…

Loading…