diff --git a/track-uniapp/src/pages/scan/components/TaskTreeNode.vue b/track-uniapp/src/pages/scan/components/TaskTreeNode.vue
index 13b33fb..d471bbe 100644
--- a/track-uniapp/src/pages/scan/components/TaskTreeNode.vue
+++ b/track-uniapp/src/pages/scan/components/TaskTreeNode.vue
@@ -4,7 +4,7 @@
-
+
⚠返工
@@ -15,39 +15,7 @@
负责人: {{ task.assignee_id }}
驳回: {{ task.reject_reason }}
-
-
-
-
-
- 📋
- 查看全部记录 ({{ task.records.length }})
- ›
-
-
-
-
- {{ formatTime(task.records[0].created_at) }}
-
- ✏️
- 🗑️
-
-
-
-
-
-
-
-
-
{{ statusLabel(task.status) }}
@@ -64,7 +32,7 @@
@tap.stop="$emit('action', { task, type: 'record' })">📝 记录/拍照
-
+
$emit('viewRecords', t)"
/>
+
+
+
+
+
+ 📋
+ 查看全部记录 ({{ task.records.length }})
+ ›
+
+
+
+
+ {{ formatTime(task.records[0].created_at) }}
+
+ ✏️
+ 🗑️
+
+
+
+
+
+
+
+
diff --git a/track-uniapp/src/pages/scan/detail.vue b/track-uniapp/src/pages/scan/detail.vue
index 5cb3f4c..79fb6a7 100644
--- a/track-uniapp/src/pages/scan/detail.vue
+++ b/track-uniapp/src/pages/scan/detail.vue
@@ -1,5 +1,5 @@
-
+
加载中...
{{ error }}
@@ -56,13 +56,13 @@
-
-
+
+
+
-
📋
@@ -86,6 +86,24 @@
/>
+
+
+
+
+
@@ -335,6 +353,21 @@ export default {
const u = this.userOptions.find(u => u.id === this.transferForm.selectedUserId);
return u ? u.name : "";
},
+ activeTask() {
+ // 查找树中第一个 WIP 或 PENDING 任务作为底部 Footer 的操作目标
+ const findActive = (tasks) => {
+ if (!tasks) return null;
+ for (const t of tasks) {
+ if (t.status === 'WIP' || t.status === 'PENDING') return t;
+ if (t.child_tasks && t.child_tasks.length) {
+ const found = findActive(t.child_tasks);
+ if (found) return found;
+ }
+ }
+ return null;
+ };
+ return this.product ? findActive(this.product.task_tree) : null;
+ },
},
onLoad(options) {
this.loadUsers();
@@ -661,7 +694,7 @@ export default {