Update Model, dashboard, lahan

Co-authored-by: Copilot <copilot@github.com>
This commit is contained in:
2026-04-29 11:06:31 +07:00
co-authored by Copilot
parent 8bcb0e47e0
commit d18b0668e1
21 changed files with 1654 additions and 59 deletions
+8 -1
View File
@@ -4,9 +4,11 @@ namespace App\Models;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;
use App\Models\User;
use App\Models\Pertanian\Lahan;
use App\Models\Wilayah\DesaKelurahan;
use Illuminate\Database\Eloquent\Relations\HasMany;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
class Profile extends Model
{
@@ -42,4 +44,9 @@ class Profile extends Model
{
return $this->belongsTo(User::class, 'user_id');
}
public function lahan(): HasMany
{
return $this->hasMany(Lahan::class, 'profile_id');
}
}