ViewExternalInvoice
The ViewExternalInvoice
-CUWO is responsible for displaying information about an external invoice. Or, more generally, an external invoicing operation - as the actual invoice may not yet exist.
The CUWO is called from the enforePOS's "Sales History" UI for objects (e.g., orders) that have been invoiced via an External Invoicing Methos (when enabled via the configuration of the EIM). It receives the "external reference" provided by the CUWO that handled the external invoicing (e.g., InvoiceSalesOrder
).
The CUWO does not have any actual success or failure result as it doesn't perform any business operation from the point of view of the enfore platform. It simply is a "window into the external invoicing system" that the user can choose to invoke.
Workflow parameters
The ViewExternalInvoice
-CUWO will receive an ViewExternalInvoiceWorkflowParameters
structure as input.
The structure is defined as:
/**
* The parameter/input structure for an "invoice sales order" workflow.
*/
class ViewExternalInvoiceWorkflowParameters extends WorkflowParameters {
readonly "@type" : string = "n4.cuwo.workflows.externalinvoicing.viewexternalinvoice.ViewExternalInvoiceWorkflowParameters";
/**
* The reference that was provided by the invoicing CUWO (e.g., InvoiceSalesOrder).
*/
public externalReference : string;
/**
* The (optional) note that was provided by the invoicing CUWO (e.g., InvoiceSalesOrder).
*/
public note? : string;
/**
* The number of the externally created invoice, when available.
*/
public invoiceNumber? : string;
/**
* The date of the externally created invoice, when available.
*/
public invoiceDate? : Date;
}
Success result
On success, the ViewExternalInvoice
-CUWO is expected to pass a GenericWorkflowResult
structure to terminateSuccess
.
Failure result
On failure, the ViewExternalInvoice
-CUWO is expected to pass a GenericWorkflowFailure
structure to terminateFailure
.
Cancelation result
On cancelation, the ViewExternalInvoice
-CUWO is expected to pass a GenericWorkflowCancelation
structure to terminateCanceled
.