mirror of
https://github.com/InvoiceShelf/InvoiceShelf.git
synced 2026-04-19 19:24:03 +00:00
Reorganize Admin/General: 14 controllers down to 6
Move global reference data to SuperAdmin: - CountriesController, CurrenciesController (not company-scoped) Merge exchange rate operations into ExchangeRateProviderController: - GetAllUsedCurrenciesController -> usedCurrenciesWithoutRate() - BulkExchangeRateController -> bulkUpdate() Consolidate single-action controllers: - DateFormatsController + TimeFormatsController + TimezonesController -> FormatsController - NextNumberController + NumberPlaceholdersController -> SerialNumberController - SearchUsersController merged into SearchController::users()
This commit is contained in:
33
app/Http/Controllers/V1/Admin/General/FormatsController.php
Normal file
33
app/Http/Controllers/V1/Admin/General/FormatsController.php
Normal file
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Controllers\V1\Admin\General;
|
||||
|
||||
use App\Http\Controllers\Controller;
|
||||
use App\Support\Formatters\DateFormatter;
|
||||
use App\Support\Formatters\TimeFormatter;
|
||||
use App\Support\Formatters\TimeZones;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
|
||||
class FormatsController extends Controller
|
||||
{
|
||||
public function dateFormats(): JsonResponse
|
||||
{
|
||||
return response()->json([
|
||||
'date_formats' => DateFormatter::get_list(),
|
||||
]);
|
||||
}
|
||||
|
||||
public function timeFormats(): JsonResponse
|
||||
{
|
||||
return response()->json([
|
||||
'time_formats' => TimeFormatter::get_list(),
|
||||
]);
|
||||
}
|
||||
|
||||
public function timezones(): JsonResponse
|
||||
{
|
||||
return response()->json([
|
||||
'time_zones' => TimeZones::get_list(),
|
||||
]);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user