-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcallbacks.php
29 lines (27 loc) · 1.07 KB
/
callbacks.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
<?php
return [
App\Events\PluginWasEnabled::class => function () {
if (!Schema::hasTable('moderation_whitelist')) {
Schema::create('moderation_whitelist', function ($table) {
$table->increments('id');
$table->integer('user_id')->unique();
$table->integer('operator');
$table->timestamps();
});
}
if (!Schema::hasTable('moderation_records')) {
Schema::create('moderation_records', function ($table) {
$table->increments('id');
$table->integer('tid')->unique();
$table->integer('porn_score')->default(-1);
$table->string('porn_label')->default('');
$table->integer('politics_score')->default(-1);
$table->string('politics_label')->default('');
$table->integer('review_state');
$table->integer('source');
$table->integer('operator')->nullable();
$table->timestamps();
});
}
},
];