From 3533b11c19b628e45f26d25bedd7c82e0aa2037a Mon Sep 17 00:00:00 2001
From: zhouwx <1175765986@qq.com>
Date: Fri, 14 Mar 2025 17:24:24 +0800
Subject: [PATCH] 接口对接
---
src/views/signProject/components/record.vue | 105 ++++++++++++++++++++++++++++++++--------------------
1 files changed, 65 insertions(+), 40 deletions(-)
diff --git a/src/views/signProject/components/record.vue b/src/views/signProject/components/record.vue
index 0ee91a6..d15ccf5 100644
--- a/src/views/signProject/components/record.vue
+++ b/src/views/signProject/components/record.vue
@@ -9,22 +9,32 @@
:close-on-click-modal="false"
>
<el-timeline style="max-width: 600px">
+ <el-timeline-item size="large" color="#0bbd87" style="font-size: 16px">
+ <div>创建人:{{state.creatContent}}</div>
+ </el-timeline-item>
+ <el-timeline-item style="font-size: 16px" :color="state.firstPeopleState == 1 ? '#0bbd87' : '#B4B4B4' " size="large">
+ <div>
+ 最初签署人:{{state.firstPeopleContent}}
+ <span v-if="state.firstPeopleState == 1" style="color: #1ab394;font-size: 14px;">[已签]</span>
+ <span v-else style="color: #6d737b;font-size: 14px;">[未签]</span>
+
+ </div>
+ </el-timeline-item>
<el-timeline-item
v-for="(activity, index) in state.activities"
:key="index"
- :icon="activity.icon"
- :type="activity.type"
- :color="activity.state == 1 ? '#0bbd87' : '#B4B4B4' "
- :size="activity.size"
+ size="large"
+ style="font-size: 16px"
+ :color="activity.signStatus == 1 || activity.signStatus == 3 ? '#0bbd87' : '#B4B4B4' "
>
<div style="display: flex;font-size: 16px">
<div style="display: flex;flex-direction: column">
- <span v-if="activity.title" style="font-size: 14px;margin-bottom: 5px;color: #6d737b">{{activity.title}}</span>
+ <span style="font-size: 14px;margin-bottom: 5px;color: #6d737b">由 {{activity.deptName}} {{activity.userName}} 流转</span>
<div>
- <span style="font-size: 16px">{{activity.content}}</span>
- <span v-if="activity.state == 1 && index != 3" style="color: #1ab394;font-size: 14px;margin-left: 5px">[已签]</span>
- <span v-if="activity.state == 0 && index != 3" style="color: #6d737b;font-size: 14px;margin-left: 5px">[未签]</span>
- <span v-if="activity.state == 1 && index == 3" style="color: #1ab394;font-size: 14px;margin-left: 5px">[已归档]</span>
+ <span style="font-size: 16px" >{{activity.signUserName}}({{activity.signDeptName}})</span>
+ <span v-if="activity.signStatus == 1" style="color: #1ab394;font-size: 14px;margin-left: 5px">[已签]</span>
+ <span v-else-if="activity.signStatus == 0 || activity.signStatus == null " style="color: #6d737b;font-size: 14px;margin-left: 5px">[未签]</span>
+ <span v-else-if="activity.signStatus == 3 && state.form.itemStatus == 2 " style="color: #1ab394;font-size: 14px;margin-left: 5px">[已归档]</span>
</div>
</div>
</div>
@@ -52,6 +62,9 @@
id: '',
},
activities: [],
+ creatContent: '',
+ firstPeopleContent: '',
+ firstPeopleState: null,
formRules:{
name: [{ required: true, trigger: "blur", message:'' }],
},
@@ -59,40 +72,52 @@
const openDialog = async (value) => {
- state.activities = [
- {
- content: '创建人:张三(综合办)',
- timestamp: '2018-04-03 20:46',
- size: 'large',
- state: 1,
- },
- {
- content: '最初签署人:李四',
- timestamp: '2018-04-03 20:46',
- size: 'large',
- state: 1,
- },
- {
- title: '由 XXX 部门 XX 流转',
- content: 'XXXX',
- timestamp: '2018-04-03 20:46',
- size: 'large',
- state: 1,
- },
- {
- title: '由 XXX 部门 XX 流转',
- content: 'XXXX',
- timestamp: '2018-04-03 20:46',
- size: 'large',
- state: 1,
- },
+ console.log('va',value)
+ state.form = JSON.parse(JSON.stringify(value))
+ state.activities = JSON.parse(JSON.stringify(value)).signatureFlows
+ const newArr = []
+ state.activities.forEach(item => {
+ if(item.sort == 1){
+ state.creatContent = item.userName + '('+ item.deptName + ')'
+ state.firstPeopleContent = item.signUserName + '('+ item.signDeptName + ')'
+ state.firstPeopleState = item.signStatus
+ }else {
+ newArr.push(item)
+ }
+ })
+ newArr.sort((a,b) => a.sort - b.sort)
+ state.activities = newArr
-
-
- ]
+ // state.activities = [
+ // {
+ // content: '创建人:张三(综合办)',
+ // timestamp: '2018-04-03 20:46',
+ // size: 'large',
+ // state: 1,
+ // },
+ // {
+ // content: '最初签署人:李四',
+ // timestamp: '2018-04-03 20:46',
+ // size: 'large',
+ // state: 1,
+ // },
+ // {
+ // title: '由 XXX 部门 XX 流转',
+ // content: 'XXXX',
+ // timestamp: '2018-04-03 20:46',
+ // size: 'large',
+ // state: 1,
+ // },
+ // {
+ // title: '由 XXX 部门 XX 流转',
+ // content: 'XXXX',
+ // timestamp: '2018-04-03 20:46',
+ // size: 'large',
+ // state: 1,
+ // },
+ // ]
dialogVisible.value = true;
}
-
const handleClose = () => {
reset();
--
Gitblit v1.9.2