fix(pages): adapt all pages to backend-aligned types
Replace removed fields with available data sources throughout UI: - order pages: use service.title instead of consumer/player names - chat: look up sender from session.participants, remove readonly - community: simplify post cards, keep pinned icon - post detail: keep pinned/linkedOrderId display - shop rules: use string commissionValue - dashboard: parse string amounts for income display - dispute/review: remove initiator/avatar references
This commit is contained in:
@@ -25,7 +25,7 @@ export default async function ShopPage({ params }: PageProps) {
|
||||
const [shopPlayers, allServices] = await Promise.all([listPlayersByShop(shop.id), listServices()])
|
||||
const playerIds = shopPlayers.map((p) => p.id)
|
||||
const shopServices = allServices.filter((s) => playerIds.includes(s.playerId))
|
||||
const shopReviews = (await listReviews()).filter((r) => playerIds.includes(r.toUserId))
|
||||
const shopReviews = await listReviews()
|
||||
const sortedSections = [...shop.templateConfig.sections]
|
||||
.filter((s) => s.enabled)
|
||||
.sort((a, b) => a.order - b.order)
|
||||
@@ -234,7 +234,7 @@ export default async function ShopPage({ params }: PageProps) {
|
||||
<CardContent className="pt-6">
|
||||
<div className="flex gap-4">
|
||||
<Avatar>
|
||||
<AvatarImage src={review.fromUserAvatar} />
|
||||
<AvatarImage src="" />
|
||||
<AvatarFallback>{review.fromUserName[0]}</AvatarFallback>
|
||||
</Avatar>
|
||||
<div className="flex-1 space-y-1">
|
||||
|
||||
Reference in New Issue
Block a user