]> wagnertech.de Git - kivitendo-erp.git/commitdiff
Unterscheidung Bankeinzug/Überweisung beim Abschließen
authorMoritz Bunkus <m.bunkus@linet-services.de>
Thu, 2 Dec 2010 10:13:43 +0000 (11:13 +0100)
committerMoritz Bunkus <m.bunkus@linet-services.de>
Fri, 3 Dec 2010 11:07:43 +0000 (12:07 +0100)
bin/mozilla/sepa.pl
locale/de/all
templates/webpages/sepa/bank_transfer_mark_as_closed_step1.html

index 6cdc35f949f2bd6942c827aabeaddb071a901ae7..ba21d818b5488ccf3d128bbb8e23e1ad718513d4 100755 (executable)
@@ -499,6 +499,7 @@ sub bank_transfer_mark_as_closed_step1 {
 
   my $form       = $main::form;
   my $locale     = $main::locale;
+  my $vc         = $form->{vc} eq 'customer' ? 'customer' : 'vendor';
 
   my @export_ids = map { $_->{id} } grep { $_->{selected} } @{ $form->{exports} || [] };
 
@@ -508,7 +509,7 @@ sub bank_transfer_mark_as_closed_step1 {
 
   my @open_export_ids = ();
   foreach my $id (@export_ids) {
-    my $export = SL::SEPA->retrieve_export('id' => $id);
+    my $export = SL::SEPA->retrieve_export('id' => $id, vc => $vc);
     push @open_export_ids, $id if (!$export->{closed});
   }
 
@@ -518,11 +519,12 @@ sub bank_transfer_mark_as_closed_step1 {
 
   $form->{title} = $locale->text('Close SEPA exports');
   $form->header();
-  print $form->parse_html_template('sepa/bank_transfer_mark_as_closed_step1', { 'OPEN_EXPORT_IDS' => \@open_export_ids });
+  print $form->parse_html_template('sepa/bank_transfer_mark_as_closed_step1', { 'OPEN_EXPORT_IDS' => \@open_export_ids, vc => $vc });
 
   $main::lxdebug->leave_sub();
 }
 
+# TODO
 sub bank_transfer_mark_as_closed_step2 {
   $main::lxdebug->enter_sub();
 
index 883d661e5fb37778670bbdd2ab7a0f3a1004a39c..5e4dea0cfbd1753b129acaf7a6f73c2865ee7900 100644 (file)
@@ -556,6 +556,7 @@ $self->{texts} = {
   'Display'                     => 'Anzeigen',
   'Display file'                => 'Datei anzeigen',
   'Display options'             => 'Anzeigeoptionen',
+  'Do you really want to close the following SEPA exports? No payment will be recorded for bank collections that haven\'t been marked as executed yet.' => 'Wollen Sie wirklich die folgenden SEPA-Exporte abschließen? Für Überweisungen, die noch nicht gebucht wurden, werden dann keine Zahlungen verbucht.',
   'Do you really want to close the following SEPA exports? No payment will be recorded for bank transfers that haven\'t been marked as executed yet.' => 'Wollen Sie wirklich die folgenden SEPA-Exporte abschließen? Für Überweisungen, die noch nicht gebucht wurden, werden dann keine Zahlungen verbucht.',
   'Do you really want to delete AP transaction #1?' => 'Wollen Sie wirklich die Kreditorenbuchung #1 löschen?',
   'Do you really want to delete AR transaction #1?' => 'Wollen Sie wirklich die Debitorenbuchung #1 löschen?',
index 4d1a6dcf2807bbd04b38b47230ba00e250bbc32e..063b4eec42a4e5a244548fdbe72497ce23ff66cc 100644 (file)
@@ -6,7 +6,11 @@
 
  <form action="sepa.pl" method="post">
   <p>
-   [%- 'Do you really want to close the following SEPA exports? No payment will be recorded for bank transfers that haven\'t been marked as executed yet.' | $T8 %]
+   [%- IF vc == 'vendor' %]
+    [%- 'Do you really want to close the following SEPA exports? No payment will be recorded for bank transfers that haven\'t been marked as executed yet.' | $T8 %]
+   [%- ELSE %]
+    [%- 'Do you really want to close the following SEPA exports? No payment will be recorded for bank collections that haven\'t been marked as executed yet.' | $T8 %]
+   [%- END %]
   </p>
 
   <p>
@@ -14,7 +18,7 @@
    [%- FOREACH id = OPEN_EXPORT_IDS %]
     [%- UNLESS loop.first %], [%- END %]
     <input type="hidden" name="open_export_ids[]" value="[% HTML.escape(id) %]">
-    <a href="sepa.pl?action=bank_transfer_edit&id=[% HTML.url(id) %]">[% HTML.escape(id) %]</a>
+    <a href="sepa.pl?action=bank_transfer_edit&id=[% HTML.url(id) %]&vc=[% HTML.url(vc) %]">[% HTML.escape(id) %]</a>
    [%- END %]
   </p>
 
@@ -24,6 +28,7 @@
   </p>
 
   <input type="hidden" name="action" value="dispatcher">
+  <input type="hidden" name="vc" value="[%- HTML.escape(vc) %]">
  </form>
 
 </body>