|
|
|
@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
|
|
|
import com.gaotao.common.constant.SysMsgConstant; |
|
|
|
import com.gaotao.common.utils.Constant; |
|
|
|
import com.gaotao.modules.customer.entity.Customer; |
|
|
|
import com.gaotao.modules.customer.mapper.CustomerMapper; |
|
|
|
import com.gaotao.modules.customer.service.CustomerService; |
|
|
|
import com.gaotao.modules.label.entity.LabelFormatCustomer; |
|
|
|
import com.gaotao.modules.label.mapper.LabelFormatCustomerMapper; |
|
|
|
@ -22,7 +23,7 @@ public class LabelFormatCustomerServiceImpl extends ServiceImpl<LabelFormatCusto |
|
|
|
private SysMsgService sysMsgService; |
|
|
|
|
|
|
|
@Autowired |
|
|
|
private CustomerService customerService; |
|
|
|
private CustomerMapper customerMapper; |
|
|
|
@Override |
|
|
|
public List<LabelFormatCustomer> selectLabelFormatCustomerList(LabelFormatCustomer labelFormatCustomer) { |
|
|
|
return baseMapper.selectLabelFormatCustomerList(labelFormatCustomer); |
|
|
|
@ -64,12 +65,7 @@ public class LabelFormatCustomerServiceImpl extends ServiceImpl<LabelFormatCusto |
|
|
|
|
|
|
|
|
|
|
|
private void customerExists(String customerNo,String customerName,String site){ |
|
|
|
List<Customer> list = customerService.lambdaQuery() |
|
|
|
.eq(Customer::getCustomerNo, customerNo) |
|
|
|
.eq(Customer::getSite, site) |
|
|
|
.eq(Customer::getCustomerName, customerName) |
|
|
|
.eq(Customer::getActive, Constant.ACTIVE) |
|
|
|
.list(); |
|
|
|
List<Customer> list = customerMapper.queryCustomer(customerNo, customerName, site,Constant.ACTIVE); |
|
|
|
if (list.isEmpty()) { |
|
|
|
throw new RuntimeException(sysMsgService.getLanguageMsg(SysMsgConstant.MSG_CUSTOMER_NOT_EXISTS)); |
|
|
|
} |
|
|
|
|