|
@@ -1,4 +1,4 @@
|
|
-import { computed, reactive, ref, toRefs, onMounted, onBeforeUnmount, getCurrentInstance } from 'vue'
|
|
|
|
|
|
+import { computed, reactive, ref, toRefs, onMounted,onBeforeMount, onBeforeUnmount, getCurrentInstance } from 'vue'
|
|
import { without, throttle } from 'lodash'
|
|
import { without, throttle } from 'lodash'
|
|
import { useStore } from '@/store'
|
|
import { useStore } from '@/store'
|
|
import { useRoute, useRouter } from 'vue-router/composables'
|
|
import { useRoute, useRouter } from 'vue-router/composables'
|
|
@@ -182,14 +182,19 @@ export default function () {
|
|
/**
|
|
/**
|
|
* 搜索前校验
|
|
* 搜索前校验
|
|
*/
|
|
*/
|
|
|
|
+ const { keywords: urlKeywords } = useRoute().query
|
|
const {
|
|
const {
|
|
getWhiteList,
|
|
getWhiteList,
|
|
onTheWhiteList,
|
|
onTheWhiteList,
|
|
checkAndClearTextIncludesCommonWords
|
|
checkAndClearTextIncludesCommonWords
|
|
- } = beforeSearchModel({ inputKeywordsState })
|
|
|
|
|
|
+ } = beforeSearchModel({ inputKeywordsState, urlKeywords })
|
|
|
|
|
|
- onMounted(async () => {
|
|
|
|
- await getWhiteList()
|
|
|
|
|
|
+ onBeforeMount( async() => {
|
|
|
|
+ try{
|
|
|
|
+ await getWhiteList()
|
|
|
|
+ } catch (e){
|
|
|
|
+ console.warn('e')
|
|
|
|
+ }
|
|
})
|
|
})
|
|
|
|
|
|
/**
|
|
/**
|