|
|
@@ -4,9 +4,11 @@ import com.alibaba.csp.sentinel.log.Logger;
|
|
|
import com.alibaba.fastjson.JSONObject;
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
|
|
+import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
|
|
import com.huyi.service.base.entity.SysCompany;
|
|
|
import com.huyi.service.base.entity.ZcChargeInf;
|
|
|
import com.huyi.service.base.entity.ZcInvoiceAddress;
|
|
|
+import com.huyi.service.base.mapper.ZcChargeInfMapper;
|
|
|
import com.huyi.service.base.service.ISysCompanyService;
|
|
|
import com.huyi.service.base.service.IZcChargeInfService;
|
|
|
import com.huyi.service.base.service.IZcInvoiceAddressService;
|
|
|
@@ -67,6 +69,9 @@ public class OwnCostManageController extends BaseController
|
|
|
@Autowired
|
|
|
private IZcChargeInfService iZcChargeInfService;
|
|
|
|
|
|
+ @Autowired
|
|
|
+ private ZcChargeInfMapper zcChargeInfMapper;
|
|
|
+
|
|
|
|
|
|
@Autowired
|
|
|
private TokenService tokenService;
|
|
|
@@ -338,14 +343,6 @@ public R list(String zfrNumber, String zciStatus, String zciInvoiceStatus,
|
|
|
}
|
|
|
//快递单号
|
|
|
String zciExpressNo = CommonUtil.objToString(map.get("zciExpressNo"));
|
|
|
- //判断开票或冲红
|
|
|
- if(CommonUtil.isNotEmpty(zciInvoiceStatus)){
|
|
|
- if("2".equals(zciInvoiceStatus) || "4".equals(zciInvoiceStatus)) {
|
|
|
- if (CommonUtil.isEmpty(zciExpressNo)) {
|
|
|
- throw new Exception("快递单号不能为空");
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
|
|
|
if(CommonUtil.isNotEmpty(zciExpressNo)){
|
|
|
//快递单号正则校验
|
|
|
@@ -364,6 +361,14 @@ public R list(String zfrNumber, String zciStatus, String zciInvoiceStatus,
|
|
|
//快递单号
|
|
|
if(CommonUtil.isNotEmpty(zciExpressNo)) {
|
|
|
zcChargeInf.setZciExpressNo(zciExpressNo);
|
|
|
+ }else
|
|
|
+ if(CommonUtil.isEmpty(zciExpressNo)){
|
|
|
+ zcChargeInfMapper.update(
|
|
|
+ null,
|
|
|
+ Wrappers.<ZcChargeInf>lambdaUpdate()
|
|
|
+ .set(ZcChargeInf::getZciExpressNo, null) //把email设置成null
|
|
|
+ .eq(ZcChargeInf::getZciId, zciId)
|
|
|
+ );
|
|
|
}
|
|
|
//开票状态
|
|
|
if(CommonUtil.isNotEmpty(zciInvoiceStatus)) {
|