| | |
| | | data() { |
| | | return { |
| | | id: 0, |
| | | baseUrl: '', |
| | | cstmr: {}, |
| | | cstmr: { |
| | | id: '', |
| | | name: '', |
| | | tel: '', |
| | | addr: '', |
| | | cstman: '' |
| | | }, |
| | | addFollower: { |
| | | follower: '', |
| | | followers: '', |
| | |
| | | }, |
| | | onLoad(option) { |
| | | this.id = option.id |
| | | this.baseUrl = uni.getStorageSync('baseUrl') |
| | | this.init() |
| | | this.autoLoad('follower','') |
| | | setTimeout(()=>{ |
| | | this.getFollowers() |
| | | },500) |
| | | |
| | | |
| | | }, |
| | | methods: { |
| | | init() { |
| | |
| | | data: {ids: ids}, |
| | | method: 'POST', |
| | | success(res) { |
| | | console.log(res); |
| | | res = res.data |
| | | if (res.code === 200) { |
| | | uni.navigateBack() |
| | |
| | | success(result) { |
| | | var res = result.data |
| | | that.getFollowers() |
| | | console.log(res); |
| | | } |
| | | }) |
| | | this.addFollower.follower = '' |
| | |
| | | method: 'POST', |
| | | success(result) { |
| | | var res = result.data |
| | | console.log(res); |
| | | if (res.code === 200) { |
| | | var element; |
| | | if (type == 'follower') { |
| | |
| | | }, |
| | | removeFollowers(userId) { |
| | | let that = this |
| | | console.log(that.cstmrId); |
| | | uni.request({ |
| | | url: that.baseUrl + '/cstmr/followers/remove/auth', |
| | | header:{ |
| | |
| | | success(res) { |
| | | res = res.data |
| | | that.getFollowers() |
| | | console.log(res); |
| | | } |
| | | }) |
| | | } |