buhuazhen
7 天以前 a0c9adb1e44f502c0473e9aafb7545981173b130
src/main/java/com/ruoyi/basic/service/impl/CustomerServiceImpl.java
@@ -29,6 +29,7 @@
import com.ruoyi.sales.pojo.SalesLedger;
import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.aop.framework.AopContext;
import org.springframework.beans.BeanUtils;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
@@ -256,7 +257,11 @@
            if (CollectionUtils.isEmpty(userList)) {
                return AjaxResult.warn("模板错误或导入数据为空");
            }
            this.saveOrUpdateBatch(userList);
            ICustomerService proxy = (ICustomerService) AopContext.currentProxy();
            for (Customer customer : userList) {
                proxy.insertCustomer(customer);
            }
//            this.saveOrUpdateBatch(userList);
            return AjaxResult.success(true);
        } catch (Exception e) {
            e.printStackTrace();