mrsb.sql 2.8 KB

1234567891011121314151617181920212223242526272829303132333435363738
  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. suspected_num int(11) NOT NULL DEFAULT 0 COMMENT '疑似人数',
  10. remarks varchar(100) NOT NULL DEFAULT '' COMMENT '异常备注',
  11. report_date date (0) COMMENT '上报日期',
  12. ms_status int(11) NOT NULL DEFAULT 1 COMMENT '健康状态:1正常,2异常',
  13. user_create bigint(20) NOT NULL DEFAULT 0 COMMENT '新增人',
  14. time_create datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '新增时间',
  15. user_update bigint(20) NOT NULL DEFAULT 0 COMMENT '修改人',
  16. time_update datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '修改时间',
  17. PRIMARY KEY (report_id) USING BTREE
  18. ) ENGINE = InnoDB default charset=utf8 comment = '每日上报表'
  19. -- ----------------------------
  20. -- Table structure for ms_suspected
  21. -- ----------------------------
  22. DROP TABLE IF EXISTS ms_suspected;
  23. CREATE TABLE ms_suspected (
  24. suspected_id bigint(20) NOT NULL DEFAULT 0 COMMENT '疑似ID',
  25. report_id bigint(20) NOT NULL DEFAULT 0 COMMENT '上报ID',
  26. user_name varchar(50) NOT NULL DEFAULT '' COMMENT '家人姓名',
  27. family_relative int(11) NOT NULL DEFAULT 1 COMMENT '是否家庭成员:1是,2暂住亲友',
  28. medical int(11) NOT NULL DEFAULT 1 COMMENT '是否就医:1否,1是',
  29. condition_status varchar(50) NOT NULL DEFAULT '' COMMENT '疑似情况:1咳嗽,2发烧,3腹泻,4胸痛,5咽痛,6其他 ',
  30. remarks varchar(100) NOT NULL DEFAULT '' COMMENT '异常备注',
  31. user_create bigint(20) NOT NULL DEFAULT 0 COMMENT '新增人',
  32. time_create datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '新增时间',
  33. user_update bigint(20) NOT NULL DEFAULT 0 COMMENT '修改人',
  34. time_update datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '修改时间',
  35. PRIMARY KEY (suspected_id) USING BTREE
  36. ) ENGINE = InnoDB default charset=utf8 comment = '家庭疑似表';