This commit is contained in:
@@ -134,7 +134,6 @@ def update_puck_table():
|
||||
#Sample mount/unmount
|
||||
|
||||
def update_samples_info_sample_mount(puck_address, sample_position, sample_detected, sample_id):
|
||||
print ""
|
||||
try:
|
||||
if (samples_info is not None) and (puck_address is not None):
|
||||
for si in samples_info:
|
||||
@@ -169,6 +168,24 @@ def update_samples_info_sample_unmount(puck_address, sample_position):
|
||||
except:
|
||||
pass
|
||||
|
||||
def update_samples_info_sample_scan(puck_address, sample_position, sample_detected, sample_id):
|
||||
try:
|
||||
if (samples_info is not None) and (puck_address is not None):
|
||||
for si in samples_info:
|
||||
if str(si["puckAddress"]) == str(puck_address) and str(si["samplePosition"]) == str(sample_position):
|
||||
if sample_detected:
|
||||
if si["sampleStatus"] == "Unknown":
|
||||
si["sampleStatus"] = "Present"
|
||||
else:
|
||||
if si["sampleStatus"] == "Present":
|
||||
si["sampleStatus"] = "Unknown"
|
||||
if sample_id is not None:
|
||||
si["sampleBarcode"] = sample_id
|
||||
save_samples_info()
|
||||
return
|
||||
except:
|
||||
pass
|
||||
|
||||
|
||||
|
||||
test_sample_data = [ \
|
||||
|
||||
Reference in New Issue
Block a user