Commit ef4c477c authored by Mikaël Salson's avatar Mikaël Salson Committed by Vidjil Team
Browse files

models/sample_set_list.py: Use the sample type ID instead of the sample set

Follows 8db87b52 to fix #4232.
In sample_set_list_ we're dealing with sample sets, sets, and runs that may have different IDs
than sample sets
parent 0ea6a11f
Pipeline #135125 passed with stages
in 6 minutes and 49 seconds
......@@ -43,17 +43,17 @@ class SampleSetList():
key = row[type]
else:
key = row
self.elements[key.sample_set_id] = key
self.elements[key.sample_set_id].file_count = 0
self.elements[key.sample_set_id].size = 0
self.elements[key.sample_set_id].conf_list = []
self.elements[key.sample_set_id].conf_id_list = [-1]
self.elements[key.sample_set_id].most_used_conf = ""
self.elements[key.sample_set_id].groups = ""
self.elements[key.sample_set_id].group_list = []
self.elements[key.id] = key
self.elements[key.id].file_count = 0
self.elements[key.id].size = 0
self.elements[key.id].conf_list = []
self.elements[key.id].conf_id_list = [-1]
self.elements[key.id].most_used_conf = ""
self.elements[key.id].groups = ""
self.elements[key.id].group_list = []
#self.elements[key.id].has_permission = auth.can_modify_sample_set(key.sample_set_id)
self.elements[key.sample_set_id].has_permission = auth.can_modify_subset(type, key.id)
self.elements[key.sample_set_id].anon_allowed = auth.can_view_info(type, key.id)
self.elements[key.id].has_permission = auth.can_modify_subset(type, key.id)
self.elements[key.id].anon_allowed = auth.can_view_info(type, key.id)
self.element_ids = self.elements.keys()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment