更新 app/Models/Park.php
All checks were successful
Deploy preview (main_ou) / deploy (push) Successful in 14s
All checks were successful
Deploy preview (main_ou) / deploy (push) Successful in 14s
This commit is contained in:
parent
0162c91d77
commit
9d0187e244
@ -130,4 +130,14 @@ class Park extends Model
|
||||
public static function getIdByName($park_name){
|
||||
return self::where('park_name',$park_name)->pluck('park_id')->first();
|
||||
}
|
||||
|
||||
/**
|
||||
* 料金設定との関連付け
|
||||
* @return \Illuminate\Database\Eloquent\Relations\HasMany
|
||||
*/
|
||||
public function prices()
|
||||
{
|
||||
return $this->hasMany(PriceA::class, 'park_id', 'park_id');
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user