n20-common-lib 2.16.7 → 2.16.9

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": "n20-common-lib",
3
- "version": "2.16.7",
3
+ "version": "2.16.9",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "serve": "vue-cli-service serve",
@@ -935,48 +935,3 @@ export default {
935
935
  }
936
936
  }
937
937
  </script>
938
- <style lang="scss">
939
- .file-upload-table-v3 {
940
- .title {
941
- font-size: 16px;
942
- font-style: normal;
943
- font-weight: 500;
944
- line-height: normal;
945
- span {
946
- color: #666666;
947
- font-family: 'PingFang SC';
948
- font-size: 14px;
949
- font-style: normal;
950
- font-weight: 400;
951
- line-height: normal;
952
- }
953
- }
954
- .title::before {
955
- content: '';
956
- display: inline-block;
957
- width: 4px;
958
- height: 16px;
959
- background: #4471fe;
960
- margin-right: 4px;
961
- position: relative;
962
- top: 2px;
963
- }
964
- .file-list {
965
- margin-top: 16px;
966
- .file-item {
967
- margin-bottom: 16px;
968
- .type-title {
969
- display: flex;
970
- width: calc(100% - 18px);
971
- height: 28px;
972
- padding: 9px;
973
- justify-content: space-between;
974
- align-items: center;
975
- flex-shrink: 0;
976
- border-radius: 4px;
977
- background: #48d2a029;
978
- }
979
- }
980
- }
981
- }
982
- </style>
@@ -171,7 +171,7 @@ function getUserCert(uno) {
171
171
  * @param {*} cspName
172
172
  * @returns
173
173
  */
174
- export function updateCert(cspName) {
174
+ export function updateCert(cspName, onSuccess) {
175
175
  let oldContainer = ''
176
176
  // 设置提供者 'ArgusKey CSP For BEHFC v1.0'
177
177
  IWSA_rsa_csp_setProvider(cspName)
@@ -214,6 +214,9 @@ export function updateCert(cspName) {
214
214
  IWSA_rsa_csp_deleteContainer(oldContainer)
215
215
  }
216
216
  Message.success('证书导入成功')
217
+ if (typeof onSuccess === 'function') {
218
+ onSuccess()
219
+ }
217
220
  } else {
218
221
  IWSA_rsa_csp_deleteContainer(res[1])
219
222
  Message.error('证书导入失败,请联系管理员,错误码为' + code)
@@ -177,5 +177,16 @@ function verifyDn(dnList, dn) {
177
177
  Message.error(`证书Dn不匹配:${dnList}里面无法匹配===>${dn}`)
178
178
  return index
179
179
  }
180
+ if (index !== -1) {
181
+ // GMT时间字符串
182
+ const gmtTimeString = dnList[index].validEnd?.replace(/GMT$/, ' GMT')
183
+ // 创建Date对象
184
+ if (gmtTimeString) {
185
+ const gmtTime = new Date(gmtTimeString)
186
+ // 转换为CST(中国标准时间)
187
+ const cstTime = gmtTime.toLocaleString('zh-CN', { timeZone: 'Asia/Shanghai' })
188
+ sessionStorage.setItem('certValidEnd', cstTime)
189
+ }
190
+ }
180
191
  return index
181
192
  }