|
|
|
@ -1,6 +1,8 @@ |
|
|
|
|
package com.dxhy.order.consumer.modules.commodity.service.impl; |
|
|
|
|
|
|
|
|
|
import com.dxhy.order.baseservice.module.commodity.dao.GroupCommodityMapper; |
|
|
|
|
import com.dxhy.order.baseservice.module.thirdservice.user.service.UserInfoService; |
|
|
|
|
import com.dxhy.order.constant.TaxClassCodeEnum; |
|
|
|
|
import com.dxhy.order.consumer.dao.GroupCommodityCodeMapper; |
|
|
|
|
import com.dxhy.order.consumer.modules.commodity.domain.dto.CloneCompanyCommodityDTO; |
|
|
|
|
import com.dxhy.order.consumer.modules.commodity.domain.dto.CloneCompanyCommodityDetailDTO; |
|
|
|
@ -13,6 +15,8 @@ import org.springframework.stereotype.Service; |
|
|
|
|
import org.springframework.transaction.annotation.Transactional; |
|
|
|
|
import org.springframework.transaction.interceptor.TransactionAspectSupport; |
|
|
|
|
|
|
|
|
|
import javax.annotation.Resource; |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* @Description |
|
|
|
|
* @Author 巩权林 |
|
|
|
@ -23,6 +27,8 @@ public class CompanyCommodityCodeServiceImpl implements ICompanyCommodityCodeSer |
|
|
|
|
|
|
|
|
|
@Autowired |
|
|
|
|
private GroupCommodityCodeMapper groupCommodityMapper; |
|
|
|
|
@Resource |
|
|
|
|
private UserInfoService userInfoService; |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* 克隆物料 |
|
|
|
@ -38,6 +44,9 @@ public class CompanyCommodityCodeServiceImpl implements ICompanyCommodityCodeSer |
|
|
|
|
ValidateUtils.validate(to); |
|
|
|
|
ValidateUtils.validate(from); |
|
|
|
|
|
|
|
|
|
from.setUserId(userInfoService.getUser() != null&&userInfoService.getUser().getUserId()!= null?userInfoService.getUser().getUserId().toString():"clone"); |
|
|
|
|
from.setDataSource(TaxClassCodeEnum.DATA_SOURCE_10.getKey()); |
|
|
|
|
|
|
|
|
|
// 删除to公司下的所有物料
|
|
|
|
|
groupCommodityMapper.deleteCommodityCodeByXhfNsrsbh(to); |
|
|
|
|
|
|
|
|
|