Jelajahi Sumber

密码加密取消匿名

FinalYu 2 tahun lalu
induk
melakukan
0d5d8c9063
1 mengubah file dengan 6 tambahan dan 1 penghapusan
  1. 6 1
      chuanyi_client2/src/components/LeftMenu/index.vue

+ 6 - 1
chuanyi_client2/src/components/LeftMenu/index.vue

@@ -297,9 +297,14 @@ export default {
         if (valid) {
           // 参数封装
           let params = JSON.parse(JSON.stringify(this.connForm))
-          params.ipPassword = encrypt(this.connForm.ipPassword, getPubKey())
           params.dataSourceName = this.datasourceForm.datasourceName
           params.dataSourceDescribe = this.datasourceForm.desc
+          if (params.isAnonymous == 1) {
+            params.ipPassword = ''
+            params.ipUserName = ''
+          } else {
+            params.ipPassword = encrypt(this.connForm.ipPassword, getPubKey())
+          }
           if (this.chooseConnServer) {
             params.typeId = this.chooseConnServer.typeId
           } else if (this.chooseServerType) {