jufubao-base 1.0.190 → 1.0.192-beta1
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/get.package.path.js +2 -2
- package/package.json +1 -1
- package/src/ICONS.js +1128 -0
- package/src/components/JfbBaseAddress/Attr.js +109 -1
- package/src/components/JfbBaseAddress/JfbBaseAddress.vue +153 -77
- package/src/components/JfbBaseAddress/XdTfkItem.vue +117 -0
- package/src/components/JfbBaseFastLink/Attr.js +22 -6
- package/src/components/JfbBaseFastLink/JfbBaseFastLink.vue +35 -20
- package/src/components/JfbBaseFooter/Attr.js +141 -75
- package/src/components/JfbBaseFooter/JfbBaseFooter.vue +50 -15
- package/src/components/JfbBaseLogin/Attr.js +3 -9
- package/src/components/JfbBaseOrderDetail/Api.js +1 -0
- package/src/components/JfbBaseOrderDetail/Attr.js +201 -65
- package/src/components/JfbBaseOrderDetail/JfbBaseOrderDetail.vue +168 -57
- package/src/components/JfbBaseOrderList/Attr.js +59 -2
- package/src/components/JfbBaseOrderList/JfbBaseOrderList.vue +139 -92
- package/src/components/JfbBaseOrderList/Mock.js +3 -0
- package/src/components/JfbBaseOrderList/XdTfkOrderItem.vue +267 -0
- package/src/components/JfbBasePhoneCollect/Attr.js +933 -411
- package/src/components/JfbBasePhoneCollect/JfbBasePhoneCollect.vue +307 -27
- package/src/components/JfbBasePhoneLogin/Attr.js +882 -405
- package/src/components/JfbBasePhoneLogin/JfbBasePhoneLogin.vue +609 -253
- package/src/components/JfbBaseSuccess/Attr.js +1 -1
- package/src/components/JfbBaseTfkCardLogin/JfbBaseTfkCardLogin.vue +0 -1
- package/src/components/JfbBaseUserCenter/Attr.js +240 -48
- package/src/components/JfbBaseUserCenter/JfbBaseUserCenter.vue +101 -30
- package/src/components/JfbBaseUserInfo/Attr.js +179 -30
- package/src/components/JfbBaseUserInfo/JfbBaseUserInfo.vue +80 -44
- package/src/components/JfbBaseUserOrder/Attr.js +291 -25
- package/src/components/JfbBaseUserOrder/JfbBaseUserOrder.vue +172 -54
- package/src/components/JfbBaseWallet/Attr.js +344 -3
- package/src/components/JfbBaseWallet/JfbBaseWallet.vue +173 -49
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
import StyleForm from "@/utils/StyleForm";
|
|
3
|
+
import IConList from "@/ICONS"
|
|
3
4
|
let styleForm = new StyleForm(
|
|
4
5
|
{border: null, shadow: null, spacing: '', bgColor:'', margin: null},
|
|
5
6
|
null,
|
|
@@ -11,6 +12,35 @@ export default {
|
|
|
11
12
|
advanced: [],
|
|
12
13
|
content: (data)=>{
|
|
13
14
|
return [
|
|
15
|
+
{
|
|
16
|
+
label: "布局样式配置",
|
|
17
|
+
ele: "xd-radio",
|
|
18
|
+
valueKey: "layout_style",
|
|
19
|
+
value: data.layout_style || 'old',
|
|
20
|
+
list: [
|
|
21
|
+
{label: '布局1', value: 'old'},
|
|
22
|
+
{label: '布局2', value: 'tfk'},
|
|
23
|
+
],
|
|
24
|
+
groupKey: "style",
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
label: "编辑图标",
|
|
28
|
+
ele: "xd-select-list",
|
|
29
|
+
valueKey: "edit_icon",
|
|
30
|
+
value: data.edit_icon || 'iconbianji-01',
|
|
31
|
+
list: IConList,
|
|
32
|
+
className: 'input80',
|
|
33
|
+
groupKey: "content",
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
label: "删除图标",
|
|
37
|
+
ele: "xd-select-list",
|
|
38
|
+
valueKey: "delete_icon",
|
|
39
|
+
value: data.delete_icon || 'iconshanchu-01',
|
|
40
|
+
list: IConList,
|
|
41
|
+
className: 'input80',
|
|
42
|
+
groupKey: "content",
|
|
43
|
+
},
|
|
14
44
|
{
|
|
15
45
|
label: '选取地区路径:',
|
|
16
46
|
ele: 'xd-select-pages-path',
|
|
@@ -23,7 +53,85 @@ export default {
|
|
|
23
53
|
},
|
|
24
54
|
inline: false,
|
|
25
55
|
},
|
|
26
|
-
...styleForm.getForm(data, '内容列表样式配置')
|
|
56
|
+
...styleForm.getForm(data, '内容列表样式配置'),
|
|
57
|
+
{
|
|
58
|
+
label: "圆角设置",
|
|
59
|
+
ele: 'xd-site-select-list',
|
|
60
|
+
valueKey: 'cardRadius',
|
|
61
|
+
value: data['cardRadius'] || '',
|
|
62
|
+
groupKey:'style',
|
|
63
|
+
placeholder: '请选择内容圆角设置',
|
|
64
|
+
multiple: false,
|
|
65
|
+
className: 'input80',
|
|
66
|
+
handleCustom({ action, data }) {
|
|
67
|
+
XdBus.getParentApi('getOptionsSettingList')({ setting_id: 'edtix_style_radius' })
|
|
68
|
+
.then(res => {
|
|
69
|
+
data.cb(res.list)
|
|
70
|
+
})
|
|
71
|
+
.catch(error => {
|
|
72
|
+
console.error(error);
|
|
73
|
+
});
|
|
74
|
+
},
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
label: "底部按钮配置",
|
|
78
|
+
ele: "title",
|
|
79
|
+
groupKey: "style",
|
|
80
|
+
size: "small"
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
label: "容器内边距:",
|
|
84
|
+
ele: "xd-margin-padding",
|
|
85
|
+
valueKey: "bottomPadding",
|
|
86
|
+
value: data.bottomPadding || null,
|
|
87
|
+
groupKey: "style",
|
|
88
|
+
setting: {
|
|
89
|
+
type: 'padding',
|
|
90
|
+
},
|
|
91
|
+
placeholder: '请设置边距',
|
|
92
|
+
inline: false,
|
|
93
|
+
notice: '设置内边距,<span style="color: red">单位:像素</span>。默认值:<span style="color: red">20</span>像素',
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
label: "容器背景颜色:",
|
|
97
|
+
ele: "xd-color",
|
|
98
|
+
valueKey: "bottomBgColor",
|
|
99
|
+
value: data.bottomBgColor || null,
|
|
100
|
+
groupKey: "style",
|
|
101
|
+
},
|
|
102
|
+
{
|
|
103
|
+
label: "按钮背景颜色:",
|
|
104
|
+
ele: "xd-color",
|
|
105
|
+
valueKey: "bottomBtnBgColor",
|
|
106
|
+
value: data.bottomBtnBgColor || null,
|
|
107
|
+
groupKey: "style",
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
label: "按钮文字颜色:",
|
|
111
|
+
ele: "xd-color",
|
|
112
|
+
valueKey: "bottomBtnTextColor",
|
|
113
|
+
value: data.bottomBtnTextColor || null,
|
|
114
|
+
groupKey: "style",
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
label: "按钮圆角:",
|
|
118
|
+
ele: "xd-site-select-list",
|
|
119
|
+
valueKey: "bottomBtnRadius",
|
|
120
|
+
value: data['bottomBtnRadius'] || '',
|
|
121
|
+
groupKey:'style',
|
|
122
|
+
placeholder: '请选择内容圆角设置',
|
|
123
|
+
multiple: false,
|
|
124
|
+
className: 'input80',
|
|
125
|
+
handleCustom({ action, data }) {
|
|
126
|
+
XdBus.getParentApi('getOptionsSettingList')({ setting_id: 'edtix_style_radius' })
|
|
127
|
+
.then(res => {
|
|
128
|
+
data.cb(res.list)
|
|
129
|
+
})
|
|
130
|
+
.catch(error => {
|
|
131
|
+
console.error(error);
|
|
132
|
+
});
|
|
133
|
+
},
|
|
134
|
+
}
|
|
27
135
|
].filter(i=>i)
|
|
28
136
|
},
|
|
29
137
|
}
|
|
@@ -26,81 +26,108 @@
|
|
|
26
26
|
class="jfb-base-address__body-address"
|
|
27
27
|
v-if="addressList && addressList.length > 0"
|
|
28
28
|
>
|
|
29
|
-
<
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
29
|
+
<template v-if="layout_style === 'old'">
|
|
30
|
+
<view
|
|
31
|
+
:style="{
|
|
32
|
+
marginBottom: jfbListSpacing + 'rpx',
|
|
33
|
+
boxShadow: jfbListShadowComputed,
|
|
34
|
+
border: jfbListBorderComputed,
|
|
35
|
+
backgroundColor: jfbListBgColor,
|
|
36
|
+
borderRadius: cardRadius + 'rpx'
|
|
37
|
+
}"
|
|
38
|
+
class="jfb-base-address__body-address-item"
|
|
39
|
+
v-for="(item, index) in addressList"
|
|
40
|
+
@click="handleSelectAddress(item)"
|
|
41
|
+
:key="index"
|
|
42
|
+
>
|
|
43
|
+
<view class="jfb-base-address__body-address-item-top">
|
|
44
|
+
<view
|
|
45
|
+
v-if="item.is_default === 'Y'"
|
|
46
|
+
:style="{
|
|
47
|
+
backgroundColor: mainColor,
|
|
48
|
+
color: '#fff',
|
|
49
|
+
fontSize: '24rpx',
|
|
50
|
+
padding: '4rpx 10rpx',
|
|
51
|
+
borderRadius: '4rpx',
|
|
52
|
+
marginRight: '20rpx',
|
|
53
|
+
}"
|
|
54
|
+
>默认</view
|
|
55
|
+
>
|
|
56
|
+
<view
|
|
57
|
+
:style="{
|
|
58
|
+
color: '#999999',
|
|
59
|
+
flex: 1,
|
|
60
|
+
paddingRight: item.is_valid === 'N' ? '40rpx' : '',
|
|
61
|
+
}"
|
|
62
|
+
>
|
|
63
|
+
<view>
|
|
64
|
+
{{ item | getCodeName }}
|
|
65
|
+
</view>
|
|
66
|
+
</view>
|
|
67
|
+
<view
|
|
68
|
+
style="position: absolute; right: 40rpx; width: 50rpx"
|
|
69
|
+
v-if="item.is_valid === 'N'"
|
|
70
|
+
>
|
|
71
|
+
<xd-font-icon
|
|
72
|
+
size="32"
|
|
73
|
+
:color="dangerColor"
|
|
74
|
+
icon="iconmingchengtubiao"
|
|
75
|
+
></xd-font-icon>
|
|
76
|
+
</view>
|
|
77
|
+
</view>
|
|
78
|
+
<view class="jfb-base-address__body-address-item-middle">
|
|
79
|
+
{{ item.address_detail }} {{ item.house_number }}
|
|
80
|
+
</view>
|
|
54
81
|
<view
|
|
55
82
|
:style="{
|
|
56
|
-
|
|
57
|
-
flex: 1,
|
|
58
|
-
paddingRight: item.is_valid === 'N' ? '40rpx' : '',
|
|
83
|
+
backgroundColor: item.is_select === 'Y' ? mainColor : '#CCC',
|
|
59
84
|
}"
|
|
85
|
+
class="jfb-base-address__body-address-item-bottom"
|
|
60
86
|
>
|
|
61
87
|
<view>
|
|
62
|
-
{{ item
|
|
88
|
+
<view style="margin-right: 40rpx">{{ item.name }}</view>
|
|
89
|
+
<view>{{ item.phone }}</view>
|
|
90
|
+
</view>
|
|
91
|
+
<view>
|
|
92
|
+
<xd-font-icon
|
|
93
|
+
@click.native.stop="handleEdit(item)"
|
|
94
|
+
style="margin-right: 40rpx"
|
|
95
|
+
icon="iconbianji-01"
|
|
96
|
+
size="32"
|
|
97
|
+
></xd-font-icon>
|
|
98
|
+
<xd-font-icon
|
|
99
|
+
@click.native.stop="handleDel(item)"
|
|
100
|
+
icon="iconshanchu-01"
|
|
101
|
+
size="32"
|
|
102
|
+
></xd-font-icon>
|
|
63
103
|
</view>
|
|
64
|
-
</view>
|
|
65
|
-
<view
|
|
66
|
-
style="position: absolute; right: 40rpx; width: 50rpx"
|
|
67
|
-
v-if="item.is_valid === 'N'"
|
|
68
|
-
>
|
|
69
|
-
<xd-font-icon
|
|
70
|
-
size="32"
|
|
71
|
-
:color="dangerColor"
|
|
72
|
-
icon="iconmingchengtubiao"
|
|
73
|
-
></xd-font-icon>
|
|
74
104
|
</view>
|
|
75
105
|
</view>
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
</view>
|
|
106
|
+
</template>
|
|
107
|
+
<template v-else>
|
|
79
108
|
<view
|
|
80
109
|
:style="{
|
|
81
|
-
|
|
110
|
+
marginBottom: jfbListSpacing + 'rpx',
|
|
111
|
+
boxShadow: jfbListShadowComputed,
|
|
112
|
+
border: jfbListBorderComputed,
|
|
113
|
+
backgroundColor: jfbListBgColor,
|
|
114
|
+
borderRadius: cardRadius + 'rpx'
|
|
82
115
|
}"
|
|
83
|
-
|
|
116
|
+
v-for="(item, index) in addressList"
|
|
117
|
+
@click="handleSelectAddress(item)"
|
|
118
|
+
:key="index"
|
|
84
119
|
>
|
|
85
|
-
<
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
size="32"
|
|
95
|
-
></xd-font-icon>
|
|
96
|
-
<xd-font-icon
|
|
97
|
-
@click.native.stop="handleDel(item)"
|
|
98
|
-
icon="iconshanchu-01"
|
|
99
|
-
size="32"
|
|
100
|
-
></xd-font-icon>
|
|
101
|
-
</view>
|
|
120
|
+
<xd-tfk-item
|
|
121
|
+
:edit_icon="edit_icon"
|
|
122
|
+
:delete_icon="delete_icon"
|
|
123
|
+
:item="item"
|
|
124
|
+
:dangerColor="dangerColor"
|
|
125
|
+
@editAddress="handleEdit(item)"
|
|
126
|
+
@delAddress="handleDel(item)"
|
|
127
|
+
@setDefault="handleSetDefault(item)"
|
|
128
|
+
></xd-tfk-item>
|
|
102
129
|
</view>
|
|
103
|
-
</
|
|
130
|
+
</template>
|
|
104
131
|
</view>
|
|
105
132
|
<view class="jfb-base-address__body-empty" v-else>
|
|
106
133
|
<xd-font-icon icon="iconbianzu-01" size="120"></xd-font-icon>
|
|
@@ -108,13 +135,19 @@
|
|
|
108
135
|
</view>
|
|
109
136
|
<view style="height: 110rpx"></view>
|
|
110
137
|
<view class="jfb-base-address__body-footer" :style="prod_bottom">
|
|
111
|
-
<
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
138
|
+
<view :style="[bottomBoxStyle]">
|
|
139
|
+
<xd-button
|
|
140
|
+
width="100%"
|
|
141
|
+
type="primary"
|
|
142
|
+
:style="{
|
|
143
|
+
background: bottomBtnBgColor,
|
|
144
|
+
color: bottomBtnTextColor
|
|
145
|
+
}"
|
|
146
|
+
:radius="bottomBtnRadius+'rpx'"
|
|
147
|
+
@click="showAddress = !showAddress"
|
|
148
|
+
>+新增收货地址
|
|
149
|
+
</xd-button>
|
|
150
|
+
</view>
|
|
118
151
|
<xd-down-drawer
|
|
119
152
|
v-if="showAddress"
|
|
120
153
|
:show.sync="showAddress"
|
|
@@ -150,6 +183,7 @@ import componentsMixins from "@/mixins/componentsMixins";
|
|
|
150
183
|
import extsMixins from "@/mixins/extsMixins";
|
|
151
184
|
import StyleForm from "@/utils/StyleForm";
|
|
152
185
|
import { getContainerPropsValue } from "@/utils/xd.base";
|
|
186
|
+
import XdTfkItem from "./XdTfkItem"
|
|
153
187
|
let styleForm = new StyleForm(
|
|
154
188
|
{
|
|
155
189
|
border: null,
|
|
@@ -174,6 +208,7 @@ export default {
|
|
|
174
208
|
XdButton,
|
|
175
209
|
XdDownDrawer,
|
|
176
210
|
XdAddress,
|
|
211
|
+
XdTfkItem,
|
|
177
212
|
},
|
|
178
213
|
mixins: [componentsMixins, extsMixins, JfbBaseAddressMixin],
|
|
179
214
|
data() {
|
|
@@ -184,7 +219,17 @@ export default {
|
|
|
184
219
|
location_url: "",
|
|
185
220
|
addressList: null,
|
|
186
221
|
...styleForm.getDataItem(),
|
|
187
|
-
version: ''
|
|
222
|
+
version: '',
|
|
223
|
+
|
|
224
|
+
layout_style: "old",
|
|
225
|
+
edit_icon: "",
|
|
226
|
+
delete_icon: "",
|
|
227
|
+
cardRadius: 16,
|
|
228
|
+
bottomPadding: "",
|
|
229
|
+
bottomBgColor: "",
|
|
230
|
+
bottomBtnBgColor: "",
|
|
231
|
+
bottomBtnTextColor: "",
|
|
232
|
+
bottomBtnRadius: "",
|
|
188
233
|
};
|
|
189
234
|
},
|
|
190
235
|
filters: {
|
|
@@ -210,6 +255,16 @@ export default {
|
|
|
210
255
|
return this.fixedStyle({ height: 0, zIndex: 111 });
|
|
211
256
|
},
|
|
212
257
|
...styleForm.getComputedItem(),
|
|
258
|
+
bottomBoxStyle(){
|
|
259
|
+
let padding = `${this.checkValue(this.bottomPadding.top, 20)}rpx`;
|
|
260
|
+
padding = `${padding} ${this.checkValue(this.bottomPadding.right, 20)}rpx`;
|
|
261
|
+
padding = `${padding} ${this.checkValue(this.bottomPadding.bottom, 20)}rpx`;
|
|
262
|
+
padding = `${padding} ${this.checkValue(this.bottomPadding.left, 20)}rpx`;
|
|
263
|
+
return {
|
|
264
|
+
padding: padding,
|
|
265
|
+
backgroundColor: this.bottomBgColor,
|
|
266
|
+
}
|
|
267
|
+
}
|
|
213
268
|
},
|
|
214
269
|
methods: {
|
|
215
270
|
onJfbLoad(options) {
|
|
@@ -236,6 +291,16 @@ export default {
|
|
|
236
291
|
{ value: "" }
|
|
237
292
|
).value;
|
|
238
293
|
styleForm.getInitItem(this, value);
|
|
294
|
+
this.layout_style = getContainerPropsValue(value, "content.layout_style", "old");
|
|
295
|
+
this.edit_icon = getContainerPropsValue(value, "content.edit_icon", "iconbianji-01");
|
|
296
|
+
this.delete_icon = getContainerPropsValue(value, "content.delete_icon", "iconshanchu-01");
|
|
297
|
+
this.cardRadius = getContainerPropsValue(value, "content.cardRadius", 16);
|
|
298
|
+
this.bottomPadding = getContainerPropsValue(value, "content.bottomPadding", {});
|
|
299
|
+
this.bottomBgColor = getContainerPropsValue(value, "content.bottomBgColor", "#FFFFFF");
|
|
300
|
+
this.bottomBtnBgColor = getContainerPropsValue(value, "content.bottomBtnBgColor", this.mainColor);
|
|
301
|
+
this.bottomBtnTextColor = getContainerPropsValue(value, "content.bottomBtnTextColor", "#FFFFFF");
|
|
302
|
+
this.bottomBtnRadius = getContainerPropsValue(value, "content.bottomBtnRadius", 40);
|
|
303
|
+
console.log("bottomBtnRadius", this.bottomBtnRadius)
|
|
239
304
|
},
|
|
240
305
|
getList(callback) {
|
|
241
306
|
this.$xdShowLoading({});
|
|
@@ -490,7 +555,8 @@ export default {
|
|
|
490
555
|
})
|
|
491
556
|
.catch(this.$xdLog.catch);
|
|
492
557
|
},
|
|
493
|
-
|
|
558
|
+
//接口数据接口映射到组件数据接口
|
|
559
|
+
apiDataMapCompData(item){
|
|
494
560
|
let city_name = [
|
|
495
561
|
item["province_name"],
|
|
496
562
|
item["city_name"],
|
|
@@ -503,13 +569,15 @@ export default {
|
|
|
503
569
|
item["area_code"],
|
|
504
570
|
item["street_code"],
|
|
505
571
|
];
|
|
506
|
-
|
|
572
|
+
return {
|
|
507
573
|
receipt_username: item["name"],
|
|
508
574
|
receipt_address: item["address_detail"],
|
|
509
575
|
receipt_phone: item["phone"],
|
|
510
576
|
receipt_default: item["is_default"] === "Y" ? true : false,
|
|
511
577
|
city_name: city_name,
|
|
512
578
|
city_code: city_code,
|
|
579
|
+
receipt_city_code: city_code,
|
|
580
|
+
receipt_city_name: city_name,
|
|
513
581
|
receipt_region_name: city_name.join(" "),
|
|
514
582
|
city_selected_data: city_name.map((item, index) => {
|
|
515
583
|
return { label: item, value: city_code[index] };
|
|
@@ -518,11 +586,20 @@ export default {
|
|
|
518
586
|
latitude: item["latitude"] || null,
|
|
519
587
|
longitude: item["longitude"] || null,
|
|
520
588
|
house_number: item["house_number"],
|
|
521
|
-
}
|
|
589
|
+
}
|
|
590
|
+
},
|
|
591
|
+
handleEdit(item) {
|
|
592
|
+
this.defaultValue = this.apiDataMapCompData(item);
|
|
522
593
|
|
|
523
594
|
console.log("handleEdit", item, this.defaultValue);
|
|
524
595
|
this.showAddress = true;
|
|
525
596
|
},
|
|
597
|
+
handleSetDefault(item){
|
|
598
|
+
let is_default = item.is_default === "Y" ? "N" : "Y";
|
|
599
|
+
this.$set(item, 'is_default', is_default);
|
|
600
|
+
let saveData = this.apiDataMapCompData({...item, is_default});
|
|
601
|
+
this.handleSave(saveData);
|
|
602
|
+
},
|
|
526
603
|
handleDel(item) {
|
|
527
604
|
console.log("handleDel", item);
|
|
528
605
|
this.$xdConfirm({
|
|
@@ -670,9 +747,10 @@ export default {
|
|
|
670
747
|
|
|
671
748
|
&-address {
|
|
672
749
|
&-item {
|
|
673
|
-
border-radius: unit(16, rpx);
|
|
750
|
+
// border-radius: unit(16, rpx);
|
|
674
751
|
margin-bottom: unit(20, rpx);
|
|
675
752
|
box-shadow: 0px 0px unit(20, rpx) 0px rgba(0, 0, 0, 0.1);
|
|
753
|
+
overflow: hidden;
|
|
676
754
|
|
|
677
755
|
&-top {
|
|
678
756
|
display: flex;
|
|
@@ -695,7 +773,7 @@ export default {
|
|
|
695
773
|
padding: unit(20, rpx) unit(40, rpx);
|
|
696
774
|
font-size: unit(28, rpx);
|
|
697
775
|
color: #fff;
|
|
698
|
-
border-radius: 0px 0px unit(16, rpx) unit(16, rpx);
|
|
776
|
+
// border-radius: 0px 0px unit(16, rpx) unit(16, rpx);
|
|
699
777
|
|
|
700
778
|
& > view {
|
|
701
779
|
display: flex;
|
|
@@ -709,9 +787,7 @@ export default {
|
|
|
709
787
|
position: fixed;
|
|
710
788
|
left: 0;
|
|
711
789
|
right: 0;
|
|
712
|
-
padding-top: unit(20, rpx);
|
|
713
790
|
background: #fff;
|
|
714
|
-
height: unit(100, rpx);
|
|
715
791
|
}
|
|
716
792
|
}
|
|
717
793
|
}
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<view class="xd-tfk-item" @click="handleSelectAddress">
|
|
3
|
+
<view class="item_top">
|
|
4
|
+
<view class="user_info">
|
|
5
|
+
{{ item.name }} <text style="margin-left: 20rpx;">{{ item.phone }}</text>
|
|
6
|
+
<view v-if="item.is_valid === 'N'"
|
|
7
|
+
style="position: absolute; right: 40rpx;top: 0;"
|
|
8
|
+
>
|
|
9
|
+
<xd-font-icon
|
|
10
|
+
size="32"
|
|
11
|
+
:color="dangerColor"
|
|
12
|
+
icon="iconmingchengtubiao"
|
|
13
|
+
></xd-font-icon>
|
|
14
|
+
</view>
|
|
15
|
+
</view>
|
|
16
|
+
<view class="user_adr">{{item.province_name}}{{item.city_name}}{{item.area_name}}{{item.street_name}}{{ item.address_detail }} {{ item.house_number }}</view>
|
|
17
|
+
</view>
|
|
18
|
+
<view class="item_bottom">
|
|
19
|
+
<view class="is_default" @click.native.stop="setDefault">
|
|
20
|
+
<xd-radio :value="item.is_default === 'Y'" :width="52" :height="52" :iconSize="20"></xd-radio>
|
|
21
|
+
<view v-if="item.is_default === 'Y'">默认地址</view>
|
|
22
|
+
<view v-else>设为默认</view>
|
|
23
|
+
</view>
|
|
24
|
+
<view class="item_opera">
|
|
25
|
+
<view class="o_i" style="margin-right: 30rpx;" @click.native.stop="handleEdit">
|
|
26
|
+
<xd-font-icon class="icon" :icon="edit_icon" :size="26"></xd-font-icon> 编辑
|
|
27
|
+
</view>
|
|
28
|
+
<view class="o_i" @click.native.stop="handleDel">
|
|
29
|
+
<xd-font-icon class="icon" :icon="delete_icon" :size="26"></xd-font-icon> 删除
|
|
30
|
+
</view>
|
|
31
|
+
</view>
|
|
32
|
+
</view>
|
|
33
|
+
</view>
|
|
34
|
+
</template>
|
|
35
|
+
<script>
|
|
36
|
+
import XdRadio from "@/components/XdRadio/XdRadio"
|
|
37
|
+
import XdFontIcon from "@/components/XdFontIcon/XdFontIcon"
|
|
38
|
+
export default{
|
|
39
|
+
name:"XdTfkItem",
|
|
40
|
+
components: {
|
|
41
|
+
XdRadio,
|
|
42
|
+
XdFontIcon,
|
|
43
|
+
},
|
|
44
|
+
props:{
|
|
45
|
+
edit_icon: String,
|
|
46
|
+
delete_icon: String,
|
|
47
|
+
item: Object,
|
|
48
|
+
dangerColor: String,
|
|
49
|
+
},
|
|
50
|
+
data(){
|
|
51
|
+
return{
|
|
52
|
+
}
|
|
53
|
+
},
|
|
54
|
+
created(){
|
|
55
|
+
},
|
|
56
|
+
methods:{
|
|
57
|
+
handleSelectAddress(){
|
|
58
|
+
this.$emit("selectAddress")
|
|
59
|
+
},
|
|
60
|
+
handleEdit(){
|
|
61
|
+
this.$emit("editAddress", this.item)
|
|
62
|
+
},
|
|
63
|
+
handleDel(){
|
|
64
|
+
this.$emit("delAddress", this.item)
|
|
65
|
+
},
|
|
66
|
+
setDefault(){
|
|
67
|
+
this.$emit("setDefault", this.item)
|
|
68
|
+
}
|
|
69
|
+
},
|
|
70
|
+
}
|
|
71
|
+
</script>
|
|
72
|
+
<style lang="less" scoped>
|
|
73
|
+
.xd-tfk-item{
|
|
74
|
+
.item_top{
|
|
75
|
+
padding: 30rpx;
|
|
76
|
+
}
|
|
77
|
+
.user_info{
|
|
78
|
+
color: #191a1b;
|
|
79
|
+
font-size: 30rpx;
|
|
80
|
+
position: relative;
|
|
81
|
+
}
|
|
82
|
+
.user_adr{
|
|
83
|
+
color: #797d82;
|
|
84
|
+
font-size: 26rpx;
|
|
85
|
+
margin-top: 6rpx;
|
|
86
|
+
overflow: hidden;
|
|
87
|
+
text-overflow: ellipsis;
|
|
88
|
+
white-space: nowrap;
|
|
89
|
+
}
|
|
90
|
+
.item_bottom{
|
|
91
|
+
display: flex;
|
|
92
|
+
justify-content: space-between;
|
|
93
|
+
padding: 20rpx;
|
|
94
|
+
border-top: 1px solid #ededed;
|
|
95
|
+
}
|
|
96
|
+
.item_opera{
|
|
97
|
+
display: flex;
|
|
98
|
+
color: #797d82;
|
|
99
|
+
align-items: center;
|
|
100
|
+
.o_i{
|
|
101
|
+
display: flex;
|
|
102
|
+
align-items: center;
|
|
103
|
+
font-size: 26rpx;
|
|
104
|
+
|
|
105
|
+
.icon{
|
|
106
|
+
margin-right: 10rpx;
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
.is_default{
|
|
111
|
+
display: flex;
|
|
112
|
+
align-items: center;
|
|
113
|
+
font-size: 26rpx;
|
|
114
|
+
color: #797d82;
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
</style>
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
'use strict';
|
|
2
|
+
import ICONS from '@/ICONS'
|
|
2
3
|
|
|
3
4
|
/**
|
|
4
5
|
* @description 当表单组件中有联动操作时候,使用方法进行返回
|
|
@@ -85,15 +86,15 @@ export default {
|
|
|
85
86
|
ele: 'el-input',
|
|
86
87
|
groupKey:'style',
|
|
87
88
|
type: 'number',
|
|
88
|
-
valueKey: '
|
|
89
|
-
value: data.
|
|
89
|
+
valueKey: 'rowSpacing',
|
|
90
|
+
value: data.rowSpacing===undefined? data.rowSpacing: '',
|
|
90
91
|
placeholder: '请输入行间距',
|
|
91
92
|
className: 'input60',
|
|
92
93
|
inline: false,
|
|
93
94
|
notice: '设置行间距,<span style="color: red">单位:像素</span>。默认值:<span style="color: red">20</span>像素',
|
|
94
95
|
},
|
|
95
96
|
{
|
|
96
|
-
label: '
|
|
97
|
+
label: '边距设置:',
|
|
97
98
|
ele: 'xd-margin-padding',
|
|
98
99
|
groupKey:'style',
|
|
99
100
|
valueKey: 'margin',
|
|
@@ -101,9 +102,22 @@ export default {
|
|
|
101
102
|
setting: {
|
|
102
103
|
type: 'margin',
|
|
103
104
|
},
|
|
104
|
-
placeholder: '
|
|
105
|
+
placeholder: '边距设置',
|
|
105
106
|
inline: false,
|
|
106
|
-
notice: '
|
|
107
|
+
notice: '边距设置,<span style="color: red">单位:像素</span>。默认值:<span style="color: red">0</span>像素',
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
label: '填充设置:',
|
|
111
|
+
ele: 'xd-margin-padding',
|
|
112
|
+
groupKey:'style',
|
|
113
|
+
valueKey: 'padding',
|
|
114
|
+
value: data['padding'] || null,
|
|
115
|
+
setting: {
|
|
116
|
+
type: 'padding',
|
|
117
|
+
},
|
|
118
|
+
placeholder: '填充设置',
|
|
119
|
+
inline: false,
|
|
120
|
+
notice: '填充设置,<span style="color: red">单位:像素</span>。默认值:<span style="color: red">20</span>像素',
|
|
107
121
|
},
|
|
108
122
|
{
|
|
109
123
|
ele: 'title',
|
|
@@ -239,7 +253,9 @@ export default {
|
|
|
239
253
|
icon: true,
|
|
240
254
|
notice: false,
|
|
241
255
|
subTitle: true,
|
|
242
|
-
|
|
256
|
+
params: true,
|
|
257
|
+
},
|
|
258
|
+
icons:ICONS,
|
|
243
259
|
},
|
|
244
260
|
handleCustom({action, data}) {
|
|
245
261
|
if (action === 'number') {
|