diff --git a/src/views/vi/testProject/plan/setting.vue b/src/views/vi/testProject/plan/setting.vue index ac2f05e..156f12f 100644 --- a/src/views/vi/testProject/plan/setting.vue +++ b/src/views/vi/testProject/plan/setting.vue @@ -22,6 +22,27 @@ + + + + + + 搜索 + 重置 + + { } }; +const queryParams = ref({ + pageNum: 1, + pageSize: 100000, + type: "TEST", + corpusName: '', + continuous: 1 +}) const getList = () => { if (props.type === "1") { - listCorpus({ - pageNum: 1, - pageSize: 100000, - type: "TEST", - continuous: 1, - }) + queryParams.value.continuous = 1 + listCorpus(queryParams.value) .then((response) => { corpusList.value = response.rows; }) .catch((err) => {}); } else { - getBatchCorpus({ - pageNum: 1, - pageSize: 100000, - type: "TEST", - continuous: 0, - }) + queryParams.value.continuous = 0 + getBatchCorpus(queryParams.value) .then((response) => { corpusList.value = response.rows; }) .catch((err) => {}); } }; + +const resetForm = () => { + queryParams.value.corpusName = '' + getList() +} + const tableRef = ref(); const submitForm = () => { const rows = tableRef.value.getSelectionRows(); selectList.value = rows; open.value = false; emits("updateSelectRows", rows); + resetForm() }; const cancel = () => { open.value = false; + resetForm() }; const getSelectList = (corpusIds) => {