PurchaseOrder - mandatory fields

As purchase orders can be tailored to suit customer needs, there are no fields that are always mandatory. The minimum amount of data required for entering purchase orders is very small. However, you should bear in mind that the actual amount needed to create meaningful orders and to progress those orders is much larger. This is wholly dependant on how your system is configured.

As a guide, you may find that the following need to be supplied:

  • Purchase Transaction Type - payload element <PurchaseTransactionType>

  • Purchase Order Reference - payload element <PurchaseOrderReference>

  • Either User Line Number - payload element <UserLineNumber> or Line Number - payload element <LineNumber>

  • Item Code - payload element <ItemCode>.

See individual methods for specific field requirements.

Uwaga: At runtime the component validates the payload contents to ensure that the values supplied are correct. Various combinations of values may require other elements in the payload to be specified before the payload can be processed successfully.

Examples of the Approve MethodExamples of the Approve Method

The following example is used to unapprove all lines on the purchase order:

<PurchaseOrder>
		<PurchaseOrderReference>PO/002104</PurchaseOrderReference>
				<Approval>
					<Unapprove>Y</Unapprove>
					<ReasonCode>DAMAGED</ReasonCode>
				</Approval>
		</PurchaseOrder>

The following example is used to unapprove line 1 and Approve lines 2 and 3 on the purchase order:

<PurchaseOrder>
		<PurchaseOrderReference>PO/002104</PurchaseOrderReference>
				<PurchaseOrderLine>LineNumber>1</LineNumber>
				<Approval>
						<Unapprove>Y</Unapprove>
						<ReasonCode>DAMAGED</ReasonCode>
				</Approval>
		</PurchaseOrderLine>
		<PurchaseOrderLine>
				<LineNumber>2</LineNumber>
				<Approval>
						<Unapprove>N</Unapprove>
						<ReasonCode>DAMAGED</ReasonCode>
				</Approval>
		</PurchaseOrderLine>
		<PurchaseOrderLine>
				<LineNumber>3</LineNumber>
		</PurchaseOrderLine>
</PurchaseOrder>