diff --git a/pages/navigation/search/searchPage.vue b/pages/navigation/search/searchPage.vue index 12c6470..dc1aa94 100644 --- a/pages/navigation/search/searchPage.vue +++ b/pages/navigation/search/searchPage.vue @@ -700,11 +700,13 @@ export default { keyword = (this.hotKeywordList.length && this.hotKeywordList[0]) || ''; } this.defaultKeyword == '请输入搜索商品' ? (keyword = '') : ''; - // this.keyword = keyword; + + keyword ? (this.keyword = keyword) : ''; this.saveKeyword(keyword); //保存为历史 this.isShowSeachGoods = true; this.$refs.mSearch.isShowSeachGoods = true; + this.$refs.mSearch.inputVal = keyword; this.params.keyword = this.keyword; this.params.pageNumber = 1; this.$set(this.sortParams, 'keyword', keyword); diff --git a/utils/filters.js b/utils/filters.js index 2650ed1..0a27eda 100644 --- a/utils/filters.js +++ b/utils/filters.js @@ -365,8 +365,10 @@ export function quiteLoginOut () { */ export function talkIm (storeId, goodsId, id) { if (isLogin('auth')) { + let url = `/pages/mine/im/index?userId=${storeId}` + if(goodsId && id) url = `/pages/mine/im/index?userId=${storeId}&goodsid=${goodsId}&skuid=${id}` uni.navigateTo({ - url: `/pages/mine/im/index?userId=${storeId}&goodsid=${goodsId}&skuid=${id}` + url }); } else {