query_menus.sql 1.0 KB

12345678910111213141516171819202122232425
  1. SELECT '==== PDA CATEGORIES ====' AS t;
  2. SELECT id, title, sort_order, status FROM mes_icons_category ORDER BY sort_order, title;
  3. SELECT '==== PDA ICONS ====' AS t;
  4. SELECT IFNULL(c.title,'未分类') AS category, i.title AS icon, i.mode, i.auth, i.status
  5. FROM mes_icons i
  6. LEFT JOIN mes_icons_category c ON c.id = i.category_id
  7. WHERE i.status = '0'
  8. ORDER BY IFNULL(c.sort_order,9999), IFNULL(c.title,''), i.title;
  9. SELECT '==== GROUPED CONFIG ====' AS t;
  10. SELECT config_key, config_value FROM js_sys_config WHERE config_key LIKE 'mes.icons%';
  11. SELECT '==== SYS MENU ====' AS t;
  12. SELECT tree_level, menu_name, menu_href, is_show, permission, parent_code, menu_code, tree_sorts
  13. FROM js_sys_menu
  14. WHERE status='0' AND menu_type IN ('1','0') AND is_show='1'
  15. ORDER BY tree_sorts, tree_sort;
  16. SELECT '==== LINE PROCESS ====' AS t;
  17. SELECT l.sn AS line_sn, l.title AS line_title, p.oprno, p.title AS process_title, p.status
  18. FROM mes_line_process p
  19. LEFT JOIN mes_line l ON l.id = p.line_id OR l.sn = p.line_sn
  20. WHERE p.status='0'
  21. ORDER BY l.sn, p.oprno;