Add notification preferences and alternate dues payment options
Notification preferences (migration 048): - Per-member opt-out of muteable categories (bookings, classes, forms, admin alerts); billing is always-on. Opt-out model, default on. - Dispatcher reads prefs and marks muted outbox rows 'skipped' instead of sending; pure isMuted logic, fail-open on a prefs lookup error. - notification_preferences table (default-deny RLS); /me toggles and self-view via validated service-client actions. Alternate dues payment methods (migration 049): - Admin sets external pay-here URLs per platform (PayPal/Zeffy/Venmo) in /settings; members see active ones on /me and pay off-platform; the treasurer reconciles manually (platform pre-tagged). https-only. - dues_payment_methods table (SELECT space member, write admin/board). /me visual pass: - Restore the chip/preset profile editor (skills/interests/willing-to/ affiliations); promote ChipInput and presets to shared modules. - Gate the Stripe pay-dues button on whether the space has Stripe configured; show external links or a contact-admin note otherwise.
This commit is contained in:
@@ -3,7 +3,8 @@
|
||||
import { useState, useTransition } from 'react'
|
||||
import { useRouter } from 'next/navigation'
|
||||
import { updateMyProfile } from '@/lib/actions'
|
||||
import { ChipInput } from './chip-input'
|
||||
import { ChipInput } from '@/components/chip-input'
|
||||
import { WILLING_TO_SUGGESTIONS } from '@/lib/profile-presets'
|
||||
|
||||
type Props = {
|
||||
initial: {
|
||||
@@ -16,16 +17,6 @@ type Props = {
|
||||
}
|
||||
}
|
||||
|
||||
const WILLING_TO_SUGGESTIONS = [
|
||||
'board_candidate',
|
||||
'treasurer_candidate',
|
||||
'host_volunteer',
|
||||
'area_lead_candidate',
|
||||
'event_organizer',
|
||||
'safety_committee',
|
||||
'docs_steward',
|
||||
]
|
||||
|
||||
export function ProfileForm({ initial }: Props) {
|
||||
const router = useRouter()
|
||||
const [displayName, setDisplayName] = useState(initial.display_name)
|
||||
|
||||
Reference in New Issue
Block a user