STAM#51188 Aanpassen QR codes
svn path=/Website/branches/v2017.2/; revision=36004
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
<xsl:value-of select="substring(translate('$Revision$', '$ ', ''), 10)"/>
|
||||
</xsl:variable>
|
||||
|
||||
<xsl:variable name="Xsrtnotificatiecode">MLD2B3</xsl:variable>
|
||||
<xsl:variable name="Xsrtnotificatiecode">MLD2B3</xsl:variable>
|
||||
|
||||
<!-- ****************************************************************************************************************** -->
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
|
||||
<xsl:template match="rapport">
|
||||
|
||||
<xsl:if test="@view = 'STAM_V_INS_QRC_OBJECT'">
|
||||
<!-- <xsl:if test="@view = 'STAM_V_INS_QRC_OBJECT'">
|
||||
<xsl:for-each select="rapport_data/data_row">
|
||||
<xsl:sort select="FCLT_F_IDENTIFICATIE"/>
|
||||
<div style="background-color: black; position: relative; margin: 0; padding: 0; width: 58.5mm; height: 19.5mm; page-break-after: always; border-bottom: 1px solid white;">
|
||||
@@ -42,10 +42,40 @@
|
||||
</xsl:element>
|
||||
</div>
|
||||
</xsl:for-each>
|
||||
</xsl:if> -->
|
||||
|
||||
<xsl:if test="@view ='STAM_V_INS_QRC_OBJECT'">
|
||||
|
||||
<html>
|
||||
|
||||
<xsl:variable name="p_rows" select="8"/>
|
||||
<xsl:variable name="p_cols" select="3"/>
|
||||
|
||||
<xsl:for-each select="//facilitor/rapport/rapport_data/data_row">
|
||||
<xsl:sort select="FCLT_F_GEBOUW"/>
|
||||
<xsl:sort select="PLAATS"/>
|
||||
<xsl:if test="position() mod ($p_rows * $p_cols) = 0">
|
||||
<xsl:comment>=== Na elke p_rows*p_cols records (m*n passen op 1 A4) =====</xsl:comment>
|
||||
<xsl:call-template name="qrc_ins_new_page">
|
||||
<xsl:with-param name="p_page" select="floor(position() div ($p_rows * $p_cols))"/>
|
||||
<xsl:with-param name="p_rows" select="$p_rows"/>
|
||||
<xsl:with-param name="p_cols" select="$p_cols"/>
|
||||
</xsl:call-template>
|
||||
<div style="page-break-after:always; margin:0;padding:0"> </div>
|
||||
</xsl:if>
|
||||
<xsl:if test="position() = last() and position() mod ($p_rows * $p_cols) != 0 ">
|
||||
<xsl:comment>=== De laatste paar, zijn minder dan m*n =====</xsl:comment>
|
||||
<xsl:call-template name="qrc_ins_new_page">
|
||||
<xsl:with-param name="p_page" select="floor((position() div ($p_rows * $p_cols))+1)"/>
|
||||
<xsl:with-param name="p_rows" select="$p_rows"/>
|
||||
<xsl:with-param name="p_cols" select="$p_cols"/>
|
||||
</xsl:call-template>
|
||||
</xsl:if>
|
||||
</xsl:for-each>
|
||||
|
||||
</html>
|
||||
</xsl:if>
|
||||
|
||||
|
||||
|
||||
<xsl:if test="@view = 'STAM_V_INS_QRC_RUIMTE'">
|
||||
<xsl:for-each select="rapport_data/data_row">
|
||||
<xsl:sort select="PLAATS"/>
|
||||
@@ -68,7 +98,80 @@
|
||||
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="qrc_ins_new_page">
|
||||
<xsl:param name="p_page"/>
|
||||
<xsl:param name="p_rows"/>
|
||||
<xsl:param name="p_cols"/>
|
||||
<table>
|
||||
|
||||
<xsl:for-each select="//facilitor/rapport/rapport_data/data_row">
|
||||
<xsl:sort select="FCLT_F_GEBOUW"/>
|
||||
<xsl:sort select="FCLT_F_PLAATS"/>
|
||||
<xsl:if test="position() >= (($p_page - 1)*($p_rows*$p_cols)+1) and position() <= ($p_page*($p_rows*$p_cols))">
|
||||
<xsl:if test="(position() mod $p_cols) = 0">
|
||||
<xsl:comment>=== Na elke 1 records (1x1 passen op 1 regel) =====</xsl:comment>
|
||||
<xsl:call-template name="qrc_ins_new_tr">
|
||||
<xsl:with-param name="p_pos" select="position() - $p_cols + 1"/>
|
||||
<xsl:with-param name="p_cols" select="$p_cols"/>
|
||||
</xsl:call-template>
|
||||
</xsl:if>
|
||||
<xsl:if test="(position() = last()) and (position() mod $p_cols) != 0">
|
||||
<xsl:comment>=== Na elke 1 records (1x1 passen op 1 regel) =====</xsl:comment>
|
||||
<xsl:call-template name="qrc_ins_new_tr">
|
||||
<xsl:with-param name="p_pos" select="floor(position() div $p_cols) * $p_cols + 1"/>
|
||||
<xsl:with-param name="p_cols" select="$p_cols"/>
|
||||
</xsl:call-template>
|
||||
</xsl:if>
|
||||
</xsl:if>
|
||||
</xsl:for-each>
|
||||
</table>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="qrc_ins_new_tr">
|
||||
<xsl:param name="p_pos"/>
|
||||
<xsl:param name="p_cols"/>
|
||||
|
||||
<tr>
|
||||
<xsl:for-each select="//facilitor/rapport/rapport_data/data_row">
|
||||
<xsl:sort select="FCLT_F_PLAATS"/>
|
||||
<xsl:if test="position() >= $p_pos and position() <= $p_pos + $p_cols - 1">
|
||||
<xsl:apply-templates select="." mode="qrc"/>
|
||||
</xsl:if>
|
||||
</xsl:for-each>
|
||||
</tr>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="data_row" mode="qrc">
|
||||
<!-- <table style="text-align: left; vertical-align: top; margin:0;padding:0 height: 32mm ; width: 70mm"> -->
|
||||
<td style="text-align:left; vertical-align: top; color: rgb(0, 174, 239); margin:0;padding:0; font-size: 8pt; font-weight: bold; height: 35mm ; width: 50mm">
|
||||
<br/>
|
||||
<xsl:value-of select="FCLT_F_IDENTIFICATIE"/>
|
||||
<xsl:choose>
|
||||
<xsl:when test="BRAND!=''">
|
||||
<br/>
|
||||
<xsl:value-of select="BRAND"/>
|
||||
</xsl:when>
|
||||
</xsl:choose>
|
||||
<xsl:choose>
|
||||
<xsl:when test="OBJ_TYPE!=''">
|
||||
<br/>
|
||||
<xsl:value-of select="OBJ_TYPE"/>
|
||||
</xsl:when>
|
||||
</xsl:choose>
|
||||
<br/>
|
||||
<xsl:value-of select="LOCATIE_CODE"/> - <xsl:value-of select="RUIMTENR"/>
|
||||
</td>
|
||||
<td> </td>
|
||||
<td style="text-align: left; vertical-align: top; margin:0;padding:0 height: 35mm ; width: 25mm">
|
||||
<xsl:element name="img">
|
||||
<xsl:attribute name="style"> color: rgb(0, 174, 239); height: 25mm; width: 25mm; margin:0cm; padding:0; border: none </xsl:attribute>
|
||||
<xsl:attribute name="src">
|
||||
../../appl/shared/qrcode.asp?size=2&text=/%3Fu%3D<xsl:value-of select="HIDE_F_BOOKMARK_ID"/>%26k%3D<xsl:value-of select="INS_DEEL_KEY"/>
|
||||
</xsl:attribute>
|
||||
</xsl:element>
|
||||
</td>
|
||||
|
||||
<!-- </table> -->
|
||||
</xsl:template>
|
||||
|
||||
</xsl:stylesheet>
|
||||
|
||||
Reference in New Issue
Block a user