jufubao-base 1.0.269-beta2 → 1.0.269-beta4

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jufubao-base",
3
- "version": "1.0.269-beta2",
3
+ "version": "1.0.269-beta4",
4
4
  "private": false,
5
5
  "description": "聚福宝业务组件基础插件包",
6
6
  "main": "index.js",
@@ -7,6 +7,29 @@ export default {
7
7
  style: [],
8
8
  content: (data) => {
9
9
  return [
10
+ {
11
+ label: '背景图片:', //label
12
+ ele: 'xd-upload', //package 名称
13
+ valueKey: 'bodyBgImg', //form[valueKey]
14
+ value: data.bodyBgImg || null, //v-model
15
+ defaultValue: data.bodyBgImg || null, //默认图片对象
16
+ groupKey: "content",
17
+ slot: true, //按钮是否使用slot
18
+ oneWidth: 200, //单个图片显示宽度
19
+ oneHeight: 350, //单个图片显示高度
20
+ elinputClassName: 'input40',
21
+ tipsformet: '上传文件格式:@imageType@,不超过@size@MB.',
22
+ type: ['jpg', 'png', 'jpeg'],
23
+ styleType: 'one', //其值:one=>单文件上传 auth=>证件正反面上传 list=>多文件上传
24
+ uploadType: 'aliyun', //''=>API服务上传 qiniu=>七牛云OSS上传 aliyun=> 阿里云OSS上传
25
+ size: 5, //5M
26
+ action: 'aliyun',
27
+ sort: true, //当上传图片列表时候,是否启用排序
28
+ maxlen: 100, //当上传图片列表时候,最大数量数量
29
+ rules: [
30
+ { required: true, message: '请上传图片', trigger: ['blur', 'change'] },
31
+ ]
32
+ },
10
33
  {
11
34
  label: '开通路径:',
12
35
  groupKey:'advanced',
@@ -5,11 +5,7 @@
5
5
  <view class="jfb-base-consump-code__edit-icon" @click="delEdit">删除</view>
6
6
  </view>
7
7
  <!-- #endif -->
8
- <view v-if="!showMask" class="jfb-base-consump-code__body" :style="{
9
- minHeight: layoutInfo.bodyMinHeightRpx + 'rpx',
10
- background: 'url(https://img.js.design/assets/img/678f560988986af5661c2876.png#a3be067970d2c78a56d08024581a9ca0)',
11
- backgroundSize: '100% 100%'
12
- }">
8
+ <view v-if="!showMask" class="jfb-base-consump-code__body" :style="[bodyStyleComp]">
13
9
  <view class="content-box">
14
10
  <view class="logo-box">
15
11
  <image v-if="shopLogo" :src="shopLogo" class="logo"></image>
@@ -108,7 +104,7 @@
108
104
  </view>
109
105
  <view :style="{
110
106
  minHeight: layoutInfo.bodyMinHeightRpx + 'rpx',
111
- background: 'url(https://img1-b.jufubao.cn/uploads/20250507/1a97fda8cd8804f9bcf984da10e0a666.png?x-oss-process=style/size8)',
107
+ backgroundImage: 'url(https://img1-b.jufubao.cn/uploads/20250507/1a97fda8cd8804f9bcf984da10e0a666.png?x-oss-process=style/size8)',
112
108
  backgroundSize: '100% 100%'
113
109
  }" v-else>
114
110
  <view
@@ -149,6 +145,9 @@
149
145
  >
150
146
  <shop-list
151
147
  v-if="showShopList"
148
+ :style="{
149
+ '--main-color': mainColor,
150
+ }"
152
151
  :getList="p_getShopList"
153
152
  @handleCityDone="handleCityDone"
154
153
  @handleCityChange="handleCityChange"
@@ -248,6 +247,8 @@
248
247
  deductDialog: false,
249
248
  paySortList: [],
250
249
  tempList: [],
250
+
251
+ bodyBgImg: "",
251
252
  }
252
253
  },
253
254
  watch: {
@@ -293,8 +294,16 @@
293
294
  return this.total_price === '' || !this.tag_id;
294
295
  },
