Browse Source

Add description of hooks for client config

pull/1714/head
yanghuanglin 5 months ago
parent
commit
0a8b44339f
  1. 24
      src/app/pages/clients/[id].vue
  2. 12
      src/i18n/locales/en.json

24
src/app/pages/clients/[id].vue

@ -72,18 +72,32 @@
/>
</FormGroup>
<FormGroup>
<FormHeading>{{ $t('form.hooks') }}</FormHeading>
<FormTextField id="PreUp" v-model="data.preUp" label="PreUp" />
<FormTextField id="PostUp" v-model="data.postUp" label="PostUp" />
<FormHeading :description="$t('client.hooksDescription')">
{{ $t('client.hooks') }}
</FormHeading>
<FormTextField
id="PreUp"
v-model="data.preUp"
:description="$t('client.hooksLeaveEmpty')"
:label="$t('client.PreUp')"
/>
<FormTextField
id="PostUp"
v-model="data.postUp"
:description="$t('client.hooksLeaveEmpty')"
:label="$t('client.PostUp')"
/>
<FormTextField
id="PreDown"
v-model="data.preDown"
label="PreDown"
:description="$t('client.hooksLeaveEmpty')"
:label="$t('client.PreDown')"
/>
<FormTextField
id="PostDown"
v-model="data.postDown"
label="PostDown"
:description="$t('client.hooksLeaveEmpty')"
:label="$t('client.PostDown')"
/>
</FormGroup>
<FormGroup>

12
src/i18n/locales/en.json

@ -98,7 +98,14 @@
"allowedIpsDesc": "Which IPs will be routed through the VPN",
"serverAllowedIpsDesc": "Which IPs the server will route to the client",
"mtuDesc": "Sets the maximum transmission unit (packet size) for the VPN tunnel",
"persistentKeepaliveDesc": "Sets the interval (in seconds) for keep-alive packets. 0 disables it"
"persistentKeepaliveDesc": "Sets the interval (in seconds) for keep-alive packets. 0 disables it",
"hooks": "Hooks",
"hooksDescription": "Hooks only works with wg-quick",
"hooksLeaveEmpty": "Only for wg-quick. Otherwise, please leave it empty",
"PreUp": "PreUp",
"PostUp": "PostUp",
"PreDown": "PreDown",
"PostDown": "PostDown"
},
"dialog": {
"change": "Change",
@ -118,8 +125,7 @@
"sectionGeneral": "General",
"sectionAdvanced": "Advanced",
"noItems": "No items",
"add": "Add",
"hooks": "Hooks"
"add": "Add"
},
"admin": {
"general": {

Loading…
Cancel
Save