feat:阶段性代码合并
This commit is contained in:
@@ -0,0 +1,85 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.zt.plat.module.qms.business.bus.dal.mapper.BusinessAssayReportDataMapper">
|
||||
|
||||
<!--
|
||||
一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。
|
||||
无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。
|
||||
代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。
|
||||
文档可见:https://www.iocoder.cn/MyBatis/x-plugins/
|
||||
-->
|
||||
|
||||
<select id="queryWaitingDataForReport" resultType="com.zt.plat.module.qms.business.bus.dal.dataobject.BusinessAssayReportDataDO">
|
||||
-- SELECT d.*,
|
||||
select
|
||||
d.ID as id,
|
||||
d.CFG_RPT_TP_ID as configReportTypeId,
|
||||
d.CFG_SMP_RPT_ID as configSampleReportId,
|
||||
d.BSN_BSE_SMP_ID as businessBaseSampleId,
|
||||
d.SMP_CD as sampleCode,
|
||||
d.ASY_DAT as assayData,
|
||||
d.RPT_FLW_CD as reportFlowCode,
|
||||
d.DOC_DAT_ID as documentDataId,
|
||||
d.SYS_DEPT_CD as systemDepartmentCode,
|
||||
d.UPD_CNT as updateCount,
|
||||
d.RMK as remark,
|
||||
d.CREATE_TIME as createTime,
|
||||
d.CREATOR as creator,
|
||||
d.UPDATER as updater,
|
||||
d.UPDATE_TIME as updateTime,
|
||||
d.CREATOR_NAME as creatorName,
|
||||
d.DELETED as deleted,
|
||||
s.CREATE_TIME as baseSampleCreateTime,
|
||||
s.SMP_NAME as sampleName,
|
||||
s.BSE_SMP_NAME as baseSampleName
|
||||
FROM T_BSN_ASY_RPT_DAT d
|
||||
inner join T_BSN_BSE_SMP s on d.BSN_BSE_SMP_ID = s.id
|
||||
<where>
|
||||
<if test="param.idList != null and param.idList.size > 0">
|
||||
and d.id in (
|
||||
<foreach item="item" collection="param.idList" separator=",">
|
||||
#{item}
|
||||
</foreach>
|
||||
)
|
||||
</if>
|
||||
<if test="param.configReportTypeId != null and param.configReportTypeId != ''">
|
||||
and d.CFG_RPT_TP_ID = #{param.configReportTypeId}
|
||||
and NOT EXISTS (
|
||||
SELECT 1
|
||||
FROM T_RPT_DOC_DAT rd
|
||||
LEFT JOIN T_RPT_DOC_MAIN m on rd.MAIN_ID = m.ID
|
||||
WHERE rd.SRC_ID = d.id
|
||||
<if test="param.reportDocumentTypeId != null and param.reportDocumentTypeId != ''">
|
||||
and m.RPT_DOC_TP = #{param.reportDocumentTypeId}
|
||||
</if>
|
||||
and m.FLW_STS in ('not_start','in_progress','completed','rejected')
|
||||
and rd.DELETED = 0
|
||||
and m.DELETED = 0
|
||||
);
|
||||
</if>
|
||||
<if test="param.businessSampleEntrustRegistrationIdList != null and param.businessSampleEntrustRegistrationIdList.size > 0">
|
||||
d.BSN_BSE_SMP_ID in (
|
||||
select BSN_BSE_SMP_ID from T_BSN_SMP_ENTT_DTL d
|
||||
where d.BSN_SMP_ENTT_REG_ID in (
|
||||
<foreach item="item" collection="param.businessSampleEntrustRegistrationIdList" separator=",">
|
||||
#{item}
|
||||
</foreach>
|
||||
)
|
||||
)
|
||||
</if>
|
||||
<if test="param.sampleCode != null and param.sampleCode != ''">
|
||||
and d.SMP_CD like '%' || #{param.sampleCode} || '%'
|
||||
</if>
|
||||
<if test="param.sampleName != null and param.sampleName != ''">
|
||||
and s.SMP_NAME like '%' || #{param.sampleName} || '%'
|
||||
</if>
|
||||
<if test="param.baseSampleCreateTime != null and param.baseSampleCreateTime.size > 0">
|
||||
and s.CREATE_TIME between #{param.baseSampleCreateTime[0]} and #{param.baseSampleCreateTime[1]}
|
||||
</if>
|
||||
and d.deleted = 0
|
||||
</where>
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
文档可见:https://www.iocoder.cn/MyBatis/x-plugins/
|
||||
-->
|
||||
|
||||
<select id="selectUnAssayTaskGroupList" resultType="map">
|
||||
<select id="selectUnAssayTaskGroupList" resultType="com.zt.plat.module.qms.business.bus.controller.vo.BusinessAssayTaskDataGroupRespVO">
|
||||
SELECT
|
||||
tbatd.CFG_ASY_MTHD_ID AS configAssayMethodId,
|
||||
tcam.NAME AS configAssayMethodName,
|
||||
@@ -19,12 +19,74 @@
|
||||
LEFT JOIN T_CFG_ASY_MTHD tcam ON
|
||||
tbatd.CFG_ASY_MTHD_ID = tcam.ID
|
||||
WHERE
|
||||
tbatd.IS_TSKD = 0
|
||||
tbatd.IS_ASN_TSKD = 0
|
||||
AND tbatd.IS_RPOD = 0
|
||||
AND tbatd.DELETED = 0
|
||||
<if test="reqVO.assayDepartmentId != null and reqVO.assayDepartmentId != ''">
|
||||
AND tbatd.ASY_DEPT_ID = #{reqVO.assayDepartmentId}
|
||||
</if>
|
||||
<if test="reqVO.sampleFlowNodeKey != null and reqVO.sampleFlowNodeKey != ''">
|
||||
AND tbatd.SMP_FLW_NDE_KY = #{reqVO.sampleFlowNodeKey}
|
||||
</if>
|
||||
<if test="reqVO.sampleFlowNodeTime[0] != null and reqVO.sampleFlowNodeTime[0] != null">
|
||||
AND tbatd.SMP_FLW_NDE_TM #{reqVO.sampleFlowNodeTime[0]} and #{reqVO.sampleFlowNodeTime[1]}
|
||||
</if>
|
||||
GROUP BY
|
||||
tbatd.CFG_ASY_MTHD_ID,
|
||||
tcam.NAME
|
||||
</select>
|
||||
|
||||
<select id="selectUnAuditTaskGroupList" resultType="com.zt.plat.module.qms.business.bus.controller.vo.BusinessAssayTaskDataGroupRespVO">
|
||||
SELECT
|
||||
tbatd.CFG_ASY_MTHD_ID AS configAssayMethodId,
|
||||
tbatd.ASY_TP AS assayType,
|
||||
tcam.NAME AS configAssayMethodName,
|
||||
COUNT(tbatd.ID) AS sampleTaskCount
|
||||
FROM
|
||||
T_BSN_ASY_TSK_DAT tbatd
|
||||
LEFT JOIN T_CFG_ASY_MTHD tcam ON
|
||||
tbatd.CFG_ASY_MTHD_ID = tcam.ID
|
||||
WHERE
|
||||
tbatd.SMP_FLW_NDE_KY = 'flw_analysis'
|
||||
AND tbatd.DELETED = 0
|
||||
GROUP BY
|
||||
tbatd.CFG_ASY_MTHD_ID,
|
||||
tbatd.ASY_TP,
|
||||
tcam.NAME
|
||||
</select>
|
||||
|
||||
<select id="selectUnAssignTaskedSubSample" resultType="com.zt.plat.module.qms.business.bus.controller.vo.UnAssignTaskedSubSampleRespVO">
|
||||
SELECT
|
||||
tbss.ID || ',' || tbatd.CFG_ASY_MTHD_ID AS id ,
|
||||
tbss.SMP_NAME AS sampleName,
|
||||
tbss.SMP_CD AS sampleCode,
|
||||
tbss.SMP_ASY_CD AS sampleAssayCode,
|
||||
tbss.SMP_RTN_CD AS sampleReturnCode,
|
||||
tbss.SMP_FLW_NDE_TM AS sampleFlowNodeTime,
|
||||
tbatd.BSN_SB_SMP_ID AS businessSubSampleId,
|
||||
tbatd.CFG_ASY_MTHD_ID AS configAssayMethodId,
|
||||
tbatd.ASY_TP AS assayType,
|
||||
tbatd.ASY_PRJ AS assayProject,
|
||||
tbatd.ASY_DEPT_ID AS assayDepartmentId,
|
||||
tbatd.ASY_DEPT_NAME AS assayDepartmentName
|
||||
FROM
|
||||
T_BSN_ASY_TSK_DAT tbatd
|
||||
LEFT JOIN T_BSN_SB_SMP tbss ON
|
||||
tbatd.BSN_SB_SMP_ID = tbss.ID
|
||||
WHERE tbatd.IS_ASN_TSKD = 0
|
||||
AND tbatd.SMP_FLW_NDE_KY = 'flw_analysis'
|
||||
GROUP BY tbss.ID ,
|
||||
tbss.SMP_NAME ,
|
||||
tbss.SMP_CD ,
|
||||
tbss.SMP_ASY_CD ,
|
||||
tbss.SMP_RTN_CD ,
|
||||
tbss.SMP_FLW_NDE_TM,
|
||||
tbatd.BSN_SB_SMP_ID ,
|
||||
tbatd.CFG_ASY_MTHD_ID ,
|
||||
tbatd.ASY_TP ,
|
||||
tbatd.ASY_PRJ,
|
||||
tbatd.ASY_DEPT_ID,
|
||||
tbatd.ASY_DEPT_NAME
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
@@ -9,4 +9,10 @@
|
||||
文档可见:https://www.iocoder.cn/MyBatis/x-plugins/
|
||||
-->
|
||||
|
||||
<delete id="physicalDeleteByIds">
|
||||
DELETE FROM T_BSN_ASY_TSK_DTL t WHERE t.ID IN
|
||||
<foreach collection="idList" index="index" item="item" open="(" separator="," close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.zt.plat.module.qms.business.bus.dal.mapper.BusinessQCCoefficientDataMapper">
|
||||
|
||||
<!--
|
||||
一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。
|
||||
无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。
|
||||
代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。
|
||||
文档可见:https://www.iocoder.cn/MyBatis/x-plugins/
|
||||
-->
|
||||
|
||||
</mapper>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.zt.plat.module.qms.business.bus.dal.mapper.BusinessQCCoefficientParameterDataMapper">
|
||||
|
||||
<!--
|
||||
一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。
|
||||
无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。
|
||||
代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。
|
||||
文档可见:https://www.iocoder.cn/MyBatis/x-plugins/
|
||||
-->
|
||||
|
||||
</mapper>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.zt.plat.module.qms.business.bus.dal.mapper.BusinessQCDataMapper">
|
||||
|
||||
<!--
|
||||
一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。
|
||||
无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。
|
||||
代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。
|
||||
文档可见:https://www.iocoder.cn/MyBatis/x-plugins/
|
||||
-->
|
||||
|
||||
</mapper>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.zt.plat.module.qms.business.bus.dal.mapper.BusinessQCManagementDataMapper">
|
||||
|
||||
<!--
|
||||
一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。
|
||||
无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。
|
||||
代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。
|
||||
文档可见:https://www.iocoder.cn/MyBatis/x-plugins/
|
||||
-->
|
||||
|
||||
</mapper>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.zt.plat.module.qms.business.bus.dal.mapper.BusinessQCManagementParameterDataMapper">
|
||||
|
||||
<!--
|
||||
一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。
|
||||
无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。
|
||||
代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。
|
||||
文档可见:https://www.iocoder.cn/MyBatis/x-plugins/
|
||||
-->
|
||||
|
||||
</mapper>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.zt.plat.module.qms.business.bus.dal.mapper.BusinessQCManagementProjectDataMapper">
|
||||
|
||||
<!--
|
||||
一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。
|
||||
无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。
|
||||
代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。
|
||||
文档可见:https://www.iocoder.cn/MyBatis/x-plugins/
|
||||
-->
|
||||
|
||||
</mapper>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.zt.plat.module.qms.business.bus.dal.mapper.BusinessQCParameterDataMapper">
|
||||
|
||||
<!--
|
||||
一般情况下,尽可能使用 Mapper 进行 CRUD 增删改查即可。
|
||||
无法满足的场景,例如说多表关联查询,才使用 XML 编写 SQL。
|
||||
代码生成器暂时只生成 Mapper XML 文件本身,更多推荐 MybatisX 快速开发插件来生成查询。
|
||||
文档可见:https://www.iocoder.cn/MyBatis/x-plugins/
|
||||
-->
|
||||
|
||||
</mapper>
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user