fix
This commit is contained in:
parent
c6717c3ae6
commit
f2afea6110
|
|
@ -395,8 +395,9 @@ class Test(Widget):
|
|||
else:
|
||||
step.spec["barcode_name"] = barcode_names[(n_pieces_adapted - 1) % len(barcode_names)]
|
||||
n_pieces_adapted -= 1
|
||||
step.spec["n_pieces"] = str(n_pieces_adapted)
|
||||
new_barcode_step = copy.deepcopy(step) # create a deep copy of the step
|
||||
new_barcode_step = copy.deepcopy(step)
|
||||
new_barcode_step.spec["n_pieces"] = str(n_pieces_adapted)
|
||||
n_pieces_adapted -= 1
|
||||
steps.insert(i + 1, new_barcode_step)
|
||||
if i in skip:
|
||||
continue
|
||||
|
|
|
|||
|
|
@ -33,9 +33,7 @@ class Test_Barcodes(Test_Test):
|
|||
self.start_counter += 1
|
||||
npieces = self.step.spec.get("n_pieces")
|
||||
npieces = int(npieces) if npieces is not None else 0
|
||||
if self.start_counter > npieces + 1: # If start_counter exceeds npieces + 1
|
||||
self.start_counter = 1
|
||||
display_str = "{}/{}".format(self.start_counter, npieces + 1)
|
||||
display_str = "PEZZI RIMANENTI {}".format(npieces)
|
||||
self.counter_l.setText(display_str)
|
||||
if show is False:
|
||||
return show
|
||||
|
|
@ -77,7 +75,6 @@ class Test_Barcodes(Test_Test):
|
|||
barcode_ok = False
|
||||
self.current_step_barcode_name = self.step.spec.get('barcode_name') # get current step's barcode name
|
||||
barcode_check = self.barcodes_spec.get(self.current_step_barcode_name)
|
||||
#self.expected_barcode.setText(self.step.spec.get(self.current_step_barcode_name))
|
||||
|
||||
# If the current step's barcode type exists in barcodes_spec and it's valid, store it
|
||||
if barcode_check and barcode_check(data):
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user