use DOANAdmin; -- 菜单 INSERT INTO sys_menu(menuName, parentId, orderNum, path, component, isFrame, isCache, menuType, visible, status, perms, icon, create_by, create_time) VALUES ('工站/资源组', 0, 999, 'PlantWorkstation', 'business/PlantWorkstation', 0, 0, 'C', '0', '0', 'business:plantworkstation:list', 'icon1', 'system', sysdate()); -- 按钮父菜单id SELECT @menuId := LAST_INSERT_ID(); INSERT INTO sys_menu(menuName, parentId, orderNum, path, component, isFrame, isCache, menuType, visible, status, perms, icon, create_by, create_time) VALUES ('查询', @menuId, 1, '#', NULL, 0, 0, 'F', '0', '0', 'business:plantworkstation:query', '', 'system', sysdate()); INSERT INTO sys_menu(menuName, parentId, orderNum, path, component, isFrame, isCache, menuType, visible, status, perms, icon, create_by, create_time) VALUES ('新增', @menuId, 2, '#', NULL, 0, 0, 'F', '0', '0', 'business:plantworkstation:add', '', 'system', sysdate()); INSERT INTO sys_menu(menuName, parentId, orderNum, path, component, isFrame, isCache, menuType, visible, status, perms, icon, create_by, create_time) VALUES ('删除', @menuId, 3, '#', NULL, 0, 0, 'F', '0', '0', 'business:plantworkstation:delete', '', 'system', sysdate()); INSERT INTO sys_menu(menuName, parentId, orderNum, path, component, isFrame, isCache, menuType, visible, status, perms, icon, create_by, create_time) VALUES ('修改', @menuId, 4, '#', NULL, 0, 0, 'F', '0', '0', 'business:plantworkstation:edit', '', 'system', sysdate()); SELECT * FROM sys_menu WHERE parentId = @menuId; SELECT * FROM sys_menu WHERE menuId = @menuId;