|
@@ -51,7 +51,14 @@
|
|
|
<template slot-scope="scope">
|
|
|
<el-select
|
|
|
v-model="scope.row.status"
|
|
|
- :class="['status'+scope.row.status]"
|
|
|
+ :class="{
|
|
|
+ 'status_color': scope.row.status === 0,
|
|
|
+ 'status_color1': scope.row.status === 1,
|
|
|
+ 'item': scope.row.status === 3,
|
|
|
+ 'item1': scope.row.status === 2,
|
|
|
+ 'item2': scope.row.status === 4,
|
|
|
+ 'status_color2': scope.row.status === 5
|
|
|
+ }"
|
|
|
class="btns"
|
|
|
size="mini"
|
|
|
@change="changeStatus(scope.row)"
|
|
@@ -81,6 +88,7 @@
|
|
|
<TestReport v-if="dialogTestReport" ref="TestReport" />
|
|
|
<DailyReport v-if="dialogDailyReport" ref="DailyReport" />
|
|
|
<ClientReport v-if="dialogClientReport" ref="ClientReport" />
|
|
|
+ <task-dialog v-if="showTaskDialog" :show.sync="showTaskDialog" :task-id="taskId.id" :status-name="taskId.statusString" @getList="get_allTask" />
|
|
|
<normal-dialog :show-dialog.sync="statusDialog" :title="'状态变更:已上线'" :width="'50%'" @confirm="confirmStatus()">
|
|
|
<div class="dialog-change-status">
|
|
|
<span>实际上线时间:</span>
|
|
@@ -90,6 +98,7 @@
|
|
|
</div>
|
|
|
</template>
|
|
|
<script>
|
|
|
+import '@/styles/PublicStyle/index.scss'
|
|
|
import TestReport from '@/views/Platform/presentation/Templates/TestReport' // 提测
|
|
|
import DailyReport from '@/views/Platform/presentation/Templates/DailyReport' // 日报
|
|
|
import ClientReport from '@/views/Platform/presentation/Templates/ClientReport' // 准出
|
|
@@ -98,19 +107,22 @@ import { taskUpdate } from '@/api/projectViewDetails'
|
|
|
import { configShowTaskEnum } from '@/api/taskIndex'
|
|
|
import scheduleList from './scheduleList'
|
|
|
import normalDialog from '@/components/dialog/normalDialog'
|
|
|
+import taskDialog from '@/views/projectManage/taskList/dialog/taskDialog' // 任务状态修改(已上线/已提测/已准出)
|
|
|
export default {
|
|
|
components: {
|
|
|
normalDialog,
|
|
|
TestReport,
|
|
|
DailyReport,
|
|
|
ClientReport,
|
|
|
- scheduleList
|
|
|
+ scheduleList,
|
|
|
+ taskDialog
|
|
|
},
|
|
|
data() {
|
|
|
return {
|
|
|
changeData: new Map(),
|
|
|
allChange: false, // 是否全展开
|
|
|
expandArr: [], // 展开行数组
|
|
|
+ showTaskDialog: false, // 状态弹窗
|
|
|
inputValue: '',
|
|
|
all_task: [], // 任务列表
|
|
|
allStatus: [], // 任务所有状态
|
|
@@ -125,7 +137,8 @@ export default {
|
|
|
dialogClientReport: false, // 准出
|
|
|
statusDialog: false, // 修改状态弹框
|
|
|
changeStatusDate: null, // 状态改变时间
|
|
|
- nowChangeTask: null // 当前正在改变的任务对象
|
|
|
+ nowChangeTask: null, // 当前正在改变的任务对象
|
|
|
+ taskId: '' // 将要修改状态的任务id
|
|
|
}
|
|
|
},
|
|
|
watch: {
|
|
@@ -173,9 +186,14 @@ export default {
|
|
|
isEx ? this.expandArr = this.all_task.map(item => item.id) : this.expandArr = []
|
|
|
},
|
|
|
async changeStatus(e) { // 状态改变
|
|
|
- if (e.status === 5) { // 已上线
|
|
|
- this.statusDialog = true
|
|
|
+ if (e.status === 2 || e.status === 4 || e.status === 5) {
|
|
|
+ this.taskId = e
|
|
|
+ this.allStatus.map(item => {
|
|
|
+ item.code === e.status ? this.taskId.statusString = item.msg : ''
|
|
|
+ })
|
|
|
+ this.showTaskDialog = true
|
|
|
this.nowChangeTask = e
|
|
|
+ return
|
|
|
} else {
|
|
|
const user = {
|
|
|
name: localStorage.getItem('username'),
|
|
@@ -190,11 +208,7 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
async confirmStatus() { // 确认更改状态
|
|
|
- const user = {
|
|
|
- name: localStorage.getItem('username'),
|
|
|
- ename: localStorage.getItem('realname'),
|
|
|
- id: ''
|
|
|
- }
|
|
|
+ const user = { name: localStorage.getItem('username'), ename: localStorage.getItem('realname'), id: '' }
|
|
|
const taskInfoDO = this.nowChangeTask
|
|
|
taskInfoDO.onlineRealTime = this.changeStatusDate
|
|
|
const resTask = await taskUpdate({ taskInfoDO, user })
|
|
@@ -388,3 +402,85 @@ export default {
|
|
|
white-space:nowrap;
|
|
|
}
|
|
|
</style>
|
|
|
+<style lang="scss">
|
|
|
+.btns .el-input--suffix .el-input__inner {
|
|
|
+ padding-right: 10px;
|
|
|
+ padding-left: 10px;
|
|
|
+ width: 73px;
|
|
|
+}
|
|
|
+.item{
|
|
|
+ /deep/ input {
|
|
|
+ color: rgb(126, 211, 33);
|
|
|
+ border: 1px solid rgb(126, 211, 33);
|
|
|
+ border-color: rgb(126, 211, 33) !important;
|
|
|
+ font-weight: 900;
|
|
|
+ }
|
|
|
+ /deep/ .el-input__suffix {
|
|
|
+ color: rgb(126, 211, 33) !important;
|
|
|
+ right: 1px;
|
|
|
+ }
|
|
|
+ /deep/ .el-select__caret {
|
|
|
+ color: rgb(126, 211, 33) !important;
|
|
|
+ }
|
|
|
+}
|
|
|
+.item1 {
|
|
|
+ /deep/ input {
|
|
|
+ color: rgb(255, 204, 102);
|
|
|
+ border: 1px solid rgb(255, 204, 102);
|
|
|
+ border-color: rgb(255, 204, 102) !important;
|
|
|
+ font-weight: 900;
|
|
|
+ }
|
|
|
+ /deep/ .el-input__suffix {
|
|
|
+ color: rgb(255, 204, 102) !important;
|
|
|
+ right: 1px;
|
|
|
+ }
|
|
|
+ /deep/ .el-select__caret {
|
|
|
+ color: rgb(255, 204, 102) !important;
|
|
|
+ }
|
|
|
+}
|
|
|
+.item2 {
|
|
|
+ /deep/ input {
|
|
|
+ color: rgb(245, 108, 108);
|
|
|
+ border: 1px solid rgb(245, 108, 108);
|
|
|
+ border-color: rgb(245, 108, 108) !important;
|
|
|
+ font-weight: 900;
|
|
|
+ }
|
|
|
+ /deep/ .el-input__suffix {
|
|
|
+ color: rgb(245, 108, 108) !important;
|
|
|
+ right: 1px;
|
|
|
+ }
|
|
|
+ /deep/ .el-select__caret {
|
|
|
+ color: rgb(245, 108, 108) !important;
|
|
|
+ }
|
|
|
+}
|
|
|
+.item3 {
|
|
|
+ /deep/ input {
|
|
|
+ color: #D675F0;
|
|
|
+ border: 1px solid #D675F0;
|
|
|
+ border-color: #D675F0 !important;
|
|
|
+ font-weight: 900;
|
|
|
+ }
|
|
|
+ /deep/ .el-input__suffix {
|
|
|
+ color: #D675F0 !important;
|
|
|
+ right: 1px;
|
|
|
+ }
|
|
|
+ /deep/ .el-select__caret {
|
|
|
+ color: #D675F0 !important;
|
|
|
+ }
|
|
|
+}
|
|
|
+.item-color {
|
|
|
+ /deep/ input {
|
|
|
+ color: rgb(106, 180, 255);
|
|
|
+ border: 1px solid rgb(106, 180, 255);
|
|
|
+ border-color: rgb(106, 180, 255) !important;
|
|
|
+ font-weight: 900;
|
|
|
+ }
|
|
|
+ /deep/ .el-input__suffix {
|
|
|
+ color: rgb(106, 180, 255) !important;
|
|
|
+ right: 1px;
|
|
|
+ }
|
|
|
+ /deep/ .el-select__caret {
|
|
|
+ color: rgb(106, 180, 255) !important;
|
|
|
+ }
|
|
|
+}
|
|
|
+</style>
|