jufubao-base 1.0.232-beta5 → 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 (45) 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 +52 -23
  8. package/src/components/JfbBaseOpenVip/Api.js +11 -40
  9. package/src/components/JfbBaseOpenVip/Attr.js +4 -4
  10. package/src/components/JfbBaseOpenVip/JfbBaseOpenVip.vue +68 -25
  11. package/src/components/JfbBaseOpenVip/Mock.js +16 -9
  12. package/src/components/JfbBaseOpenVip/XdVipList.vue +44 -6
  13. package/src/components/JfbBaseOpenVipDetail/Api.js +17 -39
  14. package/src/components/JfbBaseOpenVipDetail/Attr.js +16 -27
  15. package/src/components/JfbBaseOpenVipDetail/JfbBaseOpenVipDetail.vue +108 -23
  16. package/src/components/JfbBasePersonalData/Api.js +9 -41
  17. package/src/components/JfbBasePersonalData/Attr.js +1 -37
  18. package/src/components/JfbBasePersonalData/JfbBasePersonalData.vue +43 -21
  19. package/src/components/JfbBasePointsCard/Api.js +4 -44
  20. package/src/components/JfbBasePointsCard/Attr.js +0 -48
  21. package/src/components/JfbBasePointsCard/JfbBasePointsCard.vue +24 -107
  22. package/src/components/JfbBasePointsCard/Mock.js +1 -9
  23. package/src/components/JfbBasePointsDetail/Api.js +25 -0
  24. package/src/components/JfbBasePointsDetail/JfbBasePointsDetail.vue +65 -20
  25. package/src/components/JfbBasePointsDetail/Mock.js +2 -8
  26. package/src/components/JfbBaseSavingDetail/Api.js +12 -29
  27. package/src/components/JfbBaseSavingDetail/Attr.js +44 -22
  28. package/src/components/JfbBaseSavingDetail/JfbBaseSavingDetail.vue +593 -29
  29. package/src/components/JfbBaseSavingDetail/components/echarts.min.js +26 -0
  30. package/src/components/JfbBaseSavingDetail/components/echarts.vue +254 -0
  31. package/src/components/JfbBaseSavingDetail/components/wx-canvas.js +105 -0
  32. package/src/components/JfbBaseShare/Api.js +5 -43
  33. package/src/components/JfbBaseShare/JfbBaseShare.vue +13 -12
  34. package/src/components/JfbBaseTfkSearch/ContentProduct.vue +1 -20
  35. package/src/components/JfbBaseTfkSearch/JfbBaseTfkSearch.vue +5 -0
  36. package/src/components/JfbBaseUserInfo/JfbBaseUserInfo.vue +5 -1
  37. package/src/components/JfbBaseWithDrawAgain/Api.js +13 -30
  38. package/src/components/JfbBaseWithDrawAgain/Attr.js +70 -26
  39. package/src/components/JfbBaseWithDrawAgain/JfbBaseWithDrawAgain.vue +255 -32
  40. package/src/components/JfbBaseWithDrawRecord/Api.js +4 -43
  41. package/src/components/JfbBaseWithDrawRecord/Attr.js +56 -25
  42. package/src/components/JfbBaseWithDrawRecord/JfbBaseWithDrawRecord.vue +151 -34
  43. package/src/components/JfbBaseWithdraw/Api.js +20 -30
  44. package/src/components/JfbBaseWithdraw/Attr.js +304 -24
  45. package/src/components/JfbBaseWithdraw/JfbBaseWithdraw.vue +166 -32
@@ -6,43 +6,7 @@
6
6
  export default {
7
7
  style: [],
8
8
  content: (data) => {
9
- return [
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',
22
- ele: 'xd-select-pages-path',
23
- valueKey: 'select-pages-path',
24
- value: data['select-pages-path'] || null,
25
- setting: {
26
- router: XdBus.getParentApi('getPagesTree')
27
- },
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',
38
- },
39
- {
40
- label: '', //label
41
- groupKey:'advanced',
42
- ele: 'slot', //package 名称
43
- slot: 'is_reference',
44
- },
45
- ].filter(i=>i)
9
+ return [].filter(i=>i)
46
10
  },
47
11
  advanced: [],
48
12
  };
@@ -5,22 +5,24 @@
5
5
  <view class="jfb-base-personal-data__edit-icon" @click="delEdit">删除</view>
