呼叫成员函数 where// 在阵列中 laravel 5.0.35
我用
然后尝试
但我呼吁消除成员函数 where// 在阵列中。
为什么 DB::table 返回一个数组,但不是一个集合?
laravel v5.0.35
public function getImages/$array_symbols_id/{
$array_images = DB::table/'photo'/
->whereIn/'photo_symbol_id', $array_symbols_id/
->where/'photo_moderation_id','2'/
->orderByRaw/'RAND//'/
->get/['photo_id', 'photo_src', 'photo_symbol_id']/;
然后尝试
$array = array//;
foreach /$array_symbols_id as $id/ {
$array[] = $array_images->where/'photo_symbol_id', $id/->first//->photo_src;
}
但我呼吁消除成员函数 where// 在阵列中。
为什么 DB::table 返回一个数组,但不是一个集合?
laravel v5.0.35
没有找到相关结果
已邀请:
1 个回复
帅驴
赞同来自:
: