|
@@ -144,7 +144,7 @@ public class ApsServiceImpl implements ApsService {
|
|
|
logger.info("解锁重排订单:"+repcIds);
|
|
|
}
|
|
|
// 冷轧连续性问题重排
|
|
|
- if(StrUtil.isNotBlank(apsType) && "lzcp".equals(apsType)){
|
|
|
+ if(StrUtil.isNotBlank(apsType) && "mix".equals(apsType)){
|
|
|
lzlxOrderSchedule(apsBlankOrders,currentUser,apsType);
|
|
|
}else{
|
|
|
apsOrderScheduleNew(apsBlankOrders,currentUser,apsType);
|
|
@@ -517,12 +517,12 @@ public class ApsServiceImpl implements ApsService {
|
|
|
if(prowidth1.compareTo(prowidth2) == 0){
|
|
|
// 合金
|
|
|
if(alloy1.compareTo(alloy2) == 0){
|
|
|
- // 产品类型
|
|
|
- if(producttype1 == null || producttype2 == null || producttype1.compareTo(producttype2) == 0){
|
|
|
- // 厚度
|
|
|
- if(thickness1.compareTo(thickness2) == 0){
|
|
|
- // 合金状态
|
|
|
- if(alloystatus1 == null || alloystatus2 == null || alloystatus1.compareTo(alloystatus2) == 0){
|
|
|
+ // 合金状态
|
|
|
+ if(alloystatus1 == null || alloystatus2 == null || alloystatus1.compareTo(alloystatus2) == 0){
|
|
|
+ // 产品类型
|
|
|
+ if(producttype1 == null || producttype2 == null || producttype1.compareTo(producttype2) == 0){
|
|
|
+ // 厚度
|
|
|
+ if(thickness1.compareTo(thickness2) == 0){
|
|
|
// 重量
|
|
|
if(singlerollweight1.compareTo(singlerollweight2) == 0){
|
|
|
// 按照订单排序
|
|
@@ -538,17 +538,17 @@ public class ApsServiceImpl implements ApsService {
|
|
|
a = 1;
|
|
|
}
|
|
|
}else{
|
|
|
- a = alloystatus1.compareTo(alloystatus2);
|
|
|
+ if(thickness1.compareTo(thickness2) > 0){
|
|
|
+ a = -1;
|
|
|
+ }else{
|
|
|
+ a = 1;
|
|
|
+ }
|
|
|
}
|
|
|
}else{
|
|
|
- if(thickness1.compareTo(thickness2) > 0){
|
|
|
- a = -1;
|
|
|
- }else{
|
|
|
- a = 1;
|
|
|
- }
|
|
|
+ a = producttype1.compareTo(producttype2);
|
|
|
}
|
|
|
}else{
|
|
|
- a = producttype1.compareTo(producttype2);
|
|
|
+ a = alloystatus1.compareTo(alloystatus2);
|
|
|
}
|
|
|
}else{
|
|
|
a = alloy1.compareTo(alloy2);
|
|
@@ -579,7 +579,7 @@ public class ApsServiceImpl implements ApsService {
|
|
|
}
|
|
|
}
|
|
|
Date finalApsPlanStartDate = apsPlanStartDate;
|
|
|
- apsOrderScheduleApsNew(apsBlankOrders,currentUser,allEqs, finalApsPlanStartDate,"mix");
|
|
|
+ apsOrderScheduleApsNew(apsBlankOrders,currentUser,allEqs, finalApsPlanStartDate,apsType);
|
|
|
}
|
|
|
|
|
|
private void apsOrderScheduleApsNew(List<ApsBlankOrderVo> apsBlankOrders,SysUserVo currentUser,Map<String,Equipment> allEqs,Date apsPlanStartDate,String apsType){
|