33 lines
812 B
PHP
33 lines
812 B
PHP
<?php
|
|
|
|
namespace App\Http\Controllers;
|
|
|
|
use App\Services\PatientMigrationService;
|
|
use Illuminate\Support\Carbon;
|
|
use Inertia\Inertia;
|
|
|
|
class TestController extends Controller
|
|
{
|
|
public function testMigrations(PatientMigrationService $migrationService)
|
|
{
|
|
$startAt = Carbon::parse('2026-01-01T00:00:00')->format('Y-m-d H:i:s');
|
|
$endAt = Carbon::parse('2026-03-31T23:59:00')->format('Y-m-d H:i:s');
|
|
|
|
$cacheKey = 'branch_current_2';
|
|
\Cache::tags(['migrations_in_branch_outcome'])->flush();
|
|
|
|
$data = $migrationService->getMigrationsInBranchOutcome(2, $startAt, $endAt);
|
|
|
|
return Inertia::render('TestQuery', [
|
|
'data' => $data,
|
|
]);
|
|
}
|
|
|
|
public function testIndex()
|
|
{
|
|
return Inertia::render('TestIndex', [
|
|
|
|
]);
|
|
}
|
|
}
|