瀏覽代碼

全过程项目成员管理和项目计划列表页展示数据数量错误修改

user5 3 年之前
父節點
當前提交
d5dcf47446
共有 1 個文件被更改,包括 9 次插入3 次删除
  1. 9 3
      src/main/resources/mappings/modules/projectrecord/ProjectRecordsDao.xml

+ 9 - 3
src/main/resources/mappings/modules/projectrecord/ProjectRecordsDao.xml

@@ -1221,7 +1221,7 @@
 
 	<select id="processQueryCountByStatus" resultType="int" >
 		SELECT count(DISTINCT a.id)
-		FROM project_records a
+		FROM rural_project_records a
 		LEFT JOIN work_project_user w on a.id = w.project_id
 		LEFT JOIN work_project_user w1 on a.id = w1.project_id
 		LEFT JOIN sys_user su on w.user_id = su.id
@@ -1250,6 +1250,9 @@
 			<if test="sqlMap.dsf !=null and sqlMap.dsf!=''">
 				AND ((w1.user_id = #{currentUser.id} AND w1.del_flag='0' AND (s.id = #{currentUser.company.id} or find_in_set( #{currentUser.company.id}, s.parent_ids ) ))${sqlMap.dsf} )
 			</if>
+			<if test="projectType !=null and projectType !=''">
+				and project_type= #{projectType}
+			</if>
 			AND a.del_flag = #{DEL_FLAG_NORMAL}
 		</where>
 	</select>
@@ -1258,7 +1261,7 @@
 
 	<select id="processProjectPlanCount" resultType="int" >
 		SELECT count(DISTINCT a.id)
-		FROM project_records a
+		FROM rural_project_records a
 		<if test="leaderNameStr !=null and leaderNameStr !=''">
 			LEFT JOIN work_project_user w on a.id = w.project_id
 			LEFT JOIN sys_user su on w.user_id = su.id
@@ -1325,9 +1328,12 @@
 			<if test="endDate !=null">
 				AND a.create_date &lt; #{endDate}
 			</if>
+			<if test="projectType !=null and projectType !=''">
+				and project_type= #{projectType}
+			</if>
 			AND  a.status != 7 AND a.del_flag = #{DEL_FLAG_NORMAL}
 			<if test="sqlMap.dsf !=null and sqlMap.dsf!=''">
-				AND ((w1.user_id = #{currentUser.id} AND w1.del_flag='0' AND a.company_id = #{currentUser.company.id})${sqlMap.dsf} )
+				AND ((w1.user_id = #{currentUser.id} AND w1.del_flag='0' AND a.company_id = #{currentUser.company.id} )${sqlMap.dsf} )
 			</if>
 		</where>
 	</select>