feat: Add comprehensive permissions to BusinessEditModal

Frontend Changes:
- Add all 5 platform permissions to BusinessEditModal (matching TenantInviteModal)
  - Manage OAuth Credentials
  - Accept Online Payments (Stripe Connect)
  - Use Custom Domain
  - Remove Branding (White Label)
  - API Access
- Add "Coming Soon" feature limits section with 11 future capabilities
  - Video conferencing
  - Event types limits (unlimited or custom)
  - Calendar connections limits (unlimited or custom)
  - External API connections
  - Repeated/recurring events
  - 2FA requirement
  - System logs download
  - Data deletion
  - Masked phone numbers
  - POS system integration
  - Mobile app access
- Update TypeScript interfaces to include all permission fields
  - PlatformBusiness: Add 4 new required boolean fields
  - PlatformBusinessUpdate: Add 4 new optional boolean fields

Backend Changes:
- Update TenantUpdateSerializer to accept all 5 permission fields
  - can_manage_oauth_credentials
  - can_accept_payments
  - can_use_custom_domain
  - can_white_label
  - can_api_access

UI Improvements:
- All permissions displayed with toggle switches and descriptions
- Purple theme for permission toggles
- Gray card backgrounds for visual separation
- "Coming Soon" badge with yellow styling
- Disabled state (opacity-50) for future features
- Proper spacing and layout consistency

Result:
- BusinessEditModal now has complete feature parity with TenantInviteModal
- Platform admins can view and modify all current permissions
- Clear visibility into planned features

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
poduck
2025-11-28 04:00:42 -05:00
parent d158c1ddb0
commit 640961904e
3 changed files with 304 additions and 17 deletions

View File

@@ -28,6 +28,10 @@ export interface PlatformBusiness {
phone?: string;
// Platform permissions
can_manage_oauth_credentials: boolean;
can_accept_payments: boolean;
can_use_custom_domain: boolean;
can_white_label: boolean;
can_api_access: boolean;
}
export interface PlatformBusinessUpdate {
@@ -37,6 +41,10 @@ export interface PlatformBusinessUpdate {
max_users?: number;
max_resources?: number;
can_manage_oauth_credentials?: boolean;
can_accept_payments?: boolean;
can_use_custom_domain?: boolean;
can_white_label?: boolean;
can_api_access?: boolean;
}
export interface PlatformBusinessCreate {