completed entry used to identify the whereabouts of the entities through their routes

parent 6f210ee3
......@@ -31,7 +31,6 @@ class ReadJSWorkPlan(plugin.InputPreparationPlugin):
"""
self.data=data
WPdata = data["input"].get("workplan_spreadsheet",[])
orders = data["input"]["BOM"].get("orders",{})
if WPdata:
WPdata.pop(0) # pop the column names
for line in WPdata:
......@@ -55,11 +54,11 @@ class ReadJSWorkPlan(plugin.InputPreparationPlugin):
order["componentsList"] = components
# update the route of the component
route = part.get("route", [])
task_id = line[-1]
task_id = line[-2]
sequence = line[4]
processingTime = line[-4]
processingTime = line[-5]
operator = line[5]
partsneeded = line[-3]
partsneeded = line[-4]
# if there are requested parts then split them
if partsneeded:
partsneeded = partsneeded.replace(" ","").split(',')
......@@ -67,6 +66,7 @@ class ReadJSWorkPlan(plugin.InputPreparationPlugin):
partsneeded = [""]
technology = line[3]
quantity = line[6]
completed = line[-1]
# append the current step to the route of the part
route.append({
"task_id": task_id,
......@@ -75,9 +75,8 @@ class ReadJSWorkPlan(plugin.InputPreparationPlugin):
"operator": operator,
"partsneeded": partsneeded,
"technology": technology,
"quantity": quantity
"quantity": quantity,
"completed": completed
})
part["route"] = route
return data
\ No newline at end of file
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