mrsb.sql 4.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. -- ----------------------------
  2. -- Table structure for ms_report
  3. -- ----------------------------
  4. DROP TABLE IF EXISTS ms_report;
  5. CREATE TABLE ms_report (
  6. report_id bigint(20) NOT NULL DEFAULT 0 COMMENT '上报ID',
  7. house_id bigint(20) NOT NULL DEFAULT 0 COMMENT '门牌ID',
  8. safety_num int(11) NOT NULL DEFAULT 0 COMMENT '今日居家人数',
  9. sure_num int(11) NOT NULL DEFAULT 0 COMMENT '确诊人数',
  10. suspected_num int(11) NOT NULL DEFAULT 0 COMMENT '疑似人数',
  11. remarks varchar(200) NOT NULL DEFAULT '' COMMENT '异常备注',
  12. report_date date COMMENT '上报日期',
  13. report_status int(11) NOT NULL DEFAULT 1 COMMENT '上报状态:0草稿,1正常',
  14. ms_status int(11) NOT NULL DEFAULT 1 COMMENT '健康状态:1正常,2异常',
  15. user_create bigint(20) NOT NULL DEFAULT 0 COMMENT '新增人',
  16. time_create datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '新增时间',
  17. user_update bigint(20) NOT NULL DEFAULT 0 COMMENT '修改人',
  18. time_update datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '修改时间',
  19. PRIMARY KEY (report_id) USING BTREE
  20. ) ENGINE = InnoDB default charset=utf8 comment = '每日上报表'
  21. -- ----------------------------
  22. -- Table structure for ms_suspected
  23. -- ----------------------------
  24. DROP TABLE IF EXISTS ms_suspected;
  25. CREATE TABLE ms_suspected (
  26. suspected_id bigint(20) NOT NULL DEFAULT 0 COMMENT '疑似ID',
  27. report_id bigint(20) NOT NULL DEFAULT 0 COMMENT '上报ID',
  28. user_name varchar(50) NOT NULL DEFAULT '' COMMENT '家人姓名',
  29. grender int(11) NOT NULL DEFAULT 1 COMMENT '性别:0未设置,1男,2女',
  30. age int(11) NOT NULL DEFAULT 1 COMMENT '年龄',
  31. family_status int(11) NOT NULL DEFAULT 1 COMMENT '基本状态:1心血管疾病(服用ARB),2心血管疾病(未服用ARB),3呼吸系统病史,4肿瘤病史,5糖尿病史,6服用过激素药物,7妊娠期',
  32. status_desp varchar(100) NOT NULL DEFAULT '' COMMENT '状态描述',
  33. medical int(11) NOT NULL DEFAULT 1 COMMENT '是否确诊:0否,1是',
  34. temperature decimal(14,2) NOT NULL DEFAULT 0 COMMENT '体温',
  35. cough int(11) NOT NULL DEFAULT 0 COMMENT '咳嗽:0无咳嗽,1偶尔短暂咳嗽,2频繁咳嗽轻重,3频繁咳嗽重度',
  36. muscle int(11) NOT NULL DEFAULT 0 COMMENT '肌肉酸痛:0无,1加重,2好转,3无变化',
  37. dyspnea int(11) NOT NULL DEFAULT 0 COMMENT '呼吸困难:0无,1加重,2好转,3无变化,4严重',
  38. chest int(11) NOT NULL DEFAULT 0 COMMENT '胸闷:0无,1端坐呼吸,2活动无,3无变化',
  39. fatigue int(11) NOT NULL DEFAULT 0 COMMENT '乏力:0无,1加重,2好转,3无变化',
  40. diarrhea int(11) NOT NULL DEFAULT 0 COMMENT '腹泻:0无,1有',
  41. diarrhea_num int(11) NOT NULL DEFAULT 0 COMMENT '每日腹泻次数',
  42. others varchar(600) NOT NULL DEFAULT '' COMMENT '其他',
  43. user_create bigint(20) NOT NULL DEFAULT 0 COMMENT '新增人',
  44. time_create datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '新增时间',
  45. user_update bigint(20) NOT NULL DEFAULT 0 COMMENT '修改人',
  46. time_update datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '修改时间',
  47. PRIMARY KEY (suspected_id) USING BTREE
  48. ) ENGINE = InnoDB default charset=utf8 comment = '家庭疑似表';