|
|
|
@ -1,10 +1,10 @@
|
|
|
|
|
package com.glxp.api.service.basic.impl;
|
|
|
|
|
|
|
|
|
|
import cn.hutool.core.collection.CollUtil;
|
|
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
|
|
|
import com.github.pagehelper.PageHelper;
|
|
|
|
|
import com.glxp.api.dao.basic.BasicBusTypePreDao;
|
|
|
|
|
import com.glxp.api.entity.basic.BasicBusTypePreEntity;
|
|
|
|
|
import com.glxp.api.entity.inout.IoCodeEntity;
|
|
|
|
|
import com.glxp.api.req.basic.FilterBusTypeChangeRequest;
|
|
|
|
|
import com.glxp.api.req.basic.FilterBusTypePreRequest;
|
|
|
|
|
import com.glxp.api.res.basic.BasicBusTypePreResponse;
|
|
|
|
@ -80,6 +80,29 @@ public class BasicBusTypePreServiceImpl implements IBasicBusTypePreService {
|
|
|
|
|
return basicBusTypePreDao.selectOne(new QueryWrapper<BasicBusTypePreEntity>().eq("originAction", originAction));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
|
public boolean checkExists(BasicBusTypePreEntity basicBusTypePreEntity) {
|
|
|
|
|
QueryWrapper<BasicBusTypePreEntity> wrapper = new QueryWrapper<>();
|
|
|
|
|
wrapper.eq("action", basicBusTypePreEntity.getAction())
|
|
|
|
|
.eq("originAction", basicBusTypePreEntity.getOriginAction())
|
|
|
|
|
.eq("invCode", basicBusTypePreEntity.getInvCode())
|
|
|
|
|
.eq(null != basicBusTypePreEntity.getBeforeTime(), "beforeTime", basicBusTypePreEntity.getBeforeTime())
|
|
|
|
|
.eq(null != basicBusTypePreEntity.getDefaultInvCode(), "defaultInvCode", basicBusTypePreEntity.getDefaultInvCode())
|
|
|
|
|
.eq(null != basicBusTypePreEntity.getSupplementAll(), "supplementAll", basicBusTypePreEntity.getSupplementAll());
|
|
|
|
|
|
|
|
|
|
List<BasicBusTypePreEntity> list = basicBusTypePreDao.selectList(wrapper);
|
|
|
|
|
if (CollUtil.isNotEmpty(list)) {
|
|
|
|
|
if (null != basicBusTypePreEntity.getId()) {
|
|
|
|
|
for (BasicBusTypePreEntity busTypePreEntity : list) {
|
|
|
|
|
return busTypePreEntity.getId() == basicBusTypePreEntity.getId() ? false : true;
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 设置创建/更新信息
|
|
|
|
|
*
|
|
|
|
|