From 798ae3cdcf5d7b1878f476cfdf414b01119c453e Mon Sep 17 00:00:00 2001 From: linyaostalker <602604991@qq.com> Date: Wed, 11 Dec 2019 19:08:45 +0800 Subject: [PATCH] =?UTF-8?q?refactor:=E5=95=86=E5=93=81=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E8=A1=A8=E4=BF=AE=E6=94=B9=E6=8E=92=E5=BA=8F=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...e_column_sort_order_in_table_atg_goods.php | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 backend/modules/goods/migrations/m191211_092335_update_column_sort_order_in_table_atg_goods.php diff --git a/backend/modules/goods/migrations/m191211_092335_update_column_sort_order_in_table_atg_goods.php b/backend/modules/goods/migrations/m191211_092335_update_column_sort_order_in_table_atg_goods.php new file mode 100644 index 0000000..4b3e960 --- /dev/null +++ b/backend/modules/goods/migrations/m191211_092335_update_column_sort_order_in_table_atg_goods.php @@ -0,0 +1,22 @@ +dropColumn('atg_goods', 'sort_order'); + $this->addColumn('atg_goods', 'sort_order', $this->smallInteger(3)->defaultValue("999")->comment('排序')); + } + + public function down() + { + $this->dropColumn('atg_goods', 'sort_order'); + $this->addColumn('atg_goods', 'sort_order', $this->smallInteger(3)->defaultValue(null)->comment('排序')); + return true; + } +}