Commit 4f28691d authored by 虢奥's avatar 虢奥

远端派车逻辑补充

parent 9bc1e4f3
...@@ -115,9 +115,12 @@ def area_choose(excavators_id, closer_area_id, further_area_id, further_lane_set ...@@ -115,9 +115,12 @@ def area_choose(excavators_id, closer_area_id, further_area_id, further_lane_set
load_value = json.load(f) load_value = json.load(f)
gothrough_config_area = load_value["gothrough"] gothrough_config_area = load_value["gothrough"]
dispatch_factor = gothrough_config_area["closer_area_name"] dispatch_factor = gothrough_config_area["closer_area_name"]
# 远端挖机空闲
if further_excavator_state == 0 and goto_further_area_num == 0:
logger.info("远端挖机空闲, 调度车辆前往远端装载区")
target_excavator = DispatchInfo.load_excavator_dict[further_area_id]
# 近端挖机空闲 # 近端挖机空闲
if closer_excavator_state == 0: elif closer_excavator_state == 0:
logger.info("近端挖机空闲, 调度车辆前往近端装载区") logger.info("近端挖机空闲, 调度车辆前往近端装载区")
target_excavator = DispatchInfo.load_excavator_dict[closer_area_id] target_excavator = DispatchInfo.load_excavator_dict[closer_area_id]
# truck_dispatch_to_redis(request_truck_id, group_id, DispatchInfo.load_excavator_dict[closer_area_id]) # truck_dispatch_to_redis(request_truck_id, group_id, DispatchInfo.load_excavator_dict[closer_area_id])
......
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