table('option_log', ['engine' => 'InnoDB']); $table->addColumn('user_name', 'string',['limit' => 50, 'default'=>'','comment'=>'用户名']) ->addColumn('user_id', 'integer', ['limit' => MysqlAdapter::INT_REGULAR, 'comment' => '用户ID']) ->addColumn('module', 'string',['limit' => 20, 'default'=>'','comment'=>'模块']) ->addColumn('controller', 'string',['limit' => 20, 'default'=>'','comment'=>'控制器']) ->addColumn('action', 'string',['limit' => 20, 'default'=>'','comment'=>'方法']) ->addColumn('option', 'string',['limit' => 50, 'default'=>'','comment'=>'操作']) ->addColumn('method', 'string',['limit' => 15, 'default'=>'','comment'=>'请求方法']) ->addColumn('created_at', 'timestamp', [ 'default' => 'CURRENT_TIMESTAMP','comment' => '更新时间']) ->create(); } }