From: Sven Schöling Date: Thu, 7 Feb 2008 12:38:02 +0000 (+0000) Subject: Warendialog -> Preisgruppen in Template ausgelagert. X-Git-Tag: release-2.6.0beta1~247 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=9f795a104880cd2fd6515afa90bc3af6b284bc83;p=kivitendo-erp.git Warendialog -> Preisgruppen in Template ausgelagert. Template blendet die komplette Tabelle aus, wenn keine Preisgruppen gefunden werden. --- diff --git a/bin/mozilla/ic.pl b/bin/mozilla/ic.pl index 928a0aba6..f2ca8a929 100644 --- a/bin/mozilla/ic.pl +++ b/bin/mozilla/ic.pl @@ -2069,30 +2069,13 @@ sub price_row { my ($numrows) = @_; - print qq| - - - - - - - -|; - for my $i (1 .. $numrows) { - print qq| - - - - - -|; - } + my @PRICES = map +{ + pricegroup => $form->{"pricegroup_$_"}, + pricegroup_id => $form->{"pricegroup_id_$_"}, + price => $form->{"price_$_"}, + }, 1 .. $numrows; - print qq| -
| . $locale->text('Preisklasse') . qq|| . $locale->text('Preis') . qq|
$form->{"pricegroup_$i"}
- - -|; + print $form->parse_html_template('ic/price_row', { PRICES => \@PRICES }); $lxdebug->leave_sub(); } diff --git a/templates/webpages/ic/price_row_de.html b/templates/webpages/ic/price_row_de.html new file mode 100644 index 000000000..01153808b --- /dev/null +++ b/templates/webpages/ic/price_row_de.html @@ -0,0 +1,20 @@ +[%- USE HTML %] +[%- IF PRICES.count %] + + + + + + + +[%- FOREACH row = PRICES %] + + + + + +[%- END %] +
PreisgruppePreis
[% HTML.escape(row.pricegroup) %]
+ + +[%- END %] diff --git a/templates/webpages/ic/price_row_master.html b/templates/webpages/ic/price_row_master.html new file mode 100644 index 000000000..da548fed6 --- /dev/null +++ b/templates/webpages/ic/price_row_master.html @@ -0,0 +1,20 @@ +[%- USE HTML %] +[%- IF PRICES.count %] + + + + + + + +[%- FOREACH row = PRICES %] + + + + + +[%- END %] +
PreisklassePreis
[% HTML.escape(row.pricegroup) %]
+ + +[%- END %]