|
@@ -1,7 +1,7 @@
|
|
|
<template>
|
|
|
<div>
|
|
|
<el-button size="mini" type="primary" @click="editBtn">编 辑</el-button>
|
|
|
- <el-drawer title="新 建" append-to-body :show-close="false" :visible.sync="dialogFormVisible" size="40%">
|
|
|
+ <el-drawer title="新 建" append-to-body :show-close="false" :visible.sync="dialog" size="40%">
|
|
|
<div slot="title" style="font-size: 15px">
|
|
|
编辑服务工单
|
|
|
</div>
|
|
@@ -61,7 +61,7 @@
|
|
|
<el-input v-model="form.scenecontactphonenumber" placeholder="请输入联系人电话"></el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
- <el-col :span="24">
|
|
|
+ <!-- <el-col :span="24">
|
|
|
<el-form-item label="服务团队" prop="servicetype">
|
|
|
<selectTeam ref="team" @teamChange="teamChange">
|
|
|
<el-tag
|
|
@@ -76,7 +76,7 @@
|
|
|
<el-button class="button-new-tag" size="small" @click="$refs.team.dialogFormVisible=true">+ New people</el-button>
|
|
|
</selectTeam>
|
|
|
</el-form-item>
|
|
|
- </el-col>
|
|
|
+ </el-col> -->
|
|
|
<el-col :span="24">
|
|
|
<el-form-item label="备注" prop="remarks">
|
|
|
<el-input type="textarea" v-model="form.remarks" placeholder="请输入备注"></el-input>
|
|
@@ -86,7 +86,7 @@
|
|
|
</el-row>
|
|
|
</div>
|
|
|
<div class="fixed__btn__panel">
|
|
|
- <el-button size="small" @click="dialogFormVisible = false" class="normal-btn-width">取 消</el-button>
|
|
|
+ <el-button size="small" @click="dialog = false" class="normal-btn-width">取 消</el-button>
|
|
|
<el-button size="small" type="warning" @click="onSubmit" class="normal-btn-width btn-warning">确 定</el-button>
|
|
|
</div>
|
|
|
</el-drawer>
|
|
@@ -98,14 +98,13 @@ import selectOrder from './selectOrder'
|
|
|
import selectTemplate from './selectTemplate'
|
|
|
|
|
|
import selectTeam from './teamSelect'
|
|
|
-import { log } from '@antv/g2plot/lib/utils'
|
|
|
export default {
|
|
|
name: "add",
|
|
|
props:['data'],
|
|
|
components:{selectOrder,selectTemplate,selectTeam},
|
|
|
data(){
|
|
|
return {
|
|
|
- dialogFormVisible:false,
|
|
|
+ dialog:false,
|
|
|
serveClassList:[],
|
|
|
form:{
|
|
|
"sa_workorderid":'', //sa_brandid<=0时 为新增
|
|
@@ -140,7 +139,7 @@ export default {
|
|
|
},
|
|
|
methods:{
|
|
|
editBtn () {
|
|
|
- this.dialogFormVisible = true
|
|
|
+ this.dialog = true
|
|
|
this.form = Object.assign({},this.form,this.data)
|
|
|
this.form.projectlearders = this.form.team
|
|
|
console.log(this.form);
|
|
@@ -159,7 +158,7 @@ export default {
|
|
|
this.tool.showMessage(res,()=>{
|
|
|
this.$emit('onSuccess')
|
|
|
this.$refs['form'].resetFields();
|
|
|
- this.dialogFormVisible = false
|
|
|
+ this.dialog = false
|
|
|
})
|
|
|
})
|
|
|
},
|
|
@@ -197,6 +196,12 @@ export default {
|
|
|
userid:item.userid
|
|
|
}
|
|
|
})
|
|
|
+ result = result.filter(item => {
|
|
|
+ let is = this.form.projectlearders.every(item2 => {
|
|
|
+ return item.userid != item2.userid
|
|
|
+ })
|
|
|
+ if (is) return item
|
|
|
+ })
|
|
|
this.form.projectlearders.push(...result)
|
|
|
this.$refs.team.dialogFormVisible = false
|
|
|
}
|