1
0
mirror of https://github.com/pocket-id/pocket-id.git synced 2026-03-24 06:40:06 +00:00

feat: allow LDAP users and groups to be deleted if LDAP gets disabled

This commit is contained in:
Elias Schneider
2025-02-03 08:58:20 +01:00
parent ecd74b794f
commit 9ab178712a
11 changed files with 34 additions and 22 deletions

View File

@@ -2,6 +2,7 @@
import CheckboxWithLabel from '$lib/components/checkbox-with-label.svelte';
import FormInput from '$lib/components/form-input.svelte';
import { Button } from '$lib/components/ui/button';
import appConfigStore from '$lib/stores/application-configuration-store';
import type { User, UserCreate } from '$lib/types/user.type';
import { createForm } from '$lib/utils/form-util';
import { z } from 'zod';
@@ -15,7 +16,7 @@
} = $props();
let isLoading = $state(false);
let inputDisabled = $derived(!!existingUser?.ldapId);
let inputDisabled = $derived(!!existingUser?.ldapId && $appConfigStore.ldapEnabled);
const user = {
firstName: existingUser?.firstName || '',