Skip to content

Commit

Permalink
Merge PR #652 into 16.0
Browse files Browse the repository at this point in the history
Signed-off-by legalsylvain
  • Loading branch information
OCA-git-bot committed Oct 15, 2024
2 parents 23db544 + d805588 commit 4d8f085
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions barcodes_generator_abstract/models/barcode_generate_mixin.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@ def create(self, vals_list):
rule = rec.barcode_rule_id
if rule and rule.generate_automate and rule.generate_type == "sequence":
rec.generate_base()
rec.generate_barcode()
if not rec.barcode:
rec.generate_barcode()
return records

def write(self, vals):
Expand All @@ -50,7 +51,8 @@ def write(self, vals):
if rule.generate_automate and rule.generate_type == "sequence":
for rec in self:
rec.generate_base()
rec.generate_barcode()
if not rec.barcode:
rec.generate_barcode()
return res

# View Section
Expand Down

0 comments on commit 4d8f085

Please sign in to comment.