See the example of SORQND code below:
<?xml version="1.0" encoding="utf-8" ?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:param name="InvoiceNumberFilter" /> <xsl:param name="CustomerNumberFilter" /> <xsl:param name="OrderTypeFilter" /> <xsl:param name="CustomerPoFilter" /> <xsl:param name="DispatchNoteFilter" /> <xsl:param name="GtrReferenceFilter" /> <xsl:param name="SalesOrderFilter" /> <xsl:param name="InvoiceDateFilter" /> <xsl:param name="InvoiceDateRangeFilter" /> <xsl:param name="OperatorFilter" /> <xsl:param name="GeographicAreaFilter" /> <xsl:param name="BranchFilter" /> <xsl:template match="/"> <Query xmlns:xsd="http://www.w3.org/2001/XMLSchema-instance" xsd:noNamespaceSchemaLocation="SORQND.XSD"> <Option> <Reprint>Y</Reprint> <DocumentType>I</DocumentType> <IncludeForms/> <IncludeCustomerForms/> <IncludeStockForms/> <IncludeDetailForms/> <IncludeNotes/> <IgnorePrintStatus/> <RoundMass>O</RoundMass> <RoundMassDecs/> <RoundVolume>O</RoundVolume> <RoundVolumeDecs/> <XslStylesheet/> </Option> <Filter> <xsl:if test="$InvoiceNumberFilter!=''"> <xsl:element name="InvoiceNumber" > <xsl:attribute name="FilterType" >L</xsl:attribute> <xsl:attribute name="FilterValue" > <xsl:value-of select="$InvoiceNumberFilter" /> </xsl:attribute> </xsl:element> </xsl:if> <xsl:if test="$BranchFilter!=''"> <xsl:element name="Branch" > <xsl:attribute name="FilterType" >S</xsl:attribute> <xsl:attribute name="FilterValue" > <xsl:value-of select="$BranchFilter" /> </xsl:attribute> </xsl:element> </xsl:if> <xsl:if test="$CustomerNumberFilter!=''"> <xsl:element name="Customer" > <xsl:attribute name="FilterType" >L</xsl:attribute> <xsl:attribute name="FilterValue" > <xsl:value-of select="$CustomerNumberFilter" /> </xsl:attribute> </xsl:element> </xsl:if> <xsl:if test="$OrderTypeFilter!=''"> <xsl:element name="OrderType" > <xsl:attribute name="FilterType" >S</xsl:attribute> <xsl:attribute name="FilterValue" > <xsl:value-of select="$OrderTypeFilter" /> </xsl:attribute> </xsl:element> </xsl:if> <xsl:if test="$CustomerPoFilter!=''"> <xsl:element name="CustomerPo" > <xsl:attribute name="FilterType" >S</xsl:attribute> <xsl:attribute name="FilterValue" > <xsl:value-of select="$CustomerPoFilter" /> </xsl:attribute> </xsl:element> </xsl:if> <xsl:if test="$DispatchNoteFilter!=''"> <xsl:element name="DispatchNote" > <xsl:attribute name="FilterType" >L</xsl:attribute> <xsl:attribute name="FilterValue" > <xsl:value-of select="$DispatchNoteFilter" /> </xsl:attribute> </xsl:element> </xsl:if> <xsl:if test="$GtrReferenceFilter!=''"> <xsl:element name="GtrReference" > <xsl:attribute name="FilterType" >L</xsl:attribute> <xsl:attribute name="FilterValue" > <xsl:value-of select="$GtrReferenceFilter" /> </xsl:attribute> </xsl:element> </xsl:if> <xsl:if test="$SalesOrderFilter!=''"> <xsl:element name="SalesOrder" > <xsl:attribute name="FilterType" >L</xsl:attribute> <xsl:attribute name="FilterValue" > <xsl:value-of select="$SalesOrderFilter" /> </xsl:attribute> </xsl:element> </xsl:if> <xsl:if test="$InvoiceDateFilter!='' and $InvoiceDateRangeFilter=''"> <xsl:element name="InvoiceDate" > <xsl:attribute name="FilterType" >S</xsl:attribute> <xsl:attribute name="FilterValue" > <xsl:value-of select="$InvoiceDateFilter" /> </xsl:attribute> </xsl:element> </xsl:if> <xsl:if test="$InvoiceDateRangeFilter!='' and $InvoiceDateFilter=''"> <xsl:element name="InvoiceDate" > <xsl:attribute name="FilterType" >R</xsl:attribute> <xsl:attribute name="FilterValue" > <xsl:value-of select="$InvoiceDateFilter" /> </xsl:attribute> </xsl:element> </xsl:if> <xsl:if test="$OperatorFilter!=''"> <xsl:element name="Operator" > <xsl:attribute name="FilterType" >S</xsl:attribute> <xsl:attribute name="FilterValue" > <xsl:value-of select="$OperatorFilter" /> </xsl:attribute> </xsl:element> </xsl:if> <xsl:if test="$GeographicAreaFilter!=''"> <xsl:element name="GeographicArea" > <xsl:attribute name="FilterType" >S</xsl:attribute> <xsl:attribute name="FilterValue" > <xsl:value-of select="$GeographicAreaFilter" /> </xsl:attribute> </xsl:element> </xsl:if> </Filter> </Query> </xsl:template> </xsl:stylesheet>
This document is copyrighted by Dovetail Internet Technologies, LLC., the developers of CyberStore (www.CyberStoreForSYSPRO.com).
The name SYSPRO and other information contained in this document and the application are used with the permission of SYSPRO Impact Software, Inc. (www.syspro.com) Published Wednesday, April 24, 2024