工单详情
This commit is contained in:
@@ -20,7 +20,8 @@ const _import = require('./import-' + process.env.NODE_ENV)
|
||||
const globalRoutes = [
|
||||
{ path: '/404', component: _import('common/404'), name: '404', meta: { title: '404未找到' } },
|
||||
{ path: '/login', component: _import('common/login'), name: 'login', meta: { title: '登录' } },
|
||||
{ path: '/register', component: _import('modules/sys/register'), name: 'register', meta: { title: '注册' } }
|
||||
{ path: '/register', component: _import('modules/sys/register'), name: 'register', meta: { title: '注册' } },
|
||||
{ path: '/tickets-detail', component: _import('modules/tickets/detail'), name: 'detail-tickets', meta: { title: '工单详情' } }
|
||||
]
|
||||
|
||||
// 主入口路由(需嵌套上左右整体布局)
|
||||
|
||||
138
base-vue/src/views/modules/tickets/detail.vue
Normal file
138
base-vue/src/views/modules/tickets/detail.vue
Normal file
@@ -0,0 +1,138 @@
|
||||
<template>
|
||||
<div class="mod-config">
|
||||
<el-descriptions class="margin-top" title="工单详情" :column="2" :size="size" border>
|
||||
<!-- <template slot="extra">
|
||||
<el-button type="primary" size="small">操作</el-button>
|
||||
</template> -->
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
<!-- <i class="el-icon-user"></i> -->
|
||||
工单ID
|
||||
</template>
|
||||
{{ ticketsData.ticketsId }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
小车类型
|
||||
</template>
|
||||
{{ ticketsData.carName }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
异常类型
|
||||
</template>
|
||||
{{ ticketsData.errorType }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
合同编号
|
||||
</template>
|
||||
{{ ticketsData.contractNumber }}
|
||||
<!-- <el-tag size="small">学校</el-tag> -->
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
客户
|
||||
</template>
|
||||
{{ ticketsData.clientName }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
故障描述
|
||||
</template>
|
||||
{{ ticketsData.description }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
部门对接人
|
||||
</template>
|
||||
{{ ticketsData.deptPeople }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
客户联系电话
|
||||
</template>
|
||||
{{ ticketsData.deptPhone }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
创建者
|
||||
</template>
|
||||
{{ ticketsData.createUserId }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
创建时间
|
||||
</template>
|
||||
{{ ticketsData.createTime }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
是否验收
|
||||
</template>
|
||||
{{ ['否', '是'][Number(ticketsData.isCheck)] }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
工单状态
|
||||
</template>
|
||||
{{ statusOpt | findByValue(ticketsData.status) }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
工单关闭时间
|
||||
</template>
|
||||
{{ ticketsData.updateTime }}
|
||||
</el-descriptions-item>
|
||||
</el-descriptions>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
data () {
|
||||
return {
|
||||
ticketsData: {},
|
||||
statusOpt: [{value: '0', label: '未开始'}, {value: '1', label: '已指派'}, {value: '2', label: '处理中'}, {value: '3', label: '已完成'}]
|
||||
}
|
||||
},
|
||||
created () {
|
||||
this.getDataList()
|
||||
},
|
||||
methods: {
|
||||
// 获取数据列表
|
||||
getDataList () {
|
||||
this.$http({
|
||||
url: this.$http.adornUrl(`/tickets/tickets/info/${this.$route.query.id}`),
|
||||
method: 'get',
|
||||
params: this.$http.adornParams({})
|
||||
}).then(({data}) => {
|
||||
if (data && data.code === 0) {
|
||||
this.ticketsData = data.tickets
|
||||
}
|
||||
})
|
||||
},
|
||||
// 每页数
|
||||
sizeChangeHandle (val) {
|
||||
this.pageSize = val
|
||||
this.pageIndex = 1
|
||||
this.getDataList()
|
||||
},
|
||||
// 当前页
|
||||
currentChangeHandle (val) {
|
||||
this.pageIndex = val
|
||||
this.getDataList()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.mod-config {
|
||||
padding: 20px 10px;
|
||||
}
|
||||
.el-pagination {
|
||||
margin-top: 15px;
|
||||
text-align: right;
|
||||
}
|
||||
</style>
|
||||
@@ -25,8 +25,8 @@
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="合同编号" prop="contractNumber">
|
||||
<el-select v-model="dataForm.contractNumber" placeholder="合同编号">
|
||||
<el-form-item label="合同编号" prop="contractId">
|
||||
<el-select v-model="dataForm.contractId" placeholder="合同编号">
|
||||
<el-option
|
||||
v-for="item in dictData[2]"
|
||||
:key="item.value"
|
||||
@@ -68,7 +68,7 @@
|
||||
ticketsId: null,
|
||||
carType: '',
|
||||
errorType: '',
|
||||
contractNumber: '',
|
||||
contractId: '',
|
||||
clientId: '',
|
||||
description: '',
|
||||
deptPhone: ''
|
||||
@@ -105,8 +105,8 @@
|
||||
if (data && data.code === 0) {
|
||||
this.dataForm.carType = data.tickets.carType
|
||||
this.dataForm.errorType = String(data.tickets.errorType)
|
||||
this.dataForm.contractNumber = String(data.tickets.contractNumber)
|
||||
this.dataForm.clientId = data.tickets.clientId
|
||||
this.dataForm.contractId = String(data.tickets.contractId)
|
||||
this.dataForm.clientId = String(data.tickets.clientId)
|
||||
this.dataForm.description = data.tickets.description
|
||||
this.dataForm.deptPhone = data.tickets.deptPhone
|
||||
}
|
||||
|
||||
@@ -50,7 +50,7 @@
|
||||
align="center"
|
||||
label="合同编号">
|
||||
<template slot-scope="scope">
|
||||
{{ dictData[2] | findByValue(scope.row.contractNumber) }}
|
||||
{{ dictData[2] | findByValue(scope.row.contractId) }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
@@ -99,12 +99,18 @@
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="是否验收">
|
||||
<template slot-scope="scope">
|
||||
{{ ['否', '是'][Number(scope.row.isCheck)] }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="status"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="工单状态">
|
||||
<template slot-scope="scope">
|
||||
{{ statusOpt | findByValue(scope.row.status) }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="updateTime"
|
||||
@@ -122,7 +128,7 @@
|
||||
<template slot-scope="scope">
|
||||
<el-button type="text" size="small" @click="addOrUpdateHandle(scope.row.ticketsId)">修改</el-button>
|
||||
<el-button type="text" size="small" @click="deleteHandle(scope.row.ticketsId)">删除</el-button>
|
||||
<el-button type="text" size="small" @click="startFlowHandle(scope.row.ticketsId)">指派</el-button>
|
||||
<el-button v-show="!scope.row.status" type="text" size="small" @click="startFlowHandle(scope.row.ticketsId)">指派</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
@@ -204,7 +210,8 @@
|
||||
flowForm:{ticketsId: null},
|
||||
dynamiForm:[],
|
||||
users: [],
|
||||
roles: []
|
||||
roles: [],
|
||||
statusOpt: [{value: '0', label: '未开始'}, {value: '1', label: '已指派'}, {value: '2', label: '处理中'}, {value: '3', label: '已完成'}]
|
||||
}
|
||||
},
|
||||
mixins: [apiUtils],
|
||||
|
||||
Reference in New Issue
Block a user