feat: [demo] 데모 테넌트 관리 API 및 만료 알림 (Phase 3)
- DemoTenantController: 목록/상세/생성/리셋/연장/전환/통계 API - DemoTenantStoreRequest: 고객 체험 테넌트 생성 검증 - DemoTenantService: API용 메서드 추가 (index/show/reset/extend/convert/stats) - CheckDemoExpiredCommand: 만료 임박(7일) 알림 + 만료 테넌트 비활성 처리 - 라우트 등록 (api/v1/demo-tenants, 7개 엔드포인트) - 스케줄러 등록 (04:20 demo:check-expired) - i18n 메시지 추가 (message.demo_tenant.*, error.demo_tenant.*)
This commit is contained in:
@@ -159,6 +159,17 @@
|
||||
|
||||
// ─── 데모 쇼케이스 리셋 ───
|
||||
|
||||
// 매일 새벽 04:20에 데모 체험 테넌트 만료 체크 및 비활성 처리
|
||||
Schedule::command('demo:check-expired')
|
||||
->dailyAt('04:20')
|
||||
->appendOutputTo(storage_path('logs/scheduler.log'))
|
||||
->onSuccess(function () {
|
||||
\Illuminate\Support\Facades\Log::info('✅ demo:check-expired 스케줄러 실행 성공', ['time' => now()]);
|
||||
})
|
||||
->onFailure(function () {
|
||||
\Illuminate\Support\Facades\Log::error('❌ demo:check-expired 스케줄러 실행 실패', ['time' => now()]);
|
||||
});
|
||||
|
||||
// 매일 자정 00:00에 쇼케이스 테넌트 데이터 리셋 + 샘플 재시드
|
||||
Schedule::command('demo:reset-showcase --seed')
|
||||
->dailyAt('00:00')
|
||||
|
||||
Reference in New Issue
Block a user