|
1
|
|
|
<?php |
|
2
|
|
|
|
|
3
|
|
|
use Illuminate\Database\Migrations\Migration; |
|
|
|
|
|
|
4
|
|
|
use Illuminate\Database\Schema\Blueprint; |
|
|
|
|
|
|
5
|
|
|
use Illuminate\Support\Facades\Schema; |
|
|
|
|
|
|
6
|
|
|
|
|
7
|
|
|
class CreateVisitorsTable extends Migration |
|
8
|
|
|
{ |
|
9
|
|
|
/** |
|
10
|
|
|
* Run the migrations. |
|
11
|
|
|
* |
|
12
|
|
|
* @return void |
|
13
|
|
|
*/ |
|
14
|
|
|
public function up() |
|
15
|
|
|
{ |
|
16
|
|
|
Schema::create('visitors', function (Blueprint $table) { |
|
17
|
|
|
$table->increments('id'); |
|
18
|
|
|
$table->string('unique_id'); |
|
19
|
|
|
|
|
20
|
|
|
$table->unsignedInteger('user_id')->nullable(); |
|
21
|
|
|
$table->string('ip', 40); |
|
22
|
|
|
|
|
23
|
|
|
$table->string('user_agent')->nullable(); |
|
24
|
|
|
$table->boolean('is_desktop')->default(false); |
|
25
|
|
|
$table->boolean('is_mobile')->default(false); |
|
26
|
|
|
$table->boolean('is_bot')->default(false); |
|
27
|
|
|
$table->string('bot')->nullable(); |
|
28
|
|
|
$table->string('os')->default(''); |
|
29
|
|
|
$table->string('browser_version')->default(''); |
|
30
|
|
|
$table->string('browser')->default(''); |
|
31
|
|
|
|
|
32
|
|
|
$table->string('country')->default(''); |
|
33
|
|
|
$table->string('country_code')->default(''); |
|
34
|
|
|
$table->string('city')->default(''); |
|
35
|
|
|
$table->double('lat')->nullable(); |
|
36
|
|
|
$table->double('long')->nullable(); |
|
37
|
|
|
|
|
38
|
|
|
$table->string('browser_language_family', 4)->default(''); |
|
39
|
|
|
$table->string('browser_language', 7)->default(''); |
|
40
|
|
|
|
|
41
|
|
|
$table->timestamps(); |
|
42
|
|
|
}); |
|
43
|
|
|
} |
|
44
|
|
|
|
|
45
|
|
|
/** |
|
46
|
|
|
* Reverse the migrations. |
|
47
|
|
|
* |
|
48
|
|
|
* @return void |
|
49
|
|
|
*/ |
|
50
|
|
|
public function down() |
|
51
|
|
|
{ |
|
52
|
|
|
Schema::dropIfExists('visitors'); |
|
53
|
|
|
} |
|
54
|
|
|
} |
|
55
|
|
|
|
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths