This commit is contained in:
徐星 2026-03-31 16:30:42 +08:00
parent ddb4540968
commit 9fcd3cc350
7 changed files with 89 additions and 300 deletions

View File

@ -41,7 +41,7 @@ const menuGroups = [
{ title: '授权', items: [{ path: '/licenses', label: '授权管理' }, { path: '/activation', label: '激活管理' }] },
{ title: '固件', items: [{ path: '/firmware', label: '固件库' }, { path: '/firmware-upgrade', label: '升级任务' }] },
{ title: '配置', items: [{ path: '/config-files', label: '配置管理' }] },
{ title: '校准', items: [{ path: '/calibration', label: '校准记录' }] },
{ title: '维修', items: [{ path: '/repair-orders', label: '维修工单' }, { path: '/repair-stats', label: '维修统计' }, { path: '/scrap', label: '报废回收' }] },
{ title: '校准', items: [{ path: '/calibration', label: '校准管理' }] },
{ title: '维修', items: [{ path: '/repair', label: '维修工单' }, { path: '/repair/stats', label: '维修统计' }, { path: '/scrap', label: '报废回收' }] },
]
</script>

View File

@ -12,7 +12,7 @@ interface CalibrationRecord {
const calibrationRecords: CalibrationRecord[] = [
{
boardSn: 'AC20240308001',
boardSn: 'RX20240308001',
deviceSn: 'GD30-2025-000001',
calibrationDate: '2024-03-01',
calibrator: '王工程师',
@ -20,16 +20,16 @@ const calibrationRecords: CalibrationRecord[] = [
status: '合格',
},
{
boardSn: 'AC20240308002',
deviceSn: 'GT20-2025-000045',
boardSn: 'RX20240308002',
deviceSn: 'GD20-2025-000045',
calibrationDate: '2024-03-05',
calibrator: '李工程师',
expiryDate: '2025-03-05',
status: '合格',
},
{
boardSn: 'AC20240308003',
deviceSn: 'GTXD-2025-000023',
boardSn: 'RX20240308003',
deviceSn: 'GD10-2025-000023',
calibrationDate: '2024-03-08',
calibrator: '张工程师',
expiryDate: '2025-03-08',
@ -65,7 +65,7 @@ const getStatusStyle = (status: CalibrationRecord['status']) => {
<div class="p-6">
<!-- Page Header -->
<div class="mb-6">
<h2 class="text-2xl font-semibold mb-1">采集板校准记录</h2>
<h2 class="text-2xl font-semibold mb-1">校准管理</h2>
<p class="text-sm" style="color: rgba(0, 0, 0, 0.45)">管理采集板校准数据</p>
</div>
@ -186,7 +186,6 @@ const getStatusStyle = (status: CalibrationRecord['status']) => {
<div class="flex items-center gap-3">
<button class="text-sm" style="color: #1890FF">详情</button>
<button class="text-sm" style="color: #1890FF">下载报告</button>
<button class="text-sm" style="color: #1890FF">重新校准</button>
</div>
</td>
</tr>

View File

@ -71,7 +71,7 @@
<!-- Pending Tasks -->
<div class="bg-white p-6 rounded-lg" style="box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05)">
<h3 class="text-lg font-semibold mb-6">待处理任务</h3>
<h3 class="text-lg font-semibold mb-6">通知</h3>
<div class="grid grid-cols-2 gap-6">
<div v-for="(group, groupIndex) in taskGroups" :key="groupIndex">
<div class="flex items-center justify-between mb-4">

View File

@ -131,10 +131,6 @@
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">授权文件</div>
<button class="text-sm" style="color: #1890FF">auth_gd30_v2.3.lic</button>
</div>
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">操作</div>
<button class="text-sm" style="color: #1890FF">续期</button>
</div>
</div>
</div>
@ -162,13 +158,6 @@
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">配置同步时间</div>
<div>2024-03-01 10:35</div>
</div>
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">操作</div>
<div class="flex items-center gap-3">
<button class="text-sm" style="color: #1890FF">推送固件</button>
<button class="text-sm" style="color: #1890FF">下发配置</button>
</div>
</div>
</div>
</div>

View File

@ -94,7 +94,7 @@ const checklistData = ref<ChecklistData>({
{ id: 4, text: '系统启动正常', type: 'bool', required: true, note: '' },
{ id: 5, text: '整体功能测试', type: 'bool', required: true, note: '' },
],
GTXD: [
GM10: [
{ id: 1, text: '主板SN扫码绑定主机', type: 'text', required: true, note: '唯一SN' },
{ id: 2, text: '传感器模块连接', type: 'bool', required: true, note: '' },
{ id: 3, text: '接口板安装', type: 'bool', required: true, note: '' },
@ -153,7 +153,7 @@ const boardVersionData = [
status: 'active',
},
{
boardType: '测控板',
boardType: '发射板',
requiredVersion: 'v1.5.x',
validationRule: '版本号前缀必须为 v1.5',
status: 'active',

View File

@ -1,17 +1,20 @@
<script setup lang="ts">
import { ArrowLeft, Clock, AlertTriangle, ArrowRight, Trash2 } from 'lucide-vue-next'
import { useRouter } from 'vue-router'
import { ArrowLeft } from 'lucide-vue-next'
import { useRouter, useRoute } from 'vue-router'
import { ref } from 'vue'
const router = useRouter()
const regenerateAuth = ref(false)
const route = useRoute()
const orderId = route.params.orderId || 'WO-2024-0001'
const regenerateAuth = ref(true)
const pushFirmware = ref(false)
const processingTimeline = [
{ time: '2024-03-08 09:00', operator: '张工程师', action: '创建工单', description: '客户报修,设备无法开机' },
{ time: '2024-03-08 10:30', operator: '李工程师', action: '故障诊断', description: '初步诊断为主控板故障' },
{ time: '2024-03-08 14:00', operator: '王工程师', action: '板卡更换', description: '更换主控板,测试正常' },
{ time: '2024-03-08 16:00', operator: '李工程师', action: '测试完成', description: '功能测试通过,等待客户确认' },
const processRecords = [
{ time: '2024-02-25 14:35:00', person: '李工', action: '接单', detail: '开始处理' },
{ time: '2024-02-25 15:00:00', person: '李工', action: '确认板卡故障,准备更换' },
{ time: '2024-02-26 09:20:00', person: '李工', action: '更换板卡 AC-2024-0001→AC-2024-0003' },
{ time: '2024-02-26 10:00:00', person: '李工', action: '板卡更换完成,设备恢复正常' },
]
</script>
@ -19,300 +22,96 @@ const processingTimeline = [
<div class="p-6">
<!-- Page Header -->
<div class="mb-6">
<div class="flex items-center gap-4 mb-2">
<button
@click="router.go(-1)"
class="p-2 rounded hover:bg-gray-100 transition-colors"
style="color: rgba(0, 0, 0, 0.65)"
>
<div class="flex items-center gap-4">
<button @click="router.go(-1)" class="p-2 rounded hover:bg-gray-100 transition-colors" style="color: rgba(0,0,0,0.65)">
<ArrowLeft :size="20" />
</button>
<h2 class="text-2xl font-semibold">维修工单详情</h2>
<span class="text-xl" style="color: rgba(0, 0, 0, 0.45)">WO-2024-0001</span>
<span class="text-base" style="color: rgba(0,0,0,0.45)">{{ orderId }}</span>
</div>
</div>
<!-- Work Order Info Card -->
<div class="bg-white p-6 rounded-lg mb-6" style="box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05)">
<h3 class="text-lg font-semibold mb-6">工单信息</h3>
<div class="grid grid-cols-3 gap-x-12 gap-y-6">
<!-- 工单信息 -->
<div class="bg-white p-6 rounded-lg mb-6" style="box-shadow: 0 1px 2px rgba(0,0,0,0.05)">
<h3 class="text-base font-semibold mb-4">工单信息</h3>
<div class="space-y-2 text-sm" style="color: rgba(0,0,0,0.65)">
<div>工单号{{ orderId }}</div>
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">工单ID</div>
<div>WO-2024-0001</div>
</div>
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">工单状态</div>
<span
class="inline-block px-2 py-1 rounded text-xs"
style="background-color: #E6F7FF; color: #1890FF; border: 1px solid #91D5FF"
>
处理中
</span>
</div>
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">优先级</div>
<span
class="inline-block px-2 py-1 rounded text-xs"
style="background-color: #FFF1F0; color: #FF4D4F; border: 1px solid #FFCCC7"
>
</span>
</div>
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">创建时间</div>
<div>2024-03-08 09:00</div>
</div>
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">负责人</div>
<div>李工程师</div>
</div>
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">预计完成时间</div>
<div>2024-03-09 18:00</div>
状态
<span class="px-2 py-0.5 rounded text-xs" style="background-color: #E6F7FF; color: #1890FF; border: 1px solid #91D5FF">🔧 处理中</span>
</div>
<div>优先级<span style="color: #FF4D4F"></span></div>
<div>创建时间2024-02-25 14:20:00</div>
<div>维修人员李工</div>
<div>预计修复2024-02-28</div>
</div>
</div>
<!-- Device Info Card -->
<div class="bg-white p-6 rounded-lg mb-6" style="box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05)">
<h3 class="text-lg font-semibold mb-6">设备信息</h3>
<div class="grid grid-cols-3 gap-x-12 gap-y-6">
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">设备SN号</div>
<div>GD30-2025-000001</div>
</div>
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">设备型号</div>
<div>GD30 地质探测仪</div>
</div>
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">固件版本</div>
<div>v2.3.5</div>
</div>
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">客户名称</div>
<div>北京地质研究院</div>
</div>
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">联系方式</div>
<div>010-12345678</div>
</div>
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">购买日期</div>
<div>2025-02-01</div>
</div>
</div>
</div>
<!-- Fault Info Card -->
<div class="bg-white p-6 rounded-lg mb-6" style="box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05)">
<h3 class="text-lg font-semibold mb-6">故障信息</h3>
<div class="grid grid-cols-2 gap-x-12 gap-y-6">
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">故障类型</div>
<div>硬件故障</div>
</div>
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">故障症状</div>
<div>设备无法开机指示灯不亮</div>
</div>
<div class="col-span-2">
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">故障描述</div>
<div class="p-3 rounded" style="background-color: #FAFAFA; color: rgba(0, 0, 0, 0.65)">
设备在野外作业时突然关机之后无法重新启动检查电源连接正常充电器工作正常初步判断为主控板损坏
</div>
</div>
<!-- 设备信息 -->
<div class="bg-white p-6 rounded-lg mb-6" style="box-shadow: 0 1px 2px rgba(0,0,0,0.05)">
<h3 class="text-base font-semibold mb-4">设备信息</h3>
<div class="space-y-2 text-sm" style="color: rgba(0,0,0,0.65)">
<div>设备SNGD30-2024-000056</div>
<div>设备型号GD30-Supreme</div>
<div>固件版本v3.2.0</div>
<div>硬件版本A1</div>
<div>客户XX地质勘探公司</div>
</div>
</div>
<!-- Processing Timeline Card -->
<div class="bg-white p-6 rounded-lg mb-6" style="box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05)">
<h3 class="text-lg font-semibold mb-6">处理记录</h3>
<div class="relative">
<!-- Timeline line -->
<div
class="absolute left-6 top-6 bottom-6 w-0.5"
style="background-color: #F0F0F0"
></div>
<div class="space-y-6">
<div v-for="(entry, index) in processingTimeline" :key="index" class="flex gap-4">
<div class="flex flex-col items-center flex-shrink-0">
<div
class="w-12 h-12 rounded-full flex items-center justify-center relative z-10"
style="background-color: #E6F7FF; border: 2px solid #1890FF"
>
<Clock :size="20" style="color: #1890FF" />
</div>
</div>
<div class="flex-1 pt-2">
<div class="flex items-center gap-3 mb-2">
<span class="font-medium">{{ entry.action }}</span>
<span class="text-sm" style="color: rgba(0, 0, 0, 0.45)">{{ entry.time }}</span>
<span class="text-sm" style="color: rgba(0, 0, 0, 0.45)">操作人{{ entry.operator }}</span>
</div>
<div class="text-sm" style="color: rgba(0, 0, 0, 0.65)">
{{ entry.description }}
</div>
</div>
</div>
</div>
<!-- 故障信息 -->
<div class="bg-white p-6 rounded-lg mb-6" style="box-shadow: 0 1px 2px rgba(0,0,0,0.05)">
<h3 class="text-base font-semibold mb-4">故障信息</h3>
<div class="space-y-2 text-sm" style="color: rgba(0,0,0,0.65)">
<div>故障类型综合故障</div>
<div>故障描述采集板AC-2024-0001无法正常工作引起数据采集异常</div>
<div>初判结果自动点采集板验证不通过无法获取测量数据</div>
</div>
</div>
<!-- Board Replacement Card -->
<div class="bg-white p-6 rounded-lg mb-6" style="box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05)">
<h3 class="text-lg font-semibold mb-6">板卡更换记录</h3>
<div class="p-4 rounded-lg" style="background-color: #FAFAFA">
<div class="flex items-center justify-between">
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">旧板卡</div>
<div class="font-medium">主控板 MB20231215001</div>
</div>
<ArrowRight :size="24" style="color: #1890FF" />
<div>
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">新板卡</div>
<div class="font-medium">主控板 MB20240308001</div>
</div>
<div class="text-right">
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">更换时间</div>
<div style="color: rgba(0, 0, 0, 0.65)">2024-03-08 14:00</div>
</div>
<div class="text-right">
<div class="text-sm mb-2" style="color: rgba(0, 0, 0, 0.45)">操作人</div>
<div>王工程师</div>
</div>
</div>
</div>
</div>
<!-- License Processing Card -->
<div class="bg-white p-6 rounded-lg mb-6" style="box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05)">
<h3 class="text-lg font-semibold mb-6">授权处理</h3>
<!-- 处理记录 -->
<div class="bg-white p-6 rounded-lg mb-6" style="box-shadow: 0 1px 2px rgba(0,0,0,0.05)">
<h3 class="text-base font-semibold mb-4">处理记录</h3>
<div class="space-y-3">
<label class="flex items-center gap-3 cursor-pointer">
<input
type="checkbox"
class="w-5 h-5 rounded"
style="accent-color: #1890FF"
v-model="regenerateAuth"
/>
<span>重新生成授权文件板卡更换后需重新绑定授权</span>
</label>
<label class="flex items-center gap-3 cursor-pointer">
<input
type="checkbox"
class="w-5 h-5 rounded"
style="accent-color: #1890FF"
v-model="pushFirmware"
/>
<span>推送适配固件如更换板卡型号不同需推送兼容固件</span>
</label>
<div v-for="(record, i) in processRecords" :key="i" class="text-sm" style="color: rgba(0,0,0,0.65)">
{{ record.time }} {{ record.person }} {{ record.action }}
</div>
</div>
<button class="text-sm mt-3" style="color: #1890FF">添加记录</button>
</div>
<!-- 板卡更换记录 -->
<div class="bg-white p-6 rounded-lg mb-6" style="box-shadow: 0 1px 2px rgba(0,0,0,0.05)">
<h3 class="text-base font-semibold mb-4">板卡更换记录</h3>
<div class="space-y-2 text-sm" style="color: rgba(0,0,0,0.65)">
<div>原板卡AC-2024-0001 硬件版本: A1 状态: 已换下</div>
<div>新板卡AC-2024-0003 硬件版本: A1 状态: 已安装</div>
<div>更换时间2024-02-26 09:20:00</div>
<div>更换人员李工</div>
</div>
</div>
<!-- Scrap Processing Card -->
<div class="bg-white p-6 rounded-lg mb-6" style="box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05)">
<h3 class="text-lg font-semibold mb-6">报废处理</h3>
<!-- Warning Banner -->
<div
class="mb-6 p-4 rounded-lg flex items-start gap-3"
style="background-color: #FFF1F0; border: 1px solid #FFCCC7"
>
<AlertTriangle :size="20" style="color: #FF4D4F; flex-shrink: 0; margin-top: 2px" />
<div>
<div class="font-medium" style="color: #CF1322">警告报废操作不可逆</div>
<div class="text-sm mt-1" style="color: #FF4D4F">
报废后设备将无法恢复使用请谨慎操作
</div>
</div>
</div>
<div class="grid grid-cols-2 gap-x-12 gap-y-6 mb-6">
<div>
<label class="block text-sm mb-2" style="color: rgba(0, 0, 0, 0.85)">
报废原因 <span style="color: #FF4D4F">*</span>
<!-- 授权处理 -->
<div class="bg-white p-6 rounded-lg mb-6" style="box-shadow: 0 1px 2px rgba(0,0,0,0.05)">
<h3 class="text-base font-semibold mb-4">授权处理</h3>
<p class="text-sm mb-4" style="color: rgba(0,0,0,0.65)">板卡更换后需要重新生成授权文件</p>
<div class="space-y-3">
<label class="flex items-center gap-2 cursor-pointer text-sm">
<input type="checkbox" v-model="regenerateAuth" class="w-4 h-4" style="accent-color: #1890FF" />
重新生成授权文件
</label>
<select
class="w-full px-3 py-2 border rounded"
style="border-color: #D9D9D9; background-color: #fff"
>
<option>请选择报废原因</option>
<option>主板损坏无法修复</option>
<option>多个核心部件损坏</option>
<option>维修成本超过设备价值</option>
<option>设备老化严重</option>
</select>
</div>
<div>
<label class="block text-sm mb-2" style="color: rgba(0, 0, 0, 0.85)">
残值评估 ()
<label class="flex items-center gap-2 cursor-pointer text-sm" style="color: rgba(0,0,0,0.65)">
<input type="checkbox" v-model="pushFirmware" class="w-4 h-4" style="accent-color: #1890FF" />
推送适配固件
</label>
<input
type="number"
class="w-full px-3 py-2 border rounded"
style="border-color: #D9D9D9"
placeholder="输入残值评估金额"
value="500"
/>
</div>
<div class="col-span-2">
<label class="block text-sm mb-2" style="color: rgba(0, 0, 0, 0.85)">
可回收物料
</label>
<div class="p-3 rounded border" style="border-color: #D9D9D9; background-color: #FAFAFA">
<div class="flex flex-wrap gap-2">
<span class="px-3 py-1 rounded text-sm" style="background-color: #E6F7FF; color: #1890FF">
采集板 AC20240308002
</span>
<span class="px-3 py-1 rounded text-sm" style="background-color: #E6F7FF; color: #1890FF">
测控板 CT20240308003
</span>
<span class="px-3 py-1 rounded text-sm" style="background-color: #E6F7FF; color: #1890FF">
电源模块 PS20240308004
</span>
</div>
</div>
</div>
</div>
<!-- Scrap Process Flow -->
<div
class="p-4 rounded-lg flex items-center gap-3"
style="background-color: #E6F7FF; border: 1px solid #91D5FF"
>
<div class="text-sm" style="color: #0050B3">
<span class="font-medium">报废流程</span>
申请报废 创建报废单 报废审批 物料回收 入库
</div>
</div>
<button class="mt-4 px-4 py-2 rounded text-white text-sm" style="background-color: #1890FF">处理授权</button>
</div>
<!-- Action Bar -->
<div
class="flex items-center justify-end gap-3 p-4 bg-white rounded-lg sticky bottom-0"
style="box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.05)"
>
<button
class="px-6 py-2 rounded"
style="border: 1px solid #D9D9D9; color: rgba(0, 0, 0, 0.85)"
>
取消
</button>
<button
class="px-6 py-2 rounded text-white"
style="background-color: #1890FF"
>
关闭工单
</button>
<button
class="px-6 py-2 rounded flex items-center gap-2"
style="border: 1px solid #FF4D4F; color: #FF4D4F"
>
<Trash2 :size="16" />
申请报废
</button>
<div class="flex items-center justify-center gap-4 p-4 bg-white rounded-lg sticky bottom-0" style="box-shadow: 0 -2px 8px rgba(0,0,0,0.05)">
<button class="px-6 py-2 rounded text-sm" style="border: 1px solid #D9D9D9; color: rgba(0,0,0,0.85)" @click="router.go(-1)">取消</button>
<button class="px-6 py-2 rounded text-white text-sm" style="background-color: #1890FF">关闭工单</button>
</div>
</div>
</template>

View File

@ -17,6 +17,8 @@ export const router = createRouter({
{ path: 'licenses/generate', component: () => import('./pages/LicenseGenerate.vue') },
{ path: 'activation', component: () => import('./pages/ActivationManagement.vue') },
{ path: 'calibration', component: () => import('./pages/CalibrationRecords.vue') },
{ path: 'repair', component: () => import('./pages/RepairOrders.vue') },
{ path: 'repair/stats', component: () => import('./pages/RepairStats.vue') },
{ path: 'repair/:orderId', component: () => import('./pages/RepairOrderDetail.vue') },
{ path: 'scrap', component: () => import('./pages/ScrapManagement.vue') },
{ path: 'firmware', component: () => import('./pages/FirmwareLibrary.vue') },