Browse Source

修改查询筛选条件del_flag = 0

zjc 1 year ago
parent
commit
1e2bfa34d2

+ 1 - 1
ruoyi-admin/src/main/java/com/ruoyi/web/controller/tool/TUnifyFileController.java

@@ -109,7 +109,7 @@ public class TUnifyFileController extends BaseController
 	@DeleteMapping("/{ids}")
     public AjaxResult remove(@PathVariable String[] ids)
     {
-        return toAjax(tUnifyFileService.deleteTUnifyFileByIds(ids));
+        return toAjax(tUnifyFileService.updateTUnifyFileByIds(ids));
     }
 
     /**

+ 9 - 0
ruoyi-system/src/main/java/com/ruoyi/tool/mapper/TUnifyFileMapper.java

@@ -58,4 +58,13 @@ public interface TUnifyFileMapper
      * @return 结果
      */
     public int deleteTUnifyFileByIds(String[] ids);
+
+    /**
+     * 批量删除附件 (修改del_flag状态)
+     *
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    public int updateTUnifyFileByIds(String[] ids);
+
 }

+ 8 - 0
ruoyi-system/src/main/java/com/ruoyi/tool/service/ITUnifyFileService.java

@@ -62,4 +62,12 @@ public interface ITUnifyFileService
      */
     public int deleteTUnifyFileById(String id);
 
+    /**
+     * 批量删除附件
+     *
+     * @param ids
+     * @return
+     */
+    int updateTUnifyFileByIds(String[] ids);
+
 }

+ 10 - 0
ruoyi-system/src/main/java/com/ruoyi/tool/service/impl/TUnifyFileServiceImpl.java

@@ -104,4 +104,14 @@ public class TUnifyFileServiceImpl implements ITUnifyFileService
         return tUnifyFileMapper.deleteTUnifyFileById(id);
     }
 
+    /**
+     * 批量删除附件 (修改del_flag状态)
+     * @param ids
+     * @return
+     */
+    @Override
+    public int updateTUnifyFileByIds(String[] ids) {
+        return tUnifyFileMapper.updateTUnifyFileByIds(ids);
+    }
+
 }

+ 2 - 1
ruoyi-system/src/main/resources/mapper/invest/TProjectChannelMapper.xml

@@ -29,7 +29,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
     <select id="selectTProjectChannelList" parameterType="TProjectChannel" resultMap="TProjectChannelResult">
         <include refid="selectTProjectChannelVo"/>
