Parcourir la source

fixed blad pustego raportu

a.binder il y a 8 ans
Parent
commit
b44887708f

+ 47 - 25
SE/schema/default_db_xml_cache.public/default_db/BI_audit_ENERGA_RUM_KONTRAHENCI_POWIAZANIA/BI_audit_ENERGA_RUM_KONTRAHENCI_POWIAZANIA_tree_to_dita.xsl

@@ -979,13 +979,24 @@
                         </strow>
                     </simpletable>
                 </xsl:variable>
-                <p> Ilości powiązań <note>Uwaga, w przypadku odnalezionych kilku tras do tego samego kontrahenta pokazywana jest jedna trasa (wykres nie zawiera tego ograniczenia)</note>
-                    <xsl:copy-of select="$simpletable"/>
-                    <xsl:apply-templates mode="system_cache__dita:graph__read" select="$simpletable">
-                        <xsl:with-param name="fileindex" select="$simpletable/simpletable/@id"/>
-                        <xsl:with-param name="width" select="500"/>
-                    </xsl:apply-templates>
-                </p>
+                <xsl:choose>
+                    <xsl:when test="$simpletable//stentry">
+                        <p> Ilości powiązań <note>Uwaga, w przypadku odnalezionych kilku tras do tego samego kontrahenta pokazywana jest jedna trasa (wykres nie zawiera tego ograniczenia)</note>
+                            
+                            <xsl:copy-of select="$simpletable"/>
+                            <xsl:apply-templates mode="system_cache__dita:graph__read" select="$simpletable">
+                                <xsl:with-param name="fileindex" select="$simpletable/simpletable/@id"/>
+                                <xsl:with-param name="width" select="500"/>
+                            </xsl:apply-templates>
+                        </p>
+                    </xsl:when>
+                    <xsl:otherwise>
+                        <p>
+                            Uwaga - raport nie zawiera informacji o powiązaniach. Wybierz inne kryteria wyszukiwania.
+                        </p>
+                    </xsl:otherwise>
+                </xsl:choose>
+                
                 
                 
                 <xsl:variable name="current" select="."/>
@@ -1006,17 +1017,23 @@
                         </strow>
                     </simpletable>
                 </xsl:variable>
-                <p>Średnie długości powiązań
-                    
-                    <!--<xsl:value-of select="count( $current/BI_audit_ENERGA_RUM_KONTRAHENCI_POWIAZANIA_row[ BI_audit_ENERGA_RUM_KONTRAHENCI_POWIAZANIA_row_object[ position() = 1]/BI_audit_ENERGA_PRACOWNICY/ID=$PROCES_INIT_tree.ditamap]/object)"/>-->
-                    
-                    
-                    <xsl:copy-of select="$simpletable"/>
-                    <xsl:apply-templates mode="system_cache__dita:graph__read" select="$simpletable">
-                        <xsl:with-param name="fileindex" select="$simpletable/simpletable/@id"/>
-                        <xsl:with-param name="width" select="500"/>
-                    </xsl:apply-templates>
-                </p>
+                
+                <xsl:choose>
+                    <xsl:when test="$simpletable//stentry">
+                        <p>Średnie długości powiązań
+                            <!--<xsl:value-of select="count( $current/BI_audit_ENERGA_RUM_KONTRAHENCI_POWIAZANIA_row[ BI_audit_ENERGA_RUM_KONTRAHENCI_POWIAZANIA_row_object[ position() = 1]/BI_audit_ENERGA_PRACOWNICY/ID=$PROCES_INIT_tree.ditamap]/object)"/>-->
+                            
+                            <xsl:copy-of select="$simpletable"/>
+                            <xsl:apply-templates mode="system_cache__dita:graph__read" select="$simpletable">
+                                <xsl:with-param name="fileindex" select="$simpletable/simpletable/@id"/>
+                                <xsl:with-param name="width" select="500"/>
+                            </xsl:apply-templates>
+                        </p>
+                    </xsl:when>
+                    <xsl:otherwise/>
+                </xsl:choose>
+                
+                
                 
                 
                 <xsl:variable name="simpletable"> 
@@ -1049,13 +1066,18 @@
                         </strow>
                     </simpletable>
                 </xsl:variable>
-                <p>Kwoty transakcji <note>w mln PLN</note>
-                    <xsl:copy-of select="$simpletable"/>
-                    <xsl:apply-templates mode="system_cache__dita:graph__read" select="$simpletable">
-                        <xsl:with-param name="fileindex" select="$simpletable/simpletable/@id"/>
-                        <xsl:with-param name="width" select="500"/>
-                    </xsl:apply-templates>
-                </p>
+                <xsl:choose>
+                    <xsl:when test="$simpletable//stentry">
+                        <p>Kwoty transakcji <note>w mln PLN</note>
+                            <xsl:copy-of select="$simpletable"/>
+                            <xsl:apply-templates mode="system_cache__dita:graph__read" select="$simpletable">
+                                <xsl:with-param name="fileindex" select="$simpletable/simpletable/@id"/>
+                                <xsl:with-param name="width" select="500"/>
+                            </xsl:apply-templates>
+                        </p>
+                    </xsl:when>
+                </xsl:choose>
+                
                 
             </body>
         </topic>