<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:msxml="urn:schemas-microsoft-com:xslt" version="1.0" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:unic="http://unica.nl/">
	<xsl:output method="xml" indent="yes" encoding="utf-8"/>

	<xsl:decimal-format name="european" decimal-separator="," grouping-separator="."/>

	<xsl:variable name="Rev">
		<!-- Revision van deze MaasStatusResponse.xsl -->
		<xsl:value-of select="substring(translate('$Revision$', '$ ', ''), 10)"/>
	</xsl:variable>

	<xsl:template name="strip_prefix">
		<xsl:param name="in"/>
		<xsl:choose>
			<xsl:when test="translate(substring($in,1,1), '01234567890', '')">
				<xsl:call-template name="strip_prefix">
					<xsl:with-param name="in" select="substring($in, 2)"/>
				</xsl:call-template>
			</xsl:when>
			<xsl:otherwise>
				<xsl:value-of select="$in"/>
			</xsl:otherwise>
		</xsl:choose>
	</xsl:template>

	<xsl:template match="RegistrationStatus">
		<facilitor>
			<xsl:for-each select="Status">
				<xsl:element name="opdracht">
					<xsl:attribute name="key">
						<xsl:call-template name="strip_prefix">
							<xsl:with-param name="in" select="ExtReference"/>
						</xsl:call-template>
					</xsl:attribute>
					<xsl:attribute name="type">update</xsl:attribute>
					<xsl:choose>
						<xsl:when test="Status = 'Technisch gereed' ">
							<status>ORDAFM</status>
						</xsl:when>
						<xsl:when test="New = '1'">
							<status>ORDACP</status>
						</xsl:when>
						<xsl:otherwise>
							<status></status>
						</xsl:otherwise>
					</xsl:choose>
					<mut_datum>
						<xsl:value-of select="DateTime"/>
					</mut_datum>
					<opmerking>
						<xsl:value-of select="DateTime"/>:<xsl:value-of select="Status"/>
						<xsl:value-of select="DetailedRemarks"/>
					</opmerking>
					<xsl:element name="kenmerk">
						<xsl:attribute name="naam">Ref. Nr. Leverancier</xsl:attribute>
						<xsl:attribute name="type">C</xsl:attribute>
						<xsl:value-of select="RegistrationID"/>
					</xsl:element>
				</xsl:element>
			</xsl:for-each>
		</facilitor>
	</xsl:template>

	<!-- Root -->
	<xsl:template match="/">
		<xsl:apply-templates select="soap:Envelope/soap:Body"/>
	</xsl:template>
</xsl:stylesheet><!-- Stylesheet edited using Stylus Studio - (c) 2004-2007. Progress Software Corporation. All rights reserved. --><!-- Stylesheet edited using Stylus Studio - (c) 2004-2007. Progress Software Corporation. All rights reserved. --><!-- Stylesheet edited using Stylus Studio - (c) 2004-2007. Progress Software Corporation. All rights reserved. --><!-- Stylesheet edited using Stylus Studio - (c) 2004-2007. Progress Software Corporation. All rights reserved. --><!-- Stylesheet edited using Stylus Studio - (c) 2004-2007. Progress Software Corporation. All rights reserved. -->