...
|
...
|
@@ -71,7 +71,7 @@ public class WeightCheckHandleServiceImpl implements WeightCheckHandleService { |
|
|
double result= 0.0;
|
|
|
//以防万一 空车离场判定
|
|
|
double result2= 0.0;
|
|
|
if(grossWt>0){
|
|
|
if(Double.doubleToLongBits(grossWt)>Double.doubleToLongBits(0)){
|
|
|
result = Double.parseDouble(df.format(Math.abs((inWt - goodsWt - grossWt)) / grossWt));
|
|
|
System.out.println("进出场比对差值:"+result);
|
|
|
result2 = Double.parseDouble(df.format(Math.abs((grossWt-wt)) / grossWt));
|
...
|
...
|
@@ -99,9 +99,9 @@ public class WeightCheckHandleServiceImpl implements WeightCheckHandleService { |
|
|
public boolean checkImportDlv(double grossWt, double wt, double goodsWt,double inWt){
|
|
|
DecimalFormat df = new DecimalFormat("0.00");
|
|
|
boolean flag = false;
|
|
|
double result= 0.0;
|
|
|
double result1= 0.0;
|
|
|
if(grossWt>0){
|
|
|
double result= 0.00;
|
|
|
double result1= 0.00;
|
|
|
if(Double.doubleToLongBits(grossWt)>Double.doubleToLongBits(0)){
|
|
|
//进场过磅重量+带货重量 = 出场过磅重量
|
|
|
result = Double.parseDouble(df.format(Math.abs((inWt + goodsWt - grossWt)) / grossWt));
|
|
|
|
...
|
...
|
@@ -119,11 +119,12 @@ public class WeightCheckHandleServiceImpl implements WeightCheckHandleService { |
|
|
flag = true;
|
|
|
}
|
|
|
|
|
|
//车辆备案重量+货物重量 = 出场过磅重量,测试用,生产关闭
|
|
|
if (result1 <= range) {
|
|
|
// //车辆备案重量+货物重量 = 出场过磅重量,测试用,生产关闭
|
|
|
// if (result1 <= range) {
|
|
|
//
|
|
|
// return true;
|
|
|
// }
|
|
|
|
|
|
return true;
|
|
|
}
|
|
|
return flag;
|
|
|
}
|
|
|
|
...
|
...
|
@@ -141,17 +142,18 @@ public class WeightCheckHandleServiceImpl implements WeightCheckHandleService { |
|
|
*/
|
|
|
@Override
|
|
|
public boolean checkAllocateOrDispatch(double grossWt, double wt, double goodsWt,double inWt){
|
|
|
//todo:调拨分拨中的第二.三...场站的如卡口判断 都应该以带货入场进行判定.离场都应该已空车进行判定.
|
|
|
DecimalFormat df = new DecimalFormat("0.00");
|
|
|
boolean flag = false;
|
|
|
//载货离场判定
|
|
|
double result= 0.0;
|
|
|
double result= 0.00;
|
|
|
//空车离场判定
|
|
|
double result2= 0.0;
|
|
|
double result2= 0.00;
|
|
|
|
|
|
//卸货离场判定
|
|
|
double result3= 0.0;
|
|
|
double result3= 0.00;
|
|
|
|
|
|
if(grossWt>0){
|
|
|
if(Double.doubleToLongBits(grossWt)>Double.doubleToLongBits(0)){
|
|
|
result = Double.parseDouble(df.format(Math.abs((inWt + goodsWt - grossWt)) / grossWt));
|
|
|
result2 = Double.parseDouble(df.format(Math.abs((grossWt-wt)) / grossWt));
|
|
|
result3 = Double.parseDouble(df.format(Math.abs((inWt - goodsWt - grossWt)) / grossWt));
|
...
|
...
|
|