Commit 11cd21ff by 胡悦

提交案例视频

1 parent eb673129
......@@ -182,7 +182,8 @@ export default {
this.name = e.detail.value
if (this.name == '')
this.isSearch = false
this.list = this.searchList.filter(i => i.name.includes(this.name))
// this.list = this.searchList.filter(i => i.name.includes(this.name))
this.getCaseList(this.selectIndex == '全部' ? '' : this.selectIndex, this.name)
},
selectType() {
this.isSelect = !this.isSelect
......@@ -191,12 +192,12 @@ export default {
console.log(val)
this.selectIndex = val.value
this.isSelect = false
this.getCaseList(this.selectIndex == '全部' ? '' : this.selectIndex)
this.getCaseList(this.selectIndex == '全部' ? '' : this.selectIndex, this.name)
},
async getCaseList(category = '') {
async getCaseList(category = '', name = '') {
const userInfo = uni.$storage.get("userInfo"),
{ shopMerchantId } = userInfo;
const res = await uni.$api.boutiqueApi.getCaseList({merchantId: 44217687, category})
{ shopMerchantId } = userInfo; // 44217687
const res = await uni.$api.boutiqueApi.getCaseList({merchantId: shopMerchantId, category, name})
console.log(res)
this.list = res.list
this.searchList = res.list
......@@ -204,7 +205,7 @@ export default {
async getCategory() {
const userInfo = uni.$storage.get("userInfo"),
{ shopMerchantId } = userInfo;
const res = await uni.$api.boutiqueApi.getCategory({ merchantId: 44217687 })
const res = await uni.$api.boutiqueApi.getCategory({ merchantId: shopMerchantId })
console.log(res)
const _list = res.map(item => {
return {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!