jufubao-base 1.0.192-beta1 → 1.0.193
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/commands.js +1 -1
- package/package.json +1 -1
- package/src/components/JfbBaseAddress/Attr.js +1 -109
- package/src/components/JfbBaseAddress/JfbBaseAddress.vue +77 -153
- package/src/components/JfbBaseFastLink/Attr.js +6 -22
- package/src/components/JfbBaseFastLink/JfbBaseFastLink.vue +20 -35
- package/src/components/JfbBaseFooter/Attr.js +75 -141
- package/src/components/JfbBaseFooter/JfbBaseFooter.vue +15 -50
- package/src/components/JfbBaseLogin/Attr.js +1 -6
- package/src/components/JfbBaseOrderDetail/Attr.js +65 -147
- package/src/components/JfbBaseOrderDetail/JfbBaseOrderDetail.vue +46 -96
- package/src/components/JfbBaseOrderList/Attr.js +2 -59
- package/src/components/JfbBaseOrderList/JfbBaseOrderList.vue +92 -139
- package/src/components/JfbBaseOrderList/Mock.js +0 -3
- package/src/components/JfbBasePhoneCollect/Attr.js +1 -6
- package/src/components/JfbBasePhoneLogin/Attr.js +1 -6
- package/src/components/JfbBaseUserCenter/Attr.js +48 -240
- package/src/components/JfbBaseUserCenter/JfbBaseUserCenter.vue +30 -101
- package/src/components/JfbBaseUserInfo/Attr.js +30 -179
- package/src/components/JfbBaseUserInfo/JfbBaseUserInfo.vue +44 -80
- package/src/components/JfbBaseUserOrder/Attr.js +25 -291
- package/src/components/JfbBaseUserOrder/JfbBaseUserOrder.vue +54 -172
- package/src/components/JfbBaseWallet/Attr.js +2 -340
- package/src/components/JfbBaseWallet/JfbBaseWallet.vue +49 -173
- package/src/ICONS.js +0 -1128
- package/src/components/JfbBaseAddress/XdTfkItem.vue +0 -117
- package/src/components/JfbBaseOrderList/XdTfkOrderItem.vue +0 -267
|
@@ -13,18 +13,25 @@
|
|
|
13
13
|
<view class="jfb-base-user-order__edit-icon" @click="delEdit">删除</view>
|
|
14
14
|
</view>
|
|
15
15
|
<!-- #endif -->
|
|
16
|
-
<view
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
<view
|
|
17
|
+
v-if="list.length > 0"
|
|
18
|
+
class="jfb-base-user-order__body"
|
|
19
|
+
:style="{ padding: outMargin}"
|
|
20
|
+
>
|
|
21
|
+
<view :style="{borderRadius: bodyRadius + 'rpx', backgroundColor:bodyBackgroundColor, padding:outPadding}">
|
|
19
22
|
<view class="my-order__add">
|
|
20
|
-
<view :style="
|
|
21
|
-
<view
|
|
22
|
-
v-if="isShowBtn === 'Y'"
|
|
23
|
-
@click="handleToLink(afterUrl)"
|
|
24
|
-
:style="[addBtnStyleComp]"
|
|
25
|
-
>{{afterBuyName}}</view>
|
|
23
|
+
<view :style="{color:cardNameColor}">我的订单</view>
|
|
24
|
+
<view @click="handleToLink(afterUrl)" :style="{borderColor:subColor || mainColor,color: subColor || mainColor}">售后订单</view>
|
|
26
25
|
</view>
|
|
27
|
-
<view
|
|
26
|
+
<view
|
|
27
|
+
class="my-order__content"
|
|
28
|
+
:style="{
|
|
29
|
+
borderRadius: radius + 'rpx',
|
|
30
|
+
background: backgroundColor,
|
|
31
|
+
marginTop: spacing + 'rpx',
|
|
32
|
+
border: borderBox,
|
|
33
|
+
}"
|
|
34
|
+
>
|
|
28
35
|
<view class="my-order__content-type">
|
|
29
36
|
<view
|
|
30
37
|
class="my-order__content-type-item"
|
|
@@ -33,16 +40,14 @@
|
|
|
33
40
|
@click="handleToLink(orderListUrl, item.status)"
|
|
34
41
|
>
|
|
35
42
|
<view class="my-order__content-type-item-icon">
|
|
36
|
-
<image v-if="item.image" :src="item.image"></image>
|
|
37
43
|
<xd-font-icon
|
|
38
|
-
v-else
|
|
39
44
|
:icon="item.icon"
|
|
40
45
|
:color="iconColor"
|
|
41
46
|
:size="item.size"
|
|
42
47
|
></xd-font-icon>
|
|
43
48
|
<view
|
|
44
49
|
v-if="item.num"
|
|
45
|
-
:style="
|
|
50
|
+
:style="{backgroundColor: iconColor}"
|
|
46
51
|
class="my-order__content-type-item-number"
|
|
47
52
|
>{{item.num}}</view>
|
|
48
53
|
</view>
|
|
@@ -62,7 +67,6 @@
|
|
|
62
67
|
import componentsMixins from "@/mixins/componentsMixins";
|
|
63
68
|
import extsMixins from "@/mixins/extsMixins"
|
|
64
69
|
import { getContainerPropsValue } from "@/utils/xd.base";
|
|
65
|
-
import getServiceUrl from "@/common/getServiceUrl";
|
|
66
70
|
export default {
|
|
67
71
|
name: "JfbBaseUserOrder",
|
|
68
72
|
components: {
|
|
@@ -70,95 +74,23 @@
|
|
|
70
74
|
},
|
|
71
75
|
mixins: [componentsMixins,extsMixins,JfbBaseUserOrderMixin],
|
|
72
76
|
computed: {
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
return
|
|
79
|
-
fontSize: this.titleStyle.fontSize || '28rpx',
|
|
80
|
-
color: `${this.titleStyle.color || this.cardNameColor ||'#333'}`,
|
|
81
|
-
fontWeight: `${this.titleStyle.fontWeight || 'normal'}`,
|
|
82
|
-
}
|
|
83
|
-
},
|
|
84
|
-
bodyStyleComp(){
|
|
85
|
-
let margin = `${this.checkValue(this.bodyMargin.top, 20)}rpx`;
|
|
86
|
-
margin = `${margin} ${this.checkValue(this.bodyMargin.right, 20)}rpx`;
|
|
87
|
-
margin = `${margin} ${this.checkValue(this.bodyMargin.bottom, 20)}rpx`;
|
|
88
|
-
margin = `${margin} ${this.checkValue(this.bodyMargin.left, 20)}rpx`;
|
|
89
|
-
|
|
90
|
-
let padding = `${this.checkValue(this.bodyPadding.top, 0)}rpx`;
|
|
91
|
-
padding = `${padding} ${this.checkValue(this.bodyPadding.right, 0)}rpx`;
|
|
92
|
-
padding = `${padding} ${this.checkValue(this.bodyPadding.bottom, 0)}rpx`;
|
|
93
|
-
padding = `${padding} ${this.checkValue(this.bodyPadding.left, 0)}rpx`;
|
|
94
|
-
|
|
95
|
-
return {
|
|
96
|
-
margin,
|
|
97
|
-
padding,
|
|
98
|
-
borderRadius: this.bodyRadius + 'rpx',
|
|
99
|
-
backgroundColor: this.bodyBackgroundColor,
|
|
100
|
-
}
|
|
77
|
+
outPadding() {
|
|
78
|
+
let str = `${this.checkValue(this.bodyPadding.top, 0)}rpx`;
|
|
79
|
+
str = `${str} ${this.checkValue(this.bodyPadding.right, 0)}rpx`;
|
|
80
|
+
str = `${str} ${this.checkValue(this.bodyPadding.bottom, 0)}rpx`;
|
|
81
|
+
str = `${str} ${this.checkValue(this.bodyPadding.left, 0)}rpx`;
|
|
82
|
+
return str
|
|
101
83
|
},
|
|
102
|
-
|
|
103
|
-
let
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
if(value.style) border['borderStyle'] = value.style;
|
|
109
|
-
}
|
|
110
|
-
let addBtnShadow = {};
|
|
111
|
-
if(this.addBtnShadow && this.addBtnShadow.type === 'Y') {
|
|
112
|
-
let value = this.addBtnShadow.value || {};
|
|
113
|
-
if(value.color && value.width) {
|
|
114
|
-
addBtnShadow['boxShadow'] = `0 0 ${value.width}rpx ${value.color}`
|
|
115
|
-
}
|
|
116
|
-
}
|
|
117
|
-
return {
|
|
118
|
-
color: this.addBtnStyle.color || this.mainColor,
|
|
119
|
-
fontSize: this.addBtnStyle.fontSize || '26rpx',
|
|
120
|
-
fontWeight: this.addBtnStyle.fontWeight || 'normal',
|
|
121
|
-
borderColor: this.mainColor,
|
|
122
|
-
borderWidth: '2rpx',
|
|
123
|
-
borderStyle:'solid',
|
|
124
|
-
backgroundColor: this.addBtnBgColor || 'rgba(0,0,0,0)',
|
|
125
|
-
borderRadius:this.addBtnRadius + 'rpx',
|
|
126
|
-
...border,
|
|
127
|
-
...addBtnShadow
|
|
128
|
-
}
|
|
84
|
+
outMargin() {
|
|
85
|
+
let str = `${this.checkValue(this.bodyMargin.top, 20)}rpx`;
|
|
86
|
+
str = `${str} ${this.checkValue(this.bodyMargin.right, 20)}rpx`;
|
|
87
|
+
str = `${str} ${this.checkValue(this.bodyMargin.bottom, 20)}rpx`;
|
|
88
|
+
str = `${str} ${this.checkValue(this.bodyMargin.left, 20)}rpx`;
|
|
89
|
+
return str
|
|
129
90
|
},
|
|
130
|
-
|
|
131
|
-
return {
|
|
132
|
-
|
|
133
|
-
color: this.popColor || '#f00',
|
|
134
|
-
}
|
|
135
|
-
},
|
|
136
|
-
contStyleComp(){
|
|
137
|
-
let borderStyle = 'solid';
|
|
138
|
-
let borderWidth = 0;
|
|
139
|
-
let borderColor = 'rgba(0,0,0,0)';
|
|
140
|
-
if(this.is_border === 'Y') {
|
|
141
|
-
if(this.is_border_w !== undefined) borderWidth = this.is_border_w;
|
|
142
|
-
if(this.is_border_c !== undefined) borderColor = this.is_border_c;
|
|
143
|
-
}
|
|
144
|
-
if(this.contBorder && this.contBorder.type === 'Y') {
|
|
145
|
-
let value = this.contBorder.value ||{};
|
|
146
|
-
if(value.width) borderWidth = value.width + 'rpx';
|
|
147
|
-
if(value.color) borderColor = value.color;
|
|
148
|
-
if(value.style) borderStyle = value.style;
|
|
149
|
-
}
|
|
150
|
-
let padding = `${this.checkValue(this.contPadding.top, 40)}rpx`;
|
|
151
|
-
padding = `${padding} ${this.checkValue(this.contPadding.right, 20)}rpx`;
|
|
152
|
-
padding = `${padding} ${this.checkValue(this.contPadding.bottom, 34)}rpx`;
|
|
153
|
-
padding = `${padding} ${this.checkValue(this.contPadding.left, 20)}rpx`;
|
|
154
|
-
return {
|
|
155
|
-
borderRadius: this.radius + 'rpx',
|
|
156
|
-
backgroundColor: this.backgroundColor,
|
|
157
|
-
marginTop: this.spacing + 'rpx',
|
|
158
|
-
border: `${borderWidth} ${borderStyle} ${borderColor}`,
|
|
159
|
-
boxShadow: this.contShadow,
|
|
160
|
-
padding
|
|
161
|
-
}
|
|
91
|
+
borderBox() {
|
|
92
|
+
if (this.is_border === 'Y') return `${this.is_border_w}rpx solid ${this.is_border_c}`;
|
|
93
|
+
else return '0';
|
|
162
94
|
}
|
|
163
95
|
},
|
|
164
96
|
data() {
|
|
@@ -166,41 +98,14 @@
|
|
|
166
98
|
options: {},
|
|
167
99
|
list: [],
|
|
168
100
|
|
|
169
|
-
|
|
170
|
-
bodyPadding: {},
|
|
171
|
-
bodyRadius: 0,
|
|
172
|
-
bodyBackgroundColor: 'rgba(0,0,0,0)',
|
|
173
|
-
bodyMargin: { },
|
|
174
|
-
spacing:20,
|
|
175
|
-
|
|
176
|
-
//内容列表
|
|
101
|
+
//基础
|
|
177
102
|
color: '#333',
|
|
178
|
-
iconColor: '',
|
|
179
|
-
|
|
180
|
-
//我的标题
|
|
181
|
-
myOrderName: '我的订单',
|
|
182
|
-
cardNameColor: '#333',
|
|
183
|
-
titleStyle: {},
|
|
184
|
-
|
|
185
|
-
//售后订单
|
|
186
|
-
isShowBtn:'Y',
|
|
187
|
-
afterBuyName:'售后订单',
|
|
188
|
-
addBtnBgColor:'rgba(0,0,0,0)',
|
|
189
|
-
addBtnStyle:{},
|
|
190
|
-
addBtnBorder:{},
|
|
191
|
-
addBtnShadow:{},
|
|
192
|
-
addBtnRadius: '40',
|
|
193
|
-
|
|
194
|
-
//数字气泡
|
|
195
|
-
popColor:'#fff',
|
|
196
|
-
popBgColor:'#f00',
|
|
197
|
-
|
|
198
|
-
//content
|
|
199
103
|
backgroundColor: 'rgba(0,0,0,0)',
|
|
200
104
|
radius: 0,
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
105
|
+
iconColor: '',
|
|
106
|
+
spacing:20,
|
|
107
|
+
|
|
108
|
+
//边框
|
|
204
109
|
is_border: 'Y',
|
|
205
110
|
is_border_w: 0,
|
|
206
111
|
is_border_c: '',
|
|
@@ -209,6 +114,13 @@
|
|
|
209
114
|
afterUrl: null,
|
|
210
115
|
orderListUrl: null,
|
|
211
116
|
|
|
117
|
+
//整体
|
|
118
|
+
bodyPadding: {top: 20, left: 20, right: 20, bottom: 20},
|
|
119
|
+
bodyRadius: 0,
|
|
120
|
+
bodyBackgroundColor: 'rgba(0,0,0,0)',
|
|
121
|
+
bodyMargin: {top: 0, left: 0, right: 0, bottom: 0},
|
|
122
|
+
cardNameColor: '#333',
|
|
123
|
+
subColor:'',
|
|
212
124
|
}
|
|
213
125
|
},
|
|
214
126
|
watch: {
|
|
@@ -266,24 +178,6 @@
|
|
|
266
178
|
* @param container {object} 业务组件对象自己
|
|
267
179
|
*/
|
|
268
180
|
init(container) {
|
|
269
|
-
this.isShowBtn = getContainerPropsValue(container, 'content.isShowBtn', 'Y');
|
|
270
|
-
this.afterBuyName = getContainerPropsValue(container, 'content.afterBuyName', '售后订单');
|
|
271
|
-
|
|
272
|
-
//数字气泡
|
|
273
|
-
this.popColor = getContainerPropsValue(container, 'content.popColor', '#fff');
|
|
274
|
-
this.popBgColor = getContainerPropsValue(container, 'content.popBgColor', '#f00');
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
//标题
|
|
278
|
-
this.myOrderName = getContainerPropsValue(container, 'content.myOrderName', '我的订单')
|
|
279
|
-
this.titleStyle = getContainerPropsValue(container, 'content.titleStyle', {});
|
|
280
|
-
|
|
281
|
-
//添加按钮
|
|
282
|
-
this.addBtnBgColor = getContainerPropsValue(container, 'content.addBtnBgColor', 'rgba(0,0,0,0)');
|
|
283
|
-
this.addBtnStyle = getContainerPropsValue(container, 'content.addBtnStyle', {});
|
|
284
|
-
this.addBtnBorder = getContainerPropsValue(container, 'content.addBtnBorder', {});
|
|
285
|
-
this.addBtnRadius = getContainerPropsValue(container, 'content.addBtnRadius', '40');
|
|
286
|
-
this.addBtnShadow = getContainerPropsValue(container, 'content.addBtnShadow', {});
|
|
287
181
|
|
|
288
182
|
//整体
|
|
289
183
|
this.bodyMargin = getContainerPropsValue(container, 'content.bodyMargin', {top: 0, left: 0, right: 0, bottom: 0});
|
|
@@ -301,29 +195,23 @@
|
|
|
301
195
|
|
|
302
196
|
//基础
|
|
303
197
|
this.radius = getContainerPropsValue(container, 'content.radius', 0);
|
|
198
|
+
this.color = getContainerPropsValue(container, 'content.textColor', '#333');
|
|
199
|
+
this.iconColor = getContainerPropsValue(container, 'content.iconColor', this.mainColor);
|
|
304
200
|
this.backgroundColor = getContainerPropsValue(container, 'content.backgroundColor', '#f8f8f8');
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
this.contBorder = getContainerPropsValue(container, 'content.contBorder', {});
|
|
201
|
+
|
|
202
|
+
//边框
|
|
308
203
|
this.is_border = getContainerPropsValue(container, 'content.is_border', 'N');
|
|
309
204
|
this.is_border_c = getContainerPropsValue(container, 'content.is_border_c', '#f8f8f8');
|
|
310
205
|
this.is_border_w = getContainerPropsValue(container, 'content.is_border_w', '2');
|
|
311
206
|
|
|
312
|
-
|
|
207
|
+
|
|
313
208
|
this.list = getContainerPropsValue(container, 'content.orderTypeList', []).map(item=>{
|
|
314
|
-
let image = '';
|
|
315
|
-
if(this.$xdUniHelper.checkVarType(item.image) === 'object') {
|
|
316
|
-
image = getServiceUrl(item.image.url, 'size1');
|
|
317
|
-
}
|
|
318
209
|
return {
|
|
319
210
|
...item,
|
|
320
|
-
image,
|
|
321
211
|
size: Number(item.size ? item.size: 18) * 2,
|
|
322
212
|
num: 0
|
|
323
213
|
}
|
|
324
|
-
})
|
|
325
|
-
this.color = getContainerPropsValue(container, 'content.textColor', '#333');
|
|
326
|
-
this.iconColor = getContainerPropsValue(container, 'content.iconColor', this.mainColor);
|
|
214
|
+
})
|
|
327
215
|
},
|
|
328
216
|
|
|
329
217
|
onJfbShow(options) {
|
|
@@ -331,7 +219,6 @@
|
|
|
331
219
|
},
|
|
332
220
|
|
|
333
221
|
handleToLink(path, type) {
|
|
334
|
-
if (this.$configProject['isPreview']) return;
|
|
335
222
|
this.$xdUniHelper.navigateTo({
|
|
336
223
|
url: type ? `${path}?type=${type}` : path
|
|
337
224
|
})
|
|
@@ -357,7 +244,6 @@
|
|
|
357
244
|
justify-content: space-between;
|
|
358
245
|
align-items: center;
|
|
359
246
|
font-size: unit(28, rpx);
|
|
360
|
-
min-height: 62rpx;
|
|
361
247
|
|
|
362
248
|
& > view:nth-child(2) {
|
|
363
249
|
width: unit(200, rpx);
|
|
@@ -374,6 +260,7 @@
|
|
|
374
260
|
display: flex;
|
|
375
261
|
justify-content: space-around;
|
|
376
262
|
align-items: center;
|
|
263
|
+
padding: unit(40, rpx) unit(20, rpx) unit(35, rpx);
|
|
377
264
|
|
|
378
265
|
&-item {
|
|
379
266
|
font-size: unit(24, rpx);
|
|
@@ -381,18 +268,13 @@
|
|
|
381
268
|
flex: 1;
|
|
382
269
|
|
|
383
270
|
&-icon {
|
|
384
|
-
height: unit(
|
|
385
|
-
width: unit(
|
|
271
|
+
height: unit(40, rpx);
|
|
272
|
+
width: unit(40, rpx);
|
|
386
273
|
display: flex;
|
|
387
274
|
justify-content: center;
|
|
388
275
|
align-items: center;
|
|
389
276
|
margin: 0 auto;
|
|
390
277
|
position: relative;
|
|
391
|
-
|
|
392
|
-
& > image {
|
|
393
|
-
max-width: 100%;
|
|
394
|
-
max-height: 100%;
|
|
395
|
-
}
|
|
396
278
|
}
|
|
397
279
|
|
|
398
280
|
&-text {
|