Bugfix für das erstellen des Bestellscheins über mehrere Seiten

This commit is contained in:
Andreas Österreicher
2011-12-06 08:18:48 +00:00
parent 783b96daec
commit 13c50b5f86
4 changed files with 25 additions and 13 deletions
+15 -3
View File
@@ -144,11 +144,23 @@ if (isset($_REQUEST["xmlformat"]) && $_REQUEST["xmlformat"] == "xml")
$summe_mwst=0;
$i=0;
$pagebreakposition=30;
$pagebreak=false;
echo " <details>\n";
foreach($details->result as $row)
{
if($i==28)
//wenn die Bezeichnung zu lange ist, dann muss die Seite frueher umbrechen
if(!$pagebreak && mb_strlen($row->beschreibung)>60)
{
//echo "reduce";
$pagebreakposition--;
}
//echo "pos:".$pagebreakposition;
//echo "i:".$i;
if(!$pagebreak && $i>$pagebreakposition)
{
$pagebreak=true;
echo "</details>\n";
echo "<details_1>\n";
}
@@ -170,8 +182,8 @@ if (isset($_REQUEST["xmlformat"]) && $_REQUEST["xmlformat"] == "xml")
$summe_mwst+=$row->menge*$row->preisprove/100*$row->mwst;
$i++;
}
if($i>28)
//echo "pos:".$pagebreakposition;
if($i>$pagebreakposition)
echo " </details_1>\n";
else
echo " </details>\n";
+1 -1
View File
@@ -204,7 +204,7 @@ echo nl2br($text);
if($text!='')
{
$mail = new mail(MAIL_IT.', tw_ht@technikum-wien.at, schmuderm@technikum-wien.at, vilesci@technikum-wien.at', 'vilesci@'.DOMAIN, 'Account Deaktivierung', "Dies ist eine automatische Mail!\nFolgende Warnungen zur Accountloeschung wurden versandt:\n\n".$text);
$mail = new mail(MAIL_IT.', vilesci@technikum-wien.at', 'vilesci@'.DOMAIN, 'Account Deaktivierung', "Dies ist eine automatische Mail!\nFolgende Warnungen zur Accountloeschung wurden versandt:\n\n".$text);
$mail->send();
}
+7 -7
View File
@@ -670,7 +670,7 @@
<fo:table-column column-width="7mm"/>
<fo:table-column column-width="9.4mm"/>
<!-- <fo:table-column column-width="7.2mm"/>-->
<fo:table-column column-width="78.4mm"/>
<fo:table-column column-width="85.6mm"/><!-- 78.4mm -->
<fo:table-column column-width="34.8mm"/>
<fo:table-column column-width="14.8mm"/>
<fo:table-column column-width="19.8mm"/>
@@ -773,9 +773,9 @@
<fo:block-container position="absolute" top="25mm" left="10mm">
<fo:table table-layout="fixed" border-collapse="collapse">
<fo:table-column column-width="7mm"/>
<fo:table-column column-width="10mm"/>
<fo:table-column column-width="9.4mm"/>
<!-- <fo:table-column column-width="8mm"/>-->
<fo:table-column column-width="87mm"/>
<fo:table-column column-width="87mm"/> <!-- 79 -->
<fo:table-column column-width="35mm"/>
<fo:table-column column-width="15mm"/>
<fo:table-column column-width="20mm"/>
@@ -800,12 +800,12 @@
</fo:table-cell>
-->
<fo:table-cell display-align="center">
<fo:block font-size="8pt" font-weight="bold" content-width="80mm" text-align="center">
<fo:block font-size="8pt" font-weight="bold" content-width="78mm" text-align="center">
Bezeichnung
</fo:block>
</fo:table-cell>
<fo:table-cell display-align="center">
<fo:block font-size="8pt" font-weight="bold" content-width="35mm" text-align="center">
<fo:block font-size="8pt" font-weight="bold" content-width="34mm" text-align="center">
ArtikelNr
</fo:block>
</fo:table-cell>
@@ -864,12 +864,12 @@
</fo:block>
</fo:table-cell>
<fo:table-cell display-align="center">
<fo:block font-size="8pt" content-width="15mm" text-align="right">
<fo:block font-size="8pt" content-width="14mm" text-align="right">
<xsl:value-of select="preisprove" />
</fo:block>
</fo:table-cell>
<fo:table-cell display-align="center">
<fo:block font-size="8pt" content-width="20mm" text-align="right">
<fo:block font-size="8pt" content-width="19mm" text-align="right">
<xsl:value-of select="summe_netto" />
</fo:block>
</fo:table-cell>
+2 -2
View File
@@ -676,12 +676,12 @@
</fo:block>
</fo:table-cell>
<fo:table-cell display-align="center">
<fo:block font-size="8pt" content-width="15mm" text-align="right">
<fo:block font-size="8pt" content-width="14mm" text-align="right">
<xsl:value-of select="preisprove" />
</fo:block>
</fo:table-cell>
<fo:table-cell display-align="center">
<fo:block font-size="8pt" content-width="20mm" text-align="right">
<fo:block font-size="8pt" content-width="19mm" text-align="right">
<xsl:value-of select="summe_netto" />
</fo:block>
</fo:table-cell>