clsTeamAssignment¶
clsTeamAssignment represents one assigned service-team member on a policy. clsTeamAssignmentCollection materializes instances from pk72846_view_policy.team_assign_query, then this type interprets employee-status codes, exposes the team-function mapping used by authorization and display code, and derives an email address either from internal SAIF naming conventions or from external-client lookup procedures for non-SAIF members.
Purpose¶
- Hold one row from the policy service-team query with enough behavior to interpret status, function, and contact identity.
- Derive a usable email address from either internal SAIF user IDs or external lookup procedures (BR-VP-022).
- Preserve the unmasked consultant ID for demo scenarios so loss-control authorization can compare the real identity even when the displayed user name is masked (BR-VP-008, BR-VP-010).
Context¶
- Namespace:
SAIF.Business.View.Policy - Assembly/package:
SAIF.Business.View.Policy(embedded)
Public members¶
| Member | Signature | Purpose |
|---|---|---|
InitializeEmailAddress |
Public Sub InitializeEmailAddress(ByVal inEmailAddressDPI As IDataPortalInfo) |
Uses SQL Server procedure cp_external_client_lookup to resolve a non-SAIF member's external email address and short display suffix (BR-VP-022). |
InitializeEmailAddressUsingSystemUser |
Public Sub InitializeEmailAddressUsingSystemUser(ByVal inDPI As IDataPortalInfo) |
Uses Oracle procedure sp73341_external_client_lookup to resolve a non-SAIF member's external email address when the caller routes through the system-user path (BR-VP-022). |
UserName |
Public ReadOnly Property UserName() As String |
Returns the team member's display user name, or a masking constant when the collection loaded the row in demo mode (BR-VP-010). |
UserIdName |
Public ReadOnly Property UserIdName As String |
Preserves the original unmasked user ID when display masking is enabled so authorization logic can still compare the real consultant identity (BR-VP-008). |
FullName |
Public ReadOnly Property FullName() As String |
Returns the team member's display name, masked when the row was loaded for a demo user (BR-VP-010). |
PhoneNum |
Public ReadOnly Property PhoneNum() As String |
Returns the team member's phone number or a demo masking value when required (BR-VP-010). |
PhoneExt |
Public ReadOnly Property PhoneExt() As String |
Returns the stored phone extension, blank for masked demo rows. |
TeamFunction |
Public ReadOnly Property TeamFunction() As clsTeamAssignmentCollection.TeamFunctions |
Returns the normalized service-team role enum used by consumers to locate a consultant, underwriter, billing rep, or similar assignment. |
TeamFunctionDescription |
Public ReadOnly Property TeamFunctionDescription() As String |
Returns the database description for the role code so callers can display the assignment meaningfully. |
EmployeeStatus |
Public ReadOnly Property EmployeeStatus() As EmployeeStatuses |
Interprets the stored employee-status code into the enum that controls email derivation branches. |
EmployeeStatusCode |
ReadOnly Property EmployeeStatusCode() As String |
Exposes the raw status code for consumers that need the persisted source value. |
EmailAddress |
Public ReadOnly Property EmailAddress As String |
Returns an @saif.com address for internal SAIF identities, an externally resolved address for non-SAIF members after initialization, or blank for inactive/other/empty assignments (BR-VP-022). |
ExternalFullNameExtension |
Public ReadOnly Property ExternalFullNameExtension As String |
Stores the suffix derived during external lookup so UI code can append a short user-ID hint to the displayed external name. |
IsNonSAIFEmployee |
Public ReadOnly Property IsNonSAIFEmployee As Boolean |
Indicates that external lookup may be required because the team member is not a SAIF employee. |
IsInactiveEmployee |
Public ReadOnly Property IsInactiveEmployee As Boolean |
Indicates that email derivation should return blank because the assignment points at an inactive employee. |
IsOtherEmployee |
Public ReadOnly Property IsOtherEmployee As Boolean |
Indicates that the row does not map to a recognized employee type and therefore should not derive an address automatically. |
MaskData |
Public Property MaskData() As Boolean |
Tells Load whether to preserve live identity values or replace them with demo-safe placeholders (BR-VP-010). |
Behavioral notes¶
LoadmasksUserName,FullName,PhoneNum, andPhoneExtwhenMaskDatais true, while preserving the original user name inUserIdNamefor authorization logic (BR-VP-008, BR-VP-010).EmailAddressderives internal addresses directly forSERVIC,SCLC,SAFETYSERVICES, and other active internal IDs by appending@saif.com(BR-VP-022).- Non-SAIF members require one of the initialization methods to populate
m_EmailAddress; otherwiseEmailAddressremains blank even though the row exists (BR-VP-022). InitializeEmailAddressandInitializeEmailAddressUsingSystemUserboth derive a last-name lookup key fromFullNamebefore calling their respective procedures.
Constraints and usage notes¶
- Call the appropriate initialization method before reading
EmailAddressfor non-SAIF team members; the property alone does not trigger the database lookup. - Team-function interpretation depends on
clsTeamAssignmentCollection.CodeToTeamFunction, so unrecognized codes surface asUnknownat the collection layer. - This type is loaded by the collection; callers do not retrieve it directly through BOF criteria.
Sources¶
SAIF.Business.View.Policy/clsTeamAssignment.vb