Conditions | 1 |
Paths | 1 |
Total Lines | 21 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
9 | public function up() |
||
10 | { |
||
11 | Schema::create(config('uptime.endpoints_table'), function (Blueprint $table) { |
||
12 | $table->increments('id')->unsigned(); |
||
13 | $table->text('uri'); |
||
14 | $table->integer('frequency'); |
||
15 | $table->timestamps(); |
||
16 | }); |
||
17 | |||
18 | Schema::create(config('uptime.statuses_table'), function (Blueprint $table) { |
||
19 | $table->increments('id')->unsigned(); |
||
20 | $table->integer('endpoint_id')->unsigned(); |
||
21 | $table->integer('status_code'); |
||
22 | $table->timestamps(); |
||
23 | |||
24 | $table->foreign('endpoint_id') |
||
25 | ->references('id') |
||
26 | ->on(config('uptime.endpoints_table')) |
||
27 | ->onDelete('cascade'); |
||
28 | }); |
||
29 | } |
||
30 | |||
42 |