Skip to content

Commit

Permalink
diable options to receiver & sender
Browse files Browse the repository at this point in the history
  • Loading branch information
alkadoHs committed Feb 14, 2024
1 parent 202dd9e commit 5aeaba2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/Filament/Resources/BranchTransferResource.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ public static function table(Table $table): Table
])
->disableOptionWhen(
//disable pending users found to from branch and approved or rejected users found to to branch
fn ($record) => $record->from_branch_id == auth()->user()->branch_id && $record->status != 'pending'
fn (BranchTransfer $record) => ($record->from_branch_id == auth()->user()->branch_id && $record->status != 'pending') || ($record->to_branch_id == auth()->user()->branch_id && $record->status != 'pending')


// } $value == 'pending' || (($value == 'rejected' || $value == 'approved') && auth()->user()->role != 'vendor')
Expand Down

0 comments on commit 5aeaba2

Please sign in to comment.