91fef325 by xukangle

fix : 分类分级搜索

1 parent 7364348a
...@@ -239,9 +239,8 @@ const toSearch = (val: any, clear: boolean = false) => { ...@@ -239,9 +239,8 @@ const toSearch = (val: any, clear: boolean = false) => {
239 pageIndex: 1, 239 pageIndex: 1,
240 pageSize: 50, 240 pageSize: 50,
241 execGuid: execGuidInfo.value.execGuid, 241 execGuid: execGuidInfo.value.execGuid,
242 database: selectedA.value || '', 242 tableGuid: selectedB.value || '',
243 tableName: selectedB.value || '', 243 databaseGuid: selectedA.value || '',
244 fieldName: selectedC.value || '',
245 classifyDetailGuid: val.classifyName, 244 classifyDetailGuid: val.classifyName,
246 gradeDetailGuid: val.levelName, 245 gradeDetailGuid: val.levelName,
247 labelGuid: val.labelName, 246 labelGuid: val.labelName,
...@@ -252,8 +251,9 @@ const toSearch = (val: any, clear: boolean = false) => { ...@@ -252,8 +251,9 @@ const toSearch = (val: any, clear: boolean = false) => {
252 pageIndex: 1, 251 pageIndex: 1,
253 pageSize: 50, 252 pageSize: 50,
254 execGuid: execGuidInfo.value.execGuid, 253 execGuid: execGuidInfo.value.execGuid,
255 database: selectedA.value || '', 254 tableGuid: selectedB.value || '',
256 fieldName: selectedB.value || '', 255 databaseGuid: selectedA.value || '',
256 fieldGuid: selectedC.value || '',
257 classifyDetailGuid: val.classifyName, 257 classifyDetailGuid: val.classifyName,
258 gradeDetailGuid: val.levelName, 258 gradeDetailGuid: val.levelName,
259 labelGuid: val.labelName, 259 labelGuid: val.labelName,
...@@ -893,13 +893,11 @@ const getDataBaseTableData = async (params = {}) => { ...@@ -893,13 +893,11 @@ const getDataBaseTableData = async (params = {}) => {
893 const dataBaseParams = { 893 const dataBaseParams = {
894 pageIndex: dataBasePage.value.curr, 894 pageIndex: dataBasePage.value.curr,
895 pageSize: dataBasePage.value.limit, 895 pageSize: dataBasePage.value.limit,
896 tableGuid: tableGuid.value,
897 databaseGuid: dataBaseGuid.value,
898 isDataAsset: '', 896 isDataAsset: '',
899 execGuid: execGuidInfo.value.execGuid, 897 execGuid: execGuidInfo.value.execGuid,
900 tableName: "", 898 tableGuid: tableGuid.value,
901 database: "", 899 databaseGuid: dataBaseGuid.value,
902 fieldName: "", 900 fieldGuid: "",
903 labelGuid: "", 901 labelGuid: "",
904 classifyDetailGuid: "", 902 classifyDetailGuid: "",
905 gradeDetailGuid: "" 903 gradeDetailGuid: ""
...@@ -946,12 +944,10 @@ const getDataBaseFieldData = async (params = {}) => { ...@@ -946,12 +944,10 @@ const getDataBaseFieldData = async (params = {}) => {
946 const dataBaseParams = { 944 const dataBaseParams = {
947 pageIndex: dataFieldPage.value.curr, 945 pageIndex: dataFieldPage.value.curr,
948 pageSize: dataFieldPage.value.limit, 946 pageSize: dataFieldPage.value.limit,
949 tableGuid: "",
950 databaseGuid: "",
951 execGuid: execGuidInfo.value.execGuid, 947 execGuid: execGuidInfo.value.execGuid,
952 tableName: "", 948 tableGuid: tableGuid.value || '',
953 database: "", 949 databaseGuid: dataBaseGuid.value || '',
954 fieldName: "", 950 fieldGuid: "",
955 labelGuid: "", 951 labelGuid: "",
956 classifyDetailGuid: "", 952 classifyDetailGuid: "",
957 gradeDetailGuid: "" 953 gradeDetailGuid: ""
...@@ -1245,8 +1241,6 @@ const onAChange = async () => { ...@@ -1245,8 +1241,6 @@ const onAChange = async () => {
1245 await getSearchTableList(2, selectedA.value); // 分类分级搜索 1241 await getSearchTableList(2, selectedA.value); // 分类分级搜索
1246 } 1242 }
1247 if (activeName.value == 'second') { 1243 if (activeName.value == 'second') {
1248 console.log('onAChange', optionsA.value);
1249
1250 if (activeTab.value === 'word') { 1244 if (activeTab.value === 'word') {
1251 await getDbDirFieldSelectData(2, { databaseGuid: selectedA.value, condition: "2" }); 1245 await getDbDirFieldSelectData(2, { databaseGuid: selectedA.value, condition: "2" });
1252 } else { 1246 } else {
...@@ -1269,8 +1263,6 @@ const onBChange = async () => { ...@@ -1269,8 +1263,6 @@ const onBChange = async () => {
1269 if (activeName.value == 'second') { 1263 if (activeName.value == 'second') {
1270 if (activeTab.value === 'word') { 1264 if (activeTab.value === 'word') {
1271 await getDbDirFieldSelectData(3, { tableGuid: selectedB.value, databaseGuid: selectedA.value, condition: "3" }); 1265 await getDbDirFieldSelectData(3, { tableGuid: selectedB.value, databaseGuid: selectedA.value, condition: "3" });
1272 } else {
1273 await getDbDirTableSelectData(3, { tableGuid: selectedB.value, databaseGuid: selectedA.value, condition: "3" }); // 数据库搜索
1274 } 1266 }
1275 } 1267 }
1276 }; 1268 };
...@@ -1340,7 +1332,7 @@ onActivated(async () => { ...@@ -1340,7 +1332,7 @@ onActivated(async () => {
1340 <el-option v-for="item in optionsB" :key="item.dbGuid" :label="item.name" :value="item.dbGuid" /> 1332 <el-option v-for="item in optionsB" :key="item.dbGuid" :label="item.name" :value="item.dbGuid" />
1341 </el-select> 1333 </el-select>
1342 <el-select v-model="selectedC" placeholder="选择字段名" :disabled="!selectedB" style="width: 140px;margin-right: 8px" 1334 <el-select v-model="selectedC" placeholder="选择字段名" :disabled="!selectedB" style="width: 140px;margin-right: 8px"
1343 :clearable="true"> 1335 :clearable="true" v-if="!isShowWordSearch">
1344 <el-option v-for="item in optionsC" :key="item.dbGuid" :label="item.name" :value="item.dbGuid" /> 1336 <el-option v-for="item in optionsC" :key="item.dbGuid" :label="item.name" :value="item.dbGuid" />
1345 </el-select> 1337 </el-select>
1346 <TableTools :searchItems="searchItemList" :init="false" :searchId="'files-standard-search'" @search="toSearch" 1338 <TableTools :searchItems="searchItemList" :init="false" :searchId="'files-standard-search'" @search="toSearch"
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!