We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ad5e253 commit 4e60adcCopy full SHA for 4e60adc
database/migrations/2016_02_20_155318_add_unique_service_field.php
@@ -0,0 +1,31 @@
1
+<?php
2
+
3
+use Illuminate\Database\Schema\Blueprint;
4
+use Illuminate\Database\Migrations\Migration;
5
6
+class AddUniqueServiceField extends Migration
7
+{
8
+ /**
9
+ * Run the migrations.
10
+ *
11
+ * @return void
12
+ */
13
+ public function up()
14
+ {
15
+ Schema::table('services', function (Blueprint $table) {
16
+ $table->string('file')->unique()->change();
17
+ });
18
+ }
19
20
21
+ * Reverse the migrations.
22
23
24
25
+ public function down()
26
27
28
+ $table->dropUnique('services_file_unique');
29
30
31
+}
0 commit comments