|
|
@@ -1,72 +1,138 @@
|
|
|
<template>
|
|
|
<div>
|
|
|
- <el-dialog
|
|
|
- title="督办事项"
|
|
|
- :visible.sync="selfVisible"
|
|
|
- @open="open">
|
|
|
+ <!-- eslint-disable-next-line vue/no-mutating-props, vue/no-mutating-props -->
|
|
|
+ <el-dialog title="督办事项" :visible.sync="selfVisible" @open="open">
|
|
|
<el-row :gutter="20">
|
|
|
<el-col :span="18">
|
|
|
- <span style="font-size: 18px; margin-right: 10px;">{{theTask.taskTitle}}</span>
|
|
|
- <el-button type="primary" v-show="theTask.isOverdue === '10'" @click="changeStatus('IsOverdue', '20')">超期</el-button>
|
|
|
- <el-button type="primary" v-show="theTask.taskStatus === '10'" @click="changeStatus('TaskStatus', '20')">关闭</el-button>
|
|
|
- <div style="border-bottom: solid 1px; margin-top: 1px;"></div>
|
|
|
- <el-row :gutter="20" style="margin-top: 10px;">
|
|
|
- <el-col :span="8">督办类型:{{typeMap[theTask.taskType]}}</el-col>
|
|
|
- <el-col :span="8">状态:{{theTask.taskStatus === '10' ? '进行中' : '关闭'}}</el-col>
|
|
|
- <el-col :span="8">超期:{{theTask.isOverdue === '10' ? '否' : '是'}}</el-col>
|
|
|
- <el-col :span="8">开始时间:{{parseTime(theTask.taskStartDate)}}</el-col>
|
|
|
- <el-col :span="8">结束时间:{{parseTime(theTask.taskEndDate)}}</el-col>
|
|
|
- <el-col :span="24">说明:{{theTask.taskDesc}}</el-col>
|
|
|
- <el-col :span="8">督办人:{{userMap[theTask.supervisorUserId]}}</el-col>
|
|
|
- <el-col :span="8">监办人:{{userMap[theTask.watchUserId]}}</el-col>
|
|
|
- <el-col :span="8">负责人:{{userMap[theTask.mainUserId]}}</el-col>
|
|
|
- <el-col :span="16">团队成员:{{teamNames}}</el-col>
|
|
|
- <el-col :span="8">关联类型:
|
|
|
+ <span style="font-size: 18px; margin-right: 10px">
|
|
|
+ {{ theTask.taskTitle }}
|
|
|
+ </span>
|
|
|
+ <el-button
|
|
|
+ v-show="theTask.isOverdue === '10'"
|
|
|
+ type="primary"
|
|
|
+ @click="changeStatus('IsOverdue', '20')">
|
|
|
+ 超期
|
|
|
+ </el-button>
|
|
|
+ <el-button
|
|
|
+ v-show="theTask.taskStatus === '10'"
|
|
|
+ type="primary"
|
|
|
+ @click="changeStatus('TaskStatus', '20')">
|
|
|
+ 关闭
|
|
|
+ </el-button>
|
|
|
+ <div style="border-bottom: solid 1px; margin-top: 1px"></div>
|
|
|
+ <el-row :gutter="20" style="margin-top: 10px">
|
|
|
+ <el-col :span="8">督办类型:{{ typeMap[theTask.taskType] }}</el-col>
|
|
|
+ <el-col :span="8">
|
|
|
+ 状态:{{ theTask.taskStatus === '10' ? '进行中' : '关闭' }}
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="8">
|
|
|
+ 超期:{{ theTask.isOverdue === '10' ? '否' : '是' }}
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="8">
|
|
|
+ 开始时间:{{ parseTime(theTask.taskStartDate) }}
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="8">
|
|
|
+ 结束时间:{{ parseTime(theTask.taskEndDate) }}
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="24">说明:{{ theTask.taskDesc }}</el-col>
|
|
|
+ <el-col :span="8">
|
|
|
+ 督办人:{{ userMap[theTask.supervisorUserId] }}
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="8">
|
|
|
+ 监办人:{{ userMap[theTask.watchUserId] }}
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="8">负责人:{{ userMap[theTask.mainUserId] }}</el-col>
|
|
|
+ <el-col :span="16">团队成员:{{ teamNames }}</el-col>
|
|
|
+ <el-col :span="8">
|
|
|
+ 关联类型:
|
|
|
<span v-show="theTask.targetType == '10'">客户</span>
|
|
|
<span v-show="theTask.targetType == '20'">项目</span>
|
|
|
<span v-show="theTask.targetType == '30'">合同</span>
|
|
|
<span v-show="theTask.targetType == '40'">回款</span>
|
|
|
</el-col>
|
|
|
- <el-col :span="8">关联对象:{{theTask.targetName}}</el-col>
|
|
|
- <el-col :span="8">创建人:{{theTask.createdName}}</el-col>
|
|
|
- <el-col :span="8">创建时间:{{parseTime(theTask.createdTime)}}</el-col>
|
|
|
- <el-col :span="24">备注:{{theTask.remark}}</el-col>
|
|
|
- <el-button type="primary" v-show="theTask.taskStatus === '10'" @click="addProgress">添加进展</el-button>
|
|
|
+ <el-col :span="8">关联对象:{{ theTask.targetName }}</el-col>
|
|
|
+ <el-col :span="8">创建人:{{ theTask.createdName }}</el-col>
|
|
|
+ <el-col :span="8">
|
|
|
+ 创建时间:{{ parseTime(theTask.createdTime) }}
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="24">备注:{{ theTask.remark }}</el-col>
|
|
|
+ <el-button
|
|
|
+ v-show="theTask.taskStatus === '10'"
|
|
|
+ type="primary"
|
|
|
+ @click="addProgress">
|
|
|
+ 添加进展
|
|
|
+ </el-button>
|
|
|
<el-table border :data="progressList" height="440">
|
|
|
- <el-table-column align="center" label="进展说明" prop="progDesc"></el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ align="center"
|
|
|
+ label="进展说明"
|
|
|
+ prop="progDesc" />
|
|
|
<el-table-column align="center" label="时间" prop="progDate">
|
|
|
<template #default="{ row }">
|
|
|
- {{parseTime(row.progDate)}}
|
|
|
+ {{ parseTime(row.progDate) }}
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
<el-table-column align="center" label="附件" prop="progFile">
|
|
|
<template #default="{ row }">
|
|
|
- <el-link v-show="row.progFile != ''" @click="showFile(row.progFile)">查看附件</el-link>
|
|
|
+ <el-link
|
|
|
+ v-show="row.progFile != ''"
|
|
|
+ @click="showFile(row.progFile)">
|
|
|
+ 查看附件
|
|
|
+ </el-link>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column align="center" label="备注" prop="remark"></el-table-column>
|
|
|
+ <el-table-column align="center" label="备注" prop="remark" />
|
|
|
</el-table>
|
|
|
</el-row>
|
|
|
</el-col>
|
|
|
<el-col :span="6">
|
|
|
- <el-button :type="rightInfo == 'log' ? 'primary' : 'none'" round @click="changeRightInfo('log')">流程动态</el-button>
|
|
|
- <el-button :type="rightInfo == 'comment' ? 'primary' : 'none'" round @click="changeRightInfo('comment')">评论</el-button>
|
|
|
- <div style="border-bottom: solid 1px; margin-top: 1px;"></div>
|
|
|
- <div style="height: 560px; width: 100%;">
|
|
|
- <div v-for="log in logList" :key="log.id" style="margin-top: 10px;" v-show="rightInfo == 'log'">
|
|
|
- {{log.nodeName}}
|
|
|
- <div style="margin-top: 5px;">
|
|
|
- <span style="margin-top: 5px;">{{log.createdName}}</span><span style="float: right; margin-top: 5px;">{{log.desc}}</span>
|
|
|
- <div style="margin-top: 5px;">开始处理:{{log.startTime}}</div>
|
|
|
- <div style="margin-top: 5px;">完成处理:{{log.endTime}}</div>
|
|
|
+ <el-button
|
|
|
+ round
|
|
|
+ :type="rightInfo == 'log' ? 'primary' : 'none'"
|
|
|
+ @click="changeRightInfo('log')">
|
|
|
+ 流程动态
|
|
|
+ </el-button>
|
|
|
+ <el-button
|
|
|
+ round
|
|
|
+ :type="rightInfo == 'comment' ? 'primary' : 'none'"
|
|
|
+ @click="changeRightInfo('comment')">
|
|
|
+ 评论
|
|
|
+ </el-button>
|
|
|
+ <div style="border-bottom: solid 1px; margin-top: 1px"></div>
|
|
|
+ <div style="height: 560px; width: 100%">
|
|
|
+ <div
|
|
|
+ v-for="log in logList"
|
|
|
+ v-show="rightInfo == 'log'"
|
|
|
+ :key="log.id"
|
|
|
+ style="margin-top: 10px">
|
|
|
+ {{ log.nodeName }}
|
|
|
+ <div style="margin-top: 5px">
|
|
|
+ <span style="margin-top: 5px">{{ log.createdName }}</span>
|
|
|
+ <span style="float: right; margin-top: 5px">
|
|
|
+ {{ log.desc }}
|
|
|
+ </span>
|
|
|
+ <div style="margin-top: 5px">开始处理:{{ log.startTime }}</div>
|
|
|
+ <div style="margin-top: 5px">完成处理:{{ log.endTime }}</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <el-button style="margin-top: 10px;" type="primary" v-show="rightInfo == 'comment'" @click="addComment">评论</el-button>
|
|
|
- <div v-for="comment in commentList" :key="comment.id" style="margin-top: 10px;" v-show="rightInfo == 'comment'">
|
|
|
- {{comment.createdName}}
|
|
|
- <div style="margin-top: 5px;">
|
|
|
- <span style="margin-top: 5px;">评论时间:{{comment.createdTime}}</span>
|
|
|
- <div style="margin-top: 5px;">评论:{{comment.content}}</div>
|
|
|
+ <el-button
|
|
|
+ v-show="rightInfo == 'comment'"
|
|
|
+ style="margin-top: 10px"
|
|
|
+ type="primary"
|
|
|
+ @click="addComment">
|
|
|
+ 评论
|
|
|
+ </el-button>
|
|
|
+ <div
|
|
|
+ v-for="comment in commentList"
|
|
|
+ v-show="rightInfo == 'comment'"
|
|
|
+ :key="comment.id"
|
|
|
+ style="margin-top: 10px">
|
|
|
+ {{ comment.createdName }}
|
|
|
+ <div style="margin-top: 5px">
|
|
|
+ <span style="margin-top: 5px">
|
|
|
+ 评论时间:{{ comment.createdTime }}
|
|
|
+ </span>
|
|
|
+ <div style="margin-top: 5px">评论:{{ comment.content }}</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
@@ -74,9 +140,15 @@
|
|
|
</el-row>
|
|
|
</el-dialog>
|
|
|
<!-- 评论添加 -->
|
|
|
- <commentAdd :theTask="theTask" :doRefresh="getCommentList" :selfVisible.sync="commentAddDialogVisible"></commentAdd>
|
|
|
+ <commentAdd
|
|
|
+ :do-refresh="getCommentList"
|
|
|
+ :self-visible.sync="commentAddDialogVisible"
|
|
|
+ :the-task="theTask" />
|
|
|
<!-- 进展添加 -->
|
|
|
- <progressAdd :theTask="theTask" :doRefresh="doRefreshProgressAndLogs" :selfVisible.sync="progressAddDialogVisible"></progressAdd>
|
|
|
+ <progressAdd
|
|
|
+ :do-refresh="doRefreshProgressAndLogs"
|
|
|
+ :self-visible.sync="progressAddDialogVisible"
|
|
|
+ :the-task="theTask" />
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
@@ -91,30 +163,28 @@
|
|
|
props: {
|
|
|
selfVisible: {
|
|
|
type: Boolean,
|
|
|
- default: false
|
|
|
+ default: false,
|
|
|
},
|
|
|
theTask: {
|
|
|
type: Object,
|
|
|
- default: {}
|
|
|
+ // eslint-disable-next-line vue/require-valid-default-prop
|
|
|
+ default: {},
|
|
|
},
|
|
|
userMap: {
|
|
|
type: Object,
|
|
|
- default: {}
|
|
|
+ // eslint-disable-next-line vue/require-valid-default-prop
|
|
|
+ default: {},
|
|
|
},
|
|
|
typeMap: {
|
|
|
type: Object,
|
|
|
- default: {}
|
|
|
+ // eslint-disable-next-line vue/require-valid-default-prop
|
|
|
+ default: {},
|
|
|
},
|
|
|
doRefresh: {
|
|
|
type: Function,
|
|
|
default: undefined,
|
|
|
},
|
|
|
},
|
|
|
- watch: {
|
|
|
- selfVisible (val) {
|
|
|
- this.$emit('update:selfVisible', val)
|
|
|
- }
|
|
|
- },
|
|
|
data() {
|
|
|
return {
|
|
|
// 进展新增弹窗
|
|
|
@@ -133,20 +203,26 @@
|
|
|
commentList: [],
|
|
|
}
|
|
|
},
|
|
|
+ watch: {
|
|
|
+ selfVisible(val) {
|
|
|
+ this.$emit('update:selfVisible', val)
|
|
|
+ },
|
|
|
+ },
|
|
|
methods: {
|
|
|
// 改变督办状态
|
|
|
changeStatus(type, status) {
|
|
|
this.$confirm('确定修改督办状态?', '提示', {
|
|
|
confirmButtonText: '确定',
|
|
|
cancelButtonText: '取消',
|
|
|
- type: 'warning'
|
|
|
+ type: 'warning',
|
|
|
}).then(async () => {
|
|
|
+ // eslint-disable-next-line vue/no-mutating-props
|
|
|
this.selfVisible = false
|
|
|
let data = {
|
|
|
taskId: this.theTask.id + '',
|
|
|
type: type,
|
|
|
oldStatus: this.theTask.taskStatus,
|
|
|
- nowStatus: status
|
|
|
+ nowStatus: status,
|
|
|
}
|
|
|
const { msg } = await taskApi.updateTaskStatus(data)
|
|
|
this.$baseMessage(msg, 'success', 'vab-hey-message-success')
|
|
|
@@ -198,36 +274,42 @@
|
|
|
// 获取进展信息
|
|
|
getProgressList() {
|
|
|
this.progressList = []
|
|
|
- taskApi.getTaskProgressList({ taskId: this.theTask.id + '' })
|
|
|
- .then(res => {
|
|
|
+ taskApi
|
|
|
+ .getTaskProgressList({ taskId: this.theTask.id + '' })
|
|
|
+ .then((res) => {
|
|
|
if (res.data.list) {
|
|
|
this.progressList = res.data.list
|
|
|
}
|
|
|
- }).catch(err => {
|
|
|
+ })
|
|
|
+ .catch((err) => {
|
|
|
console.error(err)
|
|
|
})
|
|
|
},
|
|
|
// 获取日志信息
|
|
|
getLogList() {
|
|
|
this.logList = []
|
|
|
- taskApi.getTaskLogList({ taskId: this.theTask.id + '' })
|
|
|
- .then(res => {
|
|
|
+ taskApi
|
|
|
+ .getTaskLogList({ taskId: this.theTask.id + '' })
|
|
|
+ .then((res) => {
|
|
|
if (res.data.list) {
|
|
|
this.logList = res.data.list
|
|
|
}
|
|
|
- }).catch(err => {
|
|
|
+ })
|
|
|
+ .catch((err) => {
|
|
|
console.error(err)
|
|
|
})
|
|
|
},
|
|
|
// 获取评论信息
|
|
|
getCommentList() {
|
|
|
this.commentList = []
|
|
|
- taskApi.getTaskCommentList({ taskId: this.theTask.id + '' })
|
|
|
- .then(res => {
|
|
|
+ taskApi
|
|
|
+ .getTaskCommentList({ taskId: this.theTask.id + '' })
|
|
|
+ .then((res) => {
|
|
|
if (res.data.list) {
|
|
|
this.commentList = res.data.list
|
|
|
}
|
|
|
- }).catch(err => {
|
|
|
+ })
|
|
|
+ .catch((err) => {
|
|
|
console.error(err)
|
|
|
})
|
|
|
},
|
|
|
@@ -235,6 +317,6 @@
|
|
|
changeRightInfo(info) {
|
|
|
this.rightInfo = info
|
|
|
},
|
|
|
- }
|
|
|
+ },
|
|
|
}
|
|
|
-</script>
|
|
|
+</script>
|