diff --git a/pages/published/published.vue b/pages/published/published.vue index 099a485..25ff32b 100644 --- a/pages/published/published.vue +++ b/pages/published/published.vue @@ -32,8 +32,13 @@ this.macthList = res.data.data console.log(res); }) + }, + getMyPublished(type){ + this.$api.getMyPublished(type).then(res => { + console.log(res); + console.log(type); + }) } - }, onLoad: function (option) { wx.setNavigationBarTitle({ @@ -42,16 +47,20 @@ this.titletext = option.titletext if(this.titletext == '发布的店铺转让'){ this.listId = 0 + this.getMyPublished(1) } if(this.titletext == '发布的找店选址'){ this.listId = 1 + this.getMyPublished(2) } if(this.titletext == '发布的项目招商'){ this.listId = 2 + this.getMyPublished(4) } if(this.titletext == '发布的店铺出租'){ this.listId = 3 + this.getMyPublished(3) } if(this.titletext == '我的匹配'){ this.listId = 4 diff --git a/service/request.js b/service/request.js index 94cbe1a..eb65803 100644 --- a/service/request.js +++ b/service/request.js @@ -290,6 +290,13 @@ const apiService = { return new Promise((resolve,reject) => { resolve(service.get(url)) }) + }, + //获取个人发布过的信息 + getMyPublished(type){ + const url = `/center/mypub/?type=${type}` + return new Promise((resolve,reject) => { + resolve(service.post(url)) + }) } } export {