feat(tenancy): show merchant & store details on merchant user detail page
Add clickable card grids for owned merchants and store memberships, replacing static count-only banners with linked summaries. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -49,6 +49,25 @@ class PlatformSelectResponse(BaseModel):
|
||||
platform_code: str
|
||||
|
||||
|
||||
class OwnedMerchantSummary(BaseModel):
|
||||
"""Summary of a merchant owned by a user."""
|
||||
|
||||
id: int
|
||||
name: str
|
||||
is_active: bool
|
||||
store_count: int
|
||||
|
||||
|
||||
class StoreMembershipSummary(BaseModel):
|
||||
"""Summary of a user's store membership."""
|
||||
|
||||
store_id: int
|
||||
store_code: str
|
||||
store_name: str
|
||||
user_type: str
|
||||
is_active: bool
|
||||
|
||||
|
||||
class UserDetailResponse(UserResponse):
|
||||
"""Extended user response with additional details."""
|
||||
|
||||
@@ -58,6 +77,8 @@ class UserDetailResponse(UserResponse):
|
||||
is_email_verified: bool = False
|
||||
owned_merchants_count: int = 0
|
||||
store_memberships_count: int = 0
|
||||
owned_merchants: list[OwnedMerchantSummary] = []
|
||||
store_memberships: list[StoreMembershipSummary] = []
|
||||
|
||||
|
||||
class UserUpdate(BaseModel):
|
||||
|
||||
Reference in New Issue
Block a user