mhsanaei 9 месяцев назад
Родитель
Сommit
713285457f
2 измененных файлов с 1 добавлено и 14 удалено
  1. 0 1
      web/assets/js/model/outbound.js
  2. 1 13
      web/html/xui/form/outbound.html

+ 0 - 1
web/assets/js/model/outbound.js

@@ -1053,7 +1053,6 @@ Outbound.WireguardSettings = class extends CommonClass {
         super();
         this.mtu = mtu;
         this.secretKey = secretKey;
-        this.pubKey = secretKey.length>0 ? Wireguard.generateKeypair(secretKey).publicKey : '';
         this.address = address instanceof Array ? address.join(',') : address;
         this.workers = workers;
         this.domainStrategy = domainStrategy;

+ 1 - 13
web/html/xui/form/outbound.html

@@ -72,21 +72,9 @@
           </template>
           <a-input v-model.trim="outbound.settings.address"></a-input>
         </a-form-item>
-        <a-form-item>
-          <template slot="label">
-            <a-tooltip>
-              <template slot="title">
-                <span>{{ i18n "reset" }}</span>
-              </template>
-              {{ i18n "pages.xray.wireguard.secretKey" }}
-              <a-icon type="sync" @click="[outbound.settings.pubKey, outbound.settings.secretKey] = Object.values(Wireguard.generateKeypair())"></a-icon>
-            </a-tooltip>
-          </template>
+        <a-form-item label='{{ i18n "pages.xray.wireguard.secretKey" }}'>
           <a-input v-model.trim="outbound.settings.secretKey"></a-input>
         </a-form-item>
-        <a-form-item label='{{ i18n "pages.xray.wireguard.publicKey" }}'>
-          <a-input disabled v-model="outbound.settings.pubKey"></a-input>
-        </a-form-item>
         <a-form-item label='{{ i18n "pages.xray.wireguard.domainStrategy" }}'>
           <a-select v-model="outbound.settings.domainStrategy" :dropdown-class-name="themeSwitcher.currentTheme">
             <a-select-option v-for="wds in ['', ...WireguardDomainStrategy]" :value="wds">[[ wds ]]</a-select-option>