|
@@ -258,7 +258,7 @@
|
|
<div class="title-left-icon" />
|
|
<div class="title-left-icon" />
|
|
<div class="title-left-name">动态</div>
|
|
<div class="title-left-name">动态</div>
|
|
</div>
|
|
</div>
|
|
- <el-tabs v-model="tabPosition" class="sign-tabs" @tab-click="handleClick">
|
|
|
|
|
|
+ <el-tabs v-model="tabPosition" class="sign-tabs">
|
|
<el-tab-pane label="评论" name="first">
|
|
<el-tab-pane label="评论" name="first">
|
|
<div class="detail-info">
|
|
<div class="detail-info">
|
|
<ul class="comment-main">
|
|
<ul class="comment-main">
|
|
@@ -300,7 +300,7 @@
|
|
<!-- 缺陷 -->
|
|
<!-- 缺陷 -->
|
|
<el-container v-if="activeName === '3'" class="is-vertical">
|
|
<el-container v-if="activeName === '3'" class="is-vertical">
|
|
<section class="main-section contain">
|
|
<section class="main-section contain">
|
|
- <bugTableDialog ref="bugTableDialog" no-show="taskName" :obj-id="{ taskId: Number(this.$route.query.id) }" />
|
|
|
|
|
|
+ <bugTableDialog ref="bugTableDialog" no-show="taskName" :obj-id="{ taskId: taskId }" />
|
|
</section>
|
|
</section>
|
|
</el-container>
|
|
</el-container>
|
|
<!-- 缺陷 -->
|
|
<!-- 缺陷 -->
|
|
@@ -378,6 +378,8 @@ const _ = require('lodash')
|
|
import Vue from 'vue'
|
|
import Vue from 'vue'
|
|
import VueClipboard from 'vue-clipboard2'
|
|
import VueClipboard from 'vue-clipboard2'
|
|
Vue.use(VueClipboard)
|
|
Vue.use(VueClipboard)
|
|
|
|
+import { mapGetters } from 'vuex'
|
|
|
|
+import { analysisBizId_id } from '@/utils/crypto-js.js'
|
|
import {
|
|
import {
|
|
taskGet,
|
|
taskGet,
|
|
configShowTaskEnum,
|
|
configShowTaskEnum,
|
|
@@ -477,7 +479,7 @@ export default {
|
|
userNames: localStorage.getItem('realname'),
|
|
userNames: localStorage.getItem('realname'),
|
|
textarea: '', // 评论
|
|
textarea: '', // 评论
|
|
showTaskDialog: false, // 状态弹窗
|
|
showTaskDialog: false, // 状态弹窗
|
|
- taskId: Number(this.$route.query.id), // 任务id
|
|
|
|
|
|
+ taskId: -1, // 任务id
|
|
allStatus: [], // 任务所有状态
|
|
allStatus: [], // 任务所有状态
|
|
belongProjectList: [], // 所属项目列表
|
|
belongProjectList: [], // 所属项目列表
|
|
requireList: [], // 所属需求列表
|
|
requireList: [], // 所属需求列表
|
|
@@ -504,40 +506,43 @@ export default {
|
|
dplOption: [] // 关联的望岳任务
|
|
dplOption: [] // 关联的望岳任务
|
|
}
|
|
}
|
|
},
|
|
},
|
|
|
|
+
|
|
computed: {
|
|
computed: {
|
|
getStatus() {
|
|
getStatus() {
|
|
return this.allStatus.find(item => item.code === this.form_query.status) || { name: null }
|
|
return this.allStatus.find(item => item.code === this.form_query.status) || { name: null }
|
|
- }
|
|
|
|
|
|
+ },
|
|
|
|
+ ...mapGetters(['bizId'])
|
|
},
|
|
},
|
|
watch: {
|
|
watch: {
|
|
activeName: {
|
|
activeName: {
|
|
handler(newV) {
|
|
handler(newV) {
|
|
Number(newV) > 0
|
|
Number(newV) > 0
|
|
- ? this.$router.push({ path: this.$route.path, query: { id: this.$route.query.id, page: newV }})
|
|
|
|
- : this.$router.push({ path: this.$route.path, query: { id: this.$route.query.id, page: '1' }})
|
|
|
|
|
|
+ ? this.$router.replace({ path: this.$route.path, query: { ...this.$route.query, page: newV }})
|
|
|
|
+ : this.$router.replace({ path: this.$route.path, query: { ...this.$route.query, page: '1' }})
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
},
|
|
created() {
|
|
created() {
|
|
|
|
+ this.analysisBizId_id()
|
|
this.$nextTick(() => {
|
|
this.$nextTick(() => {
|
|
this.activeName = this.$route.query.page ? this.$route.query.page : '1'
|
|
this.activeName = this.$route.query.page ? this.$route.query.page : '1'
|
|
})
|
|
})
|
|
- this.taskGet()
|
|
|
|
- this.getTaskStatus()
|
|
|
|
- this.getBelongProject()
|
|
|
|
- this.getRequireList()
|
|
|
|
- this.getCommentList()
|
|
|
|
- this.getScheduleGetTaskScheduleHistory()
|
|
|
|
this.$store.state.data.status = true
|
|
this.$store.state.data.status = true
|
|
- // this.$store.state.data.bizId = true
|
|
|
|
},
|
|
},
|
|
destroyed() {
|
|
destroyed() {
|
|
this.$store.state.data.status = false
|
|
this.$store.state.data.status = false
|
|
- // this.$store.state.data.bizId = false
|
|
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
- handleClick(tab, event) {
|
|
|
|
- console.log(tab, event)
|
|
|
|
|
|
+ analysisBizId_id() { // 解析路由中的bizId_id
|
|
|
|
+ if (!this.$route.query.bizId_id) return
|
|
|
|
+ const bizId_id = analysisBizId_id(this.$route.query.bizId_id)
|
|
|
|
+ this.taskId = bizId_id[1]
|
|
|
|
+ this.taskGet()
|
|
|
|
+ this.getTaskStatus()
|
|
|
|
+ this.getBelongProject()
|
|
|
|
+ this.getRequireList()
|
|
|
|
+ this.getCommentList()
|
|
|
|
+ this.getScheduleGetTaskScheduleHistory()
|
|
},
|
|
},
|
|
async getScheduleGetTaskScheduleHistory() {
|
|
async getScheduleGetTaskScheduleHistory() {
|
|
this.scheduleVisble = false
|
|
this.scheduleVisble = false
|
|
@@ -627,13 +632,13 @@ export default {
|
|
this.taskGet()
|
|
this.taskGet()
|
|
},
|
|
},
|
|
async getBelongProject() { // 获取所属项目列表
|
|
async getBelongProject() { // 获取所属项目列表
|
|
- const res = await projectListProject({ bizId: Number(localStorage.getItem('bizId')) })
|
|
|
|
|
|
+ const res = await projectListProject({ bizId: this.bizId })
|
|
if (res.code === 200) {
|
|
if (res.code === 200) {
|
|
this.belongProjectList = res.data
|
|
this.belongProjectList = res.data
|
|
}
|
|
}
|
|
},
|
|
},
|
|
async getRequireList() { // 获取所属需求列表
|
|
async getRequireList() { // 获取所属需求列表
|
|
- const res = await configShowRequirementVersionEnum({ bizId: Number(localStorage.getItem('bizId')) })
|
|
|
|
|
|
+ const res = await configShowRequirementVersionEnum({ bizId: this.bizId })
|
|
if (res.code === 200) {
|
|
if (res.code === 200) {
|
|
this.requireList = res.data
|
|
this.requireList = res.data
|
|
}
|
|
}
|
|
@@ -651,7 +656,7 @@ export default {
|
|
}
|
|
}
|
|
},
|
|
},
|
|
async taskGet() { // 获取任务详情
|
|
async taskGet() { // 获取任务详情
|
|
- const res = await taskGet(this.$route.query.id)
|
|
|
|
|
|
+ const res = await taskGet(this.taskId)
|
|
if (res.code === 200) {
|
|
if (res.code === 200) {
|
|
this.form_query = res.data
|
|
this.form_query = res.data
|
|
if (this.form_query.isDirectlyFromDpm === 0 || this.form_query.isDirectlyFromDpm === 1) {
|
|
if (this.form_query.isDirectlyFromDpm === 0 || this.form_query.isDirectlyFromDpm === 1) {
|