CREATE TABLE IF NOT EXISTS "crm_contract" (
  "id" bigint NOT NULL GENERATED BY DEFAULT AS IDENTITY,
  "name" varchar NOT NULL,
  "customer_id" bigint,
  "business_id" bigint,
  "process_instance_id" bigint,
  "order_date" varchar,
  "owner_user_id" bigint,
  "no" varchar,
  "start_time" varchar,
  "end_time" varchar,
  "price" int,
  "discount_percent" int,
  "product_price" int,
  "ro_user_ids" varchar,
  "rw_user_ids" varchar,
  "contact_id" bigint,
  "sign_user_id" bigint,
  "contact_last_time" varchar,
  "remark" 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,
  PRIMARY KEY ("id")
    ) COMMENT '合同表';