mirror of
https://bitbucket.org/studiotem/jandl-taskmanager-app.git
synced 2026-10-21 14:29:34 +00:00
db:seed cleanup
This commit is contained in:
1 parent
33499107b7
commit
dfac41f30a
9 files changed
+75
-18
No files matched your search
@@ -2,6 +2,7 @@
|
||||
|
||||
namespace Database\Factories;
|
||||
|
||||
use App\Models\SubTask;
|
||||
use App\Models\User;
|
||||
use Illuminate\Database\Eloquent\Factories\Factory;
|
||||
|
||||
@@ -17,10 +18,11 @@ class TimesheetFactory extends Factory
|
||||
*/
|
||||
public function definition()
|
||||
{
|
||||
$user = User::factory()->create();
|
||||
$subtask = SubTask::all()->random();
|
||||
|
||||
return [
|
||||
'user_id' => $user->id,
|
||||
'user_id' => $subtask->user->id,
|
||||
'sub_task_id' => $subtask->id,
|
||||
'time' => fake()->numberBetween(1,8),
|
||||
'synced_to_karat' => null,
|
||||
];
|
||||
|
||||
Reference in new issue
Block a user