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; + } +}