Ver código fonte

feat: 完善多语言

Jack Zhou 1 semana atrás
pai
commit
fe420232b7

+ 17 - 1
src/api/module/multilingual.ts

@@ -46,4 +46,20 @@ export const getMultilingualPageInfo = (params: any, config: any) => {
     },
     config
   )
-}
+}
+
+/**
+ * get Multilingual json file
+ */
+export const getMultilingualJsonFile = (params: any, config: any) => {
+  return HttpAxios.post(
+    `${baseUrl}`,
+    {
+      action: 'multilingual',
+      operate: 'load_all_pages_by_lang',
+      ...params
+    },
+    config
+  )
+
+}

+ 3 - 3
src/components/VBreadcrumb/src/VBreadcrumb.vue

@@ -73,9 +73,9 @@ const jumpLinkMonitoring = () => {
     <div style="font-weight: 400">{{ t('destinationDelivery.confirmLeavePage') }}</div>
     <template #footer>
       <div class="dialog-footer">
-        <el-button type="default" @click="CancelRulesVisible = false" style="width: 100px"
-          >{{ t('common.cancel') }}</el-button
-        >
+        <el-button type="default" @click="CancelRulesVisible = false" style="width: 100px">{{
+          t('common.cancel')
+        }}</el-button>
         <el-button class="el-button--warning" @click="jumpLinkMonitoring" style="width: 100px">
           {{ t('common.ok') }}
         </el-button>

+ 34 - 0
src/locales/en.json

@@ -399,6 +399,40 @@
     "smartAssistantContent": "Smart Assistant is live! Ask in natural language, get real-time shipment data with multi-language support.",
     "smartNotificationContent": "Smart Notification is here! Four key event alerts with customizable rules and multi-channel delivery."
   },
