jufubao-base 1.0.208 → 1.0.209-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/package.json +1 -1
- package/src/components/JfbBaseCardInfo/JfbBaseCardInfo.vue +5 -5
- package/src/components/JfbBaseConList/JfbBaseConList.vue +5 -1
- package/src/components/JfbBaseNotice/Attr.js +0 -1
- package/src/components/JfbBaseRecharge/Api.js +21 -0
- package/src/components/JfbBaseRecharge/Attr.js +0 -1
- package/src/components/JfbBaseRecharge/JfbBaseRecharge.vue +169 -67
- package/src/components/JfbBaseRechargeNew/Api.js +74 -0
- package/src/components/JfbBaseRechargeNew/Attr.js +301 -0
- package/src/components/JfbBaseRechargeNew/JfbBaseRechargeNew.vue +468 -0
- package/src/components/JfbBaseRechargeNew/JfbBaseRechargeNewLess.less +79 -0
- package/src/components/JfbBaseRechargeNew/JfbBaseRechargeNewMixin.js +30 -0
- package/src/components/JfbBaseRechargeNew/Mock.js +5 -0
|
@@ -0,0 +1,301 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* @description 当表单组件中有联动操作时候,使用方法进行返回
|
|
5
|
+
*/
|
|
6
|
+
export default {
|
|
7
|
+
style: [],
|
|
8
|
+
content: (data) => {
|
|
9
|
+
return [
|
|
10
|
+
{
|
|
11
|
+
ele: 'title',
|
|
12
|
+
label: '旧券充值',
|
|
13
|
+
size: 'small',
|
|
14
|
+
groupKey:'content',
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
label: '票券框自定义文案:',
|
|
18
|
+
ele: 'el-input',
|
|
19
|
+
type: 'text',
|
|
20
|
+
valueKey: 'card_num_placeholder',
|
|
21
|
+
groupKey:'content',
|
|
22
|
+
value: data.card_num_placeholder||'',
|
|
23
|
+
placeholder: '请输入票券框自定义文案',
|
|
24
|
+
className: 'input80'
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
label: '票券充值点数自定义文案:',
|
|
28
|
+
ele: 'el-input',
|
|
29
|
+
type: 'text',
|
|
30
|
+
valueKey: 'point_placeholder',
|
|
31
|
+
groupKey:'content',
|
|
32
|
+
value: data.point_placeholder || '',
|
|
33
|
+
placeholder: '请输入票券充值点数自定义文案',
|
|
34
|
+
className: 'input80'
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
ele: 'title',
|
|
38
|
+
label: '新券购买',
|
|
39
|
+
size: 'small',
|
|
40
|
+
groupKey:'content',
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
label: '立即购买自定义文案:',
|
|
44
|
+
ele: 'el-input',
|
|
45
|
+
type: 'text',
|
|
46
|
+
valueKey: 'buyBtnName',
|
|
47
|
+
groupKey:'content',
|
|
48
|
+
value: data.buyBtnName || '',
|
|
49
|
+
placeholder: '请输入立即购买自定义文案',
|
|
50
|
+
className: 'input80'
|
|
51
|
+
},
|
|
52
|
+
|
|
53
|
+
{
|
|
54
|
+
ele: 'title',
|
|
55
|
+
label: '其他设置',
|
|
56
|
+
size: 'small',
|
|
57
|
+
groupKey:'content',
|
|
58
|
+
},
|
|
59
|
+
|
|
60
|
+
{
|
|
61
|
+
label: '注意事项:',
|
|
62
|
+
ele: 'xd-site-news',
|
|
63
|
+
valueKey: 'notice',
|
|
64
|
+
groupKey:'content',
|
|
65
|
+
value: data.notice || null,
|
|
66
|
+
className: 'input70',
|
|
67
|
+
setting: {
|
|
68
|
+
config: {
|
|
69
|
+
sort: true,
|
|
70
|
+
maxlen: 100,
|
|
71
|
+
action: 'aliyun',
|
|
72
|
+
size: 5,
|
|
73
|
+
tipsformet: '上传文件格式:@imageType@,不超过@size@MB.',
|
|
74
|
+
uploadType: 'aliyun',
|
|
75
|
+
type: ['jpg', 'png', 'jpeg']
|
|
76
|
+
},
|
|
77
|
+
},
|
|
78
|
+
handleCustom({action, data}) {
|
|
79
|
+
if (data && data.params) {
|
|
80
|
+
//当一个插件中出现使用内容分类时候需要设置code值,在页面引用时候容器id + code进行拼接
|
|
81
|
+
//data.params = Object.assign({}, data.params, {code: 'g_test_id'});
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
//获取返回参数(场景类型名称为必填)
|
|
85
|
+
//let loading = XdBus.getParentApi('loading')({});
|
|
86
|
+
|
|
87
|
+
//获取返回参数(场景类型名称为必填)
|
|
88
|
+
let loading = { close(){}}
|
|
89
|
+
|
|
90
|
+
//获取显示内容
|
|
91
|
+
if (action === 'screen') {
|
|
92
|
+
XdBus.getParentApi('getOptionsSettingList')({setting_id: 'edtix_bucket_content_tip'})
|
|
93
|
+
.then(res => {
|
|
94
|
+
loading.close();
|
|
95
|
+
data.cb(res['list'])
|
|
96
|
+
})
|
|
97
|
+
.catch(error => {
|
|
98
|
+
console.error(error);
|
|
99
|
+
loading.close();
|
|
100
|
+
});
|
|
101
|
+
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
//获取返回参数(广告位高度必选项)
|
|
105
|
+
if (action === 'getNewsInfo') {
|
|
106
|
+
XdBus.getParentApi('cmsGetPublishEditxContent')(data.params)
|
|
107
|
+
.then(res => {
|
|
108
|
+
loading.close()
|
|
109
|
+
data.cb({list: res.list, selectId: res.selected})
|
|
110
|
+
})
|
|
111
|
+
.catch(error => {
|
|
112
|
+
loading.close()
|
|
113
|
+
console.error(error);
|
|
114
|
+
});
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
//获取产品业务线列表
|
|
118
|
+
if (action === 'namespace') {
|
|
119
|
+
XdBus.getParentApi('getOptionsNamespaces')({})
|
|
120
|
+
.then(res => {
|
|
121
|
+
loading.close()
|
|
122
|
+
data.cb(res['list'])
|
|
123
|
+
})
|
|
124
|
+
.catch(error => {
|
|
125
|
+
loading.close()
|
|
126
|
+
console.error(error);
|
|
127
|
+
});
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
//使用内容分类
|
|
131
|
+
if (action === 'cmsPublishEditxContent') {
|
|
132
|
+
loading = XdBus.getParentApi('loading')({});
|
|
133
|
+
XdBus.getParentApi('cmsPublishEditxContent')(data.params)
|
|
134
|
+
.then(res => {
|
|
135
|
+
console.log('cmsPublishEditxContent', res)
|
|
136
|
+
loading.close();
|
|
137
|
+
data.cb(res)
|
|
138
|
+
})
|
|
139
|
+
.catch(error => {
|
|
140
|
+
loading.close();
|
|
141
|
+
console.error(error);
|
|
142
|
+
});
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
//位置列表
|
|
146
|
+
if (action === 'getListPostion') {
|
|
147
|
+
loading = XdBus.getParentApi('loading')({});
|
|
148
|
+
XdBus.getParentApi('getListNewsPosition')(data.params)
|
|
149
|
+
.then(res => {
|
|
150
|
+
loading.close();
|
|
151
|
+
data.cb(res)
|
|
152
|
+
})
|
|
153
|
+
.catch(error => {
|
|
154
|
+
loading.close();
|
|
155
|
+
console.error(error);
|
|
156
|
+
});
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
//位置创建
|
|
160
|
+
if (action === 'addPostion') {
|
|
161
|
+
loading = XdBus.getParentApi('loading')({});
|
|
162
|
+
XdBus.getParentApi('addNewsPosition')(data.params)
|
|
163
|
+
.then(res => {
|
|
164
|
+
loading.close();
|
|
165
|
+
data.cb(true)
|
|
166
|
+
})
|
|
167
|
+
.catch(error => {
|
|
168
|
+
console.error(error);
|
|
169
|
+
loading.close();
|
|
170
|
+
data.cb(false)
|
|
171
|
+
});
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
//位置编辑
|
|
175
|
+
if (action === 'editPostion') {
|
|
176
|
+
loading = XdBus.getParentApi('loading')({});
|
|
177
|
+
XdBus.getParentApi('updateNewsPosition')(data.params)
|
|
178
|
+
.then(res => {
|
|
179
|
+
loading.close();
|
|
180
|
+
data.cb(true)
|
|
181
|
+
})
|
|
182
|
+
.catch(error => {
|
|
183
|
+
console.error(error);
|
|
184
|
+
loading.close();
|
|
185
|
+
data.cb(false)
|
|
186
|
+
});
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
//位置删除
|
|
190
|
+
if (action === 'deleltePostion') {
|
|
191
|
+
loading = XdBus.getParentApi('loading')({});
|
|
192
|
+
XdBus.getParentApi('deleteNewsPosition')(data.params)
|
|
193
|
+
.then(res => {
|
|
194
|
+
loading.close();
|
|
195
|
+
data.cb(true)
|
|
196
|
+
})
|
|
197
|
+
.catch(error => {
|
|
198
|
+
console.error(error);
|
|
199
|
+
loading.close();
|
|
200
|
+
data.cb(false)
|
|
201
|
+
});
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
//获取广告位内容列表
|
|
205
|
+
if (action === 'getListContent') {
|
|
206
|
+
loading = XdBus.getParentApi('loading')({});
|
|
207
|
+
XdBus.getParentApi('getListNewsContent')(data.params)
|
|
208
|
+
.then(res => {
|
|
209
|
+
loading.close();
|
|
210
|
+
data.cb(res)
|
|
211
|
+
})
|
|
212
|
+
.catch(error => {
|
|
213
|
+
loading.close();
|
|
214
|
+
console.error(error);
|
|
215
|
+
});
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
//广告内容创建
|
|
219
|
+
if (action === 'addContent') {
|
|
220
|
+
loading = XdBus.getParentApi('loading')({});
|
|
221
|
+
XdBus.getParentApi('addNewsContent')(data.params)
|
|
222
|
+
.then(res => {
|
|
223
|
+
loading.close();
|
|
224
|
+
data.cb(true)
|
|
225
|
+
})
|
|
226
|
+
.catch(error => {
|
|
227
|
+
console.error(error);
|
|
228
|
+
loading.close();
|
|
229
|
+
data.cb(false)
|
|
230
|
+
});
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
//广告内容编辑
|
|
234
|
+
if (action === 'editContent') {
|
|
235
|
+
loading = XdBus.getParentApi('loading')({});
|
|
236
|
+
XdBus.getParentApi('updateNewsContent')(data.params)
|
|
237
|
+
.then(res => {
|
|
238
|
+
loading.close();
|
|
239
|
+
data.cb(true)
|
|
240
|
+
})
|
|
241
|
+
.catch(error => {
|
|
242
|
+
console.error(error);
|
|
243
|
+
loading.close();
|
|
244
|
+
data.cb(false)
|
|
245
|
+
});
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
//广告内容删除
|
|
249
|
+
if (action === 'deleteContent') {
|
|
250
|
+
loading = XdBus.getParentApi('loading')({});
|
|
251
|
+
XdBus.getParentApi('deleteNewsContent')(data.params)
|
|
252
|
+
.then(res => {
|
|
253
|
+
loading.close();
|
|
254
|
+
data.cb(true)
|
|
255
|
+
})
|
|
256
|
+
.catch(error => {
|
|
257
|
+
console.error(error);
|
|
258
|
+
loading.close();
|
|
259
|
+
data.cb(false)
|
|
260
|
+
});
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
//内容发布
|
|
264
|
+
if (action === 'publish') {
|
|
265
|
+
loading = XdBus.getParentApi('loading')({});
|
|
266
|
+
console.log('publish', data.params)
|
|
267
|
+
XdBus.getParentApi('cmsPublishContent')(data.params)
|
|
268
|
+
.then(res => {
|
|
269
|
+
loading.close();
|
|
270
|
+
data.cb(res)
|
|
271
|
+
})
|
|
272
|
+
.catch(error => {
|
|
273
|
+
loading.close();
|
|
274
|
+
console.error(error);
|
|
275
|
+
});
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
//通知页面进行刷新
|
|
279
|
+
if (action === 'update') {
|
|
280
|
+
loading = XdBus.getParentApi('loading')({});
|
|
281
|
+
XdBus.getParentApi('getXdBusUpdateView')('onUpdateView', {});
|
|
282
|
+
loading.close()
|
|
283
|
+
}
|
|
284
|
+
},
|
|
285
|
+
},
|
|
286
|
+
{
|
|
287
|
+
label: '票券支付路径:',
|
|
288
|
+
ele: 'xd-select-pages-path',
|
|
289
|
+
valueKey: 'payPath',
|
|
290
|
+
groupKey:'advanced',
|
|
291
|
+
placeholder: '请选择票券支付路径',
|
|
292
|
+
value: data['payPath'] || {},
|
|
293
|
+
setting: {
|
|
294
|
+
router: XdBus.getParentApi('getPagesTree'),
|
|
295
|
+
},
|
|
296
|
+
inline: false,
|
|
297
|
+
},
|
|
298
|
+
].filter(i=>i)
|
|
299
|
+
},
|
|
300
|
+
advanced: [ ],
|
|
301
|
+
};
|