feat(l1): L1 workspace Phase 1 — role, seat enforcement, adhoc walker, audit #189
@@ -237,8 +237,17 @@ export function AccountSettingsPage() {
|
|||||||
const invitesData = await accountsApi.getInvites()
|
const invitesData = await accountsApi.getInvites()
|
||||||
setInvites(invitesData)
|
setInvites(invitesData)
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
toast.error('Failed to send invitation')
|
const resp = (err as any)?.response
|
||||||
console.error(err)
|
if (resp?.status === 402 && resp?.data?.detail?.code === 'seat_limit_exceeded') {
|
||||||
|
const d = resp.data.detail
|
||||||
|
const label = d.role === 'l1_tech' ? 'L1' : 'Engineer'
|
||||||
|
toast.warning(
|
||||||
|
`${label} seats full: ${d.current}/${d.limit}. Upgrade your plan to add more.`,
|
||||||
|
)
|
||||||
|
} else {
|
||||||
|
toast.error('Failed to send invitation')
|
||||||
|
console.error(err)
|
||||||
|
}
|
||||||
} finally {
|
} finally {
|
||||||
setIsInviting(false)
|
setIsInviting(false)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user