-        <where>  
+        <where>
+            del_flag = 0
             <if test="channelName != null  and channelName != ''"> and channel_name like concat('%', #{channelName}, '%')</if>
             <if test="channelCode != null  and channelCode != ''"> and channel_code = #{channelCode}</if>
             <if test="channelType != null  and channelType != ''"> and channel_type = #{channelType}</if>

+ 2 - 1
ruoyi-system/src/main/resources/mapper/invest/TProjectCompanyMapper.xml

@@ -31,7 +31,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
     <select id="selectTProjectCompanyList" parameterType="TProjectCompany" resultMap="TProjectCompanyResult">
         <include refid="selectTProjectCompanyVo"/>
-        <where>  
+        <where>
+            del_flag = 0
             <if test="companyName != null  and companyName != ''"> and company_name like concat('%', #{companyName}, '%')</if>
             <if test="companyCode != null  and companyCode != ''"> and company_code = #{companyCode}</if>
             <if test="startTime != null "> and start_time = #{startTime}</if>

+ 2 - 1
ruoyi-system/src/main/resources/mapper/invest/TProjectContactsMapper.xml

@@ -23,7 +23,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
     <select id="selectTProjectContactsList" parameterType="TProjectContacts" resultMap="TProjectContactsResult">
         <include refid="selectTProjectContactsVo"/>
-        <where>  
+        <where>
+            del_flag = 0
             <if test="name != null  and name != ''"> and name like concat('%', #{name}, '%')</if>
             <if test="position != null  and position != ''"> and position like concat('%', #{position}, '%')</if>
             <if test="contact != null  and contact != ''"> and contact like concat('%', #{contact}, '%')</if>

+ 2 - 1
ruoyi-system/src/main/resources/mapper/invest/TProjectInformationMapper.xml

@@ -26,7 +26,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
     <select id="selectTProjectInformationList" parameterType="TProjectInformation" resultMap="TProjectInformationResult">
         <include refid="selectTProjectInformationVo"/>
-        <where>  
+        <where>
+            del_flag = 0
             <if test="fileName != null  and fileName != ''"> and file_name like concat('%', #{fileName}, '%')</if>
             <if test="fileType != null  and fileType != ''"> and file_type = #{fileType}</if>
             <if test="projectStage != null  and projectStage != ''"> and project_stage = #{projectStage}</if>

+ 2 - 1
ruoyi-system/src/main/resources/mapper/invest/TProjectMeetingMapper.xml

@@ -28,7 +28,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
     <select id="selectTProjectMeetingList" parameterType="TProjectMeeting" resultMap="TProjectMeetingResult">
         <include refid="selectTProjectMeetingVo"/>
-        <where>  
+        <where>
+            del_flag = 0
             <if test="meetingTheme != null  and meetingTheme != ''"> and meeting_theme = #{meetingTheme}</if>
             <if test="meetingCode != null  and meetingCode != ''"> and meeting_code = #{meetingCode}</if>
             <if test="meetingType != null  and meetingType != ''"> and meeting_type = #{meetingType}</if>

+ 2 - 1
ruoyi-system/src/main/resources/mapper/invest/TProjectPoolMapper.xml

@@ -47,7 +47,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
     <select id="selectTProjectPoolList" parameterType="TProjectPool" resultMap="TProjectPoolResult">
         <include refid="selectTProjectPoolVo"/>
-        <where>  
+        <where>
+            del_flag = 0
             <if test="porjectName != null  and porjectName != ''"> and porject_name like concat('%', #{porjectName}, '%')</if>
             <if test="porjectGroup != null  and porjectGroup != ''"> and porject_group = #{porjectGroup}</if>
             <if test="porjectCode != null  and porjectCode != ''"> and porject_code = #{porjectCode}</if>

+ 2 - 1
ruoyi-system/src/main/resources/mapper/invest/TProjectRecordMapper.xml

@@ -26,7 +26,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
     <select id="selectTProjectRecordList" parameterType="TProjectRecord" resultMap="TProjectRecordResult">
         <include refid="selectTProjectRecordVo"/>
-        <where>  
+        <where>
+            del_flag = 0
             <if test="porjectId != null  and porjectId != ''"> and porject_id = #{porjectId}</if>
             <if test="contacts != null  and contacts != ''"> and contacts = #{contacts}</if>
             <if test="realityUpDate != null "> and reality_up_date = #{realityUpDate}</if>

+ 2 - 1
ruoyi-system/src/main/resources/mapper/invest/TProjectScoringMapper.xml

@@ -53,7 +53,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
     <select id="selectTProjectScoringList" parameterType="TProjectScoring" resultMap="TProjectScoringResult">
         <include refid="selectTProjectScoringVo"/>
-        <where>  
+        <where>
+            del_flag = 0
             <if test="projectPoolId != null  and projectPoolId != ''"> and project_pool_id = #{projectPoolId}</if>
             <if test="investCommissioner != null  and investCommissioner != ''"> and invest_commissioner = #{investCommissioner}</if>
             <if test="scoringPerson != null  and scoringPerson != ''"> and scoring_person = #{scoringPerson}</if>

+ 2 - 1
ruoyi-system/src/main/resources/mapper/invest/TStudyInformationMapper.xml

@@ -23,7 +23,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
     <select id="selectTStudyInformationList" parameterType="TStudyInformation" resultMap="TStudyInformationResult">
         <include refid="selectTStudyInformationVo"/>
-        <where>  
+        <where>
+            del_flag = 0
             <if test="contractName != null  and contractName != ''"> and contract_name like concat('%', #{contractName}, '%')</if>
             <if test="contractType != null  and contractType != ''"> and contract_type = #{contractType}</if>
             <if test="fileBusinessId != null  and fileBusinessId != ''"> and file_business_id = #{fileBusinessId}</if>

+ 11 - 0
ruoyi-system/src/main/resources/mapper/tool/TUnifyFileMapper.xml

@@ -105,4 +105,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             #{id}
         </foreach>
     </delete>
+
+    <update id="updateTUnifyFileByIds" parameterType="TUnifyFile">
+        update t_unify_file
+        set del_flag = 1
+        where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </update>
+
+
 </mapper>