|
@@ -967,6 +967,11 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
if ("0".equals(tranSettlementReport.getManualFlag())) {
|
|
|
//卸车不为空时,结算重量=装卸取小
|
|
|
tranSettlementReport.setSettlementWeight(tranSettlementReport.getLoadingWeight() > tranSettlementReport.getUnloadingWeight() ? tranSettlementReport.getUnloadingWeight() : tranSettlementReport.getLoadingWeight());
|
|
|
+ tranSettlementReport.setTransportDamage(tranSettlementReport.getSettlementWeight()*0.001);
|
|
|
+ }
|
|
|
+ //损耗大于结算重量的1‰时=损耗-结算重量x1‰
|
|
|
+ if (tranSettlementReport.getLossWeight()>tranSettlementReport.getSettlementWeight()*0.001){
|
|
|
+ tranSettlementReport.setCargoDamage(tranSettlementReport.getLossWeight()-tranSettlementReport.getSettlementWeight()*0.001);
|
|
|
}
|
|
|
if (tranSettlementReport.getTransportPrice()!=null) {
|
|
|
//扣款
|
|
@@ -1494,6 +1499,29 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
if ("汽运".equals(warehouseInOutInfo.getOutType())) {
|
|
|
tranSettlementReport.setTranType("汽运");
|
|
|
tranSettlementReport.setTranTypeKey("1");
|
|
|
+ tranSettlementReport.setSettlementWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
+ tranSettlementReport.setServiceCharge(20d);
|
|
|
+ //运输单价不为空
|
|
|
+ if (tranProcessInfo.getTranPrice()!=null){
|
|
|
+ //应付
|
|
|
+ tranSettlementReport.setAmountIngPayable(Float.valueOf(tranProcessInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight());
|
|
|
+ //实付金额
|
|
|
+ if(tranSettlementReport.getDeductionAmount() != null){
|
|
|
+ tranSettlementReport.setAmountActuallyPaid(Double.valueOf(tranProcessInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight()
|
|
|
+ - Double.valueOf(tranSettlementReport.getDeductionAmount()) - tranSettlementReport.getServiceCharge());
|
|
|
+ }else{
|
|
|
+ tranSettlementReport.setAmountActuallyPaid(Double.valueOf(tranProcessInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight()
|
|
|
+ - tranSettlementReport.getServiceCharge());
|
|
|
+ }
|
|
|
+ //税点
|
|
|
+ tranSettlementReport.setTaxPoint(tranSettlementReport.getAmountActuallyPaid()/0.946*0.054);
|
|
|
+ //合计应付
|
|
|
+ tranSettlementReport.setTotalPayable(tranSettlementReport.getAmountActuallyPaid()+tranSettlementReport.getTaxPoint());
|
|
|
+ //未付
|
|
|
+ tranSettlementReport.setAmountNotPayable(Float.valueOf(tranProcessInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight());
|
|
|
+ tranSettlementReport.setTransportPrice(tranProcessInfo.getTranPrice());
|
|
|
+ tranSettlementReport.setSettlementPrice(Double.valueOf(String.valueOf(tranProcessInfo.getTranPrice())));
|
|
|
+ }
|
|
|
} else if ("火运".equals(warehouseInOutInfo.getOutType())) {
|
|
|
tranSettlementReport.setTranType("火运");
|
|
|
TranCarInfo tranCarInfo=tranCarInfoService.selectOne(new EntityWrapper<TranCarInfo>()
|
|
@@ -1524,29 +1552,6 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
}
|
|
|
tranSettlementReport.setContractNo(warehouseInOutInfo.getContractNo());
|
|
|
tranSettlementReport.setCarNo(warehouseInOutInfo.getCarNo());
|
|
|
- tranSettlementReport.setSettlementWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
- tranSettlementReport.setServiceCharge(20d);
|
|
|
- //运输单价不为空
|
|
|
- if (tranProcessInfo.getTranPrice()!=null){
|
|
|
- //应付
|
|
|
- tranSettlementReport.setAmountIngPayable(Float.valueOf(tranProcessInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight());
|
|
|
- //实付金额
|
|
|
- if(tranSettlementReport.getDeductionAmount() != null){
|
|
|
- tranSettlementReport.setAmountActuallyPaid(Double.valueOf(tranProcessInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight()
|
|
|
- - Double.valueOf(tranSettlementReport.getDeductionAmount()) - tranSettlementReport.getServiceCharge());
|
|
|
- }else{
|
|
|
- tranSettlementReport.setAmountActuallyPaid(Double.valueOf(tranProcessInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight()
|
|
|
- - tranSettlementReport.getServiceCharge());
|
|
|
- }
|
|
|
- //税点
|
|
|
- tranSettlementReport.setTaxPoint(tranSettlementReport.getAmountActuallyPaid()/0.946*0.054);
|
|
|
- //合计应付
|
|
|
- tranSettlementReport.setTotalPayable(tranSettlementReport.getAmountActuallyPaid()+tranSettlementReport.getTaxPoint());
|
|
|
- //未付
|
|
|
- tranSettlementReport.setAmountNotPayable(Float.valueOf(tranProcessInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight());
|
|
|
- tranSettlementReport.setTransportPrice(tranProcessInfo.getTranPrice());
|
|
|
- tranSettlementReport.setSettlementPrice(Double.valueOf(String.valueOf(tranProcessInfo.getTranPrice())));
|
|
|
- }
|
|
|
tranSettlementReport.setLoadingImg(warehouseInOutInfo.getAddressUrl());
|
|
|
tranSettlementReport.setLoadingWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
tranSettlementReport.setStatusFlag(StatusEnum.PENDING_PAY.getFlag());
|
|
@@ -1690,6 +1695,30 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
if ("汽运".equals(warehouseInOutInfo.getOutType())) {
|
|
|
tranSettlementReport.setTranType("汽运");
|
|
|
tranSettlementReport.setTranTypeKey("1");
|
|
|
+ tranSettlementReport.setSettlementWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
+ tranSettlementReport.setServiceCharge(20d);
|
|
|
+ TranCarInfo tranCarInfo=tranCarInfoService.selectById(warehouseInOutInfo.getCarId());
|
|
|
+ //运输单价不为空
|
|
|
+ if (tranCarInfo!=null&&tranCarInfo.getTranPrice()!=null){
|
|
|
+ //实付金额
|
|
|
+ if(tranSettlementReport.getDeductionAmount() != null){
|
|
|
+ tranSettlementReport.setAmountActuallyPaid(Double.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight()
|
|
|
+ - Double.valueOf(tranSettlementReport.getDeductionAmount()) - tranSettlementReport.getServiceCharge());
|
|
|
+ }else{
|
|
|
+ tranSettlementReport.setAmountActuallyPaid(Double.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight()
|
|
|
+ - tranSettlementReport.getServiceCharge());
|
|
|
+ }
|
|
|
+ //税点
|
|
|
+ tranSettlementReport.setTaxPoint(tranSettlementReport.getAmountActuallyPaid()/0.946*0.054);
|
|
|
+ //合计应付
|
|
|
+ tranSettlementReport.setTotalPayable(tranSettlementReport.getAmountActuallyPaid()+tranSettlementReport.getTaxPoint());
|
|
|
+ //应付
|
|
|
+ tranSettlementReport.setAmountIngPayable(Float.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight());
|
|
|
+ //未付
|
|
|
+ tranSettlementReport.setAmountNotPayable(Float.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight());
|
|
|
+ tranSettlementReport.setTransportPrice(Float.valueOf(tranCarInfo.getTranPrice()));
|
|
|
+ tranSettlementReport.setSettlementPrice(Double.valueOf(tranCarInfo.getTranPrice()));
|
|
|
+ }
|
|
|
} else if ("火运".equals(warehouseInOutInfo.getOutType())) {
|
|
|
tranSettlementReport.setTranType("火运");
|
|
|
TranCarInfo tranCarInfo=tranCarInfoService.selectOne(new EntityWrapper<TranCarInfo>()
|
|
@@ -1720,29 +1749,6 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
}
|
|
|
tranSettlementReport.setContractNo(warehouseInOutInfo.getContractNo());
|
|
|
tranSettlementReport.setCarNo(warehouseInOutInfo.getCarNo());
|
|
|
- tranSettlementReport.setSettlementWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
- tranSettlementReport.setServiceCharge(20d);
|
|
|
- //运输单价不为空
|
|
|
- if (warehouseInOutInfo.getFreight()!=null){
|
|
|
- //实付金额
|
|
|
- if(tranSettlementReport.getDeductionAmount() != null){
|
|
|
- tranSettlementReport.setAmountActuallyPaid(Double.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight()
|
|
|
- - Double.valueOf(tranSettlementReport.getDeductionAmount()) - tranSettlementReport.getServiceCharge());
|
|
|
- }else{
|
|
|
- tranSettlementReport.setAmountActuallyPaid(Double.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight()
|
|
|
- - tranSettlementReport.getServiceCharge());
|
|
|
- }
|
|
|
- //税点
|
|
|
- tranSettlementReport.setTaxPoint(tranSettlementReport.getAmountActuallyPaid()/0.946*0.054);
|
|
|
- //合计应付
|
|
|
- tranSettlementReport.setTotalPayable(tranSettlementReport.getAmountActuallyPaid()+tranSettlementReport.getTaxPoint());
|
|
|
- //应付
|
|
|
- tranSettlementReport.setAmountIngPayable(Float.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight());
|
|
|
- //未付
|
|
|
- tranSettlementReport.setAmountNotPayable(Float.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight());
|
|
|
- tranSettlementReport.setTransportPrice(warehouseInOutInfo.getFreight());
|
|
|
- tranSettlementReport.setSettlementPrice(Double.valueOf(String.valueOf(warehouseInOutInfo.getFreight())));
|
|
|
- }
|
|
|
tranSettlementReport.setLoadingImg(warehouseInOutInfo.getAddressUrl());
|
|
|
tranSettlementReport.setLoadingWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
tranSettlementReport.setStatusFlag(StatusEnum.PENDING_PAY.getFlag());
|
|
@@ -2231,7 +2237,31 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
tranSettlementReport.setTranCarNo(warehouseInOutInfo.getTranCarNo());
|
|
|
if ("汽运".equals(warehouseInOutInfo.getOutType())) {
|
|
|
tranSettlementReport.setTranType("汽运");
|
|
|
+ tranSettlementReport.setSettlementWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
+ tranSettlementReport.setServiceCharge(20d);
|
|
|
tranSettlementReport.setTranTypeKey("1");
|
|
|
+ TranCarInfo tranCarInfo=tranCarInfoService.selectById(warehouseInOutInfo.getCarId());
|
|
|
+ //运输单价不为空
|
|
|
+ if (tranCarInfo!=null&&tranCarInfo.getTranPrice()!=null){
|
|
|
+ //实付金额
|
|
|
+ if(tranSettlementReport.getDeductionAmount() != null){
|
|
|
+ tranSettlementReport.setAmountActuallyPaid(Double.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight()
|
|
|
+ - Double.valueOf(tranSettlementReport.getDeductionAmount()) - tranSettlementReport.getServiceCharge());
|
|
|
+ }else{
|
|
|
+ tranSettlementReport.setAmountActuallyPaid(Double.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight()
|
|
|
+ - tranSettlementReport.getServiceCharge());
|
|
|
+ }
|
|
|
+ //税点
|
|
|
+ tranSettlementReport.setTaxPoint(tranSettlementReport.getAmountActuallyPaid()/0.946*0.054);
|
|
|
+ //合计应付
|
|
|
+ tranSettlementReport.setTotalPayable(tranSettlementReport.getAmountActuallyPaid()+tranSettlementReport.getTaxPoint());
|
|
|
+ //应付
|
|
|
+ tranSettlementReport.setAmountIngPayable(Float.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight());
|
|
|
+ //未付
|
|
|
+ tranSettlementReport.setAmountNotPayable(Float.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight());
|
|
|
+ tranSettlementReport.setTransportPrice(Float.valueOf(tranCarInfo.getTranPrice()));
|
|
|
+ tranSettlementReport.setSettlementPrice(Double.valueOf(tranCarInfo.getTranPrice()));
|
|
|
+ }
|
|
|
} else if ("火运".equals(warehouseInOutInfo.getOutType())) {
|
|
|
tranSettlementReport.setTranType("火运");
|
|
|
TranCarInfo tranCarInfo=tranCarInfoService.selectOne(new EntityWrapper<TranCarInfo>()
|
|
@@ -2262,29 +2292,6 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
}
|
|
|
tranSettlementReport.setContractNo(warehouseInOutInfo.getContractNo());
|
|
|
tranSettlementReport.setCarNo(warehouseInOutInfo.getCarNo());
|
|
|
- tranSettlementReport.setSettlementWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
- tranSettlementReport.setServiceCharge(20d);
|
|
|
- //运输单价不为空
|
|
|
- if (warehouseInOutInfo.getFreight()!=null){
|
|
|
- //实付金额
|
|
|
- if(tranSettlementReport.getDeductionAmount() != null){
|
|
|
- tranSettlementReport.setAmountActuallyPaid(Double.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight()
|
|
|
- - Double.valueOf(tranSettlementReport.getDeductionAmount()) - tranSettlementReport.getServiceCharge());
|
|
|
- }else{
|
|
|
- tranSettlementReport.setAmountActuallyPaid(Double.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight()
|
|
|
- - tranSettlementReport.getServiceCharge());
|
|
|
- }
|
|
|
- //税点
|
|
|
- tranSettlementReport.setTaxPoint(tranSettlementReport.getAmountActuallyPaid()/0.946*0.054);
|
|
|
- //合计应付
|
|
|
- tranSettlementReport.setTotalPayable(tranSettlementReport.getAmountActuallyPaid()+tranSettlementReport.getTaxPoint());
|
|
|
- //应付
|
|
|
- tranSettlementReport.setAmountIngPayable(Float.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight());
|
|
|
- //未付
|
|
|
- tranSettlementReport.setAmountNotPayable(Float.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight());
|
|
|
- tranSettlementReport.setTransportPrice(warehouseInOutInfo.getFreight());
|
|
|
- tranSettlementReport.setSettlementPrice(Double.valueOf(String.valueOf(warehouseInOutInfo.getFreight())));
|
|
|
- }
|
|
|
tranSettlementReport.setLoadingImg(warehouseInOutInfo.getAddressUrl());
|
|
|
tranSettlementReport.setLoadingWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
tranSettlementReport.setStatusFlag(StatusEnum.PENDING_PAY.getFlag());
|
|
@@ -3773,6 +3780,11 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
if ("0".equals(tranSettlementReport.getManualFlag())) {
|
|
|
//卸车不为空时,结算重量=装卸取小
|
|
|
tranSettlementReport.setSettlementWeight(tranSettlementReport.getLoadingWeight() > tranSettlementReport.getUnloadingWeight() ? tranSettlementReport.getUnloadingWeight() : tranSettlementReport.getLoadingWeight());
|
|
|
+ tranSettlementReport.setTransportDamage(tranSettlementReport.getSettlementWeight()*0.001);
|
|
|
+ }
|
|
|
+ //损耗大于结算重量的1‰时=损耗-结算重量x1‰
|
|
|
+ if (tranSettlementReport.getLossWeight()>tranSettlementReport.getSettlementWeight()*0.001){
|
|
|
+ tranSettlementReport.setCargoDamage(tranSettlementReport.getLossWeight()-tranSettlementReport.getSettlementWeight()*0.001);
|
|
|
}
|
|
|
if (tranSettlementReport.getTransportPrice() != null) {
|
|
|
//扣款
|
|
@@ -4416,6 +4428,29 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
if ("汽运".equals(warehouseInOutInfo.getOutType())) {
|
|
|
tranSettlementReport.setTranType("汽运");
|
|
|
tranSettlementReport.setTranTypeKey("1");
|
|
|
+ tranSettlementReport.setSettlementWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
+ tranSettlementReport.setServiceCharge(20d);
|
|
|
+ //运输单价不为空
|
|
|
+ if (tranProcessInfo.getTranPrice()!=null){
|
|
|
+ //实付金额
|
|
|
+ if(tranSettlementReport.getDeductionAmount() != null){
|
|
|
+ tranSettlementReport.setAmountActuallyPaid(Double.valueOf(String.valueOf(tranProcessInfo.getTranPrice())) * tranSettlementReport.getSettlementWeight()
|
|
|
+ - Double.valueOf(tranSettlementReport.getDeductionAmount()) - tranSettlementReport.getServiceCharge());
|
|
|
+ }else{
|
|
|
+ tranSettlementReport.setAmountActuallyPaid(Double.valueOf(String.valueOf(tranProcessInfo.getTranPrice())) * tranSettlementReport.getSettlementWeight()
|
|
|
+ - tranSettlementReport.getServiceCharge());
|
|
|
+ }
|
|
|
+ //税点
|
|
|
+ tranSettlementReport.setTaxPoint(tranSettlementReport.getAmountActuallyPaid()/0.946*0.054);
|
|
|
+ //合计应付
|
|
|
+ tranSettlementReport.setTotalPayable(tranSettlementReport.getAmountActuallyPaid()+tranSettlementReport.getTaxPoint());
|
|
|
+ //应付
|
|
|
+ tranSettlementReport.setAmountIngPayable(tranProcessInfo.getTranPrice() * tranSettlementReport.getSettlementWeight());
|
|
|
+ //未付
|
|
|
+ tranSettlementReport.setAmountNotPayable(tranProcessInfo.getTranPrice() * tranSettlementReport.getSettlementWeight());
|
|
|
+ tranSettlementReport.setTransportPrice(tranProcessInfo.getTranPrice());
|
|
|
+ tranSettlementReport.setSettlementPrice(Double.valueOf(String.valueOf(tranProcessInfo.getTranPrice())));
|
|
|
+ }
|
|
|
} else if ("火运".equals(warehouseInOutInfo.getOutType())) {
|
|
|
tranSettlementReport.setTranType("火运");
|
|
|
TranCarInfo tranCarInfo=tranCarInfoService.selectOne(new EntityWrapper<TranCarInfo>()
|
|
@@ -4448,29 +4483,6 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
tranSettlementReport.setCarNo(warehouseInOutInfo.getCarNo());
|
|
|
tranSettlementReport.setTranCarNo(warehouseInOutInfo.getTranCarNo());
|
|
|
tranSettlementReport.setStartAddress(warehouseInOutInfo.getWarehouseName());
|
|
|
- tranSettlementReport.setSettlementWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
- tranSettlementReport.setServiceCharge(20d);
|
|
|
- //运输单价不为空
|
|
|
- if (tranProcessInfo.getTranPrice()!=null){
|
|
|
- //实付金额
|
|
|
- if(tranSettlementReport.getDeductionAmount() != null){
|
|
|
- tranSettlementReport.setAmountActuallyPaid(Double.valueOf(tranProcessInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight()
|
|
|
- - Double.valueOf(tranSettlementReport.getDeductionAmount()) - tranSettlementReport.getServiceCharge());
|
|
|
- }else{
|
|
|
- tranSettlementReport.setAmountActuallyPaid(Double.valueOf(tranProcessInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight()
|
|
|
- - tranSettlementReport.getServiceCharge());
|
|
|
- }
|
|
|
- //税点
|
|
|
- tranSettlementReport.setTaxPoint(tranSettlementReport.getAmountActuallyPaid()/0.946*0.054);
|
|
|
- //合计应付
|
|
|
- tranSettlementReport.setTotalPayable(tranSettlementReport.getAmountActuallyPaid()+tranSettlementReport.getTaxPoint());
|
|
|
- //应付
|
|
|
- tranSettlementReport.setAmountIngPayable(Float.valueOf(tranProcessInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight());
|
|
|
- //未付
|
|
|
- tranSettlementReport.setAmountNotPayable(Float.valueOf(tranProcessInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight());
|
|
|
- tranSettlementReport.setTransportPrice(tranProcessInfo.getTranPrice());
|
|
|
- tranSettlementReport.setSettlementPrice(Double.valueOf(String.valueOf(tranProcessInfo.getTranPrice())));
|
|
|
- }
|
|
|
tranSettlementReport.setLoadingImg(warehouseInOutInfo.getAddressUrl());
|
|
|
tranSettlementReport.setLoadingWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
tranSettlementReport.setStatusFlag(StatusEnum.PENDING_PAY.getFlag());
|
|
@@ -4635,6 +4647,30 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
if ("汽运".equals(warehouseInOutInfo.getOutType())) {
|
|
|
tranSettlementReport.setTranType("汽运");
|
|
|
tranSettlementReport.setTranTypeKey("1");
|
|
|
+ tranSettlementReport.setSettlementWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
+ tranSettlementReport.setServiceCharge(20d);
|
|
|
+ TranCarInfo tranCarInfo=tranCarInfoService.selectById(warehouseInOutInfo.getCarId());
|
|
|
+ //运输单价不为空
|
|
|
+ if (tranCarInfo!=null&&tranCarInfo.getTranPrice()!=null){
|
|
|
+ //实付金额
|
|
|
+ if(tranSettlementReport.getDeductionAmount() != null){
|
|
|
+ tranSettlementReport.setAmountActuallyPaid(Double.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight()
|
|
|
+ - Double.valueOf(tranSettlementReport.getDeductionAmount()) - tranSettlementReport.getServiceCharge());
|
|
|
+ }else{
|
|
|
+ tranSettlementReport.setAmountActuallyPaid(Double.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight()
|
|
|
+ - tranSettlementReport.getServiceCharge());
|
|
|
+ }
|
|
|
+ //税点
|
|
|
+ tranSettlementReport.setTaxPoint(tranSettlementReport.getAmountActuallyPaid()/0.946*0.054);
|
|
|
+ //合计应付
|
|
|
+ tranSettlementReport.setTotalPayable(tranSettlementReport.getAmountActuallyPaid()+tranSettlementReport.getTaxPoint());
|
|
|
+ //应付
|
|
|
+ tranSettlementReport.setAmountIngPayable(Float.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight());
|
|
|
+ //未付
|
|
|
+ tranSettlementReport.setAmountNotPayable(Float.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight());
|
|
|
+ tranSettlementReport.setTransportPrice(Float.valueOf(tranCarInfo.getTranPrice()));
|
|
|
+ tranSettlementReport.setSettlementPrice(Double.valueOf(tranCarInfo.getTranPrice()));
|
|
|
+ }
|
|
|
} else if ("火运".equals(warehouseInOutInfo.getOutType())) {
|
|
|
tranSettlementReport.setTranType("火运");
|
|
|
TranCarInfo tranCarInfo=tranCarInfoService.selectOne(new EntityWrapper<TranCarInfo>()
|
|
@@ -4666,29 +4702,6 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
tranSettlementReport.setContractNo(warehouseInOutInfo.getContractNo());
|
|
|
tranSettlementReport.setCarNo(warehouseInOutInfo.getCarNo());
|
|
|
tranSettlementReport.setStartAddress(warehouseInOutInfo.getWarehouseName());
|
|
|
- tranSettlementReport.setSettlementWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
- tranSettlementReport.setServiceCharge(20d);
|
|
|
- //运输单价不为空
|
|
|
- if (warehouseInOutInfo.getFreight()!=null){
|
|
|
- //实付金额
|
|
|
- if(tranSettlementReport.getDeductionAmount() != null){
|
|
|
- tranSettlementReport.setAmountActuallyPaid(Double.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight()
|
|
|
- - Double.valueOf(tranSettlementReport.getDeductionAmount()) - tranSettlementReport.getServiceCharge());
|
|
|
- }else{
|
|
|
- tranSettlementReport.setAmountActuallyPaid(Double.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight()
|
|
|
- - tranSettlementReport.getServiceCharge());
|
|
|
- }
|
|
|
- //税点
|
|
|
- tranSettlementReport.setTaxPoint(tranSettlementReport.getAmountActuallyPaid()/0.946*0.054);
|
|
|
- //合计应付
|
|
|
- tranSettlementReport.setTotalPayable(tranSettlementReport.getAmountActuallyPaid()+tranSettlementReport.getTaxPoint());
|
|
|
- //应付
|
|
|
- tranSettlementReport.setAmountIngPayable(Float.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight());
|
|
|
- //未付
|
|
|
- tranSettlementReport.setAmountNotPayable(Float.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight());
|
|
|
- tranSettlementReport.setTransportPrice(warehouseInOutInfo.getFreight());
|
|
|
- tranSettlementReport.setSettlementPrice(Double.valueOf(String.valueOf(warehouseInOutInfo.getFreight())));
|
|
|
- }
|
|
|
tranSettlementReport.setLoadingImg(warehouseInOutInfo.getAddressUrl());
|
|
|
tranSettlementReport.setLoadingWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
tranSettlementReport.setStatusFlag(StatusEnum.PENDING_PAY.getFlag());
|
|
@@ -4962,6 +4975,7 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
.eq("deliver_type", "2")
|
|
|
.eq("contract_type", "1")
|
|
|
.eq("delete_flag", "0"));
|
|
|
+
|
|
|
//现货销售出库报表
|
|
|
StockSaleReceiptReport stockSaleReceiptReport = new StockSaleReceiptReport();
|
|
|
stockSaleReceiptReport.setId(IdGenerator.generateUUID());
|
|
@@ -4974,7 +4988,12 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
stockSaleReceiptReport.setTare(Double.valueOf(String.valueOf(warehouseInOutInfo.getTare())));
|
|
|
stockSaleReceiptReport.setNetWeight(Double.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
stockSaleReceiptReport.setSettlementWeight(Double.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
- stockSaleReceiptReport.setSettlementPrice(Double.valueOf(String.valueOf(warehouseInOutInfo.getCost()==null?(contractManagementInfoSale.getUnitContractPrice()==null?0:contractManagementInfoSale.getUnitContractPrice()):warehouseInOutInfo.getCost())));
|
|
|
+ if (contractManagementInfoSale!=null) {
|
|
|
+ stockSaleReceiptReport.setSettlementPrice(Double.valueOf(String.valueOf(warehouseInOutInfo.getCost() == null ? (contractManagementInfoSale.getUnitContractPrice() == null ? 0 : contractManagementInfoSale.getUnitContractPrice()) : warehouseInOutInfo.getCost())));
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ stockSaleReceiptReport.setSettlementPrice(Double.valueOf(String.valueOf(warehouseInOutInfo.getCost() == null ? (contractManagementInfo.getUnitContractPrice() == null ? 0 : contractManagementInfo.getUnitContractPrice()) : warehouseInOutInfo.getCost())));
|
|
|
+ }
|
|
|
stockSaleReceiptReport.setAmountEdReceivable(0.0d);
|
|
|
stockSaleReceiptReport.setDeliveryDate(warehouseInOutInfo.getInOutDate());
|
|
|
stockSaleReceiptReport.setAmountIngReceivable(stockSaleReceiptReport.getSettlementPrice() * warehouseInOutInfo.getNetWeight());
|
|
@@ -5250,6 +5269,30 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
if ("汽运".equals(warehouseInOutInfo.getOutType())) {
|
|
|
tranSettlementReport.setTranType("汽运");
|
|
|
tranSettlementReport.setTranTypeKey("1");
|
|
|
+ tranSettlementReport.setSettlementWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
+ tranSettlementReport.setServiceCharge(20d);
|
|
|
+ TranCarInfo tranCarInfo=tranCarInfoService.selectById(warehouseInOutInfo.getCarId());
|
|
|
+ //运输单价不为空
|
|
|
+ if (tranCarInfo!=null&&tranCarInfo.getTranPrice()!=null){
|
|
|
+ //实付金额
|
|
|
+ if(tranSettlementReport.getDeductionAmount() != null){
|
|
|
+ tranSettlementReport.setAmountActuallyPaid(Double.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight()
|
|
|
+ - Double.valueOf(tranSettlementReport.getDeductionAmount()) - tranSettlementReport.getServiceCharge());
|
|
|
+ }else{
|
|
|
+ tranSettlementReport.setAmountActuallyPaid(Double.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight()
|
|
|
+ - tranSettlementReport.getServiceCharge());
|
|
|
+ }
|
|
|
+ //税点
|
|
|
+ tranSettlementReport.setTaxPoint(tranSettlementReport.getAmountActuallyPaid()/0.946*0.054);
|
|
|
+ //合计应付
|
|
|
+ tranSettlementReport.setTotalPayable(tranSettlementReport.getAmountActuallyPaid()+tranSettlementReport.getTaxPoint());
|
|
|
+ //应付
|
|
|
+ tranSettlementReport.setAmountIngPayable(Float.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight());
|
|
|
+ //未付
|
|
|
+ tranSettlementReport.setAmountNotPayable(Float.valueOf(tranCarInfo.getTranPrice()) * tranSettlementReport.getSettlementWeight());
|
|
|
+ tranSettlementReport.setTransportPrice(Float.valueOf(tranCarInfo.getTranPrice()));
|
|
|
+ tranSettlementReport.setSettlementPrice(Double.valueOf(tranCarInfo.getTranPrice()));
|
|
|
+ }
|
|
|
} else if ("火运".equals(warehouseInOutInfo.getOutType())) {
|
|
|
tranSettlementReport.setTranType("火运");
|
|
|
TranCarInfo tranCarInfo=tranCarInfoService.selectOne(new EntityWrapper<TranCarInfo>()
|
|
@@ -5282,29 +5325,6 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
|
|
|
tranSettlementReport.setCarNo(warehouseInOutInfo.getCarNo());
|
|
|
tranSettlementReport.setTranCarNo(warehouseInOutInfo.getTranCarNo());
|
|
|
tranSettlementReport.setStartAddress(warehouseInOutInfo.getWarehouseName());
|
|
|
- tranSettlementReport.setSettlementWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
- tranSettlementReport.setServiceCharge(20d);
|
|
|
- //运输单价不为空
|
|
|
- if (warehouseInOutInfo.getFreight()!=null){
|
|
|
- //实付金额
|
|
|
- if(tranSettlementReport.getDeductionAmount() != null){
|
|
|
- tranSettlementReport.setAmountActuallyPaid(Double.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight()
|
|
|
- - Double.valueOf(tranSettlementReport.getDeductionAmount()) - tranSettlementReport.getServiceCharge());
|
|
|
- }else{
|
|
|
- tranSettlementReport.setAmountActuallyPaid(Double.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight()
|
|
|
- - tranSettlementReport.getServiceCharge());
|
|
|
- }
|
|
|
- //税点
|
|
|
- tranSettlementReport.setTaxPoint(tranSettlementReport.getAmountActuallyPaid()/0.946*0.054);
|
|
|
- //合计应付
|
|
|
- tranSettlementReport.setTotalPayable(tranSettlementReport.getAmountActuallyPaid()+tranSettlementReport.getTaxPoint());
|
|
|
- //应付
|
|
|
- tranSettlementReport.setAmountIngPayable(Float.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight());
|
|
|
- //未付
|
|
|
- tranSettlementReport.setAmountNotPayable(Float.valueOf(warehouseInOutInfo.getFreight()) * tranSettlementReport.getSettlementWeight());
|
|
|
- tranSettlementReport.setTransportPrice(warehouseInOutInfo.getFreight());
|
|
|
- tranSettlementReport.setSettlementPrice(Double.valueOf(String.valueOf(warehouseInOutInfo.getFreight())));
|
|
|
- }
|
|
|
tranSettlementReport.setLoadingImg(warehouseInOutInfo.getAddressUrl());
|
|
|
tranSettlementReport.setLoadingWeight(Float.valueOf(String.valueOf(warehouseInOutInfo.getNetWeight())));
|
|
|
tranSettlementReport.setStatusFlag(StatusEnum.PENDING_PAY.getFlag());
|