do not attach v-if to the form since we cannot find it by ref anymore
This commit is contained in:
@@ -250,17 +250,16 @@ onMounted(async () => {
|
|||||||
>
|
>
|
||||||
<p class="has-error text-center" v-show="editError.generic">{{ editError.generic }}</p>
|
<p class="has-error text-center" v-show="editError.generic">{{ editError.generic }}</p>
|
||||||
|
|
||||||
<form ref="form" @submit.prevent="onSubmit()" autocomplete="off" @input="checkValidity()">
|
|
||||||
<fieldset :disabled="editBusy">
|
|
||||||
<input style="display: none" type="submit" :disabled="editBusy || !isFormValid" />
|
|
||||||
|
|
||||||
<FormGroup>
|
<FormGroup>
|
||||||
<label for="ldapProvider">{{ $t('users.externalLdap.provider') }} <sup><a href="https://docs.cloudron.io/user-directory/#external-directory" target="_blank"><i class="fa fa-question-circle"></i></a></sup></label>
|
<label for="ldapProvider">{{ $t('users.externalLdap.provider') }} <sup><a href="https://docs.cloudron.io/user-directory/#external-directory" target="_blank"><i class="fa fa-question-circle"></i></a></sup></label>
|
||||||
<SingleSelect id="ldapProvider" @select="onProviderChange" v-model="provider" :options="availableProviders" option-key="value" option-label="name" required/>
|
<SingleSelect id="ldapProvider" @select="onProviderChange" v-model="provider" :options="availableProviders" option-key="value" option-label="name"/>
|
||||||
<div class="warning-label" v-show="provider === 'noop' && config.provider !== 'noop'">{{ $t('users.externalLdap.disableWarning') }}</div>
|
<div class="warning-label" v-show="provider === 'noop' && config.provider !== 'noop'">{{ $t('users.externalLdap.disableWarning') }}</div>
|
||||||
</FormGroup>
|
</FormGroup>
|
||||||
|
|
||||||
<div v-if="provider !== 'noop'">
|
<form ref="form" @submit.prevent="onSubmit()" autocomplete="off" @input="checkValidity()">
|
||||||
|
<fieldset :disabled="editBusy" v-if="provider !== 'noop'">
|
||||||
|
<input style="display: none" type="submit" :disabled="editBusy || !isFormValid" />
|
||||||
|
|
||||||
<FormGroup :class="{ 'has-error': editError.url }">
|
<FormGroup :class="{ 'has-error': editError.url }">
|
||||||
<label class="control-label" for="configUrlInput">{{ $t('users.externalLdap.server') }}</label>
|
<label class="control-label" for="configUrlInput">{{ $t('users.externalLdap.server') }}</label>
|
||||||
<TextInput id="configUrlInput" v-model="url" placeholder="ldaps://example.com:636" required/>
|
<TextInput id="configUrlInput" v-model="url" placeholder="ldaps://example.com:636" required/>
|
||||||
@@ -312,7 +311,6 @@ onMounted(async () => {
|
|||||||
</FormGroup>
|
</FormGroup>
|
||||||
|
|
||||||
<Checkbox v-model="autoCreate" :label="$t('users.externalLdap.autocreateUsersOnLogin')" />
|
<Checkbox v-model="autoCreate" :label="$t('users.externalLdap.autocreateUsersOnLogin')" />
|
||||||
</div>
|
|
||||||
</fieldset>
|
</fieldset>
|
||||||
</form>
|
</form>
|
||||||
</Dialog>
|
</Dialog>
|
||||||
|
|||||||
@@ -173,8 +173,8 @@ async function onSubmit() {
|
|||||||
|
|
||||||
<div class="text-danger" v-if="formError">{{ formError }}</div>
|
<div class="text-danger" v-if="formError">{{ formError }}</div>
|
||||||
|
|
||||||
<form ref="form" @submit.prevent="onSubmit()" autocomplete="off" v-if="usesExternalServer(provider)" @input="checkValidity()">
|
<form ref="form" @submit.prevent="onSubmit()" autocomplete="off" @input="checkValidity()">
|
||||||
<fieldset :disabled="busy">
|
<fieldset :disabled="busy" v-if="usesExternalServer(provider)">
|
||||||
<input type="submit" style="display: none" :disabled="busy || !isFormValid"/>
|
<input type="submit" style="display: none" :disabled="busy || !isFormValid"/>
|
||||||
|
|
||||||
<FormGroup>
|
<FormGroup>
|
||||||
|
|||||||
Reference in New Issue
Block a user