|
@ -42,7 +42,7 @@ class SearchController extends Controller |
|
|
$result['hops'][$i]['name'] = $hopname; |
|
|
$result['hops'][$i]['name'] = $hopname; |
|
|
$i++; |
|
|
$i++; |
|
|
}; |
|
|
}; |
|
|
$grains = Grainbill::where('beer_id', $result->beer_id)->distinct('grain_id'); |
|
|
|
|
|
|
|
|
$grains = Grainbill::where('beer_id', $result->beer_id)->value('grain_id'); |
|
|
$grainarr = array(); |
|
|
$grainarr = array(); |
|
|
foreach ($grains as $grain){ |
|
|
foreach ($grains as $grain){ |
|
|
$grainname = Grain::where('id', $grain->id)->value('name'); |
|
|
$grainname = Grain::where('id', $grain->id)->value('name'); |
|
|