Improve LDAP query builder with enhanced attribute display and type handling

Replit-Commit-Author: Agent
Replit-Commit-Session-Id: 705f2157-ef97-4fbd-89e4-8c7f2ecaea90
Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/7ed01c5f-a82d-405a-b728-b2e3d127c60c/afff49ca-ba32-4dcb-b9c2-39ee146e28cb.jpg
This commit is contained in:
alphaeusmote
2025-04-08 20:22:50 +00:00
parent 6ed03199b7
commit fb68574adb
6 changed files with 807 additions and 44 deletions
+36
View File
@@ -0,0 +1,36 @@
// LDAP query types
export enum LdapOperator {
// Logical operators
AND = "and",
OR = "or",
NOT = "not",
// Comparison operators
EQUALS = "equals",
NOT_EQUALS = "notEquals",
STARTS_WITH = "startsWith",
ENDS_WITH = "endsWith",
CONTAINS = "contains",
GREATER_THAN = "greaterThan",
LESS_THAN = "lessThan",
PRESENT = "present", // attribute exists
APPROX = "approx", // approximately equals
}
// Type definition for an LDAP condition
export interface LdapCondition {
operator: LdapOperator;
attribute?: string; // Not required for logical operators (AND, OR, NOT)
value?: string; // Not required for some operators (PRESENT, logical operators)
conditions?: LdapCondition[]; // For nested conditions with logical operators
}
// Type definition for an LDAP attribute
export interface LdapAttribute {
name: string;
type: string;
description?: string;
syntax?: string;
isMultiValued?: boolean;
isMandatory?: boolean;
}