feat: prepare private offers through existing opportunities
This commit is contained in:
@@ -22,7 +22,7 @@ final class OpportunityPromotion
|
||||
public function allowed(User $actor, Opportunity $record): bool
|
||||
{
|
||||
$access = app(PortalProfileAccess::class);
|
||||
if ($record->trashed() || $record->owner_user_id === null || ! $access->canView($actor, $record)
|
||||
if ($record->isPrivateOfferPreparation() || $record->trashed() || $record->owner_user_id === null || ! $access->canView($actor, $record)
|
||||
|| $access->has($actor, 'auditor') || in_array($record->status, ['archived', 'rejected'], true)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user