first commit

This commit is contained in:
2025-10-02 22:52:13 +03:00
commit 5d8d08d2f4
137 changed files with 18187 additions and 0 deletions
+41
View File
@@ -0,0 +1,41 @@
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
class WorkoutExercise extends Model
{
use HasFactory;
protected $fillable = [
'workout_id',
'exercise_id',
'position',
'sets',
'reps',
'weight',
'rest_seconds',
'notes',
];
protected $casts = [
'position' => 'integer',
'sets' => 'integer',
'reps' => 'integer',
'weight' => 'decimal:2',
'rest_seconds' => 'integer',
];
public function workout(): BelongsTo
{
return $this->belongsTo(Workout::class);
}
public function exercise(): BelongsTo
{
return $this->belongsTo(Exercise::class);
}
}