修改sql
This commit is contained in:
@ -110,4 +110,5 @@ public interface CardMapper extends BaseMapperX<CardDO> {
|
|||||||
.reduce(BigDecimal.ZERO, BigDecimal::add);
|
.reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int udpateEXit(@Param("orderIds") Collection<Long> orderIds,@Param("exit") Integer exit,@Param("num")String num);
|
||||||
}
|
}
|
@ -389,10 +389,7 @@ public class BillingServiceImpl implements BillingService {
|
|||||||
//设置同意人
|
//设置同意人
|
||||||
updateObj.setSystemId(SecurityFrameworkUtils.getLoginUserId());
|
updateObj.setSystemId(SecurityFrameworkUtils.getLoginUserId());
|
||||||
//拒绝就把锁住的订单释放掉
|
//拒绝就把锁住的订单释放掉
|
||||||
LambdaUpdateWrapper<CardDO> wrapper = new LambdaUpdateWrapper<>();
|
cardMapper.udpateEXit(orderIds,BillingStatusEnum.BILLING_INVOICING_IS_COMPLETE.getCode(),null);
|
||||||
wrapper.in(CardDO::getId, orderIds);
|
|
||||||
wrapper.set(CardDO::getBillingExist, BillingStatusEnum.BILLING_INVOICING_IS_COMPLETE.getCode());
|
|
||||||
cardMapper.update(null, wrapper);
|
|
||||||
}else{
|
}else{
|
||||||
//开票回拒
|
//开票回拒
|
||||||
if(StrUtil.isBlank(updateObj.getRefuseDetails())){
|
if(StrUtil.isBlank(updateObj.getRefuseDetails())){
|
||||||
@ -401,11 +398,7 @@ public class BillingServiceImpl implements BillingService {
|
|||||||
updateObj.setStatus(BillingStatusEnum.BILLING_INVOICING_REJECTION.getCode());
|
updateObj.setStatus(BillingStatusEnum.BILLING_INVOICING_REJECTION.getCode());
|
||||||
updateObj.setRefuseTime(LocalDateTime.now());
|
updateObj.setRefuseTime(LocalDateTime.now());
|
||||||
//拒绝就把锁住的订单释放掉
|
//拒绝就把锁住的订单释放掉
|
||||||
LambdaUpdateWrapper<CardDO> wrapper = new LambdaUpdateWrapper<>();
|
cardMapper.udpateEXit(orderIds,BillingStatusEnum.BILLING_INVOICING_REJECTION.getCode(),"true");
|
||||||
wrapper.in(CardDO::getId, orderIds);
|
|
||||||
wrapper.set(CardDO::getBillingExist, BillingStatusEnum.BILLING_INVOICING_REJECTION.getCode());
|
|
||||||
wrapper.set(CardDO::getBillingNum,null);
|
|
||||||
cardMapper.update(null, wrapper);
|
|
||||||
}
|
}
|
||||||
billingMapper.updateById(updateObj);
|
billingMapper.updateById(updateObj);
|
||||||
}
|
}
|
||||||
|
@ -30,4 +30,16 @@
|
|||||||
select * from user_face where user_id = #{faceId};
|
select * from user_face where user_id = #{faceId};
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<update id="udpateEXit">
|
||||||
|
UPDATE member_card
|
||||||
|
SET billing_exist = #{exit}
|
||||||
|
<if test="num != null and num != ''">
|
||||||
|
, billing_num = NULL
|
||||||
|
</if>
|
||||||
|
WHERE user_id IN
|
||||||
|
<foreach collection="orderIds" item="id" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</update>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
Reference in New Issue
Block a user