fix(DictData): 字典数据弹窗切换数据未刷新问题修复

Former-commit-id: dba95fac120486fe114a3500c1c4f60d4bc2905b
This commit is contained in:
haoxr
2023-03-14 21:57:25 +08:00
parent 830ec3e2c0
commit ec9c48a71e

View File

@@ -30,6 +30,14 @@ const props = defineProps({
}
});
watch(
() => props.typeCode,
(newVal: string) => {
queryParams.typeCode = newVal;
resetQuery();
}
);
const queryFormRef = ref(ElForm);
const dataFormRef = ref(ElForm);
@@ -80,6 +88,7 @@ function handleQuery() {
*/
function resetQuery() {
queryFormRef.value.resetFields();
queryParams.pageNum = 1;
handleQuery();
}