jufubao-base 1.0.232-beta4 → 1.0.232-beta6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (46) hide show
  1. package/package.json +1 -1
  2. package/src/components/JfbBaseBalance/Api.js +18 -30
  3. package/src/components/JfbBaseBalance/Attr.js +292 -24
  4. package/src/components/JfbBaseBalance/JfbBaseBalance.vue +250 -32
  5. package/src/components/JfbBaseCodeOpenVip/Api.js +17 -39
  6. package/src/components/JfbBaseCodeOpenVip/Attr.js +19 -0
  7. package/src/components/JfbBaseCodeOpenVip/JfbBaseCodeOpenVip.vue +54 -25
  8. package/src/components/JfbBaseConsumpCode/JfbBaseConsumpCode.vue +2 -2
  9. package/src/components/JfbBaseOpenVip/Api.js +11 -40
  10. package/src/components/JfbBaseOpenVip/Attr.js +4 -4
  11. package/src/components/JfbBaseOpenVip/JfbBaseOpenVip.vue +69 -26
  12. package/src/components/JfbBaseOpenVip/Mock.js +16 -9
  13. package/src/components/JfbBaseOpenVip/XdVipList.vue +44 -6
  14. package/src/components/JfbBaseOpenVipDetail/Api.js +17 -39
  15. package/src/components/JfbBaseOpenVipDetail/Attr.js +16 -27
  16. package/src/components/JfbBaseOpenVipDetail/JfbBaseOpenVipDetail.vue +110 -25
  17. package/src/components/JfbBasePersonalData/Api.js +9 -41
  18. package/src/components/JfbBasePersonalData/Attr.js +1 -37
  19. package/src/components/JfbBasePersonalData/JfbBasePersonalData.vue +119 -32
  20. package/src/components/JfbBasePointsCard/Api.js +4 -44
  21. package/src/components/JfbBasePointsCard/Attr.js +0 -48
  22. package/src/components/JfbBasePointsCard/JfbBasePointsCard.vue +24 -107
  23. package/src/components/JfbBasePointsCard/Mock.js +1 -9
  24. package/src/components/JfbBasePointsDetail/Api.js +25 -0
  25. package/src/components/JfbBasePointsDetail/JfbBasePointsDetail.vue +65 -20
  26. package/src/components/JfbBasePointsDetail/Mock.js +2 -8
  27. package/src/components/JfbBaseSavingDetail/Api.js +12 -29
  28. package/src/components/JfbBaseSavingDetail/Attr.js +44 -22
  29. package/src/components/JfbBaseSavingDetail/JfbBaseSavingDetail.vue +593 -29
  30. package/src/components/JfbBaseSavingDetail/components/echarts.min.js +26 -0
  31. package/src/components/JfbBaseSavingDetail/components/echarts.vue +254 -0
  32. package/src/components/JfbBaseSavingDetail/components/wx-canvas.js +105 -0
  33. package/src/components/JfbBaseShare/Api.js +5 -43
  34. package/src/components/JfbBaseShare/JfbBaseShare.vue +14 -13
  35. package/src/components/JfbBaseTfkSearch/ContentProduct.vue +1 -20
  36. package/src/components/JfbBaseTfkSearch/JfbBaseTfkSearch.vue +5 -0
  37. package/src/components/JfbBaseUserInfo/JfbBaseUserInfo.vue +6 -2
  38. package/src/components/JfbBaseWithDrawAgain/Api.js +13 -30
  39. package/src/components/JfbBaseWithDrawAgain/Attr.js +70 -26
  40. package/src/components/JfbBaseWithDrawAgain/JfbBaseWithDrawAgain.vue +255 -32
  41. package/src/components/JfbBaseWithDrawRecord/Api.js +4 -43
  42. package/src/components/JfbBaseWithDrawRecord/Attr.js +56 -25
  43. package/src/components/JfbBaseWithDrawRecord/JfbBaseWithDrawRecord.vue +151 -34
  44. package/src/components/JfbBaseWithdraw/Api.js +20 -30
  45. package/src/components/JfbBaseWithdraw/Attr.js +304 -24
  46. package/src/components/JfbBaseWithdraw/JfbBaseWithdraw.vue +166 -32
