合并远端前端修复
This commit is contained in:
@@ -22,7 +22,6 @@ import { notifyTencentActionError } from './tencent/session-errors'
|
|||||||
import {
|
import {
|
||||||
useSessionPolling,
|
useSessionPolling,
|
||||||
useSessionQrDisplay,
|
useSessionQrDisplay,
|
||||||
useSessionRoleFacts,
|
|
||||||
useSessionResultFacts,
|
useSessionResultFacts,
|
||||||
buildRedeemBlockedReason,
|
buildRedeemBlockedReason,
|
||||||
resolveTaskStatusLabel,
|
resolveTaskStatusLabel,
|
||||||
@@ -92,7 +91,7 @@ export function useAdminManualRedeemPage() {
|
|||||||
} = useSessionPolling({
|
} = useSessionPolling({
|
||||||
hasSession: computed(() => Boolean(task.value?.taskId && hasSession.value)),
|
hasSession: computed(() => Boolean(task.value?.taskId && hasSession.value)),
|
||||||
shouldKeepPolling: computed(() => shouldKeepPolling(detail.value)),
|
shouldKeepPolling: computed(() => shouldKeepPolling(detail.value)),
|
||||||
onPollTick: () => refreshSessionSummary({ silent: true }),
|
onPollTick: async () => { await refreshSessionSummary({ silent: true }) },
|
||||||
pollWarningPrefix: '人工兑换状态刷新失败',
|
pollWarningPrefix: '人工兑换状态刷新失败',
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -122,12 +121,6 @@ export function useAdminManualRedeemPage() {
|
|||||||
() => `请让客户使用${loginTypeLabel.value}扫码,并在手机上确认登录`,
|
() => `请让客户使用${loginTypeLabel.value}扫码,并在手机上确认登录`,
|
||||||
)
|
)
|
||||||
|
|
||||||
useSessionRoleFacts({
|
|
||||||
activityInfo,
|
|
||||||
statusLabel,
|
|
||||||
roleFactDefaults: { nickname: '等待客户登录' },
|
|
||||||
})
|
|
||||||
|
|
||||||
const proofValue = computed(() => manualRequest.value?.proofValue || order.value?.platformOrderId || '-')
|
const proofValue = computed(() => manualRequest.value?.proofValue || order.value?.platformOrderId || '-')
|
||||||
|
|
||||||
const { resultFacts } = useSessionResultFacts({
|
const { resultFacts } = useSessionResultFacts({
|
||||||
|
|||||||
@@ -17,7 +17,6 @@ import { notifyTencentActionError } from './tencent/session-errors'
|
|||||||
import {
|
import {
|
||||||
useSessionPolling,
|
useSessionPolling,
|
||||||
useSessionQrDisplay,
|
useSessionQrDisplay,
|
||||||
useSessionRoleFacts,
|
|
||||||
useSessionResultFacts,
|
useSessionResultFacts,
|
||||||
buildRedeemBlockedReason,
|
buildRedeemBlockedReason,
|
||||||
resolveTaskStatusLabel,
|
resolveTaskStatusLabel,
|
||||||
@@ -59,7 +58,7 @@ export function useClaimPage(token: string) {
|
|||||||
} = useSessionPolling({
|
} = useSessionPolling({
|
||||||
hasSession,
|
hasSession,
|
||||||
shouldKeepPolling: computed(() => shouldKeepPolling(detail.value)),
|
shouldKeepPolling: computed(() => shouldKeepPolling(detail.value)),
|
||||||
onPollTick: () => refreshSessionSummary({ silent: true }),
|
onPollTick: async () => { await refreshSessionSummary({ silent: true }) },
|
||||||
pollWarningPrefix: '领取状态刷新失败',
|
pollWarningPrefix: '领取状态刷新失败',
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -88,12 +87,6 @@ export function useClaimPage(token: string) {
|
|||||||
() => `请使用${loginTypeLabel.value}扫描二维码,并在手机上确认登录`,
|
() => `请使用${loginTypeLabel.value}扫描二维码,并在手机上确认登录`,
|
||||||
)
|
)
|
||||||
|
|
||||||
useSessionRoleFacts({
|
|
||||||
activityInfo,
|
|
||||||
statusLabel,
|
|
||||||
roleFactDefaults: { nickname: '等待扫码登录' },
|
|
||||||
})
|
|
||||||
|
|
||||||
// Claim pages show 4 role facts, but original only had 3 (no area).
|
// Claim pages show 4 role facts, but original only had 3 (no area).
|
||||||
// Override roleFacts to match original exactly:
|
// Override roleFacts to match original exactly:
|
||||||
const claimRoleFacts = computed(() => [
|
const claimRoleFacts = computed(() => [
|
||||||
|
|||||||
+3
-1
@@ -39,7 +39,9 @@ export function useKuaishouCloudNinetyone(
|
|||||||
function createItemFromNinetyoneOrder(item: AdminNinetyoneOrderItem): EditableItem {
|
function createItemFromNinetyoneOrder(item: AdminNinetyoneOrderItem): EditableItem {
|
||||||
const productNo = String(item.productNo || '').trim()
|
const productNo = String(item.productNo || '').trim()
|
||||||
const productName = String(item.productName || productNo).trim()
|
const productName = String(item.productName || productNo).trim()
|
||||||
const shop = config.getDefaultKuaishouConsumeShop()
|
const defaultShop = config.getDefaultKuaishouConsumeShop()
|
||||||
|
const shopOpts = config.getKuaishouConsumeShopOptions()
|
||||||
|
const shop = defaultShop || (shopOpts.length > 0 ? shopOpts[0] : null)
|
||||||
return {
|
return {
|
||||||
localId: crypto.randomUUID(),
|
localId: crypto.randomUUID(),
|
||||||
id: '',
|
id: '',
|
||||||
|
|||||||
@@ -48,6 +48,7 @@ const {
|
|||||||
getSkuNamingHint,
|
getSkuNamingHint,
|
||||||
formatInventoryStatus,
|
formatInventoryStatus,
|
||||||
getGroupSuggestion,
|
getGroupSuggestion,
|
||||||
|
// utils
|
||||||
formatAdminDateTime,
|
formatAdminDateTime,
|
||||||
} = useAdminInventory()
|
} = useAdminInventory()
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
# Dev Dockerfile — single-stage, root, VNC/X11 + Playwright
|
# Dev Dockerfile — single-stage, root, VNC/X11 + Playwright
|
||||||
# For production, see backend.Dockerfile (multi-stage build)
|
# For production, see backend.Dockerfile (multi-stage build)
|
||||||
FROM node:22-bookworm
|
FROM docker.m.daocloud.io/library/node:22-bookworm
|
||||||
|
|
||||||
ARG DEBIAN_MIRROR=mirrors.cloud.tencent.com
|
ARG DEBIAN_MIRROR=mirrors.cloud.tencent.com
|
||||||
ARG NPM_REGISTRY=https://registry.npmmirror.com
|
ARG NPM_REGISTRY=https://registry.npmmirror.com
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
# ============================================================================
|
# ============================================================================
|
||||||
|
|
||||||
# --------------------------- Builder Stage -----------------------------------
|
# --------------------------- Builder Stage -----------------------------------
|
||||||
FROM node:22-bookworm AS builder
|
FROM docker.m.daocloud.io/library/node:22-bookworm AS builder
|
||||||
|
|
||||||
ARG DEBIAN_MIRROR=mirrors.cloud.tencent.com
|
ARG DEBIAN_MIRROR=mirrors.cloud.tencent.com
|
||||||
ARG NPM_REGISTRY=https://registry.npmmirror.com
|
ARG NPM_REGISTRY=https://registry.npmmirror.com
|
||||||
@@ -49,7 +49,7 @@ RUN npm run build \
|
|||||||
&& npm prune --omit=dev
|
&& npm prune --omit=dev
|
||||||
|
|
||||||
# --------------------------- Runtime Stage -----------------------------------
|
# --------------------------- Runtime Stage -----------------------------------
|
||||||
FROM node:22-bookworm-slim AS runtime
|
FROM docker.m.daocloud.io/library/node:22-bookworm-slim AS runtime
|
||||||
|
|
||||||
# HTTP mirrors — see builder note about OrbStack TLS
|
# HTTP mirrors — see builder note about OrbStack TLS
|
||||||
ENV DEBIAN_FRONTEND=noninteractive
|
ENV DEBIAN_FRONTEND=noninteractive
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
FROM caddy:2-alpine
|
FROM docker.m.daocloud.io/library/caddy:2-alpine
|
||||||
|
|
||||||
ENV TZ=Asia/Shanghai
|
ENV TZ=Asia/Shanghai
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
FROM node:22-bookworm AS builder
|
FROM docker.m.daocloud.io/library/node:22-bookworm AS builder
|
||||||
|
|
||||||
ARG NPM_REGISTRY=https://registry.npmmirror.com
|
ARG NPM_REGISTRY=https://registry.npmmirror.com
|
||||||
|
|
||||||
@@ -14,7 +14,7 @@ RUN --mount=type=cache,target=/root/.npm,sharing=locked \
|
|||||||
COPY apps/frontend/ ./
|
COPY apps/frontend/ ./
|
||||||
RUN npm run build
|
RUN npm run build
|
||||||
|
|
||||||
FROM caddy:2-alpine
|
FROM docker.m.daocloud.io/library/caddy:2-alpine
|
||||||
|
|
||||||
ENV TZ=Asia/Shanghai
|
ENV TZ=Asia/Shanghai
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
services:
|
services:
|
||||||
postgres:
|
postgres:
|
||||||
image: postgres:16-bookworm
|
image: docker.m.daocloud.io/library/postgres:16-bookworm
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
environment:
|
environment:
|
||||||
TZ: ${TZ:-Asia/Shanghai}
|
TZ: ${TZ:-Asia/Shanghai}
|
||||||
@@ -88,7 +88,7 @@ services:
|
|||||||
- "${TENCENT_BROWSER_NOVNC_PORT:-6080}:6080"
|
- "${TENCENT_BROWSER_NOVNC_PORT:-6080}:6080"
|
||||||
|
|
||||||
frontend:
|
frontend:
|
||||||
image: node:22-bookworm-slim
|
image: docker.m.daocloud.io/library/node:22-bookworm-slim
|
||||||
working_dir: /app
|
working_dir: /app
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
command: >-
|
command: >-
|
||||||
@@ -105,7 +105,7 @@ services:
|
|||||||
- frontend_node_modules:/app/node_modules
|
- frontend_node_modules:/app/node_modules
|
||||||
|
|
||||||
web:
|
web:
|
||||||
image: caddy:2-alpine
|
image: docker.m.daocloud.io/library/caddy:2-alpine
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
depends_on:
|
depends_on:
|
||||||
backend:
|
backend:
|
||||||
|
|||||||
+8
-3
@@ -1,6 +1,6 @@
|
|||||||
services:
|
services:
|
||||||
postgres:
|
postgres:
|
||||||
image: postgres:16-bookworm
|
image: docker.m.daocloud.io/library/postgres:16-bookworm
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
environment:
|
environment:
|
||||||
TZ: ${TZ:-Asia/Shanghai}
|
TZ: ${TZ:-Asia/Shanghai}
|
||||||
@@ -8,7 +8,11 @@ services:
|
|||||||
POSTGRES_USER: ${POSTGRES_USER:-postgres}
|
POSTGRES_USER: ${POSTGRES_USER:-postgres}
|
||||||
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-postgres}
|
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-postgres}
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER:-postgres} -d ${POSTGRES_DB:-order_site}"]
|
test:
|
||||||
|
[
|
||||||
|
"CMD-SHELL",
|
||||||
|
"pg_isready -U ${POSTGRES_USER:-postgres} -d ${POSTGRES_DB:-order_site}",
|
||||||
|
]
|
||||||
interval: 5s
|
interval: 5s
|
||||||
timeout: 5s
|
timeout: 5s
|
||||||
retries: 20
|
retries: 20
|
||||||
@@ -40,7 +44,8 @@ services:
|
|||||||
ocr-worker:
|
ocr-worker:
|
||||||
condition: service_healthy
|
condition: service_healthy
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: ["CMD-SHELL", "curl -fsS http://127.0.0.1:3000/health/ready || exit 1"]
|
test:
|
||||||
|
["CMD-SHELL", "curl -fsS http://127.0.0.1:3000/health/ready || exit 1"]
|
||||||
interval: 5s
|
interval: 5s
|
||||||
timeout: 5s
|
timeout: 5s
|
||||||
retries: 20
|
retries: 20
|
||||||
|
|||||||
Reference in New Issue
Block a user