| | |
| | | } |
| | | }, |
| | | methods: { |
| | | handleSubmit(){ |
| | | handleSubmit(row,done){ |
| | | if (this.form.id){ |
| | | update(this.form).then(res=>{ |
| | | if (res.data.code == 200){ |
| | |
| | | }else { |
| | | this.$message.error(res.data.msg) |
| | | } |
| | | done() |
| | | }) |
| | | }else { |
| | | this.form.userId = this.userInfo.user_id |
| | | add(this.form).then(res=>{ |
| | | if (res.data.code == 200){ |
| | | this.$message.success(res.data.msg) |
| | | }else { |
| | | this.$message.error(res.data.msg) |
| | | } |
| | | done() |
| | | }) |
| | | } |
| | | }, |
| | |
| | | getEnterpriseDetailByUserId(){ |
| | | getDetailByUserId(this.userInfo.user_id).then(res=>{ |
| | | if (res.data.code == 200){ |
| | | if (res.data.data && !this.permit){ |
| | | if (JSON.stringify(res.data.data) == '{}' && !this.permit){ |
| | | this.$alert('请先完善企业信息', '提示', { |
| | | confirmButtonText: '确定', |
| | | callback: ()=>{ |