crm_menu.sql 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. -- ----------------------------
  2. -- 合同菜单
  3. -- ----------------------------
  4. -- 菜单 SQL
  5. INSERT INTO system_menu(
  6. name, permission, type, sort, parent_id,
  7. path, icon, component, status, component_name
  8. )
  9. VALUES (
  10. '合同管理', '', 2, 0, 1254,
  11. 'contract', '', 'crm/contract/index', 0, 'Contract'
  12. );
  13. -- 按钮父菜单ID
  14. -- 暂时只支持 MySQL。如果你是 Oracle、PostgreSQL、SQLServer 的话,需要手动修改 @parentId 的部分的代码
  15. SELECT @parentId := LAST_INSERT_ID();
  16. -- 按钮 SQL
  17. INSERT INTO system_menu(
  18. name, permission, type, sort, parent_id,
  19. path, icon, component, status
  20. )
  21. VALUES (
  22. '合同查询', 'crm:contract:query', 3, 1, @parentId,
  23. '', '', '', 0
  24. );
  25. INSERT INTO system_menu(
  26. name, permission, type, sort, parent_id,
  27. path, icon, component, status
  28. )
  29. VALUES (
  30. '合同创建', 'crm:contract:create', 3, 2, @parentId,
  31. '', '', '', 0
  32. );
  33. INSERT INTO system_menu(
  34. name, permission, type, sort, parent_id,
  35. path, icon, component, status
  36. )
  37. VALUES (
  38. '合同更新', 'crm:contract:update', 3, 3, @parentId,
  39. '', '', '', 0
  40. );
  41. INSERT INTO system_menu(
  42. name, permission, type, sort, parent_id,
  43. path, icon, component, status
  44. )
  45. VALUES (
  46. '合同删除', 'crm:contract:delete', 3, 4, @parentId,
  47. '', '', '', 0
  48. );
  49. INSERT INTO system_menu(
  50. name, permission, type, sort, parent_id,
  51. path, icon, component, status
  52. )
  53. VALUES (
  54. '合同导出', 'crm:contract:export', 3, 5, @parentId,
  55. '', '', '', 0
  56. );
  57. -- ----------------------------
  58. -- ...菜单
  59. -- ----------------------------