Files
yunzerwebsiteallinone/go/docs/sql/create_oa_dailyreport_history.sql
T
2026-11-16 17:22:50 +08:00

22 lines
1.2 KiB
SQL
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
SET NAMES utf8mb4;
CREATE TABLE IF NOT EXISTS `yz_backend_oa_daily_report_history` (
`id` BIGINT UNSIGNED NOT NULL AUTO_INCREMENT,
`tid` BIGINT UNSIGNED NOT NULL DEFAULT 0 COMMENT '租户ID',
`report_id` BIGINT UNSIGNED NOT NULL DEFAULT 0 COMMENT '日报ID(yz_backend_oa_daily_report.id)',
`user_id` BIGINT UNSIGNED NOT NULL DEFAULT 0 COMMENT '操作人uid(yz_system_tenant_user.uid)',
`user_name` VARCHAR(50) NOT NULL DEFAULT '' COMMENT '操作人姓名快照',
`report_date` DATE NOT NULL COMMENT '日报日期',
`action` TINYINT NOT NULL DEFAULT 1 COMMENT '1撤销提交 2重新提交',
`today_done` TEXT COMMENT '快照:今日完成',
`tomorrow_plan` TEXT COMMENT '快照:明日计划',
`issues` TEXT COMMENT '快照:问题与建议',
`attachments` TEXT COMMENT '快照:附件JSON数组',
`submit_time` DATETIME DEFAULT NULL COMMENT '快照:提交时间',
`create_time` DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY (`id`),
KEY `idx_tid_report` (`tid`, `report_id`, `id`),
KEY `idx_tid_date` (`tid`, `report_date`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='OA-工作日报修改痕迹';