visuddhinanda 3 年之前
父節點
當前提交
616c69b4c4
共有 1 個文件被更改,包括 35 次插入0 次删除
  1. 35 0
      database/migrations/2023_04_04_142510_add_index_type_in_wbw_templates.php

+ 35 - 0
database/migrations/2023_04_04_142510_add_index_type_in_wbw_templates.php

@@ -0,0 +1,35 @@
+<?php
+
+use Illuminate\Database\Migrations\Migration;
+use Illuminate\Database\Schema\Blueprint;
+use Illuminate\Support\Facades\Schema;
+
+class AddIndexTypeInWbwTemplates extends Migration
+{
+    /**
+     * Run the migrations.
+     *
+     * @return void
+     */
+    public function up()
+    {
+        Schema::table('wbw_templates', function (Blueprint $table) {
+            //
+            $table->index('type');
+        });
+    }
+
+    /**
+     * Reverse the migrations.
+     *
+     * @return void
+     */
+    public function down()
+    {
+        Schema::table('wbw_templates', function (Blueprint $table) {
+            //
+            $table->dropIndex("wbw_templates_type_index");
+
+        });
+    }
+}