Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions apps/user_ldap/src/components/SettingsTabs/LoginTab.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,20 @@
{{ t('user_ldap', 'When logging in, {instanceName} will find the user based on the following attributes:', { instanceName }) }}
</legend>

<NcCheckboxRadioSwitch
:model-value="ldapConfigProxy.ldapLoginFilterUsername === '1'"
:description="t('user_ldap', 'Allows login against the LDAP/AD username, which is either \'uid\' or \'sAMAccountName\' and will be detected.')"
@update:model-value="ldapConfigProxy.ldapLoginFilterUsername = $event ? '1' : '0'">
{{ t('user_ldap', 'LDAP/AD Username:') }}
</NcCheckboxRadioSwitch>

<NcCheckboxRadioSwitch
:model-value="ldapConfigProxy.ldapLoginFilterEmail === '1'"
:description="t('user_ldap', 'Allows login against an email attribute. \'mail\' and \'mailPrimaryAddress\' allowed.')"
@update:model-value="ldapConfigProxy.ldapLoginFilterEmail = $event ? '1' : '0'">
{{ t('user_ldap', 'LDAP/AD Email Address:') }}
</NcCheckboxRadioSwitch>

<div class="ldap-wizard__login__line ldap-wizard__login__login-attributes">
<NcSelect
v-model="ldapLoginFilterAttributes"
Expand Down
2 changes: 1 addition & 1 deletion apps/user_ldap/src/components/SettingsTabs/UsersTab.vue
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ async function reloadFilters() {

const response2 = await callWizard('getUserLoginFilter', props.configId)
// Not using ldapConfig to avoid triggering the save logic.
ldapConfigs.value[props.configId]!.ldapLoginFilter = (response2.changes?.ldap_userlogin_filter as string | undefined) ?? ''
ldapConfigs.value[props.configId]!.ldapLoginFilter = (response2.changes?.ldap_login_filter as string | undefined) ?? ''
}
}

Expand Down
Loading