<?php

namespace Modules\Address\Models;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;
use Modules\City\Models\City;
use Modules\User\Models\User;

class Address extends Model
{
    //use soft delete
    use SoftDeletes;

    protected $fillable = [
        'user_id',
        'latitude',
        'longitude',
        'city_id',
        'description',
    ];

    public function user()
    {
        return $this->belongsTo(User::class, 'user_id')->withTrashed();
    }
    public function city()
    {
        return $this->belongsTo(City::class, 'city_id')->withTrashed();
    }



}
