Ver código fonte

Merge branch 'dev/1.0.36_zsy' of jianyu/web into feature/v1.0.36

zhangsiya 1 ano atrás
pai
commit
06de643646

+ 2 - 1
apps/bigmember_pc/src/views/search/bidding/components/search-bid-header.vue

@@ -52,8 +52,9 @@ function goToPublish () {
 function checkPower ($event) {
   if(!isLogin.value) {
     $bus.$emit('bidding:goLogin')
+    return false
   } else {
-    return doSearch($event)
+    return true
   }
 }
 // 未登录--多个关键词切换处理

+ 16 - 11
apps/bigmember_pc/src/views/search/bidding/model/base.js

@@ -86,9 +86,7 @@ export default function () {
   const cookieInfo = document.cookie.split('; ')
   cooperateCode.value = cookieInfo.some(item => item.indexOf('channelCode') > -1)
   onMounted(() => {
-    that.$nextTick(function() {
-      window.addEventListener('scroll', watchScroll)
-    })
+    window.addEventListener('scroll', watchScroll)
   })
 
   // 物业专版
@@ -165,13 +163,6 @@ export default function () {
     getFormatAPIParams: getFormatOfFilter,
     updateFilterBase
   } = useSearchFilterModel({ inBIPropertyIframe, isFree, isInApp, isBidField })
-  /**
-   * 搜索前校验
-   */
-  const {
-    onTheWhiteList,
-    checkAndClearTextIncludesCommonWords
-  } = beforeSearchModel({ inputKeywordsState })
   /**
    * 列表头操作
    */
@@ -188,6 +179,19 @@ export default function () {
     updateInputKeywordsState(obj)
   })
 
+  /**
+   * 搜索前校验
+   */
+  const {
+    getWhiteList,
+    onTheWhiteList,
+    checkAndClearTextIncludesCommonWords
+  } = beforeSearchModel({ inputKeywordsState })
+
+  onMounted(async () => {
+    await getWhiteList()
+  })
+
   /**
    * 页面tab切换Model
    */
@@ -1479,6 +1483,7 @@ export default function () {
     getLastFilter,
     toggleBlurModeTip,
     doToggleSearchBlurMode,
-    recommendCardCircleModel
+    recommendCardCircleModel,
+    getWhiteList
   }
 }

+ 1 - 1
apps/bigmember_pc/src/views/search/bidding/model/modules/before-search.js

@@ -40,7 +40,6 @@ export function beforeSearchModel (paramsObj = { }) {
       }
     }
   }
-  getWhiteList()
 
   // 判断文字中是否有通用词(返回true表示text是通用词)
   // (关键词不为空时,判断是否包含通用词)
@@ -90,6 +89,7 @@ export function beforeSearchModel (paramsObj = { }) {
   }
 
   return {
+    getWhiteList,
     onTheWhiteList,
     checkAndClearTextIncludesCommonWords
   }