File manager - Edit - /var/www/html/homologBancodetalentos/app/Http/Services/TalentBank/DashboardService.php
Back
<?php namespace App\Http\Services\TalentBank; use App\Models\TalentBank\Candidate; use App\Models\TalentBank\Company; use App\Models\TalentBank\JobListing; use Illuminate\Http\Request; use Illuminate\Support\Facades\DB; class DashboardService { public function home(Request $request): array { $counters = []; $counters['candidates'] = Candidate::where('active', 1)->count(); $counters['jobs'] = JobListing::count(); $counters['companies'] = Company::count(); $counters['companies_active'] = Company::where('active', 1)->count(); return $counters; } public function jobs(): array { $counters = []; $counters['open'] = JobListing::where('is_hiring', 1)->count(); $counters['closed'] = JobListing::where('is_hiring', 0)->count(); $counters['applications'] = DB::table('job_listing_candidate')->count(); return $counters; } }
| ver. 1.4 |
Github
|
.
| PHP 8.3.28 | Generation time: 0.02 |
proxy
|
phpinfo
|
Settings