Revision 83cc6a5b
Von Moritz Bunkus vor mehr als 17 Jahren hinzugefügt
SL/Form.pm | ||
---|---|---|
sub show_generic_error {
|
||
my ($self, $error, $title, $action) = @_;
|
||
|
||
my $add_params = {};
|
||
$add_params->{"title"} = $title if ($title);
|
||
$self->{"label_error"} = $error;
|
||
my $add_params = {
|
||
'title_error' => $title,
|
||
'label_error' => $error,
|
||
};
|
||
|
||
my @vars;
|
||
if ($action) {
|
||
... | ... | |
}
|
||
$add_params->{"VARIABLES"} = \@vars;
|
||
|
||
$self->{title} = $title if ($title);
|
||
|
||
$self->header();
|
||
print($self->parse_html_template("generic/error", $add_params));
|
||
print $self->parse_html_template2("generic/error", $add_params);
|
||
|
||
die("Error: $error\n");
|
||
}
|
||
|
||
sub show_generic_information {
|
||
my ($self, $error, $title) = @_;
|
||
my ($self, $text, $title) = @_;
|
||
|
||
my $add_params = {
|
||
'title_information' => $title,
|
||
'label_information' => $text,
|
||
};
|
||
|
||
my $add_params = {};
|
||
$add_params->{"title"} = $title if ($title);
|
||
$self->{"label_information"} = $error;
|
||
$self->{title} = $title if ($title);
|
||
|
||
$self->header();
|
||
print($self->parse_html_template("generic/information", $add_params));
|
||
print $self->parse_html_template2("generic/information", $add_params);
|
||
|
||
die("Information: $error\n");
|
||
}
|
bin/mozilla/common.pl | ||
---|---|---|
$form->{formel} = $formel;
|
||
$form->{"title"} = $locale->text("Please enter values");
|
||
$form->header();
|
||
print($form->parse_html_template("generic/calculate_qty", { "HEADER" => \@header,
|
||
"VARIABLES" => \@variable,
|
||
"onload" => $onload }));
|
||
print($form->parse_html_template2("generic/calculate_qty", { "HEADER" => \@header,
|
||
"VARIABLES" => \@variable,
|
||
"onload" => $onload }));
|
||
|
||
$lxdebug->leave_sub();
|
||
}
|
bin/mozilla/io.pl | ||
---|---|---|
|
||
sub edit_e_mail {
|
||
$lxdebug->enter_sub();
|
||
|
||
if ($form->{second_run}) {
|
||
$form->{print_and_post} = 0;
|
||
$form->{resubmit} = 0;
|
||
... | ... | |
$form->header;
|
||
|
||
my (@dont_hide_key_list, %dont_hide_key, @hidden_keys);
|
||
@dont_hide_key_list = qw(action email cc bcc subject message formname sendmode format header override);
|
||
@dont_hide_key_list = qw(action email cc bcc subject message sendmode format header override);
|
||
@dont_hide_key{@dont_hide_key_list} = (1) x @dont_hide_key_list;
|
||
@hidden_keys = grep { !$dont_hide_key{$_} } grep { !ref $form->{$_} } keys %$form;
|
||
|
||
print $form->parse_html_template('generic/edit_email',
|
||
{ title => $title,
|
||
a_filename => $attachment_filename,
|
||
_print_options_ => print_options('inline' => 1),
|
||
HIDDEN => [ map +{ name => $_, value => $form->{$_} }, @hidden_keys ],
|
||
SHOW_BCC => $myconfig{role} eq 'admin' });
|
||
@hidden_keys = sort grep { !$dont_hide_key{$_} } grep { !ref $form->{$_} } keys %$form;
|
||
|
||
print $form->parse_html_template2('generic/edit_email',
|
||
{ title => $title,
|
||
a_filename => $attachment_filename,
|
||
_print_options_ => print_options('inline' => 1),
|
||
HIDDEN => [ map +{ name => $_, value => $form->{$_} }, @hidden_keys ],
|
||
SHOW_BCC => $myconfig{role} eq 'admin' });
|
||
|
||
$lxdebug->leave_sub();
|
||
}
|
templates/webpages/generic/calculate_alu_de.html | ||
---|---|---|
<body <TMPL_IF NAME=onload>onload="<TMPL_VAR NAME=onload>"</TMPL_IF>>
|
||
|
||
<form name="Form">
|
||
|
||
<input type="hidden" name="input_name" value="<TMPL_VAR NAME=input_name ESCAPE=HTML>">
|
||
<input type="hidden" name="input_id" value="<TMPL_VAR NAME=input_id ESCAPE=HTML>">
|
||
<input type="hidden" name="calc_length" value="<TMPL_VAR NAME=calc_length ESCAPE=HTML>">
|
||
<input type="hidden" name="calc_weight" value="<TMPL_VAR NAME=calc_weight ESCAPE=HTML>">
|
||
<input type="hidden" name="row" value="<TMPL_VAR NAME=row ESCAPE=HTML>">
|
||
<input type="hidden" name="description" value="<TMPL_VAR NAME=description ESCAPE=HTML>">
|
||
|
||
<table width="100%">
|
||
<tr>
|
||
<th class="listtop"><TMPL_VAR NAME=title></th>
|
||
</tr>
|
||
<tr height="5"></tr>
|
||
|
||
<tr><td>Menge und Preise unten eingeben</td></tr>
|
||
|
||
<tr>
|
||
<td>
|
||
|
||
<table>
|
||
<tr>
|
||
<th nowrap class="listheading" colspan=2><TMPL_VAR NAME=description ESCAPE=HTML></th>
|
||
<tr class="listheading">
|
||
<th nowrap class="listheading">Gesamtlänge des Artikels</th>
|
||
<th nowrap class="listheading">Gewicht pro Meter</th>
|
||
</tr>
|
||
|
||
<tr class="listrow_1">
|
||
<td><TMPL_VAR NAME=length ESCAPE=HTML></td>
|
||
<td><TMPL_VAR NAME=weight ESCAPE=HTML></td>
|
||
</tr>
|
||
</table>
|
||
|
||
</td>
|
||
</tr>
|
||
<tr>
|
||
<th nowrap class="listheading">Preis Alu:</th>
|
||
<td><input id="price_alu" name="price_alu" value="<TMPL_VAR NAME=price_alu ESCAPE=HTML>"></td>
|
||
</tr>
|
||
<tr>
|
||
<th nowrap class="listheading">Preis Eloxal:</th>
|
||
<td><input id="price_eloxal" name="price_eloxal" value="<TMPL_VAR NAME=price_eloxal ESCAPE=HTML>"></td>
|
||
</tr>
|
||
<tr>
|
||
<td colspan=2><hr size=3 noshade></td>
|
||
</tr>
|
||
<tr>
|
||
<th nowrap class="listheading">Menge Alu:</th>
|
||
<td><input id="qty_alu" name="qty_alu" value="<TMPL_VAR NAME=qty_alu ESCAPE=HTML>"></td>
|
||
</tr>
|
||
<tr>
|
||
<th nowrap class="listheading">Menge Artikel:</th>
|
||
<td><input id="qty_article" name="qty_article" value="<TMPL_VAR NAME=qty ESCAPE=HTML>"></td>
|
||
</tr>
|
||
<tr>
|
||
<td colspan=2><hr size=3 noshade></td>
|
||
</tr>
|
||
<tr>
|
||
<th nowrap class="listheading">Gesamtpreis:</th>
|
||
<td><input id="total" name="total" value="<TMPL_VAR NAME=total ESCAPE=HTML>"></td>
|
||
</tr>
|
||
<tr>
|
||
<th nowrap class="listheading">Gesamtpreis Alu:</th>
|
||
<td><input id="total_alu" name="total_alu" value="<TMPL_VAR NAME=total_alu ESCAPE=HTML>"></td>
|
||
</tr>
|
||
<tr>
|
||
<th nowrap class="listheading">Gesamtpreis Eloxal:</th>
|
||
<td><input id="total_eloxal" name="total_eloxal" value="<TMPL_VAR NAME=total_eloxal ESCAPE=HTML>"></td>
|
||
</tr></table>
|
||
<button type="button" onclick="calculate_alu()">Berechnen</button>
|
||
<button type="button" onclick="alu_close()">?bernehmen</button>
|
||
</form>
|
||
|
||
<script type="text/javascript">
|
||
|
||
function calculate_alu() {
|
||
var qty_alu = document.getElementsByName("qty_alu")[0].value.replace(/,/g, ".");
|
||
var price_alu = document.getElementsByName("price_alu")[0].value.replace(/,/g, ".");
|
||
var price_eloxal = document.getElementsByName("price_eloxal")[0].value.replace(/,/g, ".");
|
||
var weight_article = document.getElementsByName("calc_weight")[0].value * document.getElementsByName("calc_length")[0].value;
|
||
var qty_article = Math.ceil(qty_alu / weight_article);
|
||
qty_alu = qty_article * weight_article;
|
||
alu = qty_alu * price_alu;
|
||
var qty_eloxal = qty_article * document.getElementsByName("calc_length")[0].value;
|
||
eloxal = qty_eloxal * price_eloxal;
|
||
|
||
|
||
total = alu + eloxal;
|
||
alu = number_format(alu, 2, ",", ".");
|
||
eloxal = number_format(eloxal, 2, ",", ".");
|
||
total = number_format(total, 2, ",", ".");
|
||
self.document.getElementsByName("qty_alu")[0].value = qty_alu;
|
||
self.document.getElementsByName("qty_article")[0].value = qty_article;
|
||
self.document.getElementsByName("total_alu")[0].value = alu;
|
||
self.document.getElementsByName("total_eloxal")[0].value = eloxal;
|
||
self.document.getElementsByName("total")[0].value = total;
|
||
}
|
||
|
||
function alu_close() {
|
||
|
||
var qty_alu = document.getElementsByName("qty_alu")[0].value.replace(/,/g, ".");
|
||
var price_alu = document.getElementsByName("price_alu")[0].value.replace(/,/g, ".");
|
||
var price_eloxal = document.getElementsByName("price_eloxal")[0].value.replace(/,/g, ".");
|
||
var weight_article = document.getElementsByName("calc_weight")[0].value * document.getElementsByName("calc_length")[0].value;
|
||
var qty_article = Math.ceil(qty_alu / weight_article);
|
||
qty_alu = qty_article * weight_article;
|
||
alu = qty_alu * price_alu;
|
||
var qty_eloxal = qty_article * document.getElementsByName("calc_length")[0].value;
|
||
eloxal = qty_eloxal * price_eloxal;
|
||
var sellprice =
|
||
|
||
|
||
total = alu + eloxal;
|
||
var sellprice = total / qty_article
|
||
qty_alu = number_format(qty_alu, 2, ",", ".");
|
||
qty_eloxal = number_format(qty_eloxal, 2, ",", ".");
|
||
alu = number_format(alu, 2, ",", ".");
|
||
eloxal = number_format(eloxal, 2, ",", ".");
|
||
sellprice = number_format(sellprice, 2, ",", ".");
|
||
var sellprice_index = window.opener.document.getElementsByName("sellprice_" + document.getElementsByName("row")[0].value).length - 1;
|
||
|
||
|
||
var article = document.getElementsByName("description")[0].value + "\r\nAlupreisberechnung:\r\n" + qty_alu + "kg Aluminiumprofil Einzelpreis: " + document.getElementsByName("price_alu")[0].value +" Gesamt: " + alu + "\r\n" + qty_eloxal + "m Eloxal Einzelpreis: " + document.getElementsByName("price_eloxal")[0].value + " Gesamt: " + eloxal;
|
||
window.opener.document.getElementsByName("qty_" + document.getElementsByName("row")[0].value)[0].value = qty_article;
|
||
window.opener.document.getElementsByName("sellprice_" + document.getElementsByName("row")[0].value)[sellprice_index].value = sellprice;
|
||
window.opener.document.getElementsByName("description_" + document.getElementsByName("row")[0].value)[0].value = article;
|
||
self.close();
|
||
}
|
||
function /*out: String*/ number_format( /* in: float */ number,
|
||
/* in: integer */ laenge,
|
||
/* in: String */ sep,
|
||
/* in: String */ th_sep ) {
|
||
|
||
number = Math.round( number * Math.pow(10, laenge) ) / Math.pow(10, laenge);
|
||
str_number = number+"";
|
||
arr_int = str_number.split(".");
|
||
if(!arr_int[0]) arr_int[0] = "0";
|
||
if(!arr_int[1]) arr_int[1] = "";
|
||
if(arr_int[1].length < laenge){
|
||
nachkomma = arr_int[1];
|
||
for(i=arr_int[1].length+1; i <= laenge; i++){ nachkomma += "0"; }
|
||
arr_int[1] = nachkomma;
|
||
}
|
||
if(th_sep != "" && arr_int[0].length > 3){
|
||
Begriff = arr_int[0];
|
||
arr_int[0] = "";
|
||
for(j = 3; j < Begriff.length ; j+=3){
|
||
Extrakt = Begriff.slice(Begriff.length - j, Begriff.length - j + 3);
|
||
arr_int[0] = th_sep + Extrakt + arr_int[0] + "";
|
||
}
|
||
str_first = Begriff.substr(0, (Begriff.length % 3 == 0)?3:(Begriff.length % 3));
|
||
arr_int[0] = str_first + arr_int[0];
|
||
}
|
||
return arr_int[0]+sep+arr_int[1];
|
||
}
|
||
</script>
|
||
|
||
</body>
|
||
</html>
|
templates/webpages/generic/calculate_alu_master.html | ||
---|---|---|
<body <TMPL_IF NAME=onload>onload="<TMPL_VAR NAME=onload>"</TMPL_IF>>
|
||
|
||
<form name="Form">
|
||
|
||
<input type="hidden" name="input_name" value="<TMPL_VAR NAME=input_name ESCAPE=HTML>">
|
||
<input type="hidden" name="input_id" value="<TMPL_VAR NAME=input_id ESCAPE=HTML>">
|
||
<input type="hidden" name="calc_length" value="<TMPL_VAR NAME=calc_length ESCAPE=HTML>">
|
||
<input type="hidden" name="calc_weight" value="<TMPL_VAR NAME=calc_weight ESCAPE=HTML>">
|
||
<input type="hidden" name="row" value="<TMPL_VAR NAME=row ESCAPE=HTML>">
|
||
<input type="hidden" name="description" value="<TMPL_VAR NAME=description ESCAPE=HTML>">
|
||
|
||
<table width="100%">
|
||
<tr>
|
||
<th class="listtop"><TMPL_VAR NAME=title></th>
|
||
</tr>
|
||
<tr height="5"></tr>
|
||
|
||
<tr><td><translate>Insert quantity and prices below.</translate></td></tr>
|
||
|
||
<tr>
|
||
<td>
|
||
|
||
<table>
|
||
<tr>
|
||
<th nowrap class="listheading" colspan=2><TMPL_VAR NAME=description ESCAPE=HTML></th>
|
||
<tr class="listheading">
|
||
<th nowrap class="listheading"><translate>Total length</translate></th>
|
||
<th nowrap class="listheading"><translate>Weight/m</translate></th>
|
||
</tr>
|
||
|
||
<tr class="listrow_1">
|
||
<td><TMPL_VAR NAME=length ESCAPE=HTML></td>
|
||
<td><TMPL_VAR NAME=weight ESCAPE=HTML></td>
|
||
</tr>
|
||
</table>
|
||
|
||
</td>
|
||
</tr>
|
||
<tr>
|
||
<th nowrap class="listheading"><translate>Price Alu:</translate></th>
|
||
<td><input id="price_alu" name="price_alu" value="<TMPL_VAR NAME=price_alu ESCAPE=HTML>"></td>
|
||
</tr>
|
||
<tr>
|
||
<th nowrap class="listheading"><translate>Price Eloxal:</translate></th>
|
||
<td><input id="price_eloxal" name="price_eloxal" value="<TMPL_VAR NAME=price_eloxal ESCAPE=HTML>"></td>
|
||
</tr>
|
||
<tr>
|
||
<td colspan=2><hr size=3 noshade></td>
|
||
</tr>
|
||
<tr>
|
||
<th nowrap class="listheading"><translate>Quantity Alu:</translate></th>
|
||
<td><input id="qty_alu" name="qty_alu" value="<TMPL_VAR NAME=qty_alu ESCAPE=HTML>"></td>
|
||
</tr>
|
||
<tr>
|
||
<th nowrap class="listheading"><translate>Quantity Article:</translate></th>
|
||
<td><input id="qty_article" name="qty_article" value="<TMPL_VAR NAME=qty ESCAPE=HTML>"></td>
|
||
</tr>
|
||
<tr>
|
||
<td colspan=2><hr size=3 noshade></td>
|
||
</tr>
|
||
<tr>
|
||
<th nowrap class="listheading"><translate>Total:</translate></th>
|
||
<td><input id="total" name="total" value="<TMPL_VAR NAME=total ESCAPE=HTML>"></td>
|
||
</tr>
|
||
<tr>
|
||
<th nowrap class="listheading"><translate>Total Alu:</translate></th>
|
||
<td><input id="total_alu" name="total_alu" value="<TMPL_VAR NAME=total_alu ESCAPE=HTML>"></td>
|
||
</tr>
|
||
<tr>
|
||
<th nowrap class="listheading"><translate>Total Eloxal:</translate></th>
|
||
<td><input id="total_eloxal" name="total_eloxal" value="<TMPL_VAR NAME=total_eloxal ESCAPE=HTML>"></td>
|
||
</tr></table>
|
||
<button type="button" onclick="calculate_alu()"><translate>Calculate</translate></button>
|
||
<button type="button" onclick="alu_close()"><translate>Close</translate></button>
|
||
</form>
|
||
|
||
<script type="text/javascript">
|
||
|
||
function calculate_alu() {
|
||
var qty_alu = document.getElementsByName("qty_alu")[0].value.replace(/,/g, ".");
|
||
var price_alu = document.getElementsByName("price_alu")[0].value.replace(/,/g, ".");
|
||
var price_eloxal = document.getElementsByName("price_eloxal")[0].value.replace(/,/g, ".");
|
||
var weight_article = document.getElementsByName("calc_weight")[0].value * document.getElementsByName("calc_length")[0].value;
|
||
var qty_article = Math.ceil(qty_alu / weight_article);
|
||
qty_alu = qty_article * weight_article;
|
||
alu = qty_alu * price_alu;
|
||
var qty_eloxal = qty_article * document.getElementsByName("calc_length")[0].value;
|
||
eloxal = qty_eloxal * price_eloxal;
|
||
|
||
|
||
total = alu + eloxal;
|
||
alu = number_format(alu, 2, ",", ".");
|
||
eloxal = number_format(eloxal, 2, ",", ".");
|
||
total = number_format(total, 2, ",", ".");
|
||
self.document.getElementsByName("qty_alu")[0].value = qty_alu;
|
||
self.document.getElementsByName("qty_article")[0].value = qty_article;
|
||
self.document.getElementsByName("total_alu")[0].value = alu;
|
||
self.document.getElementsByName("total_eloxal")[0].value = eloxal;
|
||
self.document.getElementsByName("total")[0].value = total;
|
||
}
|
||
|
||
function alu_close() {
|
||
|
||
var qty_alu = document.getElementsByName("qty_alu")[0].value.replace(/,/g, ".");
|
||
var price_alu = document.getElementsByName("price_alu")[0].value.replace(/,/g, ".");
|
||
var price_eloxal = document.getElementsByName("price_eloxal")[0].value.replace(/,/g, ".");
|
||
var weight_article = document.getElementsByName("calc_weight")[0].value * document.getElementsByName("calc_length")[0].value;
|
||
var qty_article = Math.ceil(qty_alu / weight_article);
|
||
qty_alu = qty_article * weight_article;
|
||
alu = qty_alu * price_alu;
|
||
var qty_eloxal = qty_article * document.getElementsByName("calc_length")[0].value;
|
||
eloxal = qty_eloxal * price_eloxal;
|
||
var sellprice =
|
||
|
||
|
||
total = alu + eloxal;
|
||
var sellprice = total / qty_article
|
||
qty_alu = number_format(qty_alu, 2, ",", ".");
|
||
qty_eloxal = number_format(qty_eloxal, 2, ",", ".");
|
||
alu = number_format(alu, 2, ",", ".");
|
||
eloxal = number_format(eloxal, 2, ",", ".");
|
||
sellprice = number_format(sellprice, 2, ",", ".");
|
||
var sellprice_index = window.opener.document.getElementsByName("sellprice_" + document.getElementsByName("row")[0].value).length - 1;
|
||
|
||
|
||
var article = document.getElementsByName("description")[0].value + "\r\nAlupreisberechnung:\r\n" + qty_alu + "kg Aluminiumprofil Einzelpreis: " + document.getElementsByName("price_alu")[0].value +" Gesamt: " + alu + "\r\n" + qty_eloxal + "m Eloxal Einzelpreis: " + document.getElementsByName("price_eloxal")[0].value + " Gesamt: " + eloxal;
|
||
window.opener.document.getElementsByName("qty_" + document.getElementsByName("row")[0].value)[0].value = qty_article;
|
||
window.opener.document.getElementsByName("sellprice_" + document.getElementsByName("row")[0].value)[sellprice_index].value = sellprice;
|
||
window.opener.document.getElementsByName("description_" + document.getElementsByName("row")[0].value)[0].value = article;
|
||
self.close();
|
||
}
|
||
function /*out: String*/ number_format( /* in: float */ number,
|
||
/* in: integer */ laenge,
|
||
/* in: String */ sep,
|
||
/* in: String */ th_sep ) {
|
||
|
||
number = Math.round( number * Math.pow(10, laenge) ) / Math.pow(10, laenge);
|
||
str_number = number+"";
|
||
arr_int = str_number.split(".");
|
||
if(!arr_int[0]) arr_int[0] = "0";
|
||
if(!arr_int[1]) arr_int[1] = "";
|
||
if(arr_int[1].length < laenge){
|
||
nachkomma = arr_int[1];
|
||
for(i=arr_int[1].length+1; i <= laenge; i++){ nachkomma += "0"; }
|
||
arr_int[1] = nachkomma;
|
||
}
|
||
if(th_sep != "" && arr_int[0].length > 3){
|
||
Begriff = arr_int[0];
|
||
arr_int[0] = "";
|
||
for(j = 3; j < Begriff.length ; j+=3){
|
||
Extrakt = Begriff.slice(Begriff.length - j, Begriff.length - j + 3);
|
||
arr_int[0] = th_sep + Extrakt + arr_int[0] + "";
|
||
}
|
||
str_first = Begriff.substr(0, (Begriff.length % 3 == 0)?3:(Begriff.length % 3));
|
||
arr_int[0] = str_first + arr_int[0];
|
||
}
|
||
return arr_int[0]+sep+arr_int[1];
|
||
}
|
||
</script>
|
||
|
||
</body>
|
||
</html>
|
templates/webpages/generic/calculate_qty_de.html | ||
---|---|---|
<body <TMPL_IF NAME=onload>onload="<TMPL_VAR NAME=onload>"</TMPL_IF>>
|
||
[% USE HTML %]<body onload="[% onload %]">
|
||
|
||
<form name="Form">
|
||
|
||
<input type="hidden" name="input_name" value="<TMPL_VAR NAME=input_name ESCAPE=HTML>">
|
||
<input type="hidden" name="input_id" value="<TMPL_VAR NAME=input_id ESCAPE=HTML>">
|
||
<input type="hidden" name="input_name" value="[% HTML.escape(input_name) %]">
|
||
<input type="hidden" name="input_id" value="[% HTML.escape(input_id) %]">
|
||
|
||
<table width="100%">
|
||
<tr>
|
||
<th class="listtop"><TMPL_VAR NAME=title></th>
|
||
<th class="listtop">[% title %]</th>
|
||
</tr>
|
||
<tr height="5"></tr>
|
||
|
||
... | ... | |
|
||
<table>
|
||
<tr class="listheading">
|
||
<TMPL_LOOP NAME=HEADER>
|
||
<th nowrap class="listheading"><TMPL_VAR NAME=column_title></a></th>
|
||
</TMPL_LOOP>
|
||
[% FOREACH col = HEADER %]
|
||
<th nowrap class="listheading">[% col.column_title %]</a></th>
|
||
[% END %]
|
||
</tr>
|
||
|
||
<TMPL_LOOP NAME=VARIABLES>
|
||
<tr class="listrow<TMPL_IF NAME=__odd__>1<TMPL_ELSE>0</TMPL_IF>">
|
||
<td><TMPL_VAR NAME=description ESCAPE=HTML>:</td><td><input id="<TMPL_VAR NAME=name>" name="<TMPL_VAR NAME=name>" value=></td>
|
||
<td><TMPL_VAR NAME=unit ESCAPE=HTML></td>
|
||
[% FOREACH row = VARIABLES %]
|
||
<tr class="listrow[% loop.count % 2 %]">
|
||
<td>[% HTML.escape(row.description) %]:</td><td><input id="[% row.name %]" name="[% row.name %]" value=""></td>
|
||
<td>[% HTML.escape(row.unit) %]</td>
|
||
</tr>
|
||
</TMPL_LOOP>
|
||
[% END %]
|
||
</table>
|
||
|
||
</td>
|
||
... | ... | |
<script type="text/javascript">
|
||
<!--//
|
||
function calculate_qty() {
|
||
<TMPL_LOOP NAME=VARIABLES>
|
||
var <TMPL_VAR NAME=name> = document.getElementsByName("<TMPL_VAR NAME=name>")[0].value.replace(/,/g, ".");
|
||
</TMPL_LOOP>
|
||
var result = <TMPL_VAR NAME=formel>;
|
||
[% FOREACH row = VARIABLES %]
|
||
var [% row.name %] = document.getElementsByName("[% row.name %]")[0].value.replace(/,/g, ".");
|
||
[% END %]
|
||
var result = [% formel %];
|
||
result = number_format(result, 2, ",", ".");
|
||
window.opener.document.getElementsByName(document.Form.input_name.value)[0].value = result;
|
||
self.close();
|
templates/webpages/generic/calculate_qty_master.html | ||
---|---|---|
<body <TMPL_IF NAME=onload>onload="<TMPL_VAR NAME=onload>"</TMPL_IF>>
|
||
[% USE HTML %]<body onload="[% onload %]">
|
||
|
||
<form name="Form">
|
||
|
||
<input type="hidden" name="input_name" value="<TMPL_VAR NAME=input_name ESCAPE=HTML>">
|
||
<input type="hidden" name="input_id" value="<TMPL_VAR NAME=input_id ESCAPE=HTML>">
|
||
<input type="hidden" name="input_name" value="[% HTML.escape(input_name) %]">
|
||
<input type="hidden" name="input_id" value="[% HTML.escape(input_id) %]">
|
||
|
||
<table width="100%">
|
||
<tr>
|
||
<th class="listtop"><TMPL_VAR NAME=title></th>
|
||
<th class="listtop">[% title %]</th>
|
||
</tr>
|
||
<tr height="5"></tr>
|
||
|
||
... | ... | |
|
||
<table>
|
||
<tr class="listheading">
|
||
<TMPL_LOOP NAME=HEADER>
|
||
<th nowrap class="listheading"><TMPL_VAR NAME=column_title></a></th>
|
||
</TMPL_LOOP>
|
||
[% FOREACH col = HEADER %]
|
||
<th nowrap class="listheading">[% col.column_title %]</a></th>
|
||
[% END %]
|
||
</tr>
|
||
|
||
<TMPL_LOOP NAME=VARIABLES>
|
||
<tr class="listrow<TMPL_IF NAME=__odd__>1<TMPL_ELSE>0</TMPL_IF>">
|
||
<td><TMPL_VAR NAME=description ESCAPE=HTML>:</td><td><input id="<TMPL_VAR NAME=name>" name="<TMPL_VAR NAME=name>" value=></td>
|
||
<td><TMPL_VAR NAME=unit ESCAPE=HTML></td>
|
||
[% FOREACH row = VARIABLES %]
|
||
<tr class="listrow[% loop.count % 2 %]">
|
||
<td>[% HTML.escape(row.description) %]:</td><td><input id="[% row.name %]" name="[% row.name %]" value=""></td>
|
||
<td>[% HTML.escape(row.unit) %]</td>
|
||
</tr>
|
||
</TMPL_LOOP>
|
||
[% END %]
|
||
</table>
|
||
|
||
</td>
|
||
... | ... | |
<script type="text/javascript">
|
||
<!--//
|
||
function calculate_qty() {
|
||
<TMPL_LOOP NAME=VARIABLES>
|
||
var <TMPL_VAR NAME=name> = document.getElementsByName("<TMPL_VAR NAME=name>")[0].value.replace(/,/g, ".");
|
||
</TMPL_LOOP>
|
||
var result = <TMPL_VAR NAME=formel>;
|
||
[% FOREACH row = VARIABLES %]
|
||
var [% row.name %] = document.getElementsByName("[% row.name %]")[0].value.replace(/,/g, ".");
|
||
[% END %]
|
||
var result = [% formel %];
|
||
result = number_format(result, 2, ",", ".");
|
||
window.opener.document.getElementsByName(document.Form.input_name.value)[0].value = result;
|
||
self.close();
|
templates/webpages/generic/edit_email_de.html | ||
---|---|---|
<body onload="fokus()">
|
||
[% USE HTML %]<body onload="fokus()">
|
||
|
||
<form name="Form" method="post" action="<TMPL_VAR script>">
|
||
<form name="Form" method="post" action="[% script %]">
|
||
|
||
<table width="100%">
|
||
<tr class="listtop">
|
||
|
||
<th class="listtop"><TMPL_VAR title></th>
|
||
<th class="listtop">[% title %]</th>
|
||
</tr>
|
||
<tr height="5"></tr>
|
||
<tr>
|
||
... | ... | |
<tr>
|
||
<th align="right" nowrap>An</th>
|
||
|
||
<td><input name="email" size="30" value="<TMPL_VAR email>"></td>
|
||
<td><input name="email" size="30" value="[% HTML.escape(email) %]"></td>
|
||
</tr>
|
||
<tr>
|
||
<th align="right" nowrap>Cc</th>
|
||
<td><input name="cc" size="30" value="<TMPL_VAR cc>"></td>
|
||
<td><input name="cc" size="30" value="[% HTML.escape(cc) %]"></td>
|
||
</tr>
|
||
<TMPL_IF SHOW_BCC>
|
||
[% IF SHOW_BCC %]
|
||
<tr>
|
||
<th align="right" nowrap>Bcc</th>
|
||
<td><input name="bcc" size="30" value="<TMPL_VAR bcc>"></td>
|
||
</tr></TMPL_IF>
|
||
<td><input name="bcc" size="30" value="[% HTML.escape(bcc) %]"></td>
|
||
</tr>[% END %]
|
||
<tr>
|
||
<th align="right" nowrap>Betreff</th>
|
||
|
||
<td><input name="subject" size="30" value="<TMPL_VAR subject>"></td>
|
||
<td><input name="subject" size="30" value="[% HTML.escape(subject) %]"></td>
|
||
</tr>
|
||
<tr>
|
||
<th align="right" nowrap>Name des Anhangs</th>
|
||
<td><input name="attachment_filename" size="30" value="<TMPL_VAR a_filename>"></td>
|
||
<td><input name="attachment_filename" size="30" value="[% HTML.escape(a_filename) %]"></td>
|
||
</table>
|
||
</td>
|
||
</tr>
|
||
... | ... | |
<th align="left" nowrap>Nachricht</th>
|
||
</tr>
|
||
<tr>
|
||
<td><textarea name="message" rows="15" cols="60" wrap="soft"><TMPL_VAR message></textarea></td>
|
||
<td><textarea name="message" rows="15" cols="60" wrap="soft">[% HTML.escape(message) %]</textarea></td>
|
||
|
||
</tr>
|
||
</table>
|
||
... | ... | |
<tr>
|
||
<td>
|
||
|
||
<TMPL_VAR _print_options_>
|
||
<TMPL_LOOP HIDDEN><input type="hidden" name="<TMPL_VAR name>" value="<TMPL_VAR value ESCAPE=HTML>"></TMPL_LOOP>
|
||
[% _print_options_ %]
|
||
[% FOREACH row = HIDDEN %]<input type="hidden" name="[% row.name %]" value="[% HTML.escape(row.value) %]">
|
||
[% END %]
|
||
|
||
</td>
|
||
</tr>
|
templates/webpages/generic/edit_email_master.html | ||
---|---|---|
<body onload="fokus()">
|
||
[% USE HTML %]<body onload="fokus()">
|
||
|
||
<form name="Form" method="post" action="<TMPL_VAR script>">
|
||
<form name="Form" method="post" action="[% script %]">
|
||
|
||
<table width="100%">
|
||
<tr class="listtop">
|
||
|
||
<th class="listtop"><TMPL_VAR title></th>
|
||
<th class="listtop">[% title %]</th>
|
||
</tr>
|
||
<tr height="5"></tr>
|
||
<tr>
|
||
... | ... | |
<tr>
|
||
<th align="right" nowrap><translate>To</translate></th>
|
||
|
||
<td><input name="email" size="30" value="<TMPL_VAR email>"></td>
|
||
<td><input name="email" size="30" value="[% HTML.escape(email) %]"></td>
|
||
</tr>
|
||
<tr>
|
||
<th align="right" nowrap><translate>Cc</translate></th>
|
||
<td><input name="cc" size="30" value="<TMPL_VAR cc>"></td>
|
||
<td><input name="cc" size="30" value="[% HTML.escape(cc) %]"></td>
|
||
</tr>
|
||
<TMPL_IF SHOW_BCC>
|
||
[% IF SHOW_BCC %]
|
||
<tr>
|
||
<th align="right" nowrap><translate>Bcc</translate></th>
|
||
<td><input name="bcc" size="30" value="<TMPL_VAR bcc>"></td>
|
||
</tr></TMPL_IF>
|
||
<td><input name="bcc" size="30" value="[% HTML.escape(bcc) %]"></td>
|
||
</tr>[% END %]
|
||
<tr>
|
||
<th align="right" nowrap><translate>Subject</translate></th>
|
||
|
||
<td><input name="subject" size="30" value="<TMPL_VAR subject>"></td>
|
||
<td><input name="subject" size="30" value="[% HTML.escape(subject) %]"></td>
|
||
</tr>
|
||
<tr>
|
||
<th align="right" nowrap><translate>Attachment name</translate></th>
|
||
<td><input name="attachment_filename" size="30" value="<TMPL_VAR a_filename>"></td>
|
||
<td><input name="attachment_filename" size="30" value="[% HTML.escape(a_filename) %]"></td>
|
||
</table>
|
||
</td>
|
||
</tr>
|
||
... | ... | |
<th align="left" nowrap><translate>Message</translate></th>
|
||
</tr>
|
||
<tr>
|
||
<td><textarea name="message" rows="15" cols="60" wrap="soft"><TMPL_VAR message></textarea></td>
|
||
<td><textarea name="message" rows="15" cols="60" wrap="soft">[% HTML.escape(message) %]</textarea></td>
|
||
|
||
</tr>
|
||
</table>
|
||
... | ... | |
<tr>
|
||
<td>
|
||
|
||
<TMPL_VAR _print_options_>
|
||
<TMPL_LOOP HIDDEN><input type="hidden" name="<TMPL_VAR name>" value="<TMPL_VAR value ESCAPE=HTML>"></TMPL_LOOP>
|
||
[% _print_options_ %]
|
||
[% FOREACH row = HIDDEN %]<input type="hidden" name="[% row.name %]" value="[% HTML.escape(row.value) %]">
|
||
[% END %]
|
||
|
||
</td>
|
||
</tr>
|
templates/webpages/generic/error_de.html | ||
---|---|---|
<body>
|
||
<table width=100%>
|
||
[% USE HTML %]<body>
|
||
<table width="100%">
|
||
<tr>
|
||
<th class=listtop><TMPL_VAR NAME=title DEFAULT="Fehler!"></th>
|
||
<th class="listtop">[% IF title_error %][% title_error %][% ELSE %]Fehler![% END %]</th>
|
||
</tr>
|
||
<tr height="5"></tr>
|
||
|
||
<tr><td><TMPL_VAR NAME=label_error></td></tr>
|
||
<tr><td>[% label_error %]</td></tr>
|
||
</table>
|
||
|
||
<TMPL_VAR NAME=DEBUG>
|
||
|
||
</body>
|
||
</html>
|
templates/webpages/generic/error_master.html | ||
---|---|---|
<body>
|
||
<table width=100%>
|
||
[% USE HTML %]<body>
|
||
<table width="100%">
|
||
<tr>
|
||
<th class=listtop><TMPL_VAR NAME=title DEFAULT="<translate>Error!</translate>"></th>
|
||
<th class="listtop">[% IF title_error %][% title_error %][% ELSE %]<translate>Error!</translate>[% END %]</th>
|
||
</tr>
|
||
<tr height="5"></tr>
|
||
|
||
<tr><td><TMPL_VAR NAME=label_error></td></tr>
|
||
<tr><td>[% label_error %]</td></tr>
|
||
</table>
|
||
|
||
<TMPL_VAR NAME=DEBUG>
|
||
|
||
</body>
|
||
</html>
|
templates/webpages/generic/information_de.html | ||
---|---|---|
<body>
|
||
<table width=100%>
|
||
[% USE HTML %]<body>
|
||
<table width="100%">
|
||
<tr>
|
||
<th class=listtop><TMPL_VAR NAME=title DEFAULT="Information"></th>
|
||
<th class="listtop">[% IF title_information %][% title_information %][% ELSE %]Information[% END %]</th>
|
||
</tr>
|
||
<tr height="5"></tr>
|
||
|
||
<tr><td><TMPL_VAR NAME=label_information></td></tr>
|
||
<tr><td>[% label_information %]</td></tr>
|
||
</table>
|
||
|
||
<TMPL_VAR NAME=DEBUG>
|
||
|
||
</body>
|
||
</html>
|
templates/webpages/generic/information_master.html | ||
---|---|---|
<body>
|
||
<table width=100%>
|
||
[% USE HTML %]<body>
|
||
<table width="100%">
|
||
<tr>
|
||
<th class=listtop><TMPL_VAR NAME=title DEFAULT="<translate>Information</translate>"></th>
|
||
<th class="listtop">[% IF title_information %][% title_information %][% ELSE %]<translate>Information</translate>[% END %]</th>
|
||
</tr>
|
||
<tr height="5"></tr>
|
||
|
||
<tr><td><TMPL_VAR NAME=label_information></td></tr>
|
||
<tr><td>[% label_information %]</td></tr>
|
||
</table>
|
||
|
||
<TMPL_VAR NAME=DEBUG>
|
||
|
||
</body>
|
||
</html>
|
Auch abrufbar als: Unified diff
Umstellung einiger Vorlagen aus templates/webpages/generic von HTML::Template auf Template. Die Vorlagen calculate_alu* werden gar nicht benutzt und deswegen entfernt.