jufubao-mall 2.0.27 → 2.0.28

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-mall",
3
- "version": "2.0.27",
3
+ "version": "2.0.28",
4
4
  "private": false,
5
5
  "description": "聚福宝商城业务组件插件包",
6
6
  "main": "index.js",
@@ -6,7 +6,7 @@
6
6
  */
7
7
  module.exports = [
8
8
  {
9
- mapFnName: "resourceGetSearchFilter",
9
+ mapFnName: "resourceGetSearchFilters",
10
10
  title: "获取搜索过滤条件",
11
11
  path: "/mall/v1/shop/msearch-filter",
12
12
  isRule: true,
@@ -1,295 +1,18 @@
1
1
  'use strict';
2
2
 
3
- /**
4
- * @description 当表单组件中有联动操作时候,使用方法进行返回
5
- */
3
+ import style from "./cusAttr/style";
4
+ import advanced from "./cusAttr/advanced";
5
+ import content from "./cusAttr/content";
6
+
6
7
  export default {
7
8
  style: [],
8
- content: (data) => {
9
- return [
10
- {
11
- label: "组件样式",
12
- ele: "title",
13
- groupKey: "content",
14
- size: "small",
15
- },
16
- {
17
- label: "风格样式:",
18
- ele: "xd-radio",
19
- groupKey: "content",
20
- valueKey: "styleLayout",
21
- value: data.styleLayout || '1',
22
- list: [
23
- { label: "风格1", value: '1' },
24
- { label: "风格2", value: '2' },
25
- { label: "风格3", value: '3' }
26
- ],
27
- labelInline: true,
28
- },
29
- {
30
- label: "是否展示导航:",
31
- ele: "xd-radio",
32
- groupKey: "content",
33
- valueKey: "showBusinessLine",
34
- value: data.showBusinessLine || 'Y',
35
- list: [
36
- { label: "显示", value: 'Y' },
37
- { label: "隐藏", value: 'N' }
38
- ],
39
- labelInline: true,
40
- },
41
- data.showBusinessLine==='Y' && {
42
- label: "导航维度:",
43
- ele: "xd-radio",
44
- groupKey: "content",
45
- valueKey: "dimension",
46
- value: data.dimension || 'business',
47
- list: [
48
- { label: "按业务线", value: 'business' },
49
- { label: "按门店分类", value: 'store' }
50
- ],
51
- labelInline: true,
52
- indent: true
53
- },
54
- data.showBusinessLine==='Y' && {
55
- label: "全部分类:",
56
- ele: "xd-radio",
57
- groupKey: "content",
58
- valueKey: "showAllBusinessLine",
59
- value: data.showAllBusinessLine || 'Y',
60
- list: [
61
- { label: "显示", value: 'Y' },
62
- { label: "隐藏", value: 'N' }
63
- ],
64
- labelInline: true,
65
- indent: true
66
- },
67
- {
68
- label: "资源列表",
69
- ele: "title",
70
- groupKey: "content",
71
- size: "small",
72
- },
73
- {
74
- label: "快速入口:",
75
- ele: "xd-radio",
76
- groupKey: "content",
77
- valueKey: "showQuickEntry",
78
- value: data.showQuickEntry || 'Y',
79
- list: [
80
- { label: "显示", value: 'Y' },
81
- { label: "隐藏", value: 'N' }
82
- ],
83
- labelInline: true,
84
- },
85
- {
86
- label: "聚好兑:",
87
- ele: "el-input",
88
- valueKey: "jhdName",
89
- value: data.jhdName || "",
90
- placeholder: '自定义名称',
91
- groupKey: "content",
92
- className: "input40",
93
- indent: true,
94
- labelInline: true,
95
- hidden: data.showQuickEntry !== 'Y',
96
- },
97
- {
98
- label: "扫一扫:",
99
- ele: "el-input",
100
- valueKey: "scanName",
101
- value: data.scanName || "",
102
- placeholder: '自定义名称',
103
- groupKey: "content",
104
- className: "input40",
105
- indent: true,
106
- labelInline: true,
107
- hidden: data.showQuickEntry !== 'Y',
108
- },
109
- {
110
- label: "展快捷码:",
111
- ele: "el-input",
112
- valueKey: "takeGoodsName",
113
- value: data.takeGoodsName || "",
114
- placeholder: '自定义名称',
115
- groupKey: "content",
116
- className: "input40",
117
- indent: true,
118
- labelInline: true,
119
- hidden: data.showQuickEntry !== 'Y',
120
- },
121
- {
122
- label: "去购票:",
123
- ele: "el-input",
124
- valueKey: "buyTicketName",
125
- value: data.buyTicketName || "",
126
- placeholder: '自定义名称',
127
- groupKey: "content",
128
- className: "input40",
129
- indent: true,
130
- labelInline: true,
131
- hidden: data.showQuickEntry !== 'Y',
132
- },
133
- {
134
- label: "背景颜色:",
135
- ele: "xd-color",
136
- valueKey: "bodyBgColor",
137
- value: data.bodyBgColor || "",
138
- groupKey: "style",
139
- },
140
- {
141
- label: "填充设置:",
142
- ele: "xd-margin-padding",
143
- valueKey: "bodyPadding",
144
- value: data.bodyPadding || {},
145
- groupKey: "style",
146
- setting: {
147
- type: 'margin',
148
- },
149
- inline: false,
150
- notice: '填充内边距,<span style="color: red">单位:像素</span>。默认值:<span style="color:red">0</span>像素',
151
- },
152
- {
153
- label: "内容配置设置",
154
- ele: "title",
155
- groupKey: "style",
156
- size: "small"
157
- },
158
- {
159
- label: "背景颜色:",
160
- ele: "xd-color",
161
- valueKey: "cardItemBgColor",
162
- value: data.cardItemBgColor || "#FFFFFF",
163
- groupKey: "style",
164
- labelInline: true,
165
- },
166
- {
167
- label: "间距设置:",
168
- ele: "el-input",
169
- valueKey: "cardItemSpace",
170
- value: data.cardItemSpace || "20",
171
- placeholder: '请输入间距',
172
- groupKey: "style",
173
- className: "input80",
174
- labelInline: true,
175
- inline: false,
176
- notice: '设置间距,<span style="color: red">单位:像素</span>。默认值:<span style="color:red">20</span>像素',
177
- },
178
- {
179
- label: '投影设置:',
180
- ele: 'xd-shadow',
181
- groupKey:'style',
182
- labelInline: true,
183
- valueKey: 'cardItemShadow',
184
- value: data['cardItemShadow'] || '',
185
- setting: {
186
- selected: 'N',
187
- },
188
- handleCustom({action, data}) {
189
- XdBus.getParentApi('getOptionsSettingList')({setting_id: 'edtix_style_radius'})
190
- .then(res => {
191
- data.cb(res.list)
192
- })
193
- .catch(error => {
194
- console.error(error);
195
- data.cb([])
196
- });
197
- },
198
- },
199
- {
200
- label: '边框设置:',
201
- ele: 'xd-border',
202
- groupKey:'style',
203
- labelInline: true,
204
- valueKey: 'cardItemBorder',
205
- value: data['cardItemBorder'] || '',
206
- setting: {
207
- selected:'N'
208
- },
209
- },
210
- {
211
- label: "圆角设置:",
212
- groupKey: 'style',
213
- ele: 'xd-slider',
214
- valueKey: "cardItemRadius",
215
- value: data['cardItemRadius'] === undefined?16:data['cardItemRadius'] ,
216
- className: "input80",
217
- labelInline: true,
218
- setting:{
219
- min: 0,//最小值
220
- max: 60, //最小值
221
- step:1, //步长
222
- showStops:false,//显示间断点
223
- showInput:false,//显示输入框
224
- }
225
- },
9
+ advanced: [],
10
+ content: (data, gValue, gColor, oldData={})=>{
226
11
 
227
- {
228
- label: '门店详情跳转路径:',
229
- ele: 'xd-select-pages-path',
230
- valueKey: 'shopInfoPath',
231
- groupKey:'advanced',
232
- placeholder: '请选择门店详情跳转路径',
233
- value: data.shopInfoPath || null,
234
- className: 'input100',
235
- setting: {
236
- router: XdBus.getParentApi('getPagesTree'),
237
- },
238
- inline: false,
239
- },
240
- {
241
- label: '扫一扫跳转路径:',
242
- ele: 'xd-select-pages-path',
243
- valueKey: 'scanPath',
244
- placeholder: '请选择扫一扫跳转路径',
245
- groupKey:'advanced',
246
- className: 'input100',
247
- value: data['scanPath'] || null,
248
- setting: {
249
- router: XdBus.getParentApi('getPagesTree'),
250
- },
251
- inline: false,
252
- },
253
- {
254
- label: '聚好兑跳转路径:',
255
- ele: 'xd-select-pages-path',
256
- valueKey: 'exchangePath',
257
- placeholder: '请选择聚好兑跳转路径',
258
- groupKey:'advanced',
259
- className: 'input100',
260
- value: data['exchangePath'] || null,
261
- setting: {
262
- router: XdBus.getParentApi('getPagesTree'),
263
- },
264
- inline: false,
265
- },
266
- {
267
- label: '去提货跳转路径:',
268
- ele: 'xd-select-pages-path',
269
- valueKey: 'takeGoodsPath',
270
- placeholder: '请选择去提货跳转路径',
271
- groupKey:'advanced',
272
- className: 'input100',
273
- value: data['takeGoodsPath'] || null,
274
- setting: {
275
- router: XdBus.getParentApi('getPagesTree'),
276
- },
277
- inline: false,
278
- },
279
- {
280
- label: '去购票跳转路径:',
281
- ele: 'xd-select-pages-path',
282
- valueKey: 'buyTicketPath',
283
- placeholder: '请选择去购票跳转路径',
284
- groupKey:'advanced',
285
- className: 'input100',
286
- value: data['buyTicketPath'] || null,
287
- setting: {
288
- router: XdBus.getParentApi('getPagesTree'),
289
- },
290
- inline: false,
291
- },
292
- ].filter(i=>i)
12
+ return [
13
+ ...content(data, gValue,gColor,oldData),
14
+ ...style(data, gValue,gColor,oldData),
15
+ ...advanced(data),
16
+ ].filter(i=>i)
293
17
  },
294
- advanced: [],
295
- };
18
+ }