查询项目信息接口,完善接口逻辑逻辑等

This commit is contained in:
mi9688
2024-10-16 18:00:59 +08:00
parent 834cfc3e7d
commit 0fb3e4bd8d
12 changed files with 123 additions and 59 deletions

View File

@ -25,10 +25,11 @@
<result property="remarks" column="remarks" />
<result property="tenantId" column="tenant_id" />
<result property="tenantName" column="tenant_name" />
<result property="ownerId" column="owner_id" />
</resultMap>
<sql id="selectProjectVo">
select project_id, project_name, sys_show_name, central_coordinates, scope, administrative_area, owner, logo, image, video_introduction, remark, p_params, introduce, del_flag, create_time, create_by, update_time, remarks, tenant_id, tenant_name from project
select project_id, project_name, sys_show_name, central_coordinates, scope, administrative_area, owner, logo, image, video_introduction, remark, p_params, introduce, del_flag, create_time, create_by, update_time, remarks, tenant_id, tenant_name, owner_id from project
</sql>
<select id="selectProjectList" parameterType="Project" resultMap="ProjectResult">
@ -48,6 +49,7 @@
<if test="remarks != null and remarks != ''"> and remarks = #{remarks}</if>
<if test="tenantId != null "> and tenant_id = #{tenantId}</if>
<if test="tenantName != null and tenantName != ''"> and tenant_name like concat('%', #{tenantName}, '%')</if>
<if test="ownerId != null "> and owner_id = #{ownerId}</if>
</where>
</select>
@ -79,6 +81,7 @@
<if test="remarks != null">remarks,</if>
<if test="tenantId != null">tenant_id,</if>
<if test="tenantName != null">tenant_name,</if>
<if test="ownerId != null">owner_id,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="projectId != null">#{projectId},</if>
@ -101,6 +104,7 @@
<if test="remarks != null">#{remarks},</if>
<if test="tenantId != null">#{tenantId},</if>
<if test="tenantName != null">#{tenantName},</if>
<if test="ownerId != null">#{ownerId},</if>
</trim>
</insert>
@ -126,6 +130,7 @@
<if test="remarks != null">remarks = #{remarks},</if>
<if test="tenantId != null">tenant_id = #{tenantId},</if>
<if test="tenantName != null">tenant_name = #{tenantName},</if>
<if test="ownerId != null">owner_id = #{ownerId},</if>
</trim>
where project_id = #{projectId}
</update>