| | |
| | | <result column="ST_Extension3" property="extension3" jdbcType="VARCHAR" /> |
| | | <result column="ST_Remark" property="remark" jdbcType="VARCHAR" /> |
| | | </resultMap> |
| | | |
| | | <resultMap id="SubTaskSummary" type="cn.flightfeather.supervision.lightshare.vo.SubTaskSummary" > |
| | | <result column="ST_GUID" property="stGuid" jdbcType="VARCHAR" /> |
| | | <result column="ST_name" property="stName" jdbcType="VARCHAR" /> |
| | | <result column="ST_PlanStartTime" property="stPlanTime" jdbcType="TIMESTAMP" /> |
| | | <result column="S_GUID" property="sceneId" jdbcType="VARCHAR" /> |
| | | <result column="S_Name" property="sceneName" jdbcType="VARCHAR" /> |
| | | <result column="S_Type" property="sceneType" jdbcType="VARCHAR" /> |
| | | <result column="I_GUID" property="insGuid" jdbcType="VARCHAR" /> |
| | | <result column="proNum" property="proNum" jdbcType="INTEGER" /> |
| | | <result column="changeNum" property="changeNum" jdbcType="INTEGER" /> |
| | | <result column="proCheckedNum" property="proCheckedNum" jdbcType="INTEGER" /> |
| | | <result column="changeCheckedNum" property="changeCheckedNum" jdbcType="INTEGER" /> |
| | | </resultMap> |
| | | <sql id="Base_Column_List" > |
| | | <!-- |
| | | WARNING - @mbg.generated |
| | |
| | | and b.S_TypeID = #{param2} |
| | | </if> |
| | | </select> |
| | | |
| | | <select id="getSummary" resultMap="SubTaskSummary"> |
| | | SELECT |
| | | a.ST_GUID, |
| | | a.ST_name, |
| | | a.ST_PlanStartTime, |
| | | b.S_GUID, |
| | | b.S_Name, |
| | | b.S_Type, |
| | | c.I_GUID, |
| | | SUM(d.PL_GUID is NOT null) AS proNum, |
| | | SUM(d.PL_IsChanged = TRUE) AS changeNum, |
| | | SUM(d.PL_Extension3 != 'unCheck') AS proCheckedNum, |
| | | SUM( |
| | | d.PL_Extension3 = 'change_pass' || d.PL_Extension3 = 'change_fail' |
| | | ) AS changeCheckedNum |
| | | |
| | | FROM |
| | | tm_t_subtask AS a |
| | | LEFT JOIN sm_t_scense AS b ON a.ST_ScenseID = b.S_GUID |
| | | LEFT JOIN im_t_inspection AS c ON a.ST_GUID = c.ST_GUID |
| | | LEFT JOIN im_t_problemlist AS d ON a.ST_GUID = d.ST_GUID |
| | | WHERE |
| | | a.T_GUID = #{param1} |
| | | <if test="param2 != null"> |
| | | and b.S_TypeID = #{param2} |
| | | </if> |
| | | GROUP BY |
| | | a.ST_GUID |
| | | </select> |
| | | </mapper> |