-- 将该建表 SQL 语句，添加到 yudao-module-cms-biz 模块的 test/resources/sql/create_tables.sql 文件里
CREATE TABLE IF NOT EXISTS "cms_contract"
(
    "id"                 bigint   NOT NULL GENERATED BY DEFAULT AS IDENTITY,
    "project_id"         bigint   NOT NULL,
    "name"               varchar  NOT NULL,
    "type"               varchar  NOT NULL,
    "progress"           varchar  NOT NULL,
    "expected_time"      varchar  NOT NULL,
    "printing_time"      varchar  NOT NULL,
    "signing_time"       varchar,
    "archive_time"       varchar,
    "status"             varchar  NOT NULL,
    "count_type"         varchar,
    "remark"             varchar,
    "contract_file_url"  varchar,
    "construction_cost"  varchar,
    "source"             varchar,
    "discount"           varchar,
    "consortium"         bit,
    "consortium_company" varchar,
    "ext_proportion"     varchar,
    "approved_amount"    varchar  NOT NULL,
    "review_file_url"    varchar,
    "creator"            varchar           DEFAULT '',
    "create_time"        datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
    "updater"            varchar           DEFAULT '',
    "update_time"        datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
    "deleted"            bit      NOT NULL DEFAULT FALSE,
    "tenant_id"          bigint   NOT NULL,
    "amount"             varchar,
    "pre_amount"         varchar,
    "design_amount"      varchar,
    "survey_fees"        varchar,
    "measurement_fee"    varchar,
    "other_fee"          varchar,
    PRIMARY KEY ("id")
) COMMENT '合同';

