dstpabuaran.com/app/Http/Requests/Admin/Settings/UpdateHRRequest.php
Yoga Pangestu a1a73cb222 Add admin settings routes and corresponding feature tests
- Introduced routes for managing admin settings including system, homepage, social media, marketplace, and HR settings.
- Created a comprehensive test suite for the AdminSettingsController to ensure proper functionality and validation of settings updates.
- Implemented tests for authentication, data integrity, and realistic user scenarios to validate the settings management process.
2026-07-31 01:04:14 +07:00

34 lines
900 B
PHP

<?php
namespace App\Http\Requests\Admin\Settings;
use Illuminate\Foundation\Http\FormRequest;
class UpdateHRRequest extends FormRequest
{
public function authorize(): bool
{
return true;
}
public function rules(): array
{
return [
'scheduled_check_in_time' => ['required', 'string', 'max:5'],
'scheduled_check_out_time' => ['required', 'string', 'max:5'],
'late_penalty_amount' => ['required', 'integer', 'min:0'],
'absent_penalty_amount' => ['required', 'integer', 'min:0'],
];
}
public function attributes(): array
{
return [
'scheduled_check_in_time' => 'jam masuk kerja',
'scheduled_check_out_time' => 'jam pulang kerja',
'late_penalty_amount' => 'denda keterlambatan',
'absent_penalty_amount' => 'denda bolos',
];
}
}