@@ -233,12 +233,12 @@ export default {
233
233
  notice: '',
234
234
  },
235
235
  {
236
- label: '支付跳转路径:',
236
+ label: '会员详情路径:',
237
237
  ele: 'xd-select-pages-path',
238
- valueKey: 'payPath',
238
+ valueKey: 'vipDetailPath',
239
239
  groupKey:'advanced',
240
- placeholder: '请选择支付跳转路径',
241
- value: data['payPath'] || null,
240
+ placeholder: '请选择会员详情路径',
241
+ value: data['vipDetailPath'] || null,
242
242
  setting: {
243
243
  router: XdBus.getParentApi('getPagesTree'),
244
244
  },
@@ -16,15 +16,18 @@
16
16
  <view class="jfb-base-open-vip__body" :style="[bodyStyle]">
17
17
  <!-- 用户信息 -->
18
18
  <view class="u_header">
19
- <view class="u_avatar"></view>
19
+ <view class="u_avatar">
20
+ <image :src="uInfo.head_url" mode="aspectFill"></image>
21
+ </view>
20
22
  <view class="u_info">
21
23
  <view class="u_info-top">
22
- <view class="vip_name">黑白灰</view>
23
- <view v-if="0" class="vip_level">普通用户</view>
24
- <view v-else class="vip_level plus">PLUS会员</view>
24
+ <view class="vip_name">{{ uInfo.show_user_name }}</view>
25
+ <view v-if="isVip" class="vip_level plus">PLUS会员</view>
26
+ <view v-else class="vip_level">普通用户</view>
25
27
  </view>
26
28
  <view class="u_sub">
27
- <view>138****7353</view>
29
+ <view v-if="isVip">已省xx</view>
30
+ <view v-else>{{ uInfo.phone_number }}</view>
28
31
  </view>
29
32
  </view>
30
33
  <view class="buy_btn" @click="showDrawer=true">立即续费</view>
@@ -37,7 +40,9 @@
37
40
  <view class="vip_box-title">PLUS会员</view>
38
41
  <view>开通享受更多权益</view>
39
42
  </view>
40
- <view class="vip_logo"></view>
43
+ <view class="vip_logo">
44
+ <image :src="siteLogo" mode="aspectFill"></image>
45
+ </view>
41
46
  </view>
42
47
  <view class="vip_banner">
43
48
  <view class="banner_item" v-for="i in 4" :key="i">
@@ -61,12 +66,18 @@
61
66
  </view>
62
67
  </view>
63
68
  </view>
64
-
65
- <xd-vip-list @handlePrivacy="handlePrivacy"></xd-vip-list>
69
+
70
+ <xd-vip-list :list="vipCardList"
71
+ @handlePrivacy="handlePrivacy"
72
+ @toVipDetail="toVipDetail"
73
+ ></xd-vip-list>
66
74
 
67
75
  <xd-down-drawer :show.sync="showDrawer" height="480rpx">
68
76
  <view class="drawer_title">立即续费</view>
69
- <xd-vip-list @handlePrivacy="handlePrivacy"></xd-vip-list>
77
+ <xd-vip-list :list="vipCardList"
78
+ @handlePrivacy="handlePrivacy"
79
+ @toVipDetail="toVipDetail"
80
+ ></xd-vip-list>
70
81
  </xd-down-drawer>
71
82
 
72
83
  </view>
@@ -83,6 +94,7 @@
83
94
  import { getContainerPropsValue } from "@/utils/xd.base";
84
95
  import componentsMixins from "@/mixins/componentsMixins";
85
96
  import extsMixins from "@/mixins/extsMixins";
97
+ import getServiceUrl from "@/common/getServiceUrl"
86
98
 
87
99
  export default {
88
100
  name: "JfbBaseOpenVip",
@@ -97,11 +109,16 @@
97
109
  ],
98
110
  data() {
99
111
  return {
100
- //hideMask: true,
112
+ closeMask: true,
101
113
 
102
114
  showDrawer: false,
115
+ uInfo: {},
116
+ xnamespace: "",
117
+ vipCardList: [],
118
+
119
+ siteLogo: "",
103
120
  //todo
104
- payPath: "",
121
+ vipDetailPath: "",
105
122
  }
106
123
  },
107
124
  computed: {
@@ -110,6 +127,9 @@
110
127
  minHeight: this.layoutInfo.bodyMinHeightRpx + "rpx",
111
128
  '--main-color': this.mainColor
112
129
  }
130
+ },
131
+ isVip(){
132
+ return this.uInfo.user_level === 'VIP';
113
133
  }
