pertama
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models\Master;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\SoftDeletes;
|
||||
use App\Models\Master\Provinsi;
|
||||
|
||||
class KabupatenKota extends Model
|
||||
{
|
||||
use SoftDeletes;
|
||||
|
||||
protected $table = 'master_kabupaten_kota';
|
||||
|
||||
protected $fillable = [
|
||||
'nama', 'kode', 'provinsi_id'
|
||||
];
|
||||
|
||||
public function provinsi()
|
||||
{
|
||||
return $this->belongsTo(Provinsi::class, 'provinsi_id');
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user