|  |  |  | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | }, | 
|---|
|  |  |  | methods: { | 
|---|
|  |  |  | open (title, target,type) { | 
|---|
|  |  |  | open (title, target, type) { | 
|---|
|  |  |  | this.title = title | 
|---|
|  |  |  | this.visible = true | 
|---|
|  |  |  | this.form.type=type | 
|---|
|  |  |  | this.form.type = type | 
|---|
|  |  |  | this.loadMember() | 
|---|
|  |  |  | // 新建组织 | 
|---|
|  |  |  | if (target == null) { | 
|---|
|  |  |  | this.$nextTick(() => { | 
|---|
|  |  |  | this.$refs.form.resetFields() | 
|---|
|  |  |  | this.form[this.configData['field.id']] = null | 
|---|
|  |  |  | this.form.type=type | 
|---|
|  |  |  | this.form.type = type | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | return | 
|---|
|  |  |  | } | 
|---|
|  |  |  | 
|---|
|  |  |  | this.$nextTick(() => { | 
|---|
|  |  |  | for (const key in this.form) { | 
|---|
|  |  |  | this.form[key] = target[key] | 
|---|
|  |  |  | this.form.type=type | 
|---|
|  |  |  | if (this.type ==0 && target.memberIds != null && target.memberIds != '') { | 
|---|
|  |  |  | let t = target.memberIds.split(',') | 
|---|
|  |  |  | this.form.memberIdList =[] | 
|---|
|  |  |  | t.forEach(item =>{ | 
|---|
|  |  |  | this.form.type = type | 
|---|
|  |  |  | if (this.form.type == 0 && target.memberIds != null && target.memberIds != '') { | 
|---|
|  |  |  | const t = target.memberIds.split(',') | 
|---|
|  |  |  | this.form.memberIdList = [] | 
|---|
|  |  |  | t.forEach(item => { | 
|---|
|  |  |  | this.form.memberIdList.push(parseInt(item)) | 
|---|
|  |  |  | }); | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | }, | 
|---|
|  |  |  | loadMember () { | 
|---|
|  |  |  | allList({ | 
|---|
|  |  |  | type: 2 | 
|---|
|  |  |  | type: 2, | 
|---|
|  |  |  | companyType: 1 | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | .then(res => { | 
|---|
|  |  |  | this.memberList = res | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | .catch(e => { | 
|---|
|  |  |  | this.$tip.apiFailed(e) | 
|---|
|  |  |  | // this.$tip.apiFailed(e) | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | .finally(() => { | 
|---|
|  |  |  | this.isWorking = false | 
|---|