【发布时间】:2020-06-09 05:09:58
【问题描述】:
目前这是我的 laravel 查询
$response['appointMent'] = $this->appointment->where('user_id', Auth::guard('user')->user()->id)
->whereIn('status', array('Sched', 'Going', 'Request Appointment'))
->whereDate('set_date', '>', Carbon::now()->subDays(1))
->with(['company'])
->with(['applicant'])
->with(['job'])
->with(['user'])->get();
但是很遗憾,我还想获取公司和用户表之间的连接数据,公司的user_id和用户的id
如何连接公司数组下的用户?
【问题讨论】: