hasTable($table)) { return; } // 创建数据表 $this->table($table, [ 'engine' => 'InnoDB', 'collation' => 'utf8mb4_general_ci', 'comment' => '数据-用户-提现', ]) ->addColumn('uuid', 'integer', ['limit' => 20, 'default' => 0, 'comment' => '用户UID']) ->addColumn('type', 'string', ['limit' => 30, 'default' => '', 'comment' => '提现方式']) ->addColumn('date', 'string', ['limit' => 20, 'default' => '', 'comment' => '提现日期']) ->addColumn('code', 'string', ['limit' => 100, 'default' => '', 'comment' => '提现单号']) ->addColumn('appid', 'string', ['limit' => 100, 'default' => '', 'comment' => '公众号APPID']) ->addColumn('openid', 'string', ['limit' => 100, 'default' => '', 'comment' => '公众号OPENID']) ->addColumn('charge_rate', 'decimal', ['precision' => 20, 'scale' => 4, 'default' => '0.0000', 'comment' => '提现手续费比例']) ->addColumn('charge_amount', 'decimal', ['precision' => 20, 'scale' => 2, 'default' => '0.00', 'comment' => '提现手续费金额']) ->addColumn('amount', 'decimal', ['precision' => 20, 'scale' => 2, 'default' => '0.00', 'comment' => '提现转账金额']) ->addColumn('qrcode', 'string', ['limit' => 999, 'default' => '', 'comment' => '收款码图片地址']) ->addColumn('bank_wseq', 'string', ['limit' => 20, 'default' => '', 'comment' => '微信银行编号']) ->addColumn('bank_name', 'string', ['limit' => 100, 'default' => '', 'comment' => '开户银行名称']) ->addColumn('bank_bran', 'string', ['limit' => 100, 'default' => '', 'comment' => '开户分行名称']) ->addColumn('bank_user', 'string', ['limit' => 100, 'default' => '', 'comment' => '开户账号姓名']) ->addColumn('bank_code', 'string', ['limit' => 100, 'default' => '', 'comment' => '开户银行卡号']) ->addColumn('alipay_user', 'string', ['limit' => 100, 'default' => '', 'comment' => '支付宝姓名']) ->addColumn('alipay_code', 'string', ['limit' => 100, 'default' => '', 'comment' => '支付宝账号']) ->addColumn('remark', 'string', ['limit' => 200, 'default' => '', 'comment' => '提现描述']) ->addColumn('trade_no', 'string', ['limit' => 100, 'default' => '', 'comment' => '交易单号']) ->addColumn('trade_time', 'string', ['limit' => 20, 'default' => '', 'comment' => '打款时间']) ->addColumn('change_time', 'string', ['limit' => 20, 'default' => '', 'comment' => '处理时间']) ->addColumn('change_desc', 'string', ['limit' => 500, 'default' => '', 'comment' => '处理描述']) ->addColumn('audit_status', 'integer', ['limit' => 1, 'default' => 0, 'comment' => '审核状态']) ->addColumn('audit_remark', 'string', ['limit' => 500, 'default' => '', 'comment' => '审核描述']) ->addColumn('audit_datetime', 'string', ['limit' => 20, 'default' => '', 'comment' => '审核时间']) ->addColumn('status', 'integer', ['limit' => 1, 'default' => 1, 'comment' => '提现状态(0失败,1待审核,2已审核,3打款中,4已打款,5已收款)']) ->addColumn('create_at', 'timestamp', ['default' => 'CURRENT_TIMESTAMP', 'comment' => '创建时间']) ->save(); } }