Browse Source

完善验证

dev
qb 3 weeks ago
parent
commit
05aea9c622
  1. 11
      src/views/resource/oss.vue

11
src/views/resource/oss.vue

@ -100,7 +100,7 @@
v-model="details.popUpShow.add"
>
<div class="el-dialog-add">
<el-form :inline="true" :model="details.form" label-width="100px">
<el-form ref="formRef" :inline="true" :model="details.form" label-width="100px">
<el-form-item
v-for="item in details.addFormOption"
:key="item.prop"
@ -163,7 +163,7 @@
</el-button>
<el-button type="primary" icon="Position" @click="handleSubmitAdd">
</el-button>
</div>
</div>
@ -274,6 +274,7 @@ console.log('$store.state.permission :>> ', $store.state);
//
const tableNodeRef = ref();
const formRef = ref();
const details = reactive<any>({
/** 是否开启搜索 */
@ -592,7 +593,10 @@ const handleEdit = row => {
};
/** 新增提交 */
const handleSubmitAdd = async () => {
const handleSubmitAdd = () => {
formRef.value.validate(async valid => {
if (!valid) return;
try {
details.loadingObj.pageLoading = true;
@ -611,6 +615,7 @@ const handleSubmitAdd = async () => {
} finally {
details.loadingObj.pageLoading = false;
}
});
};
/** 删除提交 */

Loading…
Cancel
Save