From 50e95b985a72fcec4a93a2470e9efdfb2620148a Mon Sep 17 00:00:00 2001
From: zhou zhou <3272660260@qq.com>
Date: 星期四, 02 四月 2026 15:46:09 +0800
Subject: [PATCH] #i18n

---
 rsf-design/src/views/basic-info/warehouse-areas/warehouseAreasPage.helpers.js |   52 +++++++++++++++++++++++++++++++---------------------
 1 files changed, 31 insertions(+), 21 deletions(-)

diff --git a/rsf-design/src/views/basic-info/warehouse-areas/warehouseAreasPage.helpers.js b/rsf-design/src/views/basic-info/warehouse-areas/warehouseAreasPage.helpers.js
index ffed312..40935e4 100644
--- a/rsf-design/src/views/basic-info/warehouse-areas/warehouseAreasPage.helpers.js
+++ b/rsf-design/src/views/basic-info/warehouse-areas/warehouseAreasPage.helpers.js
@@ -1,9 +1,11 @@
 const STATUS_META = {
-  1: { text: '姝e父', type: 'success', bool: true },
-  0: { text: '鍐荤粨', type: 'danger', bool: false }
+  1: { textKey: 'common.status.normal', fallback: 'Normal', type: 'success', bool: true },
+  0: { textKey: 'common.status.frozen', fallback: 'Frozen', type: 'danger', bool: false }
 }
 
-export const WAREHOUSE_AREAS_REPORT_TITLE = '搴撳尯鎶ヨ〃'
+export function getWarehouseAreasReportTitle(t) {
+  return t('pages.basicInfo.warehouseAreas.reportTitle')
+}
 export const WAREHOUSE_AREAS_REPORT_STYLE = {
   titleAlign: 'center',
   titleLevel: 'strong',
@@ -16,14 +18,14 @@
   return String(value ?? '').trim()
 }
 
-function normalizeFlagText(value) {
-  if (value === 1 || value === '1' || value === true || value === '鏄�') {
-    return '鏄�'
+function normalizeFlagValue(value) {
+  if (value === 1 || value === '1' || value === true || value === '\u662f') {
+    return 1
   }
-  if (value === 0 || value === '0' || value === false || value === '鍚�') {
-    return '鍚�'
+  if (value === 0 || value === '0' || value === false || value === '\u5426') {
+    return 0
   }
-  return normalizeText(value) || '-'
+  return null
 }
 
 export function createWarehouseAreasSearchState() {
@@ -65,17 +67,17 @@
   }
 }
 
-export function getWarehouseAreasStatusOptions() {
+export function getWarehouseAreasStatusOptions(t) {
   return [
-    { label: '姝e父', value: 1 },
-    { label: '鍐荤粨', value: 0 }
+    { label: t('common.status.normal'), value: 1 },
+    { label: t('common.status.frozen'), value: 0 }
   ]
 }
 
-export function getWarehouseAreasFlagOptions() {
+export function getWarehouseAreasFlagOptions(t) {
   return [
-    { label: '鍚�', value: 0 },
-    { label: '鏄�', value: 1 }
+    { label: t('common.status.no'), value: 0 },
+    { label: t('common.status.yes'), value: 1 }
   ]
 }
 
@@ -190,11 +192,14 @@
   if (status === false || Number(status) === 0) {
     return STATUS_META[0]
   }
-  return { text: '鏈煡', type: 'info', bool: false }
+  return { textKey: 'common.status.unknown', fallback: 'Unknown', type: 'info', bool: false }
 }
 
 export function normalizeWarehouseAreasDetailRecord(record = {}) {
   const statusMeta = getWarehouseAreasStatusMeta(record.statusBool ?? record.status)
+  const flagMinusValue = normalizeFlagValue(record.flagMinus$ ?? record.flagMinus)
+  const flagLabelManageValue = normalizeFlagValue(record.flagLabelMange$ ?? record.flagLabelMange)
+  const flagMixValue = normalizeFlagValue(record.flagMix$ ?? record.flagMix)
   return {
     ...record,
     warehouseName: normalizeText(record.warehouseId$ || record.warehouseName || ''),
@@ -204,10 +209,16 @@
     code: normalizeText(record.code || ''),
     name: normalizeText(record.name || ''),
     memo: normalizeText(record.memo || ''),
-    flagMinusText: normalizeFlagText(record.flagMinus$ ?? record.flagMinus),
-    flagLabelMangeText: normalizeFlagText(record.flagLabelMange$ ?? record.flagLabelMange),
-    flagMixText: normalizeFlagText(record.flagMix$ ?? record.flagMix),
-    statusText: statusMeta.text,
+    flagMinusText: normalizeText(record.flagMinus$ ?? record.flagMinus) || '-',
+    flagMinusTextKey:
+      flagMinusValue === null ? '' : flagMinusValue ? 'common.status.yes' : 'common.status.no',
+    flagLabelMangeText: normalizeText(record.flagLabelMange$ ?? record.flagLabelMange) || '-',
+    flagLabelMangeTextKey:
+      flagLabelManageValue === null ? '' : flagLabelManageValue ? 'common.status.yes' : 'common.status.no',
+    flagMixText: normalizeText(record.flagMix$ ?? record.flagMix) || '-',
+    flagMixTextKey: flagMixValue === null ? '' : flagMixValue ? 'common.status.yes' : 'common.status.no',
+    statusText: statusMeta.fallback,
+    statusTextKey: statusMeta.textKey,
     statusType: statusMeta.type,
     statusBool: record.statusBool !== void 0 ? Boolean(record.statusBool) : statusMeta.bool,
     createByText: normalizeText(record.createBy$ || record.createByText || ''),
@@ -227,4 +238,3 @@
   }
   return records.map((record) => normalizeWarehouseAreasListRow(record))
 }
-

--
Gitblit v1.9.1