|
|
@@ -6,6 +6,7 @@ import java.util.*;
|
|
|
|
|
|
import cn.hutool.core.bean.BeanUtil;
|
|
|
import cn.hutool.core.date.DateTime;
|
|
|
+import cn.hutool.core.util.ObjectUtil;
|
|
|
import cn.hutool.json.JSONUtil;
|
|
|
import com.fs.common.core.domain.R;
|
|
|
import com.fs.common.exception.CustomException;
|
|
|
@@ -49,6 +50,7 @@ import com.fs.store.service.IFsStoreAfterSalesService;
|
|
|
import com.fs.store.service.IFsUserService;
|
|
|
import com.fs.system.config.SnowflakeUtils;
|
|
|
import com.fs.system.service.ISysConfigService;
|
|
|
+import org.apache.http.util.Asserts;
|
|
|
import org.springframework.aop.framework.AopContext;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.beans.factory.annotation.Qualifier;
|
|
|
@@ -239,10 +241,15 @@ public class LiveAfterSalesServiceImpl implements ILiveAfterSalesService {
|
|
|
return R.ok("操作成功");
|
|
|
}
|
|
|
|
|
|
+ @Autowired
|
|
|
+ private ILiveAfterSalesService liveAfterSalesService;
|
|
|
@Override
|
|
|
public R refundMoney(LiveAfterSalesRefundParam param) {
|
|
|
- ILiveOrderService liveOrderService1 = (ILiveOrderService) AopContext.currentProxy();
|
|
|
- return liveOrderService1.refundOrderMoney(param.getOrderId());
|
|
|
+ LiveAfterSales liveAfterSales = liveAfterSalesService.selectLiveAfterSalesById(param.getSalesId());
|
|
|
+ if(ObjectUtil.isNull(liveAfterSales)) {
|
|
|
+ throw new IllegalArgumentException("售后单不存在!");
|
|
|
+ }
|
|
|
+ return liveOrderService.refundOrderMoney(liveAfterSales.getOrderId());
|
|
|
}
|
|
|
|
|
|
/**
|