testing
This commit is contained in:
parent
0d10e2047b
commit
825a192581
@ -58,22 +58,7 @@ class TabulateWinners extends Command
|
||||
->first();
|
||||
return $mainWinnerQuery->vehicle;
|
||||
}
|
||||
/* function categoryWinner($category)
|
||||
{
|
||||
$categoryWinnerQuery = VehicleScores::join('vehicles', 'vehicle_scores.vehicle', '=', 'vehicles.id')
|
||||
->groupBy('vehicles.id')
|
||||
->selectRaw('*, sum(vehicle_scores.overall_score) as totalscore')
|
||||
->whereNotIn('vehicle_scores.vehicle', function ($query) {
|
||||
$query->select('vehicle')->from('car_show_winners');
|
||||
})
|
||||
//->where('vehicles.doNotJudge', '=', 0)
|
||||
//->where('vehicles.type', '=', "$category")
|
||||
->orderBy('totalscore', 'desc')
|
||||
->first();
|
||||
return $categoryWinnerQuery->vehicle;
|
||||
}
|
||||
|
||||
*/
|
||||
function pcWinner()
|
||||
{
|
||||
$peoplesChoiceWinnerQuery = DB::table('peoples_choice')
|
||||
@ -190,7 +175,20 @@ class TabulateWinners extends Command
|
||||
->first();
|
||||
return $thousandsQuery->vehicle;
|
||||
}
|
||||
|
||||
function categoryWinner($category)
|
||||
{
|
||||
$categoryWinnerQuery = VehicleScores::join('vehicles', 'vehicle_scores.vehicle', '=', 'vehicles.id')
|
||||
->groupBy('vehicles.id')
|
||||
->selectRaw('*, sum(vehicle_scores.overall_score) as totalscore')
|
||||
->whereNotIn('vehicle_scores.vehicle', function ($query) {
|
||||
$query->select('vehicle')->from('car_show_winners');
|
||||
})
|
||||
//->where('vehicles.doNotJudge', '=', 0)
|
||||
//->where('vehicles.type', '=', "$category")
|
||||
->orderBy('totalscore', 'desc')
|
||||
->first();
|
||||
return $categoryWinnerQuery->vehicle;
|
||||
}
|
||||
//categories
|
||||
/* Here for reference only
|
||||
$individuallyProcessedAwards = array(
|
||||
|
Loading…
Reference in New Issue
Block a user