diff --git a/src/components/customSearch.vue b/src/components/customSearch.vue index 540300d..28ad531 100644 --- a/src/components/customSearch.vue +++ b/src/components/customSearch.vue @@ -68,7 +68,7 @@ const props = defineProps({ searchKeywords:{//搜索文本 type:String }, - searchType:{//哪种类型显示对象 + searchType:{//哪种类型显示对象 typeId:1-首页,2-业务首页,3-消息 之后可以自动添加 type:Object }, searchTypeList:{//类型列表 @@ -111,7 +111,7 @@ const emit = defineEmits(['confirm']); // 加载历史记录 const loadHistory = () => { - let typeId = props.searchType.typeId + let typeId = props.searchType?props.searchType.typeId:undefined const history = uni.getStorageSync('searchHistory'+typeId) || [] historyList.value = history } diff --git a/src/pages/business/business.vue b/src/pages/business/business.vue index 6b1d7ed..2d2aede 100644 --- a/src/pages/business/business.vue +++ b/src/pages/business/business.vue @@ -3,23 +3,33 @@ + - + + - @@ -59,7 +69,8 @@