|
@ -242,18 +242,20 @@ public class BPSLTask extends AbstractTask { |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@Override |
|
|
@Override |
|
|
protected void feedbackTaskState(JSONObject param,SchBaseTask schBaseTask, BaseResponse result) { |
|
|
protected synchronized void feedbackTaskState(JSONObject param,SchBaseTask schBaseTask, BaseResponse result) { |
|
|
//重算最优点
|
|
|
//重算最优点
|
|
|
JSONObject jsonObject = JSONObject.parseObject(schBaseTask.getExt_group_data()); |
|
|
JSONObject jsonObject = JSONObject.parseObject(schBaseTask.getExt_group_data()); |
|
|
SchBasePoint point = this.findNextPoint(jsonObject,schBaseTask); |
|
|
SchBasePoint point = this.findNextPoint(jsonObject,schBaseTask); |
|
|
//正极板现在不堆叠
|
|
|
//正极板两种情况,任务没分配就是点位高度,如果已分配则已减掉,所以重复请求需要加回去,多次变动太恶心了待优化
|
|
|
if( "1".equals(jsonObject.getString("material_type"))) { |
|
|
if( "1".equals(jsonObject.getString("material_type"))&&ObjectUtil.isEmpty(point.getIng_task_code())) { |
|
|
schBaseTask.setPoint_code1(point.getPoint_code()+"0"+(point.getVehicle_qty())); |
|
|
schBaseTask.setPoint_code1(point.getPoint_code()+"0"+(point.getVehicle_qty())); |
|
|
|
|
|
}else if ("1".equals(jsonObject.getString("material_type"))&&ObjectUtil.isNotEmpty(point.getIng_task_code())){ |
|
|
|
|
|
schBaseTask.setPoint_code1(point.getPoint_code()+"0"+(point.getVehicle_qty()+1)); |
|
|
}else{ |
|
|
}else{ |
|
|
schBaseTask.setPoint_code1(point.getPoint_code().replace("HCQ","QHQ")); |
|
|
schBaseTask.setPoint_code1(point.getPoint_code().replace("HCQ","QHQ")); |
|
|
} |
|
|
} |
|
|
//如果是正极板对接位则直接减库存
|
|
|
//如果是正极板对接位则直接减库存
|
|
|
if ((point.getPoint_code().startsWith("ZJBDJW"))&&!schBaseTask.getTask_code().equals(point.getIng_task_code())) { |
|
|
if ((point.getPoint_code().startsWith("ZJBDJW"))&&ObjectUtil.isEmpty(point.getIng_task_code())) { |
|
|
point.setVehicle_qty(point.getVehicle_qty() - 1); |
|
|
point.setVehicle_qty(point.getVehicle_qty() - 1); |
|
|
} |
|
|
} |
|
|
//重算点位时把点位占用
|
|
|
//重算点位时把点位占用
|
|
|