Files
2024-11-07 15:22:58 +01:00

76 lines
2.0 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="2.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template name="DocumentType">
<xsl:param name="DocumentType" />
<xsl:choose>
<xsl:when test="'DEV-8311'">
<xsl:value-of select="'XMLDESADV'" />
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="' '" />
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template name="DocumentSubType">
<xsl:param name="LFART" />
<xsl:choose>
<xsl:when test="$LFART = 'ZIL'">
<xsl:value-of select="'DESADV_IBT'" />
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="'DESADV_GI'" />
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template name="QuantityQualifier">
<xsl:param name="UoM" />
<xsl:choose>
<xsl:when test="$UoM = 'PCE'">
<xsl:value-of select="'12'" />
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="'999'" />
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template name="EDI_DC40-8309">
<xsl:param name="sendFromGLN" />
<xsl:param name="sendToGLN" />
<EDI_DC40>
<xsl:attribute name="SEGMENT"><xsl:copy-of select="1"/> </xsl:attribute>
<TABNAM>EDI_DC40</TABNAM>
<MANDT>100</MANDT>
<DIRECT>2</DIRECT>
<OUTMOD></OUTMOD>
<DOCNUM></DOCNUM>
<IDOCTYP>DELVRY07</IDOCTYP>
<MESTYP>WHSCON</MESTYP>
<MESCOD>WE</MESCOD>
<STDMES>DESADV</STDMES>
<SNDPOR>SYSPRO</SNDPOR> <!-- change to Syspro -->
<SNDPRT>LS</SNDPRT>
<SNDPRN>SYSPRO</SNDPRN>
<RCVPOR>SAP</RCVPOR>
<RCVPRT>LS</RCVPRT>
<RCVPFC></RCVPFC>
<RCVPRN>SAP</RCVPRN>
<SNDLAD><xsl:value-of select="$sendFromGLN"/></SNDLAD>
<RCVLAD><xsl:value-of select="$sendToGLN"/></RCVLAD>
<CREDAT></CREDAT>
<CRETIM></CRETIM>
<REFGRP>SYSPRO</REFGRP>
<REFMES><xsl:value-of select="$sendFromGLN"/></REFMES>
<SERIAL><xsl:value-of select="current-dateTime()"/></SERIAL>
</EDI_DC40>
</xsl:template>
<xsl:template name="Qualifier-8309">
<xsl:value-of select="'PGI'" />
</xsl:template>
</xsl:stylesheet>