n20-common-lib 2.9.0 → 2.9.2
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 +2 -2
- package/src/assets/css/layout-content.scss +4 -0
- package/src/assets/css/normalize.scss +4 -1
- package/src/components/Layout/indexN.vue +2 -2
- package/src/plugins/Sign/Itrus/index.js +15 -18
- package/src/utils/axios.js +4 -4
- package/style/index.css +1 -1
- package/theme/blue.css +1 -1
- package/theme/cctcRed.css +1 -1
- package/theme/green.css +1 -1
- package/theme/lightBlue.css +1 -1
- package/theme/orange.css +1 -1
- package/theme/purple.css +1 -1
- package/theme/red.css +1 -1
- package/theme/yellow.css +1 -1
package/package.json
CHANGED
|
@@ -1,8 +1,12 @@
|
|
|
1
1
|
.content-box {
|
|
2
2
|
box-sizing: border-box;
|
|
3
|
+
-webkit-box-sizing: border-box; /* Safari/Chrome */
|
|
4
|
+
-moz-box-sizing: border-box; /* Firefox */
|
|
3
5
|
margin: 0 8px 8px 8px;
|
|
4
6
|
padding: 8px;
|
|
5
7
|
border-radius: 0 0 6px 6px;
|
|
8
|
+
-webkit-border-radius: 0 0 6px 6px; /* Safari/Chrome */
|
|
9
|
+
-moz-border-radius: 0 0 6px 6px; /* Firefox */
|
|
6
10
|
height: var(--client-height);
|
|
7
11
|
background: $--color-white;
|
|
8
12
|
overflow: auto;
|
|
@@ -287,6 +287,7 @@ iframe {
|
|
|
287
287
|
.block {
|
|
288
288
|
display: block;
|
|
289
289
|
}
|
|
290
|
+
|
|
290
291
|
.inline_block {
|
|
291
292
|
display: inline-block;
|
|
292
293
|
}
|
|
@@ -669,7 +670,9 @@ $list: 45, 60, 80, 100, 110, 120, 130, 140, 150, 160, 170, 180, 190, 200, 210, 2
|
|
|
669
670
|
}
|
|
670
671
|
}
|
|
671
672
|
|
|
673
|
+
/* height: 100%; 速龙浏览器下子元素无法继承父元素的高速度 */
|
|
672
674
|
.n20-page-content {
|
|
675
|
+
height: 100%;
|
|
673
676
|
overflow-y: auto;
|
|
674
677
|
overflow-x: hidden;
|
|
675
678
|
}
|
|
@@ -861,4 +864,4 @@ $list: 45, 60, 80, 100, 110, 120, 130, 140, 150, 160, 170, 180, 190, 200, 210, 2
|
|
|
861
864
|
transform: translateY(0);
|
|
862
865
|
animation-timing-function: cubic-bezier(0, 0, 0.2, 1);
|
|
863
866
|
}
|
|
864
|
-
}
|
|
867
|
+
}
|
|
@@ -48,14 +48,13 @@ const routerBaseRe = new RegExp('^' + routerBase)
|
|
|
48
48
|
|
|
49
49
|
import { addListener, removeListener } from 'resize-detector'
|
|
50
50
|
|
|
51
|
-
import
|
|
51
|
+
import auth from '../../utils/auth'
|
|
52
52
|
import forEachs from '../../utils/forEachs'
|
|
53
53
|
import { setRela } from '../../utils/relaNo'
|
|
54
54
|
import asideNav from './AsideNav/index.vue'
|
|
55
55
|
import headerWrap from './HeaderWrap/indexN.vue'
|
|
56
56
|
import menuDrawer from './HeaderWrap/menuDrawer.vue'
|
|
57
57
|
import tabsNav from './TabsNav/index.vue'
|
|
58
|
-
import auth from '../../utils/auth'
|
|
59
58
|
|
|
60
59
|
export default {
|
|
61
60
|
name: 'Layout',
|
|
@@ -203,6 +202,7 @@ export default {
|
|
|
203
202
|
},
|
|
204
203
|
methods: {
|
|
205
204
|
async getCertify() {
|
|
205
|
+
let { getCert } = await import('../../plugins/Sign')
|
|
206
206
|
const cert = await getCert()
|
|
207
207
|
if (cert === -1 || ['dnListEmpty', 'dnIsEmpty', 'Empty'].includes(cert)) {
|
|
208
208
|
this.$message.error($lc(`证书验证失败,请重新登录`))
|
|
@@ -2501,23 +2501,21 @@ const config = {
|
|
|
2501
2501
|
disableExeUrl: true
|
|
2502
2502
|
}
|
|
2503
2503
|
|
|
2504
|
-
|
|
2505
|
-
|
|
2506
|
-
|
|
2507
|
-
|
|
2508
|
-
|
|
2509
|
-
|
|
2510
|
-
|
|
2511
|
-
|
|
2512
|
-
|
|
2513
|
-
|
|
2514
|
-
|
|
2515
|
-
})
|
|
2516
|
-
}
|
|
2517
|
-
|
|
2518
|
-
initCertList()
|
|
2504
|
+
let url = window.NetSignName || `/portal/天诚安信数字证书助手-3.7.7.0.exe`
|
|
2505
|
+
let name = window.NetSignDownloadName || '天诚安信数字证书助手'
|
|
2506
|
+
try {
|
|
2507
|
+
TCA.config(config)
|
|
2508
|
+
} catch (error) {
|
|
2509
|
+
Notification({
|
|
2510
|
+
title: '提示',
|
|
2511
|
+
dangerouslyUseHTMLString: true,
|
|
2512
|
+
message: `<div>检测到您的电脑中没有安装签名助手,为了不影响使用请使用管理员权限<a class="color-primary" href="${url}" download>下载安装</a>${name}</div>`,
|
|
2513
|
+
duration: 5000
|
|
2514
|
+
})
|
|
2519
2515
|
}
|
|
2520
2516
|
|
|
2517
|
+
initCertList()
|
|
2518
|
+
|
|
2521
2519
|
function getDN() {
|
|
2522
2520
|
let dn
|
|
2523
2521
|
let userInfo = JSON.parse(sessionStorage.getItem('userInfo'))
|
|
@@ -2528,7 +2526,6 @@ function getDN() {
|
|
|
2528
2526
|
}
|
|
2529
2527
|
|
|
2530
2528
|
export function getCert(dn) {
|
|
2531
|
-
init()
|
|
2532
2529
|
if (dn === undefined) {
|
|
2533
2530
|
dn = getDN()
|
|
2534
2531
|
}
|
|
@@ -2563,7 +2560,7 @@ export function getCert(dn) {
|
|
|
2563
2560
|
|
|
2564
2561
|
// 签名方法
|
|
2565
2562
|
export function getSign(plain, dn) {
|
|
2566
|
-
|
|
2563
|
+
let plainText = undefined
|
|
2567
2564
|
if (typeof plain === 'object') {
|
|
2568
2565
|
plainText = JSON.stringify(plain)
|
|
2569
2566
|
} else {
|
|
@@ -2599,7 +2596,7 @@ export function getSign(plain, dn) {
|
|
|
2599
2596
|
sginCert.clearPinCache()
|
|
2600
2597
|
}
|
|
2601
2598
|
return sginCert.signMessage(
|
|
2602
|
-
|
|
2599
|
+
plainText,
|
|
2603
2600
|
process.env.VUE_APP_NetSign_ARG_PLAIN ?? window.VUE_APP_NetSign_ARG_PLAIN ?? false
|
|
2604
2601
|
)
|
|
2605
2602
|
} else {
|
package/src/utils/axios.js
CHANGED
|
@@ -93,7 +93,7 @@ axios.interceptors.request.use((opt) => {
|
|
|
93
93
|
})
|
|
94
94
|
|
|
95
95
|
function errorFn(status, msg, noMsg, isErr, res) {
|
|
96
|
-
if (status === 401
|
|
96
|
+
if (status === 401) {
|
|
97
97
|
noMsg || showMsg($lc('超时未操作,请重新登录!'))
|
|
98
98
|
setTimeout(() => {
|
|
99
99
|
if (navigator.userAgent.includes('NSTC-WebEntry')) {
|
|
@@ -104,11 +104,11 @@ function errorFn(status, msg, noMsg, isErr, res) {
|
|
|
104
104
|
auth.removeToken()
|
|
105
105
|
}
|
|
106
106
|
}, 1000)
|
|
107
|
-
} else if (status === 400
|
|
107
|
+
} else if (status === 400 ) {
|
|
108
108
|
noMsg || showMsg($lc('400,参数错误!'))
|
|
109
|
-
} else if (status === 404
|
|
109
|
+
} else if (status === 404 ) {
|
|
110
110
|
noMsg || showMsg($lc('404,网络连接失败!'))
|
|
111
|
-
} else if (status === 500
|
|
111
|
+
} else if (status === 500) {
|
|
112
112
|
noMsg || showMsg($lc('500,服务器链接失败!'))
|
|
113
113
|
} else if (status === 'ECONNABORTED' && msg.includes('timeout')) {
|
|
114
114
|
noMsg || showMsg($lc('请求超时'))
|