Bug fixes and Action / Decision seeder
This commit is contained in:
@@ -2,6 +2,8 @@
|
||||
|
||||
namespace Database\Seeders;
|
||||
|
||||
use App\Models\Action;
|
||||
use App\Models\Decision;
|
||||
use Illuminate\Database\Console\Seeds\WithoutModelEvents;
|
||||
use Illuminate\Database\Seeder;
|
||||
|
||||
@@ -12,6 +14,116 @@ class ActionSeeder extends Seeder
|
||||
*/
|
||||
public function run(): void
|
||||
{
|
||||
//
|
||||
Action::create([
|
||||
'name' => 'KLIC - IZHODNI',
|
||||
'color_tag' => '',
|
||||
'segment_id' => 1
|
||||
]);
|
||||
|
||||
Action::create([
|
||||
'name' => 'KLIC - VHODNI',
|
||||
'color_tag' => '',
|
||||
'segment_id' => 1
|
||||
]);
|
||||
|
||||
Action::create([
|
||||
'name' => 'ePOŠTA',
|
||||
'color_tag' => '',
|
||||
'segment_id' => 1
|
||||
]);
|
||||
|
||||
Action::create([
|
||||
'name' => 'VROČANJE',
|
||||
'color_tag' => '',
|
||||
'segment_id' => 1
|
||||
]);
|
||||
|
||||
Action::create([
|
||||
'name' => 'SMS',
|
||||
'color_tag' => '',
|
||||
'segment_id' => 1
|
||||
]);
|
||||
|
||||
//------- 1
|
||||
Decision::create([
|
||||
'name' => 'Obljuba',
|
||||
'color_tag' => '',
|
||||
]);
|
||||
|
||||
\DB::table('action_decision')->insert([
|
||||
'action_id' => 1,
|
||||
'decision_id' => 1
|
||||
]);
|
||||
|
||||
\DB::table('action_decision')->insert([
|
||||
'action_id' => 2,
|
||||
'decision_id' => 1
|
||||
]);
|
||||
|
||||
//------- 2
|
||||
Decision::create([
|
||||
'name' => 'Poslana',
|
||||
'color_tag' => '',
|
||||
]);
|
||||
|
||||
\DB::table('action_decision')->insert([
|
||||
'action_id' => 3,
|
||||
'decision_id' => 2
|
||||
]);
|
||||
|
||||
//-------- 3
|
||||
Decision::create([
|
||||
'name' => 'Prejeta',
|
||||
'color_tag' => '',
|
||||
]);
|
||||
|
||||
\DB::table('action_decision')->insert([
|
||||
'action_id' => 3,
|
||||
'decision_id' => 3
|
||||
]);
|
||||
|
||||
//--------- 4
|
||||
Decision::create([
|
||||
'name' => 'Neuspešna',
|
||||
'color_tag' => '',
|
||||
]);
|
||||
|
||||
\DB::table('action_decision')->insert([
|
||||
'action_id' => 4,
|
||||
'decision_id' => 4
|
||||
]);
|
||||
|
||||
//--------- 5
|
||||
Decision::create([
|
||||
'name' => 'Uspešna',
|
||||
'color_tag' => '',
|
||||
]);
|
||||
|
||||
\DB::table('action_decision')->insert([
|
||||
'action_id' => 4,
|
||||
'decision_id' => 5
|
||||
]);
|
||||
|
||||
//--------- 6
|
||||
Decision::create([
|
||||
'name' => 'Poslan SMS',
|
||||
'color_tag' => '',
|
||||
]);
|
||||
|
||||
\DB::table('action_decision')->insert([
|
||||
'action_id' => 5,
|
||||
'decision_id' => 6
|
||||
]);
|
||||
|
||||
//--------- 7
|
||||
Decision::create([
|
||||
'name' => 'Prejet SMS',
|
||||
'color_tag' => '',
|
||||
]);
|
||||
|
||||
\DB::table('action_decision')->insert([
|
||||
'action_id' => 5,
|
||||
'decision_id' => 7
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,7 +25,8 @@ public function run(): void
|
||||
|
||||
$this->call([
|
||||
PersonSeeder::class,
|
||||
SegmentSeeder::class
|
||||
SegmentSeeder::class,
|
||||
ActionSeeder::class
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user