|
|
@ -14,16 +14,17 @@ class CreateLogsTable extends Migration |
|
|
|
public function up() |
|
|
|
{ |
|
|
|
Schema::create('logs', function (Blueprint $table) { |
|
|
|
$table->uuid(); |
|
|
|
$table->id(); |
|
|
|
|
|
|
|
$tabke->json('message'); |
|
|
|
$table->json('message'); |
|
|
|
$table->enum('state', [ |
|
|
|
'critical', 'solved', 'error' |
|
|
|
'critical', 'info', 'error' |
|
|
|
]); |
|
|
|
|
|
|
|
// sources
|
|
|
|
$table->uuid('source_id')->nullable(); |
|
|
|
$table->foreign('source_id')->references('id')->on('sources'); |
|
|
|
$table->unsignedBigInteger('source_id'); |
|
|
|
$table->foreign('source_id') |
|
|
|
->references('id') |
|
|
|
->on('sources'); |
|
|
|
|
|
|
|
$table->timestamps(); |
|
|
|
}); |
|
|
|