295
296
  curPaySelectShow(){
297
+ if(this.paySortList.length === 0) return ''
296
298
  let curPay = this.paySortList[0];
297
- return curPay.pay_method_name + (curPay.wallet_amount ? `: ${$xdUniHelper.divisionFloatNumber(curPay.wallet_amount, 100)}` : '')
299
+ return curPay.pay_method_name + (curPay.pay_method !== 'card' ? `: ${this.$xdUniHelper.divisionFloatNumber(curPay.wallet_amount, 100)}` : '')
300
+ },
301
+ bodyStyleComp(){
302
+ return {
303
+ minHeight: this.layoutInfo.bodyMinHeightRpx + 'rpx',
304
+ backgroundImage: `url(${this.bodyBgImg})`,
305
+ backgroundSize: '100% 100%'
306
+ }
298
307
  }
299
308
  },
300
309
  created() {
@@ -389,6 +398,7 @@
389
398
  ).value;
390
399
  this.cityPath = getContainerPropsValue(container, 'content.cityPath', { value: "" }
391
400
  ).value;
401
+ this.bodyBgImg = getServiceUrl(getContainerPropsValue(container, 'content.bodyBgImg', {url: ""}).url)
392
402
  },
393
403
  handleSortClose(){
394
404
  this.deductDialog = false;
@@ -11,8 +11,8 @@ module.exports = {
11
11
  batchConsumpUseCardCreated: { "request_order_id": "quickpay-5000358-DBeMnvrvInuINYeTqbCXw", "request_id": "e17499843ece44b1" },
12
12
 
13
13
  getConsumpAsyncSubmitStatus: { "hand_status": "U", "hand_status_msg": "异步下单中", "order_id": "", "pay_order_id": "", "need_pay_price": "0", "request_id": "fddff0af4216825d" },
14
-
15
- getConsumpShopList: { "namespaces": [{ "label": "蛋糕(勿改)", "value": "cake" }], "brands": [{ "label": "测试1111", "value": 14, "icon": "\/uploads\/20230324\/3265afeb6a1f2a94f25c968a09275574.png" }, { "label": "品牌jls0519", "value": 100003, "icon": "\/uploads\/20230710\/44f645b06fe4da358f7b0ee06259afcd.jpg" }], "list": [{ "brand_id": 14, "brand_name": "测试1111", "brand_type": "MA", "business_status": "CLOSED", "consume_mode": ["SELL"], "consume_mode_name": "", "distance": "42km", "distance_conversion": "41.9km", "default_consume_type": "CV", "consume_type": ["CV"], "is_support_jhd": true, "address": "顺义区东六环与顺于路交叉口东150米", "province_name": "", "city_name": "", "area_name": "", "street_name": "", "phone": "(010)89430806", "resource_shop_id": 8003489, "exts_params": "eyJyZXNvdXJjZV9zaG9wX2lkIjo4MDAzNDg5LCJzaG9wX2lkIjoxMTUzNTIwLCJ2ZXJzaW9uIjoyfQ", "resource_shop_name": "六九豆浆饺子(石门市场店)", "shop_icon": "\/uploads\/20230324\/3265afeb6a1f2a94f25c968a09275574.png", "shop_id": 1153520, "shop_tags": [], "stars": 0, "time_slot_name": "-", "business_code": "", "longitude": "116.630756", "latitude": "40.134773" }, { "brand_id": 100003, "brand_name": "品牌jls0519", "brand_type": "MA", "business_status": "OPEN_BUSINESS", "consume_mode": ["SELL"], "consume_mode_name": "", "distance": "55km", "distance_conversion": "54.8km", "default_consume_type": "", "consume_type": [""], "is_support_jhd": false, "address": "东城区东直门街道东城区东直门内南大街4号(东直门内第一个十字路口东南角)", "province_name": "", "city_name": "", "area_name": "", "street_name": "", "phone": "64034959", "resource_shop_id": 8000077, "exts_params": "eyJyZXNvdXJjZV9zaG9wX2lkIjo4MDAwMDc3LCJzaG9wX2lkIjoxMDIzNTMwLCJ2ZXJzaW9uIjoyfQ", "resource_shop_name": "东直门[2]", "shop_icon": "\/uploads\/20230710\/44f645b06fe4da358f7b0ee06259afcd.jpg", "shop_id": 1023530, "shop_tags": [], "stars": 0, "time_slot_name": "09:00-18:00", "business_code": "", "longitude": "116.44373384708321", "latitude": "39.94636369444035" }, { "brand_id": 100003, "brand_name": "品牌jls0519", "brand_type": "MA", "business_status": "OPEN_BUSINESS", "consume_mode": ["SELL"], "consume_mode_name": "", "distance": "56km", "distance_conversion": "55.5km", "default_consume_type": "JHD", "consume_type": ["JHD"], "is_support_jhd": true, "address": "东城区建国门街道北京inn", "province_name": "", "city_name": "", "area_name": "", "street_name": "", "phone": "18843854566", "resource_shop_id": 8000078, "exts_params": "eyJyZXNvdXJjZV9zaG9wX2lkIjo4MDAwMDc4LCJzaG9wX2lkIjoxMDM3MjY2LCJ2ZXJzaW9uIjoyfQ", "resource_shop_name": "a加盟商-185", "shop_icon": "\/uploads\/20230710\/44f645b06fe4da358f7b0ee06259afcd.jpg", "shop_id": 1037266, "shop_tags": [], "stars": 0, "time_slot_name": "-", "business_code": "", "longitude": "116.43814998003319", "latitude": "39.9280800962547" }], "total_size": 3, "next_page_token": "", "request_id": "fa91f05cff4b280b" },
14
+
15
+ getConsumpShopList: {"categories":[{"label":"商超","value":100518},{"label":"蛋糕店","value":100519}],"namespaces":[{"label":"蛋糕(勿改)","value":"cake"}],"brands":[{"label":"测试1111","value":14,"icon":"\/uploads\/20230324\/3265afeb6a1f2a94f25c968a09275574.png"},{"label":"好利来","value":3,"icon":"\/uploads\/20230524\/b18190a6d80ae31a84a1ed53fc0dc8aa.jpg"}],"list":[{"brand_id":14,"brand_name":"测试1111","brand_type":"MA","business_status":"OPEN_BUSINESS","consume_mode":["SELL"],"consume_mode_name":"","distance":"37km","distance_conversion":"36.8km","default_consume_type":"CV","consume_type":["CV"],"is_support_jhd":false,"address":"通州区马驹桥镇北京通州区","province_name":"","city_name":"","area_name":"","street_name":"","phone":"13152565898","resource_shop_id":8003538,"exts_params":"eyJyZXNvdXJjZV9zaG9wX2lkIjo4MDAzNTM4LCJzaG9wX2lkIjoxMDUwMzQyLCJ2ZXJzaW9uIjoyfQ","resource_shop_name":"新建559","shop_icon":"https://sandbox-img2.jufubao.cn\/uploads\/20230324\/3265afeb6a1f2a94f25c968a09275574.png","shop_id":1050342,"shop_tags":[],"stars":0,"time_slot_name":"-","business_code":"","longitude":"116.6634126629373","latitude":"39.91601857510662","discount_ratio":7200},{"brand_id":14,"brand_name":"测试1111","brand_type":"MA","business_status":"CLOSED","consume_mode":["SELL"],"consume_mode_name":"","distance":"38km","distance_conversion":"37.9km","default_consume_type":"CV","consume_type":["CV"],"is_support_jhd":true,"address":"顺义区东六环与顺于路交叉口东150米","province_name":"","city_name":"","area_name":"","street_name":"","phone":"(010)89430806","resource_shop_id":8003489,"exts_params":"eyJyZXNvdXJjZV9zaG9wX2lkIjo4MDAzNDg5LCJzaG9wX2lkIjoxMTUzNTIwLCJ2ZXJzaW9uIjoyfQ","resource_shop_name":"六九豆浆饺子(石门市场店)","shop_icon":"https://sandbox-img2.jufubao.cn\/uploads\/20230324\/3265afeb6a1f2a94f25c968a09275574.png","shop_id":1153520,"shop_tags":[],"stars":0,"time_slot_name":"-","business_code":"","longitude":"116.65307505295904","latitude":"40.07088305940431","discount_ratio":7200}],"total_size":6,"next_page_token":"2","request_id":"d7071936733ed3f5"},
16
16
 
17
17
  getConsumpSettleMainInfo: { "shop_id": 1037266, "shop_logo": "\/uploads\/20230710\/44f645b06fe4da358f7b0ee06259afcd.jpg", "shop_name": "a加盟商-185", "shop_brand": 100003, "shop_partner_name": "A加盟商-余额测试", "settle_tag_list": [{ "label": "幸福西饼、goodlike品牌", "value": 262, "price": 0, "price_yuan": "0.00", "is_static_price": false, "icon_url": "https:\/\/sandbox-img.jufubao.cn\/uploads\/20230728\/70f4dd90cdf2681e71ccf41d332d71a0.jpeg" }], "request_id": "a4a6cfe9db905597" },
18
18
 
@@ -13,7 +13,7 @@
13
13
  </view>
14
14
  <view class="shop_list" v-if="list && list.length">
15
15
  <view
16
- class="shop_item"
16
+ class="shop_item" :class="{active: i === 0}"
17
17
  v-for="(item,i) in list"
18
18
  :key="item.shop_id"
19
19
  @click="$emit('onChose', item)"
@@ -22,9 +22,12 @@
22
22
  <image :src="item.shop_icon" />
23
23
  </view>
24
24
  <view class="shop_info">
25
- <view class="shop_name">
26
- <view class="_name">{{ item.resource_shop_name }}</view>
27
- <view class="distance" v-if='item.distance'>{{ item.distance }}</view>
25
+ <view class="shop_top">
26
+ <view class="shop_name">
27
+ <view class="_name">{{ item.resource_shop_name }}</view>
28
+ <view class="distance" v-if='item.distance'>{{ item.distance }}</view>
29
+ </view>
30
+ <view v-if="item.discount_ratio" class="shop_radio">全店{{ item.discount_ratio/1000 }}折</view>
28
31
  </view>
29
32
  <view class='shop_addr'>{{ item.address }}</view>
30
33
  </view>
@@ -34,7 +37,9 @@
34
37
  </view>
35
38
  </view>
36
39
  <view v-else class="empty_data">
37
- <xd-no-data icon-type="shop" height="100%">附近暂无推荐门店</xd-no-data>
40
+ <xd-no-data :scaleSize="2.5" icon-type="shop" height="100%">
41
+ <view style="margin-top: -100rpx;">附近暂无推荐门店</view>
42
+ </xd-no-data>
38
43
  </view>
39
44
  </view>
40
45
  </template>
@@ -75,6 +80,11 @@ export default {
75
80
  stateLocation: state => state.cityLocation.location || {},
76
81
  }),
77
82
  },
