| | |
| | | <result property="continueContent" column="continue_content"/> |
| | | <result property="continueCount" column="continue_count"/> |
| | | <result property="continueTimeNext" column="continue_time_next"/> |
| | | <result property="operationItemId" column="operation_item_id"/> |
| | | </resultMap> |
| | | |
| | | <resultMap type="com.smartor.domain.ServiceSubtaskCount" id="ServiceSubtaskResult2"> |
| | |
| | | continue_content, |
| | | continue_count, |
| | | continue_time_next, |
| | | operation_item_id, |
| | | task_situation |
| | | from service_subtask |
| | | </sql> |
| | |
| | | </if> |
| | | </if> |
| | | <if test="deptOrDistrict==2"> |
| | | AND (1=1 |
| | | <if test="leavehospitaldistrictcodes != null and leavehospitaldistrictcodes.size() > 0"> |
| | | AND (leavehospitaldistrictcode IN |
| | | AND leavehospitaldistrictcode IN |
| | | <foreach collection="leavehospitaldistrictcodes" item="leavehospitaldistrictcode" open="(" |
| | | separator="," |
| | | close=")"> |
| | |
| | | <if test=" leaveldeptcodes != null and leaveldeptcodes.size()>0"> |
| | | OR deptcode IN |
| | | <foreach collection="leaveldeptcodes" item="leaveldeptcode" open="(" separator="," |
| | | close="))"> |
| | | close=")"> |
| | | #{leaveldeptcode} |
| | | </foreach> |
| | | </if> |
| | | </if>) |
| | | </if> |
| | | <if test="deptOrDistrict==3"> |
| | | AND (1=1 |
| | | <if test="leavehospitaldistrictcodes != null and leavehospitaldistrictcodes.size() > 0"> |
| | | AND (leavehospitaldistrictcode IN |
| | | AND leavehospitaldistrictcode IN |
| | | <foreach collection="leavehospitaldistrictcodes" item="leavehospitaldistrictcode" open="(" |
| | | separator="," |
| | | close=")"> |
| | |
| | | </foreach> |
| | | </if> |
| | | <if test=" visitDeptCodes != null and visitDeptCodes.size()>0"> |
| | | and visit_dept_code IN |
| | | AND visit_dept_code IN |
| | | <foreach collection="visitDeptCodes" item="visitDeptCode" open="(" separator="," |
| | | close="))"> |
| | | close=")"> |
| | | #{visitDeptCode} |
| | | </foreach> |
| | | </if> |
| | | ) |
| | | </if> |
| | | |
| | | <if test="deptOrDistrict==4"> |
| | | AND (1=1 |
| | | <if test="leavehospitaldistrictcodes != null and leavehospitaldistrictcodes.size() > 0"> |
| | | AND (leavehospitaldistrictcode IN |
| | | AND leavehospitaldistrictcode IN |
| | | <foreach collection="leavehospitaldistrictcodes" item="leavehospitaldistrictcode" open="(" |
| | | separator="," |
| | | close=")"> |
| | |
| | | <if test=" visitDeptCodes != null and visitDeptCodes.size()>0"> |
| | | OR visit_dept_code IN |
| | | <foreach collection="visitDeptCodes" item="visitDeptCode" open="(" separator="," |
| | | close="))"> |
| | | close=")"> |
| | | #{visitDeptCode} |
| | | </foreach> |
| | | </if> |
| | | ) |
| | | </if> |
| | | |
| | | <if test="visitTime != null"> |
| | |
| | | AND date_format(visit_time,'%y%m%d') <= date_format(#{endtime},'%y%m%d') |
| | | </if> |
| | | <if test="orgid != null and orgid != ''">and orgid = #{orgid}</if> |
| | | <if test="serviceType != null and serviceType != ''">and service_type = #{serviceType}</if> |
| | | <if test="serviceTypes != null and serviceTypes != ''">and service_type IN (#{serviceTypes})</if> |
| | | <if test="deptcode != null and deptcode != ''">and deptcode = #{deptcode}</if> |
| | | <if test="deptname != null and deptname != ''">and deptname = #{deptname}</if> |
| | | <if test="isabnormal != null">and isabnormal = #{isabnormal}</if> |
| | |
| | | AND date_format(visit_time,'%y%m%d') <= date_format(#{endtime},'%y%m%d') |
| | | </if> |
| | | <if test="orgid != null and orgid != ''">and orgid = #{orgid}</if> |
| | | <if test="serviceType != null and serviceType != ''">and service_type = #{serviceType}</if> |
| | | <if test="serviceTypes != null and serviceTypes != ''">and service_type IN (#{serviceTypes})</if> |
| | | <if test="isabnormal != null ">and isabnormal = #{isabnormal}</if> |
| | | <if test="deptcode != null and deptcode != ''">and deptcode = #{deptcode}</if> |
| | | <if test="deptname != null and deptname != ''">and deptname = #{deptname}</if> |
| | |
| | | <if test="continueCount != null ">continue_count,</if> |
| | | <if test="continueTimeNext != null ">continue_time_next,</if> |
| | | <if test="continueContent != null ">continue_content,</if> |
| | | <if test="operationItemId != null ">operation_item_id,</if> |
| | | </trim> |
| | | <trim prefix="values (" suffix=")" suffixOverrides=","> |
| | | <if test="sendname != null">#{sendname},</if> |
| | |
| | | <if test="continueCount != null ">#{continueCount},</if> |
| | | <if test="continueTimeNext != null ">#{continueTimeNext,jdbcType=TIMESTAMP},</if> |
| | | <if test="continueContent != null ">#{continueContent},</if> |
| | | <if test="operationItemId != null ">#{operationItemId},</if> |
| | | </trim> |
| | | </insert> |
| | | |
| | |
| | | <if test="continueCount != null ">continue_count = #{continueCount},</if> |
| | | <if test="continueTimeNext != null ">continue_time_next = #{continueTimeNext,jdbcType=TIMESTAMP},</if> |
| | | <if test="continueContent != null ">continue_content = #{continueContent},</if> |
| | | <if test="operationItemId != null ">operation_item_id = #{operationItemId},</if> |
| | | </trim> |
| | | where id = #{id} |
| | | </update> |