app->bind(CompanyAddressWriter::class, EloquentCompanyAddressWriter::class); $this->app->bind(CompanyDataPurger::class, EloquentCompanyDataPurger::class); $this->app->bind(CompanyDefaultsProvisioner::class, EloquentBusinessDefaultsProvisioner::class); $this->app->bind(CompanyInvitationSender::class, LaravelCompanyInvitationSender::class); $this->app->bind(CompanyLogoManager::class, MediaLibraryCompanyLogoManager::class); $this->app->bind(MemberReferencesCleaner::class, EloquentMemberReferencesCleaner::class); $this->app->bind(UserAvatarManager::class, MediaLibraryUserAvatarManager::class); } public function boot(): void { Gate::policy(Company::class, CompanyPolicy::class); Gate::policy(User::class, UserPolicy::class); Gate::policy(Role::class, RolePolicy::class); Gate::define('create company', [CompanyPolicy::class, 'create']); Gate::define('transfer company ownership', [CompanyPolicy::class, 'transferOwnership']); Gate::define('delete company', [CompanyPolicy::class, 'delete']); Gate::define('manage company', [SettingsPolicy::class, 'manageCompany']); Gate::define('delete multiple users', [UserPolicy::class, 'deleteMultiple']); Gate::define('owner only', [OwnerPolicy::class, 'managedByOwner']); } }