Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
C
clx-performance
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
姜武杰
clx-performance
Commits
0e0c0c80
提交
0e0c0c80
authored
8月 13, 2024
作者:
刘海泉
浏览文件
操作
浏览文件
下载
差异文件
Merge remote-tracking branch 'origin/v20.8_add_sub_weight_20240805' into dev
上级
1c58d3ba
19888ca0
隐藏空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
13 行增加
和
16 行删除
+13
-16
OrderChildMapper.java
...ain/java/com/clx/performance/mapper/OrderChildMapper.java
+3
-2
OrderGoodsServiceImpl.java
...m/clx/performance/service/impl/OrderGoodsServiceImpl.java
+5
-9
OrderWeightServiceImpl.java
.../clx/performance/service/impl/OrderWeightServiceImpl.java
+4
-4
OrderChildSqlProvider.java
...om/clx/performance/sqlProvider/OrderChildSqlProvider.java
+1
-1
没有找到文件。
performance-web/src/main/java/com/clx/performance/mapper/OrderChildMapper.java
浏览文件 @
0e0c0c80
...
@@ -186,6 +186,6 @@ public interface OrderChildMapper extends BaseMapper<OrderChild> {
...
@@ -186,6 +186,6 @@ public interface OrderChildMapper extends BaseMapper<OrderChild> {
@
Select
Provider
(
type
=
OrderChildSqlProvider
.
class
,
method
=
"batchUpdateCancel"
)
@
Update
Provider
(
type
=
OrderChildSqlProvider
.
class
,
method
=
"batchUpdateCancel"
)
void
batchUpdateCancel
(
@Param
(
"canCancelOrderChildList"
)
List
<
OrderChild
>
canCancelOrderChildList
);
void
batchUpdateCancel
(
List
<
OrderChild
>
canCancelOrderChildList
);
}
}
\ No newline at end of file
performance-web/src/main/java/com/clx/performance/service/impl/OrderGoodsServiceImpl.java
浏览文件 @
0e0c0c80
...
@@ -178,7 +178,7 @@ public class OrderGoodsServiceImpl implements OrderGoodsService, InitializingBea
...
@@ -178,7 +178,7 @@ public class OrderGoodsServiceImpl implements OrderGoodsService, InitializingBea
orderGoodsVO
.
setUnloadEndTime
(
orderInfoFeign
.
getUnloadEndTime
());
orderGoodsVO
.
setUnloadEndTime
(
orderInfoFeign
.
getUnloadEndTime
());
orderGoodsVO
.
setLoadBeginTime
(
orderInfoFeign
.
getLoadBeginTime
());
orderGoodsVO
.
setLoadBeginTime
(
orderInfoFeign
.
getLoadBeginTime
());
orderGoodsVO
.
setLoadEndTime
(
orderInfoFeign
.
getLoadEndTime
());
orderGoodsVO
.
setLoadEndTime
(
orderInfoFeign
.
getLoadEndTime
());
orderGoodsVO
.
setResidueTransportWeight
(
BigDecimal
.
ZERO
.
compareTo
(
residueWeight
)
>
0
?
BigDecimal
.
ZERO
:
residueWeight
);
orderGoodsVO
.
setResidueTransportWeight
(
residueWeight
);
//获取订单配置的违约金方案
//获取订单配置的违约金方案
OwnerQuotationDetailVO
quotationDetailVO
=
quotationService
.
getQuotationByOrderNo
(
orderNo
).
orElseThrow
(
PerformanceResultEnum
.
DATA_NOT_FIND
);
OwnerQuotationDetailVO
quotationDetailVO
=
quotationService
.
getQuotationByOrderNo
(
orderNo
).
orElseThrow
(
PerformanceResultEnum
.
DATA_NOT_FIND
);
...
@@ -781,7 +781,7 @@ public class OrderGoodsServiceImpl implements OrderGoodsService, InitializingBea
...
@@ -781,7 +781,7 @@ public class OrderGoodsServiceImpl implements OrderGoodsService, InitializingBea
PerformanceResultEnum
.
DATA_NOT_FIND
);
PerformanceResultEnum
.
DATA_NOT_FIND
);
//订单剩余吨数
//订单剩余吨数
BigDecimal
orderResidueWeight
=
orderWeightService
.
getOrderResidueWeight
(
goodsCancelParam
.
getOrderNo
());
BigDecimal
orderResidueWeight
=
orderWeightService
.
getOrderResidueWeight
(
orderGoods
.
getOrderNo
());
//获取货单剩余吨数
//获取货单剩余吨数
BigDecimal
orderGoodsResidueWeight
=
this
.
calcOrderGoodsResidueWeight
(
orderGoods
.
getExtractWeight
(),
orderGoods
.
getAlreadyTransportWeight
());
BigDecimal
orderGoodsResidueWeight
=
this
.
calcOrderGoodsResidueWeight
(
orderGoods
.
getExtractWeight
(),
orderGoods
.
getAlreadyTransportWeight
());
...
@@ -1034,12 +1034,8 @@ public class OrderGoodsServiceImpl implements OrderGoodsService, InitializingBea
...
@@ -1034,12 +1034,8 @@ public class OrderGoodsServiceImpl implements OrderGoodsService, InitializingBea
@Override
@Override
public
BigDecimal
calcOrderGoodsResidueWeight
(
BigDecimal
extractWeight
,
BigDecimal
alreadyWeight
)
{
public
BigDecimal
calcOrderGoodsResidueWeight
(
BigDecimal
extractWeight
,
BigDecimal
alreadyWeight
)
{
BigDecimal
residueTransportWeight
=
Objects
.
nonNull
(
extractWeight
)?
extractWeight:
BigDecimal
.
ZERO
BigDecimal
weight1
=
Objects
.
nonNull
(
extractWeight
)?
extractWeight:
BigDecimal
.
ZERO
;
.
subtract
(
Objects
.
nonNull
(
alreadyWeight
)?
alreadyWeight:
BigDecimal
.
ZERO
);
BigDecimal
weight2
=
Objects
.
nonNull
(
alreadyWeight
)?
alreadyWeight:
BigDecimal
.
ZERO
;
return
weight1
.
subtract
(
weight2
);
if
(
residueTransportWeight
.
compareTo
(
BigDecimal
.
ZERO
)
<=
0
){
return
BigDecimal
.
ZERO
;
}
return
residueTransportWeight
;
}
}
}
}
performance-web/src/main/java/com/clx/performance/service/impl/OrderWeightServiceImpl.java
浏览文件 @
0e0c0c80
...
@@ -4,10 +4,7 @@ import com.clx.order.enums.VehicleUsageEnum;
...
@@ -4,10 +4,7 @@ import com.clx.order.enums.VehicleUsageEnum;
import
com.clx.order.vo.feign.FeignOrderInfoVO
;
import
com.clx.order.vo.feign.FeignOrderInfoVO
;
import
com.clx.performance.dao.OrderChildDao
;
import
com.clx.performance.dao.OrderChildDao
;
import
com.clx.performance.dao.OrderGoodsDao
;
import
com.clx.performance.dao.OrderGoodsDao
;
import
com.clx.performance.enums.OrderGoodsStatusEnum
;
import
com.clx.performance.enums.*
;
import
com.clx.performance.enums.PerformanceResultEnum
;
import
com.clx.performance.enums.ResultEnum
;
import
com.clx.performance.enums.TruckDemandEnum
;
import
com.clx.performance.extranal.user.OrderService
;
import
com.clx.performance.extranal.user.OrderService
;
import
com.clx.performance.model.OrderChild
;
import
com.clx.performance.model.OrderChild
;
import
com.clx.performance.model.OrderGoods
;
import
com.clx.performance.model.OrderGoods
;
...
@@ -147,6 +144,9 @@ public class OrderWeightServiceImpl implements OrderWeightService {
...
@@ -147,6 +144,9 @@ public class OrderWeightServiceImpl implements OrderWeightService {
BigDecimal
alreadyWeight
=
BigDecimal
.
ZERO
;
//该订单下已经拉运的重量
BigDecimal
alreadyWeight
=
BigDecimal
.
ZERO
;
//该订单下已经拉运的重量
for
(
OrderChild
child
:
orderChildList
)
{
for
(
OrderChild
child
:
orderChildList
)
{
if
(
child
.
getStatus
()
>
OrderChildEnum
.
Status
.
COMPLETE
.
getCode
()){
continue
;
}
if
(
Objects
.
nonNull
(
child
.
getLoadNet
())){
if
(
Objects
.
nonNull
(
child
.
getLoadNet
())){
alreadyWeight
=
alreadyWeight
.
add
(
child
.
getLoadNet
());
alreadyWeight
=
alreadyWeight
.
add
(
child
.
getLoadNet
());
}
else
{
}
else
{
...
...
performance-web/src/main/java/com/clx/performance/sqlProvider/OrderChildSqlProvider.java
浏览文件 @
0e0c0c80
...
@@ -271,7 +271,7 @@ public class OrderChildSqlProvider {
...
@@ -271,7 +271,7 @@ public class OrderChildSqlProvider {
StringJoiner
sj
=
new
StringJoiner
(
","
,
"order_goods_no in ("
,
")"
);
StringJoiner
sj
=
new
StringJoiner
(
","
,
"order_goods_no in ("
,
")"
);
orderGoodsList
.
forEach
(
item
->
sj
.
add
(
"'"
+
item
+
"'"
));
orderGoodsList
.
forEach
(
item
->
sj
.
add
(
"'"
+
item
+
"'"
));
WHERE
(
sj
.
toString
());
WHERE
(
sj
.
toString
());
WHERE
(
"
a.
status < "
+
OrderChildEnum
.
Status
.
DRIVER_CANCEL
.
getCode
());
WHERE
(
"
status < "
+
OrderChildEnum
.
Status
.
DRIVER_CANCEL
.
getCode
());
GROUP_BY
(
" order_goods_no"
);
GROUP_BY
(
" order_goods_no"
);
}}.
toString
();
}}.
toString
();
}
}
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论