refactor(小型刀具库同步方法): 注入优化,方法名修改
This commit is contained in:
parent
1626935c8d
commit
a70e8f4c9b
@ -3,12 +3,14 @@ package com.ktg.mes.md.mapper;
|
||||
import com.ktg.common.annotation.DataSource;
|
||||
import com.ktg.common.enums.DataSourceType;
|
||||
import com.ktg.mes.md.domain.AP0AE;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author Kelvin
|
||||
*/
|
||||
@Mapper
|
||||
public interface AP0AEMapper {
|
||||
@DataSource(DataSourceType.SQLSERVER)
|
||||
List<AP0AE> selectOutNewData();
|
||||
|
@ -8,8 +8,16 @@ import java.util.List;
|
||||
* @author luo26
|
||||
*/
|
||||
public interface IAP0AEService {
|
||||
public List<AP0AE> selectOutNewData();
|
||||
|
||||
/**
|
||||
* 获取借用记录
|
||||
* @return 借用记录列表
|
||||
*/
|
||||
public List<AP0AE> selectBorrowedNewData();
|
||||
|
||||
public List<AP0AE> selectInNewData();
|
||||
/**
|
||||
* 获取归还记录
|
||||
* @return 归还记录列表
|
||||
*/
|
||||
public List<AP0AE> selectReturnedNewData();
|
||||
}
|
||||
|
@ -15,6 +15,7 @@ import com.ktg.mes.wm.domain.WmsInTask;
|
||||
import com.ktg.mes.wm.service.IWmStorageAreaService;
|
||||
import com.ktg.mes.wm.service.IWmsInPlanService;
|
||||
import com.ktg.mes.wm.service.IWmsInTaskService;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@ -29,29 +30,21 @@ import java.util.List;
|
||||
* @author Kelvin
|
||||
*/
|
||||
@Service
|
||||
@RequiredArgsConstructor
|
||||
public class AP0AEServiceImpl implements IAP0AEService {
|
||||
@Autowired
|
||||
private AP0AEMapper aP0AEMapper;
|
||||
|
||||
@Autowired
|
||||
private IWmsInPlanService wmsInPlanService;
|
||||
|
||||
@Autowired
|
||||
private IWmsInTaskService wmsInTaskService;
|
||||
|
||||
@Autowired
|
||||
private IWmStorageAreaService wmStorageAreaService;
|
||||
|
||||
@Autowired
|
||||
private IMdItemService mdItemService;
|
||||
private final AP0AEMapper aP0AEMapper;
|
||||
private final IWmsInPlanService wmsInPlanService;
|
||||
private final IWmsInTaskService wmsInTaskService;
|
||||
private final IWmStorageAreaService wmStorageAreaService;
|
||||
private final IMdItemService mdItemService;
|
||||
|
||||
@Override
|
||||
public List<AP0AE> selectOutNewData() {
|
||||
public List<AP0AE> selectBorrowedNewData() {
|
||||
return this.aP0AEMapper.selectOutNewData();
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<AP0AE> selectInNewData() {
|
||||
public List<AP0AE> selectReturnedNewData() {
|
||||
List<AP0AE> ap0aeList = aP0AEMapper.selectInNewData();
|
||||
ap0aeList.stream().filter(ap0ae -> ap0ae.getAE003() != null).forEach(ap0ae -> {
|
||||
WmsInPlan wmsInPlan = new WmsInPlan();
|
||||
|
Loading…
Reference in New Issue
Block a user