114
134
  },
115
135
  watch: {
@@ -120,28 +140,39 @@
120
140
  },
121
141
  created() {
122
142
  this.init(this.container);
123
-
143
+ this.siteLogo = getServiceUrl(this.projectAttr['site_logo']);
124
144
  //todo
125
145
  },
126
146
  methods: {
127
147
  onJfbLoad(options) {
128
-
129
- // jfbRootExec('baiduUserLogin', {
130
-
131
- // vm: this,// data: {
132
-
133
- // account: 'gaoshiyong',// password: '123456789',// type: 3,// ...options
134
-
135
- // }
136
-
137
- // }).then().catch()
148
+ this.setNameSpace(options);
149
+ this.p_getBaseUserInfo();
150
+ this.p_getVipList();
138
151
  },
139
152
  /**
140
153
  * @description 监听事件变化
141
154
  * @param container {object} 业务组件对象自己
142
155
  */
143
156
  init(container) {
144
- this.payPath = getContainerPropsValue(container, 'content.payPath', {value: ""}).value;
157
+ this.vipDetailPath = getContainerPropsValue(container, 'content.vipDetailPath', {value: "/system/system/vipdetail"}).value;
158
+ },
159
+ p_getBaseUserInfo(){
160
+ jfbRootExec("getBaseUserInfo", {
161
+ vm: this,
162
+ data: {}
163
+ }).then(res => {
164
+ this.uInfo = res;
165
+ })
166
+ },
167
+ p_getVipList(){
168
+ jfbRootExec("getVipList", {
169
+ vm: this,
170
+ data: {
171
+ namespace: this.xnamespace,
172
+ }
173
+ }).then(res => {
174
+ this.vipCardList = res.list;
175
+ })
145
176
  },
146
177
  handlePrivacy(code){
147
178
  let params = `page_id=${this.pageAttr["page_id"]}`;
@@ -150,8 +181,13 @@
150
181
  url: `/pages/content/content?${params}`
151
182
  })
152
183
  },
184
+ toVipDetail(vip_card_id){
185
+ this.$xdUniHelper.navigateTo({
186
+ url: `${this.vipDetailPath}?vip_card_id=${vip_card_id}`
187
+ })
188
+ },
153
189
  onJfbScroll(options) {
154
- console.log('event.onJfbScroll', options)
190
+ // console.log('event.onJfbScroll', options)
155
191
  },
