for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace CleaniqueCoders\Profile\Models;
use Illuminate\Database\Eloquent\Model;
class Address extends Model
{
protected $guarded = ['id'];
/**
* Get the route key for the model.
*
* @return string
*/
public function getRouteKeyName()
return 'hashslug';
}
* Get all of the owning addressable models.
public function addressable()
return $this->morphTo();
* Get Country.
* @return \CleaniqueCoders\Profile\Models\Country
public function country()
return $this->belongsTo(Country::class);
return $this->belongsTo(...\Models\Country::class)
Illuminate\Database\Eloquent\Relations\BelongsTo
CleaniqueCoders\Profile\Models\Country