diff --git a/generate-menu-excel.js b/generate-menu-excel.js index 1e97c56..8c92029 100644 --- a/generate-menu-excel.js +++ b/generate-menu-excel.js @@ -688,6 +688,51 @@ const menuData = [ hideInMenu: false, parentRoute: '/system', }, + + // 一级菜单 - 知识库 + { + level: 1, + name: '知识库', + permissionCode: 'Knowledge', + route: '/kb', + component: null, + icon: 'icon-book', + order: 8, + hideInMenu: false, + }, + { + level: 2, + name: '培训手册', + permissionCode: 'Knowledge.Training', + route: '/kb/training', + component: 'views/kb/training/index', + icon: 'icon-book', + order: 0, + hideInMenu: false, + parentRoute: '/kb', + }, + { + level: 2, + name: '分类管理', + permissionCode: 'Knowledge.Category', + route: '/kb/category', + component: 'views/kb/category/index', + icon: null, + order: 1, + hideInMenu: false, + parentRoute: '/kb', + }, + { + level: 2, + name: '文章管理', + permissionCode: 'Knowledge.Article', + route: '/kb/article', + component: 'views/kb/article/index', + icon: null, + order: 2, + hideInMenu: false, + parentRoute: '/kb', + }, ]; // 生成 CSV 内容(UTF-8 BOM 以便 Excel 正确识别中文) diff --git a/src/api/operation/shipContainer.ts b/src/api/operation/shipContainer.ts new file mode 100644 index 0000000..65d0a0e --- /dev/null +++ b/src/api/operation/shipContainer.ts @@ -0,0 +1,204 @@ +import { axiosInstance } from '@/api/rbac' +import { assertBusinessOk, omsUrl, unwrapData } from '@/api/oms/common' + +function post(path: string, body?: unknown): Promise { + return axiosInstance.post(omsUrl(path), body).then((res) => { + assertBusinessOk(res.data) + return unwrapData(res.data) as T + }) +} + +function get(path: string, params?: Record): Promise { + return axiosInstance.get(omsUrl(path), { params }).then((res) => { + assertBusinessOk(res.data) + return unwrapData(res.data) as T + }) +} + +export type ShipBagItem = { + id: number + orderId: number + waybillNo: string + orderStatus?: string + orderStatusName?: string + consigneeCountry?: string +} + +export type ShipBag = { + id: number + bagNo: string + bagType: string + status: string + statusName?: string + warehouseId?: number + destinationCountry?: string + destinationPort?: string + channelCode?: string + length?: number + width?: number + height?: number + weight?: number + parcelCount: number + sealTime?: string + shipTime?: string + masterId?: number + remark?: string + createTime?: string + items?: ShipBagItem[] +} + +export type ShipMasterItem = { + id: number + itemType: string + bagId?: number + bagNo?: string + orderId?: number + waybillNo?: string +} + +export type ShipMaster = { + id: number + masterNo: string + externalMawb?: string + status: string + statusName?: string + warehouseId?: number + destinationCountry?: string + destinationPort?: string + flightOrVoyage?: string + length?: number + width?: number + height?: number + weight?: number + bagCount: number + parcelCount: number + sealTime?: string + handTime?: string + remark?: string + createTime?: string + items?: ShipMasterItem[] +} + +export type ShipBagMetaInput = { + bagNo: string + destinationCountry?: string + destinationPort?: string + channelCode?: string + length?: number | null + width?: number | null + height?: number | null + weight?: number | null + remark?: string +} + +export type ShipMasterMetaInput = { + masterNo: string + destinationCountry?: string + destinationPort?: string + flightOrVoyage?: string + length?: number | null + width?: number | null + height?: number | null + weight?: number | null + remark?: string +} + +export type ShipPageResult = { items: T[]; total: number } + +export const createShipBag = (body: { + bagType?: string + warehouseId?: number + destinationCountry?: string + channelCode?: string + remark?: string +}) => post('/operation/bag/create', body) + +export const addParcelToBag = (bagNo: string, waybillNo: string) => + post('/operation/bag/add-parcel', { bagNo, waybillNo }) + +export const removeParcelFromBag = (bagNo: string, waybillNo: string) => + post('/operation/bag/remove-parcel', { bagNo, waybillNo }) + +export const sealShipBag = (bagNo: string) => post('/operation/bag/seal', { bagNo }) + +export const voidShipBag = (bagNo: string) => post('/operation/bag/void', { bagNo }) + +export const updateShipBagMeta = (body: ShipBagMetaInput) => + post('/operation/bag/update-meta', body) + +export const getShipBag = (bagNo: string) => get('/operation/bag/get', { bagNo }) + +export const pageShipBags = (body: { + pageIndex?: number + pageSize?: number + keyword?: string + status?: string + warehouseId?: number +}) => post>('/operation/bag/page', body) + +export type ShipPrintLabelItem = { + bagNo?: string + masterNo?: string + printUrl: string +} + +export type ShipPrintLabelsResult = { + templateName?: string + items: ShipPrintLabelItem[] +} + +/** POST /operation/bag/print-labels */ +export const printShipBagLabels = (body: { bagNos: string[]; labelTemplateId?: number }) => + post('/operation/bag/print-labels', body) + +export const outboundByBag = (bagNo: string, warehouseId?: number) => + post<{ bagNo: string; successCount: number; waybillNos: string[] }>( + '/operation/outbound/bag-create', + { bagNo, warehouseId }, + ) + +export const createShipMaster = (body: { + warehouseId?: number + destinationCountry?: string + flightOrVoyage?: string + externalMawb?: string + remark?: string +}) => post('/operation/master/create', body) + +export const addBagToMaster = (masterNo: string, bagNo: string) => + post('/operation/master/add-bag', { masterNo, bagNo }) + +export const addParcelToMaster = (masterNo: string, waybillNo: string) => + post('/operation/master/add-parcel', { masterNo, waybillNo }) + +export const removeMasterItem = (masterNo: string, itemId: number) => + post('/operation/master/remove-item', { masterNo, itemId }) + +export const sealShipMaster = (masterNo: string) => + post('/operation/master/seal', { masterNo }) + +export const bindMasterMawb = (masterNo: string, externalMawb: string, flightOrVoyage?: string) => + post('/operation/master/bind-mawb', { masterNo, externalMawb, flightOrVoyage }) + +export const updateShipMasterMeta = (body: ShipMasterMetaInput) => + post('/operation/master/update-meta', body) + +export const handOverMaster = (masterNo: string) => + post('/operation/master/hand-over', { masterNo }) + +export const getShipMaster = (masterNo: string) => + get('/operation/master/get', { masterNo }) + +export const pageShipMasters = (body: { + pageIndex?: number + pageSize?: number + keyword?: string + status?: string + warehouseId?: number +}) => post>('/operation/master/page', body) + +/** POST /operation/master/print-labels */ +export const printShipMasterLabels = (body: { + masterNos: string[] + labelTemplateId?: number +}) => post('/operation/master/print-labels', body) diff --git a/src/components/top-nav/RightTopUser.vue b/src/components/top-nav/RightTopUser.vue index a416554..4a6f729 100644 --- a/src/components/top-nav/RightTopUser.vue +++ b/src/components/top-nav/RightTopUser.vue @@ -465,11 +465,8 @@ const pwdForm = reactive({ confirmPassword: '', }); -function validateConfirmPassword( - _rule: unknown, - value: string, - callback: (error?: string) => void -) { +// Arco Form:validator(value, callback) +function validateConfirmPassword(value: string, callback: (error?: string) => void) { if (value !== pwdForm.newPassword) { callback(t('profile.passwordMismatch')); } else { diff --git a/src/components/top-nav/index.vue b/src/components/top-nav/index.vue index d6013c7..75b5987 100644 --- a/src/components/top-nav/index.vue +++ b/src/components/top-nav/index.vue @@ -1015,6 +1015,9 @@ const pathToRouteNameMap: Record = { '/channel/guide': 'ChannelGuide', '/marketing/guide': 'MarketingGuide', '/order/guide': 'OrderGuide', + '/kb/training': 'KbTraining', + '/kb/category': 'KbCategory', + '/kb/article': 'KbArticle', // Track 相关路由 '/track/guide': 'TrackGuide', '/track/order': 'TrackOrder', diff --git a/src/constants/pageButtonCatalog.ts b/src/constants/pageButtonCatalog.ts index 69bd4e8..828dea0 100644 --- a/src/constants/pageButtonCatalog.ts +++ b/src/constants/pageButtonCatalog.ts @@ -310,6 +310,10 @@ export const PAGE_BUTTON_PARENT_ALIASES: Record = { 'Warehouse.BinLocation.Query': 'Warehouse.BinLocation', 'Operation.InboundScan.Query': 'Operation.InboundScan', 'Operation.OutboundScan.Query': 'Operation.OutboundScan', + 'Operation.BagPack.Query': 'Operation.BagPack', + 'Operation.BagManage.Query': 'Operation.BagManage', + 'Operation.MasterBoard.Query': 'Operation.MasterBoard', + 'Operation.MasterBill.Query': 'Operation.MasterBill', 'Operation.PrintLabel.Query': 'Operation.PrintLabel', 'Operation.FulfillPack.Query': 'Operation.FulfillPack', 'Operation.FulfillPack.BatchPrint': 'Operation.FulfillPack', @@ -806,6 +810,28 @@ const CORE_GROUPS: PageButtonGroup[] = [ { code: 'Reset', name: '重置' }, { code: 'Outbound', name: '出库' }, ]), + B('Operation.BagPack', [ + { code: 'Query', name: '查询' }, + { code: 'Create', name: '开袋' }, + { code: 'Seal', name: '封袋' }, + ]), + B('Operation.BagManage', [ + { code: 'Query', name: '查询' }, + { code: 'Seal', name: '封袋' }, + { code: 'Void', name: '作废' }, + { code: 'BatchPrint', name: '批量打印' }, + ]), + B('Operation.MasterBoard', [ + { code: 'Query', name: '查询' }, + { code: 'Create', name: '开主单' }, + { code: 'Seal', name: '封板' }, + ]), + B('Operation.MasterBill', [ + { code: 'Query', name: '查询' }, + { code: 'BindMawb', name: '绑MAWB' }, + { code: 'HandOver', name: '交运' }, + { code: 'BatchPrint', name: '批量打印' }, + ]), B('Operation.PrintLabel', [ { code: 'Query', name: '查询' }, { code: 'Reset', name: '重置' }, @@ -959,6 +985,7 @@ const CORE_GROUPS: PageButtonGroup[] = [ ]), // ── 知识库 ── + B('Knowledge.Training', []), B('Knowledge.Category', [ { code: 'Query', name: '查询' }, { code: 'Knowledge.Category.Edit', name: '编辑' }, diff --git a/src/locale/en-US.ts b/src/locale/en-US.ts index 878d5ca..e509baa 100644 --- a/src/locale/en-US.ts +++ b/src/locale/en-US.ts @@ -1219,6 +1219,10 @@ export default { 'menu.operation': 'Operation', 'menu.operation.inboundScan': 'Inbound Scan', 'menu.operation.outboundScan': 'Outbound Scan', + 'menu.operation.bagPack': 'Bag Packing', + 'menu.operation.bagManage': 'Bag Manage', + 'menu.operation.masterBoard': 'Master Boarding', + 'menu.operation.masterBill': 'Master Bill', 'menu.operation.printLabel': 'Print Label', 'menu.operation.parcelArrival': 'Parcel Arrival', 'menu.operation.fulfillPack': 'Fulfill Pack & Outbound', @@ -4233,6 +4237,8 @@ export default { 'operation.printLabel.labelTemplate.outbound': 'Outbound Label', 'operation.printLabel.labelTemplate.sku': 'SKU Label', 'operation.printLabel.labelTemplate.box': 'Box Mark Label', + 'operation.printLabel.labelTemplate.shipBag': 'Ship Bag Label', + 'operation.printLabel.labelTemplate.shipMaster': 'Ship Master Label', 'operation.printLabel.preview.title': 'Label preview', 'operation.printLabel.preview.empty': 'Scan a number to show order info; open Preview when needed', 'operation.printLabel.preview.product': 'Product', diff --git a/src/locale/kb/en-US.ts b/src/locale/kb/en-US.ts index 1681b51..f2f93cd 100644 --- a/src/locale/kb/en-US.ts +++ b/src/locale/kb/en-US.ts @@ -1,5 +1,6 @@ export default { 'menu.kb': 'Knowledge Base', + 'menu.kb.training': 'Training Handbook', 'menu.kb.category': 'Categories', 'menu.kb.article': 'Articles', diff --git a/src/locale/kb/zh-CN.ts b/src/locale/kb/zh-CN.ts index e989265..326d82b 100644 --- a/src/locale/kb/zh-CN.ts +++ b/src/locale/kb/zh-CN.ts @@ -1,5 +1,6 @@ export default { 'menu.kb': '知识库', + 'menu.kb.training': '培训手册', 'menu.kb.category': '分类管理', 'menu.kb.article': '文章管理', diff --git a/src/locale/zh-CN.ts b/src/locale/zh-CN.ts index f12292e..b7b7a4a 100644 --- a/src/locale/zh-CN.ts +++ b/src/locale/zh-CN.ts @@ -1209,6 +1209,10 @@ export default { 'menu.operation': '操作', 'menu.operation.inboundScan': '入库扫描', 'menu.operation.outboundScan': '出库扫描', + 'menu.operation.bagPack': '装袋作业', + 'menu.operation.bagManage': '大包管理', + 'menu.operation.masterBoard': '打板作业', + 'menu.operation.masterBill': '主单管理', 'menu.operation.printLabel': '打印标签', 'menu.operation.parcelArrival': '快递到仓', 'menu.operation.fulfillPack': '代发打包出库', @@ -4256,6 +4260,8 @@ export default { 'operation.printLabel.labelTemplate.outbound': '出库标签', 'operation.printLabel.labelTemplate.sku': 'sku标签', 'operation.printLabel.labelTemplate.box': '箱唛标签', + 'operation.printLabel.labelTemplate.shipBag': '大包标签', + 'operation.printLabel.labelTemplate.shipMaster': '主单标签', 'operation.printLabel.preview.title': '面单预览', 'operation.printLabel.preview.empty': '扫描单号后显示订单信息,需要时可点预览查看面单', 'operation.printLabel.preview.product': '销售产品', diff --git a/src/router/routes/newModules/knowledge.ts b/src/router/routes/newModules/knowledge.ts index 4fbb87b..6e60950 100644 --- a/src/router/routes/newModules/knowledge.ts +++ b/src/router/routes/newModules/knowledge.ts @@ -12,6 +12,20 @@ const KNOWLEDGE: AppRouteRecordRaw = { order: 8, }, children: [ + { + path: 'training', + name: 'KbTraining', + component: () => import('@/views/kb/training/index.vue'), + meta: { + locale: 'menu.kb.training', + requiresAuth: true, + // 供菜单管理「同步子菜单及按钮」写入二级菜单权限码(不走路由守卫) + menuPermission: 'Knowledge.Training', + order: 0, + icon: 'icon-book', + adminPortalOnly: true, + }, + }, { path: 'category', name: 'KbCategory', @@ -20,6 +34,7 @@ const KNOWLEDGE: AppRouteRecordRaw = { locale: 'menu.kb.category', requiresAuth: true, permission: 'Knowledge.Category.Query', + menuPermission: 'Knowledge.Category', order: 1, }, }, @@ -31,6 +46,7 @@ const KNOWLEDGE: AppRouteRecordRaw = { locale: 'menu.kb.article', requiresAuth: true, permission: 'Knowledge.Article.Query', + menuPermission: 'Knowledge.Article', order: 2, }, }, diff --git a/src/router/routes/newModules/operation.ts b/src/router/routes/newModules/operation.ts index 65ef21a..54931aa 100644 --- a/src/router/routes/newModules/operation.ts +++ b/src/router/routes/newModules/operation.ts @@ -34,6 +34,54 @@ const OPERATION: AppRouteRecordRaw = { order: 2, }, }, + { + path: 'bagPack', + name: 'BagPack', + component: () => import('@/views/operation/bagPack/index.vue'), + meta: { + locale: 'menu.operation.bagPack', + requiresAuth: true, + permission: 'Operation.BagPack.Query', + menuPermission: 'Operation.BagPack', + order: 3, + }, + }, + { + path: 'bagManage', + name: 'BagManage', + component: () => import('@/views/operation/bagManage/index.vue'), + meta: { + locale: 'menu.operation.bagManage', + requiresAuth: true, + permission: 'Operation.BagManage.Query', + menuPermission: 'Operation.BagManage', + order: 4, + }, + }, + { + path: 'masterBoard', + name: 'MasterBoard', + component: () => import('@/views/operation/masterBoard/index.vue'), + meta: { + locale: 'menu.operation.masterBoard', + requiresAuth: true, + permission: 'Operation.MasterBoard.Query', + menuPermission: 'Operation.MasterBoard', + order: 5, + }, + }, + { + path: 'masterBill', + name: 'MasterBill', + component: () => import('@/views/operation/masterBill/index.vue'), + meta: { + locale: 'menu.operation.masterBill', + requiresAuth: true, + permission: 'Operation.MasterBill.Query', + menuPermission: 'Operation.MasterBill', + order: 6, + }, + }, { path: 'printLabel', name: 'PrintLabel', @@ -42,7 +90,7 @@ const OPERATION: AppRouteRecordRaw = { locale: 'menu.operation.printLabel', requiresAuth: true, permission: 'Operation.PrintLabel', - order: 3, + order: 7, }, }, { @@ -53,7 +101,7 @@ const OPERATION: AppRouteRecordRaw = { locale: 'menu.operation.parcelArrival', requiresAuth: true, permission: 'Operation.ParcelArrival.Query', - order: 4, + order: 8, }, }, { @@ -64,7 +112,7 @@ const OPERATION: AppRouteRecordRaw = { locale: 'menu.operation.fulfillPack', requiresAuth: true, permission: 'Operation.FulfillPack', - order: 5, + order: 9, }, }, ], diff --git a/src/utils/menu-i18n.ts b/src/utils/menu-i18n.ts index d6a64bd..a67a351 100644 --- a/src/utils/menu-i18n.ts +++ b/src/utils/menu-i18n.ts @@ -59,6 +59,10 @@ export const MENU_NAME_TO_LOCALE_KEY: Record = { 操作: 'menu.operation', 入库扫描: 'menu.operation.inboundScan', 出库扫描: 'menu.operation.outboundScan', + 装袋作业: 'menu.operation.bagPack', + 大包管理: 'menu.operation.bagManage', + 打板作业: 'menu.operation.masterBoard', + 主单管理: 'menu.operation.masterBill', 打印标签: 'menu.operation.printLabel', 快递到仓: 'menu.operation.parcelArrival', API: 'menu.api', @@ -109,6 +113,7 @@ export const MENU_NAME_TO_LOCALE_KEY: Record = { 技能卡片: 'menu.xhs.skills', 拟人设置: 'menu.xhs.humanSettings', 知识库: 'menu.kb', + 培训手册: 'menu.kb.training', 分类管理: 'menu.kb.category', 文章管理: 'menu.kb.article', } diff --git a/src/utils/menu-icon.ts b/src/utils/menu-icon.ts index 89a585a..79cb9e7 100644 --- a/src/utils/menu-icon.ts +++ b/src/utils/menu-icon.ts @@ -12,6 +12,7 @@ export const TOP_MENU_DEFAULT_ICONS: Record = { 'menu.operation': 'IconSettings', 'menu.api': 'IconComputer', 'menu.system': 'IconSettings', + 'menu.kb': 'IconBook', 'menu.xhs': 'IconBook', } @@ -31,6 +32,7 @@ export const SUB_MENU_DEFAULT_ICONS: Record = { 'menu.finance.rechargeRecord': 'IconList', 'menu.finance.accountFlow': 'IconSwap', 'menu.finance.receivablePayable': 'IconFile', + 'menu.kb.training': 'IconBook', 'menu.order.orderGuide': 'IconBook', 'menu.order.priceCheck': 'IconSearch', 'menu.order.placeOrder': 'IconPlus', @@ -127,6 +129,7 @@ export const PATH_TO_LOCALE_KEY: Record = { '/order/guide': 'menu.order.orderGuide', '/channel/guide': 'menu.channel.channelGuide', '/marketing/guide': 'menu.marketing.marketingGuide', + '/kb/training': 'menu.kb.training', '/agentAdmin/list': 'menu.agentAdmin.list', '/agentAdmin/commission': 'menu.agentAdmin.commission', } diff --git a/src/utils/route-name-mapper.ts b/src/utils/route-name-mapper.ts index a392d62..e1770ea 100644 --- a/src/utils/route-name-mapper.ts +++ b/src/utils/route-name-mapper.ts @@ -22,6 +22,14 @@ const routeNameMap: Record = { '/order/guide': 'OrderGuide', 'order': 'Order', '/order': 'Order', + 'operation_bag_pack': 'BagPack', + '/operation/bagPack': 'BagPack', + 'operation_bag_manage': 'BagManage', + '/operation/bagManage': 'BagManage', + 'operation_master_board': 'MasterBoard', + '/operation/masterBoard': 'MasterBoard', + 'operation_master_bill': 'MasterBill', + '/operation/masterBill': 'MasterBill', // 首页相关 'home_workplace': 'Workplace', @@ -118,6 +126,14 @@ const routeNameMap: Record = { '/marketing': 'Marketing', 'marketing_guide': 'MarketingGuide', '/marketing/guide': 'MarketingGuide', + 'kb': 'Knowledge', + '/kb': 'Knowledge', + 'kb_training': 'KbTraining', + '/kb/training': 'KbTraining', + 'kb_category': 'KbCategory', + '/kb/category': 'KbCategory', + 'kb_article': 'KbArticle', + '/kb/article': 'KbArticle', 'channel_sales_products': 'SalesProducts', '/channel/salesProducts': 'SalesProducts', 'channel_service_channels': 'ServiceChannels', diff --git a/src/utils/workplace-care.ts b/src/utils/workplace-care.ts index 9f8c04f..f7047be 100644 --- a/src/utils/workplace-care.ts +++ b/src/utils/workplace-care.ts @@ -49,6 +49,7 @@ export function resolveCareRoleTone(hasRole: (code: string) => boolean): CareRol /** 员工工作台常用入口:按角色 3~4 个,避免与「今日待办」数字入口重复 */ export type AdminQuickLinkKey = + | 'training' | 'warning' | 'waybill' | 'track' @@ -59,20 +60,28 @@ export function resolveAdminQuickLinkKeys( hasRole: (code: string) => boolean, ): AdminQuickLinkKey[] { const tone = resolveCareRoleTone(hasRole) + let roleLinks: AdminQuickLinkKey[] switch (tone) { case 'finance': - return ['waybill', 'price', 'track'] + roleLinks = ['waybill', 'price', 'track'] + break case 'cs': - return ['waybill', 'track', 'pickup'] + roleLinks = ['waybill', 'track', 'pickup'] + break case 'ops': - return ['waybill', 'pickup', 'track'] + roleLinks = ['waybill', 'pickup', 'track'] + break case 'track': - return ['warning', 'track', 'waybill'] + roleLinks = ['warning', 'track', 'waybill'] + break case 'sales': - return ['waybill', 'price', 'track'] + roleLinks = ['waybill', 'price', 'track'] + break default: - return ['waybill', 'track', 'pickup', 'price'] + roleLinks = ['waybill', 'track', 'pickup', 'price'] } + // 培训手册置顶,方便新人;总量仍控制在 4 个以内 + return ['training', ...roleLinks.filter((k) => k !== 'training')].slice(0, 4) } /** 待办卡紧急度:有量时问题件 / 理赔优先 */ diff --git a/src/views/channel/composables/useKpiAreaPage.ts b/src/views/channel/composables/useKpiAreaPage.ts index 41f79b9..08d5a79 100644 --- a/src/views/channel/composables/useKpiAreaPage.ts +++ b/src/views/channel/composables/useKpiAreaPage.ts @@ -462,14 +462,15 @@ export function useKpiAreaPage(areaType: KpiAreaType) { trigger: 'change', }, { - validator: (_rule: any, value: any, callback: any) => { + // Arco Form:validator(value, callback),不要写成 AntD 的 (rule, value, callback) + validator: (value: any, callback: (error?: string) => void) => { if ( model.matchMode === 'range' && model.leftPostCode && value && isPostcodeRangeInvalid(String(model.leftPostCode).trim(), String(value).trim()) ) { - callback(new Error(t('channel.area.form.rules.postcodeRangeInvalid'))); + callback(t('channel.area.form.rules.postcodeRangeInvalid')); } else { callback(); } diff --git a/src/views/channel/issueTemplate/index.vue b/src/views/channel/issueTemplate/index.vue index 3f2921e..0a3127d 100644 --- a/src/views/channel/issueTemplate/index.vue +++ b/src/views/channel/issueTemplate/index.vue @@ -352,7 +352,8 @@ const formItemList = computed(() => { ifShow: () => formState.handlerType === 'user', rules: [ { - validator: (_rule: unknown, value: number | undefined, callback: (error?: string) => void) => { + // Arco Form:validator(value, callback) + validator: (value: number | undefined, callback: (error?: string) => void) => { if (formState.handlerType !== 'user') { callback() return diff --git a/src/views/channel/labelDesign/index.vue b/src/views/channel/labelDesign/index.vue index 16c236f..ce3685c 100644 --- a/src/views/channel/labelDesign/index.vue +++ b/src/views/channel/labelDesign/index.vue @@ -201,6 +201,8 @@ const typeOptions = computed(() => [ { value: 'outbound', label: t('operation.printLabel.labelTemplate.outbound') }, { value: 'sku', label: t('operation.printLabel.labelTemplate.sku') }, { value: 'box', label: t('operation.printLabel.labelTemplate.box') }, + { value: 'shipBag', label: t('operation.printLabel.labelTemplate.shipBag') }, + { value: 'shipMaster', label: t('operation.printLabel.labelTemplate.shipMaster') }, ]) function typeLabel(type?: string) { diff --git a/src/views/channel/salesProducts/components/PriceListHotTable.vue b/src/views/channel/salesProducts/components/PriceListHotTable.vue index 41449ba..5076821 100644 --- a/src/views/channel/salesProducts/components/PriceListHotTable.vue +++ b/src/views/channel/salesProducts/components/PriceListHotTable.vue @@ -6,10 +6,39 @@ :class="{ 'is-ready': ready }" > + + +
+
+ +
+
+
+ + + + diff --git a/src/views/kb/training/TrainingRolePicker.vue b/src/views/kb/training/TrainingRolePicker.vue new file mode 100644 index 0000000..9e63f00 --- /dev/null +++ b/src/views/kb/training/TrainingRolePicker.vue @@ -0,0 +1,103 @@ + + + + + diff --git a/src/views/kb/training/checklist-items.ts b/src/views/kb/training/checklist-items.ts new file mode 100644 index 0000000..8d457ea --- /dev/null +++ b/src/views/kb/training/checklist-items.ts @@ -0,0 +1,111 @@ +export type TrainingWeekKey = 'week1' | 'week2' | 'week3' | 'week4' | 'practice' | 'exam' +export type TrainingRoleKey = 'all' | 'cs' | 'channel' | 'warehouse' | 'implement' + +export interface TrainingChecklistItem { + id: string + week: TrainingWeekKey + label: string + /** 为空表示全岗位;否则仅这些岗位强调 */ + roles?: TrainingRoleKey[] +} + +export const TRAINING_ROLES: { key: TrainingRoleKey; label: string; summary: string }[] = [ + { + key: 'all', + label: '通才 / 未定岗', + summary: '四周全学,约 20 个工作日', + }, + { + key: 'cs', + label: '客服', + summary: '第1+3周为主,第4周轨迹扫一眼;约 12 个工作日', + }, + { + key: 'channel', + label: '渠道运营', + summary: '第2周深挖 + 第3周待排货;第1周快速过;约 12 个工作日', + }, + { + key: 'warehouse', + label: '仓管 / 操作', + summary: '第1周状态 + 第3周入库出库;约 8~10 个工作日', + }, + { + key: 'implement', + label: '实施 / 对接', + summary: '第1周主线 + 第4周轨迹/API;约 10 个工作日', + }, +] + +/** 岗位建议学习的周次(用于课表提示) */ +export const ROLE_WEEK_FOCUS: Record = { + all: ['week1', 'week2', 'week3', 'week4', 'practice', 'exam'], + cs: ['week1', 'week3', 'week4', 'practice', 'exam'], + channel: ['week1', 'week2', 'week3', 'practice', 'exam'], + warehouse: ['week1', 'week3', 'practice', 'exam'], + implement: ['week1', 'week4', 'practice', 'exam'], +} + +export const CHECKLIST_ITEMS: TrainingChecklistItem[] = [ + // 练习包 + { id: 'practice.customer-register', week: 'practice', label: '测服自行注册客户账号(网页端 /login)' }, + { id: 'practice.admin-access', week: 'practice', label: '拿到或申请运营端账号(/admin),权限含订单/渠道/轨迹' }, + { id: 'practice.pick-product', week: 'practice', label: '选定一条已启用销售产品作为练习线(现有产品即可)' }, + { id: 'practice.happy-path', week: 'practice', label: '跑通幸福路径:查价→下单→入库→付款→出库' }, + { id: 'practice.pending-alloc', week: 'practice', label: '人为制造一票待排货,再修好变为待支付' }, + { id: 'practice.draft-fail', week: 'practice', label: '制造/找到一票预报失败草稿,能读失败原因' }, + { id: 'practice.price-vs-order', week: 'practice', label: '复现「查价有价、下单更严」(缺邮编/黑名单等)' }, + { id: 'practice.track-refresh', week: 'practice', label: '出库后在轨迹订单刷新,能读时间轴(有则看未映射)' }, + + // 第1周 + { id: 'w1.map', week: 'week1', label: '画出销售产品 / 服务渠道 / 预报 vs 入库 / 待排货' }, + { id: 'w1.pc-order', week: 'week1', label: '网页端完成查价→下单→看到已预报' }, + { id: 'w1.h5', week: 'week1', label: 'H5 同账号对照查价与订单列表' }, + { id: 'w1.ops-find', week: 'week1', label: '运营端用运单号找到该单并说出状态含义' }, + { id: 'w1.explain', week: 'week1', label: '能解释:客户选销售产品,入库后系统选服务渠道' }, + + // 第2周 + { id: 'w2.zone', week: 'week2', label: '价格分区 / 黑名单 / 偏远各做一组正反例', roles: ['all', 'channel'] }, + { id: 'w2.weight', week: 'week2', label: '按计重规则手算一例计费重', roles: ['all', 'channel'] }, + { id: 'w2.price', week: 'week2', label: '卖价矩阵故意配错,看到「卖价未匹配」', roles: ['all', 'channel'] }, + { id: 'w2.alloc', week: 'week2', label: '理解排货与买价发布;能说明待排货成因', roles: ['all', 'channel', 'cs'] }, + { id: 'w2.publish', week: 'week2', label: '规则+价格都点过发布;故意不发布观察旧规则', roles: ['all', 'channel'] }, + + // 第3周 + { id: 'w3.full', week: 'week3', label: '完整跑通:下单→入库→付款→出库' }, + { id: 'w3.pending', week: 'week3', label: '待排货→重算应付→待支付' }, + { id: 'w3.fee-talk', week: 'week3', label: '用预报/入库件重尺差演练费用解释', roles: ['all', 'cs', 'channel'] }, + { id: 'w3.cross-end', week: 'week3', label: '同一运单号网页端与运营端状态一致' }, + { id: 'w3.warehouse', week: 'week3', label: '跟一次入库/出库扫描(或录屏)', roles: ['all', 'warehouse'] }, + + // 第4周 + { id: 'w4.track', week: 'week4', label: '轨迹订单刷新,能读时间轴', roles: ['all', 'cs', 'implement'] }, + { id: 'w4.unmap', week: 'week4', label: '理解未映射:有原文无标准节点先查内容映射', roles: ['all', 'cs', 'implement'] }, + { id: 'w4.push', week: 'week4', label: '看过一条推送记录(成功或失败原因)', roles: ['all', 'implement', 'cs'] }, + { id: 'w4.api', week: 'week4', label: '能口述上游/下游/映射/应用/发布', roles: ['all', 'implement'] }, + { id: 'w4.log', week: 'week4', label: '打开请求日志对照最终报文', roles: ['all', 'implement'] }, + + // 总验收 + { id: 'exam.flow', week: 'exam', label: '能画出查价→…→轨迹状态流转' }, + { id: 'exam.price-fail', week: 'exam', label: '能解释查价有价下单失败的常见原因' }, + { id: 'exam.pending', week: 'exam', label: '能说明待排货是什么、怎么处理' }, + { id: 'exam.publish', week: 'exam', label: '改价客户仍旧价时,先查是否发布' }, + { id: 'exam.track', week: 'exam', label: '能处理「官网有轨迹你们没有」' }, + { id: 'exam.api', week: 'exam', label: '能说明上游下游映射发布;排错看请求日志' }, + { id: 'exam.ends', week: 'exam', label: '同一运单号:网页端/H5/运营端各在哪找' }, + { id: 'exam.notes', week: 'exam', label: '提交「一票货四端对照」个人笔记' }, +] + +export function itemsForWeek(week: TrainingWeekKey): TrainingChecklistItem[] { + return CHECKLIST_ITEMS.filter((i) => i.week === week) +} + +export function itemsForRole(role: TrainingRoleKey): TrainingChecklistItem[] { + const weeks = new Set(ROLE_WEEK_FOCUS[role]) + return CHECKLIST_ITEMS.filter((i) => { + if (!weeks.has(i.week)) return false + if (!i.roles || i.roles.length === 0) return true + if (role === 'all') return true + return i.roles.includes(role) || i.roles.includes('all') + }) +} diff --git a/src/views/kb/training/handbook-checklist.md b/src/views/kb/training/handbook-checklist.md new file mode 100644 index 0000000..fc813c9 --- /dev/null +++ b/src/views/kb/training/handbook-checklist.md @@ -0,0 +1,52 @@ +# 总验收说明 + +> 验收安排在 **工作日**(建议第 4 周周五或下一周周一)。 +> **下方勾选清单** 即总验收题,勾选保存在本机;带教对照勾选提问即可。 + +--- + +## 带教人 checklist + +- [ ] 测服可自助注册客户;运营账号能开 +- [ ] 练习用现有已启用销售产品即可 +- [ ] **每周五** 30 分钟对照「进度」勾选;周六日不排 +- [ ] 法定假日顺延,不压缩进周末 +- [ ] 第 4 周周五:收「一票货四端对照」笔记 + 过验收勾选 + +--- + +## 个人笔记模板 + +```text +运单号: +客户单号: +销售产品: +网页端截图: +H5 截图: +运营端状态: +预报费用 / 入库费用: +排货渠道: +轨迹最新节点: +本次踩坑: +对应指引章节: +``` + +--- + +## 配套指引 + +| 主题 | 路径 | +|------|------| +| 渠道 | [/channel/guide](/channel/guide) | +| 订单 | [/order/guide](/order/guide) | +| 轨迹 | [/track/guide](/track/guide) | +| API | [/api/apiDebugger](/api/apiDebugger) | +| 话术 | 本页「话术」Tab | +| 练习包 | 本页「练习包」Tab | + +--- + +## 一句话 + +> 先当客户发一票,再当运营配通、查通; +> 钱看渠道发布,货看订单状态,进度看轨迹映射,外系统看 API 发布与日志。 diff --git a/src/views/kb/training/handbook-overview.md b/src/views/kb/training/handbook-overview.md new file mode 100644 index 0000000..009283c --- /dev/null +++ b/src/views/kb/training/handbook-overview.md @@ -0,0 +1,111 @@ +# OMS 新人培训手册 + +> 面向 **运营、客服、实施、仓管** 等内部新人。 +> 只讲业务:怎么理解系统、怎么按月学会、怎么验收。 +> 渠道 / 订单 / 轨迹 / API 的细配与排障,请点开文末「配套指引」。 + +页面上方可选 **岗位轨**(勾选进度按岗位过滤,保存在本机)。 + +--- + +## 计时规则(必读) + +- **只计工作日(周一~周五)**,周六、周日 **不排课、不计入进度**。 +- 通才四周 ≈ **20 个工作日**;遇法定节假日顺延到下一个工作日。 +- 课表里的「周一~周五」均指当周工作日,不是自然日连号。 + +--- + +## 岗位速成(怎么选课) + +| 岗位 | 怎么学 | 大约工期 | +|------|--------|----------| +| **通才 / 未定岗** | 第1~4周全学 + 练习包 | 20 个工作日 | +| **客服** | 第1、3周为主;第4周只学轨迹(周一~周二);话术 Tab 常备 | ≈12 个工作日 | +| **渠道运营** | 第1周快速过;第2周深挖;第3周待排货与费用 | ≈12 个工作日 | +| **仓管 / 操作** | 第1周状态机;第3周入库出库与待排货协同 | ≈8~10 个工作日 | +| **实施 / 对接** | 第1周主线;第4周轨迹+API;练习包场景 1、5 | ≈10 个工作日 | + +测服账号 **自己注册**;产品用环境里已有线路即可 → 见「练习包」Tab。 + +--- + +## 1. 这套系统在干什么? + +| 模块 | 一句话 | 指引页 | +|------|--------|--------| +| **渠道** | 卖什么、卖多少、货走哪条下游 | [/channel/guide](/channel/guide) | +| **订单** | 查价 → 下单 → 入库 → 付款 → 出库 | [/order/guide](/order/guide) | +| **轨迹** | 服务商轨迹翻译成标准节点,再推给客户 | [/track/guide](/track/guide) | +| **API** | 公司标准接口 ↔ 服务商方言 | [/api/apiDebugger](/api/apiDebugger) | + +**主线:** + +``` +渠道定规则并发布 → 客户下单预报计费 → 入库实测改价并排货 +→ 付款出库 → 轨迹上网 →(可选)推客户系统 / 调外部接口 +``` + +订单状态: + +``` +草稿 → 已预报 →(入库)→ 待支付 或 待排货 + ↓(付款) + 待发货 →(出库)→ 待上网 → …轨迹 +``` + +--- + +## 2. 四个端 + +| 端 | 登录入口 | 谁用 | +|----|----------|------| +| **网页端** | `/login` | 发货客户 PC | +| **H5** | `/h5` | 同一客户手机 | +| **运营端** | `/admin` | 内部员工 | +| **客户端** | 与网页端同一客户体系 | 「当客户」优先网页端,再用 H5 对照 | + +**心态:** 先当客户发一票,再当运营配通、查通。 + +--- + +## 3. 四周主题 + +| 周次 | 主题 | +|------|------| +| **第 1 周** | 当客户跑通;分清四端 | +| **第 2 周** | 渠道为什么有价;不发布=没改 | +| **第 3 周** | 订单运营排障;待排货与费用 | +| **第 4 周** | 轨迹 + API | + +```mermaid +flowchart LR + A[第1周 当客户] --> B[第2周 渠道配置] + B --> C[第3周 订单排障] + C --> D[第4周 轨迹与API] +``` + +**刻意先不啃:** 开发 Tab、表结构、脚本细节。 + +--- + +## 4. 每日最小闭环(工作日) + +1. 网页端或 H5 下/查一票 +2. 运营端看同一运单状态与费用 +3. 出库后看轨迹时间轴 +4. 三问:发布了吗?预报还是入库?映射还是推送? + +周末可自愿复习,**不计入是否完成**。 + +--- + +## 5. 配套入口 + +| 主题 | 路径 | +|------|------| +| 练习包 | 本页「练习包」Tab | +| 对客话术 | 本页「话术」Tab | +| 勾选进度 | 本页「进度」Tab | +| 渠道 / 订单 / 轨迹 / API 指引 | `/channel/guide` 等 | +| 工作台 | 运营端工作台「培训手册」快捷入口 | diff --git a/src/views/kb/training/handbook-practice.md b/src/views/kb/training/handbook-practice.md new file mode 100644 index 0000000..b4255b5 --- /dev/null +++ b/src/views/kb/training/handbook-practice.md @@ -0,0 +1,54 @@ +# 测服练习包 + +> 账号请 **自己在测服注册**;销售产品用环境里 **已有已启用产品** 即可,不必新建专线。 +> 勾选进度见本页下方或「进度」Tab(保存在本机浏览器)。 + +--- + +## 1. 开练前准备 + +| 准备项 | 怎么做 | +|--------|--------| +| **客户账号** | 测服网页端 [`/login`](/login) 自行注册;手机可再用 H5 [`/h5`](/h5) 同账号登录 | +| **运营账号** | 向带教/管理员要内部账号,入口 [`/admin`](/admin);至少能看订单、渠道、轨迹 | +| **练习产品** | 在「我要查价 / 我要下单」里任选一条 **已启用** 销售产品;记下编码与目的国 | +| **权限** | 若侧栏没有「培训手册」,让管理员对知识库点一次「同步子菜单」,并勾选角色菜单 | + +--- + +## 2. 必练场景(建议按序) + +| # | 场景 | 你要看到什么 | 备注 | +|---|------|--------------|------| +| 1 | **幸福路径** | 已预报 → 入库后待支付 → 付款 → 出库 → 待上网 | 用任意现有产品;件重尺填完整 | +| 2 | **查价松 / 下单严** | 查价能出参考价;故意缺邮编或踩黑名单时下单失败 | 对客话术:查价仅供参考 | +| 3 | **待排货** | 入库后进待排货;修好配置/重算应付后变待支付 | 可让带教临时关掉某渠道买价或清空排货再恢复 | +| 4 | **预报失败草稿** | 订单停在草稿,有「预报失败原因」 | 常见:分区未匹配、卖价未匹配、未发布 | +| 5 | **轨迹刷新** | 出库后轨迹订单有时间轴;若有未映射会看到原文 | 服务商尚未上网时只有已预报也正常 | + +制造待排货/草稿时 **只用测服**,改完记得还原,避免影响他人。 + +--- + +## 3. 四端对照(同一票) + +对场景 1 的运单号,分别打开: + +| 端 | 看哪里 | +|----|--------| +| 网页端 | [`/order/myOrders`](/order/myOrders) | +| H5 | [`/h5/orders`](/h5/orders) | +| 运营端 | 运单管理 / 我的订单(按权限) | +| 轨迹 | [`/track/order`](/track/order)(出库后) | + +截图或记到个人笔记(模板见「进度 / 验收」)。 + +--- + +## 4. 带教最小配合 + +- 测服可注册客户;运营账号能开 +- 允许新人在测服改练习相关配置(或带教代改演示待排货) +- **每周五** 对照「进度」Tab 勾选情况聊 30 分钟;周六日不排 + +产品不必单独建:现网测服已有线路全部可用。 diff --git a/src/views/kb/training/handbook-scripts.md b/src/views/kb/training/handbook-scripts.md new file mode 100644 index 0000000..99a8abb --- /dev/null +++ b/src/views/kb/training/handbook-scripts.md @@ -0,0 +1,61 @@ +# 对客话术速查 + +> 客服日常页。先安抚,再给原因与下一步;涉及改价/禁运时对齐渠道同事。 +> 细配见 [订单指引](/order/guide)、[轨迹指引](/track/guide)、[渠道指引](/channel/guide)。 + +--- + +## 1. 开场与原则 + +| 原则 | 说法示例 | +|------|----------| +| 查价≠最终价 | 「查价是参考,最终以仓库入库实测重量和尺寸计费为准。」 | +| 状态可查 | 「您报一下运单号或客户单号,我帮您看当前到哪一步。」 | +| 不瞎承诺时效 | 「轨迹以服务商上网为准;我们这边看到节点会同步给您。」 | +| 改配置要发布 | (对内)客户仍旧价 → 先问渠道是否点过发布,别只改草稿 | + +--- + +## 2. 下单 / 费用 + +| 客户或系统说法 | 可对客户说 | 你后台先查 | +|----------------|------------|------------| +| 客户单号已存在 | 「这个客户单号已经用过了,请换一个再提交,或告诉我原单号我帮您查。」 | 同客户是否已有该单 | +| 产品不存在/未启用 | 「当前线路暂时不可用,我帮您看下可发的替代线路。」 | 销售产品是否启用 | +| 地址命中黑名单 | 「这个邮编/地区暂时无法收寄,请换地址或换线路;需要的话我帮您确认禁运范围。」 | 黑名单 + 产品关联 | +| 价格分区未匹配 | 「目的地分区还对不上报价,我请渠道同事核对邮编分区,好了马上回您。」 | 价格分区明细、是否发布 | +| 卖价未匹配 | 「这个重量/货物类型暂时报不出价,我们核对价卡后回您。」 | 卖价矩阵重量段/货物属性 | +| 未命中价格/规则快照 | 「线路规则刚在调整,请稍等我们发布后再下;或先换一条已上线线路。」 | 是否发布 rules/price | +| 查价有价、下单失败 | 「查价比较宽松,下单要完整邮编和地址。请按页面提示补全后再试。」 | 邮编、黑名单、尺寸 | +| 一直草稿 | 「系统还在算预报运费,请稍等刷新;若一直如此,我看失败原因帮您改。」 | 预报失败原因 | +| 入库后比预报贵 | 「入库按实测重和体积重重新计费,体积大或超重都会上调,这是正常规则。」 | 预报 vs 入库件重尺 | +| 一直待排货 | 「货已收到,系统还在匹配承运渠道。我们处理好运费渠道后会变成待支付,再通知您付款。」 | 待排货原因;找渠道补买价/排货 | + +--- + +## 3. 轨迹 + +| 客户说法 | 可对客户说 | 你后台先查 | +|----------|------------|------------| +| 官网有轨迹,你们没有 | 「我马上按单号刷新;若服务商文案还没对上我们的标准节点,会先补映射再更新给您。」 | 刷新;未映射原文;单号类型 | +| 一直显示已预报 | 「仓库出库后,要等服务商上网才会有运输节点。我帮您确认是否已出库、拉取是否已开始。」 | 是否出库;拉取开始节点 | +| 节点乱跳 / 缺段 | 「我们核对一下节点映射,避免关键词过宽;好了会按正确顺序展示。」 | 映射关键词、反向词 | +| 我们系统没收到推送 | 「我查一下贵司推送开关和最近一次推送记录;必要时先手工补推一笔。」 | 自动推送、顺序、推送记录 | + +--- + +## 4. 付款 / 出库 + +| 场景 | 可对客户说 | +|------|------------| +| 催付 | 「您的包裹已入库计费完成,请登录后完成支付,我们才能安排出库。」 | +| 已付未出库 | 「支付已收到,仓库正在排队出库;出库后轨迹会进入待上网。」 | +| 要拦截 | 「请提供运单号,我看当前状态能否拦截;已出库/已上网的需按服务商规则处理。」 | + +--- + +## 5. 对内三句(自己先想清) + +1. 规则/价格 **发布了吗**? +2. 卡在 **预报** 还是 **入库/排货**? +3. 轨迹是 **映射** 问题还是 **推送** 问题? diff --git a/src/views/kb/training/handbook-week1.md b/src/views/kb/training/handbook-week1.md new file mode 100644 index 0000000..bccfcd4 --- /dev/null +++ b/src/views/kb/training/handbook-week1.md @@ -0,0 +1,58 @@ +# 第 1 周:建立业务地图 + 当客户跑通一票 + +**本周目标:** 能口述「一票货从问价到上网」;分清网页端 / H5 / 运营端角色。 +**计时:** 仅周一~周五 5 个工作日;周六日不算。 + +--- + +## 学习安排(工作日) + +| 工作日 | 学什么 | 怎么练 | +|--------|--------|--------| +| **周一** | 读 [渠道指引](/channel/guide)、[订单指引](/order/guide) 前半;画业务脑图 | 纸上画出:销售产品 / 服务渠道 / 预报 vs 入库 / 待排货 | +| **周二** | 继续补脑图;运营端只逛菜单,先别改配置 | 能讲清四个模块各管什么 | +| **周三** | **网页端当客户**:查价 → 下单 → 看状态 → 付款(测服) | 故意漏邮编、错尺寸,感受「查价松、下单严」 | +| **周四** | **H5 对照同一账号** | 同一目的国/重量查价与下单,记下 PC/H5 差异与话术 | +| **周五** | 运营端找到这票:订单/运单、轨迹订单;本周验收 | 对照状态机;能讲清草稿 / 已预报 / 待支付 / 待排货 | + +--- + +## 必记概念 + +### 查价 vs 下单 + +| | 查价 | 下单 | +|--|------|------| +| 目的 | 心里有数 | 真正建单 | +| 尺寸 | 可不填(按实重大致估) | 长宽高实重都必须 > 0 | +| 邮编 | 可不填(不校验黑名单) | 必须有邮编;命中黑名单直接拒单 | +| 是否落库 | 否 | 是,有运单号 | + +**对客话术:** 查价仅供参考;最终以入库实测计费为准。 + +### 幸福路径(先走通) + +假设发马来西亚,销售产品「MY 特惠线」,预报 30×20×10 cm、实重 0.8kg: + +1. 查价 → 看到参考运费 +2. 下单成功 → 很快变 **已预报**,有预报运费 +3. 入库称重变了 → 重算应收 → 排货成功 → **待支付** +4. 客户付款 → **待发货** +5. 出库 → **待上网**,之后看轨迹 + +### 刚下完单还是「草稿」? + +多半预报还在队列里。等几秒刷新;若一直草稿,打开订单看 **预报失败原因**。 + +--- + +## 本周练习 + +请在本页 **下方勾选清单** 完成练习(进度保存在本机)。 +客服 / 仓管 / 实施:本周为必学;渠道运营可快速过状态机后进入第 2 周。 + +--- + +## 周五验收 + +能对客说清「查价仅供参考,最终以入库实测为准」;能画出状态流转;能指出同一票在网页端 / H5 / 运营端分别在哪看。 diff --git a/src/views/kb/training/handbook-week2.md b/src/views/kb/training/handbook-week2.md new file mode 100644 index 0000000..f937896 --- /dev/null +++ b/src/views/kb/training/handbook-week2.md @@ -0,0 +1,94 @@ +# 第 2 周:渠道配置(为什么有价、为什么卡单) + +**本周目标:** 理解钱与走货规则从哪来;会按推荐顺序在测服配一条测试线。 +**计时:** 仅周一~周五 5 个工作日;周六日不算。 + +详配见 [渠道指引](/channel/guide)。 + +--- + +## 心智模型 + +> **销售产品**决定客户怎么买、卖多少钱; +> **服务渠道**决定货怎么走、成本多少; +> **排货**把两者在入库时接上。 +> **改配置不发布 = 等于没改。** + +订单计费读的是 **发布后的快照**,不是你刚改完还没点发布的草稿。 + +--- + +## 新开线路推荐顺序(照着做) + +``` +主数据 + ① 价格分区(国家/邮编落到哪一价区) + ② 黑名单(禁运) + ③ 偏远分区(可选) + ④ 计重规则 + 计重进位 + +成本侧 + ⑤ 建服务渠道(下游通道) + ⑥ 配渠道买价并发布 + +卖价侧 + ⑦ 建销售产品,绑上分区、计重、黑名单等 + ⑧ 配产品卖价 + ⑨ 配排货(挂上可用服务渠道) + ⑩ 写对客说明(可选) + ⑪ 发布「规则」+ 发布「价格」 +``` + +| 发布类型 | 大概包含 | 忘了会怎样 | +|----------|----------|------------| +| **规则(rules)** | 计重、黑名单、偏远、排货等 | 计重/禁运/排货仍按旧版 | +| **价格(price)** | 卖价矩阵 + 价格分区明细 | 运费仍按旧卖价 | + +--- + +## 学习安排(工作日) + +| 工作日 | 重点 | +|--------|------| +| **周一** | 价格分区 / 黑名单 / 偏远:各做一组正反例(邮编多为左开右闭) | +| **周二** | 计重规则 + 进位;用例子算出计费重 | +| **周三** | 卖价矩阵:价区 × 重量段 × 货物属性;故意配错看「卖价未匹配」 | +| **周四** | 服务渠道买价 + 排货;买价不发布 → 入库容易进 **待排货** | +| **周五** | 规则 + 价格发布;对照订单报错表自测;本周验收 | + +--- + +## 必记例子 + +### 计费重 + +产品:体积重 = 长×宽×高 ÷ 6000;实重与体积重取大。 + +- 件:30×20×10、实重 0.8 → 体积重 1.0 → 计费重 **1.0kg** +- 入库后实重变 1.2 → 计费重可能升到更高档 → 应收比预报高,属正常,要跟客户讲清 + +### 黑名单 vs 偏远 + +| | 黑名单 | 偏远 | +|--|--------|------| +| 命中 | **不能下单** | 可以下单,订单标偏远 | +| 运营 | 换地址或改黑名单区 | 留意偏远附加费 | + +### 只配卖价、排货为空 / 买价未发布 + +→ 入库后容易进 **待排货**(货已收,但还没定走哪条下游)。 + +--- + +## 本周练习 + +请在本页 **下方勾选清单** 完成练习。 +**渠道运营** 本周为重头;客服至少要懂「待排货 / 未发布」话术;仓管/实施可略读。 + +产品:用测服 **已有销售产品** 练习发布与排障即可,不必新建专线。 + +--- + +## 周五验收 + +能默写新产品上线 checklist;改价忘发布能自己排查;能说清销售产品 vs 服务渠道。 diff --git a/src/views/kb/training/handbook-week3.md b/src/views/kb/training/handbook-week3.md new file mode 100644 index 0000000..8a0bfa6 --- /dev/null +++ b/src/views/kb/training/handbook-week3.md @@ -0,0 +1,95 @@ +# 第 3 周:订单全链路运营 + 客服排障 + +**本周目标:** 会跟仓、会催付、会看费用争议;网页端 / H5 / 运营端同一票能对上。 +**计时:** 仅周一~周五 5 个工作日;周六日不算。 + +详配与报错表见 [订单指引](/order/guide)。 + +--- + +## 学习安排(工作日) + +| 工作日 | 重点 | +|--------|------| +| **周一** | 幸福路径上半:下单 → 已预报 → 入库 → 待支付 | +| **周二** | 幸福路径下半:付款 → 出库 → 待上网;四端对同一运单号 | +| **周三** | **待排货专项**:看原因、补买价/排货、重算应付 | +| **周四** | 预报 vs 入库费用;常见报错话术演练 | +| **周五** | 批量导入 / 模板映射(若常用);跟一次入库出库;本周验收 | + +--- + +## 入库与待排货 + +入库时系统会: + +1. 写入库实测件重尺 +2. **重算客户应收** +3. **尝试自动排货**(从销售产品排货列表选服务渠道并算成本) + +| 结果 | 订单状态 | 含义 | +|------|----------|------| +| 排货成功 | **待支付** | 可以催客户付款 | +| 排货失败 | **待排货** | 货已收、钱也能算给客户看,但还没定下游渠道 | + +**待排货不是丢单。** 常见原因:排货列表空、渠道未启用、买价未发布、客户不在白名单、重量/分区匹配不到买价。 + +处理完后在订单侧做 **重算应付**(以现场按钮名为准),成功应变为 **待支付**。 + +--- + +## 下单成功后系统在忙什么?(运营视角) + +| 阶段 | 你会看到 | 失败时 | +|------|----------|--------| +| 提交当时 | 有运单号,可能短暂「草稿/处理中」 | — | +| 预报计费 | 变成 **已预报**,有预报应收 | 停在草稿,看预报失败原因 | +| 面单 / 营销等 | 异步,一般不挡下单 | 可稍后重打面单 | +| 入库后 | 实测改价 + 排货 | 待排货或待支付 | + +拦截类自动触发发生在「点下单、还没建成单」之前:命中则直接报错,**不会留下订单**。 + +--- + +## 常见报错 ↔ 怎么回 + +| 客户或系统提示 | 可能原因 | 运营动作 | +|----------------|----------|----------| +| 客户单号已存在 | 同客户重复客户单号 | 换单号,或查是否已下过 | +| 销售产品不存在或未启用 | 产品停用 / 编码错 | 查销售产品状态 | +| 未命中价格/规则快照 | 改过配置 **没发布** | 渠道 → 销售产品 → 发布 | +| 收件地址命中黑名单 | 地址在禁运区 | 换地址,或调整黑名单 | +| 价格分区未匹配 | 邮编/国家不在分区 | 补分区或核对地址 | +| 卖价未匹配 | 重量段/货物属性/价区对不上 | 查卖价矩阵 | +| 查价有价、下单失败 | 查价未校验邮编/黑名单 | 用完整地址再试下单 | +| 一直待排货 | 见上一节 | 先看订单上的待排货原因 | + +--- + +## 推荐日常工作流(运营) + +``` +① 新产品:先在渠道配齐并发布 +② 「我要查价」自测几个国家+重量 +③ 「我要下单」测单 → 确认已预报 +④ 仓库入库 → 确认待支付(待排货则先排障) +⑤ 付款 → 出库 → 轨迹中心看是否上网 +⑥ 客诉对照上表;费用争议核对预报 vs 入库实测 +``` + +常用菜单:查价 `/order/priceCheck`、下单 `/order/placeOrder`、我的订单 `/order/myOrders`;仓侧在 **操作** 菜单(入库/出库扫描)。 + +--- + +## 本周练习 + +请在本页 **下方勾选清单** 完成练习。 +客服 / 仓管 / 渠道运营均为重点周;实施可跟一票幸福路径即可。 + +话术见「话术」Tab;待排货场景见「练习包」。 + +--- + +## 周五验收 + +给一张异常单,能定位是渠道配置、地址问题,还是还在预报队列;能处理待排货到待支付。 diff --git a/src/views/kb/training/handbook-week4.md b/src/views/kb/training/handbook-week4.md new file mode 100644 index 0000000..14b20d2 --- /dev/null +++ b/src/views/kb/training/handbook-week4.md @@ -0,0 +1,91 @@ +# 第 4 周:轨迹对客 + API 对接意识 + +**本周目标:** 客服查轨迹不慌;知道外部系统怎么连进来(业务层,不写代码)。 +**计时:** 仅周一~周五 5 个工作日;周六日不算。 + +详见 [轨迹指引](/track/guide)、[API 指引](/api/apiDebugger)。 + +--- + +## 学习安排(工作日) + +| 工作日 | 重点 | +|--------|------| +| **周一** | 轨迹:状态/内容主数据 → 拉取映射 → 单票刷新;「官网有、我们没有」优先查未映射 | +| **周二** | 推送:自动推送、顺序异常、手工救急;预警概念扫一眼 | +| **周三** | API:上游 / 下游 / 映射 / 应用 / 发布;跟一次调试;看请求日志 | +| **周四** | 串讲:渠道发布 → 客户下单 → 出库 → 轨迹拉取 →(可选)推客户 / 调外部 | +| **周五** | **综合演练**:一票货四端截图对照;整理 FAQ;准备总验收 | + +--- + +## 轨迹心智模型 + +> **拉取** = 把服务商的话翻译成公司标准节点; +> **推送** = 按约定顺序告诉客户。 +> 看到原始轨迹却没有标准节点,优先查 **内容映射**,不是「系统没拉到」。 + +``` +服务商原始轨迹 + → 轨迹中心按规则翻译成「标准节点」 + → 写到轨迹订单 + →(可选)推送给客户系统 / OMS +``` + +### 新服务商接入顺序(运营向) + +``` +① 轨迹状态(已揽收 / 运输中 / 签收 …) +② 轨迹内容(标准话术关联状态) +③ 轨迹标记(可选) +④ 确认拉取接口已通 +⑤ 轨迹拉取:主配置 → 内容映射 → 频率 +⑥ 轨迹推送(若客户要回调) +⑦ 测试单「刷新轨迹」,看时间轴与推送记录 +``` + +### 客服常见问答 + +| 客户说法 | 可能原因 | 怎么处理 | +|----------|----------|----------| +| 官网有轨迹,你们没有 | 未映射 / 间隔未到 / 单号类型不对 | 刷新;看未映射原文;补映射 | +| 一直显示已预报 | 未上网,或拉取未开始 | 看出库、拉取开始节点 | +| 我们系统没收回调 | 自动推送关了、顺序卡了、异常单 | 查推送记录;必要时手工推 | + +--- + +## API(Like API)心智模型 + +> **上游**是公司普通话,**下游**是服务商方言;**映射**是翻译器,**发布**才上岗。 +> 排错先看 **请求日志里真正发出的那一包**。 + +| 名词 | 白话 | +|------|------| +| 上游接口 | 给业务用的标准口(如 `TRACK_QUERY`) | +| 下游接口 | 服务商真实 HTTP | +| 映射 | 字段对照 + 签名脚本 | +| 应用 | 谁有权调用(AppKey) | +| 发布 | 配置生效开关 | + +推荐上手:下游(贴 cURL)→ 上游 → 映射 → 应用授权 → 调试 / 请求日志。 + +**注意:** `/api/apiDebugger` 自由调试 **不会** 自动写回下游配置;正式联调优先在已配置的上下游里调试。 + +--- + +## 本周练习 + +请在本页 **下方勾选清单** 完成练习。 +**实施** 全周必学;**客服** 重点周一~周二轨迹;渠道/仓管可浏览。 + +--- + +## 周五验收 + +能讲清三件事: + +1. 订单卡在哪一段(预报 / 待排货 / 待支付 / 待上网) +2. 轨迹卡在映射还是推送 +3. 接口卡在未发布、鉴权,还是签名/报文字段 + +完成后到「进度」Tab 勾总验收项(安排在工作日)。 diff --git a/src/views/kb/training/index.vue b/src/views/kb/training/index.vue new file mode 100644 index 0000000..62cea05 --- /dev/null +++ b/src/views/kb/training/index.vue @@ -0,0 +1,129 @@ + + + + + diff --git a/src/views/kb/training/useTrainingProgress.ts b/src/views/kb/training/useTrainingProgress.ts new file mode 100644 index 0000000..537f9a4 --- /dev/null +++ b/src/views/kb/training/useTrainingProgress.ts @@ -0,0 +1,109 @@ +import { computed, ref, watch } from 'vue' +import { + CHECKLIST_ITEMS, + TRAINING_ROLES, + itemsForRole, + type TrainingRoleKey, +} from './checklist-items' + +const STORAGE_CHECKED = 'oms.kb.training.checked.v1' +const STORAGE_ROLE = 'oms.kb.training.role.v1' + +function readChecked(): Record { + try { + const raw = localStorage.getItem(STORAGE_CHECKED) + if (!raw) return {} + const parsed = JSON.parse(raw) as Record + return parsed && typeof parsed === 'object' ? parsed : {} + } catch { + return {} + } +} + +function readRole(): TrainingRoleKey { + try { + const raw = localStorage.getItem(STORAGE_ROLE) as TrainingRoleKey | null + if (raw && TRAINING_ROLES.some((r) => r.key === raw)) return raw + } catch { + // ignore + } + return 'all' +} + +const checkedMap = ref>(readChecked()) +const role = ref(readRole()) + +watch( + checkedMap, + (val) => { + try { + localStorage.setItem(STORAGE_CHECKED, JSON.stringify(val)) + } catch { + // ignore quota + } + }, + { deep: true }, +) + +watch(role, (val) => { + try { + localStorage.setItem(STORAGE_ROLE, val) + } catch { + // ignore + } +}) + +export function useTrainingProgress() { + const roleMeta = computed(() => TRAINING_ROLES.find((r) => r.key === role.value)!) + + const relevantItems = computed(() => itemsForRole(role.value)) + + const doneCount = computed( + () => relevantItems.value.filter((i) => checkedMap.value[i.id]).length, + ) + + const totalCount = computed(() => relevantItems.value.length) + + const percent = computed(() => + totalCount.value ? Math.round((doneCount.value / totalCount.value) * 100) : 0, + ) + + function isChecked(id: string) { + return Boolean(checkedMap.value[id]) + } + + function setChecked(id: string, value: boolean) { + checkedMap.value = { ...checkedMap.value, [id]: value } + } + + function toggle(id: string) { + setChecked(id, !isChecked(id)) + } + + function resetAll() { + checkedMap.value = {} + } + + function weekProgress(week: string) { + const items = relevantItems.value.filter((i) => i.week === week) + const done = items.filter((i) => checkedMap.value[i.id]).length + return { done, total: items.length } + } + + return { + role, + roleMeta, + roles: TRAINING_ROLES, + checkedMap, + relevantItems, + allItems: CHECKLIST_ITEMS, + doneCount, + totalCount, + percent, + isChecked, + setChecked, + toggle, + resetAll, + weekProgress, + } +} diff --git a/src/views/operation/bagManage/index.vue b/src/views/operation/bagManage/index.vue new file mode 100644 index 0000000..2afe374 --- /dev/null +++ b/src/views/operation/bagManage/index.vue @@ -0,0 +1,684 @@ + + + + + diff --git a/src/views/operation/bagPack/index.vue b/src/views/operation/bagPack/index.vue new file mode 100644 index 0000000..17dcf8e --- /dev/null +++ b/src/views/operation/bagPack/index.vue @@ -0,0 +1,704 @@ + + + + + diff --git a/src/views/operation/masterBill/index.vue b/src/views/operation/masterBill/index.vue new file mode 100644 index 0000000..9d2d4c6 --- /dev/null +++ b/src/views/operation/masterBill/index.vue @@ -0,0 +1,732 @@ + + + + + diff --git a/src/views/operation/masterBoard/index.vue b/src/views/operation/masterBoard/index.vue new file mode 100644 index 0000000..166144a --- /dev/null +++ b/src/views/operation/masterBoard/index.vue @@ -0,0 +1,597 @@ + + + + + diff --git a/src/views/operation/outboundScan/index.vue b/src/views/operation/outboundScan/index.vue index 85eee2b..a871c93 100644 --- a/src/views/operation/outboundScan/index.vue +++ b/src/views/operation/outboundScan/index.vue @@ -3,11 +3,19 @@
+
+ + 小包出库 + 大包出库 + +
-

{{ $t('operation.outbound.form.hint.supportedTypes') }}

+

+ {{ + scanMode === 'bag' + ? '大包须已封袋;按袋内入库/预报件重尺批量出库。小包也可不装袋单独出库。' + : $t('operation.outbound.form.hint.supportedTypes') + }} +

@@ -51,7 +65,17 @@ {{ feedbackMessage }}

-
+
+
+
+
{{ formData.waybillNumber || '-' }}
+
+ 模式:大包出库(无需再填件重尺) +
+
+
+
+
{{ formData.waybillNumber || '-' }}
@@ -153,6 +177,7 @@ import { useTableContainerHeight } from '@/composables/useTableContainerHeight' import { useOperationScanFocus } from '@/composables/useOperationScanFocus' import { useOperationScanFeedback } from '@/composables/useOperationScanFeedback' import { outboundCreate, outboundRecentList, outboundOrderLookup } from '@/api/operation' +import { outboundByBag } from '@/api/operation/shipContainer' import { withServerFilterColumns } from '@/utils/headerFilterAdapter' const { t } = useI18n() @@ -171,6 +196,7 @@ const { defineOptions({ name: 'OutboundScan' }) +const scanMode = ref<'parcel' | 'bag'>('parcel') const submitting = ref(false) const lookingUp = ref(false) const listLoading = ref(false) @@ -329,6 +355,10 @@ async function ensureOrderLookup(): Promise { } async function onScanEnter() { + if (scanMode.value === 'bag') { + await handleSubmit() + return + } const ok = await ensureOrderLookup() if (!ok) return if (hasMetrics()) { @@ -340,10 +370,28 @@ async function onScanEnter() { async function handleSubmit() { if (!formData.waybillNumber?.trim()) { - showWarning(t('operation.outbound.message.waybillNumberRequired')) + showWarning( + scanMode.value === 'bag' ? '请输入大包号' : t('operation.outbound.message.waybillNumberRequired'), + ) maybeRefocusScan() return } + if (scanMode.value === 'bag') { + submitting.value = true + try { + const result = await outboundByBag(formData.waybillNumber.trim()) + showSuccess(`大包出库成功,共 ${result.successCount} 票`) + handleReset(false) + await loadRecent() + maybeRefocusScan() + } catch (e: any) { + showError(e?.message || t('operation.outbound.message.outboundFailed')) + maybeRefocusScan() + } finally { + submitting.value = false + } + return + } const ok = await ensureOrderLookup() if (!ok) return if (!hasMetrics()) { diff --git a/src/views/operation/printLabel/index.vue b/src/views/operation/printLabel/index.vue index 9b1c1bb..2a7a080 100644 --- a/src/views/operation/printLabel/index.vue +++ b/src/views/operation/printLabel/index.vue @@ -643,6 +643,9 @@ async function loadRecent() { inbound: t('operation.printLabel.labelTemplate.inbound'), outbound: t('operation.printLabel.labelTemplate.outbound'), sku: t('operation.printLabel.labelTemplate.sku'), + box: t('operation.printLabel.labelTemplate.box'), + shipBag: t('operation.printLabel.labelTemplate.shipBag'), + shipMaster: t('operation.printLabel.labelTemplate.shipMaster'), } recentOrders.value = (items || []).map((row: any, idx: number) => { const ok = row.printSuccess === 1 || row.printSuccess === true diff --git a/src/views/operation/styles/ops-scan-page.less b/src/views/operation/styles/ops-scan-page.less index d428364..42bbe66 100644 --- a/src/views/operation/styles/ops-scan-page.less +++ b/src/views/operation/styles/ops-scan-page.less @@ -127,6 +127,81 @@ flex-wrap: wrap; } +.ops-scan__row--setup { + flex-wrap: wrap; + gap: 8px; +} + +/* 扫描模式 / 袋型分段:灰底白块选中,高度与 32px 工具栏按钮一致 */ +.ops-mode.arco-radio-group-button, +.ops-mode { + flex-shrink: 0; + background: var(--color-fill-2) !important; + border: 1px solid var(--color-border-2); + border-radius: 4px; + padding: 2px; + gap: 0; + + :deep(.arco-radio-button) { + margin: 0 !important; + padding: 0 !important; + border: none !important; + background: transparent !important; + box-shadow: none !important; + } + + :deep(.arco-radio-button .arco-radio-button-content) { + display: inline-flex; + align-items: center; + justify-content: center; + min-width: 64px; + height: 28px; + padding: 0 12px; + border-radius: 3px; + font-size: 13px; + line-height: 28px; + color: var(--color-text-2); + background: transparent; + box-shadow: none; + transition: background 0.15s, color 0.15s; + } + + :deep(.arco-radio-button.arco-radio-checked .arco-radio-button-content) { + color: var(--app-primary-color); + font-weight: 600; + background: var(--app-card-bg); + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06); + } + + :deep(.arco-radio-button:not(.arco-radio-checked):hover .arco-radio-button-content) { + color: var(--app-primary-color); + } + + :deep(.arco-radio-disabled .arco-radio-button-content) { + color: var(--color-text-4); + cursor: not-allowed; + } +} + +.ops-setup-btn { + height: 32px !important; + padding: 0 12px !important; + border-radius: 4px !important; + font-size: 14px; + flex-shrink: 0; +} + +.ops-resume-input { + flex: 1 1 200px; + min-width: 180px; + max-width: 280px; + + :deep(.arco-input-wrapper) { + height: 32px; + border-radius: 4px; + } +} + .ops-scan-input { width: 100%; diff --git a/src/views/order/orderColumnLabelsZh.ts b/src/views/order/orderColumnLabelsZh.ts index 851d24c..63b30dc 100644 --- a/src/views/order/orderColumnLabelsZh.ts +++ b/src/views/order/orderColumnLabelsZh.ts @@ -26,6 +26,8 @@ export const ORDER_COLUMN_LABEL_ZH: Record = { clientNo: '客户单号', trackNo: '跟踪号', serviceNo: '运单号', + shipBagNo: '大包号', + shipMasterNo: '内部主单号', productCode: '产品编码', productName: '销售产品', maxTimeliness: '最大时效(天)', diff --git a/src/views/order/waybillManage/columnConfig.ts b/src/views/order/waybillManage/columnConfig.ts index 3670f38..1803898 100644 --- a/src/views/order/waybillManage/columnConfig.ts +++ b/src/views/order/waybillManage/columnConfig.ts @@ -36,6 +36,8 @@ export const WAYBILL_MANAGE_COLUMN_CATALOG: OrderListColumnDef[] = [ { key: 'clientNo', labelKey: M('customerOrderNo'), width: 150 }, { key: 'trackNo', labelKey: M('trackingNo'), width: 160 }, { key: 'serviceNo', labelKey: M('waybillNo'), width: 200 }, + { key: 'shipBagNo', labelKey: L('shipBagNo'), width: 150 }, + { key: 'shipMasterNo', labelKey: L('shipMasterNo'), width: 150 }, { key: 'downstreamServiceNo', labelKey: M('downstreamServiceNo'), width: 180 }, { key: 'productCode', labelKey: L('productCode'), width: 110 }, { key: 'productName', labelKey: M('shippingMethod'), width: 120 }, diff --git a/src/views/order/waybillManage/index.vue b/src/views/order/waybillManage/index.vue index a1b039c..25e3d8c 100644 --- a/src/views/order/waybillManage/index.vue +++ b/src/views/order/waybillManage/index.vue @@ -333,6 +333,8 @@ serviceNo: serviceNo ?? '', clientNo: clientNo ?? '', trackNo: trackNo ?? '', + shipBagNo: pick(raw, 'shipBagNo', 'ShipBagNo') ?? '', + shipMasterNo: pick(raw, 'shipMasterNo', 'ShipMasterNo') ?? '', waybillNo, customerOrderNo: clientNo ?? '', trackingNo: trackNo ?? '', diff --git a/src/views/user/profile/ProfilePanel.vue b/src/views/user/profile/ProfilePanel.vue index ff4b4d1..8df2592 100644 --- a/src/views/user/profile/ProfilePanel.vue +++ b/src/views/user/profile/ProfilePanel.vue @@ -388,7 +388,8 @@ const contactRows = computed(() => [ }, ]) -function validateConfirmPassword(_rule: unknown, value: string, callback: (error?: string) => void) { +// Arco Form:validator(value, callback) +function validateConfirmPassword(value: string, callback: (error?: string) => void) { if (value !== pwdForm.newPassword) { callback(t('profile.passwordMismatch')) } else { diff --git a/vite.config.ts b/vite.config.ts index f1c8f73..d97a198 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -197,7 +197,7 @@ export default defineConfig(({ mode }) => { secure: false, bypass(req) { const path = req.url?.split('?')[0] ?? ''; - const kbSpaPages = ['/kb/category', '/kb/article']; + const kbSpaPages = ['/kb/category', '/kb/article', '/kb/training']; if (kbSpaPages.some((p) => path === p || path.startsWith(`${p}/`))) { return '/index.html'; } @@ -363,6 +363,10 @@ export default defineConfig(({ mode }) => { const operationSpaPrefixes = [ '/operation/inboundScan', '/operation/outboundScan', + '/operation/bagPack', + '/operation/bagManage', + '/operation/masterBoard', + '/operation/masterBill', '/operation/printLabel', '/operation/parcelArrival', '/operation/fulfillPack', @@ -669,6 +673,10 @@ export default defineConfig(({ mode }) => { // Operation 相关前端路由 '/operation/inboundScan', '/operation/outboundScan', + '/operation/bagPack', + '/operation/bagManage', + '/operation/masterBoard', + '/operation/masterBill', '/operation/printLabel', '/operation/parcelArrival', '/operation/fulfillPack', @@ -692,6 +700,7 @@ export default defineConfig(({ mode }) => { // Knowledge 前端路由(API 为 /kb/admin/*、/kb/portal/*) '/kb/category', '/kb/article', + '/kb/training', // Finance 相关前端路由 '/finance/rechargeRecord', '/finance/accountFlow',