add EquipmentDrawer

This commit is contained in:
lb
2023-08-22 15:53:02 +08:00
parent 1b055ebfa4
commit 4eb9b321db
5 changed files with 380 additions and 15 deletions

View File

@@ -44,6 +44,7 @@
v-model="form[col.prop]"
type="datetime"
:placeholder="`请选择${col.label}`"
value-format="timestamp"
v-bind="col.bind"></el-date-picker>
<el-upload
class="upload-in-dialog"
@@ -215,13 +216,14 @@ export default {
if (!promiseList.length) this.formLoading = false;
},
// 上传成功的特殊处理
beforeUpload(){},
// 上传前的验证规则可通过 bind 属性传入
handleUploadSuccess(response, file, fileList) {
console.log('[dialogForm:handleUploadSuccess]', response, file, fileList, this.form);
// 保存原始文件名
if ('fileNames' in this.form) this.form.fileNames.push(file.name);
// 保存完整地址
if ('fileUrls' in this.form) this.form.fileUrls.push(response.data);
// console.log('[dialogForm:handleUploadSuccess]', response, file, fileList, this.form);
this.$modal.msgSuccess('上传成功');
},