jufubao-base 1.0.56 → 1.0.61-beta1001
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 +2 -2
- package/src/components/JfbBaseCardDetail/JfbBaseCardDetail.vue +19 -1
- package/src/components/JfbBaseCardDetailEntry/Api.js +58 -0
- package/src/components/JfbBaseCardDetailEntry/Attr.js +30 -0
- package/src/components/JfbBaseCardDetailEntry/JfbBaseCardDetailEntry.vue +812 -0
- package/src/components/JfbBaseCardDetailEntry/JfbBaseCardDetailEntryLess.less +80 -0
- package/src/components/JfbBaseCardDetailEntry/JfbBaseCardDetailEntryMixin.js +30 -0
- package/src/components/JfbBaseCardDetailEntry/Mock.js +106 -0
- package/src/components/JfbBaseCardDetailEntry/XdEditPwd.vue +299 -0
- package/src/components/JfbBaseCardDetailEntry/XdPwPay.vue +214 -0
- package/src/components/JfbBaseCardDisabledEntry/Api.js +12 -7
- package/src/components/JfbBaseCardDisabledEntry/JfbBaseCardDisabledEntry.vue +39 -12
- package/src/components/JfbBaseCardEntry/JfbBaseCardEntry.vue +37 -1
- package/src/components/JfbBaseCardInfoEntry/Api.js +71 -0
- package/src/components/JfbBaseCardInfoEntry/Attr.js +37 -0
- package/src/components/JfbBaseCardInfoEntry/JfbBaseCardInfoEntry.vue +661 -0
- package/src/components/JfbBaseCardInfoEntry/JfbBaseCardInfoEntryLess.less +80 -0
- package/src/components/JfbBaseCardInfoEntry/JfbBaseCardInfoEntryMixin.js +30 -0
- package/src/components/JfbBaseCardInfoEntry/Mock.js +122 -0
- package/src/components/JfbBaseCardMergeEntry/Api.js +61 -0
- package/src/components/JfbBaseCardMergeEntry/Attr.js +237 -0
- package/src/components/JfbBaseCardMergeEntry/JfbBaseCardMergeEntry.vue +443 -0
- package/src/components/JfbBaseCardMergeEntry/JfbBaseCardMergeEntryLess.less +80 -0
- package/src/components/JfbBaseCardMergeEntry/JfbBaseCardMergeEntryMixin.js +30 -0
- package/src/components/JfbBaseCardMergeEntry/Mock.js +32 -0
- package/src/components/JfbBaseCardShiftEntry/Api.js +51 -0
- package/src/components/JfbBaseCardShiftEntry/Attr.js +237 -0
- package/src/components/JfbBaseCardShiftEntry/JfbBaseCardShiftEntry.vue +476 -0
- package/src/components/JfbBaseCardShiftEntry/JfbBaseCardShiftEntryLess.less +80 -0
- package/src/components/JfbBaseCardShiftEntry/JfbBaseCardShiftEntryMixin.js +30 -0
- package/src/components/JfbBaseCardShiftEntry/Mock.js +5 -0
- package/src/mixins/colorCardMixins.js +1 -1
|
@@ -0,0 +1,237 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
export default {
|
|
4
|
+
style: [],
|
|
5
|
+
advanced: [],
|
|
6
|
+
content: (data) => {
|
|
7
|
+
return [
|
|
8
|
+
{
|
|
9
|
+
label: '返回按钮地址:', //label
|
|
10
|
+
ele: 'xd-select-pages-path', //package 名称
|
|
11
|
+
valueKey: 'back_url', //form[valueKey]
|
|
12
|
+
placeholder: '请选择返回按钮地址',
|
|
13
|
+
value: data.back_url || null,
|
|
14
|
+
setting: {
|
|
15
|
+
router: XdBus.getParentApi('getPagesTree'),
|
|
16
|
+
},
|
|
17
|
+
inline: false,
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
label: '提示内容:',
|
|
21
|
+
ele: 'xd-site-news',
|
|
22
|
+
valueKey: 'notice',
|
|
23
|
+
value: data.notice || null,
|
|
24
|
+
className: 'input70',
|
|
25
|
+
setting: {
|
|
26
|
+
config: {
|
|
27
|
+
sort: true,
|
|
28
|
+
maxlen: 100,
|
|
29
|
+
action: 'aliyun',
|
|
30
|
+
size: 5,
|
|
31
|
+
tipsformet: '上传文件格式:@imageType@,不超过@size@MB.',
|
|
32
|
+
uploadType: 'aliyun',
|
|
33
|
+
type: ['jpg', 'png', 'jpeg']
|
|
34
|
+
},
|
|
35
|
+
},
|
|
36
|
+
handleCustom({action, data}) {
|
|
37
|
+
if (data && data.params) {
|
|
38
|
+
//当一个插件中出现使用内容分类时候需要设置code值,在页面引用时候容器id + code进行拼接
|
|
39
|
+
//data.params = Object.assign({}, data.params, {code: 'g_test_id'});
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
//获取返回参数(场景类型名称为必填)
|
|
43
|
+
let loading = XdBus.getParentApi('loading')({});
|
|
44
|
+
|
|
45
|
+
//获取显示内容
|
|
46
|
+
if (action === 'screen') {
|
|
47
|
+
XdBus.getParentApi('getOptionsSettingList')({setting_id: 'edtix_bucket_content_tip'})
|
|
48
|
+
.then(res => {
|
|
49
|
+
loading.close();
|
|
50
|
+
data.cb(res['list'])
|
|
51
|
+
})
|
|
52
|
+
.catch(error => {
|
|
53
|
+
console.error(error);
|
|
54
|
+
loading.close();
|
|
55
|
+
});
|
|
56
|
+
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
//获取返回参数(广告位高度必选项)
|
|
60
|
+
if (action === 'getNewsInfo') {
|
|
61
|
+
XdBus.getParentApi('cmsGetPublishEditxContent')(data.params)
|
|
62
|
+
.then(res => {
|
|
63
|
+
loading.close()
|
|
64
|
+
data.cb({list: res.list, selectId: res.selected})
|
|
65
|
+
})
|
|
66
|
+
.catch(error => {
|
|
67
|
+
loading.close()
|
|
68
|
+
console.error(error);
|
|
69
|
+
});
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
//获取产品业务线列表
|
|
73
|
+
if (action === 'namespace') {
|
|
74
|
+
XdBus.getParentApi('getOptionsNamespaces')({})
|
|
75
|
+
.then(res => {
|
|
76
|
+
loading.close()
|
|
77
|
+
data.cb(res['list'])
|
|
78
|
+
})
|
|
79
|
+
.catch(error => {
|
|
80
|
+
loading.close()
|
|
81
|
+
console.error(error);
|
|
82
|
+
});
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
//使用内容分类
|
|
86
|
+
if (action === 'cmsPublishEditxContent') {
|
|
87
|
+
XdBus.getParentApi('cmsPublishEditxContent')(data.params)
|
|
88
|
+
.then(res => {
|
|
89
|
+
console.log('cmsPublishEditxContent', res)
|
|
90
|
+
loading.close();
|
|
91
|
+
data.cb(res)
|
|
92
|
+
})
|
|
93
|
+
.catch(error => {
|
|
94
|
+
loading.close();
|
|
95
|
+
console.error(error);
|
|
96
|
+
});
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
//位置列表
|
|
100
|
+
if (action === 'getListPostion') {
|
|
101
|
+
XdBus.getParentApi('getListNewsPosition')(data.params)
|
|
102
|
+
.then(res => {
|
|
103
|
+
loading.close();
|
|
104
|
+
data.cb(res)
|
|
105
|
+
})
|
|
106
|
+
.catch(error => {
|
|
107
|
+
loading.close();
|
|
108
|
+
console.error(error);
|
|
109
|
+
});
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
//位置创建
|
|
113
|
+
if (action === 'addPostion') {
|
|
114
|
+
XdBus.getParentApi('addNewsPosition')(data.params)
|
|
115
|
+
.then(res => {
|
|
116
|
+
loading.close();
|
|
117
|
+
data.cb(true)
|
|
118
|
+
})
|
|
119
|
+
.catch(error => {
|
|
120
|
+
console.error(error);
|
|
121
|
+
loading.close();
|
|
122
|
+
data.cb(false)
|
|
123
|
+
});
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
//位置编辑
|
|
127
|
+
if (action === 'editPostion') {
|
|
128
|
+
XdBus.getParentApi('updateNewsPosition')(data.params)
|
|
129
|
+
.then(res => {
|
|
130
|
+
loading.close();
|
|
131
|
+
data.cb(true)
|
|
132
|
+
})
|
|
133
|
+
.catch(error => {
|
|
134
|
+
console.error(error);
|
|
135
|
+
loading.close();
|
|
136
|
+
data.cb(false)
|
|
137
|
+
});
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
//位置删除
|
|
141
|
+
if (action === 'deleltePostion') {
|
|
142
|
+
XdBus.getParentApi('deleteNewsPosition')(data.params)
|
|
143
|
+
.then(res => {
|
|
144
|
+
loading.close();
|
|
145
|
+
data.cb(true)
|
|
146
|
+
})
|
|
147
|
+
.catch(error => {
|
|
148
|
+
console.error(error);
|
|
149
|
+
loading.close();
|
|
150
|
+
data.cb(false)
|
|
151
|
+
});
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
//获取广告位内容列表
|
|
155
|
+
if (action === 'getListContent') {
|
|
156
|
+
XdBus.getParentApi('getListNewsContent')(data.params)
|
|
157
|
+
.then(res => {
|
|
158
|
+
loading.close();
|
|
159
|
+
data.cb(res)
|
|
160
|
+
})
|
|
161
|
+
.catch(error => {
|
|
162
|
+
loading.close();
|
|
163
|
+
console.error(error);
|
|
164
|
+
});
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
//广告内容创建
|
|
168
|
+
if (action === 'addContent') {
|
|
169
|
+
XdBus.getParentApi('addNewsContent')(data.params)
|
|
170
|
+
.then(res => {
|
|
171
|
+
loading.close();
|
|
172
|
+
data.cb(true)
|
|
173
|
+
})
|
|
174
|
+
.catch(error => {
|
|
175
|
+
console.error(error);
|
|
176
|
+
loading.close();
|
|
177
|
+
data.cb(false)
|
|
178
|
+
});
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
//广告内容编辑
|
|
182
|
+
if (action === 'editContent') {
|
|
183
|
+
XdBus.getParentApi('updateNewsContent')(data.params)
|
|
184
|
+
.then(res => {
|
|
185
|
+
loading.close();
|
|
186
|
+
data.cb(true)
|
|
187
|
+
})
|
|
188
|
+
.catch(error => {
|
|
189
|
+
console.error(error);
|
|
190
|
+
loading.close();
|
|
191
|
+
data.cb(false)
|
|
192
|
+
});
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
//广告内容删除
|
|
196
|
+
if (action === 'deleteContent') {
|
|
197
|
+
XdBus.getParentApi('deleteNewsContent')(data.params)
|
|
198
|
+
.then(res => {
|
|
199
|
+
loading.close();
|
|
200
|
+
data.cb(true)
|
|
201
|
+
})
|
|
202
|
+
.catch(error => {
|
|
203
|
+
console.error(error);
|
|
204
|
+
loading.close();
|
|
205
|
+
data.cb(false)
|
|
206
|
+
});
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
//内容发布
|
|
210
|
+
if (action === 'publish') {
|
|
211
|
+
console.log('publish', data.params)
|
|
212
|
+
XdBus.getParentApi('cmsPublishContent')(data.params)
|
|
213
|
+
.then(res => {
|
|
214
|
+
loading.close();
|
|
215
|
+
data.cb(res)
|
|
216
|
+
})
|
|
217
|
+
.catch(error => {
|
|
218
|
+
loading.close();
|
|
219
|
+
console.error(error);
|
|
220
|
+
});
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
//通知页面进行刷新
|
|
224
|
+
if (action === 'update') {
|
|
225
|
+
XdBus.getParentApi('getXdBusUpdateView')('onUpdateView', {});
|
|
226
|
+
loading.close()
|
|
227
|
+
}
|
|
228
|
+
},
|
|
229
|
+
inline: false,
|
|
230
|
+
notice: '',
|
|
231
|
+
rules: [
|
|
232
|
+
{required: true, message: '请配置温馨提示内容', trigger: 'change'},
|
|
233
|
+
],
|
|
234
|
+
},
|
|
235
|
+
].filter(i=>i)
|
|
236
|
+
},
|
|
237
|
+
};
|
|
@@ -0,0 +1,476 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<view
|
|
3
|
+
class="jfb-base-card-shift-entry"
|
|
4
|
+
@click="handleEditxSelect"
|
|
5
|
+
:class="{
|
|
6
|
+
editx: isEditx && active,
|
|
7
|
+
noBorder: noBorder,
|
|
8
|
+
}"
|
|
9
|
+
>
|
|
10
|
+
<!--#ifdef H5-->
|
|
11
|
+
<view
|
|
12
|
+
class="jfb-base-card-shift-entry__edit"
|
|
13
|
+
:class="{ editx: isEditx && active }"
|
|
14
|
+
v-if="isEditx && active && !noBorder"
|
|
15
|
+
>
|
|
16
|
+
<view class="jfb-base-card-shift-entry__edit-icon" @click="delEdit">删除</view>
|
|
17
|
+
</view>
|
|
18
|
+
<!-- #endif -->
|
|
19
|
+
<view
|
|
20
|
+
class="jfb-base-card-shift-entry__body"
|
|
21
|
+
v-if="info !== null"
|
|
22
|
+
:style="{minHeight: layoutInfo.bodyMinHeightRpx + 'rpx'}"
|
|
23
|
+
>
|
|
24
|
+
<view
|
|
25
|
+
class="jfb-base-card-shift-entry__body-header"
|
|
26
|
+
:style="{
|
|
27
|
+
background: headerBg.color,
|
|
28
|
+
backgroundSize: '100%',
|
|
29
|
+
}"
|
|
30
|
+
>
|
|
31
|
+
<view
|
|
32
|
+
class="jfb-base-card-shift-entry__body-header-wrap"
|
|
33
|
+
:style="{
|
|
34
|
+
backgroundImage: `url(${headerBg.image})`,
|
|
35
|
+
}"
|
|
36
|
+
>
|
|
37
|
+
<view class="jfb-base-card-shift-entry__body-header__title">
|
|
38
|
+
<view>
|
|
39
|
+
<xd-font-icon
|
|
40
|
+
size="40"
|
|
41
|
+
color="#fff"
|
|
42
|
+
icon="iconzhuanhuanshitu"
|
|
43
|
+
style="margin-right:10rpx"
|
|
44
|
+
></xd-font-icon>
|
|
45
|
+
转换的票券
|
|
46
|
+
</view>
|
|
47
|
+
</view>
|
|
48
|
+
<view style="padding-top:40rpx" class="jfb-base-card-shift-entry__body-header-item">
|
|
49
|
+
<view>券名:</view>
|
|
50
|
+
<view>{{info.card_type_name}}</view>
|
|
51
|
+
</view>
|
|
52
|
+
<view
|
|
53
|
+
style="padding-bottom: 20rpx"
|
|
54
|
+
class="jfb-base-card-shift-entry__body-header-item"
|
|
55
|
+
>
|
|
56
|
+
<view>券号:</view>
|
|
57
|
+
<view>{{info.card_number}}</view>
|
|
58
|
+
</view>
|
|
59
|
+
</view>
|
|
60
|
+
</view>
|
|
61
|
+
<!-- 转换之前 -->
|
|
62
|
+
<view
|
|
63
|
+
class="jfb-base-card-shift-entry__body-content"
|
|
64
|
+
>
|
|
65
|
+
<view
|
|
66
|
+
:class="
|
|
67
|
+
item.key === 'other_card_point'
|
|
68
|
+
? 'jfb-base-card-shift-entry__body-content-special'
|
|
69
|
+
: 'jfb-base-card-shift-entry__body-content-item'
|
|
70
|
+
"
|
|
71
|
+
v-for="(item, index) in valueKey"
|
|
72
|
+
:key="index"
|
|
73
|
+
>
|
|
74
|
+
<view> {{ item.label }}: </view>
|
|
75
|
+
<view :style="{color:mainColor,fontWeight:500}" v-if="item.type === 'price'">
|
|
76
|
+
{{ info[item.key] }}
|
|
77
|
+
<text>{{info.unit}}</text>
|
|
78
|
+
</view>
|
|
79
|
+
<view style="color: #333; font-weight: 500" v-else>
|
|
80
|
+
{{ info[item.key] }}
|
|
81
|
+
<text v-if="item.type === 'type'">券</text>
|
|
82
|
+
</view>
|
|
83
|
+
</view>
|
|
84
|
+
</view>
|
|
85
|
+
<!-- 转换剩余 -->
|
|
86
|
+
<view
|
|
87
|
+
class="jfb-base-card-shift-entry__body-content"
|
|
88
|
+
:style="{background:changeBg}"
|
|
89
|
+
>
|
|
90
|
+
<view class="jfb-base-card-shift-entry__body-content-title">
|
|
91
|
+
<xd-font-icon
|
|
92
|
+
size="32"
|
|
93
|
+
:color="mainColor"
|
|
94
|
+
icon="iconrepository-xialaxuanxiangdown"
|
|
95
|
+
></xd-font-icon>
|
|
96
|
+
<view>转换后预估票券额度</view>
|
|
97
|
+
</view>
|
|
98
|
+
<view
|
|
99
|
+
:class="
|
|
100
|
+
item.key === 'other_card_point'
|
|
101
|
+
? 'jfb-base-card-shift-entry__body-content-special'
|
|
102
|
+
: 'jfb-base-card-shift-entry__body-content-item'
|
|
103
|
+
"
|
|
104
|
+
v-for="(item, index) in changeValueKey"
|
|
105
|
+
:key="index"
|
|
106
|
+
>
|
|
107
|
+
<view> {{ item.label }}: </view>
|
|
108
|
+
<view :style="{color:mainColor,fontWeight:500}" v-if="item.type === 'price'">
|
|
109
|
+
{{ info[item.key] }}
|
|
110
|
+
<text>点</text>
|
|
111
|
+
</view>
|
|
112
|
+
<view style="color: #333; font-weight: 500" v-else>
|
|
113
|
+
{{ info[item.key] }}
|
|
114
|
+
<text v-if="item.type === 'type'">券</text>
|
|
115
|
+
</view>
|
|
116
|
+
</view>
|
|
117
|
+
</view>
|
|
118
|
+
<!-- 注意事项 -->
|
|
119
|
+
<view class="jfb-base-card-shift-entry__body-tips" v-if="notice">
|
|
120
|
+
<view style="text-align:center;padding-bottom:24rpx;color:#333;font-weight:500">注意事项</view>
|
|
121
|
+
<xd-content-xss :html="notice"></xd-content-xss>
|
|
122
|
+
</view>
|
|
123
|
+
<view :style="{height: '100rpx'}"></view>
|
|
124
|
+
<!-- 靠底支付 -->
|
|
125
|
+
<view class="fixe_bottom" :style="prod_bottom">
|
|
126
|
+
<xd-button
|
|
127
|
+
@click="handleChange"
|
|
128
|
+
width="500rpx"
|
|
129
|
+
type="primary">
|
|
130
|
+
转换
|
|
131
|
+
</xd-button>
|
|
132
|
+
</view>
|
|
133
|
+
<xd-dailog
|
|
134
|
+
class="dialog"
|
|
135
|
+
title=""
|
|
136
|
+
:show.sync="success"
|
|
137
|
+
:showClose="false"
|
|
138
|
+
:confirm="false"
|
|
139
|
+
:cancel="false"
|
|
140
|
+
:radius="20"
|
|
141
|
+
>
|
|
142
|
+
<view class="jfb-base-card-shift-entry__body-success">
|
|
143
|
+
<view class="jfb-base-card-shift-entry__body-success-title">
|
|
144
|
+
<xd-font-icon
|
|
145
|
+
size="48"
|
|
146
|
+
:color="mainColor"
|
|
147
|
+
icon="icondui-01"
|
|
148
|
+
></xd-font-icon>
|
|
149
|
+
<text :style="{color:mainColor,marginLeft:'20rpx'}">转换成功</text>
|
|
150
|
+
</view>
|
|
151
|
+
<view class="jfb-base-card-shift-entry__body-success-content">
|
|
152
|
+
已成功将 <text style="color:#333;padding: 0 16rpx">{{ card_number }}</text> 转换成为
|
|
153
|
+
<text style="color:#333;padding: 0 16rpx">{{ changeNumber }}</text>可在券包中查看
|
|
154
|
+
</view>
|
|
155
|
+
<xd-button type="primarys" width="360rpx" @click="handleToLink"
|
|
156
|
+
>返回列表</xd-button
|
|
157
|
+
>
|
|
158
|
+
</view>
|
|
159
|
+
</xd-dailog>
|
|
160
|
+
</view>
|
|
161
|
+
</view>
|
|
162
|
+
</template>
|
|
163
|
+
|
|
164
|
+
<script>
|
|
165
|
+
import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
|
|
166
|
+
import XdRadio from "@/components/XdRadio/XdRadio";
|
|
167
|
+
import XdButton from "@/components/XdButton/XdButton";
|
|
168
|
+
import XdDailog from "@/components/XdDailog/XdDailog";
|
|
169
|
+
import { jfbRootExec } from "@/utils/xd.event";
|
|
170
|
+
import JfbBaseCardShifEntrytMixin from "./JfbBaseCardShiftEntryMixin";
|
|
171
|
+
import componentsMixins from "@/mixins/componentsMixins";
|
|
172
|
+
import colorCardMixins from "@/mixins/colorCardMixins";
|
|
173
|
+
import extsMixins from "@/mixins/extsMixins";
|
|
174
|
+
import { getContainerPropsValue } from "@/utils/xd.base";
|
|
175
|
+
import XdContentXss from '@/components/XdContentXss/XdContentXss'
|
|
176
|
+
const Color = require("color");
|
|
177
|
+
|
|
178
|
+
export default {
|
|
179
|
+
name: "JfbBaseCardShiftEntry",
|
|
180
|
+
components: {
|
|
181
|
+
XdFontIcon,
|
|
182
|
+
XdRadio,
|
|
183
|
+
XdButton,
|
|
184
|
+
XdDailog,
|
|
185
|
+
XdContentXss
|
|
186
|
+
},
|
|
187
|
+
mixins: [JfbBaseCardShifEntrytMixin, componentsMixins, extsMixins,colorCardMixins],
|
|
188
|
+
data() {
|
|
189
|
+
return {
|
|
190
|
+
info: null,
|
|
191
|
+
valueKey: [
|
|
192
|
+
{
|
|
193
|
+
label: "票券余额",
|
|
194
|
+
key: "card_point",
|
|
195
|
+
type: "price",
|
|
196
|
+
},
|
|
197
|
+
{
|
|
198
|
+
label: "购买其他物品可抵",
|
|
199
|
+
key: "other_card_point",
|
|
200
|
+
type: "price",
|
|
201
|
+
},
|
|
202
|
+
{
|
|
203
|
+
label: "有效期限",
|
|
204
|
+
key: "end_time",
|
|
205
|
+
type: "normal",
|
|
206
|
+
},
|
|
207
|
+
],
|
|
208
|
+
changeValueKey: [
|
|
209
|
+
{
|
|
210
|
+
label: "票券余额",
|
|
211
|
+
key: "exchange_card_point",
|
|
212
|
+
type: "price",
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
label: "购买其他物品可抵",
|
|
216
|
+
key: "other_card_point",
|
|
217
|
+
type: "price",
|
|
218
|
+
}
|
|
219
|
+
],
|
|
220
|
+
card_number: "",
|
|
221
|
+
changeNumber: "",
|
|
222
|
+
success: false,
|
|
223
|
+
notice: "",
|
|
224
|
+
|
|
225
|
+
//页面跳转地址
|
|
226
|
+
backUrl: "",
|
|
227
|
+
bottomHeight: 120,
|
|
228
|
+
changeBg: ''
|
|
229
|
+
};
|
|
230
|
+
},
|
|
231
|
+
computed: {
|
|
232
|
+
prod_bottom() {
|
|
233
|
+
return this.fixedStyle({height: 0, zIndex: 111});
|
|
234
|
+
},
|
|
235
|
+
},
|
|
236
|
+
created() {
|
|
237
|
+
this.changeBg = Color(this.warningColor).alpha(0.2).toString();
|
|
238
|
+
this.backUrl = getContainerPropsValue(this.container, "content.back_url", {
|
|
239
|
+
value: "",
|
|
240
|
+
}).value;
|
|
241
|
+
},
|
|
242
|
+
methods: {
|
|
243
|
+
handleChange() {
|
|
244
|
+
jfbRootExec("changeCardBindEntry", {
|
|
245
|
+
vm: this,
|
|
246
|
+
data: {
|
|
247
|
+
card_number: this.card_number,
|
|
248
|
+
},
|
|
249
|
+
})
|
|
250
|
+
.then((res) => {
|
|
251
|
+
this.success = true;
|
|
252
|
+
this.changeNumber = res["to_card_number"];
|
|
253
|
+
})
|
|
254
|
+
.catch();
|
|
255
|
+
},
|
|
256
|
+
handleToLink() {
|
|
257
|
+
this.$xdUniHelper.navigateTo({
|
|
258
|
+
url: this.backUrl,
|
|
259
|
+
});
|
|
260
|
+
},
|
|
261
|
+
getContent() {
|
|
262
|
+
jfbRootExec("getListGiftNewsContentEntry", {
|
|
263
|
+
vm: this,
|
|
264
|
+
data: {
|
|
265
|
+
page_id: this.pageAttr["page_id"], //页面ID
|
|
266
|
+
container_id: this.containerId, //组件ID
|
|
267
|
+
limit: 1,
|
|
268
|
+
},
|
|
269
|
+
})
|
|
270
|
+
.then((res) => {
|
|
271
|
+
this.notice = res.list[0].content;
|
|
272
|
+
})
|
|
273
|
+
.catch((error) => {
|
|
274
|
+
console.error(error);
|
|
275
|
+
});
|
|
276
|
+
},
|
|
277
|
+
|
|
278
|
+
onJfbLoad(options) {
|
|
279
|
+
this.card_number = options.card_number;
|
|
280
|
+
this.getContent();
|
|
281
|
+
jfbRootExec("getByIdCardDetailEntry", {
|
|
282
|
+
vm: this,
|
|
283
|
+
data: {
|
|
284
|
+
card_number: this.card_number,
|
|
285
|
+
},
|
|
286
|
+
})
|
|
287
|
+
.then((res) => {
|
|
288
|
+
let temp = {};
|
|
289
|
+
Object.keys(res).map((key) => {
|
|
290
|
+
if (key === "card_point" || key === "exchange_card_point") {
|
|
291
|
+
temp[key] = this.$xdUniHelper.divisionFloatNumber(res[key], 100);
|
|
292
|
+
} else {
|
|
293
|
+
temp[key] = res[key];
|
|
294
|
+
}
|
|
295
|
+
});
|
|
296
|
+
if(res.other_card_point===0 || res.card_point_type === 1) {
|
|
297
|
+
this.valueKey.splice(1,1);
|
|
298
|
+
this.changeValueKey.splice(1,1)
|
|
299
|
+
}
|
|
300
|
+
this.headerBg = this.getCardThemes(res.card_type_name);
|
|
301
|
+
this.info = temp;
|
|
302
|
+
})
|
|
303
|
+
.catch((err) => {});
|
|
304
|
+
},
|
|
305
|
+
onJfbUpdate(data) {
|
|
306
|
+
this.getContent();
|
|
307
|
+
},
|
|
308
|
+
onJfbBack(options) {
|
|
309
|
+
this.$xdUniHelper.navigateBack();
|
|
310
|
+
},
|
|
311
|
+
},
|
|
312
|
+
};
|
|
313
|
+
</script>
|
|
314
|
+
|
|
315
|
+
<style scoped lang="less">
|
|
316
|
+
@import "./JfbBaseCardShiftEntryLess.less";
|
|
317
|
+
|
|
318
|
+
.jfb-base-card-shift-entry {
|
|
319
|
+
border: 1px dashed rgba(0, 0, 0, 0);
|
|
320
|
+
box-sizing: border-box;
|
|
321
|
+
|
|
322
|
+
&__body {
|
|
323
|
+
position: relative;
|
|
324
|
+
color: #333;
|
|
325
|
+
padding: unit(26, rpx);
|
|
326
|
+
&-header {
|
|
327
|
+
border-radius: unit(16, rpx);
|
|
328
|
+
font-size: unit(40, rpx);
|
|
329
|
+
font-weight: 700;
|
|
330
|
+
color: #fff;
|
|
331
|
+
position: relative;
|
|
332
|
+
min-height: unit(260,rpx);
|
|
333
|
+
|
|
334
|
+
&__title {
|
|
335
|
+
height: unit(56, rpx);
|
|
336
|
+
display: flex;
|
|
337
|
+
justify-content: flex-start;
|
|
338
|
+
align-items: center;
|
|
339
|
+
|
|
340
|
+
|
|
341
|
+
& > view {
|
|
342
|
+
padding: 0 unit(80, rpx);
|
|
343
|
+
font-size: unit(24, rpx);
|
|
344
|
+
line-height: unit(56, rpx);
|
|
345
|
+
background: rgba(102, 102, 102, 0.4);
|
|
346
|
+
color: #fff;
|
|
347
|
+
border-radius:unit(16, rpx) 0 unit(16, rpx) 0;
|
|
348
|
+
display: flex;
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
}
|
|
352
|
+
|
|
353
|
+
&-wrap {
|
|
354
|
+
width: unit(700, rpx);
|
|
355
|
+
border-radius: unit(16, rpx);
|
|
356
|
+
background-size: 100%;
|
|
357
|
+
min-height: 100%;
|
|
358
|
+
display: flex;
|
|
359
|
+
flex-direction: column;
|
|
360
|
+
justify-content: center;
|
|
361
|
+
}
|
|
362
|
+
|
|
363
|
+
&-item {
|
|
364
|
+
display: flex;
|
|
365
|
+
justify-content: flex-start;
|
|
366
|
+
align-content: center;
|
|
367
|
+
padding-bottom: unit(32, rpx);
|
|
368
|
+
padding-left: unit(40,rpx);
|
|
369
|
+
|
|
370
|
+
& > view:first-child {
|
|
371
|
+
flex-basis: unit(120,rpx);
|
|
372
|
+
flex-shrink: 0;
|
|
373
|
+
}
|
|
374
|
+
}
|
|
375
|
+
}
|
|
376
|
+
|
|
377
|
+
&-content {
|
|
378
|
+
background: #fff;
|
|
379
|
+
border-radius: unit(16, rpx);
|
|
380
|
+
padding: unit(38, rpx) 0;
|
|
381
|
+
margin-top: unit(24, rpx);
|
|
382
|
+
|
|
383
|
+
&-title {
|
|
384
|
+
display: flex;
|
|
385
|
+
flex-direction: column;
|
|
386
|
+
justify-content: center;
|
|
387
|
+
align-items: center;
|
|
388
|
+
font-weight: 500;
|
|
389
|
+
margin-bottom: unit(32,rpx);
|
|
390
|
+
}
|
|
391
|
+
|
|
392
|
+
&-item {
|
|
393
|
+
display: flex;
|
|
394
|
+
color: #666;
|
|
395
|
+
justify-content: space-between;
|
|
396
|
+
align-content: center;
|
|
397
|
+
font-size: unit(28, rpx);
|
|
398
|
+
padding: unit(16, rpx) unit(48, rpx);
|
|
399
|
+
}
|
|
400
|
+
|
|
401
|
+
&-special {
|
|
402
|
+
display: flex;
|
|
403
|
+
color: #666;
|
|
404
|
+
justify-content: space-between;
|
|
405
|
+
font-size: unit(24, rpx);
|
|
406
|
+
padding: unit(18, rpx) unit(24, rpx);
|
|
407
|
+
margin: 0 unit(24, rpx);
|
|
408
|
+
border-radius: unit(16, rpx);
|
|
409
|
+
background: #f9f9f9;
|
|
410
|
+
align-content: center;
|
|
411
|
+
}
|
|
412
|
+
}
|
|
413
|
+
|
|
414
|
+
&-tips {
|
|
415
|
+
font-size: unit(28, rpx);
|
|
416
|
+
padding: unit(28, rpx);
|
|
417
|
+
color: #666;
|
|
418
|
+
background: #fff;
|
|
419
|
+
border-radius: unit(16,rpx);
|
|
420
|
+
margin-top: unit(24,rpx);
|
|
421
|
+
}
|
|
422
|
+
|
|
423
|
+
&-agree {
|
|
424
|
+
display: flex;
|
|
425
|
+
align-items: center;
|
|
426
|
+
justify-content: center;
|
|
427
|
+
font-size: unit(24, rpx);
|
|
428
|
+
color: #bbb;
|
|
429
|
+
padding: unit(20, rpx) 0;
|
|
430
|
+
margin-bottom: unit(40,rpx);
|
|
431
|
+
|
|
432
|
+
& > view {
|
|
433
|
+
margin-left: unit(25, rpx);
|
|
434
|
+
}
|
|
435
|
+
}
|
|
436
|
+
|
|
437
|
+
.fixe_bottom{
|
|
438
|
+
display: flex;
|
|
439
|
+
align-items: center;
|
|
440
|
+
justify-content: space-between;
|
|
441
|
+
height: unit(100, rpx);
|
|
442
|
+
padding: 0 unit(40, rpx);
|
|
443
|
+
background: #FFF;
|
|
444
|
+
box-shadow: 0 0 unit(16, rpx) rgba(0,0,0,.05);
|
|
445
|
+
.flex_l{
|
|
446
|
+
display: flex;
|
|
447
|
+
align-items: center;
|
|
448
|
+
font-size: unit(32,rpx);
|
|
449
|
+
}
|
|
450
|
+
}
|
|
451
|
+
|
|
452
|
+
&-success {
|
|
453
|
+
padding: unit(70, rpx);
|
|
454
|
+
&-title {
|
|
455
|
+
font-size: unit(32, rpx);
|
|
456
|
+
display: flex;
|
|
457
|
+
align-items: center;
|
|
458
|
+
justify-content: center;
|
|
459
|
+
}
|
|
460
|
+
|
|
461
|
+
&-content {
|
|
462
|
+
font-size: unit(28, rpx);
|
|
463
|
+
color: #666;
|
|
464
|
+
text-align: center;
|
|
465
|
+
line-height: unit(42, rpx);
|
|
466
|
+
margin: unit(50, rpx) 0;
|
|
467
|
+
}
|
|
468
|
+
}
|
|
469
|
+
|
|
470
|
+
|
|
471
|
+
.dialog ::v-deep .xd-dailog__body-content {
|
|
472
|
+
padding: 0;
|
|
473
|
+
}
|
|
474
|
+
}
|
|
475
|
+
}
|
|
476
|
+
</style>
|