2 Commits ce68dcd7f9 ... 9e942dd20a

Author SHA1 Message Date
  danch 9e942dd20a Merge remote-tracking branch 'origin/dev' into dev 2 weeks ago
  danch eddde3a182 用户管理-查询方案删除,未同步删除查询方案内容问题 2 weeks ago

+ 8 - 2
jeecgboot-vue3/src/components/Lttc/BaseService/LTTCBaseServiceAdvancedSearch.vue

@@ -6,7 +6,8 @@
         高级查询方案:
         <a-tooltip placement="top" v-for="(item, index) in savedQueries.slice(0, visibleCount)">
           <template #title>
-            <span>双击取消查询 |<a-button type="link" @click.stop="() =>  handleDrawDelete(item.id)" danger>删除方案</a-button></span>
+            <span>双击取消查询 |<a-button type="link" @click.stop="() =>  handleDrawDelete(item.id)"
+                                          danger>删除方案</a-button></span>
           </template>
           <a-button :type="isActive(index) ? 'primary' : 'link'"
                     :key="index" @click.stop="() => handleQueryNameClick(index,item)"
@@ -196,10 +197,13 @@ const quickQuery = () => {
  * 重置高级查询方案
  */
 const resetQuery = () => {
+  // 选中的按钮取消
   activeIndex.value = null
+  // 查询条件取消
   queries.value = [{column: '', condition: 'like', term: '', mode: 'and'}];
   console.log("props.rawData");
   console.log(props.rawData);
+  // 返回查询数据喝状态
   emit('update:searchedDataReset');
   emit('update:searchedData', resetData.value);
 
@@ -229,7 +233,7 @@ const modeOptions = ref([
 ]);
 
 // 查询条件数组
-const queries = ref([{column: '', condition: 'like', term: '', mode: 'and'}]);
+const queries = ref<any>([{column: '', condition: 'like', term: '', mode: 'and'}]);
 
 // 保存的查询条件
 const savedQueries = ref([]); // 这里存储保存的查询条件
@@ -516,6 +520,8 @@ const handleCancel = () => {
  */
 const deleteQuery = (id: any) => {
   savedQueries.value = savedQueries.value.filter(item => item.id !== id);
+  // 重新加载默认查询方案数据
+  resetQuery();
 }
 /**
  * 后端删除高级查询记录