Commit 697feb24b6c28523b20d82e83aa253f8ecc2d050

Authored by pengye
1 parent 59fe6c58

新邀请函入口页加创建邀请关系链接口、邀请函模板9修改

@@ -130,14 +130,12 @@ @@ -130,14 +130,12 @@
130 </view> 130 </view>
131 </block> 131 </block>
132 <!-- 用餐环境 --> 132 <!-- 用餐环境 -->
133 - <view class="introduce">  
134 - <block wx:if="{{store.images.length>0 && (!store.is_images || store.is_images!='0')}}">  
135 - <block wx:if="{{titleType}}">  
136 - <titleStyle titleStyleType="{{titleType}}" titleText="用餐环境"></titleStyle>  
137 - </block>  
138 - <block wx:for="{{store.images}}" wx:key="arryIndex" wx:for-index="arryIndex">  
139 - <image src="{{item}}" bindtap="lookImgs" data-url="{{item}}" data-imgs="{{store.images}}" mode="widthFix" />  
140 - </block> 133 + <view class="introduce" wx:if="{{store.images.length>0 && (!store.is_images || store.is_images!='0')}}">
  134 + <block wx:if="{{titleType}}">
  135 + <titleStyle titleStyleType="{{titleType}}" titleText="用餐环境"></titleStyle>
  136 + </block>
  137 + <block wx:for="{{store.images}}" wx:key="arryIndex" wx:for-index="arryIndex">
  138 + <image src="{{item}}" bindtap="lookImgs" data-url="{{item}}" data-imgs="{{store.images}}" mode="widthFix" />
141 </block> 139 </block>
142 </view> 140 </view>
143 <!-- 主厨介绍 --> 141 <!-- 主厨介绍 -->
@@ -24,6 +24,7 @@ Page({ @@ -24,6 +24,7 @@ Page({
24 this.setData(param) 24 this.setData(param)
25 this.getDetail() 25 this.getDetail()
26 this.setSetRelation() 26 this.setSetRelation()
  27 + this.setRelaOpenidFun()
27 }, 28 },
28 // 页面滚动事件 29 // 页面滚动事件
29 onPageScroll: function (event) {}, 30 onPageScroll: function (event) {},
@@ -49,6 +50,21 @@ Page({ @@ -49,6 +50,21 @@ Page({
49 }) 50 })
50 } 51 }
51 }, 52 },
  53 + // 创建邀请关系链
  54 + setRelaOpenidFun() {
  55 + if (this.data.options && this.data.options.id) {
  56 + let obj = {
  57 + rid: this.data.options.id,
  58 + openid: getApp().openid,
  59 + uid: this.data.options.uid,
  60 + fromid: this.data.options.fromid || ''
  61 + }
  62 + if (this.data.options.fromid) delete obj.uid
  63 + App.Reserve.SetRelaOpenid(obj).then(res => {
  64 + console.log('创建邀请关系链', res);
  65 + })
  66 + }
  67 + },
52 // 获取店铺详情 68 // 获取店铺详情
53 getDetail() { 69 getDetail() {
54 App.Reserve.Detail({ 70 App.Reserve.Detail({
@@ -182,7 +182,7 @@ Page({ @@ -182,7 +182,7 @@ Page({
182 } 182 }
183 }, 183 },
184 goHome(){ 184 goHome(){
185 - wx.switchTab({ 185 + wx.redirectTo({
186 url: '/pages/reserve/index' 186 url: '/pages/reserve/index'
187 }) 187 })
188 }, 188 },