156
192
  onJfbReachBottom(options) {
157
193
  console.log('event.onJfbReachBottom', options)
@@ -190,9 +226,13 @@
190
226
  .u_avatar{
191
227
  width: 120rpx;
192
228
  height: 120rpx;
193
- background-color: #f00;
194
229
  border-radius: 120rpx;
195
230
  margin-right: 24rpx;
231
+ overflow: hidden;
232
+ image{
233
+ width: 100%;
234
+ height: 100%;
235
+ }
196
236
  }
197
237
  .u_info{
198
238
  flex:1;
@@ -261,7 +301,10 @@
261
301
  .vip_logo{
262
302
  width: 104rpx;
263
303
  height: 104rpx;
264
- background-color: #E8A841;
304
+ image{
305
+ width: 100%;
306
+ height: 100%;
307
+ }
265
308
  }
266
309
  }
267
310
 
@@ -1,13 +1,20 @@
1
1
  'use strict';
2
2
 
3
3
  module.exports = {
4
-
5
- getOpenByIdFilmSquate:{},
6
-
7
- updateOpenFilmPaiqiDate:{},
8
-
9
- removeOpenFilmAddress:{},
10
-
11
- addOpenFilmcart:{},
12
-
4
+ getBaseUserInfo: {
5
+ "user_name": "15801505541",
6
+ "user_code": "97SJSG667V",
7
+ "nickname": "草鸡无敌飞侠",
8
+ "real_name": "",
9
+ "head_url": "https://sandbox-img.jufubao.cn//uploads/20230217/dc6f1817ae3714814328fcff55925d00.jpg?x-oss-process=style/size8",
10
+ "province_code": "",
11
+ "city_code": "",
12
+ "province_name": "",
13
+ "city_name": "",
14
+ "sex": "",
15
+ "sex_name": "未知",
16
+ "birthday_date": "",
17
+ "phone_number": "15801505541",
18
+ "request_id": "44cf5b8402ff7c2e"
19
+ }
13
20
  }
@@ -1,13 +1,13 @@
1
1
  <template>
2
2
  <view class="xd_vip_wrap">
3
3
  <view class="vip_list">
4
- <view class="vip_item" :class="{active: i==1}" v-for="i in 6" :key="i">
5
- <view class="vip_name">1日体验</view>
6
- <view class="vip_price">10.00</view>
4
+ <view class="vip_item" :class="{active: item.vip_card_id===vip_card_id}" v-for="item in uiList" :key="item.vip_card_id">
5
+ <view class="vip_name">{{ item.product_name}}</view>
6
+ <view class="vip_price">{{ $xdUniHelper.divisionFloatNumber(item.sale_price, 100) }}</view>
7
7
  </view>
8
8
  </view>
9
9
  <view class="vip_pay">
10
- <xd-button type="primary" width="600rpx">立即支付¥148/年</xd-button>
10
+ <view class="pay_btn" @click="toVipDetail">立即支付 <xd-unit style="margin-left: 16rpx;" :price="curVipCard.sale_price" :isOld="false" colorNew="#FFFFFF"></xd-unit></view>
11
11
  <view class="vip_tip">开通视为同意<text @click.stop="handlePrivacy('privacy_service')">《共享PLUS会员用户协议》</text></view>
12
12
  </view>
13
13
  </view>
@@ -15,18 +15,45 @@
15
15
 
16
16
  <script>
17
17
  import XdButton from "@/components/XdButton/XdButton.vue"
18
+ import XdUnit from "@/components/XdUnit/XdUnit.vue"
18
19
  export default {
19
20
  components: {
20
- XdButton
21
+ XdButton,
22
+ XdUnit
23
+ },
24
+ props: {
25
+ list: {
26
+ type: Array,
27
+ default(){
28
+ return []
29
+ }
30
+ }
31
+ },
32
+ watch: {
33
+ list(val){
34
+ this.vip_card_id = val[0].vip_card_id || ''
35
+ this.uiList = val
36
+ }
37
+ },
38
+ computed: {
39
+ curVipCard(){
40
+ return this.uiList.find(item => item.vip_card_id === this.vip_card_id) || {}
41
+ }
21
42
  },
22
43
  data(){
23
44
  return {
24
-
45
+ uiList: [],
46
+ vip_card_id: ''
25
47
  }
26
48
  },
27
49
  methods: {
28
50
  handlePrivacy(type){
29
51
  this.$emit('handlePrivacy', type)
52
+ },
53
+ toVipDetail(){
54
+ if(this.vip_card_id){
55
+ this.$emit('toVipDetail', this.vip_card_id)
56
+ }
30
57
  }
31
58
  }
32
59
  }
@@ -70,6 +97,17 @@
70
97
  }
71
98
  .vip_pay{
72
99
  padding: 24rpx 0 50rpx;
100
+ .pay_btn{
101
+ width: 600rpx;
102
+ display: flex;
103
+ align-items: center;
104
+ justify-content: center;
105
+ height: 80rpx;
106
+ background-color: var(--main-color);
107
+ color: #FFFFFF;
108
+ margin: 0 auto;
109
+ border-radius: 80rpx;
110
+ }
73
111
  }
