|  | @@ -277,10 +277,9 @@
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |      <select id="pageQuestion" resultType="com.xunmei.core.question.domain.Question">
 |  |      <select id="pageQuestion" resultType="com.xunmei.core.question.domain.Question">
 | 
											
												
													
														|  |          select * from core_question q
 |  |          select * from core_question q
 | 
											
												
													
														|  | -        inner join sys_org o on q.org_id =o.id
 |  | 
 | 
											
												
													
														|  |          where 1=1
 |  |          where 1=1
 | 
											
												
													
														|  |          <if test="params.checkSub==true">
 |  |          <if test="params.checkSub==true">
 | 
											
												
													
														|  | -            and o.path like concat((select path from sys_org where id=#{params.orgId}),"%")
 |  | 
 | 
											
												
													
														|  | 
 |  | +            and q.org_path like concat((select path from sys_org where id=#{params.orgId}),"%")
 | 
											
												
													
														|  |          </if>
 |  |          </if>
 | 
											
												
													
														|  |          <if test="params.checkSub!=true">
 |  |          <if test="params.checkSub!=true">
 | 
											
												
													
														|  |              and q.org_id=#{params.orgId}
 |  |              and q.org_id=#{params.orgId}
 | 
											
										
											
												
													
														|  | @@ -304,10 +303,9 @@
 | 
											
												
													
														|  |      </select>
 |  |      </select>
 | 
											
												
													
														|  |      <select id="pageApp" resultType="com.xunmei.core.question.domain.Question">
 |  |      <select id="pageApp" resultType="com.xunmei.core.question.domain.Question">
 | 
											
												
													
														|  |          select * from core_question q
 |  |          select * from core_question q
 | 
											
												
													
														|  | -        inner join sys_org o on q.org_id =o.id
 |  | 
 | 
											
												
													
														|  |          where 1=1
 |  |          where 1=1
 | 
											
												
													
														|  |          <if test="params.checkSub==true">
 |  |          <if test="params.checkSub==true">
 | 
											
												
													
														|  | -            and o.path like concat((select path from sys_org where id=#{params.orgId}),"%")
 |  | 
 | 
											
												
													
														|  | 
 |  | +            and q.org_path like concat((select path from sys_org where id=#{params.orgId}),"%")
 | 
											
												
													
														|  |          </if>
 |  |          </if>
 | 
											
												
													
														|  |          <if test="params.checkSub!=true">
 |  |          <if test="params.checkSub!=true">
 | 
											
												
													
														|  |              and q.org_id=#{params.orgId}
 |  |              and q.org_id=#{params.orgId}
 | 
											
										
											
												
													
														|  | @@ -334,10 +332,10 @@
 | 
											
												
													
														|  |      </select>
 |  |      </select>
 | 
											
												
													
														|  |      <select id="pageReform" resultType="com.xunmei.core.question.domain.Question">
 |  |      <select id="pageReform" resultType="com.xunmei.core.question.domain.Question">
 | 
											
												
													
														|  |          select * from core_question q
 |  |          select * from core_question q
 | 
											
												
													
														|  | -        inner join sys_org o on q.org_id =o.id
 |  | 
 | 
											
												
													
														|  | 
 |  | +<!--        inner join sys_org o on q.org_id =o.id-->
 | 
											
												
													
														|  |          where q.confirm_status>=2 and q.reform_status is not null
 |  |          where q.confirm_status>=2 and q.reform_status is not null
 | 
											
												
													
														|  |          <if test="params.checkSub==true">
 |  |          <if test="params.checkSub==true">
 | 
											
												
													
														|  | -            and o.path like concat((select path from sys_org where id=#{params.orgId}),"%")
 |  | 
 | 
											
												
													
														|  | 
 |  | +            and q.org_path like concat((select path from sys_org where id=#{params.orgId}),"%")
 | 
											
												
													
														|  |          </if>
 |  |          </if>
 | 
											
												
													
														|  |          <if test="params.checkSub!=true">
 |  |          <if test="params.checkSub!=true">
 | 
											
												
													
														|  |              and q.org_id=#{params.orgId}
 |  |              and q.org_id=#{params.orgId}
 | 
											
										
											
												
													
														|  | @@ -391,6 +389,7 @@
 | 
											
												
													
														|  |          q.question_desc,
 |  |          q.question_desc,
 | 
											
												
													
														|  |          q.submitor_name,
 |  |          q.submitor_name,
 | 
											
												
													
														|  |          q.submit_time,
 |  |          q.submit_time,
 | 
											
												
													
														|  | 
 |  | +        q.confirm_status,
 | 
											
												
													
														|  |          q.reform_deadline,
 |  |          q.reform_deadline,
 | 
											
												
													
														|  |          case q.src_type when 1 then '确认' else ( case f1.execute_status when 0 then '确认' when 1 then '提出异议' else
 |  |          case q.src_type when 1 then '确认' else ( case f1.execute_status when 0 then '确认' when 1 then '提出异议' else
 | 
											
												
													
														|  |          '未确认'
 |  |          '未确认'
 | 
											
										
											
												
													
														|  | @@ -408,21 +407,26 @@
 | 
											
												
													
														|  |          left join core_question_flow f2 on q.id = f2.question_id and f2.execute_step = 2
 |  |          left join core_question_flow f2 on q.id = f2.question_id and f2.execute_step = 2
 | 
											
												
													
														|  |          left join core_question_flow f3 on q.id = f3.question_id and f3.execute_step = 11
 |  |          left join core_question_flow f3 on q.id = f3.question_id and f3.execute_step = 11
 | 
											
												
													
														|  |          where 1=1
 |  |          where 1=1
 | 
											
												
													
														|  | -        <if test="param.checkSub==true">
 |  | 
 | 
											
												
													
														|  | -            and q.org_path like concat((select `path` from sys_org where id = #{param.orgId}),'%')
 |  | 
 | 
											
												
													
														|  | 
 |  | +        <if test="params.checkSub==true">
 | 
											
												
													
														|  | 
 |  | +            and q.org_path like concat((select path from sys_org where id=#{params.orgId}),"%")
 | 
											
												
													
														|  |          </if>
 |  |          </if>
 | 
											
												
													
														|  | -        <if test="param.checkSub==false">
 |  | 
 | 
											
												
													
														|  | -            and q.org_id=#{param.orgId}
 |  | 
 | 
											
												
													
														|  | 
 |  | +        <if test="params.checkSub!=true">
 | 
											
												
													
														|  | 
 |  | +            and q.org_id=#{params.orgId}
 | 
											
												
													
														|  |          </if>
 |  |          </if>
 | 
											
												
													
														|  | -        <if test="param.confirmStatus!=null">
 |  | 
 | 
											
												
													
														|  | -            and q.confirm_status=#{param.confirmStatus}
 |  | 
 | 
											
												
													
														|  | 
 |  | +        <if test="params.confirmStatus!=null">
 | 
											
												
													
														|  | 
 |  | +            <if test="params.confirmStatus==4">
 | 
											
												
													
														|  | 
 |  | +                and (q.confirm_status!=3) and q.reform_deadline < #{today}
 | 
											
												
													
														|  | 
 |  | +            </if>
 | 
											
												
													
														|  | 
 |  | +            <if test="params.confirmStatus!=4">
 | 
											
												
													
														|  | 
 |  | +                and q.confirm_status=#{params.confirmStatus}
 | 
											
												
													
														|  | 
 |  | +            </if>
 | 
											
												
													
														|  |          </if>
 |  |          </if>
 | 
											
												
													
														|  | -        <if test="param.searchKey!=null">
 |  | 
 | 
											
												
													
														|  | -            and (q.check_item like concat('%',#{param.searchKey},'%') or q.src_task_name like
 |  | 
 | 
											
												
													
														|  | -            concat('%',#{param.searchKey},'%'))
 |  | 
 | 
											
												
													
														|  | 
 |  | +        <if test="params.submitRange!=null and params.submitRange.length==2">
 | 
											
												
													
														|  | 
 |  | +            and q.submit_time between #{params.submitRange[0]} and #{params.submitRange[1]}
 | 
											
												
													
														|  |          </if>
 |  |          </if>
 | 
											
												
													
														|  | -        <if test="param.submitRange!=null and param.submitRange.length==2">
 |  | 
 | 
											
												
													
														|  | -            and q.submit_time between #{param.submitRange[0]} and #{param.submitRange[1]}
 |  | 
 | 
											
												
													
														|  | 
 |  | +        <if test="params.searchKey!=null">
 | 
											
												
													
														|  | 
 |  | +            and (q.question_desc like concat('%',#{params.searchKey},'%') or q.check_content like
 | 
											
												
													
														|  | 
 |  | +            concat('%',#{params.searchKey},'%'))
 | 
											
												
													
														|  |          </if>
 |  |          </if>
 | 
											
												
													
														|  |          order by q.id desc
 |  |          order by q.id desc
 | 
											
												
													
														|  |      </select>
 |  |      </select>
 | 
											
										
											
												
													
														|  | @@ -434,6 +438,7 @@
 | 
											
												
													
														|  |          q.question_desc,
 |  |          q.question_desc,
 | 
											
												
													
														|  |          q.submitor_name,
 |  |          q.submitor_name,
 | 
											
												
													
														|  |          q.submit_time,
 |  |          q.submit_time,
 | 
											
												
													
														|  | 
 |  | +        q.confirm_status,
 | 
											
												
													
														|  |          q.reform_deadline,
 |  |          q.reform_deadline,
 | 
											
												
													
														|  |          case q.src_type when 1 then '确认' else ( case f1.execute_status when 0 then '确认' when 1 then '提出异议' else
 |  |          case q.src_type when 1 then '确认' else ( case f1.execute_status when 0 then '确认' when 1 then '提出异议' else
 | 
											
												
													
														|  |          '未确认'
 |  |          '未确认'
 | 
											
										
											
												
													
														|  | @@ -450,25 +455,27 @@
 | 
											
												
													
														|  |          left join core_question_flow f1 on q.id = f1.question_id and f1.execute_step = 1
 |  |          left join core_question_flow f1 on q.id = f1.question_id and f1.execute_step = 1
 | 
											
												
													
														|  |          left join core_question_flow f2 on q.id = f2.question_id and f2.execute_step = 2
 |  |          left join core_question_flow f2 on q.id = f2.question_id and f2.execute_step = 2
 | 
											
												
													
														|  |          left join core_question_flow f3 on q.id = f3.question_id and f3.execute_step = 11
 |  |          left join core_question_flow f3 on q.id = f3.question_id and f3.execute_step = 11
 | 
											
												
													
														|  | -        where 1=1
 |  | 
 | 
											
												
													
														|  | -        <if test="param.checkSub==true">
 |  | 
 | 
											
												
													
														|  | -            and q.org_path like concat((select `path` from sys_org where id = #{param.orgId}),'%')
 |  | 
 | 
											
												
													
														|  | -        </if>
 |  | 
 | 
											
												
													
														|  | -        <if test="param.checkSub==false">
 |  | 
 | 
											
												
													
														|  | -            and q.org_id=#{param.orgId}
 |  | 
 | 
											
												
													
														|  | 
 |  | +        where q.confirm_status>=2 and q.reform_status is not null
 | 
											
												
													
														|  | 
 |  | +        <if test="params.checkSub==true">
 | 
											
												
													
														|  | 
 |  | +            and q.org_path like concat((select path from sys_org where id=#{params.orgId}),"%")
 | 
											
												
													
														|  |          </if>
 |  |          </if>
 | 
											
												
													
														|  | -        <if test="param.reformStatus==null">
 |  | 
 | 
											
												
													
														|  | -            and q.confirm_status>=2
 |  | 
 | 
											
												
													
														|  | 
 |  | +        <if test="params.checkSub!=true">
 | 
											
												
													
														|  | 
 |  | +            and q.org_id=#{params.orgId}
 | 
											
												
													
														|  |          </if>
 |  |          </if>
 | 
											
												
													
														|  | -        <if test="param.reformStatus!=null">
 |  | 
 | 
											
												
													
														|  | -            and q.reform_status=#{param.reformStatus}
 |  | 
 | 
											
												
													
														|  | 
 |  | +        <if test="params.reformStatus!=null">
 | 
											
												
													
														|  | 
 |  | +            <if test="params.reformStatus==12">
 | 
											
												
													
														|  | 
 |  | +                and q.confirm_status!=3 and q.reform_deadline < #{today}
 | 
											
												
													
														|  | 
 |  | +            </if>
 | 
											
												
													
														|  | 
 |  | +            <if test="params.reformStatus!=12">
 | 
											
												
													
														|  | 
 |  | +                and q.reform_status=#{params.reformStatus}
 | 
											
												
													
														|  | 
 |  | +            </if>
 | 
											
												
													
														|  |          </if>
 |  |          </if>
 | 
											
												
													
														|  | -        <if test="param.searchKey!=null">
 |  | 
 | 
											
												
													
														|  | -            and (q.check_content like concat('%',#{param.searchKey},'%') or q.src_task_name like
 |  | 
 | 
											
												
													
														|  | -            concat('%',#{param.searchKey},'%'))
 |  | 
 | 
											
												
													
														|  | 
 |  | +        <if test="params.reformRange!=null and params.reformRange.length==2">
 | 
											
												
													
														|  | 
 |  | +            and q.reform_deadline between #{params.reformRange[0]} and #{params.reformRange[1]}
 | 
											
												
													
														|  |          </if>
 |  |          </if>
 | 
											
												
													
														|  | -        <if test="param.reformRange!=null and param.reformRange.length==2">
 |  | 
 | 
											
												
													
														|  | -            and q.reform_deadline between #{param.reformRange[0]} and #{param.reformRange[1]}
 |  | 
 | 
											
												
													
														|  | 
 |  | +        <if test="params.searchKey!=null">
 | 
											
												
													
														|  | 
 |  | +            and (q.question_desc like concat('%',#{params.searchKey},'%') or q.check_content like
 | 
											
												
													
														|  | 
 |  | +            concat('%',#{params.searchKey},'%'))
 | 
											
												
													
														|  |          </if>
 |  |          </if>
 | 
											
												
													
														|  |          order by q.id desc
 |  |          order by q.id desc
 | 
											
												
													
														|  |      </select>
 |  |      </select>
 |