test commit

This commit is contained in:
Kirill
2026-05-22 12:51:41 +05:00
parent b2ccc2a256
commit 669b9aa45d
9 changed files with 3 additions and 13 deletions
@@ -42,7 +42,6 @@ export type AdminOrderDetailResponse = {
email: string
displayName: string | null
avatar?: string | null
avatarType?: string | null
avatarStyle?: string | null
}
items: Array<{
@@ -27,7 +27,6 @@ export type PublicReviewFeedItem = {
createdAt: string
authorDisplay: string
authorAvatar?: string | null
authorAvatarType?: string | null
authorAvatarStyle?: string | null
product: {
id: string
@@ -56,7 +55,6 @@ export type PublicProductReviewItem = {
createdAt: string
authorDisplay: string
authorAvatar?: string | null
authorAvatarType?: string | null
authorAvatarStyle?: string | null
}
-1
View File
@@ -32,7 +32,6 @@ export async function updateAdminUser(
export type AdminAvatarResponse = {
avatar: string | null
avatarType: string | null
avatarStyle: string | null
}
-1
View File
@@ -3,7 +3,6 @@ export type AdminUser = {
email: string
displayName: string | null
avatar?: string | null
avatarType?: string | null
avatarStyle?: string | null
createdAt: string
updatedAt: string
@@ -43,7 +43,6 @@ export function AdminSettingsPage() {
email: string
displayName: string | null
avatar: string | null
avatarType: string | null
avatarStyle: string | null
}>('admin/profile')
return data
Binary file not shown.
+1 -1
View File
@@ -74,7 +74,7 @@ export async function registerAdminOrderRoutes(fastify) {
where: { id },
include: {
user: {
select: { id: true, email: true, displayName: true, avatar: true, avatarType: true, avatarStyle: true },
select: { id: true, email: true, displayName: true, avatar: true, avatarStyle: true },
},
items: true,
messages: { orderBy: { createdAt: 'asc' } },
-2
View File
@@ -34,7 +34,6 @@ export async function registerAdminUserRoutes(fastify) {
email: true,
displayName: true,
avatar: true,
avatarType: true,
avatarStyle: true,
createdAt: true,
updatedAt: true,
@@ -48,7 +47,6 @@ export async function registerAdminUserRoutes(fastify) {
email: u.email,
displayName: u.displayName,
avatar: u.avatar,
avatarType: u.avatarType,
avatarStyle: u.avatarStyle,
createdAt: u.createdAt,
updatedAt: u.updatedAt,
+2 -4
View File
@@ -40,7 +40,7 @@ export async function registerPublicReviewRoutes(fastify) {
const rows = await prisma.review.findMany({
where: { status: 'approved', product: { published: true } },
include: {
user: { select: { email: true, displayName: true, avatar: true, avatarType: true, avatarStyle: true } },
user: { select: { email: true, displayName: true, avatar: true, avatarStyle: true } },
product: { select: { id: true, title: true, published: true, slug: true } },
},
orderBy: { createdAt: 'desc' },
@@ -55,7 +55,6 @@ export async function registerPublicReviewRoutes(fastify) {
createdAt: r.createdAt,
authorDisplay: publicReviewAuthorDisplay(r.user),
authorAvatar: r.user?.avatar ?? null,
authorAvatarType: r.user?.avatarType ?? null,
authorAvatarStyle: r.user?.avatarStyle ?? null,
product: {
id: r.product?.id ?? r.productId,
@@ -88,7 +87,7 @@ export async function registerPublicReviewRoutes(fastify) {
const rawItems = await prisma.review.findMany({
where,
include: {
user: { select: { email: true, displayName: true, avatar: true, avatarType: true, avatarStyle: true } },
user: { select: { email: true, displayName: true, avatar: true, avatarStyle: true } },
},
orderBy: { createdAt: 'desc' },
skip: (page - 1) * pageSize,
@@ -103,7 +102,6 @@ export async function registerPublicReviewRoutes(fastify) {
createdAt: r.createdAt,
authorDisplay: publicReviewAuthorDisplay(r.user),
authorAvatar: r.user?.avatar ?? null,
authorAvatarType: r.user?.avatarType ?? null,
authorAvatarStyle: r.user?.avatarStyle ?? null,
}))