6
6
  </view>
7
7
  <!-- #endif -->
8
- <view class="jfb-base-personal-data__body">
8
+ <view class="jfb-base-personal-data__body" v-if="info">
9
9
  <view class="jfb-base-personal-data__body-item">
10
10
  <view class="jfb-base-personal-data__body-item-label">头像</view>
11
- <image class="profile" :src="data.profile"  ></image>
11
+ <image class="profile" :src="info.head_url"  ></image>
12
12
  </view>
13
13
  <view class="jfb-base-personal-data__body-item">
14
14
  <view class="jfb-base-personal-data__body-item-label">账号</view>
15
- <view class="jfb-base-personal-data__body-item-value">{{data.account}}</view>
15
+ <view class="jfb-base-personal-data__body-item-value">{{info.phone_number}}</view>
16
16
  </view>
17
17
  <view class="jfb-base-personal-data__body-item">
18
18
  <view class="jfb-base-personal-data__body-item-label">名称</view>
19
- <input class="jfb-base-personal-data__body-item-value" v-model="data.name" type="text">
19
+ <input @blur="handleSetInfo" @confirm="handleSetInfo" class="jfb-base-personal-data__body-item-value"
20
+ v-model="info.nickname" type="text">
20
21
  </view>
21
22
  <view class="jfb-base-personal-data__body-item">
22
23
  <view class="jfb-base-personal-data__body-item-label">性别</view>
23
- <XdSelect padding="0" color="#999" class="select" :defaultValue="data.sex" v-model="data.sex" :list="sexList">
24
+ <XdSelect @change="handleSetSex" padding="0" color="#999" class="select" :defaultValue="info.sex"
25
+ v-model="info.sex" :list="sexList">
24
26
  <template>
25
27
  <view class="jfb-base-personal-data__body-item-value">
26
28
  <XdFontIcon class="icon" color="#999999" size="24" icon="iconxiangyou_xian"></XdFontIcon>
@@ -32,13 +34,13 @@
32
34
  <view class="jfb-base-personal-data__body-item">
33
35
  <view class="jfb-base-personal-data__body-item-label">生日</view>
34
36
  <view style="display: flex;align-items: center" @click="showDate=true">
35
- <view class="jfb-base-personal-data__body-item-value">{{data.birthday}}</view>
37
+ <view class="jfb-base-personal-data__body-item-value">{{info.birthday_date}}</view>
36
38
  <XdFontIcon class="icon" color="#999999" size="24" icon="iconxiangyou_xian"></XdFontIcon>
37
39
  </view>
38
40
  </view>
39
- <XdDate ref="calendar" :selectType="false" :main-color="mainColor" :current-is-show-other-month="false" :show.sync="showDate"
40
- :clear-date="true" :insert="false" :lunar="false" :selected-circle="false" :date="data.birthday"
41
- @confirm="confirmDate" @close="closeDate"></XdDate>
41
+ <XdDate ref="calendar" :selectType="false" :main-color="mainColor" :current-is-show-other-month="false"
42
+ :show.sync="showDate" :clear-date="true" :insert="false" :lunar="false" :selected-circle="false"
43
+ :date="info.birthday_date" @confirm="confirmDate" @close="closeDate"></XdDate>
42
44
  </view>
43
45
  </view>
44
46
  </template>
@@ -64,26 +66,19 @@
64
66
  ],
65
67
  data() {
66
68
  return {
69
+ info: {},
67
70
  single: '',
68
71
  showDate: false,
69
- birthday: '',
70
72
  sexList: [
71
73
  {
72
74
  label: '男',
73
- value: 1
75
+ value: '1'
74
76
  },
75
77
  {
76
78
  label: '女',
77
- value: 2
79
+ value: '2'
78
80
  }
79
81
  ],
80
- data: {
81
- sex: 1,
82
- profile: 'https://img.js.design/assets/smartFill/img316164da746310.jpg',
83
- account: 5455645545,
84
- name: '张三',
85
- birthday: '2025-04-09'
86
- }
87
82
  }
88
83
  },
89
84
  watch: {
@@ -96,19 +91,46 @@
96
91
  this.init(this.container);
97
92
  },