83
+ watch: {
84
+ stateCity(){
85
+ this.p_getList();
86
+ }
87
+ },
78
88
  created(){
79
89
  this.p_getList();
80
90
  },
@@ -186,6 +196,11 @@ export default {
186
196
  background: #FFFFFF;
187
197
  padding: 20rpx;
188
198
  margin-bottom: 20rpx;
199
+ border-radius: 12rpx;
200
+
201
+ &.active{
202
+ border: 1px solid var(--main-color);
203
+ }
189
204
  }
190
205
  .shop_image{
191
206
  width: 200rpx;
@@ -207,6 +222,14 @@ export default {
207
222
  .shop_addr{
208
223
  color: #999999;
209
224
  font-size: 24rpx;
225
+ margin-top: 12rpx;
226
+ }
227
+ }
228
+ .shop_top{
229
+ .shop_radio{
230
+ font-size: 24rpx;
231
+ color: rgba(255, 87, 51, 1);
232
+ margin-top: 12rpx;
210
233
  }
211
234
  }
212
235
  .shop_name{
@@ -215,7 +238,6 @@ export default {
215
238
  justify-content: space-between;
216
239
  font-size: 32rpx;
217
240
  color: #242424;
218
- height: 120rpx;
219
241
  ._name{
220
242
  flex: 1;
221
243
  width: 200rpx;
@@ -8,13 +8,16 @@
8
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
- <view class="profile">
12
- <image v-if="info.head_url" :src="info.head_url"></image>
13
- <image v-else src="https://img1-b.jufubao.cn/uploads/20250528/e88bb70d4ccdcdd01a277bdf6b66c488.jpg"></image>
11
+ <view class="profile_wrap">
12
+ <view class="profile">
13
+ <image v-if="info.head_url" :src="info.head_url"></image>
14
+ <image v-else src="https://img1-b.jufubao.cn/uploads/20250528/e88bb70d4ccdcdd01a277bdf6b66c488.jpg"></image>
15
+ </view>
14
16
  <!--#ifdef MP-->
15
17
  <button type="default" open-type="chooseAvatar" @chooseavatar="handleChooseAvatar"></button>
16
18
  <!-- #endif -->
17
19
  </view>
20
+
18
21
 
19
22
  </view>
20
23
  <view class="jfb-base-personal-data__body-item">
@@ -54,6 +57,7 @@
54
57
  v-model="info.sex"
55
58
  :list="sexList"
56
59
  width="100%"
60
+ style="width:100%;"
57
61
  justifyContent="flex-end"
58
62
  >
59
63
  <template>
@@ -227,6 +231,19 @@
227
231
 
228
232
  .jfb-base-personal-data {
229
233
  &__body {
234
+ .profile_wrap{
235
+ width: 100%;
236
+ height: 80rpx;
237
+ position: relative;
238
+ & > button {
239
+ position: absolute;
240
+ right: 0;
241
+ top: 0;
242
+ opacity: 0;
243
+ width: 100%;
244
+ height: 100%;
245
+ }
246
+ }
230
247
  .icon {
231
248
  margin-left: 8rpx;
232
249
  }
@@ -258,8 +275,10 @@
258
275
  width: 80rpx;
259
276
  height: 80rpx;
260
277
  border-radius: 50%;
261
- position: relative;
278
+ position: absolute;
262
279
  overflow: hidden;
280
+ right: 0;
281
+ top: 0;
263
282
 
264
283
  & > image {
265
284
  width: 78rpx;
@@ -268,14 +287,6 @@
268
287
  border:1px solid #ccc;
269
288
  box-sizing: border-box;
270
289
  }
271
- & > button {
272
- position: absolute;
273
- left: 0;
274
- right: 0;
275
- bottom: 0;
276
- top: 0;
277
- opacity: 0;
278
- }
279
290
  }
280
291
  }
281
292
  }
@@ -12,7 +12,7 @@
12
12
  <view class="jfb-base-points-card__body-list-item-label">
13
13
  {{item.name}}
14
14
  </view>
15
- <view v-if="item.method!=='coupon'" class="jfb-base-points-card__body-list-item-value">{{getAmout(item.amount)}}</view>
15
+ <view v-if="item.method==='wallet'||item.method==='score'" class="jfb-base-points-card__body-list-item-value">{{getAmout(item.amount)}}</view>
16
16
  <view v-else class="jfb-base-points-card__body-list-item-value">{{item.coupon_count}}</view>
17
17
  </view>
18
18
  </view>
@@ -127,7 +127,7 @@
127
127
  if (item.method === 'wallet') {
128
128
  this.$xdUniHelper.navigateTo({ url: `${this.withdrawPath}?method=wallet` })
129
129
  }
130
- if (item.method === 'coupon') {
130
+ if (item.method === 'coupon' || item.method === 'card') {
131
131
  this.$xdUniHelper.navigateTo({ url: this.couponPath })
132
132
  }
133
133
  },
@@ -13,6 +13,16 @@ module.exports = [
13
13
  isRule: false,
14
14
  isConsole: true,
15
15
  disabled: true,
16
+ },
17
+ {
18
+ mapFnName: "getVipMoneySaving",
19
+ title: "获取会员省钱金额",
20
+ path: '/member/v1/money-saving-record/total-amount',
21
+ isRule: false,
22
+ params: {
23
+ },
24
+ isConsole: true,
25
+ disabled: true
16
26
  }
17
27
 
18
28
  ];
@@ -20,18 +20,18 @@
20
20
  <image v-else @click="handleToPersonal" :style="{border: `1px solid ${imageColor}`, borderRadius:imageRadius}" src="https://img1-b.jufubao.cn/uploads/20250528/e88bb70d4ccdcdd01a277bdf6b66c488.jpg"></image>
21
21
  <view class="jfb-base-user-info__body-plus-header-top-left-info">
22
22
  <view class="jfb-base-user-info__body-plus-header-top-left-info-name" v-if="logined">
23
- <view :style="is_vip==='Y'?[plusNickNameStyle]:[normalNickNameStyle]">{{userInfo|getName}} </view>
23
+ <view :style="[nickStyleComp]">{{userInfo|getName}} </view>
24
24
  <view v-if="is_vip==='Y'"><text>PLUS</text>会员</view>
25
25
  <view v-else>普通用户</view>
26
26
  </view>
27
27
  <view>
28
28
  <view v-if="is_vip==='Y'">
29
- <text style="color:#D19E6B;">已省</text><text style="color: #FEE9CC;">¥30.00</text>
29
+ <text style="color:#D19E6B;">已省</text><text style="color: #FEE9CC;">¥{{ $xdUniHelper.divisionFloatNumber(save_amount, 100) }}</text>
30
30
  </view>
31
- <view v-else>
31
+ <!-- <view v-else>
32
32
  <text style="color:#CCCCCC;">开通会员预计可省</text>
33
33
  <text style="color:#FFFFFF;">¥49.00</text>
34
- </view>
34
+ </view> -->
35
35
  </view>
36
36
  </view>
37
37
  </view>
@@ -42,7 +42,7 @@
42
42
  <view :style="[boxPlusStyleCompBottom]" :class="is_vip==='Y'?'is_vip_bottom':'is_normal_bottom'"
43
43
  class="jfb-base-user-info__body-plus-header-bottom">
44
44
  <view class="_left">
45
- <view v-if="is_vip==='Y'">有效期至:2025年10月01日</view>
45
+ <view v-if="is_vip==='Y'">有效期至:{{ userInfo.vip_expire_time }}</view>
46
46
  <view v-else></view>
47
47
  </view>
48
48
  <view class="_right">
@@ -204,6 +204,9 @@
204
204
  if (this.is_border === 'Y') return `${this.is_border_w}rpx ${this.is_border_s} ${this.is_border_c}`;
205
205
  else return '0';
206
206
  },
207
+ nickStyleComp(){
208
+ return this.is_vip==='Y'? this.plusNickNameStyle:this.normalNickNameStyle
209
+ },
207
210
  plusNickNameStyle() {
208
211
  return {
209
212
  fontSize: this.plusNickStyle.fontSize || '32rpx',
@@ -257,6 +260,7 @@
257
260
  isSetting: 'N',
258
261
  // logoutName:'[退出登录]',
259
262
  imageRadius: '50%',
263
+ save_amount: 0,
260
264
 
261
265
  //基础
262
266
  imageColor: '#333',
@@ -378,10 +382,14 @@
378
382
  }).then(res => {
379
383
  res = res || {};
380
384
  if(res['head_url']) res['head_url'] = getServiceUrl(res['head_url'], 'size2')
385
+ res.vip_expire_time = this.$xdUniHelper.getDate(
386
+ res.vip_expire_time * 1000
387
+ ).fullDate;
381
388
  this.userInfo = res;
382
389
  }).catch(error => {
383
390
  console.log('getBaseUserInfo', error)
384
391
  })
392
+ this.p_getVipMoneySaving();
385
393
  },
386
394
  /**
387
395
  * @description 监听事件变化
@@ -451,6 +459,14 @@
451
459
  this.$xdRoot.$emit("setLayoutPageBg", bg);
452
460
  }
453
461
  },
462
+ p_getVipMoneySaving(){
463
+ jfbRootExec("getVipMoneySaving", {
464
+ vm: this,
465
+ data: {}
466
+ }).then(res => {
467
+ this.save_amount = res.save_amount;
468
+ })
469
+ },
454
470
  handleToPersonal(){
455
471
  this.$xdUniHelper.navigateTo({
456
472
  url: this.profilePath