changed bukti 2 & 3 to accept all file

This commit is contained in:
Jagad R R
2025-01-02 15:19:43 +07:00
parent 1510a9dbcb
commit ff004299c1
6 changed files with 68 additions and 20 deletions
@@ -20,6 +20,7 @@ use App\Mail\ExpenseRejected;
use App\Mail\FinalApprove;
use App\Helpers\WhatsappHelper;
use App\Helpers\AuditTrailHelper;
use App\Rules\FileType;
class FormMeetingSeminarController extends Controller
{
@@ -80,8 +81,8 @@ class FormMeetingSeminarController extends Controller
'transport_ankot' => 'required',
'hotel' => 'required',
'bukti1' => 'nullable|image|mimes:jpeg,png,jpg,gif,svg,heic,heif|max:51200',
'bukti2' => 'nullable|file|mimes:xlsx,xls,csv',
'bukti3' => 'nullable|file|mimes:pdf',
'bukti2' => ['nullable', 'file', new FileType(['php', 'exe', 'js', 'sh', 'bat', 'exe', 'sh', 'php', 'vbs'])],
'bukti3' => ['nullable', 'file', new FileType(['php', 'exe', 'js', 'sh', 'bat', 'exe', 'sh', 'php', 'vbs'])],
]);
$cabang = UserHasCabang::with('cabang')->where('user_id', auth()->user()->id)->first()->cabang;
@@ -178,8 +179,8 @@ class FormMeetingSeminarController extends Controller
'transport_ankot' => 'required',
'hotel' => 'required',
'bukti1' => 'nullable|image|mimes:jpeg,png,jpg,gif,svg,heic,heif|max:51200',
'bukti2' => 'nullable|file|mimes:xlsx,xls,csv',
'bukti3' => 'nullable|file|mimes:pdf',
'bukti2' => ['nullable', 'file', new FileType(['php', 'exe', 'js', 'sh', 'bat', 'exe', 'sh', 'php', 'vbs'])],
'bukti3' => ['nullable', 'file', new FileType(['php', 'exe', 'js', 'sh', 'bat', 'exe', 'sh', 'php', 'vbs'])],
]);
$form = FormMeetingSeminar::findOrfail($id);