From b56a59e06e76c635e5f12931ed98852367b867d8 Mon Sep 17 00:00:00 2001 From: jinlin <jinlin> Date: 星期一, 11 三月 2024 11:09:50 +0800 Subject: [PATCH] 修改 --- modules/mainPart/src/main/resources/mapper/taskReliability/ModelRbdDao.xml | 33 ++++++++++++++++++++++++++++++--- 1 files changed, 30 insertions(+), 3 deletions(-) diff --git a/modules/mainPart/src/main/resources/mapper/taskReliability/ModelRbdDao.xml b/modules/mainPart/src/main/resources/mapper/taskReliability/ModelRbdDao.xml index 6832632..67e8be8 100644 --- a/modules/mainPart/src/main/resources/mapper/taskReliability/ModelRbdDao.xml +++ b/modules/mainPart/src/main/resources/mapper/taskReliability/ModelRbdDao.xml @@ -3,8 +3,35 @@ <mapper namespace="com.zt.life.modules.taskReliability.dao.ModelRbdDao"> - <update id="deleteByModelId"> - delete from model_rbd where model_id=#{modelId} - </update> + <select id="getList" resultType="com.zt.life.modules.taskReliability.model.ModelRbd"> + select a.* + from model_rbd a + <where> + a.is_delete = 0 + <if test="productId!=null and productId!=''"> + and a.product_id =${productId} + </if> + <if test="whereSql!=null"> + and ${whereSql} + </if> + </where> + <if test="orderBySql!=null"> + ORDER BY ${orderBySql} + </if> + </select> + <select id="getDiagram" resultType="com.zt.life.modules.taskReliability.model.ModelRbd"> + select a.* + from model_rbd a + <where> + a.is_delete = 0 + and a.id=#{modelId} + </where> + limit 1 + </select> + <update id="deleteByModelId"> + delete + from model_rbd + where id = #{modelId} + </update> </mapper> -- Gitblit v1.9.1