|
@@ -1,6 +1,6 @@
|
|
|
<template>
|
|
|
<div class="stock">
|
|
|
- <template v-if="!addOrUpdateVisible">
|
|
|
+ <template v-if="!addOrUpdateVisible && !detailVisible">
|
|
|
<el-form :inline="true" :model="dataForm" @keyup.enter.native="getDataList()">
|
|
|
<el-form-item label="工单名称">
|
|
|
<el-input v-model="dataForm.taskName" placeholder="工单名称" clearable/>
|
|
@@ -250,6 +250,7 @@
|
|
|
</template>
|
|
|
<attach-detail-dialog ref="attachDetail" />
|
|
|
<worder-add-or-update v-if="addOrUpdateVisible" ref="worder" @onChose="onChose" />
|
|
|
+ <work-center-detail v-if="detailVisible" ref="detail"></work-center-detail>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
@@ -261,12 +262,14 @@ import {taskTypeOption, rankTypeOption, nodeStateOPtion} from '@/utils/enums'
|
|
|
import UserComponent from '@/views/modules/common/user-component'
|
|
|
import AttachDetailDialog from '../common/attach-detail-dialog'
|
|
|
import WorderAddOrUpdate from '../worder/add-or-update'
|
|
|
+import WorkCenterDetail from './work-center-detail'
|
|
|
export default {
|
|
|
name: 'works-work-center',
|
|
|
- components: {UserComponent, AttachDetailDialog, WorderAddOrUpdate},
|
|
|
+ components: {UserComponent, AttachDetailDialog, WorderAddOrUpdate, WorkCenterDetail},
|
|
|
data () {
|
|
|
return {
|
|
|
addOrUpdateVisible: false,
|
|
|
+ detailVisible: false,
|
|
|
dataListLoading: false,
|
|
|
pageIndex: 1,
|
|
|
pageSize: 10,
|
|
@@ -284,6 +287,7 @@ export default {
|
|
|
methods: {
|
|
|
onChose () {
|
|
|
this.addOrUpdateVisible = false
|
|
|
+ this.detailVisible = false
|
|
|
},
|
|
|
userChanged (val) {
|
|
|
// this.dataForm.userId = val
|
|
@@ -318,7 +322,11 @@ export default {
|
|
|
this.dataListLoading = false
|
|
|
})
|
|
|
},
|
|
|
- showDetail () {
|
|
|
+ showDetail (taskId) {
|
|
|
+ this.detailVisible = true
|
|
|
+ this.$nextTick(() => {
|
|
|
+ this.$refs.detail.init(taskId)
|
|
|
+ })
|
|
|
},
|
|
|
addOrUpdateHandle (taskId, item) {
|
|
|
this.addOrUpdateVisible = true
|