From 02e2819ec171b99e216434a7911c63b795d051bf Mon Sep 17 00:00:00 2001 From: anthonywj Date: Tue, 16 May 2023 09:29:52 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8E=BB=E9=99=A4=E6=97=A0=E7=94=A8=E5=9F=BA?= =?UTF-8?q?=E7=A1=80=E4=BF=A1=E6=81=AF=E7=9B=B8=E5=85=B3=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/basic/UdiSyncController.java | 62 +- .../dao/basic/CompanyProductRelevanceDao.java | 23 - .../com/glxp/api/dao/basic/UdiProductDao.java | 87 -- .../glxp/api/dao/basic/UdiRelevanceDao.java | 121 -- .../com/glxp/api/dao/basic/UdiRlSupDao.java | 54 - .../basic/CompanyProductRelevanceService.java | 22 - .../api/service/basic/UdiProductService.java | 63 - .../service/basic/UdiRelevanceService.java | 105 -- .../CompanyProductRelevanceServiceImpl.java | 62 - .../basic/impl/UdiProductServiceImpl.java | 158 --- .../basic/impl/UdiRelevanceServiceImpl.java | 405 ------ .../basic/CompanyProductRelevanceDao.xml | 226 --- .../mybatis/mapper/basic/UdiProductDao.xml | 964 ------------- .../mybatis/mapper/basic/UdiRelevanceDao.xml | 1253 ----------------- .../mybatis/mapper/basic/UdiRlSupDao.xml | 369 ----- 15 files changed, 16 insertions(+), 3958 deletions(-) delete mode 100644 src/main/java/com/glxp/api/dao/basic/CompanyProductRelevanceDao.java delete mode 100644 src/main/java/com/glxp/api/dao/basic/UdiProductDao.java delete mode 100644 src/main/java/com/glxp/api/dao/basic/UdiRelevanceDao.java delete mode 100644 src/main/java/com/glxp/api/dao/basic/UdiRlSupDao.java delete mode 100644 src/main/java/com/glxp/api/service/basic/CompanyProductRelevanceService.java delete mode 100644 src/main/java/com/glxp/api/service/basic/UdiProductService.java delete mode 100644 src/main/java/com/glxp/api/service/basic/UdiRelevanceService.java delete mode 100644 src/main/java/com/glxp/api/service/basic/impl/CompanyProductRelevanceServiceImpl.java delete mode 100644 src/main/java/com/glxp/api/service/basic/impl/UdiProductServiceImpl.java delete mode 100644 src/main/java/com/glxp/api/service/basic/impl/UdiRelevanceServiceImpl.java delete mode 100644 src/main/resources/mybatis/mapper/basic/CompanyProductRelevanceDao.xml delete mode 100644 src/main/resources/mybatis/mapper/basic/UdiProductDao.xml delete mode 100644 src/main/resources/mybatis/mapper/basic/UdiRelevanceDao.xml delete mode 100644 src/main/resources/mybatis/mapper/basic/UdiRlSupDao.xml diff --git a/src/main/java/com/glxp/api/controller/basic/UdiSyncController.java b/src/main/java/com/glxp/api/controller/basic/UdiSyncController.java index 4d39831..3302e85 100644 --- a/src/main/java/com/glxp/api/controller/basic/UdiSyncController.java +++ b/src/main/java/com/glxp/api/controller/basic/UdiSyncController.java @@ -25,8 +25,6 @@ import com.glxp.api.res.PageSimpleResponse; import com.glxp.api.service.basic.ProductInfoService; import com.glxp.api.service.basic.SyncUdiService; import com.glxp.api.service.basic.UdiCompanyService; -import com.glxp.api.service.basic.UdiProductService; -import com.glxp.api.service.basic.UdiRelevanceService; import com.glxp.api.util.udi.FilterUdiUtils; import cn.hutool.core.util.StrUtil; @@ -39,10 +37,6 @@ import lombok.extern.slf4j.Slf4j; @RestController public class UdiSyncController { - @Resource - UdiRelevanceService udiRelevanceService; - @Resource - UdiProductService udiProductService; @Resource SyncUdiService syncUdiService; @Resource @@ -82,22 +76,22 @@ public class UdiSyncController { List productInfoEntities = udiDlDeviceResponse.getData().getList(); if (productInfoEntities != null && productInfoEntities.size() > 0) { for (ProductInfoEntity productInfoEntity : productInfoEntities) { - List udiRelevanceEntities = udiRelevanceService.selectByUuid(productInfoEntity.getUuid()); - if (udiRelevanceEntities != null && udiRelevanceEntities.size() > 0) { - for (UdiRelevanceEntity udiRelevanceEntity : udiRelevanceEntities) { - if (udiRelevanceEntity.getThirdId() == null && - udiRelevanceEntity.getThirdId2() == null && udiRelevanceEntity.getThirdId1() == null && - udiRelevanceEntity.getThirdId3() == null && udiRelevanceEntity.getThirdId4() == null) { - //不能添加 - productInfoEntity.setCheck(true); - break; - } else - productInfoEntity.setCheck(false); - } - - } else { - productInfoEntity.setCheck(false); - } +// List udiRelevanceEntities = udiRelevanceService.selectByUuid(productInfoEntity.getUuid()); +// if (udiRelevanceEntities != null && udiRelevanceEntities.size() > 0) { +// for (UdiRelevanceEntity udiRelevanceEntity : udiRelevanceEntities) { +// if (udiRelevanceEntity.getThirdId() == null && +// udiRelevanceEntity.getThirdId2() == null && udiRelevanceEntity.getThirdId1() == null && +// udiRelevanceEntity.getThirdId3() == null && udiRelevanceEntity.getThirdId4() == null) { +// //不能添加 +// productInfoEntity.setCheck(true); +// break; +// } else +// productInfoEntity.setCheck(false); +// } +// +// } else { +// productInfoEntity.setCheck(false); +// } } } } @@ -124,30 +118,6 @@ public class UdiSyncController { } } - - - @AuthRuleAnnotation("") - @GetMapping("/udiwms/basic/instrument/maintain/filterProduct") - public BaseResponse filterProduct(FilterUdiRelRequest filterUdiRelRequest) { - List udiInfoEntities - = udiProductService.filterAllUdiInfo(filterUdiRelRequest); - PageInfo pageInfo; - pageInfo = new PageInfo<>(udiInfoEntities); - PageSimpleResponse pageSimpleResponse = new PageSimpleResponse<>(); - pageSimpleResponse.setTotal(pageInfo.getTotal()); - pageSimpleResponse.setList(udiInfoEntities); - return ResultVOUtils.success(pageSimpleResponse); - } - - @AuthRuleAnnotation("") - @GetMapping("/udiwms/basic/findByCode") - public BaseResponse findByCode(FilterUdiRelRequest filterUdiRelRequest) { - - UdiEntity udiEntity = FilterUdiUtils.getUdi(filterUdiRelRequest.getUdiCode()); - UdiProductEntity udiProductEntity - = udiProductService.findByNameCode(udiEntity.getUdi()); - return ResultVOUtils.success(udiProductEntity); - } //出入库同步下载 diff --git a/src/main/java/com/glxp/api/dao/basic/CompanyProductRelevanceDao.java b/src/main/java/com/glxp/api/dao/basic/CompanyProductRelevanceDao.java deleted file mode 100644 index 091c4de..0000000 --- a/src/main/java/com/glxp/api/dao/basic/CompanyProductRelevanceDao.java +++ /dev/null @@ -1,23 +0,0 @@ -package com.glxp.api.dao.basic; - -import com.glxp.api.dao.BaseMapperPlus; -import com.glxp.api.entity.basic.BasicProductsEntity; -import com.glxp.api.entity.basic.CompanyProductRelevanceEntity; -import com.glxp.api.req.basic.CompanyProductRelevanceRequest; -import com.glxp.api.res.basic.CompanyProductRelevanceResponse; -import org.apache.ibatis.annotations.Mapper; - -import java.util.List; - -@Mapper -public interface CompanyProductRelevanceDao extends BaseMapperPlus { - List filterUdiGp(CompanyProductRelevanceRequest basicInstrumentMaintainRequest); - - boolean insertCompanyProductRelevance(CompanyProductRelevanceEntity companyCertEntity); - - boolean importCompanyProductRelevance(CompanyProductRelevanceEntity companyProductRelevanceEntity); - - boolean deleteById(String id); - - boolean deleteByRlId(String id); -} diff --git a/src/main/java/com/glxp/api/dao/basic/UdiProductDao.java b/src/main/java/com/glxp/api/dao/basic/UdiProductDao.java deleted file mode 100644 index cca4b94..0000000 --- a/src/main/java/com/glxp/api/dao/basic/UdiProductDao.java +++ /dev/null @@ -1,87 +0,0 @@ -package com.glxp.api.dao.basic; - -import com.glxp.api.entity.basic.UdiProductEntity; -import com.glxp.api.req.basic.FilterUdiRelRequest; -import com.glxp.api.req.basic.UdiInfoRequest; -import com.glxp.api.res.basic.UdiRelevanceResponse; -import org.apache.ibatis.annotations.Mapper; -import org.apache.ibatis.annotations.Param; - -import java.util.List; - -@Mapper -public interface UdiProductDao { - - List filterUdiInfo(FilterUdiRelRequest filterUdiRelRequest); - - UdiProductEntity findByNameCode(@Param("nameCode") String nameCode); - - UdiProductEntity findByUuid(@Param("uuid") String uuid); - - List findByUuids(@Param("uuid") String uuid); - - UdiProductEntity findById(@Param("id") String id); - - boolean insertUdiInfo(UdiProductEntity udiProductEntity); - - boolean insertUdiInfos(@Param("udiInfoEntities") List udiInfoEntities); - - /** - * 根据nameCode更新产品信息 - */ - boolean updateUdiInfo(UdiProductEntity udiProductEntity); - - /** - * 根据UUID更新产品信息 - */ - boolean updateUdiInfoByUuid(UdiProductEntity udiProductEntity); - - /** - * 根据ID更新产品信息 - */ - boolean updateUdiInfoById(UdiProductEntity udiProductEntity); - - boolean deleteById(@Param("id") String id); - - boolean deleteByUuid(@Param("uuid") String uuid); - - /** - * 根据UUID批量查询数据 - */ - List batchSelectByUuid(@Param("uuids") List uuids); - - - List filterUdiInfo2(FilterUdiRelRequest filterUdiRelRequest); - - - /** - * 导入医疗器械信息 - */ - void importUdiInfo(@Param("udiInfoEntities") List udiInfoEntities); - - /** - * 查询包装层级 - * - * @param nameCode - * @return - */ - Integer selectPackLevel(@Param("nameCode") String nameCode); - - /** - * 查询产品规格型号列表 - * - * @param relId - * @return - */ - List selectGgxhList(@Param("relId") String relId); - - boolean updateUdiInfoNotAll(UdiInfoRequest udiInfoRequest); - - /** - * 根据DI查询此产品是否允许无批次号参数 - * - * @param nameCode - * @return - */ - UdiProductEntity selectAllowNoBatch(@Param("nameCode") String nameCode); -} diff --git a/src/main/java/com/glxp/api/dao/basic/UdiRelevanceDao.java b/src/main/java/com/glxp/api/dao/basic/UdiRelevanceDao.java deleted file mode 100644 index e9193b0..0000000 --- a/src/main/java/com/glxp/api/dao/basic/UdiRelevanceDao.java +++ /dev/null @@ -1,121 +0,0 @@ -package com.glxp.api.dao.basic; - -import com.glxp.api.dao.BaseMapperPlus; -import com.glxp.api.entity.basic.UdiRelevanceEntity; -import com.glxp.api.req.basic.FilterUdiRelRequest; -import com.glxp.api.res.basic.UdiRelevanceResponse; -import org.apache.ibatis.annotations.Mapper; -import org.apache.ibatis.annotations.Param; - -import java.util.List; - -@Mapper -public interface UdiRelevanceDao extends BaseMapperPlus { - - List filterUdiRelevance(FilterUdiRelRequest filterUdiRelRequest); - - - List filterUdiJoinSup(FilterUdiRelRequest filterUdiRelRequest); - - List filterCertUdi(FilterUdiRelRequest filterUdiRelRequest); - - List filterUdiGp(FilterUdiRelRequest filterUdiRelRequest); - - // UdiRelevanceResponse selectUdiByUUid - List selectByUuid(@Param("uuid") String uuid); - - - List contrastJoinSelect(FilterUdiRelRequest filterUdiRelRequest); - - - UdiRelevanceEntity selectById(@Param("id") Long id); - - UdiRelevanceEntity selectByThirdId(FilterUdiRelRequest filterUdiRelRequest); - - List filterEntity(FilterUdiRelRequest filterUdiRelRequest); - - - boolean insertUdiRelevance(UdiRelevanceEntity udiRelevanceEntity); - - boolean insertUdiRelevanceignore(UdiRelevanceEntity udiRelevanceEntity); - - boolean updateUdiRelevance(UdiRelevanceEntity udiRelevanceEntity); - - boolean deleteById(@Param("id") String id); - - boolean deleteByIds(@Param("ids") List id); - - boolean deleteByUuid(@Param("uuid") String uuid); - - /** - * 根据UUID批量查询信息 - * - * @param uuids - * @return - */ - List batchSelectByUuid(@Param("uuids") List uuids); - - - List batchSelectByIds(@Param("ids") List ids); - - /** - * 批量导入数据 - * - * @param udiRelevanceEntities - */ - void importUdiRelevance(@Param("udiRelevanceEntities") List udiRelevanceEntities); - - /** - * /** - * 查找产品UUID - * - * @param relId - * @return - */ - String selectUuidById(@Param("relId") String relId); - - - List selectGroupByNameCode(@Param("nameCode") String nameCode, @Param("isDisable") Boolean isDisable); - - /** - * 根据耗材字典ID查询产品名称 - * - * @param relId - * @return - */ - String selectProductNameByRelId(@Param("relId") Long relId); - - /** - * 查询预警参数 - * - * @param relId - * @return - */ - UdiRelevanceEntity selectRemindParams(@Param("relId") Long relId); - - Boolean updateBatchById(@Param("list") List list); - - /** - * 根据院内分类编码查询 - * - * @param relCode - * @return - */ - Long selectProductByRelCode(@Param("relCode") String relCode); - - /** - * 根据DI查找此产品的id - * - * @param nameCode - * @return - */ - String selectRelIdByNameCode(@Param("nameCode") String nameCode); - - /** - * 查询一条产品信息数据 - * - * @param filterUdiRelRequest - * @return - */ - UdiRelevanceResponse selectOneUdiJoinSup(FilterUdiRelRequest filterUdiRelRequest); -} diff --git a/src/main/java/com/glxp/api/dao/basic/UdiRlSupDao.java b/src/main/java/com/glxp/api/dao/basic/UdiRlSupDao.java deleted file mode 100644 index e7ed0d6..0000000 --- a/src/main/java/com/glxp/api/dao/basic/UdiRlSupDao.java +++ /dev/null @@ -1,54 +0,0 @@ -package com.glxp.api.dao.basic; - -import com.glxp.api.dao.BaseMapperPlus; -import com.glxp.api.entity.basic.UdiRlSupEntity; -import com.glxp.api.req.basic.CompanyProductRelevanceRequest; -import com.glxp.api.req.basic.FilterCompanyProductRelevanceRequest; -import com.glxp.api.res.basic.UdiRlSupResponse; -import org.apache.ibatis.annotations.Mapper; -import org.apache.ibatis.annotations.Param; - -import java.util.List; - -@Mapper -public interface UdiRlSupDao extends BaseMapperPlus { - - List filterUdiGp(CompanyProductRelevanceRequest basicInstrumentMaintainRequest); - - List filterCompanyProductRelevance(FilterCompanyProductRelevanceRequest filterCompanyProductRelevanceRequest); - - UdiRlSupEntity findCompanyProductRelevance(String CustomerId); - - UdiRlSupEntity findCompanyProductRelevanceByProductId(String productId); - - UdiRlSupEntity findCompanyProductRelevanceByUdiRlIdFk(@Param("udiRlIdFk") String udiRlIdFk, @Param("customerId") String customerId); - - UdiRlSupEntity findCompanyProductRelevanceByProductUuid(UdiRlSupEntity udiRlSupEntity); - - List getCompanyProductRelevance(FilterCompanyProductRelevanceRequest filterCompanyProductRelevanceRequest); - - - boolean insertCompanyProductRelevance(UdiRlSupEntity companyCertEntity); - - boolean importCompanyProductRelevance(UdiRlSupEntity udiRlSupEntity); - - boolean deleteById(String id); - - boolean deleteByRlId(String id); - - /** - * 根据耗材ID查询供应商ID列表 - * - * @param relId - * @return - */ - List selectUnitFkByRelId(@Param("relId") Long relId); - - /** - * 统计供应商配送产品数量 - * - * @param companyProductRelevanceRequest - * @return - */ - Long selectSupRlCount(CompanyProductRelevanceRequest companyProductRelevanceRequest); -} diff --git a/src/main/java/com/glxp/api/service/basic/CompanyProductRelevanceService.java b/src/main/java/com/glxp/api/service/basic/CompanyProductRelevanceService.java deleted file mode 100644 index ce04e36..0000000 --- a/src/main/java/com/glxp/api/service/basic/CompanyProductRelevanceService.java +++ /dev/null @@ -1,22 +0,0 @@ -package com.glxp.api.service.basic; - - -import com.baomidou.mybatisplus.extension.service.IService; -import com.glxp.api.entity.basic.CompanyProductRelevanceEntity; -import com.glxp.api.req.basic.CompanyProductRelevanceRequest; -import com.glxp.api.res.basic.CompanyProductRelevanceResponse; - -import java.util.List; - -public interface CompanyProductRelevanceService extends IService { - - List filterUdiGp(CompanyProductRelevanceRequest basicInstrumentMaintainRequest); - - boolean insertCompanyProductRelevance(CompanyProductRelevanceEntity companyCertEntity); - - boolean deleteById(String id); - - boolean deleteByRlId(String id); - - boolean isExitByRelId(String relId); -} diff --git a/src/main/java/com/glxp/api/service/basic/UdiProductService.java b/src/main/java/com/glxp/api/service/basic/UdiProductService.java deleted file mode 100644 index ee4ecdc..0000000 --- a/src/main/java/com/glxp/api/service/basic/UdiProductService.java +++ /dev/null @@ -1,63 +0,0 @@ -package com.glxp.api.service.basic; - -import com.glxp.api.entity.basic.UdiProductEntity; -import com.glxp.api.req.basic.FilterUdiRelRequest; -import com.glxp.api.req.basic.UdiInfoRequest; -import com.glxp.api.res.basic.UdiRelevanceResponse; -import org.apache.ibatis.annotations.Param; - -import java.util.List; - -/** - * 耗材字典-字典信息 - */ -public interface UdiProductService { - - List filterUdiInfo(FilterUdiRelRequest filterUdiRelRequest); - - UdiProductEntity findBySptm(String sptm); - - List filterUdiInfo2(FilterUdiRelRequest filterUdiRelRequest); - - List filterAllUdiInfo(FilterUdiRelRequest filterUdiRelRequest); - - UdiProductEntity findByNameCode(String nameCode); - - UdiProductEntity findById(@Param("id") String id); - - UdiProductEntity findByUuid(String uuid); - - List findByUuids(String uuid); - - boolean insertUdiInfo(UdiProductEntity udiProductEntity); - - boolean insertUdiInfos(List udiInfoEntities); - - boolean updateUdiInfo(UdiProductEntity udiProductEntity); - - boolean updateUdiInfoByUuid(UdiProductEntity udiProductEntity); - - boolean updateUdiInfoById(UdiProductEntity udiProductEntity); - - boolean deleteById(String id); - - boolean deleteByUuid(String uuid); - - /** - * 查询产品规格型号列表 - * - * @param relId - * @return - */ - List getGgxhList(String relId); - - boolean updateUdiInfoNotAll(UdiInfoRequest udiInfoRequest); - - /** - * 根据DI查询此产品是否允许无批次号 - * - * @param nameCode - * @return - */ - UdiProductEntity getAllowNoBatch(String nameCode); -} diff --git a/src/main/java/com/glxp/api/service/basic/UdiRelevanceService.java b/src/main/java/com/glxp/api/service/basic/UdiRelevanceService.java deleted file mode 100644 index decf0ac..0000000 --- a/src/main/java/com/glxp/api/service/basic/UdiRelevanceService.java +++ /dev/null @@ -1,105 +0,0 @@ -package com.glxp.api.service.basic; - - -import com.baomidou.mybatisplus.extension.service.IService; -import com.glxp.api.entity.basic.UdiRelevanceEntity; -import com.glxp.api.req.basic.FilterUdiRelRequest; -import com.glxp.api.res.basic.UdiRelevanceResponse; - -import java.util.List; - -/** - * 耗材字典关联 - */ -public interface UdiRelevanceService extends IService { - - List filterUdiRelevance(FilterUdiRelRequest filterUdiRelRequest); - - List filterCertUdi(FilterUdiRelRequest filterUdiRelRequest); - - List filterUdiJoinSup(FilterUdiRelRequest filterUdiRelRequest); - - List filterUdiEntity(FilterUdiRelRequest filterUdiRelRequest); - - UdiRelevanceResponse selectByNameCode(String nameCode); - - /** - * 根据耗材字典ID查询耗材相关数据 - * - * @param relId - * @return - */ - UdiRelevanceResponse selectByRelId(String relId); - - //根据DI查询产品信息 - List selectAllByNameCode(String nameCode); - - - List selectAllByNameCode(String nameCode, String unitFk); - - boolean isExit(); - - List filterUdiGp(FilterUdiRelRequest filterUdiRelRequest); - - boolean isExitByUuid(String uuid); - - List batchSelectByUuid(List uuids); - - List batchSelectByIds(List ids); - - List selectByUuid(String uuid); - - UdiRelevanceEntity selectById(Long id); - - UdiRelevanceResponse selectGroupById(Long id); - - UdiRelevanceResponse selectUdiId(Long id); - - - UdiRelevanceResponse selectSupGroupById(Long id, String supId); - - - UdiRelevanceEntity selectUpdateByUuid(String uuid); - - UdiRelevanceEntity selectUpdateByThirdId(String thirdId); - - UdiRelevanceEntity selectByMainIdLimitOne(String mainId); - - List selectByMainId(String mainId); - - UdiRelevanceEntity selectUpteaByAll(String uuid, String thirdId); - - UdiRelevanceEntity selectByThirdId(String thirdId, String thirdSys); - - List selectListByThirdId(String thirdId, String thirdSys); - - boolean insertUdiRelevance(UdiRelevanceEntity udiRelevanceEntity); - - boolean insertUdiRelevanceignore(UdiRelevanceEntity udiRelevanceEntity); - - boolean updateUdiRelevance(UdiRelevanceEntity udiRelevanceEntity); - - boolean deleteById(String id); - - boolean deleteByIds(List id); - - boolean deleteByUuid(String uuid); - - /** - * 查询产品的uuid - * - * @param relId - * @return - */ - String findUuidById(String relId); - - List selectGroupByNameCode(String nameCode, Boolean isDisable); - - /** - * 根据UDI码查询耗材字典ID - * - * @param code - * @return - */ - String getRelIdByUdiCode(String code); -} diff --git a/src/main/java/com/glxp/api/service/basic/impl/CompanyProductRelevanceServiceImpl.java b/src/main/java/com/glxp/api/service/basic/impl/CompanyProductRelevanceServiceImpl.java deleted file mode 100644 index 238cfe6..0000000 --- a/src/main/java/com/glxp/api/service/basic/impl/CompanyProductRelevanceServiceImpl.java +++ /dev/null @@ -1,62 +0,0 @@ -package com.glxp.api.service.basic.impl; - - -import cn.hutool.core.util.IdUtil; -import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; -import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; -import com.github.pagehelper.PageHelper; -import com.glxp.api.dao.basic.CompanyProductRelevanceDao; -import com.glxp.api.entity.basic.CompanyProductRelevanceEntity; -import com.glxp.api.req.basic.CompanyProductRelevanceRequest; -import com.glxp.api.res.basic.CompanyProductRelevanceResponse; -import com.glxp.api.service.basic.CompanyProductRelevanceService; -import org.springframework.stereotype.Service; -import org.springframework.transaction.annotation.Transactional; - -import javax.annotation.Resource; -import java.util.Collections; -import java.util.List; - -@Service -@Transactional(rollbackFor = Exception.class) -public class CompanyProductRelevanceServiceImpl extends ServiceImpl - implements CompanyProductRelevanceService { - @Resource - CompanyProductRelevanceDao companyProductRelevanceDao; - - @Override - public List filterUdiGp(CompanyProductRelevanceRequest basicInstrumentMaintainRequest) { - if (basicInstrumentMaintainRequest == null) { - return Collections.emptyList(); - } - if (basicInstrumentMaintainRequest.getPage() != null) { - int offset = (basicInstrumentMaintainRequest.getPage() - 1) * basicInstrumentMaintainRequest.getLimit(); - PageHelper.offsetPage(offset, basicInstrumentMaintainRequest.getLimit()); - } - - List data = companyProductRelevanceDao.filterUdiGp(basicInstrumentMaintainRequest); - return data; - } - - @Override - public boolean insertCompanyProductRelevance(CompanyProductRelevanceEntity companyProductRelevanceEntity) { - if (companyProductRelevanceEntity.getId() == null) - companyProductRelevanceEntity.setId(IdUtil.getSnowflakeNextId()); - return companyProductRelevanceDao.insertCompanyProductRelevance(companyProductRelevanceEntity); - } - - @Override - public boolean deleteById(String id) { - return companyProductRelevanceDao.deleteById(id); - } - - @Override - public boolean deleteByRlId(String id) { - return companyProductRelevanceDao.deleteByRlId(id); - } - - @Override - public boolean isExitByRelId(String relId) { - return companyProductRelevanceDao.exists(new QueryWrapper().eq("udiRlIdFk", relId)); - } -} diff --git a/src/main/java/com/glxp/api/service/basic/impl/UdiProductServiceImpl.java b/src/main/java/com/glxp/api/service/basic/impl/UdiProductServiceImpl.java deleted file mode 100644 index f337343..0000000 --- a/src/main/java/com/glxp/api/service/basic/impl/UdiProductServiceImpl.java +++ /dev/null @@ -1,158 +0,0 @@ -package com.glxp.api.service.basic.impl; - -import cn.hutool.core.collection.CollUtil; -import cn.hutool.core.util.IdUtil; -import cn.hutool.core.util.StrUtil; -import com.github.pagehelper.PageHelper; -import com.glxp.api.dao.basic.UdiProductDao; -import com.glxp.api.entity.basic.UdiProductEntity; -import com.glxp.api.req.basic.FilterUdiRelRequest; -import com.glxp.api.req.basic.UdiInfoRequest; -import com.glxp.api.res.basic.UdiRelevanceResponse; -import com.glxp.api.service.basic.UdiProductService; -import com.glxp.api.util.udi.FilterUdiUtils; -import org.springframework.stereotype.Service; -import org.springframework.transaction.annotation.Transactional; - -import javax.annotation.Resource; -import java.util.Collections; -import java.util.List; - -@Service -@Transactional(rollbackFor = Exception.class) -public class UdiProductServiceImpl implements UdiProductService { - - @Resource - UdiProductDao udiProductDao; - - @Override - public List filterUdiInfo(FilterUdiRelRequest filterUdiRelRequest) { - if (filterUdiRelRequest == null) { - return Collections.emptyList(); - } - if (filterUdiRelRequest.getPage() != null) { - int offset = (filterUdiRelRequest.getPage() - 1) * filterUdiRelRequest.getLimit(); - PageHelper.offsetPage(offset, filterUdiRelRequest.getLimit()); - } - - List data = udiProductDao.filterUdiInfo(filterUdiRelRequest); - return data; - } - - - @Override - public UdiProductEntity findBySptm(String sptm) { - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - filterUdiRelRequest.setSptm(sptm); - List data = udiProductDao.filterUdiInfo(filterUdiRelRequest); - if (CollUtil.isNotEmpty(data)) { - return data.get(0); - } - return null; - } - - @Override - public List filterUdiInfo2(FilterUdiRelRequest filterUdiRelRequest) { - if (filterUdiRelRequest == null) { - return Collections.emptyList(); - } - if (filterUdiRelRequest.getPage() != null) { - int offset = (filterUdiRelRequest.getPage() - 1) * filterUdiRelRequest.getLimit(); - PageHelper.offsetPage(offset, filterUdiRelRequest.getLimit()); - } - - List data = udiProductDao.filterUdiInfo2(filterUdiRelRequest); - return data; - } - - @Override - public List filterAllUdiInfo(FilterUdiRelRequest filterUdiRelRequest) { - if (filterUdiRelRequest == null) { - return Collections.emptyList(); - } - List data = udiProductDao.filterUdiInfo(filterUdiRelRequest); - return data; - } - - @Override - public UdiProductEntity findByNameCode(String nameCode) { - String prefix = FilterUdiUtils.getDiStr(nameCode); - return udiProductDao.findByNameCode(prefix); - } - - @Override - public UdiProductEntity findById(String id) { - return udiProductDao.findById(id); - } - - @Override - public UdiProductEntity findByUuid(String uuid) { - return udiProductDao.findByUuid(uuid); - } - - @Override - public List findByUuids(String uuid) { - return udiProductDao.findByUuids(uuid); - } - - @Override - public boolean insertUdiInfo(UdiProductEntity udiProductEntity) { - if (udiProductEntity.getId() == null) { - udiProductEntity.setId(IdUtil.getSnowflakeNextId()); - } - return udiProductDao.insertUdiInfo(udiProductEntity); - } - - @Override - public boolean insertUdiInfos(List udiInfoEntities) { - return udiProductDao.insertUdiInfos(udiInfoEntities); - } - - @Override - public boolean updateUdiInfo(UdiProductEntity udiProductEntity) { - if (StrUtil.isEmpty(udiProductEntity.getNameCode())) - return false; - return udiProductDao.updateUdiInfo(udiProductEntity); - } - - @Override - public boolean updateUdiInfoByUuid(UdiProductEntity udiProductEntity) { - if (StrUtil.isEmpty(udiProductEntity.getUuid())) - return false; - return udiProductDao.updateUdiInfoByUuid(udiProductEntity); - } - - @Override - public boolean updateUdiInfoById(UdiProductEntity udiProductEntity) { - return udiProductDao.updateUdiInfoById(udiProductEntity); - } - - - @Override - public boolean deleteById(String id) { - return udiProductDao.deleteById(id); - } - - @Override - public boolean deleteByUuid(String uuid) { - return udiProductDao.deleteByUuid(uuid); - } - - @Override - public List getGgxhList(String relId) { - return udiProductDao.selectGgxhList(relId); - } - - @Override - public boolean updateUdiInfoNotAll(UdiInfoRequest udiInfoRequest) { - if (StrUtil.isEmpty(udiInfoRequest.getUuid())) - return false; - return udiProductDao.updateUdiInfoNotAll(udiInfoRequest); - } - - @Override - public UdiProductEntity getAllowNoBatch(String nameCode) { - String di = FilterUdiUtils.getDiStr(nameCode); - return udiProductDao.selectAllowNoBatch(di); - } -} diff --git a/src/main/java/com/glxp/api/service/basic/impl/UdiRelevanceServiceImpl.java b/src/main/java/com/glxp/api/service/basic/impl/UdiRelevanceServiceImpl.java deleted file mode 100644 index 5883de4..0000000 --- a/src/main/java/com/glxp/api/service/basic/impl/UdiRelevanceServiceImpl.java +++ /dev/null @@ -1,405 +0,0 @@ -package com.glxp.api.service.basic.impl; - -import java.util.Collections; -import java.util.List; - -import javax.annotation.Resource; - -import org.springframework.stereotype.Service; -import org.springframework.transaction.annotation.Transactional; - -import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; -import com.github.pagehelper.PageHelper; -import com.glxp.api.constant.ConstantStatus; -import com.glxp.api.dao.basic.UdiRelevanceDao; -import com.glxp.api.entity.basic.UdiEntity; -import com.glxp.api.entity.basic.UdiRelevanceEntity; -import com.glxp.api.req.basic.FilterUdiRelRequest; -import com.glxp.api.res.basic.UdiRelevanceResponse; -import com.glxp.api.service.basic.UdiRelevanceService; -import com.glxp.api.util.udi.FilterUdiUtils; - -import cn.hutool.core.collection.CollUtil; -import cn.hutool.core.util.StrUtil; - -@Service -@Transactional(rollbackFor = Exception.class) -public class UdiRelevanceServiceImpl extends ServiceImpl implements UdiRelevanceService { - @Resource - UdiRelevanceDao udiRelevanceDao; - - - @Override - public List filterUdiRelevance(FilterUdiRelRequest filterUdiRelRequest) { - if (filterUdiRelRequest == null) { - return Collections.emptyList(); - } - if (filterUdiRelRequest.getPage() != null) { - int offset = (filterUdiRelRequest.getPage() - 1) * filterUdiRelRequest.getLimit(); - PageHelper.offsetPage(offset, filterUdiRelRequest.getLimit()); - } - List data = udiRelevanceDao.filterUdiRelevance(filterUdiRelRequest); - return data; - } - - @Override - public List filterCertUdi(FilterUdiRelRequest filterUdiRelRequest) { - - - if (filterUdiRelRequest == null) { - return Collections.emptyList(); - } - if (filterUdiRelRequest.getPage() != null) { - int offset = (filterUdiRelRequest.getPage() - 1) * filterUdiRelRequest.getLimit(); - PageHelper.offsetPage(offset, filterUdiRelRequest.getLimit()); - } - List data = udiRelevanceDao.filterCertUdi(filterUdiRelRequest); - return data; - - } - - @Override - public List filterUdiJoinSup(FilterUdiRelRequest filterUdiRelRequest) { - if (filterUdiRelRequest == null) { - return Collections.emptyList(); - } - if (filterUdiRelRequest.getPage() != null) { - int offset = (filterUdiRelRequest.getPage() - 1) * filterUdiRelRequest.getLimit(); - PageHelper.offsetPage(offset, filterUdiRelRequest.getLimit()); - } - List data = udiRelevanceDao.filterUdiJoinSup(filterUdiRelRequest); - return data; - } - - - @Override - public List filterUdiEntity(FilterUdiRelRequest filterUdiRelRequest) { - - List data = udiRelevanceDao.filterEntity(filterUdiRelRequest); - return data; - } - - @Override - public List selectAllByNameCode(String nameCode) { - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - filterUdiRelRequest.setUniqueNameCode(nameCode); - List udiRelevanceResponses = filterUdiRelevance(filterUdiRelRequest); - return udiRelevanceResponses; - } - - @Override - public UdiRelevanceResponse selectByNameCode(String nameCode) { - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - filterUdiRelRequest.setUniqueNameCode(nameCode); - List udiRelevanceResponses = filterUdiRelevance(filterUdiRelRequest); - if (udiRelevanceResponses != null && udiRelevanceResponses.size() > 0) - return udiRelevanceResponses.get(0); - return null; - } - - @Override - public UdiRelevanceResponse selectByRelId(String relId) { - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - filterUdiRelRequest.setRelId(relId); - List udiRelevanceResponses = filterUdiRelevance(filterUdiRelRequest); - if (CollUtil.isNotEmpty(udiRelevanceResponses)) { - return udiRelevanceResponses.get(0); - } - return null; - } - - @Override - public List selectAllByNameCode(String nameCode, String unitFk) { - List udiRelevanceResponses; - if (StrUtil.isNotEmpty(unitFk)) { - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - filterUdiRelRequest.setUniqueNameCode(nameCode); - filterUdiRelRequest.setUnitFk(unitFk); - filterUdiRelRequest.setIsDisable(false); - udiRelevanceResponses = filterUdiJoinSup(filterUdiRelRequest); - } else { - udiRelevanceResponses = selectGroupByNameCode(nameCode, false); - } - if (udiRelevanceResponses.size() == 1) { - UdiRelevanceResponse udiRelevanceResponse = udiRelevanceResponses.get(0); - if (udiRelevanceResponse == null || udiRelevanceResponse.getProductType() == ConstantStatus.PRODUCT_TYPE_THIRD) { - return selectByMainId(nameCode); - } - } - return udiRelevanceResponses; - - - } - - @Override - public boolean isExit() { - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - filterUdiRelRequest.setPage(1); - filterUdiRelRequest.setLimit(1); - List data = filterUdiRelevance(filterUdiRelRequest); - if (data != null && data.size() > 0) { - return true; - } - return false; - } - - @Override - public List filterUdiGp(FilterUdiRelRequest filterUdiRelRequest) { - if (filterUdiRelRequest == null) { - return Collections.emptyList(); - } - if (filterUdiRelRequest.getPage() != null) { - int offset = (filterUdiRelRequest.getPage() - 1) * filterUdiRelRequest.getLimit(); - PageHelper.offsetPage(offset, filterUdiRelRequest.getLimit()); - } - - List data = udiRelevanceDao.filterUdiGp(filterUdiRelRequest); - return data; - } - - @Override - public boolean isExitByUuid(String uuid) { - List udiRelevanceEntities = udiRelevanceDao.selectByUuid(uuid); - if (udiRelevanceEntities != null && !udiRelevanceEntities.isEmpty()) { - return true; - } - return false; - } - - @Override - public List batchSelectByUuid(List uuids) { - return udiRelevanceDao.batchSelectByUuid(uuids); - } - - @Override - public List batchSelectByIds(List ids) { - return udiRelevanceDao.batchSelectByIds(ids); - } - - @Override - public List selectByUuid(String uuid) { - return udiRelevanceDao.selectByUuid(uuid); - } - - @Override - public UdiRelevanceEntity selectById(Long id) { - return udiRelevanceDao.selectById(id); - } - - @Override - public UdiRelevanceResponse selectGroupById(Long id) { - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - filterUdiRelRequest.setId(id); - filterUdiRelRequest.setDiType(1); - List data = udiRelevanceDao.filterUdiRelevance(filterUdiRelRequest); - if (data != null && data.size() > 0) - return data.get(0); - return null; - } - - @Override - public UdiRelevanceResponse selectUdiId(Long id) { - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - filterUdiRelRequest.setId(id); - List data = udiRelevanceDao.filterUdiRelevance(filterUdiRelRequest); - if (data != null && data.size() > 0) - return data.get(0); - return null; - } - - @Override - public UdiRelevanceResponse selectSupGroupById(Long id, String supId) { - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - if (StrUtil.isNotEmpty(supId)) - filterUdiRelRequest.setUnitFk(supId); - filterUdiRelRequest.setId(id); - filterUdiRelRequest.setDiType(1); - return udiRelevanceDao.selectOneUdiJoinSup(filterUdiRelRequest); - } - - - @Override - public UdiRelevanceEntity selectUpdateByUuid(String uuid) { - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - filterUdiRelRequest.setUuid(uuid); - List data = udiRelevanceDao.filterEntity(filterUdiRelRequest); - if (data != null && data.size() > 0) - return data.get(0); - return null; - } - - @Override - public UdiRelevanceEntity selectUpdateByThirdId(String thirdId) { - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - if (thirdId != null) { - /* ThrSystemEntity basicThirdSysEntity = basicThirdSysService.selectMainThrSys(); - String mainSys = basicThirdSysEntity.getThirdId(); - if (mainSys.equals("thirdId")) { - filterUdiRelRequest.setThirdId(thirdId); - } else if (mainSys.equals("thirdId1")) { - filterUdiRelRequest.setThirdId1(thirdId); - } else if (mainSys.equals("thirdId2")) { - filterUdiRelRequest.setThirdId2(thirdId); - } else if (mainSys.equals("thirdId3")) { - filterUdiRelRequest.setThirdId3(thirdId); - } else if (mainSys.equals("thirdId4")) { - filterUdiRelRequest.setThirdId4(thirdId); - }*/ - } - List data = udiRelevanceDao.filterEntity(filterUdiRelRequest); - if (data != null && data.size() > 0) - return data.get(0); - return null; - } - - @Override - public UdiRelevanceEntity selectByMainIdLimitOne(String mainId) { - - if (mainId == null) - return null; - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - filterUdiRelRequest.setMainId(mainId); - return udiRelevanceDao.selectByThirdId(filterUdiRelRequest); - } - - @Override - public List selectByMainId(String mainId) { - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - filterUdiRelRequest.setMainId(mainId); - List udiRelevanceResponses = filterUdiRelevance(filterUdiRelRequest); - return udiRelevanceResponses; - } - - @Override - public UdiRelevanceEntity selectUpteaByAll(String uuid, String thirdId) { - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - if (thirdId != null) { - /*ThrSystemEntity basicThirdSysEntity = basicThirdSysService.selectMainThrSys(); - String mainSys = basicThirdSysEntity.getThirdId(); - filterUdiRelRequest.setUuid(uuid); - if (mainSys.equals("thirdId")) { - filterUdiRelRequest.setThirdId(thirdId); - } else if (mainSys.equals("thirdId1")) { - filterUdiRelRequest.setThirdId1(thirdId); - } else if (mainSys.equals("thirdId2")) { - filterUdiRelRequest.setThirdId2(thirdId); - } else if (mainSys.equals("thirdId3")) { - filterUdiRelRequest.setThirdId3(thirdId); - } else if (mainSys.equals("thirdId4")) { - filterUdiRelRequest.setThirdId4(thirdId); - }*/ - } - - List data = udiRelevanceDao.filterEntity(filterUdiRelRequest); - if (data != null && data.size() > 0) - return data.get(0); - return null; - } - - @Override - public UdiRelevanceEntity selectByThirdId(String thirdId, String thirdSys) { - - if (StrUtil.isEmpty(thirdId) || StrUtil.isEmpty(thirdSys)) { - return null; - } - - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - if ("thirdId".equals(thirdSys)) { - filterUdiRelRequest.setThirdId(thirdId); - } else if ("thirdId1".equals(thirdSys)) { - filterUdiRelRequest.setThirdId1(thirdId); - } else if ("thirdId2".equals(thirdSys)) { - filterUdiRelRequest.setThirdId2(thirdId); - } else if ("thirdId3".equals(thirdSys)) { - filterUdiRelRequest.setThirdId3(thirdId); - } else if ("thirdId4".equals(thirdSys)) { - filterUdiRelRequest.setThirdId4(thirdId); - } - - return udiRelevanceDao.selectByThirdId(filterUdiRelRequest); - } - - @Override - public List selectListByThirdId(String thirdId, String thirdSys) { - if (StrUtil.isEmpty(thirdId) || StrUtil.isEmpty(thirdSys)) { - return null; - } - - FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); - if ("thirdId".equals(thirdSys)) { - filterUdiRelRequest.setThirdId(thirdId); - } else if ("thirdId1".equals(thirdSys)) { - filterUdiRelRequest.setThirdId1(thirdId); - } else if ("thirdId2".equals(thirdSys)) { - filterUdiRelRequest.setThirdId2(thirdId); - } else if ("thirdId3".equals(thirdSys)) { - filterUdiRelRequest.setThirdId3(thirdId); - } else if ("thirdId4".equals(thirdSys)) { - filterUdiRelRequest.setThirdId4(thirdId); - } - List data = udiRelevanceDao.filterUdiGp(filterUdiRelRequest); - return data; - } - - @Override - public boolean insertUdiRelevance(UdiRelevanceEntity udiRelevanceEntity) { - return udiRelevanceDao.insertUdiRelevance(udiRelevanceEntity); - } - - @Override - public boolean insertUdiRelevanceignore(UdiRelevanceEntity udiRelevanceEntity) { - return udiRelevanceDao.insertUdiRelevanceignore(udiRelevanceEntity); - } - - @Override - public boolean updateUdiRelevance(UdiRelevanceEntity udiRelevanceEntity) { - /*ThrSystemEntity basicThirdSysEntity = basicThirdSysService.selectMainThrSys(); - String mainSys = basicThirdSysEntity.getThirdId(); - if (mainSys.equals("thirdId")) { - udiRelevanceEntity.setMainId(udiRelevanceEntity.getThirdId()); - } else if (mainSys.equals("thirdId1")) { - udiRelevanceEntity.setMainId(udiRelevanceEntity.getThirdId1()); - } else if (mainSys.equals("thirdId2")) { - udiRelevanceEntity.setMainId(udiRelevanceEntity.getThirdId2()); - } else if (mainSys.equals("thirdId3")) { - udiRelevanceEntity.setMainId(udiRelevanceEntity.getThirdId3()); - } else if (mainSys.equals("thirdId4")) { - udiRelevanceEntity.setMainId(udiRelevanceEntity.getThirdId4()); - }*/ - return udiRelevanceDao.updateUdiRelevance(udiRelevanceEntity); - } - - @Override - public boolean deleteById(String id) { - return udiRelevanceDao.deleteById(id); - } - - @Override - public boolean deleteByIds(List ids) { - return udiRelevanceDao.deleteByIds(ids); - } - - @Override - public boolean deleteByUuid(String uuid) { - return udiRelevanceDao.deleteByUuid(uuid); - } - - @Override - public String findUuidById(String relId) { - return udiRelevanceDao.selectUuidById(relId); - } - - @Override - public List selectGroupByNameCode(String nameCode, Boolean isDisable) { - return udiRelevanceDao.selectGroupByNameCode(nameCode, isDisable); - } - - @Override - public String getRelIdByUdiCode(String code) { - if (StrUtil.isBlank(code)) { - return null; - } - UdiEntity udi = FilterUdiUtils.getUdi(code); - return udiRelevanceDao.selectRelIdByNameCode(udi.getUdi()); - } -} diff --git a/src/main/resources/mybatis/mapper/basic/CompanyProductRelevanceDao.xml b/src/main/resources/mybatis/mapper/basic/CompanyProductRelevanceDao.xml deleted file mode 100644 index ec4bb31..0000000 --- a/src/main/resources/mybatis/mapper/basic/CompanyProductRelevanceDao.xml +++ /dev/null @@ -1,226 +0,0 @@ - - - - - - replace - INTO company_product_relevance(id, customerId, productId, enterpriseId, registrationId, - createTime, updateTime, auditStatus, productUuid, udiRlIdFk, unitFk, - price) - values (#{id}, #{customerId}, - #{productId}, - #{enterpriseId}, - #{registrationId}, - #{createTime}, - #{updateTime}, - #{auditStatus}, - #{productUuid}, - #{udiRlIdFk}, - #{unitFk}, #{price}) - - - - - replace - INTO company_product_relevance(id, customerId, productId, enterpriseId, registrationId, - create_time, update_time, auditStatus, productUuid, udiRlIdFk, unitFk, - price) - values (#{id}, - #{customerId}, - #{productId}, - #{enterpriseId}, - #{registrationId}, - #{create_time}, - #{update_time}, - #{auditStatus}, - #{productUuid}, - #{udiRlIdFk}, - #{unitFk}, #{price}) - - - - DELETE - FROM company_product_relevance - WHERE id = #{id} - - - - - DELETE - FROM company_product_relevance - WHERE udiRlIdFk = #{id} - - - - diff --git a/src/main/resources/mybatis/mapper/basic/UdiProductDao.xml b/src/main/resources/mybatis/mapper/basic/UdiProductDao.xml deleted file mode 100644 index 1b8aa14..0000000 --- a/src/main/resources/mybatis/mapper/basic/UdiProductDao.xml +++ /dev/null @@ -1,964 +0,0 @@ - - - - - - - - - - - - - - - - - replace - INTO basic_products - (id, uuid, originUuid, nameCode, deviceRecordKey, packRatio, packLevel, packUnit, bhxjsl, bhzxxsbzsl, - zxxsbzbhsydysl, bhxjcpbm, bzcj, cpmctymc, cplb, flbm, ggxh, qxlb, tyshxydm, - ylqxzcrbarmc, zczbhhzbapzbh, ylqxzcrbarywmc, sydycpbs, sjcpbm, versionNumber, diType, ybbm, sptm, - manufactory, measname, productType, scbssfbhph, scbssfbhxlh, scbssfbhscrq, scbssfbhsxrq, cpms, - allowNoBatch, allowNoExpire, - allowNoProduct, allowNoSerial, spmc, cplx, hchzsb, cpdls, price, basicPrductRemak1, basicPrductRemak2, - basicPrductRemak3, basicPrductRemak4, basicPrductRemak5, basicPrductRemak6, basicPrductRemak7, - basicPrductRemak8) - values (#{id}, #{uuid}, - #{originUuid}, - #{nameCode}, - #{deviceRecordKey}, - #{packRatio}, - #{packLevel}, - #{packUnit}, - #{bhxjsl}, - #{bhzxxsbzsl }, - #{zxxsbzbhsydysl}, - #{bhxjcpbm}, - #{bzcj}, - #{cpmctymc}, - #{cplb}, - #{flbm}, - #{ggxh}, - #{qxlb}, - #{tyshxydm}, - #{ylqxzcrbarmc}, - #{zczbhhzbapzbh}, - #{ylqxzcrbarywmc}, - #{sydycpbs}, - #{sjcpbm}, - #{versionNumber}, - #{diType}, - #{ybbm}, - #{sptm}, - #{manufactory}, - #{measname}, - #{productType}, - #{scbssfbhph}, - #{scbssfbhxlh}, - #{scbssfbhscrq}, - #{scbssfbhsxrq}, - #{cpms}, - #{allowNoBatch}, - #{allowNoExpire}, - #{allowNoProduct}, #{allowNoSerial}, - #{spmc}, - #{cplx}, - #{hchzsb}, - #{cpdls}, - #{price}, - #{basicPrductRemak1}, - #{basicPrductRemak2}, - #{basicPrductRemak3}, - #{basicPrductRemak4}, - #{basicPrductRemak5}, - #{basicPrductRemak6}, - #{basicPrductRemak7}, - #{basicPrductRemak8}) - - - - replace INTO basic_products - (id, uuid, originUuid, nameCode, deviceRecordKey, packRatio, packLevel, packUnit, bhxjsl, bhzxxsbzsl, - zxxsbzbhsydysl, bhxjcpbm, bzcj, cpmctymc, cplb, flbm, ggxh, qxlb, tyshxydm, - ylqxzcrbarmc, zczbhhzbapzbh, ylqxzcrbarywmc, sydycpbs, sjcpbm, versionNumber, diType, ybbm, sptm, - manufactory, measname, productType, scbssfbhph, scbssfbhxlh, scbssfbhscrq, scbssfbhsxrq, cpms, - allowNoBatch, allowNoExpire, - allowNoProduct, allowNoSerial, spmc, cplx, hchzsb, cpdls, price, basicPrductRemak1, basicPrductRemak2, - basicPrductRemak3, basicPrductRemak4, basicPrductRemak5, basicPrductRemak6, basicPrductRemak7, - basicPrductRemak8) - values - - - (#{item.id}, - #{item.uuid}, - #{item.originUuid}, - #{item.nameCode}, - #{item.deviceRecordKey}, - #{item.packRatio}, - #{item.packLevel}, - #{item.packUnit}, - #{item.bhxjsl}, - #{item.bhzxxsbzsl}, - #{item.zxxsbzbhsydysl}, - #{item.bhxjcpbm}, - #{item.bzcj}, - #{item.cpmctymc}, - #{item.cplb}, - #{item.flbm}, - #{item.ggxh}, - #{item.qxlb}, - #{item.tyshxydm}, - #{item.ylqxzcrbarmc}, - #{item.zczbhhzbapzbh}, - #{item.ylqxzcrbarywmc}, - #{item.sydycpbs}, - #{item.sjcpbm}, - #{item.versionNumber}, - #{item.diType}, - #{item.ybbm}, - #{item.sptm}, - #{item.manufactory}, - #{item.measname}, - #{item.productType}, - #{item.scbssfbhph}, - #{item.scbssfbhxlh}, - #{item.scbssfbhscrq}, - #{item.scbssfbhsxrq}, - #{item.cpms}, - #{item.allowNoBatch}, - #{item.allowNoExpire}, - #{item.allowNoProduct}, #{item.allowNoSerial}, - #{item.spmc}, - #{item.cplx}, - #{item.hchzsb}, - #{item.cpdls}, - #{item.price}, - #{item.basicPrductRemak1}, - #{item.basicPrductRemak2}, - #{item.basicPrductRemak3}, - #{item.basicPrductRemak4}, - #{item.basicPrductRemak5}, - #{item.basicPrductRemak6}, - #{item.basicPrductRemak7}, - #{item.basicPrductRemak8}) - - - - - DELETE - FROM basic_products - WHERE id = #{id} - - - - DELETE - FROM basic_products - WHERE uuid = #{uuid} - - - - UPDATE basic_products - - - originUuid=#{originUuid}, - - - nameCode=#{nameCode}, - - - deviceRecordKey=#{deviceRecordKey}, - - - packRatio=#{packRatio}, - - - packLevel=#{packLevel}, - - - packUnit=#{packUnit}, - - - bhxjsl=#{bhxjsl}, - - - bhzxxsbzsl=#{bhzxxsbzsl}, - - - zxxsbzbhsydysl=#{zxxsbzbhsydysl}, - - - bhxjcpbm=#{bhxjcpbm}, - - - bzcj=#{bzcj}, - - - cpmctymc=#{cpmctymc}, - - - cplb=#{cplb}, - - - flbm=#{flbm}, - - - ggxh=#{ggxh}, - - - qxlb=#{qxlb}, - - - tyshxydm=#{tyshxydm}, - - - ylqxzcrbarmc=#{ylqxzcrbarmc}, - - - zczbhhzbapzbh=#{zczbhhzbapzbh}, - - - ylqxzcrbarywmc=#{ylqxzcrbarywmc}, - - - sydycpbs=#{sydycpbs}, - - - sjcpbm=#{sjcpbm}, - - - versionNumber=#{versionNumber}, - - - diType=#{diType}, - - - ybbm=#{ybbm}, - - - sptm=#{sptm}, - - - manufactory=#{manufactory}, - - - measname=#{measname}, - - - productType=#{productType}, - - - scbssfbhph=#{scbssfbhph}, - - - scbssfbhxlh=#{scbssfbhxlh}, - - - scbssfbhscrq=#{scbssfbhscrq}, - - - scbssfbhsxrq=#{scbssfbhsxrq}, - - - cpms=#{cpms}, - - - allowNoBatch=#{allowNoBatch}, - - - allowNoExpire=#{allowNoExpire}, - - - allowNoProduct=#{allowNoProduct}, - - - allowNoSerial=#{allowNoSerial}, - - - - - spmc=#{spmc}, - - - cplx=#{cplx}, - - - hchzsb=#{hchzsb}, - - - cpdls=#{cpdls}, - - - price=#{price}, - - - basicPrductRemak1=#{basicPrductRemak1}, - - - basicPrductRemak2=#{basicPrductRemak2}, - - - basicPrductRemak3=#{basicPrductRemak3}, - - - basicPrductRemak4=#{basicPrductRemak4}, - - - basicPrductRemak5=#{basicPrductRemak5}, - - - basicPrductRemak6=#{basicPrductRemak6}, - - - basicPrductRemak7=#{basicPrductRemak7}, - - - basicPrductRemak8=#{basicPrductRemak8}, - - - WHERE nameCode = #{nameCode} - and uuid = #{uuid} - - - - update basic_products - - - originUuid=#{originUuid}, - - - nameCode=#{nameCode}, - - - deviceRecordKey=#{deviceRecordKey}, - - - packRatio=#{packRatio}, - - - packLevel=#{packLevel}, - - - packUnit=#{packUnit}, - - - bhxjsl=#{bhxjsl}, - - - bhzxxsbzsl=#{bhzxxsbzsl}, - - - zxxsbzbhsydysl=#{zxxsbzbhsydysl}, - - - bhxjcpbm=#{bhxjcpbm}, - - - bzcj=#{bzcj}, - - - cpmctymc=#{cpmctymc}, - - - cplb=#{cplb}, - - - flbm=#{flbm}, - - - ggxh=#{ggxh}, - - - qxlb =#{qxlb}, - - - tyshxydm=#{tyshxydm}, - - - ylqxzcrbarmc=#{ylqxzcrbarmc}, - - - zczbhhzbapzbh=#{zczbhhzbapzbh}, - - - ylqxzcrbarywmc=#{ylqxzcrbarywmc}, - - - sydycpbs=#{sydycpbs}, - - - sjcpbm=#{sjcpbm}, - - - versionNumber=#{versionNumber}, - - - diType=#{diType}, - - - ybbm=#{ybbm}, - - - sptm=#{sptm}, - - - manufactory=#{manufactory}, - - - measname=#{measname}, - - - productType=#{productType}, - - - scbssfbhph=#{scbssfbhph}, - - - scbssfbhxlh=#{scbssfbhxlh}, - - - scbssfbhscrq=#{scbssfbhscrq}, - - - scbssfbhsxrq=#{scbssfbhsxrq}, - - - cpms=#{cpms}, - - - allowNoBatch=#{allowNoBatch}, - - - allowNoExpire=#{allowNoExpire}, - - - allowNoProduct=#{allowNoProduct}, - - - allowNoSerial=#{allowNoSerial}, - - - spmc=#{spmc}, - - - cplx=#{cplx}, - - - hchzsb=#{hchzsb}, - - - cpdls=#{cpdls}, - - - price=#{price}, - - - basicPrductRemak1=#{basicPrductRemak1}, - - - basicPrductRemak2=#{basicPrductRemak2}, - - - basicPrductRemak3=#{basicPrductRemak3}, - - - basicPrductRemak4=#{basicPrductRemak4}, - - - basicPrductRemak5=#{basicPrductRemak5}, - - - basicPrductRemak6=#{basicPrductRemak6}, - - - basicPrductRemak7=#{basicPrductRemak7}, - - - basicPrductRemak8=#{basicPrductRemak8}, - - - where uuid = #{uuid} - - - - update basic_products - - - originUuid=#{originUuid}, - - - nameCode=#{nameCode}, - - - deviceRecordKey=#{deviceRecordKey}, - - - packRatio=#{packRatio}, - - - packLevel=#{packLevel}, - - - packUnit=#{packUnit}, - - - bhxjsl=#{bhxjsl}, - - - bhzxxsbzsl=#{bhzxxsbzsl}, - - - zxxsbzbhsydysl=#{zxxsbzbhsydysl}, - - - bhxjcpbm=#{bhxjcpbm}, - - - bzcj=#{bzcj}, - - - cpmctymc=#{cpmctymc}, - - - cplb=#{cplb}, - - - flbm=#{flbm}, - - - ggxh=#{ggxh}, - - - qxlb =#{qxlb}, - - - tyshxydm=#{tyshxydm}, - - - ylqxzcrbarmc=#{ylqxzcrbarmc}, - - - zczbhhzbapzbh=#{zczbhhzbapzbh}, - - - ylqxzcrbarywmc=#{ylqxzcrbarywmc}, - - - sydycpbs=#{sydycpbs}, - - - sjcpbm=#{sjcpbm}, - - - versionNumber=#{versionNumber}, - - - diType=#{diType}, - - - ybbm=#{ybbm}, - - - sptm=#{sptm}, - - - manufactory=#{manufactory}, - - - measname=#{measname}, - - - productType=#{productType}, - - - scbssfbhph=#{scbssfbhph}, - - - scbssfbhxlh=#{scbssfbhxlh}, - - - scbssfbhscrq=#{scbssfbhscrq}, - - - scbssfbhsxrq=#{scbssfbhsxrq}, - - - cpms=#{cpms}, - - - allowNoBatch=#{allowNoBatch}, - - - allowNoExpire=#{allowNoExpire}, - - - allowNoProduct=#{allowNoProduct}, - - - allowNoSerial=#{allowNoSerial}, - - - spmc=#{spmc}, - - - cplx=#{cplx}, - - - hchzsb=#{hchzsb}, - - - cpdls=#{cpdls}, - - - price=#{price}, - - - basicPrductRemak1=#{basicPrductRemak1}, - - - basicPrductRemak2=#{basicPrductRemak2}, - - - basicPrductRemak3=#{basicPrductRemak3}, - - - basicPrductRemak4=#{basicPrductRemak4}, - - - basicPrductRemak5=#{basicPrductRemak5}, - - - basicPrductRemak6=#{basicPrductRemak6}, - - - basicPrductRemak7=#{basicPrductRemak7}, - - - basicPrductRemak8=#{basicPrductRemak8}, - - - where id = #{id} - - - - - - - - - - - - - - UPDATE basic_products - - - packRatio=#{packRatio}, - - - packLevel=#{packLevel}, - - - bhxjsl=#{bhxjsl}, - - - bhzxxsbzsl=#{bhzxxsbzsl}, - - - zxxsbzbhsydysl=#{zxxsbzbhsydysl}, - - - bhxjcpbm=#{bhxjcpbm}, - - - bzcj=#{bzcj}, - - - addType=#{addType}, - - - deviceRecordKey=#{deviceRecordKey}, - - - cpmctymc=#{cpmctymc}, - - - cplb=#{cplb}, - - - flbm=#{flbm}, - - - ggxh=#{ggxh}, - - - qxlb=#{qxlb}, - - - tyshxydm=#{tyshxydm}, - - - ylqxzcrbarmc=#{ylqxzcrbarmc}, - - - ylqxzcrbarywmc=#{ylqxzcrbarywmc}, - - - uuid=#{uuid}, - - - sjcpbm=#{sjcpbm}, - - - versionNumber=#{versionNumber}, - - - sptm=#{sptm}, - - - manufactory=#{manufactory}, - - - ybbm=#{ybbm}, - - - measname=#{measname}, - - - diType=#{diType}, - - - productType=#{productType}, - - - scbssfbhph=#{scbssfbhph}, - - - scbssfbhxlh=#{scbssfbhxlh}, - - - scbssfbhscrq=#{scbssfbhscrq}, - - - scbssfbhsxrq=#{scbssfbhsxrq}, - - - cpms=#{cpms}, - - - originUuid=#{originUuid}, - - - spmc=#{spmc}, - - - cpdls=#{cpdls}, - - - basicPrductRemak1=#{basicPrductRemak1}, - - - basicPrductRemak2=#{basicPrductRemak2}, - - - basicPrductRemak3=#{basicPrductRemak3}, - - - basicPrductRemak4=#{basicPrductRemak4}, - - - basicPrductRemak5=#{basicPrductRemak5}, - - - basicPrductRemak6=#{basicPrductRemak6}, - - - basicPrductRemak7=#{basicPrductRemak7}, - - - basicPrductRemak8=#{basicPrductRemak8}, - - - WHERE uuid = #{uuid} - - - - diff --git a/src/main/resources/mybatis/mapper/basic/UdiRelevanceDao.xml b/src/main/resources/mybatis/mapper/basic/UdiRelevanceDao.xml deleted file mode 100644 index a900f4f..0000000 --- a/src/main/resources/mybatis/mapper/basic/UdiRelevanceDao.xml +++ /dev/null @@ -1,1253 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - replace - INTO basic_udirel - (id, uuid, mainId, thirdId, thirdId1, thirdId2, thirdId3, thirdId4, udplatCode, isUseDy, isDisable, - isLock, - lockStatus, isAdavence, useMuti, useNum, supName, createTime, updateTime, modifyTime, createUser, - updateUser, - remark, useExpireTime, dispatch, groupBuy, needCert) - values (#{id}, - #{uuid}, - #{mainId}, - #{thirdId}, - #{thirdId1}, - #{thirdId2}, - #{thirdId3}, - #{thirdId4}, - #{udplatCode}, - #{isUseDy}, - #{isDisable}, - #{isLock}, - #{lockStatus}, - #{isAdavence}, - #{useMuti}, - #{useNum}, - #{supName}, - #{createTime}, - #{updateTime}, - #{modifyTime}, - #{createUser}, - #{updateUser}, - #{remark}, #{useExpireTime}, #{dispatch}, #{groupBuy}, #{needCert}) - - - - insert - ignore - INTO basic_udirel - (id, uuid, mainId, thirdId, thirdId1, thirdId2, thirdId3, thirdId4, udplatCode, isUseDy, isDisable, - isLock, - lockStatus, isAdavence, useMuti, useNum, supName, createTime, updateTime, modifyTime, createUser, - updateUser, - remark, useExpireTime, dispatch, groupBuy, needCert) - values (#{id}, - #{uuid}, - #{mainId}, - #{thirdId}, - #{thirdId1}, - #{thirdId2}, - #{thirdId3}, - #{thirdId4}, - #{udplatCode}, - #{isUseDy}, - #{isDisable}, - #{isLock}, - #{lockStatus}, - #{isAdavence}, - #{useMuti}, - #{useNum}, - #{supName}, - #{createTime}, - #{updateTime}, - #{modifyTime}, - #{createUser}, - #{updateUser}, - #{remark}, #{useExpireTime}, #{dispatch}, #{groupBuy}, #{needCert}) - - - - DELETE - FROM basic_udirel - WHERE id = #{id} - - - - DELETE - FROM basic_udirel WHERE id in - - #{item} - - - - - DELETE - FROM basic_udirel - WHERE uuid = #{uuid} - - - - UPDATE basic_udirel - - - uuid=#{uuid}, - - - mainId=#{mainId}, - - - thirdId=#{thirdId}, - - - thirdId1=#{thirdId1}, - - - thirdId2=#{thirdId2}, - - - thirdId3=#{thirdId3}, - - - thirdId4=#{thirdId4}, - - - udplatCode=#{udplatCode}, - - - isUseDy=#{isUseDy}, - - - isDisable=#{isDisable}, - - - isLock=#{isLock}, - - - lockStatus=#{lockStatus}, - - - isAdavence=#{isAdavence}, - - - useMuti=#{useMuti}, - - - useNum=#{useNum}, - - - supName=#{supName}, - - - createTime=#{createTime}, - - - updateTime=#{updateTime}, - - - modifyTime=#{modifyTime}, - - - createUser=#{createUser}, - - - updateUser=#{updateUser}, - - - remark=#{remark}, - - - useExpireTime=#{useExpireTime}, - - - dispatch=#{dispatch}, - - - groupBuy=#{groupBuy}, - - - lowStockNum=#{lowStockNum}, - - - overStockNum=#{overStockNum}, - - - recentDateTime=#{recentDateTime}, - - - isDateBy=#{isDateBy}, - - - relCode=#{relCode}, - - - needCert=#{needCert}, - - - WHERE id = #{id} - - - - - - - - replace - into basic_udirel - (id, uuid, mainId, thirdId, thirdId1, thirdId2, thirdId3, thirdId4, udplatCode, isUseDy, isDisable, - isLock, - lockStatus, isAdavence, useMuti, useNum, supName, createTime, updateTime, modifyTime, createUser, - updateUser, - remark, useExpireTime, dispatch, groupBuy,needCert) - values - - - (#{item.id}, - #{item.uuid}, - #{item.mainId}, - #{item.thirdId}, - #{item.thirdId1}, - #{item.thirdId2}, - #{item.thirdId3}, - #{item.thirdId4}, - #{item.udplatCode}, - #{item.isUseDy}, - #{item.isDisable}, - #{item.isLock}, - #{item.lockStatus}, - #{item.isAdavence}, - #{item.useMuti}, - #{item.useNum}, - #{item.supName}, - #{item.createTime}, - #{item.updateTime}, - #{item.modifyTime}, - #{item.createUser}, - #{item.updateUser}, - #{item.remark}, #{item.useExpireTime}, #{item.dispatch}, #{item.groupBuy},#{item.needCert}) - - - - - - - - - - update - basic_udirel - set `relCode` = #{item.relCode} - where id = #{item.id} - - - - - - - - - - - - diff --git a/src/main/resources/mybatis/mapper/basic/UdiRlSupDao.xml b/src/main/resources/mybatis/mapper/basic/UdiRlSupDao.xml deleted file mode 100644 index 5a60742..0000000 --- a/src/main/resources/mybatis/mapper/basic/UdiRlSupDao.xml +++ /dev/null @@ -1,369 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - replace - INTO company_product_relevance(id,customerId, productId, enterpriseId, registrationId, - createTime, updateTime, auditStatus, productUuid, udiRlIdFk, unitFk, - price, createUser, updateUser) - values (#{id},#{customerId}, - #{productId}, - #{enterpriseId}, - #{registrationId}, - #{createTime}, - #{updateTime}, - #{auditStatus}, - #{productUuid}, - #{udiRlIdFk}, - #{unitFk}, - #{price}, - #{createUser}, - #{updateUser}) - - - - - replace - INTO company_product_relevance(id, customerId, productId, enterpriseId, registrationId, - createTime, updateTime, auditStatus, productUuid, udiRlIdFk, unitFk, - price, createUser, updateUser) - values (#{id}, - #{customerId}, - #{productId}, - #{enterpriseId}, - #{registrationId}, - #{createTime}, - #{updateTime}, - #{auditStatus}, - #{productUuid}, - #{udiRlIdFk}, - #{unitFk}, - #{price}, - #{createUser}, - #{updateUser}) - - - - DELETE - FROM company_product_relevance - WHERE id = #{id} - - - - - DELETE - FROM company_product_relevance - WHERE udiRlIdFk = #{id} - - - - - - - -