eoss-ui 0.4.39 → 0.4.41
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/button-group.js +40 -13
- package/lib/button.js +35 -8
- package/lib/checkbox-group.js +35 -8
- package/lib/data-table-form.js +35 -8
- package/lib/data-table.js +97 -34
- package/lib/date-picker.js +35 -8
- package/lib/dialog.js +52 -39
- package/lib/editor.js +415 -887
- package/lib/eoss-ui.common.js +11166 -10552
- package/lib/flow-group.js +37 -26
- package/lib/flow-list.js +35 -8
- package/lib/flow.js +163 -54
- package/lib/form.js +10081 -9075
- package/lib/handle-user.js +35 -8
- package/lib/handler.js +35 -8
- package/lib/icons.js +2 -2
- package/lib/index.js +1 -1
- package/lib/input-number.js +35 -8
- package/lib/input.js +35 -8
- package/lib/login.js +35 -8
- package/lib/main.js +35 -8
- package/lib/mainComp.js +35 -8
- package/lib/nav.js +35 -8
- package/lib/page.js +35 -8
- package/lib/player.js +37 -10
- package/lib/qr-code.js +35 -8
- package/lib/radio-group.js +35 -8
- package/lib/select-ganged.js +35 -8
- package/lib/select.js +35 -8
- package/lib/selector-panel.js +43 -16
- package/lib/selector.js +40 -13
- package/lib/sizer.js +35 -8
- package/lib/steps.js +35 -8
- package/lib/switch.js +35 -8
- package/lib/table-form.js +48 -13
- package/lib/tabs.js +40 -36
- package/lib/theme-chalk/editor.css +1 -1
- package/lib/theme-chalk/index.css +1 -1
- package/lib/tips.js +35 -8
- package/lib/tree-group.js +39 -21
- package/lib/tree.js +35 -8
- package/lib/upload.js +95 -52
- package/lib/utils/util.js +35 -8
- package/lib/wujie.js +35 -8
- package/lib/wxlogin.js +35 -8
- package/package.json +1 -1
- package/packages/button-group/src/main.vue +3 -3
- package/packages/data-table/src/column.vue +6 -0
- package/packages/data-table/src/main.vue +12 -0
- package/packages/dialog/src/main.vue +3 -11
- package/packages/editor/src/editor.vue +20 -0
- package/packages/editor/src/minx.js +129 -19
- package/packages/editor/src/toolbar.vue +93 -324
- package/packages/flow/src/component/CommonOpinions.vue +29 -11
- package/packages/flow/src/component/CustomPreset.vue +5 -1
- package/packages/flow/src/component/Preset.vue +5 -1
- package/packages/flow/src/main.vue +21 -1
- package/packages/flow/src/processForm.vue +15 -8
- package/packages/flow/src/selectUser.vue +9 -2
- package/packages/flow-group/src/main.vue +0 -8
- package/packages/form/src/main.vue +1519 -1462
- package/packages/form/src/table.vue +8 -0
- package/packages/selector/src/main.vue +1 -1
- package/packages/selector-panel/src/main.vue +4 -4
- package/packages/tabs/src/main.vue +1 -10
- package/packages/theme-chalk/lib/editor.css +1 -1
- package/packages/theme-chalk/lib/index.css +1 -1
- package/packages/theme-chalk/src/editor.scss +23 -0
- package/packages/tree-group/src/main.vue +0 -2
- package/packages/upload/src/main.vue +31 -23
- package/src/index.js +1 -1
- package/src/utils/util.js +41 -8
|
@@ -5,10 +5,30 @@
|
|
|
5
5
|
position: relative;
|
|
6
6
|
display: flex;
|
|
7
7
|
padding: 0 4px;
|
|
8
|
+
flex-wrap: wrap;
|
|
8
9
|
border-bottom: $--border-base;
|
|
10
|
+
.es-editor-toolbar-item-box {
|
|
11
|
+
height: 40px;
|
|
12
|
+
display: inline-flex;
|
|
13
|
+
& + .es-editor-toolbar-item-box {
|
|
14
|
+
.es-editor-toolbar-item {
|
|
15
|
+
&:first-child {
|
|
16
|
+
border-left: $--border-base;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
}
|
|
9
21
|
.es-editor-toolbar-item {
|
|
10
22
|
height: 40px;
|
|
11
23
|
padding: 4px;
|
|
24
|
+
&.es-last {
|
|
25
|
+
border-right: $--border-base;
|
|
26
|
+
}
|
|
27
|
+
.es-icon-text {
|
|
28
|
+
& + .el-icon--right {
|
|
29
|
+
width: auto;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
12
32
|
}
|
|
13
33
|
.el-button--default {
|
|
14
34
|
border: 0;
|
|
@@ -17,6 +37,9 @@
|
|
|
17
37
|
color: #333;
|
|
18
38
|
background-color: #f1f1f1;
|
|
19
39
|
}
|
|
40
|
+
&.es-icon-right {
|
|
41
|
+
padding-right: 3px;
|
|
42
|
+
}
|
|
20
43
|
}
|
|
21
44
|
}
|
|
22
45
|
.es-editor-main {
|
|
@@ -67,7 +67,6 @@
|
|
|
67
67
|
<es-form
|
|
68
68
|
v-if="form"
|
|
69
69
|
v-bind="form"
|
|
70
|
-
:zoom="zoom"
|
|
71
70
|
:ref="form.ref ? form.ref : 'esForm'"
|
|
72
71
|
v-on="{ ...$listeners, ...form.events }"
|
|
73
72
|
>
|
|
@@ -84,7 +83,6 @@
|
|
|
84
83
|
size="mini"
|
|
85
84
|
v-bind="{ close: true, ...table }"
|
|
86
85
|
:param="param"
|
|
87
|
-
:zoom="zoom"
|
|
88
86
|
:ref="table.ref ? table.ref : 'esDataTable'"
|
|
89
87
|
v-on="{ ...$listeners, ...table.events }"
|
|
90
88
|
>
|
|
@@ -81,27 +81,31 @@
|
|
|
81
81
|
></i>
|
|
82
82
|
</template>
|
|
83
83
|
<template v-else>
|
|
84
|
-
<
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
84
|
+
<template v-if="!isDisabled">
|
|
85
|
+
<i
|
|
86
|
+
class="el-icon-plus es-uploader-icon"
|
|
87
|
+
v-if="selectType === 'icon-plus'"
|
|
88
|
+
></i>
|
|
89
|
+
<el-button
|
|
90
|
+
v-else
|
|
91
|
+
class="es-upload-button"
|
|
92
|
+
:class="icon"
|
|
93
|
+
:type="selectType"
|
|
94
|
+
:size="btnSize"
|
|
95
|
+
>{{
|
|
96
|
+
text ? text : autoUpload ? '点击上传' : '选择文件'
|
|
97
|
+
}}</el-button
|
|
98
|
+
>
|
|
99
|
+
<el-button
|
|
100
|
+
class="es-upload-button"
|
|
101
|
+
v-if="!autoUpload"
|
|
102
|
+
:type="uploadType"
|
|
103
|
+
:size="btnSize"
|
|
104
|
+
@click.stop="handleUpload"
|
|
105
|
+
>
|
|
106
|
+
上传文件
|
|
107
|
+
</el-button>
|
|
108
|
+
</template>
|
|
105
109
|
<el-button
|
|
106
110
|
v-if="showFileList && isDownloads"
|
|
107
111
|
slot="handle"
|
|
@@ -440,10 +444,12 @@ export default {
|
|
|
440
444
|
};
|
|
441
445
|
},
|
|
442
446
|
isRequiredOwnId() {
|
|
447
|
+
if (this.requiredOwnId !== undefined) {
|
|
448
|
+
return this.requiredOwnId;
|
|
449
|
+
}
|
|
443
450
|
if (!this.fileList || !this.fileList.length) {
|
|
444
451
|
return true;
|
|
445
452
|
}
|
|
446
|
-
return this.requiredOwnId;
|
|
447
453
|
},
|
|
448
454
|
show() {
|
|
449
455
|
if ((this.photo && typeof this.photo === 'string') || this.value) {
|
|
@@ -1062,7 +1068,9 @@ export default {
|
|
|
1062
1068
|
this.$message.success(response.msg);
|
|
1063
1069
|
}
|
|
1064
1070
|
}
|
|
1065
|
-
let se =
|
|
1071
|
+
let se =
|
|
1072
|
+
this.filesTotalSize +
|
|
1073
|
+
(this.resultFile ? Math.ceil((file.size / 1024) * 100) / 100 : 0);
|
|
1066
1074
|
this.filesTotalSize = se;
|
|
1067
1075
|
this.onSuccess && this.onSuccess(response, file, fileList);
|
|
1068
1076
|
this.$emit('success', response, file, fileList);
|
package/src/index.js
CHANGED
package/src/utils/util.js
CHANGED
|
@@ -1364,7 +1364,7 @@ const isFunction = function (obj) {
|
|
|
1364
1364
|
};
|
|
1365
1365
|
|
|
1366
1366
|
/**
|
|
1367
|
-
*
|
|
1367
|
+
* isLogined
|
|
1368
1368
|
* @desc:是否登录(用于路由守卫中)
|
|
1369
1369
|
* @author huangbo
|
|
1370
1370
|
* @date 2022年5月7日
|
|
@@ -1377,7 +1377,7 @@ const isFunction = function (obj) {
|
|
|
1377
1377
|
* @param {sting} [loginPage] - 第三方登录页面地址
|
|
1378
1378
|
* @param {boolean} [redirect] - 是否重定向(用于新脚手架)
|
|
1379
1379
|
**/
|
|
1380
|
-
const
|
|
1380
|
+
const isLogined = function ({
|
|
1381
1381
|
to,
|
|
1382
1382
|
from,
|
|
1383
1383
|
next,
|
|
@@ -1423,16 +1423,17 @@ const isLogged = function ({
|
|
|
1423
1423
|
data: to.query
|
|
1424
1424
|
}).then(res => {
|
|
1425
1425
|
if (res.rCode === 0) {
|
|
1426
|
-
|
|
1426
|
+
let { results } = res;
|
|
1427
|
+
switch (results.statusCode) {
|
|
1427
1428
|
case 0:
|
|
1428
1429
|
const storage = getStorage('storage');
|
|
1429
1430
|
setStorage({
|
|
1430
1431
|
type: storage,
|
|
1431
1432
|
key: {
|
|
1432
|
-
ssId:
|
|
1433
|
-
token:
|
|
1434
|
-
Authorization:
|
|
1435
|
-
deviceUnique:
|
|
1433
|
+
ssId: results.ssId,
|
|
1434
|
+
token: results.token,
|
|
1435
|
+
Authorization: results.token,
|
|
1436
|
+
deviceUnique: results.deviceUnique
|
|
1436
1437
|
}
|
|
1437
1438
|
});
|
|
1438
1439
|
next();
|
|
@@ -1442,7 +1443,7 @@ const isLogged = function ({
|
|
|
1442
1443
|
case 2:
|
|
1443
1444
|
break;
|
|
1444
1445
|
case 3:
|
|
1445
|
-
const href =
|
|
1446
|
+
const href = results.authorizeUrl.replace(
|
|
1446
1447
|
'{redirectUri}',
|
|
1447
1448
|
encodeURIComponent(url)
|
|
1448
1449
|
);
|
|
@@ -1469,6 +1470,34 @@ const isLogged = function ({
|
|
|
1469
1470
|
}
|
|
1470
1471
|
}
|
|
1471
1472
|
break;
|
|
1473
|
+
case 4:
|
|
1474
|
+
this.$alert(
|
|
1475
|
+
results.msg ? results.msg : '账号未绑定,账号密码登录后自动绑定!',
|
|
1476
|
+
'提示',
|
|
1477
|
+
{
|
|
1478
|
+
confirmButtonText: '确定',
|
|
1479
|
+
type: 'error'
|
|
1480
|
+
}
|
|
1481
|
+
)
|
|
1482
|
+
.then(() => {
|
|
1483
|
+
sessionStorage.setItem(
|
|
1484
|
+
'extUserBindHandleId',
|
|
1485
|
+
results.extUserBindHandleId
|
|
1486
|
+
);
|
|
1487
|
+
window.location.href = delUrlParam({ key: 'code' });
|
|
1488
|
+
if (loginPage) {
|
|
1489
|
+
win.top.location.replace(loginPage);
|
|
1490
|
+
} else if (document.referrer) {
|
|
1491
|
+
win.top.location.replace(document.referrer);
|
|
1492
|
+
} else if (win.top.location.href.indexOf('main.html') > -1) {
|
|
1493
|
+
win.top.location.href = './login.html';
|
|
1494
|
+
} else {
|
|
1495
|
+
next('/login');
|
|
1496
|
+
}
|
|
1497
|
+
})
|
|
1498
|
+
.catch((e) => {});
|
|
1499
|
+
break;
|
|
1500
|
+
default:
|
|
1472
1501
|
}
|
|
1473
1502
|
} else {
|
|
1474
1503
|
if (token) {
|
|
@@ -1504,6 +1533,9 @@ const isLogged = function ({
|
|
|
1504
1533
|
}
|
|
1505
1534
|
}
|
|
1506
1535
|
};
|
|
1536
|
+
const isLogged = function (res) {
|
|
1537
|
+
isLogined(res);
|
|
1538
|
+
};
|
|
1507
1539
|
|
|
1508
1540
|
/**
|
|
1509
1541
|
* isObject
|
|
@@ -2137,6 +2169,7 @@ export default {
|
|
|
2137
2169
|
indexOfObj,
|
|
2138
2170
|
isFunction,
|
|
2139
2171
|
isLogged,
|
|
2172
|
+
isLogined,
|
|
2140
2173
|
isObject,
|
|
2141
2174
|
jointUrl,
|
|
2142
2175
|
loadJs,
|