| | |
| | | import searchShopList from '@/components/searchShopList.vue' |
| | | import { categoryList, goodsList, brandList, h5Image, logout, getByLoginNew, listForH5 } from '@/apis/index.js' |
| | | import { ANCHOR_PAGE_V3, getAnchorHomePath, normalizeAnchorPageVersion } from '@/utils/anchorHome.js' |
| | | import { matchKeyword } from '@/utils/goodsFilter.js' |
| | | import { mapState } from 'vuex' |
| | | export default { |
| | | data() { |
| | |
| | | |
| | | title: '', |
| | | fontColor: 'rgba(255, 220, 108, 1)', |
| | | fontColorIndex: '' |
| | | fontColorIndex: '', |
| | | configuration: null |
| | | } |
| | | }, |
| | | components: { bigImg, search, searchShopList }, |
| | |
| | | }, |
| | | // 已选商品列表搜索品牌 |
| | | searchBrand(e, item) { |
| | | item.brandSearchList = item.brandList.filter(item => { |
| | | if (item.name.indexOf(e.detail.value) > -1) { |
| | | return item |
| | | } |
| | | }) |
| | | item.brandSearchList = item.brandList.filter(brand => matchKeyword(brand, e.detail.value)) |
| | | this.$forceUpdate() |
| | | }, |
| | | // 已选商品列表搜索型号 |
| | | searchModel(e, item) { |
| | | item.modelSearchList = item.xhData.filter(item => { |
| | | if (item.name.indexOf(e.detail.value) !== -1) { |
| | | return item |
| | | } |
| | | }) |
| | | item.modelSearchList = item.xhData.filter(goods => matchKeyword(goods, e.detail.value)) |
| | | this.$forceUpdate() |
| | | }, |
| | | // 获取搜索的标题 |