98
93
  methods: {
99
- onJfbLoad(options) { },
94
+ onJfbLoad(options) {
95
+ this.getInfo()
96
+ },
100
97
  /**
101
98
  * @description 监听事件变化
102
99
  * @param container {object} 业务组件对象自己
103
100
  */
104
101
  init(container) {
105
102
  },
103
+ getInfo() {
104
+ jfbRootExec("getBasePersonInfo", {
105
+ vm: this,
106
+ data: {},
107
+ }).then(res => {
108
+ this.info = res
109
+ })
110
+ },
106
111
  confirmDate(e) {
107
112
  console.log(e, 'confirmDate');
108
- this.data.birthday = e.fulldate
113
+ this.info.birthday_date = e.fulldate
114
+ this.handleSetInfo()
109
115
  },
110
116
  closeDate() {
111
117
 
118
+ },
119
+ handleSetSex(data) {
120
+ this.info.sex = data.item.value
121
+ this.handleSetInfo()
122
+ },
123
+ handleSetInfo() {
124
+ jfbRootExec("setBasePersonInfo", {
125
+ vm: this,
126
+ data: {
127
+ nickname: this.info.nickname,
128
+ sex: this.info.sex.value,
129
+ birthday_date: this.info.birthday_date
130
+ },
131
+ }).then(res => {
132
+ this.getInfo()
133
+ })
112
134
  },
113
135
  onJfbScroll(options) {
114
136
  console.log('event.onJfbScroll', options)
@@ -7,51 +7,11 @@
7
7
  module.exports = [
8
8
  {
9
9
  //设置方法名字当别忘记加上【模块名字】:Points
10
- mapFnName: 'getPointsByIdFilmSquate',
11
- title: '获取电影广场列表',
12
- path: '/api/account/film/list-film-square',
10
+ mapFnName: 'getPointsPropertyList',
11
+ title: '用户资产 - 列表',
12
+ path: '/pay/v1/property/list',
13
13
  isRule: false,
14
- params: {
15
- last_key: ['当前页', 'Number', '必选'],
16
- page_size: ['每页数量', 'Number', '必选'],
17
- },
18
- isConsole: true,
19
- disabled: true,
20
- },
21
- {
22
- //设置方法名字当别忘记加上【模块名字】:Points
23
- mapFnName: 'updatePointsFilmPaiqiDate',
24
- title: '更新排期',
25
- path: '/api/account/film/paiqi-date',
26
- isRule: false,
27
- params: {
28
- film_id: ['电影id', 'Number', '必选'],
29
- cinema_id: ['影院id', 'Number', '必选'],
30
- },
31
- isConsole: true,
32
- disabled: true,
33
- },
34
- {
35
- //设置方法名字当别忘记加上【模块名字】:Points
36
- mapFnName: 'removePointsFilmAddress',
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
- //设置方法名字当别忘记加上【模块名字】:Points
48
- mapFnName: 'addPointsFilmcart',
49
- title: '添加购物车',
50
- path: '/api/account/film/paiqi-date',
51
- isRule: false,
52
- params: {
53
- film_id: ['电影id', 'Number', '必选'],
54
- },
14
+ params: {},
55
15
  isConsole: true,
56
16
  disabled: true,
57
17
  },
@@ -21,42 +21,6 @@ export default {
21
21
  { label: '普通用户样式', value: 'N' },
22
22
  ]
23
23
  },
24
- {
25
- label: '是否展示积分入口:',
26
- labelInline: true,
27
- ele: 'xd-radio',
28
- valueKey: 'isPoints',
29
- groupKey: 'content',
30
- value: data['isPoints'] || 'Y',
31
- list: [
32
- { "label": "展示", "value": 'Y' },
33
- { "label": "隐藏", "value": 'N' },
34
- ]
35
- },
36
- {
37
- label: '是否展示余额入口:',
38
- labelInline: true,
39
- ele: 'xd-radio',
40
- valueKey: 'isYue',
41
- groupKey: 'content',
42
- value: data['isYue'] || 'Y',
43
- list: [
44
- { "label": "展示", "value": 'Y' },
45
- { "label": "隐藏", "value": 'N' },
46
- ]
47
- },
48
- {
49
- label: '是否展示优惠券入口:',
50
- labelInline: true,
51
- ele: 'xd-radio',
52
- valueKey: 'isConpon',
53
- groupKey: 'content',
54
- value: data['isConpon'] || 'Y',
55
- list: [
56
- { "label": "展示", "value": 'Y' },
57
- { "label": "隐藏", "value": 'N' },
58
- ]
59
- },
60
24
  {
61
25
  label: '外边距:',
62
26
  ele: 'xd-margin-padding',
@@ -181,18 +145,6 @@ export default {
181
145
  labelInline: true,
182
146
  classNmae: 'input80',
183
147
  },
184
- {
185
- label: '积分兑换地址路径:',
186
- ele: 'xd-select-pages-path',
187
- valueKey: 'pointsPath',
188
- groupKey:'advanced',
189
- placeholder: '请选择积分兑换地址路径',
190
- value: data['addressUrl'] || null,
191
- setting: {
192
- router: XdBus.getParentApi('getPagesTree'),
193
- },
194
- inline: false,
195
- },
196
148
  {
197
149
  label: '余额提现路径:',
198
150
  ele: 'xd-select-pages-path',
@@ -7,12 +7,13 @@
7
7
  <!-- #endif -->
8
8
  <view class="jfb-base-points-card__body">
9
9
  <view :style="[bodyStyleComp]" class="jfb-base-points-card__body-list">
10
- <view :style="[itemStyleComp]" @click="handleTo(item)" v-for="(item,index) in typeList" :key="index" class="jfb-base-points-card__body-list-item">
10
+ <view :style="[itemStyleComp]" @click="handleTo(item)" v-for="(item,index) in typeList" :key="index"
11
+ class="jfb-base-points-card__body-list-item">
11
12
  <view class="jfb-base-points-card__body-list-item-label">
12
- {{item.label}}
13
- <view :style="{background:is_vip==='N'?mainColor:'',color:is_vip==='N'?'#fff':''}" class="jfb-base-points-card__body-list-item-operate" v-if="item.operate">{{item.operate}}</view>
13
+ {{item.name}}
14
14
  </view>
15
- <view class="jfb-base-points-card__body-list-item-value">{{item.value}}</view>
15
+ <view v-if="item.method!=='coupon'" class="jfb-base-points-card__body-list-item-value">{{getAmout(item.amount)}}</view>
16
+ <view v-else class="jfb-base-points-card__body-list-item-value">{{item.coupon_count}}</view>
16
17
  </view>
17
18
  </view>
18
19
  </view>
@@ -52,28 +53,7 @@
52
53
  },
53
54
  data() {
54
55
  return {
55
- isPoints: '',
56
- isYue: '',
57
- isConpon: '',
58
- typeList: [
59
- {
60
- label: "积分",
61
- key: "points",
62
- value: 0
63
- },
64
- {
65
- label: "余额",
66
- key: "yue",
67
- operate: '提现',
68
- value: 0
69
- },
70
- {
71
- label: "优惠券",
72
- key: "conpon",
73
- value: 0
74
- },
75
- ],
76
- is_vip: 'N',
56
+ typeList: [],
77
57
  plusBodyBgColor: '',
78
58
  plusItemBgColor: '',
79
59
  normalBodyBgColor: '',
@@ -94,62 +74,6 @@
94
74
  if (JSON.stringify(value) === JSON.stringify(oldValue)) return;
95
75
  if (this.$configProject['isPreview']) this.init(value)
96
76
  },
97
- isPoints(n, o) {
98
- if (n === "Y") {
99
- let flag = this.typeList.find((item) => item.key === "points");
100
- if (!flag) {
101
- this.typeList.splice(0, 0, {
102
- label: "积分",
103
- key: "points",
104
- operate: '兑换'
105
- });
106
- }
107
- } else {
108
- let flagIndex = this.typeList.findIndex(
109
- (item) => item.key === "points"
110
- );
111
- if (flagIndex !== -1) {
112
- this.typeList.splice(flagIndex, 1);
113
- }
114
- }
115
- },
116
- isYue(n, o) {
117
- if (n === "Y") {
118
- let flag = this.typeList.find((item) => item.key === "yue");
119
- if (!flag) {
120
- this.typeList.splice(1, 0, {
121
- label: "余额",
122
- key: "yue",
123
- operate: '提现'
124
- });
125
- }
126
- } else {
127
- let flagIndex = this.typeList.findIndex(
128
- (item) => item.key === "yue"
129
- );
130
- if (flagIndex !== -1) {
131
- this.typeList.splice(flagIndex, 1);
132
- }
133
- }
134
- },
135
- isConpon(n, o) {
136
- if (n === "Y") {
137
- let flag = this.typeList.find((item) => item.key === "conpon");
138
- if (!flag) {
139
- this.typeList.splice(2, 0, {
140
- label: "优惠券",
141
- key: "conpon",
142
- });
143
- }
144
- } else {
145
- let flagIndex = this.typeList.findIndex(
146
- (item) => item.key === "conpon"
147
- );
148
- if (flagIndex !== -1) {
149
- this.typeList.splice(flagIndex, 1);
150
- }
151
- }
152
- },
153
77
  is_plus_preview() {
154
78
  if (this.$configProject['isPreview']) {
155
79
  this.is_vip = this.is_plus_preview
@@ -157,26 +81,19 @@
157
81
  }
158
82
  },
159
83
  created() {
84
+ console.log(this.getTokenForKey('user_level'), 'user_leveluser_level');
85
+ this.is_vip = this.getTokenForKey('user_level') && this.getTokenForKey('user_level') === 'VIP' ? 'Y' : 'N'
160
86
  this.init(this.container);
161
-
162
- //todo
163
87
  },
164
88
  methods: {
165
89
  onJfbLoad(options) {
166
- this.typeList = this.typeList.map(item => {
167
- if (item.key === 'points') {
168
- // item.value = 'score_amount'
169
- item.value = 89144
170
- }
171
- if (item.key === 'yue') {
172
- // item.value = 'total_amount'
173
- item.value = 4545
174
- }
175
- if (item.key === 'conpon') {
176
- // item.value = 'coupon_count'
177
- item.value = 3
178
- }
179
- return item
90
+ jfbRootExec("getPointsPropertyList", {
91
+ vm: this,
92
+ data: {},
93
+ }).then(res => {
94
+ this.typeList = res.list
95
+ }).catch(err => {
96
+ console.log(err, "err");
180
97
  })
181
98
  },
182
99
  /**
@@ -184,9 +101,6 @@
184
101
  * @param container {object} 业务组件对象自己
185
102
  */
186
103
  init(container) {
187
- this.isPoints = getContainerPropsValue(container, "content.isPoints", "Y");
188
- this.isYue = getContainerPropsValue(container, "content.isYue", "Y");
189
- this.isConpon = getContainerPropsValue(container, "content.isConpon", "Y");
190
104
  this.plusBodyBgColor = getContainerPropsValue(container, 'content.plusBodyBgColor', 'linear-gradient(180deg, #FFFCF8 0%, #FFF3E2 100%)');
191
105
  this.plusItemBgColor = getContainerPropsValue(container, 'content.plusItemBgColor', 'linear-gradient(136.55deg, #FFECD1 0%, #F6D6AB 100%)');
192
106
  this.normalBodyBgColor = getContainerPropsValue(container, 'content.normalBodyBgColor', '#fff');
@@ -200,15 +114,18 @@
200
114
  this.withdrawPath = getContainerPropsValue(container, 'content.withdrawPath', { value: "" }).value;
201
115
  this.couponPath = getContainerPropsValue(container, 'content.couponPath', { value: "" }).value;
202
116
  },
117
+ getAmout(amount) {
118
+ return this.$xdUniHelper.divisionFloatNumber(amount, 100)
119
+ },
203
120
  handleTo(item) {
204
- if (item.key === 'points') {
205
- this.$router.push(this.pointsPath)
121
+ if (item.method === 'score') {
122
+ this.$xdUniHelper.navigateTo({ url: `${this.pointsPath}?method=score` })
206
123
  }
207
- if (item.key === 'yue') {
208
- this.$router.push(this.withdrawPath)
124
+ if (item.method === 'wallet') {
125
+ this.$xdUniHelper.navigateTo({ url: `${this.withdrawPath}?method=wallet` })
209
126
  }
210
- if (item.key === 'conpon') {
211
- this.$router.push(this.couponPath)
127
+ if (item.method === 'coupon') {
128
+ this.$xdUniHelper.navigateTo({ url: this.couponPath })
212
129
  }
213
130
  },
214
131
  onJfbScroll(options) {
@@ -1,13 +1,5 @@
1
1
  'use strict';
2
2
 
3
3
  module.exports = {
4
-
5
- getPointsByIdFilmSquate:{},
6
-
7
- updatePointsFilmPaiqiDate:{},
8
-
9
- removePointsFilmAddress:{},
10
-
11
- addPointsFilmcart:{},
12
-
4
+ getPointsPropertyList:{"list":[{"method":"wallet","coupon_count":0,"amount":20000,"name":"余额"},{"method":"score","coupon_count":0,"amount":10000,"name":"积分"},{"method":"coupon","coupon_count":0,"amount":0,"name":"优惠券"}],"request_id":"2b0ac6cb23abdbbb"},
13
5
  }
@@ -20,4 +20,29 @@ module.exports = [
20
20
  isConsole: true,
21
21
  disabled: true,
22
22
  },
23
+ {
24
+ //设置方法名字当别忘记加上【模块名字】:Points
25
+ mapFnName: 'getPointsWalletDetail',
26
+ title: '用户资产 - 获取钱包(或积分)余额详情',
27
+ path: '/pay/v1/property/wallet-detail',
28
+ isRule: false,
29
+ params: {
30
+ method: ['wallet 余额; score 积分;', 'Number', '非必选'],
31
+ },
32
+ isConsole: true,
33
+ disabled: true,
34
+ },
35
+ {
36
+ //设置方法名字当别忘记加上【模块名字】:Points
37
+ mapFnName: 'getPointsWalletTradeList',
38
+ title: '用户资产 - 获取钱包(或积分)交易记录列表',
39
+ path: '/pay/v1/property/wallet-trade/list',
40
+ isRule: false,
41
+ params: {
42
+ wallet_type: ['钱包类型', 'Number', '必选'],
43
+ page_size: ['每页条数', 'Number', '必选'],
44
+ },
45
+ isConsole: true,
46
+ disabled: true,
47
+ },
23
48
  ];
@@ -9,28 +9,24 @@
9
9
  <view :style="[bodyStyleComp]" class="jfb-base-points-detail__body-points">
10
10
  <view>
11
11
  可用积分
12
- <XdFontIcon @click="showDialog=true" style="margin-left: 10rpx" size="20" icon="iconmingchengtubiao"></XdFontIcon>
12
+ <XdFontIcon @click="showDialog=true" style="margin-left: 10rpx" size="20" icon="iconmingchengtubiao">
13
+ </XdFontIcon>
13
14
  </view>
14
- <view>128.80</view>
15
+ <view>{{getAmout(amount)}}</view>
15
16
  </view>
16
- <view :style="[bodyStyleComp]" class="jfb-base-points-detail__body-list">
17
- <view class="jfb-base-points-detail__body-list-item">
17
+ <view v-if="recordList&&recordList.ength>0" :style="[bodyStyleComp]" class="jfb-base-points-detail__body-list">
18
+ <view v-for="(item,index) in recordList" :key="index" class="jfb-base-points-detail__body-list-item">
18
19
  <view class="jfb-base-points-detail__body-list-item-info">
19
- <view class="jfb-base-points-detail__body-list-item-info-label">积分兑换余额</view>
20
- <view :class="income?'income':'expenses'" class="jfb-base-points-detail__body-list-item-info-value">- 12:00
20
+ <view class="jfb-base-points-detail__body-list-item-info-label">{{item.trade_type_name}}</view>
21
+ <view :class="item.operate_type==='A'?'income':'expenses'"
22
+ class="jfb-base-points-detail__body-list-item-info-value"><text>{{item.operate_type==='A'?'+':'-'}}</text>
23
+ {{getAmout(item.amount)}}
21
24
  </view>
22
25
  </view>
23
- <view class="jfb-base-points-detail__body-list-item-date">2025-04-10 16:23</view>
24
- </view>
25
- <view class="jfb-base-points-detail__body-list-item">
26
- <view class="jfb-base-points-detail__body-list-item-info">
27
- <view class="jfb-base-points-detail__body-list-item-info-label">积分兑换余额</view>
28
- <view :class="income?'income':'expenses'" class="jfb-base-points-detail__body-list-item-info-value">- 12:00
29
- </view>
30
- </view>
31
- <view class="jfb-base-points-detail__body-list-item-date">2025-04-10 16:23</view>
26
+ <view class="jfb-base-points-detail__body-list-item-date">{{item.created_time}}</view>
32
27
  </view>
33
28
  </view>
29
+ <XdNoData v-else></XdNoData>
34
30
  <XdDailog :cancel="false" @onBtn="showDialog=false" confirmText="我知道了" title="积分说明" :show.sync="showDialog">
35
31
  <xd-content-xss v-html="notice"></xd-content-xss>
36
32
  </XdDailog>
@@ -40,8 +36,9 @@
40
36
 
41
37
  <script>
42
38
  import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
43
- import XdDailog from '@/components/XdDailog/XdDailog.vue'
44
- import XdContentXss from '@/components/XdContentXss/XdContentXss'
39
+ import XdDailog from '@/components/XdDailog/XdDailog.vue';
40
+ import XdNoData from "@/components/XdNoData/XdNoData";
41
+ import XdContentXss from '@/components/XdContentXss/XdContentXss';
45
42
  import { jfbRootExec } from "@/utils/xd.event";
46
43
  import JfbBasePointsDetailMixin from "./JfbBasePointsDetailMixin";
47
44
  import { getContainerPropsValue } from "@/utils/xd.base";
@@ -52,7 +49,8 @@
52
49
  components: {
53
50
  XdFontIcon,
54
51
  XdDailog,
55
- XdContentXss
52
+ XdContentXss,
53
+ XdNoData
56
54
  },
57
55
  mixins: [
58
56
  componentsMixins, extsMixins, JfbBasePointsDetailMixin
@@ -66,7 +64,10 @@
66
64
  bgColor: '',
67
65
  bodyBorder: {},
68
66
  notice: '',
69
- showDialog: false
67
+ showDialog: false,
68
+ method: '',
69
+ amount: 0,
70
+ recordList: []
70
71
  }
71
72
  },
72
73
  computed: {
@@ -93,8 +94,14 @@
93
94
  },
94
95
  methods: {
95
96
  onJfbLoad(options) {
97
+ console.log(this.getTokenForKey('csrf_user_id'), 'user_leveluser_level');
98
+ this.method = options.method
99
+ this.getPointsDetail()
96
100
  this.getContent()
97
101
  },
102
+ getAmout(amount) {
103
+ return this.$xdUniHelper.divisionFloatNumber(amount, 100)
104
+ },
98
105
  getContent() {
99
106
  jfbRootExec("getListBaseNewsContent", {
100
107
  vm: this,
@@ -116,6 +123,40 @@
116
123
  console.error(error);
117
124
  });
118
125
  },
126
+ getPointsDetail() {
127
+ jfbRootExec("getPointsWalletDetail", {
128
+ vm: this,
129
+ data: {
130
+ method: this.method
131
+ },
132
+ }).then(res => {
133
+ this.amount = res.wallet_list[0].amount
134
+ this.wallet_type = res.wallet_list[0].wallet_type
135
+ this.getPointsRecord()
136
+ })
137
+ },
138
+ getPointsRecord() {
139
+ jfbRootExec("getPointsWalletTradeList", {
140
+ vm: this,
141
+ data: {
142
+ wallet_type: this.wallet_type,
143
+ page_size: 10,
144
+ },
145
+ }).then(res => {
146
+ let list = res.list.map(item => {
147
+ item["created_time"] = this.$xdUniHelper.getDate(
148
+ item["created_time"] * 1000
149
+ ).fullTime;
150
+ return item;
151
+ })
152
+ this.hasNext = res.next_page_token !== "";
153
+ if (this.page_token === 1) {
154
+ this.recordList = list
155
+ } else {
156
+ this.recordList = this.recordList.concat(list);
157
+ }
158
+ })
159
+ },
119
160
  /**
120
161
  * @description 监听事件变化
121
162
  * @param container {object} 业务组件对象自己
@@ -133,7 +174,10 @@
133
174
  console.log('event.onJfbScroll', options)
134
175
  },
135
176
  onJfbReachBottom(options) {
136
- console.log('event.onJfbReachBottom', options)
177
+ if (this.hasNext) {
178
+ this.page_token = this.next_page_token;
179
+ this.getPointsRecord()
180
+ }
137
181
  },
138
182
  onJfbShow(options) {
139
183
  console.log('event.onJfbShow', options)
@@ -174,6 +218,7 @@
174
218
  color: #333;
175
219
  font-size: 64rpx;
176
220
  font-weight: 500;
221
+ margin-top: 20rpx;
177
222
  }
178
223
  }
179
224