74
112
  .vip_tip{
75
113
  text-align: center;
@@ -6,53 +6,31 @@
6
6
  */
7
7
  module.exports = [
8
8
  {
9
- //设置方法名字当别忘记加上【模块名字】:Open
10
- mapFnName: 'getOpenByIdFilmSquate',
11
- title: '获取电影广场列表',
12
- path: '/api/account/film/list-film-square',
9
+ mapFnName: "getVipConfirm",
10
+ title: "获取vip确认信息",
11
+ path: "/member/v1/:xnamespace/order/confirm",
13
12
  isRule: false,
14
- params: {
15
- last_key: ['当前页', 'Number', '必选'],
16
- page_size: ['每页数量', 'Number', '必选'],
13
+ data: {
14
+ vip_card_id: ["vip卡id", "Number", "必选"],
15
+ xnamespace: ['业务线', 'String', '必选']
17
16
  },
18
17
  isConsole: true,
19
18
  disabled: true,
20
19
  },
21
20
  {
22
- //设置方法名字当别忘记加上【模块名字】:Open
23
- mapFnName: 'updateOpenFilmPaiqiDate',
24
- title: '更新排期',
25
- path: '/api/account/film/paiqi-date',
21
+ mapFnName: "createVipOrder",
22
+ title: "创建VIP订单",
23
+ path: "/member/v1/order/submit",
26
24
  isRule: false,
27
- params: {
28
- film_id: ['电影id', 'Number', '必选'],
29
- cinema_id: ['影院id', 'Number', '必选'],
25
+ data: {
26
+ business_code: ['业务编码', 'String', '必选'],
27
+ product_id: ['商品id', 'Number', '必选'],
28
+ notify_provider_id: ['notify_provider_id', 'Number', '可选'],
29
+ selected_card_list_json: ['已使用的卡券数据', 'array', '可选'],
30
+ selected_wallet_list_json: ['已使用的钱包数据', 'array', '可选'],
31
+ need_pay_price: ['需要支付的价格', 'Number', '可选']
30
32
  },
31
33
  isConsole: true,
32
34
  disabled: true,
33
- },
34
- {
35
- //设置方法名字当别忘记加上【模块名字】:Open
36
- mapFnName: 'removeOpenFilmAddress',
37
- title: '删除我的配送地址',
38
- path: '/api/account/film/paiqi-date',
39
- isRule: false,
40
- params: {
41
- film_id: ['电影id', 'Number', '必选'],
42
- },
43
- isConsole: true,
44
- disabled: true,
45
- },
46
- {
47
- //设置方法名字当别忘记加上【模块名字】:Open
48
- mapFnName: 'addOpenFilmcart',
49
- title: '添加购物车',
50
- path: '/api/account/film/paiqi-date',
51
- isRule: false,
52
- params: {
53
- film_id: ['电影id', 'Number', '必选'],
54
- },
55
- isConsole: true,
56
- disabled: true,
57
- },
35
+ }
58
36
  ];
@@ -8,39 +8,28 @@ export default {
8
8
  content: (data) => {
9
9
  return [
10
10
  {
11
- label: '背景颜色:',
12
- ele: 'xd-color',
13
- valueKey: 'bgColor',
14
- value: data.bgColor || '',
15
- placeholder: '请输入占位框背景颜色',
16
- groupKey:'content',
17
- },
18
- {
19
- label: '选中路径:',
20
- groupKey:'advanced',
21
- className: 'input100',
11
+ label: '支付页面路径:',
22
12
  ele: 'xd-select-pages-path',
23
- valueKey: 'select-pages-path',
24
- value: data['select-pages-path'] || null,
13
+ valueKey: 'payPath',
14
+ groupKey:'advanced',
15
+ placeholder: '请选择支付页面路径',
16
+ value: data['payPath'] || null,
25
17
  setting: {
26
- router: XdBus.getParentApi('getPagesTree')
18
+ router: XdBus.getParentApi('getPagesTree'),
27
19
  },
28
- },
29
- data.bgColor && {
30
- label: '高度:',
31
- ele: 'el-input',
32
- groupKey:'style',
33
- type: 'number',
34
- valueKey: 'height',
35
- value: data.height || 100,
36
- placeholder: '请输入占位框高度,单位像素,默认:10px',
37
- className: 'input60',
20
+ inline: false,
38
21
  },
39
22
  {
40
- label: '', //label
23
+ label: '支付成功路径:',
24
+ ele: 'xd-select-pages-path',
25
+ valueKey: 'paySuccessPath',
41
26
  groupKey:'advanced',
42
- ele: 'slot', //package 名称
43
- slot: 'is_reference',
27
+ placeholder: '请选择支付成功路径',
28
+ value: data['paySuccessPath'] || null,
29
+ setting: {
30
+ router: XdBus.getParentApi('getPagesTree'),
31
+ },
32
+ inline: false,
44
33
  },
45
34
  ].filter(i=>i)
46
35
  },
@@ -13,25 +13,38 @@
13
13
  <view class="jfb-base-open-vip-detail__edit-icon" @click="delEdit">删除</view>
14
14
  </view>
15
15
  <!-- #endif -->
16
- <view class="jfb-base-open-vip-detail__body">
16
+ <view class="jfb-base-open-vip-detail__body" :style="[bodyStyle]">
17
17
  <view class="combo_section">
18
- <view class="combo_section-title">套餐名称:年卡会员</view>
19
- <xd-list-item label="套餐金额" paddingLR="40rpx">¥125.00</xd-list-item>
20
- <xd-list-item label="套餐期限" paddingLR="40rpx">30天</xd-list-item>
18
+ <view class="combo_section-title">套餐名称:{{ vipInfo.product_name }}</view>
19
+ <xd-list-item label="套餐金额" paddingLR="40rpx">¥{{ $xdUniHelper.divisionFloatNumber(vipInfo.sale_price, 100) }}</xd-list-item>
20
+ <xd-list-item label="套餐期限" paddingLR="40rpx">{{ vipInfo.life_cycle_label }}</xd-list-item>
21
21
  </view>
22
22
 
23
23
  <view class="combo_section">
24
- <xd-list-item label="套餐金额" paddingLR="40rpx">¥125.00</xd-list-item>
25
- <xd-list-item label="平台优惠" paddingLR="40rpx">-¥125.00</xd-list-item>
24
+ <xd-list-item label="套餐金额" paddingLR="40rpx">¥{{ $xdUniHelper.divisionFloatNumber(vipInfo.user_pay_amount, 100) }}</xd-list-item>
25
+ <xd-list-item label="平台优惠" paddingLR="40rpx">-¥{{ $xdUniHelper.divisionFloatNumber(vipInfo.platform_discount_amount, 100) }}</xd-list-item>
26
+ </view>
27
+
28
+ <view class="fixed_bottom" :style="[fixed_bottom]">
29
+ <view class="pay_btn" @click="p_createVipOrder">
30
+ 立即支付
31
+ <xd-unit style="margin-left: 16rpx;"
32
+ :price="vipInfo.sale_price"
33
+ :isOld="false"
34
+ colorNew="#FFFFFF"
35
+ ></xd-unit>
36
+ </view>
37
+ <view class="plus_privacy">开通视为同意 <text @click.stop="handlePrivacy('privacy_service')"></text>《共享PLUS会员用户协议》</view>
26
38
  </view>
27
-
28
39
  </view>
29
40
  </view>
30
41
  </template>
31
42
 
32
43
  <script>
33
44
  import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
34
- import XdListItem from "@/components/XdListItem/XdListItem"
45
+ import XdListItem from "@/components/CusListItem/CusListItem"
46
+ import XdUnit from "@/components/XdUnit/XdUnit.vue"
47
+ import XdButton from "@/components/XdButton/XdButton";
35
48
  import { jfbRootExec } from "@/utils/xd.event";
36
49
  import JfbBaseOpenVipDetailMixin from "./JfbBaseOpenVipDetailMixin";
37
50
  import { getContainerPropsValue } from "@/utils/xd.base";
@@ -41,17 +54,37 @@
41
54
  name: "JfbBaseOpenVipDetail",
42
55
  components: {
43
56
  XdFontIcon,
44
- XdListItem
57
+ XdListItem,
58
+ XdButton,
59
+ XdUnit,
45
60
  },
46
61
  mixins: [
47
62
  componentsMixins, extsMixins, JfbBaseOpenVipDetailMixin
48
63
  ],
49
64
  data() {
50
65
  return {
51
- //hideMask: true,
66
+ closeMask: true,
67
+ xnamespace: "",
68
+ notify_provider_id: "",
69
+
70
+ vip_card_id: "",
71
+ vipInfo: {},
52
72
  //todo
73
+ payPath: "",
74
+ paySuccessPath: "",
53
75
  }
54
76
  },
77
+ computed: {
78
+ bodyStyle(){
79
+ return {
80
+ minHeight: this.layoutInfo.bodyMinHeightRpx + "rpx",
81
+ '--main-color': this.mainColor
82
+ }
83
+ },
84
+ fixed_bottom() {
85
+ return this.fixedStyle({paddingBottom: 36, zIndex: 111})
86
+ },
87
+ },
55
88
  watch: {
56
89
  container(value, oldValue) {
57
90
  if (JSON.stringify(value) === JSON.stringify(oldValue)) return;
@@ -60,34 +93,58 @@
60
93
  },
61
94
  created() {
62
95
  this.init(this.container);
63
-
96
+ this.notify_provider_id = this.projectAttr.notify_provider_id;
64
97
  //todo
65
98
  },
66
99
  methods: {
67
100
  onJfbLoad(options) {
68
-
69
- // jfbRootExec('baiduUserLogin', {
70
-
71
- // vm: this,// data: {
72
-
73
- // account: 'gaoshiyong',// password: '123456789',// type: 3,// ...options
74
-
75
- // }
76
-
77
- // }).then().catch()
101
+ this.setNameSpace(options);
102
+ this.vip_card_id = options.vip_card_id;
103
+ this.p_getVipConfirm();
78
104
  },
79
105
  /**
80
106
  * @description 监听事件变化
81
107
  * @param container {object} 业务组件对象自己
82
108
  */
83
109
  init(container) {
110
+ this.payPath = getContainerPropsValue(container, 'content.payPath', {value: ""}).value;
111
+ this.paySuccessPath = getContainerPropsValue(container, 'content.paySuccessPath', {value: ""}).value;
112
+ },
113
+ p_getVipConfirm(){
114
+ jfbRootExec("getVipConfirm", {
115
+ vm: this,
116
+ data: {
117
+ vip_card_id: this.vip_card_id,
118
+ xnamespace: this.xnamespace
119
+ }
120
+ }).then(res => {
121
+ this.vipInfo = res;
122
+ })
123
+ },
124
+ p_createVipOrder(){
125
+ jfbRootExec("createVipOrder", {
126
+ vm: this,
127
+ data: {
128
+ business_code: this.xnamespace,
129
+ product_id: this.vipInfo.product_id,
130
+ notify_provider_id: this.notify_provider_id,
131
+ need_pay_price: this.vipInfo.user_pay_amount
132
+ }
133
+ }).then(res => {
134
+ if(res.need_pay_price > 0){
135
+ this.$xdUniHelper.redirectTo({
136
+ url: this.payPath + `?order_id=${res.pay_order_id}&main_order_id=${res.main_order_id}`
137
+ })
138
+ }else{
139
+ this.$xdUniHelper.redirectTo({
140
+ url: this.paySuccessPath + '?order_id=' + res.main_order_id
141
+ })
142
+ }
84
143
 
85
- //this.bgcolor = getContainerPropsValue(container, 'content.bgcolor', '#fff');
86
-
87
- //this.height = getContainerPropsValue(container, 'content.height', 10);
144
+ })
88
145
  },
89
146
  onJfbScroll(options) {
90
- console.log('event.onJfbScroll', options)
147
+ // console.log('event.onJfbScroll', options)
91
148
  },
92
149
  onJfbReachBottom(options) {
93
150
  console.log('event.onJfbReachBottom', options)
@@ -135,6 +192,34 @@
135
192
  color: #999999;
136
193
  }
137
194
  }
195
+ .fixed_bottom{
196
+ position: fixed;
197
+ bottom: 0;
198
+ left: 0;
199
+ width: 100%;
200
+ padding: 36rpx;
201
+ box-sizing: border-box;
202
+ background-color: #FFFFFF;
203
+ display: flex;
204
+ flex-direction: column;
205
+ align-items: center;
206
+ .pay_btn{
207
+ width: 600rpx;
208
+ display: flex;
209
+ align-items: center;
210
+ justify-content: center;
211
+ height: 80rpx;
212
+ background-color: var(--main-color);
213
+ color: #FFFFFF;
214
+ margin: 0 auto;
215
+ border-radius: 80rpx;
216
+ }
217
+ .plus_privacy{
218
+ font-size: 22rpx;
219
+ color: #999;
220
+ margin-top: 16rpx;
221
+ }
222
+ }
138
223
  }
139
224
  }
140
225
  </style>