|
@@ -824,20 +824,20 @@ public class MeterWorkRailwayActualServiceImpl extends BaseServiceImpl<MeterWork
|
|
|
} else if (!queryrow.getIsPreSacale().equals("0") && queryrow.getPredictionNo() != null) {
|
|
} else if (!queryrow.getIsPreSacale().equals("0") && queryrow.getPredictionNo() != null) {
|
|
|
throw new MarkerMetException(500, "只有未匹配的净重数据才能进行委托匹配操作");
|
|
throw new MarkerMetException(500, "只有未匹配的净重数据才能进行委托匹配操作");
|
|
|
}
|
|
}
|
|
|
- try{
|
|
|
|
|
- SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
|
|
|
|
- if(queryrow.getUpdateTime() != null && StringUtils.isNotEmpty(queryrow.getUpdateTime().toString())) {
|
|
|
|
|
- long sTime = df.parse(queryrow.getUpdateTime().toString()).getTime();
|
|
|
|
|
- long eTime = df.parse((new Date()).toString()).getTime();
|
|
|
|
|
- long diff = (eTime - sTime) / 1000;
|
|
|
|
|
- if(diff <= 15) {
|
|
|
|
|
- throw new MarkerMetException(500, "匹配委托需在解除委托15秒后进行,请稍等");
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
- }catch(Exception e) {
|
|
|
|
|
- e.printStackTrace();
|
|
|
|
|
- throw new MarkerMetException(500, "操作失败");
|
|
|
|
|
- }
|
|
|
|
|
|
|
+// try{
|
|
|
|
|
+// SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
|
|
|
|
+// if(queryrow.getUpdateTime() != null && StringUtils.isNotEmpty(queryrow.getUpdateTime().toString())) {
|
|
|
|
|
+// long sTime = df.parse(queryrow.getUpdateTime().toString()).getTime();
|
|
|
|
|
+// long eTime = df.parse((new Date()).toString()).getTime();
|
|
|
|
|
+// long diff = (eTime - sTime) / 1000;
|
|
|
|
|
+// if(diff <= 15) {
|
|
|
|
|
+// throw new MarkerMetException(500, "匹配委托需在解除委托15秒后进行,请稍等");
|
|
|
|
|
+// }
|
|
|
|
|
+// }
|
|
|
|
|
+// }catch(Exception e) {
|
|
|
|
|
+// e.printStackTrace();
|
|
|
|
|
+// throw new MarkerMetException(500, "操作失败");
|
|
|
|
|
+// }
|
|
|
|
|
|
|
|
PreRailwayScale prerow = preRailwayScaleMapper.selectByPrimaryKey(predictionNo);
|
|
PreRailwayScale prerow = preRailwayScaleMapper.selectByPrimaryKey(predictionNo);
|
|
|
if (prerow == null) {
|
|
if (prerow == null) {
|
|
@@ -1036,20 +1036,20 @@ public class MeterWorkRailwayActualServiceImpl extends BaseServiceImpl<MeterWork
|
|
|
if (mwcaquery == null) {
|
|
if (mwcaquery == null) {
|
|
|
throw new MarkerMetException(500, "不存在对应的结净数据");
|
|
throw new MarkerMetException(500, "不存在对应的结净数据");
|
|
|
}else {
|
|
}else {
|
|
|
- try{
|
|
|
|
|
- SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
|
|
|
|
- if(mwcaquery.getUpdateTime() != null && StringUtils.isNotEmpty(mwcaquery.getUpdateTime().toString())) {
|
|
|
|
|
- long sTime = df.parse(mwcaquery.getUpdateTime().toString()).getTime();
|
|
|
|
|
- long eTime = df.parse((new Date()).toString()).getTime();
|
|
|
|
|
- long diff = (eTime - sTime) / 1000;
|
|
|
|
|
- if(diff <= 15) {
|
|
|
|
|
- throw new MarkerMetException(500, "解除委托需在匹配委托15秒后进行,请稍等");
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
- }catch(Exception e) {
|
|
|
|
|
- e.printStackTrace();
|
|
|
|
|
- throw new MarkerMetException(500, "操作失败");
|
|
|
|
|
- }
|
|
|
|
|
|
|
+// try{
|
|
|
|
|
+// SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
|
|
|
|
+// if(mwcaquery.getUpdateTime() != null && StringUtils.isNotEmpty(mwcaquery.getUpdateTime().toString())) {
|
|
|
|
|
+// long sTime = df.parse(mwcaquery.getUpdateTime().toString()).getTime();
|
|
|
|
|
+// long eTime = df.parse((new Date()).toString()).getTime();
|
|
|
|
|
+// long diff = (eTime - sTime) / 1000;
|
|
|
|
|
+// if(diff <= 15) {
|
|
|
|
|
+// throw new MarkerMetException(500, "解除委托需在匹配委托15秒后进行,请稍等");
|
|
|
|
|
+// }
|
|
|
|
|
+// }
|
|
|
|
|
+// }catch(Exception e) {
|
|
|
|
|
+// e.printStackTrace();
|
|
|
|
|
+// throw new MarkerMetException(500, "操作失败");
|
|
|
|
|
+// }
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
if(model.getPredictionNo() != null && StringUtils.isNotEmpty(model.getPredictionNo())){
|
|
if(model.getPredictionNo() != null && StringUtils.isNotEmpty(model.getPredictionNo())){
|