|
@@ -131,6 +131,11 @@ public class ProductionProcesses implements Serializable {
|
|
|
*/
|
|
|
private Integer delay;
|
|
|
|
|
|
+ /**
|
|
|
+ * 延迟分钟数据(步长5分钟)
|
|
|
+ */
|
|
|
+ private List<Integer> thFzdDelays;
|
|
|
+
|
|
|
private Step previousStep;
|
|
|
|
|
|
/**
|
|
@@ -468,28 +473,45 @@ public class ProductionProcesses implements Serializable {
|
|
|
return optionalProviderEquipments;
|
|
|
}
|
|
|
|
|
|
- @ValueRangeProvider
|
|
|
+ /*@ValueRangeProvider
|
|
|
@JsonIgnore
|
|
|
public CountableValueRange<Integer> getDelayRange() {
|
|
|
- /*if(this.getPreviousProcesses() != null && this.getPreviousProcesses().size()>0){
|
|
|
- Integer maxWaitTime = null;
|
|
|
- for (ProductionProcesses previousProcess : this.getPreviousProcesses()) {
|
|
|
- if(previousProcess.getMaxWaitTime() != null && previousProcess.getMaxWaitTime()>0){
|
|
|
- if(maxWaitTime == null){
|
|
|
- maxWaitTime = previousProcess.getMaxWaitTime();
|
|
|
- }else{
|
|
|
- if(previousProcess.getMaxWaitTime() > maxWaitTime){
|
|
|
- maxWaitTime = previousProcess.getMaxWaitTime();
|
|
|
- }
|
|
|
- }
|
|
|
+ Integer maxDelay = 1;
|
|
|
+ if(!this.ifLock){
|
|
|
+ if(this.processType.equals("成退") || this.processType.equals("中退") || this.processType.equals("小卷成退")){
|
|
|
+ if("dd".equals(apsOverallConfig.getScheduleType().getScheduleType())){
|
|
|
+ maxDelay = 500;
|
|
|
+ }else{
|
|
|
+ maxDelay = 800;
|
|
|
}
|
|
|
+ }else if(this.processType.equals("铸轧")){
|
|
|
+ maxDelay = 5000;
|
|
|
+ } else if (this.processType.equals("冷轧")) {
|
|
|
+ if("dd".equals(apsOverallConfig.getScheduleType().getScheduleType())){
|
|
|
+ maxDelay = 800;
|
|
|
+ }else{
|
|
|
+ maxDelay = 2000;
|
|
|
+ }
|
|
|
+ }else if (this.processType.equals("箔轧")) {
|
|
|
+ if("dd".equals(apsOverallConfig.getScheduleType().getScheduleType())){
|
|
|
+ maxDelay = 800;
|
|
|
+ }else{
|
|
|
+ maxDelay = 2000;
|
|
|
+ }
|
|
|
+ } else{
|
|
|
+ maxDelay = 500;
|
|
|
}
|
|
|
- if(maxWaitTime != null && maxWaitTime>0){
|
|
|
- int maxrange = (maxWaitTime / 20) + 1;
|
|
|
- return ValueRangeFactory.createIntValueRange(0, maxrange);
|
|
|
- }
|
|
|
- }*/
|
|
|
+ }
|
|
|
+ return ValueRangeFactory.createIntValueRange(0, maxDelay);
|
|
|
+ }*/
|
|
|
+
|
|
|
+ @ValueRangeProvider
|
|
|
+ @JsonIgnore
|
|
|
+ public List<Integer> getDelayRange() {
|
|
|
+ List<Integer> delays = new ArrayList<>();
|
|
|
+ delays.add(0);
|
|
|
Integer maxDelay = 1;
|
|
|
+ Integer bc = 1;
|
|
|
if(!this.ifLock){
|
|
|
if(this.processType.equals("成退") || this.processType.equals("中退") || this.processType.equals("小卷成退")){
|
|
|
if("dd".equals(apsOverallConfig.getScheduleType().getScheduleType())){
|
|
@@ -497,25 +519,37 @@ public class ProductionProcesses implements Serializable {
|
|
|
}else{
|
|
|
maxDelay = 800;
|
|
|
}
|
|
|
+ bc = 60;
|
|
|
}else if(this.processType.equals("铸轧")){
|
|
|
maxDelay = 5000;
|
|
|
+ bc = 10;
|
|
|
} else if (this.processType.equals("冷轧")) {
|
|
|
if("dd".equals(apsOverallConfig.getScheduleType().getScheduleType())){
|
|
|
maxDelay = 800;
|
|
|
}else{
|
|
|
maxDelay = 2000;
|
|
|
}
|
|
|
+ bc = 10;
|
|
|
}else if (this.processType.equals("箔轧")) {
|
|
|
if("dd".equals(apsOverallConfig.getScheduleType().getScheduleType())){
|
|
|
maxDelay = 800;
|
|
|
}else{
|
|
|
maxDelay = 2000;
|
|
|
}
|
|
|
+ bc = 10;
|
|
|
} else{
|
|
|
maxDelay = 500;
|
|
|
+ bc = 10;
|
|
|
}
|
|
|
}
|
|
|
- return ValueRangeFactory.createIntValueRange(0, maxDelay);
|
|
|
+
|
|
|
+ for (Integer i = 1; i <= maxDelay; i++) {
|
|
|
+ delays.add(i*bc);
|
|
|
+ }
|
|
|
+ if(thFzdDelays != null && thFzdDelays.size()>0){
|
|
|
+ delays.addAll(thFzdDelays);
|
|
|
+ }
|
|
|
+ return delays;
|
|
|
}
|
|
|
|
|
|
public void setOptionalProviderEquipments(List<Equipment> optionalProviderEquipments) {
|
|
@@ -1203,6 +1237,14 @@ public class ProductionProcesses implements Serializable {
|
|
|
this.lastHistoryEquipmentId = lastHistoryEquipmentId;
|
|
|
}
|
|
|
|
|
|
+ public List<Integer> getThFzdDelays() {
|
|
|
+ return thFzdDelays;
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setThFzdDelays(List<Integer> thFzdDelays) {
|
|
|
+ this.thFzdDelays = thFzdDelays;
|
|
|
+ }
|
|
|
+
|
|
|
public String getSeriSort(){
|
|
|
String sortStr = this.getId();
|
|
|
if(this.getStartTime() != null){
|