Correct writing: use async before valid
/**Submit*/
handleSubmit() {
this.$refs["form"].validate(async valid => {
if (valid) {
await this.handleUploadFile();
}
ApiUpdateOrganBrand(this.form).then(res => {
console.log(res);
this.$message.success("Brand configuration success");
this.handleClose();
});
});
},
I started by writing async in front of handle submit, reporting the unexpected reserved word ‘await’