| | |
| | | <el-dialog |
| | | v-dialogDrag |
| | | :close-on-click-modal="false" |
| | | :destroy-on-close="true" |
| | | :title="title" |
| | | :visible.sync="visible" |
| | | width="40%" |
| | |
| | | </ul> |
| | | <Divider left="30px" text="选择文件后会自动上传"></Divider> |
| | | <el-upload |
| | | :name="fileName" |
| | | :action="fileUrl" |
| | | :before-upload="beforeUpload" |
| | | :data="fileData" |
| | |
| | | fileType: { |
| | | type: Array, |
| | | default: () => [] |
| | | }, |
| | | fileName: { |
| | | type: String, |
| | | default: () => "file" |
| | | }, |
| | | // 对话框头部名称 |
| | | title: { |
| | |
| | | }, |
| | | // 文件上传成功 |
| | | onSuccess(resbonse) { |
| | | console.log(resbonse); |
| | | if (resbonse.code === 200) { |
| | | this.$message.success("导入成功!"); |
| | | this.visible = false; |
| | | this.$emit('updata'); |
| | | this.$emit('updata',resbonse); |
| | | } else { |
| | | this.$message.error(resbonse.msg); |
| | | } |