jufubao-base 1.0.311-beta101 → 1.0.311-beta3
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/JfbBaseBlock/Attr.js +34 -167
- package/src/components/JfbBaseBlock/JfbBaseBlock.vue +9 -12
- package/src/components/JfbBaseCardDetail/Attr.js +12 -0
- package/src/components/JfbBaseCardDetail/JfbBaseCardDetail.vue +162 -1
- package/src/components/JfbBaseCardDetailEntry/Attr.js +12 -0
- package/src/components/JfbBaseCardDetailEntry/JfbBaseCardDetailEntry.vue +163 -2
- package/src/components/JfbBaseCardInfo/JfbBaseCardInfo.vue +2 -2
- package/src/components/JfbBaseCardInfoEntry/JfbBaseCardInfoEntry.vue +3 -3
- package/src/components/JfbBaseEntry/Attr.js +72 -5
- package/src/components/JfbBaseEntry/JfbBaseEntry.vue +47 -183
- package/src/components/JfbBaseImageBlock/Attr.js +23 -150
- package/src/components/JfbBaseImageBlock/JfbBaseImageBlock.vue +27 -29
- package/src/components/JfbBaseNotice/Attr.js +512 -5
- package/src/components/JfbBaseNotice/JfbBaseNotice.vue +181 -188
- package/src/components/JfbBaseVideo/Attr.js +297 -5
- package/src/components/JfbBaseVideo/JfbBaseVideo.vue +62 -36
- package/src/components/JfbBaseEntry/cusAttr/content.js +0 -77
- package/src/components/JfbBaseEntry/cusAttr/style.js +0 -288
- package/src/components/JfbBaseNotice/cusAttr/content.js +0 -308
- package/src/components/JfbBaseNotice/cusAttr/cssOne.js +0 -395
- package/src/components/JfbBaseNotice/cusAttr/cssThree.js +0 -101
- package/src/components/JfbBaseNotice/cusAttr/cssTwo.js +0 -208
- package/src/components/JfbBaseNotice/cusAttr/style.js +0 -31
- package/src/components/JfbBaseVideo/cusAttr/content.js +0 -236
- package/src/components/JfbBaseVideo/cusAttr/image.js +0 -213
- package/src/components/JfbBaseVideo/cusAttr/style.js +0 -172
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
import cssThree from "./cssThree";
|
|
4
|
-
import cssTwo from "./cssTwo";
|
|
5
|
-
import cssOne from "./cssOne";
|
|
6
|
-
export default function (data, gValue, gColor, oldData) {
|
|
7
|
-
return [
|
|
8
|
-
...cssOne(data, gValue, gColor, oldData),
|
|
9
|
-
...cssTwo(data, gValue, gColor, oldData),
|
|
10
|
-
...cssThree(data, gValue, gColor, oldData),
|
|
11
|
-
{
|
|
12
|
-
label: '版本号:',
|
|
13
|
-
ele: 'el-input',
|
|
14
|
-
type: 'text',
|
|
15
|
-
groupKey: 'content',
|
|
16
|
-
valueKey: 'version',
|
|
17
|
-
value: 'v2.0',
|
|
18
|
-
hidden: true,
|
|
19
|
-
},
|
|
20
|
-
{
|
|
21
|
-
label: '过滤引用模版字段:',
|
|
22
|
-
ele: 'el-input',
|
|
23
|
-
type: 'text',
|
|
24
|
-
groupKey: 'content',
|
|
25
|
-
valueKey: 'refFilterKey',
|
|
26
|
-
value: '[]',
|
|
27
|
-
hidden: true,
|
|
28
|
-
},
|
|
29
|
-
].filter(i=>i);
|
|
30
|
-
}
|
|
31
|
-
|
|
@@ -1,236 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
import {
|
|
3
|
-
dataVal ,
|
|
4
|
-
statusShow,
|
|
5
|
-
statusDataVal,
|
|
6
|
-
customVal,
|
|
7
|
-
cusDisabled ,
|
|
8
|
-
getCustomAttr,
|
|
9
|
-
isArray,
|
|
10
|
-
isObject
|
|
11
|
-
} from "@/utils/AttrTools";
|
|
12
|
-
|
|
13
|
-
export default (data, gValue,gColor,oldData)=>{
|
|
14
|
-
let video = { size: {width:690, height: 388}, type:'1', position: {}};
|
|
15
|
-
return[
|
|
16
|
-
{
|
|
17
|
-
ele: 'title',
|
|
18
|
-
label: '基础',
|
|
19
|
-
size: 'small',
|
|
20
|
-
groupKey:'content',
|
|
21
|
-
},
|
|
22
|
-
{
|
|
23
|
-
label: '组件样式',
|
|
24
|
-
ele: 'xd-site-poster',
|
|
25
|
-
valueKey: 'video',
|
|
26
|
-
groupKey:'content',
|
|
27
|
-
className: 'input100',
|
|
28
|
-
value: video,
|
|
29
|
-
labelInline:true,
|
|
30
|
-
setting: {
|
|
31
|
-
count: 1,
|
|
32
|
-
scene: {label: '视频', value: 'video'},
|
|
33
|
-
sizeDisabled: {
|
|
34
|
-
wDisabled:true,
|
|
35
|
-
hDisabled: false,
|
|
36
|
-
},
|
|
37
|
-
isNew: 'video',
|
|
38
|
-
},
|
|
39
|
-
handleCustom({action, data}) {
|
|
40
|
-
//设置场景参数
|
|
41
|
-
if(data) {
|
|
42
|
-
data.params = Object.assign({}, {scene: 'video'}, data.params || {})
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
//获取显示内容
|
|
46
|
-
if (action === 'screenList') {
|
|
47
|
-
XdBus.getParentApi('getOptionsSettingList')({setting_id: 'editx_base_ad_split_screen'})
|
|
48
|
-
.then(res => {
|
|
49
|
-
data.cb(res['list'])
|
|
50
|
-
})
|
|
51
|
-
.catch(error => {
|
|
52
|
-
console.error(error);
|
|
53
|
-
});
|
|
54
|
-
return
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
//获取返回参数(广告位高度必选项)
|
|
58
|
-
if (action === 'getPosterInfo') {
|
|
59
|
-
XdBus.getParentApi('cmsGetPublishEditxContent')(data.params)
|
|
60
|
-
.then(res => {
|
|
61
|
-
data.cb({list: res.list, selectId: res.selected})
|
|
62
|
-
})
|
|
63
|
-
.catch(error => {
|
|
64
|
-
console.error(error);
|
|
65
|
-
});
|
|
66
|
-
return
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
//使用内容分类
|
|
70
|
-
if (action === 'cmsPublishEditxContent') {
|
|
71
|
-
XdBus.getParentApi('cmsPublishEditxContent')(data.params)
|
|
72
|
-
.then(res => {
|
|
73
|
-
data.cb(res)
|
|
74
|
-
})
|
|
75
|
-
.catch(error => {
|
|
76
|
-
console.error(error);
|
|
77
|
-
});
|
|
78
|
-
return
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
let loading = XdBus.getParentApi('loading')({});
|
|
82
|
-
//位置列表
|
|
83
|
-
if (action === 'getListPostion') {
|
|
84
|
-
XdBus.getParentApi('getListPosterPosition')(data.params)
|
|
85
|
-
.then(res => {
|
|
86
|
-
loading.close();
|
|
87
|
-
data.cb(res)
|
|
88
|
-
})
|
|
89
|
-
.catch(error => {
|
|
90
|
-
loading.close();
|
|
91
|
-
console.error(error);
|
|
92
|
-
});
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
//位置创建
|
|
96
|
-
if (action === 'addPostion') {
|
|
97
|
-
XdBus.getParentApi('addPosterPosition')(data.params)
|
|
98
|
-
.then(res => {
|
|
99
|
-
loading.close();
|
|
100
|
-
data.cb(true)
|
|
101
|
-
})
|
|
102
|
-
.catch(error => {
|
|
103
|
-
console.error(error);
|
|
104
|
-
loading.close();
|
|
105
|
-
data.cb(false)
|
|
106
|
-
});
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
//位置编辑
|
|
110
|
-
if (action === 'editPostion') {
|
|
111
|
-
XdBus.getParentApi('updatePosterPosition')(data.params)
|
|
112
|
-
.then(res => {
|
|
113
|
-
loading.close();
|
|
114
|
-
data.cb(true)
|
|
115
|
-
})
|
|
116
|
-
.catch(error => {
|
|
117
|
-
console.error(error);
|
|
118
|
-
loading.close();
|
|
119
|
-
data.cb(false)
|
|
120
|
-
});
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
//位置删除
|
|
124
|
-
if (action === 'deleltePostion') {
|
|
125
|
-
XdBus.getParentApi('deletePosterPosition')(data.params)
|
|
126
|
-
.then(res => {
|
|
127
|
-
loading.close();
|
|
128
|
-
data.cb(true)
|
|
129
|
-
})
|
|
130
|
-
.catch(error => {
|
|
131
|
-
console.error(error);
|
|
132
|
-
loading.close();
|
|
133
|
-
data.cb(false)
|
|
134
|
-
});
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
//获取广告位内容列表
|
|
138
|
-
if (action === 'getListContent') {
|
|
139
|
-
XdBus.getParentApi('getListPosterContent')(data.params)
|
|
140
|
-
.then(res => {
|
|
141
|
-
loading.close();
|
|
142
|
-
data.cb(res)
|
|
143
|
-
})
|
|
144
|
-
.catch(error => {
|
|
145
|
-
loading.close();
|
|
146
|
-
console.error(error);
|
|
147
|
-
});
|
|
148
|
-
}
|
|
149
|
-
|
|
150
|
-
//广告内容创建
|
|
151
|
-
if (action === 'addContent') {
|
|
152
|
-
XdBus.getParentApi('addPosterContent')(data.params)
|
|
153
|
-
.then(res => {
|
|
154
|
-
loading.close();
|
|
155
|
-
data.cb(true)
|
|
156
|
-
})
|
|
157
|
-
.catch(error => {
|
|
158
|
-
console.error(error);
|
|
159
|
-
loading.close();
|
|
160
|
-
data.cb(false)
|
|
161
|
-
});
|
|
162
|
-
}
|
|
163
|
-
|
|
164
|
-
//广告内容编辑
|
|
165
|
-
if (action === 'editContent') {
|
|
166
|
-
XdBus.getParentApi('updatePosterContent')(data.params)
|
|
167
|
-
.then(res => {
|
|
168
|
-
loading.close();
|
|
169
|
-
data.cb(true)
|
|
170
|
-
})
|
|
171
|
-
.catch(error => {
|
|
172
|
-
console.error(error);
|
|
173
|
-
loading.close();
|
|
174
|
-
data.cb(false)
|
|
175
|
-
});
|
|
176
|
-
}
|
|
177
|
-
|
|
178
|
-
//广告内容删除
|
|
179
|
-
if (action === 'deleteContent') {
|
|
180
|
-
XdBus.getParentApi('deletePosterContent')(data.params)
|
|
181
|
-
.then(res => {
|
|
182
|
-
loading.close();
|
|
183
|
-
data.cb(true)
|
|
184
|
-
})
|
|
185
|
-
.catch(error => {
|
|
186
|
-
console.error(error);
|
|
187
|
-
loading.close();
|
|
188
|
-
data.cb(false)
|
|
189
|
-
});
|
|
190
|
-
}
|
|
191
|
-
|
|
192
|
-
//获取广告内容跳转地址类型
|
|
193
|
-
if (action === 'jumpPosterContentType') {
|
|
194
|
-
XdBus.getParentApi('getOptionsSettingList')({setting_id: "cms_setting"})
|
|
195
|
-
.then(res => {
|
|
196
|
-
loading.close();
|
|
197
|
-
data.cb(res['redirect_type'])
|
|
198
|
-
})
|
|
199
|
-
.catch(error => {
|
|
200
|
-
loading.close();
|
|
201
|
-
console.error(error);
|
|
202
|
-
});
|
|
203
|
-
}
|
|
204
|
-
|
|
205
|
-
//发布
|
|
206
|
-
if (action === 'publish') {
|
|
207
|
-
console.log('publish', data.params)
|
|
208
|
-
XdBus.getParentApi('cmsPublishContent')(data.params)
|
|
209
|
-
.then(res => {
|
|
210
|
-
loading.close();
|
|
211
|
-
data.cb(res)
|
|
212
|
-
})
|
|
213
|
-
.catch(error => {
|
|
214
|
-
loading.close();
|
|
215
|
-
console.error(error);
|
|
216
|
-
});
|
|
217
|
-
}
|
|
218
|
-
|
|
219
|
-
//获取站内页面地址
|
|
220
|
-
if (action === 'router') {
|
|
221
|
-
loading.close()
|
|
222
|
-
return XdBus.getParentApi('getPagesTree');
|
|
223
|
-
|
|
224
|
-
}
|
|
225
|
-
|
|
226
|
-
//通知页面进行刷新
|
|
227
|
-
if(action === 'update') {
|
|
228
|
-
XdBus.getParentApi('getXdBusUpdateView')('onUpdateView', {});
|
|
229
|
-
loading.close()
|
|
230
|
-
}
|
|
231
|
-
},
|
|
232
|
-
notice:`建议尺寸:${video.size.width}*${video.size.height}`,
|
|
233
|
-
inline: false,
|
|
234
|
-
},
|
|
235
|
-
]
|
|
236
|
-
}
|
|
@@ -1,213 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
import {
|
|
3
|
-
dataVal,
|
|
4
|
-
statusShow,
|
|
5
|
-
getPMarginRLTB,
|
|
6
|
-
getAttrData,
|
|
7
|
-
getBorOrShaHeight,
|
|
8
|
-
cRaBorShadow
|
|
9
|
-
} from "@/utils/AttrTools";
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
export default (data, gValue, gColor, oldData ,isBody=false)=> {
|
|
13
|
-
let listLayout = 'slide';
|
|
14
|
-
if(data['listLayout'] !== undefined) listLayout = data['listLayout'];
|
|
15
|
-
|
|
16
|
-
let listRow = 1;
|
|
17
|
-
let enterMode = 'round';
|
|
18
|
-
let carouselHeight = 0; //滚动高度
|
|
19
|
-
if(listLayout === 'carousel') {
|
|
20
|
-
listRow = 2;
|
|
21
|
-
if(data['listRow'] !== undefined) listRow = data['listRow'];
|
|
22
|
-
if(data['enterMode'] !== undefined) enterMode = data['enterMode'];
|
|
23
|
-
if(enterMode === 'normal') carouselHeight = 10;
|
|
24
|
-
else carouselHeight = 46;
|
|
25
|
-
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
//品牌内容显示
|
|
29
|
-
let itemHeight = 0, bodyHeight = 0, bodyWidth = 0, tabHeight = 56;
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
//滑动效果
|
|
33
|
-
if(listLayout === 'slide') {
|
|
34
|
-
let text = 36;
|
|
35
|
-
let image = 120;
|
|
36
|
-
itemHeight = text + image + getAttrData(data,'imageText', [16,44],{
|
|
37
|
-
sKey: 'imageTextStatus',
|
|
38
|
-
fields:['imageText'],
|
|
39
|
-
isData: true,
|
|
40
|
-
gValue
|
|
41
|
-
});
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
//轮廓外边距
|
|
45
|
-
let defMargin = {top:0,left:16,right:16, bottom:16},oldDefMargin = {top:0,left:0,right:0, bottom:20};
|
|
46
|
-
let bodyMargin = getAttrData(data,'margin', [defMargin,oldDefMargin],{
|
|
47
|
-
sKey: 'marginStatus',
|
|
48
|
-
fields:['margin'],
|
|
49
|
-
isPM:true,
|
|
50
|
-
isData: true,
|
|
51
|
-
gValue
|
|
52
|
-
});
|
|
53
|
-
bodyWidth = 750 - getPMarginRLTB(bodyMargin,'RL', 0);
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
//轮廓内填充
|
|
57
|
-
let defBgImagePadding = 0, oldDefBgImagePadding = 32;
|
|
58
|
-
if(listLayout === 'carousel') {
|
|
59
|
-
defBgImagePadding = 0;
|
|
60
|
-
oldDefBgImagePadding = 0;
|
|
61
|
-
}
|
|
62
|
-
let bodyPadding = getAttrData(data,'bgImagePadding', [defBgImagePadding,oldDefBgImagePadding],{
|
|
63
|
-
sKey: 'bgImagePaddingStatus',
|
|
64
|
-
fields:['bgImagePadding'],
|
|
65
|
-
isPM:true,
|
|
66
|
-
isData: true,
|
|
67
|
-
gValue
|
|
68
|
-
});
|
|
69
|
-
let bodyPaddingTB = getPMarginRLTB(bodyPadding,'TB', 0);
|
|
70
|
-
if(isBody === false) bodyWidth = bodyWidth - getPMarginRLTB(bodyPadding,'RL', 0);
|
|
71
|
-
|
|
72
|
-
//内容区域投影
|
|
73
|
-
let itemShadow = cRaBorShadow( data, 'itemShadow', {dValue:'N', old:['is_shadow','is_shadow_w','is_shadow_bg']},gValue);
|
|
74
|
-
let itemShadowWidth = getBorOrShaHeight(itemShadow,{width:0, type:'N'});
|
|
75
|
-
|
|
76
|
-
//内容区域边距
|
|
77
|
-
let defItemPadding = {top:16,left:16,right:0, bottom:16}, oldDefItemPadding = {top:32,left:0,right:0, bottom:0};
|
|
78
|
-
if(listLayout === 'carousel') {
|
|
79
|
-
defItemPadding = 16;
|
|
80
|
-
oldDefItemPadding = 20;
|
|
81
|
-
}
|
|
82
|
-
let itemPadding = getAttrData(data,'itemPadding', [defItemPadding,oldDefItemPadding],{
|
|
83
|
-
sKey: 'itemPaddingStatus',
|
|
84
|
-
fields:['itemPadding'],
|
|
85
|
-
isPM:true,
|
|
86
|
-
isData: true,
|
|
87
|
-
gValue
|
|
88
|
-
});
|
|
89
|
-
itemPadding.top = Math.max(itemPadding.top,itemShadowWidth);
|
|
90
|
-
itemPadding.bottom = Math.max(itemPadding.bottom,itemShadowWidth);
|
|
91
|
-
itemPadding.left = Math.max(itemPadding.left,itemShadowWidth);
|
|
92
|
-
itemPadding.right = Math.max(itemPadding.right,itemShadowWidth);
|
|
93
|
-
let itemPaddingTB = getPMarginRLTB(itemPadding,'TB', 0);
|
|
94
|
-
|
|
95
|
-
//品牌填充
|
|
96
|
-
let defContPadding = 16,defOldContPadding = {top:32, left:32, right:32, bottom:16};
|
|
97
|
-
if(listLayout === 'carousel') {
|
|
98
|
-
defContPadding = 0;
|
|
99
|
-
defOldContPadding = 0;
|
|
100
|
-
}
|
|
101
|
-
let contPadding = getAttrData(data,'contPadding', [defContPadding,defOldContPadding],{
|
|
102
|
-
sKey: 'contPaddingStatus',
|
|
103
|
-
fields:['contPadding'],
|
|
104
|
-
isPM:true,
|
|
105
|
-
isData: true,
|
|
106
|
-
gValue
|
|
107
|
-
});
|
|
108
|
-
if(listLayout === 'carousel') contPadding = {top:0, bottom:0, left: 0, right:0}
|
|
109
|
-
let contPaddingTB = getPMarginRLTB(contPadding,'TB', 0);
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
//品牌边框
|
|
113
|
-
let tabBorder = cRaBorShadow( data, 'tabBorder', {dValue:'N'},gValue);
|
|
114
|
-
let tabBorderWidth = getBorOrShaHeight(tabBorder,{width:0, type:'N'}) * 2;
|
|
115
|
-
|
|
116
|
-
//标题边距
|
|
117
|
-
let tabPadding = getAttrData(data,'tabPadding', [24,{top:0, left:0, right:0, bottom:0}],{
|
|
118
|
-
sKey: 'tabPaddingStatus',
|
|
119
|
-
fields:['tabPadding'],
|
|
120
|
-
isPM:true,
|
|
121
|
-
isData: true,
|
|
122
|
-
gValue
|
|
123
|
-
});
|
|
124
|
-
let tabPaddingTB = getPMarginRLTB(tabPadding,'TB', 0);
|
|
125
|
-
|
|
126
|
-
//标题描边
|
|
127
|
-
let itemBorder = cRaBorShadow( data, 'itemBorder', {dValue:'D'},gValue);
|
|
128
|
-
let itemBorderWidth = getBorOrShaHeight(itemBorder,{width:2, type:'Y'}) * 2;
|
|
129
|
-
|
|
130
|
-
//间距设置
|
|
131
|
-
let spacing = listLayout === 'slide'?16:24;
|
|
132
|
-
let itemSpacing = getAttrData(data,'padding', [spacing,32],{
|
|
133
|
-
sKey: 'paddingStatus',
|
|
134
|
-
fields:['itemSpacing'],
|
|
135
|
-
isData: true,
|
|
136
|
-
gValue
|
|
137
|
-
});
|
|
138
|
-
let rowSpacing = getAttrData(data,'rowSpacing', [spacing,10],{
|
|
139
|
-
sKey: 'paddingStatus',
|
|
140
|
-
fields:['rowSpacing'],
|
|
141
|
-
isData: true,
|
|
142
|
-
gValue
|
|
143
|
-
});
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
//轮播图
|
|
147
|
-
if(listLayout === 'carousel'){
|
|
148
|
-
const cell = 5;
|
|
149
|
-
const textHeight = 40; //品牌标题高度
|
|
150
|
-
const bodyPaddingRL = getPMarginRLTB(bodyPadding,'RL', 0);
|
|
151
|
-
const bodyMarginRL = getPMarginRLTB(bodyMargin,'RL', 0);
|
|
152
|
-
const itemPaddingRL = getPMarginRLTB(itemPadding,'RL', 0);
|
|
153
|
-
const cellWidth = itemSpacing * (cell - 1);
|
|
154
|
-
const rowWidth = rowSpacing * (listRow - 1);
|
|
155
|
-
let itemWidth = 750 - bodyPaddingRL - bodyMarginRL - itemPaddingRL - cellWidth - itemBorderWidth * (cell - 1);
|
|
156
|
-
itemWidth = itemWidth/5;
|
|
157
|
-
const textMarginTop = 8;//标题间距
|
|
158
|
-
itemHeight = (itemWidth + textHeight + textMarginTop) * listRow + rowWidth;
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
//内容区域高度
|
|
162
|
-
let contentHeight = carouselHeight + itemHeight + itemPaddingTB + contPaddingTB + itemBorderWidth * listRow;
|
|
163
|
-
//标题区域高度
|
|
164
|
-
let titleHeight = tabHeight + tabPaddingTB + tabBorderWidth + bodyPaddingTB;
|
|
165
|
-
|
|
166
|
-
if(isBody) bodyHeight = contentHeight + titleHeight;
|
|
167
|
-
else bodyHeight = contentHeight;
|
|
168
|
-
|
|
169
|
-
bodyHeight = Math.floor(bodyHeight);
|
|
170
|
-
bodyWidth = Math.floor(bodyWidth);
|
|
171
|
-
|
|
172
|
-
return [
|
|
173
|
-
isBody === true && {
|
|
174
|
-
label: '背景图',
|
|
175
|
-
ele: 'xd-upload',
|
|
176
|
-
valueKey: 'bgImage',
|
|
177
|
-
defaultValue: dataVal({data, key:'bgImage', dValue: {}, gValue}),
|
|
178
|
-
value: dataVal({data, key:'bgImage', dValue:{}, gValue}),
|
|
179
|
-
hidden: !statusShow({data, key: 'outBgColorStatus', fields:['outBgColor','bgImage'], gValue}),
|
|
180
|
-
labelInline:true,
|
|
181
|
-
slot: true,
|
|
182
|
-
tipsformet: `上传文件格式:@imageType@,不超过@size@MB.,建议尺寸为:<span style="color:red">${bodyWidth}*${bodyHeight}</span>像素。`,
|
|
183
|
-
type: ['jpg', 'png', 'jpeg'],
|
|
184
|
-
styleType: 'one',
|
|
185
|
-
uploadType: 'aliyun',
|
|
186
|
-
size: 2,
|
|
187
|
-
action: 'aliyun',
|
|
188
|
-
oneWidth: 275,
|
|
189
|
-
oneHeight: 275 * (bodyHeight)/ bodyWidth,
|
|
190
|
-
groupKey: 'style'
|
|
191
|
-
},
|
|
192
|
-
isBody === false && {
|
|
193
|
-
label: '背景图',
|
|
194
|
-
ele: 'xd-upload',
|
|
195
|
-
valueKey: 'contBgImage',
|
|
196
|
-
defaultValue: dataVal({data, key:'contBgImage', dValue: {}, gValue}),
|
|
197
|
-
value: dataVal({data, key:'contBgImage', dValue:{}, gValue}),
|
|
198
|
-
hidden: !statusShow({data, key: 'contBgColorStatus', fields:['contBgColor','contBgImage'], gValue}),
|
|
199
|
-
labelInline:true,
|
|
200
|
-
slot: true,
|
|
201
|
-
tipsformet: `上传文件格式:@imageType@,不超过@size@MB.,建议尺寸为:<span style="color:red">${bodyWidth}*${bodyHeight}</span>像素。`,
|
|
202
|
-
type: ['jpg', 'png', 'jpeg'],
|
|
203
|
-
styleType: 'one',
|
|
204
|
-
uploadType: 'aliyun',
|
|
205
|
-
size: 2,
|
|
206
|
-
action: 'aliyun',
|
|
207
|
-
oneWidth: 275,
|
|
208
|
-
oneHeight: 275 * (bodyHeight)/ bodyWidth,
|
|
209
|
-
groupKey: 'style'
|
|
210
|
-
}
|
|
211
|
-
].filter(i=>i);
|
|
212
|
-
}
|
|
213
|
-
|
|
@@ -1,172 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
import {dataVal, statusDataVal, statusShow} from "@/utils/AttrTools";
|
|
4
|
-
export default function (data, gValue, gColor, oldData) {
|
|
5
|
-
return [
|
|
6
|
-
{
|
|
7
|
-
ele: 'title',
|
|
8
|
-
label: '常规',
|
|
9
|
-
size: 'small',
|
|
10
|
-
groupKey:'style',
|
|
11
|
-
},
|
|
12
|
-
{
|
|
13
|
-
label: '外边距',
|
|
14
|
-
ele: 'xd-radio',
|
|
15
|
-
groupKey: 'style',
|
|
16
|
-
valueKey: 'marginStatus',
|
|
17
|
-
value: statusDataVal({data, key:'marginStatus', fields:['margin'],gValue}),
|
|
18
|
-
labelInline:true,
|
|
19
|
-
list: [
|
|
20
|
-
{label: '默认', value: 'D'},
|
|
21
|
-
{label: '自定义', value: 'C'},
|
|
22
|
-
]
|
|
23
|
-
},
|
|
24
|
-
{ele: 'group_start'},
|
|
25
|
-
{
|
|
26
|
-
label: '',
|
|
27
|
-
ele: 'xd-margin-padding',
|
|
28
|
-
groupKey:'style',
|
|
29
|
-
valueKey: 'margin',
|
|
30
|
-
value: dataVal({
|
|
31
|
-
data,
|
|
32
|
-
key:'margin',
|
|
33
|
-
dValue:0,
|
|
34
|
-
gValue,
|
|
35
|
-
isPM: true,
|
|
36
|
-
}),
|
|
37
|
-
hidden: !statusShow({data, key: 'marginStatus', fields:['margin'], gValue}),
|
|
38
|
-
setting: {
|
|
39
|
-
type: 'margin',
|
|
40
|
-
},
|
|
41
|
-
},
|
|
42
|
-
{ele: 'group_end'},
|
|
43
|
-
{
|
|
44
|
-
ele: 'title',
|
|
45
|
-
label: '內容区',
|
|
46
|
-
size: 'small',
|
|
47
|
-
groupKey:'style',
|
|
48
|
-
},
|
|
49
|
-
{
|
|
50
|
-
label: '内容区背景',
|
|
51
|
-
ele: 'xd-radio',
|
|
52
|
-
groupKey: 'style',
|
|
53
|
-
valueKey: 'bgColorStatus',
|
|
54
|
-
value: statusDataVal({data, key:'bgColorStatus', fields:['bgColor'],gValue}),
|
|
55
|
-
labelInline:true,
|
|
56
|
-
list: [
|
|
57
|
-
{label: '默认', value: 'D'},
|
|
58
|
-
{label: '自定义', value: 'C'},
|
|
59
|
-
]
|
|
60
|
-
},
|
|
61
|
-
{ele: 'group_start'},
|
|
62
|
-
{
|
|
63
|
-
label: '',
|
|
64
|
-
ele: 'xd-color',
|
|
65
|
-
valueKey: 'bgColor',
|
|
66
|
-
value: dataVal({data, key:'bgColor', dValue:'rgba(0,0,0,0)', gValue}),
|
|
67
|
-
hidden: !statusShow({data, key: 'bgColorStatus', fields:['bgColor'], gValue}),
|
|
68
|
-
placeholder: '请选择背景色',
|
|
69
|
-
classNmae: 'input80',
|
|
70
|
-
groupKey: 'style',
|
|
71
|
-
labelInline: true,
|
|
72
|
-
setting: {
|
|
73
|
-
showAlpha: true
|
|
74
|
-
}
|
|
75
|
-
},
|
|
76
|
-
{ele: 'group_end'},
|
|
77
|
-
{
|
|
78
|
-
label: '内容区边距',
|
|
79
|
-
ele: 'xd-radio',
|
|
80
|
-
groupKey: 'style',
|
|
81
|
-
valueKey: 'paddingStatus',
|
|
82
|
-
value: statusDataVal({data, key:'paddingStatus', fields:['padding'],gValue}),
|
|
83
|
-
labelInline:true,
|
|
84
|
-
list: [
|
|
85
|
-
{label: '默认', value: 'D'},
|
|
86
|
-
{label: '自定义', value: 'C'},
|
|
87
|
-
]
|
|
88
|
-
},
|
|
89
|
-
{ele: 'group_start'},
|
|
90
|
-
{
|
|
91
|
-
label: '',
|
|
92
|
-
ele: 'xd-margin-padding',
|
|
93
|
-
valueKey: 'padding',
|
|
94
|
-
value: dataVal({
|
|
95
|
-
data,
|
|
96
|
-
key:'padding',
|
|
97
|
-
dValue:0,
|
|
98
|
-
gValue,
|
|
99
|
-
isPM: true,
|
|
100
|
-
}),
|
|
101
|
-
hidden: !statusShow({data, key: 'paddingStatus', fields:['padding'], gValue}),
|
|
102
|
-
groupKey: 'style',
|
|
103
|
-
setting: {
|
|
104
|
-
type: 'padding',
|
|
105
|
-
},
|
|
106
|
-
placeholder: '请填充设置',
|
|
107
|
-
},
|
|
108
|
-
{ele: 'group_end'},
|
|
109
|
-
{
|
|
110
|
-
label: '内容区圆角',
|
|
111
|
-
ele: 'xd-radio',
|
|
112
|
-
groupKey: 'style',
|
|
113
|
-
valueKey: 'radiusStatus',
|
|
114
|
-
value: statusDataVal({data, key:'radiusStatus',cValue:'N',dValue:'N', fields:['radius'],gValue}),
|
|
115
|
-
labelInline:true,
|
|
116
|
-
list: [
|
|
117
|
-
{label: '默认', value: 'D'},
|
|
118
|
-
{label: '无圆角', value: 'N'},
|
|
119
|
-
{label: '自定义', value: 'C'},
|
|
120
|
-
]
|
|
121
|
-
},
|
|
122
|
-
{ele: 'group_start'},
|
|
123
|
-
{
|
|
124
|
-
label: '',
|
|
125
|
-
ele: 'xd-site-select-list',
|
|
126
|
-
labelInline: true,
|
|
127
|
-
valueKey: 'radius',
|
|
128
|
-
value: dataVal({data, key:'radius', dValue:'10', gValue}), //默认0
|
|
129
|
-
hidden: !statusShow({data, key: 'radiusStatus', fields:['radius'], gValue}),
|
|
130
|
-
placeholder: '请选择圆角',
|
|
131
|
-
multiple: false,
|
|
132
|
-
className: 'input80',
|
|
133
|
-
groupKey:'style',
|
|
134
|
-
handleCustom({action, data}) {
|
|
135
|
-
XdBus.getParentApi('getOptionsSettingList')({
|
|
136
|
-
setting_id: 'edtix_style_radius',
|
|
137
|
-
key: Date.now()
|
|
138
|
-
})
|
|
139
|
-
.then(res => {
|
|
140
|
-
res.list = res.list.filter(item=>{
|
|
141
|
-
return item.label !== '无';
|
|
142
|
-
});
|
|
143
|
-
data.cb(res.list)
|
|
144
|
-
})
|
|
145
|
-
.catch(error => {
|
|
146
|
-
console.error(error);
|
|
147
|
-
});
|
|
148
|
-
},
|
|
149
|
-
},
|
|
150
|
-
{ele: 'group_end'},
|
|
151
|
-
{
|
|
152
|
-
label: '版本号:',
|
|
153
|
-
ele: 'el-input',
|
|
154
|
-
type: 'text',
|
|
155
|
-
groupKey: 'content',
|
|
156
|
-
valueKey: 'version',
|
|
157
|
-
value: 'v2.0',
|
|
158
|
-
hidden: true,
|
|
159
|
-
},
|
|
160
|
-
{
|
|
161
|
-
label: '过滤引用模版字段:',
|
|
162
|
-
ele: 'el-input',
|
|
163
|
-
type: 'text',
|
|
164
|
-
groupKey: 'content',
|
|
165
|
-
valueKey: 'refFilterKey',
|
|
166
|
-
value: '[]',
|
|
167
|
-
hidden: true,
|
|
168
|
-
},
|
|
169
|
-
|
|
170
|
-
]
|
|
171
|
-
}
|
|
172
|
-
|