从查询laravel获取表名

时间:2018-02-28 19:47:33

标签: php laravel octobercms

如何获取包含合并集合的查询的表名

示例:

$hotels = collect(Hotel::where('special_offer_status', '=', 1)->with('special_offer_photo')->get());
        $tours = collect(Tour::where('special_offer_status', '=', 1)->with('special_offer_photo')->get());
        $trips = collect(Trip::where('special_offer_status', '=', 1)->with('special_offer_photo')->get());
        $merged = $hotels->merge($tours)->merge($trips);
        return $merged;

$ merged与表

无关

0 个答案:

没有答案