bri-components 1.2.24 → 1.2.26
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/lib/bri-components.min.js +3 -3
- package/package.json +1 -1
- package/src/components/Error/Error403.vue +9 -1
- package/src/components/Error/Error404.vue +6 -0
- package/src/components/Error/Error500.vue +21 -4
- package/src/components/Error/errorBack.vue +3 -1
- package/src/components/controls/base/BriUpload/BriUpload.vue +15 -17
- package/src/components/form/DshDefaultSearch.vue +2 -2
- package/src/components/form/searchMixin.js +6 -4
- package/src/components/unit/DshFormUnit.vue +2 -2
- package/src/styles/components/form/DshForm.less +9 -6
- package/src/styles/components/unit/DshFormUnit.less +2 -2
package/package.json
CHANGED
|
@@ -4,7 +4,9 @@
|
|
|
4
4
|
<Card class="error-body-card">
|
|
5
5
|
<div class="error-body-title">
|
|
6
6
|
<span>4</span><!--
|
|
7
|
-
--><span class="span-403-0"
|
|
7
|
+
--><span class="span-403-0">
|
|
8
|
+
<Icon type="md-lock" />
|
|
9
|
+
</span><!--
|
|
8
10
|
--><span class="span-403-3">3</span>
|
|
9
11
|
</div>
|
|
10
12
|
<p class="error-body-message">很抱歉,您没有该页面的访问权限!</p>
|
|
@@ -25,6 +27,12 @@
|
|
|
25
27
|
components: {
|
|
26
28
|
errorBack
|
|
27
29
|
},
|
|
30
|
+
props: {},
|
|
31
|
+
data () {
|
|
32
|
+
return {};
|
|
33
|
+
},
|
|
34
|
+
computed: {},
|
|
35
|
+
created () {},
|
|
28
36
|
methods: {}
|
|
29
37
|
};
|
|
30
38
|
</script>
|
|
@@ -4,11 +4,15 @@
|
|
|
4
4
|
<Card class="error-body-card">
|
|
5
5
|
<div class="error-body-title">
|
|
6
6
|
<span>5</span><!--
|
|
7
|
-
--><span class="span-500-0"
|
|
8
|
-
|
|
7
|
+
--><span class="span-500-0">
|
|
8
|
+
<Icon type="logo-freebsd-devil" />
|
|
9
|
+
</span><!--
|
|
10
|
+
--><span class="span-500-0">
|
|
11
|
+
<Icon type="logo-freebsd-devil" />
|
|
12
|
+
</span>
|
|
9
13
|
</div>
|
|
10
|
-
<p class="error-body-message"
|
|
11
|
-
<p class="error-body-message">
|
|
14
|
+
<p class="error-body-message">{{ msg }}</p>
|
|
15
|
+
<p class="error-body-message">The server is wrong!</p>
|
|
12
16
|
|
|
13
17
|
<!-- 返回按钮组件 -->
|
|
14
18
|
<error-back></error-back>
|
|
@@ -25,6 +29,19 @@
|
|
|
25
29
|
components: {
|
|
26
30
|
errorBack
|
|
27
31
|
},
|
|
32
|
+
props: {},
|
|
33
|
+
data () {
|
|
34
|
+
return {};
|
|
35
|
+
},
|
|
36
|
+
computed: {
|
|
37
|
+
queryMsg () {
|
|
38
|
+
return this.$route.query.msg;
|
|
39
|
+
},
|
|
40
|
+
msg () {
|
|
41
|
+
return `${this.queryMsg ? `服务器错误:${this.queryMsg}` : "抱歉,服务器错误"}!`;
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
created () {},
|
|
28
45
|
methods: {}
|
|
29
46
|
};
|
|
30
47
|
</script>
|
|
@@ -118,21 +118,11 @@
|
|
|
118
118
|
BriUploadImage,
|
|
119
119
|
uploadList
|
|
120
120
|
},
|
|
121
|
-
props: {
|
|
122
|
-
type: {
|
|
123
|
-
type: String,
|
|
124
|
-
default: "drag"
|
|
125
|
-
},
|
|
126
|
-
maxSize: {
|
|
127
|
-
type: Number,
|
|
128
|
-
default: 1024
|
|
129
|
-
}
|
|
130
|
-
},
|
|
121
|
+
props: {},
|
|
131
122
|
data () {
|
|
132
123
|
return {
|
|
133
124
|
prefixCls: prefixCls,
|
|
134
125
|
dragOver: false,
|
|
135
|
-
tempIndex: 1,
|
|
136
126
|
|
|
137
127
|
operationMap: {
|
|
138
128
|
upload: {
|
|
@@ -150,6 +140,8 @@
|
|
|
150
140
|
_fileType: "file",
|
|
151
141
|
_showType: this.isFullRow && !this.isInTable ? "old" : "inline", // 宽度为100%、且不在级联表格或内部表格里的 显示老版
|
|
152
142
|
// _multiple: true,
|
|
143
|
+
_useType: "drag",
|
|
144
|
+
_maxSize: 1024 * 1024,
|
|
153
145
|
_format: [],
|
|
154
146
|
|
|
155
147
|
...this.propsObj,
|
|
@@ -164,9 +156,15 @@
|
|
|
164
156
|
showType () {
|
|
165
157
|
return this.selfPropsObj._showType;
|
|
166
158
|
},
|
|
159
|
+
useType () {
|
|
160
|
+
return this.selfPropsObj._useType;
|
|
161
|
+
},
|
|
167
162
|
format () {
|
|
168
163
|
return this.selfPropsObj._format;
|
|
169
164
|
},
|
|
165
|
+
maxSize () {
|
|
166
|
+
return this.selfPropsObj._maxSize;
|
|
167
|
+
},
|
|
170
168
|
|
|
171
169
|
// 限制文件格式
|
|
172
170
|
accept () {
|
|
@@ -177,9 +175,9 @@
|
|
|
177
175
|
classes () {
|
|
178
176
|
return {
|
|
179
177
|
[`${prefixCls}`]: true,
|
|
180
|
-
[`${prefixCls}-select`]: this.
|
|
181
|
-
[`${prefixCls}-drag`]: this.
|
|
182
|
-
[`${prefixCls}-dragOver`]: this.
|
|
178
|
+
[`${prefixCls}-select`]: this.useType === "select",
|
|
179
|
+
[`${prefixCls}-drag`]: this.useType === "drag",
|
|
180
|
+
[`${prefixCls}-dragOver`]: this.useType === "drag" && this.dragOver,
|
|
183
181
|
[`BriUpload-${this.showType}-wrapper`]: true
|
|
184
182
|
};
|
|
185
183
|
}
|
|
@@ -196,8 +194,8 @@
|
|
|
196
194
|
if (data.res === 0) {
|
|
197
195
|
if (this.multipleMode) {
|
|
198
196
|
this.curValList = [
|
|
199
|
-
|
|
200
|
-
|
|
197
|
+
data.data,
|
|
198
|
+
...this.curValList
|
|
201
199
|
];
|
|
202
200
|
} else {
|
|
203
201
|
this.curValList = [
|
|
@@ -234,7 +232,7 @@
|
|
|
234
232
|
|
|
235
233
|
postFiles.forEach(fileItem => {
|
|
236
234
|
if (
|
|
237
|
-
!this.format.
|
|
235
|
+
(!this.format.length || this.format.some(item => item.toLocaleLowerCase() === fileItem.name.split(".").pop().toLocaleLowerCase())) &&
|
|
238
236
|
(fileItem.size <= this.maxSize * 1024)
|
|
239
237
|
) {
|
|
240
238
|
this.handlePost(fileItem);
|
|
@@ -165,9 +165,9 @@
|
|
|
165
165
|
getFormItem (formItem) {
|
|
166
166
|
return {
|
|
167
167
|
...this.formatFormItem(formItem),
|
|
168
|
+
|
|
168
169
|
_line: true,
|
|
169
|
-
|
|
170
|
-
_wrap: formItem._defaultSearchWrap,
|
|
170
|
+
_useColor: false,
|
|
171
171
|
|
|
172
172
|
...(
|
|
173
173
|
// date、daterange类型的(formItem._type基本不会为daterange)
|
|
@@ -111,6 +111,11 @@ export default {
|
|
|
111
111
|
getFormItem (formItem) {
|
|
112
112
|
return {
|
|
113
113
|
...this.formatFormItem(formItem),
|
|
114
|
+
|
|
115
|
+
_line: false,
|
|
116
|
+
_span: 24,
|
|
117
|
+
_useColor: true,
|
|
118
|
+
|
|
114
119
|
...(
|
|
115
120
|
["default", "rely"].includes(this.mode)
|
|
116
121
|
? (
|
|
@@ -121,10 +126,7 @@ export default {
|
|
|
121
126
|
: {}
|
|
122
127
|
)
|
|
123
128
|
: {}
|
|
124
|
-
)
|
|
125
|
-
_line: false,
|
|
126
|
-
_span: 24,
|
|
127
|
-
_useColor: true
|
|
129
|
+
)
|
|
128
130
|
};
|
|
129
131
|
},
|
|
130
132
|
// 格式化表单配置,适合需要
|
|
@@ -117,10 +117,10 @@
|
|
|
117
117
|
return [];
|
|
118
118
|
}
|
|
119
119
|
},
|
|
120
|
-
// 实际最精确值是68px(label:30px, control:32px, 上下padding各:
|
|
120
|
+
// 实际最精确值是68px(label:30px, control:32px, 上下padding各: 2px 8px,因为ivu-form-item-content里line-height: 32px导致有问题,故先74px
|
|
121
121
|
height: {
|
|
122
122
|
type: [String, Number],
|
|
123
|
-
default: "
|
|
123
|
+
default: "74"
|
|
124
124
|
},
|
|
125
125
|
rowStyle: {
|
|
126
126
|
type: Object,
|
|
@@ -1,15 +1,18 @@
|
|
|
1
1
|
.DshForm {
|
|
2
|
+
padding-bottom: 5px;
|
|
3
|
+
|
|
2
4
|
&-item-FormItem {
|
|
3
5
|
margin-bottom: 0px!important;
|
|
4
6
|
}
|
|
5
7
|
|
|
6
8
|
.ivu-form-item-content {
|
|
7
9
|
line-height: normal;
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
10
|
+
|
|
11
|
+
.ivu-form-item-error-tip {
|
|
12
|
+
top: calc(100% - 8px);
|
|
13
|
+
left: 16px;
|
|
14
|
+
padding-top: 0px;
|
|
15
|
+
font-size: 12px;
|
|
16
|
+
}
|
|
14
17
|
}
|
|
15
18
|
}
|