Fixed Bug 436: Radierparagraph: Loeschen am gleichen Tag erlauben
authorPhilip Reetz <p.reetz@linet-services.de>
Tue, 12 Dec 2006 09:06:48 +0000 (09:06 +0000)
committerPhilip Reetz <p.reetz@linet-services.de>
Tue, 12 Dec 2006 09:06:48 +0000 (09:06 +0000)
SL/IR.pm
SL/IS.pm
bin/mozilla/ir.pl
bin/mozilla/is.pl
locale/de/ir
locale/de/is

index c847781..77df806 100644 (file)
--- a/SL/IR.pm
+++ b/SL/IR.pm
@@ -841,7 +841,7 @@ sub retrieve_invoice {
 
     # retrieve invoice
     $query = qq|SELECT a.cp_id, a.invnumber, a.transdate AS invdate, a.duedate,
-                a.ordnumber, a.quonumber, a.paid, a.taxincluded, a.notes, a.taxzone_id, a.storno,
+                a.ordnumber, a.quonumber, a.paid, a.taxincluded, a.notes, a.taxzone_id, a.storno, a.gldate,
                a.intnotes, a.curr AS currency
                FROM ap a
                WHERE a.id = $form->{id}|;
index ba1062b..7df695e 100644 (file)
--- a/SL/IS.pm
+++ b/SL/IS.pm
@@ -1472,7 +1472,7 @@ sub retrieve_invoice {
 
     # retrieve invoice
     $query = qq|SELECT a.invnumber, a.ordnumber, a.quonumber, a.cusordnumber,
-                a.transdate AS invdate, a.deliverydate, a.paid, a.storno,
+                a.transdate AS invdate, a.deliverydate, a.paid, a.storno, a.gldate,
                 a.shippingpoint, a.shipvia, a.terms, a.notes, a.intnotes, a.taxzone_id,
                a.duedate, a.taxincluded, a.curr AS currency, a.shipto_id, a.cp_id,
                a.employee_id, e.name AS employee, a.payment_id, a.language_id, a.delivery_customer_id, a.delivery_vendor_id, a.type
index 11cab57..03f377d 100644 (file)
@@ -224,6 +224,9 @@ sub form_header {
       s/option>\Q$form->{$item}\E/option selected>$form->{$item}/;
   }
 
+  $form->{radier} =
+    ($form->current_date(\%myconfig) eq $form->{gldate}) ? 1 : 0;
+
   #quote selectvendor Bug 133
   $form->{"selectvendor"} = $form->quote($form->{"selectvendor"});
 
@@ -743,7 +746,12 @@ sub form_footer {
     print qq|<input class=submit type=submit name=action value="|
       . $locale->text('Storno') . qq|">
 | unless ($form->{storno});
-
+    if ($form->{radier}) {
+    print qq|
+    <input class=submit type=submit name=action value="|
+      . $locale->text('Delete') . qq|">
+|;
+  }
   } else {
     if ($invdate > $closedto) {
       print qq|<input class=submit type=submit name=action value="|
index 110beee..857e604 100644 (file)
@@ -311,6 +311,9 @@ sub form_header {
     }
   }
 
+  $form->{radier} =
+    ($form->current_date(\%myconfig) eq $form->{gldate}) ? 1 : 0;
+
   $payment = qq|<option value=""></option>|;
   foreach $item (@{ $form->{payment_terms} }) {
     if ($form->{payment_id} eq $item->{id}) {
@@ -443,13 +446,11 @@ sub form_header {
   $exchangerate .= qq|
 <input type=hidden name=forex value=$form->{forex}>
 |;
-  print(STDERR "$form->{customer} Kunde\n");
 
   $customer =
     ($form->{selectcustomer})
     ? qq|<select name=customer>$form->{selectcustomer}</select>\n<input type=hidden name="selectcustomer" value="$form->{selectcustomer}">|
     : qq|<input name=customer value="$form->{customer}" size=35>|;
-  print(STDERR "$form->{customer} Kunde\n");
 
   #sk
   $contact =
@@ -1096,6 +1097,12 @@ if ($form->{type} eq "credit_note") {
       . $locale->text('Credit Note') . qq|">
 |;
   }
+    if ($form->{radier}) {
+    print qq|
+    <input class=submit type=submit name=action value="|
+      . $locale->text('Delete') . qq|">
+|;
+  }
 
 
     if ($invdate > $closedto) {
index e13808a..732a948 100644 (file)
@@ -45,6 +45,7 @@ $self->{texts} = {
   'Date'                        => 'Datum',
   'Dec'                         => 'Dez',
   'December'                    => 'Dezember',
+  'Delete'                      => 'Löschen',
   'Delivery Date'               => 'Lieferdatum',
   'Department'                  => 'Abteilung',
   'Description'                 => 'Beschreibung',
@@ -224,6 +225,7 @@ $self->{subs} = {
   'vendor_invoice'              => 'vendor_invoice',
   'yes'                         => 'yes',
   'weiter'                      => 'continue',
+  'löschen'                     => 'delete',
   'buchen'                      => 'post',
   'zahlung_buchen'              => 'post_payment',
   'storno'                      => 'storno',
index 00d832e..9835f47 100644 (file)
@@ -56,6 +56,7 @@ $self->{texts} = {
   'Date'                        => 'Datum',
   'Dec'                         => 'Dez',
   'December'                    => 'Dezember',
+  'Delete'                      => 'Löschen',
   'Delivery Date'               => 'Lieferdatum',
   'Department'                  => 'Abteilung',
   'Description'                 => 'Beschreibung',
@@ -253,6 +254,7 @@ $self->{subs} = {
   'yes'                         => 'yes',
   'weiter'                      => 'continue',
   'gutschrift'                  => 'credit_note',
+  'löschen'                     => 'delete',
   'email'                       => 'e_mail',
   'auftrag'                     => 'order',
   'buchen'                      => 'post',