qc_init_v2.4.0_通用版_消息通知.sql 5.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. use `qc`;
  2. /**
  3. sys_dictionary_info 字段表配置消息通知下拉框搜索内容
  4. */
  5. INSERT INTO `sys_dictionary_info` (`is_deleted`, `gmt_create`, `gmt_modified`, `creator`, `modifier`, `group_type`, `name`, `val`, `return_type`, `order_no`, `remark`) VALUES ('N', '1970-01-01 12:00:00', '1970-01-01 12:00:00', '0', '0', '46', '全部', '', '2', '0', '通知类型');
  6. INSERT INTO `sys_dictionary_info` (`is_deleted`, `gmt_create`, `gmt_modified`, `creator`, `modifier`, `group_type`, `name`, `val`, `return_type`, `order_no`, `remark`) VALUES ('N', '1970-01-01 12:00:00', '1970-01-01 12:00:00', '0', '0', '46', '质控任务', '1', '2', '1', '通知类型');
  7. INSERT INTO `sys_dictionary_info` (`is_deleted`, `gmt_create`, `gmt_modified`, `creator`, `modifier`, `group_type`, `name`, `val`, `return_type`, `order_no`, `remark`) VALUES ('N', '1970-01-01 12:00:00', '1970-01-01 12:00:00', '0', '0', '47', '全部', '', '2', '0', '阅读状态');
  8. INSERT INTO `sys_dictionary_info` (`is_deleted`, `gmt_create`, `gmt_modified`, `creator`, `modifier`, `group_type`, `name`, `val`, `return_type`, `order_no`, `remark`) VALUES ('N', '1970-01-01 12:00:00', '1970-01-01 12:00:00', '0', '0', '47', '未读', '0', '2', '1', '阅读状态');
  9. INSERT INTO `sys_dictionary_info` (`is_deleted`, `gmt_create`, `gmt_modified`, `creator`, `modifier`, `group_type`, `name`, `val`, `return_type`, `order_no`, `remark`) VALUES ('N', '1970-01-01 12:00:00', '1970-01-01 12:00:00', '0', '0', '47', '已读', '1', '2', '2', '阅读状态');
  10. /**
  11. sys_menu 新增消息通知菜单
  12. */
  13. INSERT INTO `sys_menu` (`id`, `is_deleted`, `gmt_create`, `gmt_modified`, `creator`, `modifier`, `name`, `parent_id`, `code`, `show_status`, `maintain_status`, `order_no`, `remark`) VALUES ('120', 'N', '1970-01-01 12:00:00', '1970-01-01 12:00:00', '0', '0', '消息通知', '-1', 'YH-XXTZ', '1', '1', '16', '用户-消息通知');
  14. INSERT INTO `sys_permission` (`id`, `is_deleted`, `gmt_create`, `gmt_modified`, `creator`, `modifier`, `name`, `code`, `permissionUrl`, `method`, `descritpion`, `remark`) VALUES ('210', 'N', '1970-01-01 12:00:00', '1970-01-01 12:00:00', '0', '0', '查看', 'FUNC000210', '/medNewsNotice/getNewsNoticeInfoById', 'ALL', '查看', '用户-消息通知-查看');
  15. INSERT INTO `sys_menu_permission` ( `is_deleted`, `gmt_create`, `gmt_modified`, `creator`, `modifier`, `menu_id`, `permission_id`, `order_nu`, `remark`) VALUES ('N', '1970-01-01 12:00:00', '1970-01-01 12:00:00', '0', '0', '120', '210', NULL, '用户-消息通知-查看');
  16. /**
  17. sys_role_menu 全院、科室、个人、核查人员(院级、科室、质控科)六个角色添加消息通知菜单
  18. */
  19. INSERT INTO `sys_role_menu` (`is_deleted`, `gmt_create`, `gmt_modified`, `creator`, `modifier`, `role_id`, `menu_id`, `remark`) VALUES ('N', '2022-05-05 10:36:44', '2022-05-05 10:36:44', '0', '0', '1', '120', NULL);
  20. INSERT INTO `sys_role_menu` (`is_deleted`, `gmt_create`, `gmt_modified`, `creator`, `modifier`, `role_id`, `menu_id`, `remark`) VALUES ('N', '2022-05-05 10:36:44', '2022-05-05 10:36:44', '0', '0', '2', '120', NULL);
  21. INSERT INTO `sys_role_menu` (`is_deleted`, `gmt_create`, `gmt_modified`, `creator`, `modifier`, `role_id`, `menu_id`, `remark`) VALUES ('N', '2022-05-05 10:36:44', '2022-05-05 10:36:44', '0', '0', '3', '120', NULL);
  22. INSERT INTO `sys_role_menu` (`is_deleted`, `gmt_create`, `gmt_modified`, `creator`, `modifier`, `role_id`, `menu_id`, `remark`) VALUES ('N', '2022-05-05 10:36:44', '2022-05-05 10:36:44', '0', '0', '7', '120', NULL);
  23. INSERT INTO `sys_role_menu` (`is_deleted`, `gmt_create`, `gmt_modified`, `creator`, `modifier`, `role_id`, `menu_id`, `remark`) VALUES ('N', '2022-05-05 10:36:44', '2022-05-05 10:36:44', '0', '0', '8', '120', NULL);
  24. INSERT INTO `sys_role_menu` (`is_deleted`, `gmt_create`, `gmt_modified`, `creator`, `modifier`, `role_id`, `menu_id`, `remark`) VALUES ('N', '2022-05-05 10:36:44', '2022-05-05 10:36:44', '0', '0', '9', '120', NULL);
  25. /**
  26. med_news_notice 消息通知表
  27. */
  28. DROP TABLE IF EXISTS `med_news_notice`;
  29. CREATE TABLE `med_news_notice` (
  30. `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键',
  31. `hospital_id` bigint(11) DEFAULT NULL COMMENT '医院ID',
  32. `title` varchar(512) NOT NULL COMMENT '标题',
  33. `type` char(3) DEFAULT '0' COMMENT '通知类型,1:质控任务 0:其他',
  34. `news` longtext COMMENT '消息',
  35. `status` char(3) DEFAULT '0' COMMENT '阅读状态,0:未读 1:已读',
  36. `sender` varchar(20) DEFAULT '0' COMMENT '发送者',
  37. `receiver` varchar(20) DEFAULT '0' COMMENT '接收者',
  38. `is_deleted` char(3) DEFAULT 'N' COMMENT '是否删除,N:未删除,Y:删除',
  39. `gmt_create` datetime DEFAULT '1970-01-01 12:00:00' COMMENT '记录创建时间',
  40. `gmt_modified` datetime DEFAULT '1970-01-01 12:00:00' COMMENT '记录修改时间,如果时间是1970年则表示纪录未修改',
  41. `creator` varchar(60) DEFAULT '0' COMMENT '创建人,0表示无创建人值',
  42. `modifier` varchar(60) DEFAULT '0' COMMENT '修改人,如果为0则表示纪录未修改',
  43. PRIMARY KEY (`id`)
  44. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='消息通知表';