|
|
@@ -11,28 +11,33 @@ |
|
|
|
<resultMap id="BaseResultMap" type="com.mt.wms.empty.vo.CountEleVo"> |
|
|
|
<id column="task_id" property="taskId"/> |
|
|
|
<result column="create_time" property="createTime"/> |
|
|
|
<result column="total_bat" property="value"/> |
|
|
|
<result column="total_bat" property="totalBat"/> |
|
|
|
</resultMap> |
|
|
|
|
|
|
|
<!-- 根据角色查询菜单,角色已分配的菜单标记为选中状态 --> |
|
|
|
<select id="list" |
|
|
|
resultType="com.mt.wms.empty.vo.CountEleVo"> |
|
|
|
SELECT menu.id AS id, |
|
|
|
menu.parent_id AS parentId, |
|
|
|
menu.code AS code, |
|
|
|
menu.name AS name, |
|
|
|
menu.category AS category, |
|
|
|
menu.type AS type, |
|
|
|
menu.order_num AS orderNum, |
|
|
|
roleMenu.id AS checked |
|
|
|
FROM t_sys_menu AS menu |
|
|
|
LEFT JOIN t_sys_role_menu AS roleMenu ON menu.id = roleMenu.menu_id |
|
|
|
AND roleMenu.role_id = #{roleId} |
|
|
|
AND roleMenu.valid = 1 |
|
|
|
WHERE menu.valid = 1 |
|
|
|
AND menu.enabled = 1 |
|
|
|
AND menu.category = #{category} |
|
|
|
ORDER BY menu.order_num |
|
|
|
select |
|
|
|
tpev .task_id , |
|
|
|
tpev.total_bat, |
|
|
|
tpev .create_time , |
|
|
|
tpev .kiln_id |
|
|
|
from |
|
|
|
t_par_ele_value tpev |
|
|
|
inner join( |
|
|
|
select |
|
|
|
max(total_bat) as total_bat , |
|
|
|
task_id |
|
|
|
from |
|
|
|
t_par_ele_value tpev2 |
|
|
|
group by |
|
|
|
task_id |
|
|
|
)tpev3 on |
|
|
|
tpev .task_id = tpev3.task_id |
|
|
|
and tpev .total_bat = tpev3.total_bat |
|
|
|
where tpev .kiln_id =#{kilnId} |
|
|
|
order by tpev .create_time desc |
|
|
|
limit 10 |
|
|
|
</select> |
|
|
|
|
|
|
|
|