namespace EntitlementDAL.DTOs; /// Request to create a brand-new tenant's identity: the MCLIENT row plus its first /// admin MUSER. Internal-staff-only — never reachable by a client-portal caller. public class CreateClientRequestDTO { public string ClientCode { get; set; } = string.Empty; public string ClientName { get; set; } = string.Empty; public string ClientShortName { get; set; } = string.Empty; public string AdminUserCode { get; set; } = string.Empty; public string AdminUserName { get; set; } = string.Empty; public string AdminEmail { get; set; } = string.Empty; public string AdminMobile { get; set; } = string.Empty; // Legal/Contract Agreement Consent jurisdiction resolution (tracker §51.12) — genuinely // optional, no validation. Null/empty means "unknown," which IAgreementConsentProvider // already treats identically to an explicit universal request everywhere else this // mechanism is used — no caller is required to start supplying it. public string? JurisdictionCode { get; set; } // Tracker §52 — BYOC/On-Prem gating: defaults to SaaS (0). Only OnboardClient.cs's own // SL endpoint ever threads a caller-supplied value through here (an internal-staff-only, // additionally entdeploy-gated action for anything other than SaaS); SelfProvisionTrial/ // Demo's own internal OnboardClientRequestDTO construction never sets this field, so // Trial/Demo structurally can never become anything but SaaS. public byte DeploymentType { get; set; } } /// The one and only place the first admin's plaintext temporary password is ever /// visible — the caller must relay it out-of-band; it is never logged or persisted anywhere /// except as its hashed form on MUSER (see IUserBLL.SaveUser). public class CreateClientResultDTO { public int ClientId { get; set; } public int UserId { get; set; } public string TemporaryPassword { get; set; } = string.Empty; } /// MCLIENT — the base columns confirmed live against a real tenant DB, plus /// Entitlement's own already-written additive columns (20260713_Entitlement_Phase1_MCLIENT_Extension). public class NewClientDTO { public int ClientId { get; set; } public string ClientCode { get; set; } = string.Empty; public string ClientName { get; set; } = string.Empty; public string ClientShortName { get; set; } = string.Empty; // Entitlement's own additive MCLIENT columns. // DeploymentType — see GB5Shared.Enums.Client.ClientDeploymentType for the canonical // enum (reconciled 2026-07-26 against MPROVISIONINGJOB.DeploymentType, which // previously assigned different meanings to the same byte value). public byte DeploymentType { get; set; } public byte SubscriptionStatus { get; set; } public byte TrialMode { get; set; } // Tracker §51.12 — added alongside DeploymentType/SubscriptionStatus/TrialMode above, same // additive-column convention. public string? JurisdictionCode { get; set; } // audit tail public short Version { get; set; } public byte Status { get; set; } = 1; public int SortOrder { get; set; } public int CreatedById { get; set; } public DateTime CreatedOn { get; set; } public int ModifiedById { get; set; } public DateTime ModifiedOn { get; set; } public byte SourceType { get; set; } }