alterConnectTable(); $this->alterWechatSubscribeTable(); } protected function alterConnectTable() { $this->table('kg_connect') ->addColumn('deleted', 'integer', [ 'null' => false, 'default' => '0', 'limit' => MysqlAdapter::INT_REGULAR, 'signed' => false, 'comment' => '删除标识', 'after' => 'provider', ]) ->save(); } protected function alterWechatSubscribeTable() { $this->table('kg_wechat_subscribe') ->addColumn('union_id', 'string', [ 'null' => false, 'default' => '', 'limit' => 64, 'collation' => 'utf8mb4_general_ci', 'encoding' => 'utf8mb4', 'comment' => '联合ID', 'after' => 'open_id', ]) ->addColumn('deleted', 'integer', [ 'null' => false, 'default' => '0', 'limit' => MysqlAdapter::INT_REGULAR, 'signed' => false, 'comment' => '删除标识', 'after' => 'open_id', ]) ->save(); } }