[!NOTE]
The Legends CLI query for this package returned only the package specification; no package body was available for this run (this is normal/expected for this API — DBA_SOURCE/ALL_SOURCE exposes only what is granted). Procedure descriptions and business-rule inferences below are therefore derived from the calling VB.NET code in clsLetterRequest.vb and clsLetterRequestCollection.vb rather than from actual PL/SQL body logic, and are marked with *.
Pk82289_LegalNet_Letters supports the LegalNet letter-request workflow used to generate Xpressions print output for legal-case correspondence.* Based on the calling code in clsLetterRequest.vb and clsLetterRequestCollection.vb, the package retrieves worker/claim identification data for a legal case (GetWorkerInfo), lists outstanding letter requests (SelectLetterRequests), retrieves a single letter request's detail by its sequence number (SelectLetter), and records the printed date once a letter has been generated (UpdateLetterRequest).*
REF CURSOR (recordset) of worker/claim identification data
Called by
clsLetterRequest.GetWorkerInfo (Print\clsLetterRequest.vb, property at line 1211; private method around line 926)
Description: Called from clsLetterRequest.GetWorkerInfo, which passes MyCriteria.LegalCaseSeqNum as in_legalCaseSeq and reads the returned cursor for SaifClaimNum, PolicyNum, PrimaryTaxId, WorkerFirstName, WorkerLastName, injurydate, and RequestDate. Returns worker and claim identification information for the given legal case, used to populate letter merge fields for printing.*
clsLetterRequestCollection (Print\clsLetterRequestCollection.vb:324, via RetrieveSQL used in BeforeRetrieve)
Description: Bound as RetrieveSQL for clsLetterRequestCollection, whose BeforeRetrieve override sends this statement with no additional filter parameters visible at the call site. Returns the set of outstanding/queued letter requests used to populate a clsLetterRequestCollection for batch letter processing.*
REF CURSOR (recordset) of a single letter-request's detail
Called by
clsLetterRequest.RetrieveSQL (Print\clsLetterRequest.vb:1197); also clsLetterRequestCollection.RetrieveByRequestSeq
Description: Bound as RetrieveSQL for clsLetterRequest; BeforeRetrieve passes MyCriteria.LetterRequestSeqNum as inLetterRequestSeqNum and the resulting reader is used to Fill the object's fields (LegalCaseSeqNum, LetterRequestSeqNum, LetterTypeCode, Claimant, NumCopies, DefaultPrinter, PrintedDate). Retrieves the full detail of a single letter request by its sequence number, for display/printing of one letter.*
Row count (rows affected), consumed via NonQuery request in the caller
Called by
clsLetterRequest.UpdateSQL (Print\clsLetterRequest.vb:1203), invoked from BeforeUpdate
Description: Bound as UpdateSQL for clsLetterRequest; BeforeUpdate sends _printedDate as inPrintedDate and MyCriteria.LetterRequestSeqNum as inLetterRequestSeqNum, and AfterUpdate verifies exactly one row was affected. Marks a letter request as printed by recording its printed date, keyed by the letter-request sequence number.*
Rules extracted from the calling VB.NET code (inferred; no package body was available for direct confirmation):
BR-PKG3-001: Letter request update expects a single affected row¶
Field
Value
Statement
After calling UpdateLetterRequest, clsLetterRequest.AfterUpdate checks that exactly one row was affected by the update.*
Trigger
Saving a clsLetterRequest object (letter marked as printed).
Enforcement
clsLetterRequest.AfterUpdate in Print\clsLetterRequest.vb.*
Outcome
A rows-affected count other than 1 indicates the letter-request sequence number did not match exactly one row; calling code handling implies an error/exception path.*
Source
Print\clsLetterRequest.vb
BR-PKG3-002: Printed date defaults by letter type before update¶
Field
Value
Statement
For RDISC letters, _printedDate is set to the file-create date; for DEFLT letters, _printedDate is set to today's date, before UpdateLetterRequest is called to persist the printed date.*
Trigger
PostFill() runs after a clsLetterRequest is retrieved (SelectLetter), based on the letter's LetterTypeCode.
Enforcement
clsLetterRequest.PostFill in Print\clsLetterRequest.vb.*
Outcome
The value ultimately written via inPrintedDate depends on letter type rather than always reflecting the actual print time.*
Source
Print\clsLetterRequest.vb
BR-PKG3-003: Worker information is scoped to a single legal case¶
Field
Value
Statement
GetWorkerInfo is always invoked with a single in_legalCaseSeq value (MyCriteria.LegalCaseSeqNum) and is expected to return worker/claim data for that one legal case.*
Trigger
clsLetterRequest.PostFill calls GetWorkerInfo() after the letter request is filled.
Enforcement
clsLetterRequest.GetWorkerInfo (private) in Print\clsLetterRequest.vb.*
Outcome
Merge fields such as claimant name, claim number, and injury date are populated per-legal-case for the letter being printed.*
Source
Print\clsLetterRequest.vb
These rules are documented in business-rules.md. Newly introduced rules must be added to business-rules.md as part of the same writing task.
-- Actual PL/SQL spec retrieved from Oracle via Legends CLI-- Source: DBA_SOURCE / ALL_SOURCE for WCIS_DBA.pk82289_legalnet_lettersPACKAGEPk82289_LegalNet_LettersASTYPEref_cursorISREFCURSOR;PROCEDUREGetWorkerInfo(in_legalCaseSeqINLEGAL_CASE.LEGAL_CASE_SEQ_NUM%TYPE,recordsetINOUTref_cursor);PROCEDURESelectLetterRequests(recordsetINOUTref_cursor);PROCEDURESelectLetter(inLetterRequestSeqNumINNUMBER,recordsetINOUTref_cursor);PROCEDUREUpdateLetterRequest(inPrintedDateINLETTER_REQUEST.PRINTED_DATE%TYPE,inLetterRequestSeqNumINLETTER_REQUEST.LETTER_REQUEST_SEQ_NUM%TYPE);ENDPk82289_LegalNet_Letters;
PL/SQL package/procedure body
No package body was returned by the Legends CLI query for WCIS_DBA.pk82289_legalnet_letters in this
run. This is normal/expected for this API: DBA_SOURCE/ALL_SOURCE only exposes source text the
querying account has visibility into, and for this package only the SPEC text was available. No
body source is available to display.
Note: Statements marked with * were inferred from code structure, naming conventions, or
contextual evidence where direct confirmation was not available in source artifacts. Statements
marked with ** could not be confirmed; treat as unknown until verified.