2024-04-11 10:59:09 +00:00
|
|
|
<?php
|
|
|
|
namespace Modules\Admin\Services;
|
|
|
|
|
|
|
|
use Modules\Admin\Models\Castes;
|
|
|
|
use Modules\Admin\Models\Cities;
|
|
|
|
use Modules\Admin\Models\Country;
|
2024-04-11 12:05:16 +00:00
|
|
|
use Modules\Admin\Models\Departments;
|
|
|
|
use Modules\Admin\Models\Designations;
|
2024-04-11 10:59:09 +00:00
|
|
|
use Modules\Admin\Models\Districts;
|
|
|
|
use Modules\Admin\Models\Genders;
|
|
|
|
use Modules\Admin\Models\Nationalities;
|
|
|
|
use Modules\Admin\Models\Province;
|
|
|
|
|
|
|
|
final class AdminService
|
|
|
|
{
|
|
|
|
function pluckCountries()
|
|
|
|
{
|
|
|
|
return Country::pluck('title', 'country_id');
|
|
|
|
}
|
|
|
|
|
|
|
|
function pluckProvinces()
|
|
|
|
{
|
|
|
|
return Province::pluck('title', 'province_id');
|
|
|
|
}
|
|
|
|
|
|
|
|
function pluckDistricts()
|
|
|
|
{
|
|
|
|
return Districts::pluck('title', 'district_id');
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
function pluckCities()
|
|
|
|
{
|
|
|
|
return Cities::pluck('title', 'city_id');
|
|
|
|
}
|
|
|
|
|
|
|
|
function pluckCastes()
|
|
|
|
{
|
|
|
|
return Castes::pluck('title', 'caste_id');
|
|
|
|
}
|
|
|
|
|
|
|
|
function pluckGenders()
|
|
|
|
{
|
|
|
|
return Genders::pluck('title', 'gender_id');
|
|
|
|
}
|
|
|
|
|
|
|
|
function pluckNationalities()
|
|
|
|
{
|
|
|
|
return Nationalities::pluck('title', 'nationality_id');
|
|
|
|
}
|
|
|
|
|
2024-04-11 12:05:16 +00:00
|
|
|
function pluckDepartments()
|
|
|
|
{
|
|
|
|
return Departments::pluck('title', 'department_id');
|
|
|
|
}
|
|
|
|
|
|
|
|
function pluckDesignations()
|
|
|
|
{
|
|
|
|
return Designations::pluck('title', 'designation_id');
|
|
|
|
}
|
2024-04-11 10:59:09 +00:00
|
|
|
}
|
|
|
|
|