MGCLatticeExpenseReportService.createExpenseReport
Creates an expense report with its lines for a worker, the way the expense report page does (see the class remarks), and with SubmitToWorkflow submits it to its expense report approval workflow the way its Submit does. The report and its lines are created in one transaction; the submit runs after it, with the standard submit checks outside a transaction as the standard requires.
- HTTP method:
POST - Route:
/api/services/MGCLatticeExpenseServiceGroup/MGCLatticeExpenseReportService/createExpenseReport - Service class:
MGCLatticeExpenseReportService
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
_request | MGCLatticeExpenseReportCreateRequestContract | No | The request: WorkerPersonnelNumber (empty = the calling user's worker), Purpose, Description, Location, Dimensions, Lines, SubmitToWorkflow, Comment, and standard header fields. |
Returns
MGCLatticeOrderOperationResponseContract
An MGCLatticeOrderOperationResponseContract: DocumentId is the expense report number; with SubmitToWorkflow, PostedDocumentId is the correlation id of the workflow instance (lower case, without braces), the key the workflow service's approveWorkItem, rejectWorkItem, recallWorkflow and getWorkflowStatus take.
Security
- Requires privilege
MGCLatticeExpenseReportServiceMaintain