created migration for quicklog user option
这个提交包含在:
父节点
559f3d1923
当前提交
139668fcc8
共有 1 个文件被更改,包括 29 次插入 和 0 次删除
|
|
@ -0,0 +1,29 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||||
|
|
||||||
|
/*
|
||||||
|
* This adds an option to enable the
|
||||||
|
* QUICKLOG Feature
|
||||||
|
*/
|
||||||
|
|
||||||
|
class Migration_quicklog extends CI_Migration {
|
||||||
|
|
||||||
|
public function up()
|
||||||
|
{
|
||||||
|
if (!$this->db->field_exists('user_quicklog', 'users')) {
|
||||||
|
$fields = array(
|
||||||
|
'user_quicklog integer DEFAULT 0 AFTER user_default_confirmation',
|
||||||
|
);
|
||||||
|
|
||||||
|
$this->dbforge->add_column('users', $fields);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public function down()
|
||||||
|
{
|
||||||
|
if ($this->db->field_exists('user_quicklog', 'users')) {
|
||||||
|
$this->dbforge->drop_column('users', 'user_quicklog');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
正在加载…
在新工单中引用