Prophet Invoice as XML
| Purpose | The ultimate in file transfer, connect Prophet to anything with XML |
| Description | Provides sophisticated integration between Prophet and many other systems. XML data is standardised and portable. Prophet's Alex uses XML. This report enables business transaction level integration with other businesses - this is what e commerce looks like on the inside! Prophet's ODBC driver is too slow, especially in multi-user high-volume environments, to generate timely XML output. This RG runs at real time speed. |
| Sample | |
| Selections |
R E P O R T S E L E C T I O N ╔═════════════════════════════════╗ ║ ║ ║ Print Invoice Id ________ ║ ║ ║ ║ Simulate mode (Y/N) N ║ ║ ║ ╚═════════════════════════════════╝ |
| Sort Seq | None, run one invoice at a time |
| Filters | Invoice Id number |
| Group by | None |
| Run from | Alternative reports in OE, SI |
| Code | AAAAAA01 - strange name because it must be top of the list of alternate reports. Why? Because it is invoked by a macro, which does not have select-specific-report capability. |
| Equivalent | Nearest match in standard reports is one that outputs a file that other Prophet systems can import with FT.7.Import Invoice. Some Prophet sites use this to transfer orders from remote branches to head office, or from QPos to Prophet. |
| Complexity | High - complex code, sophisticated interface to other information systems. |
| Code snip |
E D I T B O D Y │ SET XMLData TO "<?xml version="+Q+"1.0"+Q+" standalone="+Q+"yes"+Q+"?><invoice │ OUTPUT XMLLINE │ │ SET Message TO "Fail: No message" │ │ ┌─IF FINDRECORD(InvoiceHeadFile,InvoiceHeadFile.InvoiceIDKey,PrintInvoiceId)─┐ │ │ ┌─IF InvoiceHeadFile.InvoiceOrderType = "N"────────────────────────────────┐ │ │ │ ┌─IF InvoiceHeadFile.InvoiceCreditOrd = "I"──────────────────────────────┐ │ │ │ │ ┌─IF InvoiceHeadFile.Status = "C"──────────────────────────────────────┐ │ │ │ │ │ ┌─IF BLANK(InvoiceHeadFile.InvoiceNumber)────────────────────────────┐ │ │ │ │ │ │ SEEK(InvoiceLineFile,0) │ │ │ │ │ │ │ ┌─IF COPY(UPPERCASE(SimulateMode),0,1) = "N"───────────────────────┐ │ │ │ │ │ │ │ CALLHOOK('RGINOEOR Generate invoice number and date') │ │ │ │ │ │ │ │ SET Message TO "Ok: Invoice id " + PrintInvoiceId + " printed as " │ │ │ │ │ │ ├─ELSE ────────────────────────────────────────────────────────────┤ │ │ │ │ │ │ │ SET Message TO "Ok: Invoice id " + PrintInvoiceId + " simulated. " │ │ │ │ │ │ └──────────────────────────────────────────────────────────────────┘ │ │ │ │ │ ├─ELSE ──────────────────────────────────────────────────────────────┤ │ │ │ │ │ │ SET Message TO "Fail: Invoice id "+PrintInvoiceId+" already printed │ │ │ │ │ └────────────────────────────────────────────────────────────────────┘ │ │ │ │ ├─ELSE ────────────────────────────────────────────────────────────────┤ │ │ │ │ │ SET Message TO "Fail: Invoice id " + PrintInvoiceId + " is not complet │ │ │ │ └──────────────────────────────────────────────────────────────────────┘ │ │ │ ├─ELSE ──────────────────────────────────────────────────────────────────┤ │ │ │ │ SET Message TO "Fail: Invoice id " + PrintInvoiceId + " is an order, quo |
| Release date | 10 June 2002 |