Bulk-raise claim tasks¶
Assembles many claim tasks through clsClaimTaskGenerator and persists them as one collection.
| Field | Value |
|---|---|
| Operation ID | OP-2 |
| Trigger | An application process needs to raise one or more workflow tasks against claims |
| Inputs | Text, optional assignee mailid, optional due date/offset, priority enum, claim category, notepad-required flag |
| Outputs | Tasks queued in the inner collection, persisted on Save() |
| Primary components | clsClaimTaskGenerator.AddTask, clsClaimTaskGenerator.NewTask, clsClaimTaskGenerator.Save |
| Entry point | SAIF.Business.Tasks.Claim/clsClaimTaskGenerator.vb |
Steps¶
- Construction: store DPI, resolve default claim (by
ClaimID, claim number, orclsClaimData), create the inner collection viaclsClaimTaskCollection.NewTaskCollection(dpi), and defaultm_CreateUsertodpi.UserIDwhen not supplied (BR-GEN-04). AddTask(...)overloads normalize the due date before delegating: no-date overloads useclsSmartDate(Today).NextWorkDay; date overloads substituteNextWorkDaywhen the supplied date is not a working day; offset overloads useNextWorkDay(offset, NonWorkDayOption.PreviousWorkDay, False)(BR-GEN-02).- Private
NewTask(...): ifinClaimID = 0, throwApplicationException("ClaimID not specified")(BR-GEN-01). - On failure: creation aborts with the exception.
- Create the task via
clsClaimTask.NewTask(collection criteria DPI, inClaimID, m_CreateUser).
Origin: This step invokes Create a claim task, which builds and enriches the claim task. 5. If no assignee was supplied, resolve one:
ClaimServices.GetResponsibleAdjuster(dpi, inClaimID)when noclsClaimDatais cached, otherwisem_ClaimData.AdjusterMailID(BR-GEN-03). 6. IfinNotePadRequired, setsetNotePadFlag = "Y"(marks the task dirty and makesRequiresNotePadEntrytrue). 7. If aclsClaimDatais cached, copyPolicyNumberonto the task. 8. AssignMailID(triggers BR-CT-03/BR-CT-06 viaCheckRules("TaskUser")),Text(sanitized, triggers BR-CT-04/BR-CT-05),PriorityCode(fromGetPriorityText),TaskDate. 9. SetCategoryCodetoFSTRKforClaimCategories.FastTrack, otherwiseCLMM(BR-CT-10). 10. Register the extra ruleIsValidClaimIDon the task instance (BR-GEN-05) and add the task to the inner collection. 11.Save()forwards tom_Collection.Save()— the base collection applies edits and persists each task through the inherited stored-procedure path.Origin: Persistence is implemented by SAIF.Business.Tasks; step 11 is the inherited task collection save path.
Process flow¶
flowchart TD
Start([AddTask called]) --> Norm[Normalize due date]
Norm --> Check{ClaimID = 0?}
Check -->|Yes| Err([ApplicationException])
Check -->|No| NewTask[Create claim task]
NewTask --> Assignee{Assignee supplied?}
Assignee -->|No| Resolve[Resolve responsible adjuster]
Assignee -->|Yes| SetFields["Set MailID, Text, Priority,<br>Category"]
Resolve --> SetFields
SetFields --> Register[Register IsValidClaimID rule]
Register --> Add[Add to inner collection]
Add --> Save([Save persists collection])
Failure and edge-case behavior¶
- Missing claim ID:
ApplicationException("ClaimID not specified"). - Rule failures surface through
IsValid/ErrorMessagesrather than exceptions.
Related documentation¶
Sources¶
- SAIF.Business.Tasks.Claim/clsClaimTaskGenerator.vb