This commit is contained in:
cb 2025-05-22 20:53:55 +08:00
parent ef23b61265
commit 71bb414f23
3 changed files with 10 additions and 2 deletions

View File

@ -532,8 +532,10 @@ public class OrderController extends BaseController {
Set<Long> goodsStandardIds = appGoodsList.stream().map(AppGoodsRequest::getGoodsStandardId).collect(Collectors.toSet());
// 所有商品
List<GoodsStandard> goodsList = goodsStandardService.selectByIds(goodsStandardIds);
logger.info("商品信息{}", goodsList);
// 商品所属师傅
Goods goods = goodsService.selectById(goodsList.get(0).getGoodsId());
logger.info("下单后的师傅信息{}", goods);
// 师傅信息
Worker worker = workerService.selectById(goods.getWorkerId());
// 商户ID

View File

@ -473,9 +473,12 @@ public class OrderDetailController extends BaseController {
param1.setFinancialChangeRecordId(financialChangeRecord.getId());
BigDecimal attachmentMoney= BigDecimal.ZERO;
List<OrderAttachmentRecord> orderAttachmentRecords=orderAttachmentRecordService.selectOrderAttachmentRecordList(param1);
if(orderAttachmentRecords!=null&&orderAttachmentRecords.size()>0){
attachmentMoney.add(orderAttachmentRecords.get(0).getAttachMoney());
financialChangeRecord.setAttachmentMoney(attachmentMoney);
}
}
for (OrderAttachmentRecord orderAttachmentRecord:orderAttachmentRecordList){
addMoneyTotal= addMoneyTotal.add(orderAttachmentRecord.getAttachMoney());
}

View File

@ -41,12 +41,14 @@
<if test="orderMasterId != null">order_master_id,</if>
<if test="type != null">type,</if>
<if test="attachMoney != null">attach_money,</if>
<if test="financialChangeRecordId != null">financial_change_record_id,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="orderDetailId != null">#{orderDetailId},</if>
<if test="orderMasterId != null">#{orderMasterId},</if>
<if test="type != null">#{type},</if>
<if test="attachMoney != null">#{attachMoney},</if>
<if test="financialChangeRecordId != null">#{financial_change_record_id},</if>
</trim>
</insert>
@ -58,6 +60,7 @@
<if test="type != null">type = #{type},</if>
<if test="attachMoney != null">attach_money = #{attachMoney},</if>
<if test="paymentId != null">payment_id = #{paymentId},</if>
<if test="financialChangeRecordId != null">financial_change_record_id=#{financialChangeRecordId},</if>
</trim>
where id = #{id}
</update>