子文库 不能重复
parent
c0f8997197
commit
f473efa71b
21
tools/t7.py
21
tools/t7.py
|
|
@ -52,6 +52,9 @@ class AutoLayout:
|
||||||
self.rule = self.read_rule()
|
self.rule = self.read_rule()
|
||||||
self.rule_exclusive_customer = self.read_rule_exclusive_customer()
|
self.rule_exclusive_customer = self.read_rule_exclusive_customer()
|
||||||
|
|
||||||
|
# 子文库名称
|
||||||
|
self.chip_sublib = defaultdict(set)
|
||||||
|
|
||||||
# 不平衡文库
|
# 不平衡文库
|
||||||
self.chip_speciallib_size = dict()
|
self.chip_speciallib_size = dict()
|
||||||
|
|
||||||
|
|
@ -274,6 +277,9 @@ class AutoLayout:
|
||||||
self.chip_barcode_recode[chipname].update({'N' * 8 + item['i7'] for item in library_data['data']})
|
self.chip_barcode_recode[chipname].update({'N' * 8 + item['i7'] for item in library_data['data']})
|
||||||
# self.chip_barcode_recode[chipname].update({item['i5'] + 'N' * 8 for item in library_data['data']})
|
# self.chip_barcode_recode[chipname].update({item['i5'] + 'N' * 8 for item in library_data['data']})
|
||||||
|
|
||||||
|
# 子文库
|
||||||
|
self.chip_sublib[chipname].update({item['sublibrary'] for item in library_data['data']})
|
||||||
|
|
||||||
self.chip_customer[chipname].add(library_data['customer'])
|
self.chip_customer[chipname].add(library_data['customer'])
|
||||||
self.chip_classification[chipname].add(library_data['classification'])
|
self.chip_classification[chipname].add(library_data['classification'])
|
||||||
|
|
||||||
|
|
@ -336,7 +342,6 @@ class AutoLayout:
|
||||||
|
|
||||||
# barcode有重复
|
# barcode有重复
|
||||||
notrepeatbarcode = True
|
notrepeatbarcode = True
|
||||||
|
|
||||||
if self.chip_barcode_recode[chipname].intersection({item['barcode'] for item in library_data['data']}) or \
|
if self.chip_barcode_recode[chipname].intersection({item['barcode'] for item in library_data['data']}) or \
|
||||||
self.chip_barcode_recode[chipname].intersection(
|
self.chip_barcode_recode[chipname].intersection(
|
||||||
{'N' * 8 + item['i7'] for item in library_data['data']}) or \
|
{'N' * 8 + item['i7'] for item in library_data['data']}) or \
|
||||||
|
|
@ -408,7 +413,19 @@ class AutoLayout:
|
||||||
if is_not_balance_list:
|
if is_not_balance_list:
|
||||||
base_balance = False
|
base_balance = False
|
||||||
|
|
||||||
if sizelimit and notrepeatbarcode and exclusive_classific and exclusive_customer and splibrary and base_balance and spmethylibrary and use_huada:
|
# 子文库名不能重复
|
||||||
|
notrepeatsublib = True
|
||||||
|
if self.chip_sublib[chipname].intersection({item['sublibrary'] for item in library_data['data']}):
|
||||||
|
notrepeatsublib = False
|
||||||
|
|
||||||
|
if sizelimit and notrepeatbarcode and \
|
||||||
|
exclusive_classific and \
|
||||||
|
exclusive_customer and \
|
||||||
|
splibrary and \
|
||||||
|
base_balance and \
|
||||||
|
spmethylibrary and \
|
||||||
|
use_huada and \
|
||||||
|
notrepeatsublib:
|
||||||
return True
|
return True
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue