You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

CoachSchedulingModel.php 668B

12345678910111213141516171819202122232425
  1. <?php
  2. namespace app\model\store\yoga;
  3. use app\yoga\model\appointment\AppointmentModel;
  4. use app\common\model\CommonModel;
  5. use app\yoga\model\project\ProjectModel;
  6. class CoachSchedulingModel extends CommonModel{
  7. protected $name = 'yoga_coach_scheduling';
  8. protected $pk = 'scheduling_id';
  9. public function project()
  10. {
  11. return $this->hasOne(ProjectModel::class,'project_id','project_id');
  12. }
  13. public function coach()
  14. {
  15. return $this->hasOne(CoachModel::class,'coach_id','coach_id');
  16. }
  17. public function appointment()
  18. {
  19. return $this->hasMany(AppointmentModel::class,'scheduling_id','scheduling_id');
  20. }
  21. }