From 45c2ea6e63a823bc0337835ef3c6e90ba0d84b0b Mon Sep 17 00:00:00 2001 From: sheng <905537351@qq.com> Date: Mon, 22 Jun 2026 14:58:04 +0800 Subject: [PATCH] feat: migrate tray management module - add V2 tray management page for planning production monitoring - add tray management API, route, and i18n entries - update migration task list status for tray management --- docs/迁移任务列表.md | 6 +- .../planning-production/tray-management.js | 67 +++ src/locales/en.json | 42 ++ src/locales/zh-chs.json | 42 ++ src/router/modules/planning-production.js | 6 + .../tray-management/index.vue | 562 ++++++++++++++++++ 6 files changed, 722 insertions(+), 3 deletions(-) create mode 100644 src/api/planning-production/tray-management.js create mode 100644 src/views/planning-production/production-monitoring/tray-management/index.vue diff --git a/docs/迁移任务列表.md b/docs/迁移任务列表.md index d57ef754..f4987375 100644 --- a/docs/迁移任务列表.md +++ b/docs/迁移任务列表.md @@ -3,8 +3,8 @@ > 根据 `后台Webman界面截图对照表.md` 生成。状态以当前 V2 项目中已落地的页面目录为准。 - 总功能数:79 -- 已迁移:20 -- 未迁移:59 +- 已迁移:21 +- 未迁移:58 | 状态 | 一级模块 | 二级模块 | 三级模块 | 功能说明 | V2 目标路径 | |:---:|---|---|---|---|---| @@ -49,7 +49,7 @@ | ⬜ | 计划与生产 (Planning & Production) | 预警中心 (Alert Center) | 预警中心 (Alert Center) | 预警中心 | 待确认 | | ⬜ | 计划与生产 (Planning & Production) | 生产监控 (Production Monitoring) | 物料监控 (Material Monitoring) | 物料监控 | 待确认 | | ⬜ | 计划与生产 (Planning & Production) | 生产监控 (Production Monitoring) | 电池复投管理 (Rework Management) | 返工管理 | 待确认 | -| ⬜ | 计划与生产 (Planning & Production) | 生产监控 (Production Monitoring) | 托盘管理 (Tray Management) | 托盘管理 | 待确认 | +| ✅ | 计划与生产 (Planning & Production) | 生产监控 (Production Monitoring) | 托盘管理 (Tray Management) | 托盘管理 | `src/views/planning-production/production-monitoring/tray-management/` | | ⬜ | 计划与生产 (Planning & Production) | 生产监控 (Production Monitoring) | 托盘登录 (Tray Registration) | 托盘登记 | 待确认 | | ⬜ | 计划与生产 (Planning & Production) | 生产监控 (Production Monitoring) | 设备监控 (Equipment Monitoring) | 设备监控 | 待确认 | | ⬜ | 计划与生产 (Planning & Production) | 生产监控 (Production Monitoring) | 电池工序管理 (Process Execution) | 工序管理 | 待确认 | diff --git a/src/api/planning-production/tray-management.js b/src/api/planning-production/tray-management.js new file mode 100644 index 00000000..edd3a6ef --- /dev/null +++ b/src/api/planning-production/tray-management.js @@ -0,0 +1,67 @@ +import { request } from '@/api/_service' + +const BASE = 'planning_production/produce/tray_manage/' + +function apiParams (method, data = {}) { + return { + method, + platform: 'background', + ...data + } +} + +export function getTrayManageInfo (data) { + return request({ + url: BASE + 'list', + method: 'get', + params: apiParams('planning_production_produce_traymanage_list', data) + }) +} + +export function changeFlowProcess (data) { + return request({ + url: BASE + 'change', + method: 'put', + params: apiParams('planning_production_produce_traymanage_change', data) + }) +} + +export function inactiveTray (data) { + return request({ + url: BASE + 'inactive', + method: 'put', + params: apiParams('planning_production_produce_traymanage_inactive', data) + }) +} + +export function trayNg (data) { + return request({ + url: BASE + 'ng', + method: 'put', + params: apiParams('planning_production_produce_traymanage_ng', data) + }) +} + +export function rangeNgAndRC (data) { + return request({ + url: BASE + 'ngrc', + method: 'put', + params: apiParams('planning_production_produce_traymanage_ngrc', data) + }) +} + +export function rangeFx (data) { + return request({ + url: BASE + 'fenx', + method: 'put', + params: apiParams('planning_production_produce_traymanage_fenx', data) + }) +} + +export function cleanTrayNg (data) { + return request({ + url: BASE + 'clean', + method: 'put', + params: apiParams('planning_production_produce_traymanage_clean', data) + }) +} diff --git a/src/locales/en.json b/src/locales/en.json index aa33e79d..89a99812 100644 --- a/src/locales/en.json +++ b/src/locales/en.json @@ -922,6 +922,48 @@ "incomplete": "Incomplete", "batch_defect_detail": "Batch Defect Report Details" } + }, + "production_monitoring": { + "tray_management": { + "tray_code": "Tray Code", + "tray_code_placeholder": "Enter tray code", + "enter_tray_to_query": "Enter tray code to query", + "query": "Search", + "reset": "Reset", + "current_process": "Current Process", + "start_time": "Start Time", + "end_time": "End Time", + "device_code": "Device Code", + "batch": "Batch", + "lot": "LOT", + "input_battery_count": "Input Battery Count", + "input_time": "Input Time", + "previous_process": "Previous Process", + "status": "Status", + "activated": "Activated", + "not_activated": "Not Activated", + "tray_ng": "Full Tray NG", + "prompt": "Notice", + "confirm": "Confirm", + "cancel": "Cancel", + "stop_tray": "Stop Tray", + "capacity_sorting": "Capacity Sorting", + "clear_tray_ng": "Clear Tray NG", + "confirm_stop_tray": "Stop this tray? It and its batteries will be deactivated. Proceed?", + "confirm_full_tray_ng": "Mark entire tray as NG?", + "full_tray_ng_success": "Tray marked as NG successfully", + "confirm_clear_tray_ng": "Clear tray NG status?", + "confirm_capacity_resort": "Re-sort capacity?", + "cannot_adjust_to_initial_process": "Cannot revert to initial process", + "confirm_adjust_tray_process": "Adjust tray process?", + "adjust_process_success": "Process adjusted successfully", + "operation_success": "Operation successful", + "operation_cancelled": "Operation canceled", + "battery_id": "Battery Barcode", + "grade": "Grade", + "activation_status": "Activation Status", + "channel_battery_info": "Channel {index} Battery Info" + } } } }, diff --git a/src/locales/zh-chs.json b/src/locales/zh-chs.json index e7b9a2a2..3234e47d 100644 --- a/src/locales/zh-chs.json +++ b/src/locales/zh-chs.json @@ -922,6 +922,48 @@ "incomplete": "未完成", "batch_defect_detail": "批次不良报表详情" } + }, + "production_monitoring": { + "tray_management": { + "tray_code": "托盘编码", + "tray_code_placeholder": "输入托盘编码", + "enter_tray_to_query": "请输入托盘编码后查询", + "query": "查询", + "reset": "重置", + "current_process": "当前工序", + "start_time": "开始时间", + "end_time": "结束时间", + "device_code": "设备编码", + "batch": "批次", + "lot": "LOT", + "input_battery_count": "投入电池", + "input_time": "投入时间", + "previous_process": "上一工序", + "status": "状态", + "activated": "激活", + "not_activated": "未激活", + "tray_ng": "整盘NG", + "prompt": "提示", + "confirm": "确定", + "cancel": "取消", + "stop_tray": "停止托盘", + "capacity_sorting": "容量分选", + "clear_tray_ng": "清除托盘NG", + "confirm_stop_tray": "是否要停止托盘?停止后托盘和其中的电池都会取消激活!请注意!", + "confirm_full_tray_ng": "是否进行整盘NG操作?", + "full_tray_ng_success": "整盘NG操作成功", + "confirm_clear_tray_ng": "是否进行清除托盘NG操作?", + "confirm_capacity_resort": "是否要进行容量再分选操作?", + "cannot_adjust_to_initial_process": "无法调整到初始工序", + "confirm_adjust_tray_process": "是否将该托盘调整工序?", + "adjust_process_success": "调整工序成功", + "operation_success": "操作成功!", + "operation_cancelled": "已取消操作", + "battery_id": "电池条码", + "grade": "等级", + "activation_status": "激活状态", + "channel_battery_info": "通道 {index} 电池信息" + } } } }, diff --git a/src/router/modules/planning-production.js b/src/router/modules/planning-production.js index 9aeb04b5..44cf05c0 100644 --- a/src/router/modules/planning-production.js +++ b/src/router/modules/planning-production.js @@ -31,6 +31,12 @@ export default { name: `${pre}production_batch_management-bad`, meta: { ...meta, cache: true, title: '生产批次不良报表' }, component: _import('planning-production/batch-management/batch-defect-report') + }, + { + path: 'produce/monitor/tray_manage', + name: `${pre}monitor-tray_manage`, + meta: { ...meta, cache: true, title: '托盘管理' }, + component: _import('planning-production/production-monitoring/tray-management') } ])('planning_production-') } diff --git a/src/views/planning-production/production-monitoring/tray-management/index.vue b/src/views/planning-production/production-monitoring/tray-management/index.vue new file mode 100644 index 00000000..e06c4560 --- /dev/null +++ b/src/views/planning-production/production-monitoring/tray-management/index.vue @@ -0,0 +1,562 @@ + + + + + + + + + + + {{ $t(key('query')) }} + + + {{ $t(key('reset')) }} + + + + + + + + + + + + + + + {{ item.flow_process_code || item.name }} + + [{{ $t(key('current_process')) }}] + + + {{ $t(key('start_time')) }}: {{ item.beginTime }} + {{ $t(key('end_time')) }}: {{ item.endTime }} + {{ $t(key('device_code')) }}: {{ item.device_code }} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + {{ $t(key('stop_tray')) }} + + + {{ $t(key('tray_ng')) }} + + + {{ $t(key('capacity_sorting')) }} + + + {{ $t(key('clear_tray_ng')) }} + + + + + + + + {{ item }} + + + + + + {{ rowIndex + 1 }} + + + {{ idx }} + + {{ batteryInfo[idx - 1].classname }} + + + + {{ rowIndex + 1 }} + + + + + + {{ item }} + + + + + + + + + + + + + {{ selectedBattery.battery_id }} + + + {{ selectedBattery.classname }} + + + {{ Number(selectedBattery.active) === 1 ? $t(key('activated')) : $t(key('not_activated')) }} + + + + {{ $t(key('cancel')) }} + + + + + + + +
+ {{ item.flow_process_code || item.name }} + + [{{ $t(key('current_process')) }}] + +
{{ $t(key('start_time')) }}: {{ item.beginTime }}
{{ $t(key('end_time')) }}: {{ item.endTime }}
{{ $t(key('device_code')) }}: {{ item.device_code }}