+  "menu": {
+    "dashboard": "Dashboard",
+    "booking": "Booking",
+    "booking_management": "Booking Management",
+    "report": "Report",
+    "reportManagement": "Report Management",
+    "reportDetail": "Detail",
+    "reportSchedule": "Schedule Configuration",
+    "bookingDetail": "Booking Detail",
+    "destination_delivery": "Destination Delivery",
+    "tracking": "Tracking",
+    "trackingDetail": "Tracking Detail",
+    "trackingDownloadAttachment": "Tracking Download Attachment",
+    "shipmentDetail": "Shipment Detail",
+    "addVGM": "Add VGM",
+    "publicTracking": "Public Tracking",
+    "publicTrackingDetail": "Detail",
+    "login": "Login",
+    "resetPassword": "Reset Password",
+    "system_management": "System Management",
+    "system_message": "System Message",
+    "systemMessageDetail": "Detail",
+    "system_settings": "System Settings",
+    "createNewRule": "Create New Rule",
+    "createNewBooking": "Create New Booking",
+    "configurations": "Configurations",
+    "template_management": "Template Management",
+    "multilingual_config": "Multilingual Config",
+    "chat_log": "Chat Log",
+    "ai_api_log": "AI API Log",
+    "operation_log": "Operation Log",
+    "prompt_configuration": "Prompt Configuration"
+
+  },
   "layout": {
     "themes": "Themes",
     "customizeWorkspaceTip": "Customize your workspace by changing the appearance and theme color",

+ 71 - 25
src/router/index.ts

@@ -3,7 +3,9 @@ import { useUserStore } from '@/stores/modules/user'
 import { useBreadCrumb } from '@/stores/modules/breadCrumb'
 import { useHeaderSearch } from '@/stores/modules/headerSearch'
 import { useFiltersStore } from '@/stores/modules/filtersList'
+import i18n from '@/locales/index'
 
+const t = i18n.global.t
 const router = createRouter({
   history: createWebHistory(`${import.meta.env.VITE_BASE_URL}`),
   routes: [
@@ -16,17 +18,26 @@ const router = createRouter({
         {
           path: '/dashboard',
           name: 'Dashboard',
-          component: () => import('../views/Dashboard')
+          component: () => import('../views/Dashboard'),
+          meta: {
+            breadName: t('menu.dashboard')
+          }
         },
         {
           path: '/booking',
           name: 'Booking',
-          component: () => import('../views/Booking')
+          component: () => import('../views/Booking'),
+          meta: {
+            breadName: t('menu.booking')
+          }
         },
         {
           path: '/report',
           name: 'Report Management',
-          component: () => import('../views/Report')
+          component: () => import('../views/Report'),
+          meta: {
+            breadName: t('menu.reportManagement')
+          }
         },
         {
           path: '/report/detail',
@@ -34,7 +45,7 @@ const router = createRouter({
           component: () => import('../views/Report/src/components/ReportDetail'),
           meta: {
             activeMenu: '/report',
-            breadName: 'Detail'
+            breadName: t('menu.reportDetail')
           }
         },
         {
@@ -43,7 +54,7 @@ const router = createRouter({
           component: () => import('../views/Report/src/components/ReportSchedule'),
           meta: {
             activeMenu: '/report',
-            breadName: 'Schedule Configuration'
+            breadName: t('menu.reportSchedule')
           }
         },
         {
@@ -51,20 +62,25 @@ const router = createRouter({
           name: 'Booking Detail',
           component: () => import('../views/Booking/src/components/BookingDetail'),
           meta: {
-            activeMenu: '/booking'
+            activeMenu: '/booking',
+            breadName: t('menu.bookingDetail')
           }
         },
         {
           path: '/tracking',
           name: 'Tracking',
-          component: () => import('../views/Tracking')
+          component: () => import('../views/Tracking'),
+          meta: {
+            breadName: t('menu.tracking')
+          }
         },
         {
           path: '/tracking/detail',
           name: 'Tracking Detail',
           component: () => import('../views/Tracking/src/components/TrackingDetail'),
           meta: {
-            activeMenu: '/tracking'
+            activeMenu: '/tracking',
+            breadName: t('menu.trackingDetail')
           }
         },
         {
@@ -72,7 +88,9 @@ const router = createRouter({
           name: 'Tracking Download Attachment',
           component: () => import('../views/Tracking/src/components/DownloadAttachment'),
           meta: {
-            activeMenu: '/tracking'
+            activeMenu: '/tracking',
+            breadName: t('menu.trackingDownloadAttachment')
+
           }
         },
         {
@@ -80,7 +98,8 @@ const router = createRouter({
           name: 'Shipment Detail',
           component: () => import('../views/Tracking/src/components/TrackingDetail'),
           meta: {
-            activeMenu: '/tracking'
+            activeMenu: '/tracking',
+            breadName: t('menu.shipmentDetail')
           }
         },
         {
@@ -89,7 +108,8 @@ const router = createRouter({
           component: () =>
             import('../views/Tracking/src/components/TrackingTable/src/components/VGMView.vue'),
           meta: {
-            activeMenu: '/tracking'
+            activeMenu: '/tracking',
+            breadName: t('menu.addVGM')
           }
         },
         {
@@ -97,7 +117,8 @@ const router = createRouter({
           name: 'Public Tracking',
           component: () => import('../views/Tracking/src/components/PublicTracking'),
           meta: {
-            activeMenu: '/tracking'
+            activeMenu: '/tracking',
+            breadName: t('menu.publicTracking')
           }
         },
         {
@@ -108,7 +129,9 @@ const router = createRouter({
               '../views/Tracking/src/components/PublicTracking/src/components/PublicTrackingDetail.vue'
             ),
           meta: {
-            activeMenu: '/tracking'
+            activeMenu: '/tracking',
+            breadName: t('menu.publicTrackingDetail')
+
           }
         },
         {
@@ -116,18 +139,22 @@ const router = createRouter({
           name: 'Login',
           component: () => import('../views/Login'),
           meta: {
-            activeMenu: '/tracking'
+            activeMenu: '/tracking',
+            breadName: t('menu.login')
           }
         },
         {
           path: '/reset-password',
           name: 'Reset Password',
-          component: () => import('../views/Login/src/components/ChangePasswordCard.vue')
+          component: () => import('../views/Login/src/components/ChangePasswordCard.vue'),
+          meta: {
+            breadName: t('menu.resetPassword')
+          }
         },
         {
           path: '/operation-log',
           name: 'Operation log',
-          component: () => import('../views/OperationLog')
+          component: () => import('../views/OperationLog'),
         },
         {
           path: '/chat-log',
@@ -160,28 +187,35 @@ const router = createRouter({
         {
           path: '/system-message',
           name: 'System Message',
-          component: () => import('../views/SystemMessage')
+          component: () => import('../views/SystemMessage'),
+          meta: {
+            breadName: t('menu.systemMessage')
+          }
         },
         {
           path: '/system-message-detail',
           name: 'System Message Detail',
+          component: () => import('../views/SystemMessage/src/components/SystemMessageDetail.vue'),
           meta: {
-            breadName: 'Detail',
+            breadName: t('menu.systemMessageDetail'),
             activeMenu: '/system-message'
           },
-          component: () => import('../views/SystemMessage/src/components/SystemMessageDetail.vue')
         },
         {
           path: '/system-settings',
           name: 'System Settings',
-          component: () => import('../views/SystemSettings')
+          component: () => import('../views/SystemSettings'),
+          meta: {
+            breadName: t('menu.systemSettings')
+          }
         },
         {
           path: '/system-settings/create-new-rule',
           name: 'Create New Rule',
           component: () => import('../views/SystemSettings/src/components/CreateNewrule'),
           meta: {
-            activeMenu: '/system-settings'
+            activeMenu: '/system-settings',
+            breadName: t('menu.createNewRule')
           }
         },
         {
@@ -192,19 +226,29 @@ const router = createRouter({
         {
           path: '/destination-delivery',
           name: 'Destination Delivery',
-          component: () => import('../views/DestinationDelivery')
+          component: () => import('../views/DestinationDelivery'),
+          meta: {
+            breadName: t('menu.destinationDelivery')
+          }
+
         },
         {
           path: '/destination-delivery/create-new-booking',
           name: 'Create New Booking',
-          component: () => import('../views/DestinationDelivery/src/components/CreateNewBooking')
+          component: () => import('../views/DestinationDelivery/src/components/CreateNewBooking'),
+          meta: {
+            breadName: t('menu.createNewBooking'),
+            activeMenu: '/destination-delivery'
+          }
+
         },
         {
           path: '/destination-delivery/configurations',
           name: 'Configurations',
           component: () => import('../views/DestinationDelivery/src/components/ConfiguRations'),
           meta: {
-            activeMenu: '/destination-delivery'
+            activeMenu: '/destination-delivery',
+            breadName: t('menu.configurations')
           }
         },
         {
@@ -215,7 +259,9 @@ const router = createRouter({
               '../views/DestinationDelivery/src/components/ConfiguRations/src/components/CreateNewRule.vue'
             ),
           meta: {
-            activeMenu: '/destination-delivery'
+            activeMenu: '/destination-delivery',
+            breadName: t('menu.createNewRule')
+
           }
         },
         {

+ 1 - 1
src/stores/modules/breadCrumb.ts

@@ -2,7 +2,7 @@ import { defineStore } from 'pinia'
 
 interface Route {
   breadName: string
-
+  label: string
   path: string
   query?: string
 }

+ 1 - 1
src/views/Booking/src/components/BookingDetail/src/components/ContainersView.vue

@@ -37,7 +37,7 @@ const tableData = ref<VxeGridProps<any>>({
 const handleColumns = (columns: any) => {
   const newColumns = columns.map((item: any) => {
     let curColumn: any = {
-      title: item.title,
+      title: t(item.cleaned_field_name),
       field: item.field,
       minWidth: 30
     }

+ 1 - 1
src/views/Booking/src/components/BookingTable/src/BookingTable.vue

@@ -40,7 +40,7 @@ const tableOriginColumnsField = ref()
 const handleColumns = (columns: any, status?: string) => {
   const newColumns = columns.map((item: any) => {
     let curColumn: any = {
-      title: t(`${item.cleaned_field_name}`),
+      title: t(item.cleaned_field_name),
       field: item.field,
       sortable: true
     }

+ 3 - 1
src/views/Dashboard/src/components/ScoringSystem.vue

@@ -341,7 +341,9 @@ const submitDetails = (val: any) => {
     <div class="scoring_left">
       <img class="scoring_img" src="../image/dashboard_scoring.png" />
       <div>{{ t('scoringGrade.satisfactionQuestionWithSpace') }}</div>
-      <div class="das_share" @click="dialogVisible = true">{{ t('scoringGrade.shareYourFeedback') }}</div>
+      <div class="das_share" @click="dialogVisible = true">
+        {{ t('scoringGrade.shareYourFeedback') }}
+      </div>
       <el-dialog
         v-model="dialogVisible"
         :destroy-on-close="true"

+ 20 - 18
src/views/Layout/src/components/Menu/MenuView.vue

@@ -29,84 +29,84 @@ const getMenuList = () => {
   menuList.value = [
     {
       index: '1',
-      label: 'Dashboard',
+      label: 'dashboard',
       icon: 'icon_data_fill_b',
       path: '/dashboard'
     },
     {
       index: '2',
-      label: 'Booking',
+      label: 'booking',
       icon: 'icon_booking__fill_b',
       type: 'list',
       children: [
         {
           index: '2-1',
-          label: 'Booking Management',
+          label: 'bookingManagement',
           path: '/booking'
         },
         {
           index: '2-2',
-          label: 'Destination Delivery',
+          label: 'destinationDelivery',
           path: '/destination-delivery'
         }
       ]
     },
     {
       index: '3',
-      label: 'Tracking',
+      label: 'tracking',
       icon: 'icon_tracking__fill_b',
       path: '/tracking'
     },
     {
       index: '4',
-      label: 'Report',
+      label: 'report',
       icon: 'icon_report__fill_b',
       path: '/report'
     },
     {
       index: '5',
-      label: 'System Management',
+      label: 'systemMessage',
       icon: 'icon_system__management_fill_b',
       type: 'list',
       children: [
         {
           index: '5-7',
-          label: 'Template Management',
+          label: 'templateManagement',
           path: '/template-management'
         },
         {
           index: '5-1',
-          label: 'System Message',
+          label: 'systemMessage',
           path: '/system-message'
         },
         {
           index: '5-2',
-          label: 'System Settings',
+          label: 'systemSettings',
           path: '/system-settings'
         },
         {
           index: '5-3',
-          label: 'Multilingual Config',
+          label: 'multilingualConfig',
           path: '/multilingual-config'
         },
         {
           index: '5-4',
-          label: 'Chat Log',
+          label: 'chatLog',
           path: '/chat-log'
         },
         {
           index: '5-5',
-          label: 'AI API Log',
+          label: 'aiApiLog',
           path: '/ai-api-log'
         },
         {
           index: '5-6',
-          label: 'Operation Log',
+          label: 'operationLog',
           path: '/operation-log'
         },
         {
           index: '5-7',
-          label: 'Prompt Configuration',
+          label: 'promptConfiguration',
           path: '/prompt-configuration'
         }
       ]
@@ -246,15 +246,17 @@ const jumpLink = (link: string) => {
           :index="item.path"
         >
           <span class="font_family" :class="[`icon-${item.icon}`]"></span>
-          <template #title>{{ item.label }}</template>
+          <template #title>{{ t(`menu.${item.label}`) }}</template>
         </el-menu-item>
         <el-sub-menu v-else :index="item.index">
           <template #title>
             <div class="font_family" style="font-size: 16px" :class="[`icon-${item.icon}`]"></div>
-            <span>{{ item.label }}</span>
+            <span>{{ t(`menu.${item.label}`) }}</span>
           </template>
           <template v-for="childrenItem in item.children" :key="childrenItem.index">
-            <el-menu-item :index="childrenItem.path">{{ childrenItem.label }}</el-menu-item>
+            <el-menu-item :index="childrenItem.path">{{
+              t(`menu.${childrenItem.label}`)
+            }}</el-menu-item>
           </template>
         </el-sub-menu>
       </template>

+ 49 - 36
src/views/MultilingualConfig/src/MultilingualConfig.vue

@@ -3,6 +3,7 @@ import { type VxeGridProps } from 'vxe-table'
 import { useCalculatingHeight } from '@/hooks/calculatingHeight'
 import FilterTabs from './components/FilterTabs.vue'
 import { cloneDeep } from 'lodash'
+import { onBeforeRouteLeave } from 'vue-router'
 
 const languageStatusList = [
   'englishStatus',
@@ -187,38 +188,14 @@ type EditableField =
 const tableData = ref<VxeGridProps<RowItem>>({
   border: true,
   round: true,
-  columns: [
-    // {
-    //   title: 'Key',
-    //   field: 'key',
-    //   width: 300,
-    //   slots: {
-    //     default: 'key'
-    //   }
-    // },
-    // {
-    //   title: 'English',
-    //   field: 'english',
-    //   minWidth: 300,
-    //   slots: {
-    //     header: 'table_header',
-    //     default: 'cell'
-    //   }
-    // },
-    // {
-    //   title: 'Chinese',
-    //   field: 'simplifiedChinese',
-    //   minWidth: 300,
-    //   slots: {
-    //     header: 'table_header',
-    //     default: 'cell'
-    //   }
-    // }
-  ],
+  columns: [],
   cellConfig: {
-    // minHeight: 68
+    // minHeight: 62
   },
-  scrollY: { enabled: true, oSize: 20, gt: 30 },
+  columnConfig: {
+    resizable: true
+  },
+  // scrollY: { enabled: true, oSize: 20, gt: 30 },
   emptyText: ' '
 })
 
@@ -272,6 +249,13 @@ const spanishUnverifiedNumber = computed(() => {
 const portugueseUnverifiedNumber = computed(() => {
   return showTableData.value.filter((item) => item.portugueseStatus === 0).length
 })
+const curPageUnverifiedNumber = computed(() => {
+  return (
+    variableTableData.value.filter((item) =>
+      currnentTab.value.some((status) => item[status as keyof typeof item] === 0)
+    ).length || 0
+  )
+})
 
 const unverifiedNumberMap = computed(() => {
   return {
@@ -289,6 +273,7 @@ const tableLoading = ref(false)
 const getMultilingualConfig = async () => {
   tableLoading.value = true
   try {
+    await saveMultilingualConfig()
     const { code, data: responseData } = await $api.getMultilingualConfig({
       pagekey: selectedPage.value,
       langKey: currnentTab.value.map((status) => status.replace('Status', '')).join(',')
@@ -377,13 +362,14 @@ const getChangedConfig = () => {
 const saveMultilingualConfig = async () => {
   try {
     const changedConfig = getChangedConfig()
-    console.log('changedConfig', changedConfig)
     if (changedConfig.multilingual_param.length === 0) {
       return
     }
     const res = await $api.saveMultilingualConfig(changedConfig)
     if (res.code === 200) {
-      getMultilingualConfig()
+      // getMultilingualConfig()
+
+      originalTableData.value = cloneDeep(variableTableData.value)
     } else {
       ElMessage.error('Save failed')
     }
@@ -392,6 +378,25 @@ const saveMultilingualConfig = async () => {
     ElMessage.error('Save failed')
   }
 }
+
+let saveInterval: any = null
+const pollingSave = () => {
+  saveInterval = setInterval(() => {
+    saveMultilingualConfig()
+  }, 5000)
+}
+
+onMounted(() => {
+  pollingSave()
+})
+onBeforeRouteLeave(() => {
+  pollingSave()
+})
+onUnmounted(() => {
+  if (saveInterval) {
+    clearInterval(saveInterval)
+  }
+})
 </script>
 
 <template>
@@ -414,7 +419,7 @@ const saveMultilingualConfig = async () => {
             <div style="display: flex; align-items: center">
               <span style="font-size: 14px">{{ label }}</span>
               <div class="page-select-unverified-tag">
-                <span> {{ getCurrentPageUnverifiedNumber() }} Unverified</span>
+                <span> {{ curPageUnverifiedNumber }} Unverified</span>
               </div>
             </div>
           </template>
@@ -427,7 +432,14 @@ const saveMultilingualConfig = async () => {
             <div style="display: flex; align-items: center">
               <span>{{ item.label }}</span>
               <div class="page-item-unverified-tag" style="margin-left: 20px">
-                <span style="font-size: 10px"> {{ item.unverifiedNumber || 0 }} Unverified</span>
+                <span style="font-size: 10px">
+                  {{
+                    selectedPage === item.value
+                      ? curPageUnverifiedNumber
+                      : item.unverifiedNumber || 0
+                  }}
+                  Unverified</span
+                >
               </div>
             </div>
           </el-option>
@@ -602,11 +614,12 @@ const saveMultilingualConfig = async () => {
     align-items: center;
     justify-content: center;
     height: 20px;
-    width: 20px;
+    min-width: 20px;
+    padding: 4px;
     margin-top: 1px;
     margin-left: 8px;
     margin-right: 40px;
-    border-radius: 50%;
+    border-radius: 20px;
     font-size: 10px;
     color: var(--color-theme);
     background-color: var(--color-tag-unfinished-approval-bg);

+ 26 - 26
src/views/Tracking/src/components/PublicTracking/src/components/BasicInformation.vue

@@ -12,41 +12,41 @@ const allData: any = ref({
   basicInformation: {
     top: [
       {
-        labelKey: 'ptMawbMblNo',
+        labelKey: 'mawbMblNo',
         content: ''
       },
       {
-        labelKey: 'ptHawbHblNo',
+        labelKey: 'hawbHblNo',
         content: '',
         type: 'link'
       },
       {
-        labelKey: 'ptBookingNo',
+        labelKey: 'bookingNo',
         content: ''
       },
       {
-        labelKey: 'ptPoNo',
+        labelKey: 'poNo',
         content: ''
       },
       {
-        labelKey: 'ptVesselAirline',
+        labelKey: 'vesselAirline',
         content: ''
       },
       {
-        labelKey: 'ptVoyageFlight',
+        labelKey: 'voyageFlight',
         content: ''
       }
     ]
   },
   businessPartners: [
     {
-      titleKey: 'ptOriginAgent',
+      titleKey: 'originAgent',
       company: '',
       address: '',
       phone: ''
     },
     {
-      titleKey: 'ptDestinationAgent',
+      titleKey: 'destinationAgent',
       company: '',
       address: '',
       phone: ''
@@ -54,29 +54,29 @@ const allData: any = ref({
   ],
   packing: [
     {
-      labelKey: 'ptQuantityUnit',
+      labelKey: 'quantityUnit',
       content: ''
     },
     {
-      labelKey: 'ptGWeight',
+      labelKey: 'gWeight',
       content: ''
     },
     {
-      labelKey: 'ptChWeight',
+      labelKey: 'chWeight',
       content: ''
     },
     {
-      labelKey: 'ptVolume',
+      labelKey: 'volume',
       content: ''
     }
   ],
   marksAndDescription: [
     {
-      labelKey: 'ptMarks',
+      labelKey: 'marks',
       content: ''
     },
     {
-      labelKey: 'ptDescription',
+      labelKey: 'remark',
       content: ''
     }
   ]
@@ -95,40 +95,40 @@ const convertData = (data: any) => {
     basicInformation: {
       top: [
         {
-          labelKey: 'ptMawbMblNo',
+          labelKey: 'mawbMblNo',
           content: data.basicInfo['MAWB/MBL No.'] || '--'
         },
         {
-          labelKey: 'ptHawbHblNo',
+          labelKey: 'hawbHblNo',
           content: data.basicInfo['HAWB/HBOL'] || '--'
         },
         {
-          labelKey: 'ptBookingNo',
+          labelKey: 'bookingNo',
           content: data.basicInfo.Carrier_Booking_No || '--'
         },
         {
-          labelKey: 'ptPoNo',
+          labelKey: 'poNo',
           content: data.basicInfo.PO_NO || '--'
         },
         {
-          labelKey: 'ptVesselAirline',
+          labelKey: 'vesselAirline',
           content: data.basicInfo['Vessel/Airline'] || '--'
         },
         {
-          labelKey: 'ptVoyageFlight',
+          labelKey: 'voyageFlight',
           content: data.basicInfo['Voyage/Filght'] || '--'
         }
       ]
     },
     businessPartners: [
       {
-        titleKey: 'ptOriginAgent',
+        titleKey: 'originAgent',
         company: data.businessPartners.origin.company || '--',
         address: data.businessPartners.origin.address || '--',
         phone: data.businessPartners.origin.phone || '--'
       },
       {
-        titleKey: 'ptDestinationAgent',
+        titleKey: 'destinationAgent',
         company: data.businessPartners.destination.company || '--',
         address: data.businessPartners.destination.address || '--',
         phone: data.businessPartners.destination.phone || '--'
@@ -136,19 +136,19 @@ const convertData = (data: any) => {
     ],
     packing: [
       {
-        labelKey: 'ptQuantityUnit',
+        labelKey: 'quantityUnit',
         content: data.packing['Quantity/Unit'] || '--'
       },
       {
-        labelKey: 'ptGWeight',
+        labelKey: 'gWeight',
         content: substringFromStart(data.packing['G. Weight'], -4) + ' KGS'
       },
       {
-        labelKey: 'ptChWeight',
+        labelKey: 'chWeight',
         content: substringFromStart(data.packing['Ch. Weight'], -4) + ' KGS'
       },
       {
-        labelKey: 'ptVolume',
+        labelKey: 'volume',
         content: substringFromStart(data.packing['Volume'], -4) + ' CBM'
       }
     ]

+ 1 - 1
src/views/Tracking/src/components/TrackingDetail/src/components/AMS&ISF.vue

@@ -20,7 +20,7 @@ const loading = ref(false)
 const handleColumns = (columns: any) => {
   const newColumns = columns.map((item: any) => {
     let curColumn: any = {
-      title: item.title,
+      title: t(item.cleaned_field_name),
       field: item.field
     }
 

+ 1 - 1
src/views/Tracking/src/components/TrackingDetail/src/components/ContainersView.vue

@@ -42,7 +42,7 @@ const tableRef = ref<VxeGridInstance | null>(null)
 const handleColumns = (columns: any) => {
   const newColumns = columns.map((item: any) => {
     let curColumn: any = {
-      title: item.title,
+      title: t(item.cleaned_field_name),
       field: item.field,
       minWidth: 30
     }

+ 1 - 1
src/views/Tracking/src/components/TrackingTable/src/TrackingTable.vue

@@ -43,7 +43,7 @@ const tableOriginColumnsField = ref()
 const handleColumns = (columns: any, status?: string) => {
   const newColumns = columns?.map((item: any) => {
     let curColumn: any = {
-      title: item.title,
+      title: t(item.cleaned_field_name),
       field: item.field,
       sortable: true
     }