X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;ds=sidebyside;f=bin%2Fmozilla%2Foe.pl;h=f7a52e979f42cd078e6a21dc6d9a29c576511d69;hb=7743b3ab885b485ae317338c55da427b62ab457d;hp=9bfc86ca70f09b9953ef71a4e14beae2c59e706c;hpb=c108773fd77dde3a483a96422327215056a7eaf2;p=kivitendo-erp.git
diff --git a/bin/mozilla/oe.pl b/bin/mozilla/oe.pl
index 9bfc86ca7..f7a52e979 100644
--- a/bin/mozilla/oe.pl
+++ b/bin/mozilla/oe.pl
@@ -284,7 +284,6 @@ sub order_links {
sub prepare_order {
$lxdebug->enter_sub();
- $form->{media} = "screen";
$form->{formname} = $form->{type} unless $form->{formname};
my $i = 0;
@@ -328,8 +327,8 @@ sub prepare_order {
sub form_header {
$lxdebug->enter_sub();
- $checkedopen = ($form->{closed}) ? "" : "checked";
- $checkedclosed = ($form->{closed}) ? "checked" : "";
+ my $checkedclosed = $form->{"closed"} ? "checked" : "";
+ my $checkeddelivered = $form->{"delivered"} ? "checked" : "";
map { $form->{$_} =~ s/\"/"/g }
qw(ordnumber quonumber shippingpoint shipvia notes intnotes shiptoname
@@ -380,15 +379,20 @@ sub form_header {
$openclosed = qq|
-
- |
+
+
+|;
+
+ if (($form->{"type"} eq "sales_order") ||
+ ($form->{"type"} eq "purchase_order")) {
+ $openclosed .= qq|
+
+
+|;
+ }
+
+ $openclosed .= qq|
+
|;
}
@@ -432,11 +436,12 @@ sub form_header {
"";
} else {
$form->{selectshipto} .=
- "";
+ "";
}
}
} else {
+ $form->{selectshipto} = $form->unquote($form->{selectshipto});
$form->{selectshipto} =~ s/ selected//g;
if ($form->{shipto_id} ne "") {
$form->{selectshipto} =~ s/value=$form->{shipto_id}/value=$form->{shipto_id} selected/;
@@ -445,9 +450,9 @@ sub form_header {
$shipto = qq|
| . $locale->text('Shipping Address') . qq| |
- |
- |;
-
+ | |;
+ $form->{selectshipto} = $form->quote($form->{selectshipto});
+ $shipto .= qq| |;
@@ -493,8 +498,7 @@ sub form_header {
$vclabel = ucfirst $form->{vc};
$vclabel = $locale->text($vclabel);
- $terms = qq||;
+
if ($form->{business}) {
$business = qq|
@@ -595,7 +599,7 @@ sub form_header {
$form->{creditlimit} |
|
| . $locale->text('Remaining') . qq| |
- $form->{creditremaining} |
+ $form->{creditremaining} |
@@ -625,7 +629,6 @@ sub form_header {
|;
- $terms = "";
}
$ordnumber .= qq|
@@ -699,6 +702,8 @@ sub form_header {
$onload = qq|alert('$credittext')|;
}
+ $form->{"javascript"} .= qq||;
+
$form->header;
print qq|
@@ -802,7 +807,6 @@ print qq|
$openclosed
$employee
$ordnumber
- $terms
@@ -1029,7 +1033,7 @@ sub form_footer {
| . $locale->text("Edit the $form->{type}") . qq|
-text('Update') . qq|">
@@ -1102,11 +1106,6 @@ sub form_footer {
|;
}
- if ($form->{menubar}) {
- require "$form->{path}/menu.pl";
- &menubar;
- }
-
print qq|
{rowcount}>
@@ -1388,6 +1387,19 @@ sub search {
|;
}
+ my $delivered;
+ if (($form->{"type"} eq "sales_order") ||
+ ($form->{"type"} eq "purchase_order")) {
+ $delivered = qq|
+
+
+ |
+
+ |
+
+|;
+ }
+
# use JavaScript Calendar or not
$form->{jsscript} = $jscalendar;
$jsscript = "";
@@ -1455,6 +1467,7 @@ sub search {
$openclosed
+ $delivered
| . $locale->text('ID') . qq| |
@@ -1530,7 +1543,7 @@ sub orders {
# construct href
$href =
- "$form->{script}?path=$form->{path}&action=orders&type=$form->{type}&vc=$form->{vc}&login=$form->{login}&password=$form->{password}&transdatefrom=$form->{transdatefrom}&transdateto=$form->{transdateto}&open=$form->{open}&closed=$form->{closed}&$ordnumber=$number&$form->{vc}=$name&department=$department&warehouse=$warehouse";
+ "$form->{script}?path=$form->{path}&action=orders&type=$form->{type}&vc=$form->{vc}&login=$form->{login}&password=$form->{password}&transdatefrom=$form->{transdatefrom}&transdateto=$form->{transdateto}&open=$form->{open}&closed=$form->{closed}¬delivered=$form->{notdelivered}&delivered=$form->{delivered}&$ordnumber=$number&$form->{vc}=$name&department=$department&warehouse=$warehouse";
# construct callback
$number = $form->escape($form->{$ordnumber}, 1);
@@ -1539,17 +1552,20 @@ sub orders {
$warehouse = $form->escape($form->{warehouse}, 1);
$callback =
- "$form->{script}?path=$form->{path}&action=orders&type=$form->{type}&vc=$form->{vc}&login=$form->{login}&password=$form->{password}&transdatefrom=$form->{transdatefrom}&transdateto=$form->{transdateto}&open=$form->{open}&closed=$form->{closed}&$ordnumber=$number&$form->{vc}=$name&department=$department&warehouse=$warehouse";
+ "$form->{script}?path=$form->{path}&action=orders&type=$form->{type}&vc=$form->{vc}&login=$form->{login}&password=$form->{password}&transdatefrom=$form->{transdatefrom}&transdateto=$form->{transdateto}&open=$form->{open}&closed=$form->{closed}¬delivered=$form->{notdelivered}&delivered=$form->{delivered}&$ordnumber=$number&$form->{vc}=$name&department=$department&warehouse=$warehouse";
@columns =
$form->sort_columns("transdate", "reqdate", "id", "$ordnumber",
"name", "netamount", "tax", "amount",
"curr", "employee", "shipvia", "open",
- "closed");
+ "closed", "delivered");
$form->{l_open} = $form->{l_closed} = "Y"
if ($form->{open} && $form->{closed});
+ $form->{"l_delivered"} = "Y"
+ if ($form->{"delivered"} && $form->{"notdelivered"});
+
foreach $item (@columns) {
if ($form->{"l_$item"} eq "Y") {
push @column_index, $item;
@@ -1635,6 +1651,8 @@ sub orders {
qq|| . $locale->text('O') . qq| | |;
$column_header{closed} =
qq|| . $locale->text('C') . qq| | |;
+ $column_header{"delivered"} =
+ qq|| . $locale->text("Delivered") . qq| | |;
$column_header{employee} =
qq|$employee | |;
@@ -1762,6 +1780,9 @@ sub orders {
$column_data{closed} = " | ";
$column_data{open} = "X | ";
}
+ $column_data{"delivered"} = "" .
+ ($oe->{"delivered"} ? $locale->text("Yes") : $locale->text("No")) .
+ " | ";
$i++;
$i %= 2;
@@ -1848,11 +1869,6 @@ sub orders {
. $locale->text('Add') . qq|">|;
}
- if ($form->{menubar}) {
- require "$form->{path}/menu.pl";
- &menubar;
- }
-
print qq|
@@ -2124,10 +2140,12 @@ sub invoice {
# also copy deliverydate from the order
$form->{deliverydate} = $form->{reqdate} if $form->{reqdate};
+ $form->{orddate} = $form->{transdate};
} else {
$form->isblank("quonumber", $locale->text('Quotation Number missing!'));
$form->isblank("transdate", $locale->text('Quotation Date missing!'));
$form->{ordnumber} = "";
+ $form->{quodate} = $form->{transdate};
}
# if the name changed get new values
@@ -2841,14 +2859,6 @@ sub display_ship_receive {
-|;
-
- if ($form->{menubar}) {
- require "$form->{path}/menu.pl";
- &menubar;
- }
-
- print qq|
{rowcount}>
@@ -3120,14 +3130,8 @@ sub list_transfer {
{password}>
|;
+ . $locale->text('Transfer') . qq|">
- if ($form->{menubar}) {
- require "$form->{path}/menu.pl";
- &menubar;
- }
-
- print qq|
|