Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision b8916e5c

Von Sven Schöling vor etwa 15 Jahren hinzugefügt

  • ID b8916e5c2982dd12e0a612252c85f5e1648e162c
  • Vorgänger b65cc47a
  • Nachfolger 7130d91e

is_templates: form_footer erste Version

Unterschiede anzeigen:

bin/mozilla/is.pl
173 173
  $form->{selectcustomer} = 1;
174 174

  
175 175
  # departments
176
  if ($form->{all_departments}) {
177
    $form->{selectdepartment} = "<option>\n";
178
    $form->{department}       = "$form->{department}--$form->{department_id}";
179

  
180
    map {
181
      $form->{selectdepartment} .=
182
        "<option>$_->{description}--$_->{id}</option>\n"
183
    } (@{ $form->{all_departments} });
184
  }
176
#  if ($form->{all_departments}) {
177
#    $form->{selectdepartment} = "<option>\n";
178
#    $form->{department}       = "$form->{department}--$form->{department_id}";
179
#
180
#    map {
181
#      $form->{selectdepartment} .= "<option>$_->{description}--$_->{id}</option>\n"
182
#    } @{ $form->{all_departments} };
183
#  }
185 184

  
186 185
  $form->{employee} = "$form->{employee}--$form->{employee_id}";
187 186

  
......
191 190

  
192 191
  foreach my $key (keys %{ $form->{AR_links} }) {
193 192
    foreach my $ref (@{ $form->{AR_links}{$key} }) {
194
      $form->{"select$key"} .=
195
"<option>$ref->{accno}--$ref->{description}</option>\n";
193
      $form->{"select$key"} .= "<option>$ref->{accno}--$ref->{description}</option>\n";
196 194
    }
197 195

  
198 196
    if ($key eq "AR_paid") {
199 197
      next unless $form->{acc_trans}{$key};
200 198
      for my $i (1 .. scalar @{ $form->{acc_trans}{$key} }) {
201
        $form->{"AR_paid_$i"} =
202
          "$form->{acc_trans}{$key}->[$i-1]->{accno}--$form->{acc_trans}{$key}->[$i-1]->{description}";
199
        $form->{"AR_paid_$i"}      = "$form->{acc_trans}{$key}->[$i-1]->{accno}--$form->{acc_trans}{$key}->[$i-1]->{description}";
203 200

  
204 201
        # reverse paid
205
        $form->{"paid_$i"} = $form->{acc_trans}{$key}->[$i - 1]->{amount} * -1;
206
        $form->{"datepaid_$i"} =
207
          $form->{acc_trans}{$key}->[$i - 1]->{transdate};
208
        $form->{"forex_$i"} = $form->{"exchangerate_$i"} =
209
          $form->{acc_trans}{$key}->[$i - 1]->{exchangerate};
210
        $form->{"source_$i"} = $form->{acc_trans}{$key}->[$i - 1]->{source};
211
        $form->{"memo_$i"}   = $form->{acc_trans}{$key}->[$i - 1]->{memo};
202
        $form->{"paid_$i"}         = $form->{acc_trans}{$key}->[$i - 1]->{amount} * -1;
203
        $form->{"datepaid_$i"}     = $form->{acc_trans}{$key}->[$i - 1]->{transdate};
204
        $form->{"exchangerate_$i"} = $form->{acc_trans}{$key}->[$i - 1]->{exchangerate};
205
        $form->{"forex_$i"}        = $form->{"exchangerate_$i"};
206
        $form->{"source_$i"}       = $form->{acc_trans}{$key}->[$i - 1]->{source};
207
        $form->{"memo_$i"}         = $form->{acc_trans}{$key}->[$i - 1]->{memo};
212 208

  
213 209
        $form->{paidaccounts} = $i;
214 210
      }
215 211
    } else {
216
      $form->{$key} =
217
        "$form->{acc_trans}{$key}->[0]->{accno}--$form->{acc_trans}{$key}->[0]->{description}";
212
      $form->{$key} = "$form->{acc_trans}{$key}->[0]->{accno}--$form->{acc_trans}{$key}->[0]->{description}";
218 213
    }
219

  
220 214
  }
221 215

  
222 216
  $form->{paidaccounts} = 1 unless (exists $form->{paidaccounts});
223 217

  
224 218
  $form->{AR} = $form->{AR_1} unless $form->{id};
225 219

  
226
  $form->{locked} =
227
    ($form->datetonum($form->{invdate}, \%myconfig) <=
228
     $form->datetonum($form->{closedto}, \%myconfig));
220
  $form->{locked} = ($form->datetonum($form->{invdate},  \%myconfig)
221
                  <= $form->datetonum($form->{closedto}, \%myconfig));
229 222

  
230 223
  $main::lxdebug->leave_sub();
231 224
}
......
399 392
  $form->{invtotal} = $form->{invsubtotal};
400 393

  
401 394
  my ($rows, $introws);
402
  if (($rows = $form->numtextrows($form->{notes}, 26, 8)) < 2) {
403
    $rows = 2;
404
  }
405
  if (($introws = $form->numtextrows($form->{intnotes}, 35, 8)) < 2) {
406
    $introws = 2;
407
  }
408
  $rows = ($rows > $introws) ? $rows : $introws;
409
  my $notes = qq|<textarea name="notes" rows="$rows" cols="26" wrap="soft">$form->{notes}</textarea>|;
410
  my $intnotes = qq|<textarea name="intnotes" rows="$rows" cols="35" wrap="soft">$form->{intnotes}</textarea>|;
411

  
412
  $form->{taxincluded} = ($form->{taxincluded} ? "checked" : "");
413

  
414
  my $taxincluded = "";
415
  if ($form->{taxaccounts}) {
416
    $taxincluded = qq| <input name="taxincluded" class="checkbox" type="checkbox" $form->{taxincluded}> <b>| . $locale->text('Tax Included') . qq|</b><br><br>|;
417
  }
395
  if (($rows    = $form->numtextrows($form->{notes}, 26, 8)) < 2)    { $rows    = 2; }
396
  if (($introws = $form->numtextrows($form->{intnotes}, 35, 8)) < 2) { $introws = 2; }
397
  $form->{rows} = ($rows > $introws) ? $rows : $introws;
418 398

  
419 399
  my ($tax, $subtotal);
420 400
  if (!$form->{taxincluded}) {
......
429 409
	      <tr>
430 410
                <th align="right">$form->{"${item}_description"}&nbsp;| . $form->{"${item}_rate"} * 100 .qq|%</th>
431 411
                <td align="right">$form->{"${item}_total"}</td>
432
	      </tr>
433
|;
412
	      </tr> |;
434 413
      }
435 414
    }
436 415

  
437
    $form->{invsubtotal} = $form->format_amount(\%myconfig, $form->{invsubtotal}, 2, 0);
416
#    $form->{invsubtotal} = $form->format_amount(\%myconfig, $form->{invsubtotal}, 2, 0);
438 417

  
439 418
    $subtotal = qq|
440 419
	      <tr>
......
446 425
  }
447 426

  
448 427
  if ($form->{taxincluded}) {
428
    $form->{taxaccounts_array} = [ split / /, $form->{taxaccounts} ];
449 429
    foreach my $item (split / /, $form->{taxaccounts}) {
450 430
      if ($form->{"${item}_base"}) {
451 431
        $form->{"${item}_total"} = $form->round_amount( ($form->{"${item}_base"} * $form->{"${item}_rate"} / (1 + $form->{"${item}_rate"})), 2);
......
453 433
        $form->{"${item}_total"} = $form->format_amount(\%myconfig, $form->{"${item}_total"}, 2);
454 434
        $form->{"${item}_netto"} = $form->format_amount(\%myconfig, $form->{"${item}_netto"}, 2);
455 435

  
456
        $tax .= qq|
457
	      <tr>
458
		<th align="right">Enthaltene $form->{"${item}_description"}&nbsp;|
459
		                    . $form->{"${item}_rate"} * 100 .qq|%</th>
460
		<td align="right">$form->{"${item}_total"}</td>
461
	      </tr>
462
	      <tr>
463
	        <th align="right">Nettobetrag</th>
464
		<td align="right">$form->{"${item}_netto"}</td>
465
	      </tr>
466
|;
436
#        $tax .= qq|
437
#	      <tr>
438
#		<th align="right">Enthaltene $form->{"${item}_description"}&nbsp;|
439
#		                    . $form->{"${item}_rate"} * 100 .qq|%</th>
440
#		<td align="right">$form->{"${item}_total"}</td>
441
#	      </tr>
442
#	      <tr>
443
#	        <th align="right">Nettobetrag</th>
444
#		<td align="right">$form->{"${item}_netto"}</td>
445
#	      </tr>
446
#|;
467 447
      }
468 448
    }
469 449

  
470 450
  }
471 451

  
472 452
  $form->{oldinvtotal} = $form->{invtotal};
473
  $form->{invtotal}    = $form->format_amount(\%myconfig, $form->{invtotal}, 2, 0);
453
#  $form->{invtotal}    = $form->format_amount(\%myconfig, $form->{invtotal}, 2, 0);
474 454

  
475
  my $follow_ups_block;
455
  # unfortunately locales doesn't support extended syntax
476 456
  if ($form->{id}) {
477 457
    my $follow_ups = FU->follow_ups('trans_id' => $form->{id});
478

  
479 458
    if (@{ $follow_ups} ) {
480
      my $num_due       = sum map { $_->{due} * 1 } @{ $follow_ups };
481
      $follow_ups_block = qq|
482
      <tr>
483
        <td colspan="2">| . $locale->text("There are #1 unfinished follow-ups of which #2 are due.", scalar @{ $follow_ups }, $num_due) . qq|</td>
484
      </tr>
485
|;
486
    }
487
  }
488

  
489
  print qq|
490
  <tr>
491
    <td>
492
      <table width="100%">
493
	<tr valign="bottom">
494
	  <td>
495
	    <table>
496
	      <tr>
497
		<th align="left">| . $locale->text('Notes') . qq|</th>
498
		<th align="left">| . $locale->text('Internal Notes') . qq|</th>
499
                <th align="right">| . $locale->text('Payment Terms') . qq|</th>
500
	      </tr>
501
	      <tr valign="top">
502
		<td>$notes</td>
503
		<td>$intnotes</td>
504
                <td><select name="payment_id" onChange="if (this.value) set_duedate(['payment_id__' + this.value, 'invdate__' + invdate.value],['duedate'])">$payment
505
                </select></td>
506
	      </tr>
507
        $follow_ups_block
508
	    </table>
509
	  </td>
510
          <td>
511
            <table>
512
            <tr>
513
              <th  align=left>| . $locale->text('Ertrag') . qq|</th>
514
              <td>| .  $form->format_amount(\%myconfig, $form->{marge_total}, 2, 0) . qq|</td>
515
            </tr>
516
            <tr>
517
              <th  align=left>| . $locale->text('Ertrag prozentual') . qq|</th>
518
              <td>| .  $form->format_amount(\%myconfig, $form->{marge_percent}, 2, 0) . qq| %</td>
519
            </tr>
520
            <input type=hidden name="marge_total" value="$form->{"marge_total"}">
521
            <input type=hidden name="marge_percent" value="$form->{"marge_percent"}">
522
            </table>
523
          </td>
524
	  <td align="right">
525
	    $taxincluded
526
	    <table>
527
	      $subtotal
528
	      $tax
529
	      <tr>
530
		<th align="right">| . $locale->text('Total') . qq|</th>
531
		<td align="right">$form->{invtotal}</td>
532
	      </tr>
533
	    </table>
534
	  </td>
535
	</tr>
536
      </table>
537
    </td>
538
  </tr>
539
|;
540
  my $webdav_list;
541
  if ($main::webdav) {
542
    $webdav_list = qq|
543
  <tr>
544
    <td><hr size="3" noshade></td>
545
  </tr>
546
  <tr>
547
    <th class="listtop" align="left">Dokumente im Webdav-Repository</th>
548
  </tr>
549
    <table width="100%">
550
      <td align="left" width="30%"><b>Dateiname</b></td>
551
      <td align="left" width="70%"><b>Webdavlink</b></td>
552
|;
553
    foreach my $file (@{ $form->{WEBDAV} }) {
554
      $webdav_list .= qq|
555
      <tr>
556
        <td align="left">$file->{name}</td>
557
        <td align="left"><a href="$file->{link}">$file->{type}</a></td>
558
      </tr>
559
|;
459
      $form->{follow_ups_text} = $locale->text("There are #1 unfinished follow-ups of which #2 are due.",
460
                                               scalar @{ $follow_ups },
461
                                               sum map { $_->{due} * 1 } @{ $follow_ups });
560 462
    }
561
    $webdav_list .= qq|
562
    </table>
563
  </tr>
564
|;
565

  
566
    print $webdav_list;
567 463
  }
568
if ($form->{type} eq "credit_note") {
569
  print qq|
570
  <tr>
571
    <td>
572
      <table width="100%">
573
	<tr class="listheading">
574
	  <th colspan="6" class="listheading">|
575
    . $locale->text('Payments') . qq|</th>
576
	</tr>
577
|;
578
} else {
579
  print qq|
580
  <tr>
581
    <td>
582
      <table width="100%">
583
	<tr class="listheading">
584
	  <th colspan="6" class="listheading">|
585
    . $locale->text('Incoming Payments') . qq|</th>
586
	</tr>
587
|;
588
}
589 464

  
590
  my @column_index;
591
  if ($form->{currency} eq $form->{defaultcurrency}) {
592
    @column_index = qw(datepaid source memo paid AR_paid);
593
  } else {
594
    @column_index = qw(datepaid source memo paid exchangerate AR_paid);
595
  }
596

  
597
  my %column_data;
598
  $column_data{datepaid}     = "<th>" . $locale->text('Date') . "</th>";
599
  $column_data{paid}         = "<th>" . $locale->text('Amount') . "</th>";
600
  $column_data{exchangerate} = "<th>" . $locale->text('Exch') . "</th>";
601
  $column_data{AR_paid}      = "<th>" . $locale->text('Account') . "</th>";
602
  $column_data{source}       = "<th>" . $locale->text('Source') . "</th>";
603
  $column_data{memo}         = "<th>" . $locale->text('Memo') . "</th>";
604

  
605
  print "
606
	<tr>
607
";
608
  map { print "$column_data{$_}\n" } @column_index;
609
  print "
610
        </tr>
611
";
612

  
613
  my @triggers  = ();
614
  my $totalpaid = 0;
615

  
616
  $form->{paidaccounts}++ if ($form->{"paid_$form->{paidaccounts}"});
617
  for my $i (1 .. $form->{paidaccounts}) {
618 465

  
619
    print "
620
        <tr>\n";
621

  
622
    $form->{"selectAR_paid_$i"} = $form->{selectAR_paid};
623
    $form->{"selectAR_paid_$i"} =~
624
      s/option>\Q$form->{"AR_paid_$i"}\E/option selected>$form->{"AR_paid_$i"}/;
625

  
626
    # format amounts
627
    $totalpaid += $form->{"paid_$i"};
628
    if ($form->{"paid_$i"}) {
629
      $form->{"paid_$i"} = $form->format_amount(\%myconfig, $form->{"paid_$i"}, 2);
630
    }
631
    $form->{"exchangerate_$i"} = $form->format_amount(\%myconfig, $form->{"exchangerate_$i"});
632

  
633
    if ($form->{"exchangerate_$i"} == 0) {
634
      $form->{"exchangerate_$i"} = "";
635
    }
636
    my $exchangerate = qq|&nbsp;|;
637
    if ($form->{currency} ne $form->{defaultcurrency}) {
638
      if ($form->{"forex_$i"}) {
639
        $exchangerate = qq|<input type="hidden" name="exchangerate_$i" value="$form->{"exchangerate_$i"}">$form->{"exchangerate_$i"}|;
640
      } else {
641
        $exchangerate = qq|<input name="exchangerate_$i" size="10" value="$form->{"exchangerate_$i"}">|;
642
      }
643
    }
644

  
645
    $exchangerate .= qq|<input type="hidden" name="forex_$i" value="$form->{"forex_$i"}">|;
646

  
647
    $column_data{"paid_$i"} =
648
      qq|<td align="center"><input name="paid_$i" size="11" value="$form->{"paid_$i"}" onBlur=\"check_right_number_format(this)\"></td>|;
649
    $column_data{"exchangerate_$i"} = qq|<td align="center">$exchangerate</td>|;
650
    $column_data{"AR_paid_$i"}      =
651
      qq|<td align="center"><select name="AR_paid_$i">$form->{"selectAR_paid_$i"}</select></td>|;
652
    $column_data{"datepaid_$i"} =
653
      qq|<td align="center"><input id="datepaid_$i" name="datepaid_$i"  size="11" title="$myconfig{dateformat}" value="$form->{"datepaid_$i"}" onBlur=\"check_right_date_format(this)\">
654
         <input type="button" name="datepaid_$i" id="trigger_datepaid_$i" value="?"></td>|;
655
    $column_data{"source_$i"} =
656
      qq|<td align=center><input name="source_$i" size="11" value="$form->{"source_$i"}"></td>|;
657
    $column_data{"memo_$i"} =
658
      qq|<td align="center"><input name="memo_$i" size="11" value="$form->{"memo_$i"}"></td>|;
659

  
660
    map { print qq|$column_data{"${_}_$i"}\n| } @column_index;
661
    print "
662
        </tr>\n";
663
    push(@triggers, "datepaid_$i", "BL", "trigger_datepaid_$i");
664
  }
665

  
666
  my $paid_missing = $form->{oldinvtotal} - $totalpaid;
667

  
668
  print qq|
669
    <tr>
670
      <td></td>
671
      <td></td>
672
      <td align="center">| . $locale->text('Total') . qq|</td>
673
      <td align="center">| . H($form->format_amount(\%myconfig, $totalpaid, 2)) . qq|</td>
674
    </tr>
675
    <tr>
676
      <td></td>
677
      <td></td>
678
      <td align="center">| . $locale->text('Missing amount') . qq|</td>
679
      <td align="center">| . H($form->format_amount(\%myconfig, $paid_missing, 2)) . qq|</td>
680
    </tr>
681
|;
682

  
683
  map({ print($cgi->hidden("-name" => $_, "-value" => $form->{$_})); } qw(paidaccounts selectAR_paid oldinvtotal));
684
  print qq|<input type="hidden" name="oldtotalpaid" value="$totalpaid">
685
    </table>
686
    </td>
687
  </tr>
688
  <tr>
689
    <td><hr size="3" noshade></td>
690
  </tr>
691
  <tr>
692
    <td>
693
|;
694

  
695
  print_options();
696

  
697
  print qq|
698
    </td>
699
  </tr>
700
</table>
701
|;
702

  
703
  my $invdate  = $form->datetonum($form->{invdate},  \%myconfig);
704
  my $closedto = $form->datetonum($form->{closedto}, \%myconfig);
705

  
706
  if ($form->{id}) {
707
    my $show_storno = !$form->{storno} && !IS->has_storno(\%myconfig, $form, "ar") && (($totalpaid == 0) || ($totalpaid eq ""));
708

  
709
    print qq|
710
    <input class="submit" type="submit" accesskey="u" name="action" id="update_button" value="| . $locale->text('Update') . qq|">
711
    <input class="submit" type="submit" name="action" value="| . $locale->text('Ship to') . qq|">
712
    <input class="submit" type="submit" name="action" value="| . $locale->text('Print') . qq|">
713
    <input class="submit" type="submit" name="action" value="| . $locale->text('E-mail') . qq|"> |;
714
    print qq|<input class="submit" type="submit" name="action" value="| . $locale->text('Storno') . qq|"> | if ($show_storno);
715
    print qq|<input class="submit" type="submit" name="action" value="| . $locale->text('Post Payment') . qq|"> |;
716
    print qq|<input class="submit" type="submit" name="action" value="| . $locale->text('Use As Template') . qq|"> |;
717
    if ($form->{id} && !($form->{type} eq "credit_note")) {
718
      print qq| <input class="submit" type="submit" name="action" value="| . $locale->text('Credit Note') . qq|"> |;
719
    }
720
    if ($form->{radier}) {
721
      print qq| <input class="submit" type="submit" name="action" value="| . $locale->text('Delete') . qq|"> |;
722
    }
723

  
724

  
725
    if ($invdate > $closedto) {
726
      print qq| <input class="submit" type="submit" name="action" value="| . $locale->text('Order') . qq|"> |;
727
    }
728

  
729
    print qq| <input type="button" class="submit" onclick="follow_up_window()" value="| . $locale->text('Follow-Up') . qq|">|;
730

  
731
  } else {
732
    if ($invdate > $closedto) {
733
      print qq|
734
      <input class="submit" type="submit" name="action" id="update_button" value="| . $locale->text('Update') . qq|">
735
      <input class="submit" type="submit" name="action" value="| . $locale->text('Ship to') . qq|">
736
      <input class="submit" type="submit" name="action" value="| . $locale->text('Preview') . qq|">
737
      <input class="submit" type="submit" name="action" value="| . $locale->text('E-mail') . qq|">
738
      <input class="submit" type="submit" name="action" value="| . $locale->text('Print and Post') . qq|">
739
      <input class="submit" type="submit" name="action" value="| . $locale->text('Post') . qq|"> | .
740
        NTI($cgi->submit('-name' => 'action', '-value' => $locale->text('Save draft'), '-class' => 'submit'));
741
    }
742
  }
743

  
744
  # button for saving history
745
  if($form->{id} ne "") {
746
    print qq|
747
  	  <input type="button" class="submit" onclick="set_history_window(|
748
  	  . Q($form->{id})
749
  	  . qq|);" name="history" id="history" value="|
750
  	  . $locale->text('history')
751
  	  . qq|"> |;
752
  }
753
  # /button for saving history
754

  
755
  # mark_as_paid button
756
  if($form->{id} ne "") {
757
    print qq|<input type="submit" class="submit" name="action" value="| . $locale->text('mark as paid') . qq|">|;
758
  }
759
  # /mark_as_paid button
760
  print $form->write_trigger(\%myconfig, scalar(@triggers) / 3, @triggers) .
761
    qq|
762

  
763
<input type="hidden" name="rowcount" value="$form->{rowcount}">
764
| .
765
$cgi->hidden("-name" => "callback", "-value" => $form->{callback})
766
. $cgi->hidden('-name' => 'draft_id', '-default' => [$form->{draft_id}])
767
. $cgi->hidden('-name' => 'draft_description', '-default' => [$form->{draft_description}])
768
. $cgi->hidden('-name' => 'customer_discount', '-value' => [$form->{customer_discount}])
769
. qq|
770
</form>
771

  
772
</body>
773

  
774
 </html>
775
|;
466
  print $form->parse_html_template('is/form_footer');
467

  
468
#  print qq|
469
#  <tr>
470
#    <td>
471
#      <table width="100%">
472
#	<tr valign="bottom">
473
#	  <td>
474
#	    <table>
475
#	      <tr>
476
#		<th align="left">| . $locale->text('Notes') . qq|</th>
477
#		<th align="left">| . $locale->text('Internal Notes') . qq|</th>
478
#                <th align="right">| . $locale->text('Payment Terms') . qq|</th>
479
#	      </tr>
480
#	      <tr valign="top">
481
#		<td>$notes</td>
482
#		<td>$intnotes</td>
483
#                <td><select name="payment_id" onChange="if (this.value) set_duedate(['payment_id__' + this.value, 'invdate__' + invdate.value],['duedate'])">$payment
484
#                </select></td>
485
#	      </tr>
486
#        $follow_ups_block
487
#	    </table>
488
#	  </td>
489
#          <td>
490
#            <table>
491
#            <tr>
492
#              <th  align=left>| . $locale->text('Ertrag') . qq|</th>
493
#              <td>| .  $form->format_amount(\%myconfig, $form->{marge_total}, 2, 0) . qq|</td>
494
#            </tr>
495
#            <tr>
496
#              <th  align=left>| . $locale->text('Ertrag prozentual') . qq|</th>
497
#              <td>| .  $form->format_amount(\%myconfig, $form->{marge_percent}, 2, 0) . qq| %</td>
498
#            </tr>
499
#            <input type=hidden name="marge_total" value="$form->{"marge_total"}">
500
#            <input type=hidden name="marge_percent" value="$form->{"marge_percent"}">
501
#            </table>
502
#          </td>
503
#	  <td align="right">
504
#	    $taxincluded
505
#	    <table>
506
#	      $subtotal
507
#	      $tax
508
#	      <tr>
509
#		<th align="right">| . $locale->text('Total') . qq|</th>
510
#		<td align="right">$form->{invtotal}</td>
511
#	      </tr>
512
#	    </table>
513
#	  </td>
514
#	</tr>
515
#      </table>
516
#    </td>
517
#  </tr>
518
#|;
519
#  my $webdav_list;
520
#  if ($main::webdav) {
521
#    $webdav_list = qq|
522
#  <tr>
523
#    <td><hr size="3" noshade></td>
524
#  </tr>
525
#  <tr>
526
#    <th class="listtop" align="left">Dokumente im Webdav-Repository</th>
527
#  </tr>
528
#    <table width="100%">
529
#      <td align="left" width="30%"><b>Dateiname</b></td>
530
#      <td align="left" width="70%"><b>Webdavlink</b></td>
531
#|;
532
#    foreach my $file (@{ $form->{WEBDAV} }) {
533
#      $webdav_list .= qq|
534
#      <tr>
535
#        <td align="left">$file->{name}</td>
536
#        <td align="left"><a href="$file->{link}">$file->{type}</a></td>
537
#      </tr>
538
#|;
539
#    }
540
#    $webdav_list .= qq|
541
#    </table>
542
#  </tr>
543
#|;
544
#
545
#    print $webdav_list;
546
#  }
547
#if ($form->{type} eq "credit_note") {
548
#  print qq|
549
#  <tr>
550
#    <td>
551
#      <table width="100%">
552
#	<tr class="listheading">
553
#	  <th colspan="6" class="listheading">|
554
#    . $locale->text('Payments') . qq|</th>
555
#	</tr>
556
#|;
557
#} else {
558
#  print qq|
559
#  <tr>
560
#    <td>
561
#      <table width="100%">
562
#	<tr class="listheading">
563
#	  <th colspan="6" class="listheading">|
564
#    . $locale->text('Incoming Payments') . qq|</th>
565
#	</tr>
566
#|;
567
#}
568
#
569
#  my @column_index;
570
#  if ($form->{currency} eq $form->{defaultcurrency}) {
571
#    @column_index = qw(datepaid source memo paid AR_paid);
572
#  } else {
573
#    @column_index = qw(datepaid source memo paid exchangerate AR_paid);
574
#  }
575
#
576
#  my %column_data;
577
#  $column_data{datepaid}     = "<th>" . $locale->text('Date') . "</th>";
578
#  $column_data{paid}         = "<th>" . $locale->text('Amount') . "</th>";
579
#  $column_data{exchangerate} = "<th>" . $locale->text('Exch') . "</th>";
580
#  $column_data{AR_paid}      = "<th>" . $locale->text('Account') . "</th>";
581
#  $column_data{source}       = "<th>" . $locale->text('Source') . "</th>";
582
#  $column_data{memo}         = "<th>" . $locale->text('Memo') . "</th>";
583
#
584
#  print "
585
#	<tr>
586
#";
587
#  map { print "$column_data{$_}\n" } @column_index;
588
#  print "
589
#        </tr>
590
#";
591
#
592
#  my @triggers  = ();
593
#  my $totalpaid = 0;
594
#
595
#  $form->{paidaccounts}++ if ($form->{"paid_$form->{paidaccounts}"});
596
#  for my $i (1 .. $form->{paidaccounts}) {
597
#
598
#    print "
599
#        <tr>\n";
600
#
601
#    $form->{"selectAR_paid_$i"} = $form->{selectAR_paid};
602
#    $form->{"selectAR_paid_$i"} =~
603
#      s/option>\Q$form->{"AR_paid_$i"}\E/option selected>$form->{"AR_paid_$i"}/;
604
#
605
#    # format amounts
606
#    $totalpaid += $form->{"paid_$i"};
607
#    if ($form->{"paid_$i"}) {
608
#      $form->{"paid_$i"} = $form->format_amount(\%myconfig, $form->{"paid_$i"}, 2);
609
#    }
610
#    $form->{"exchangerate_$i"} = $form->format_amount(\%myconfig, $form->{"exchangerate_$i"});
611
#
612
#    if ($form->{"exchangerate_$i"} == 0) {
613
#      $form->{"exchangerate_$i"} = "";
614
#    }
615
#    my $exchangerate = qq|&nbsp;|;
616
#    if ($form->{currency} ne $form->{defaultcurrency}) {
617
#      if ($form->{"forex_$i"}) {
618
#        $exchangerate = qq|<input type="hidden" name="exchangerate_$i" value="$form->{"exchangerate_$i"}">$form->{"exchangerate_$i"}|;
619
#      } else {
620
#        $exchangerate = qq|<input name="exchangerate_$i" size="10" value="$form->{"exchangerate_$i"}">|;
621
#      }
622
#    }
623
#
624
#    $exchangerate .= qq|<input type="hidden" name="forex_$i" value="$form->{"forex_$i"}">|;
625
#
626
#    $column_data{"paid_$i"} =
627
#      qq|<td align="center"><input name="paid_$i" size="11" value="$form->{"paid_$i"}" onBlur=\"check_right_number_format(this)\"></td>|;
628
#    $column_data{"exchangerate_$i"} = qq|<td align="center">$exchangerate</td>|;
629
#    $column_data{"AR_paid_$i"}      =
630
#      qq|<td align="center"><select name="AR_paid_$i">$form->{"selectAR_paid_$i"}</select></td>|;
631
#    $column_data{"datepaid_$i"} =
632
#      qq|<td align="center"><input id="datepaid_$i" name="datepaid_$i"  size="11" title="$myconfig{dateformat}" value="$form->{"datepaid_$i"}" onBlur=\"check_right_date_format(this)\">
633
#         <input type="button" name="datepaid_$i" id="trigger_datepaid_$i" value="?"></td>|;
634
#    $column_data{"source_$i"} =
635
#      qq|<td align=center><input name="source_$i" size="11" value="$form->{"source_$i"}"></td>|;
636
#    $column_data{"memo_$i"} =
637
#      qq|<td align="center"><input name="memo_$i" size="11" value="$form->{"memo_$i"}"></td>|;
638
#
639
#    map { print qq|$column_data{"${_}_$i"}\n| } @column_index;
640
#    print "
641
#        </tr>\n";
642
#    push(@triggers, "datepaid_$i", "BL", "trigger_datepaid_$i");
643
#  }
644
#
645
#  my $paid_missing = $form->{oldinvtotal} - $totalpaid;
646
#
647
#  print qq|
648
#    <tr>
649
#      <td></td>
650
#      <td></td>
651
#      <td align="center">| . $locale->text('Total') . qq|</td>
652
#      <td align="center">| . H($form->format_amount(\%myconfig, $totalpaid, 2)) . qq|</td>
653
#    </tr>
654
#    <tr>
655
#      <td></td>
656
#      <td></td>
657
#      <td align="center">| . $locale->text('Missing amount') . qq|</td>
658
#      <td align="center">| . H($form->format_amount(\%myconfig, $paid_missing, 2)) . qq|</td>
659
#    </tr>
660
#|;
661
#
662
#  map({ print($cgi->hidden("-name" => $_, "-value" => $form->{$_})); } qw(paidaccounts selectAR_paid oldinvtotal));
663
#  print qq|<input type="hidden" name="oldtotalpaid" value="$totalpaid">
664
#    </table>
665
#    </td>
666
#  </tr>
667
#  <tr>
668
#    <td><hr size="3" noshade></td>
669
#  </tr>
670
#  <tr>
671
#    <td>
672
#|;
673
#
674
#  print_options();
675
#
676
#  print qq|
677
#    </td>
678
#  </tr>
679
#</table>
680
#|;
681
#
682
#  my $invdate  = $form->datetonum($form->{invdate},  \%myconfig);
683
#  my $closedto = $form->datetonum($form->{closedto}, \%myconfig);
684
#
685
#  if ($form->{id}) {
686
#    my $show_storno = !$form->{storno} && !IS->has_storno(\%myconfig, $form, "ar") && (($totalpaid == 0) || ($totalpaid eq ""));
687
#
688
#    print qq|
689
#    <input class="submit" type="submit" accesskey="u" name="action" id="update_button" value="| . $locale->text('Update') . qq|">
690
#    <input class="submit" type="submit" name="action" value="| . $locale->text('Ship to') . qq|">
691
#    <input class="submit" type="submit" name="action" value="| . $locale->text('Print') . qq|">
692
#    <input class="submit" type="submit" name="action" value="| . $locale->text('E-mail') . qq|"> |;
693
#    print qq|<input class="submit" type="submit" name="action" value="| . $locale->text('Storno') . qq|"> | if ($show_storno);
694
#    print qq|<input class="submit" type="submit" name="action" value="| . $locale->text('Post Payment') . qq|"> |;
695
#    print qq|<input class="submit" type="submit" name="action" value="| . $locale->text('Use As Template') . qq|"> |;
696
#    if ($form->{id} && !($form->{type} eq "credit_note")) {
697
#      print qq| <input class="submit" type="submit" name="action" value="| . $locale->text('Credit Note') . qq|"> |;
698
#    }
699
#    if ($form->{radier}) {
700
#      print qq| <input class="submit" type="submit" name="action" value="| . $locale->text('Delete') . qq|"> |;
701
#    }
702
#
703
#
704
#    if ($invdate > $closedto) {
705
#      print qq| <input class="submit" type="submit" name="action" value="| . $locale->text('Order') . qq|"> |;
706
#    }
707
#
708
#    print qq| <input type="button" class="submit" onclick="follow_up_window()" value="| . $locale->text('Follow-Up') . qq|">|;
709
#
710
#  } else {
711
#    if ($invdate > $closedto) {
712
#      print qq|
713
#      <input class="submit" type="submit" name="action" id="update_button" value="| . $locale->text('Update') . qq|">
714
#      <input class="submit" type="submit" name="action" value="| . $locale->text('Ship to') . qq|">
715
#      <input class="submit" type="submit" name="action" value="| . $locale->text('Preview') . qq|">
716
#      <input class="submit" type="submit" name="action" value="| . $locale->text('E-mail') . qq|">
717
#      <input class="submit" type="submit" name="action" value="| . $locale->text('Print and Post') . qq|">
718
#      <input class="submit" type="submit" name="action" value="| . $locale->text('Post') . qq|"> | .
719
#        NTI($cgi->submit('-name' => 'action', '-value' => $locale->text('Save draft'), '-class' => 'submit'));
720
#    }
721
#  }
722
#
723
#  # button for saving history
724
#  if($form->{id} ne "") {
725
#    print qq|
726
#  	  <input type="button" class="submit" onclick="set_history_window(|
727
#  	  . Q($form->{id})
728
#  	  . qq|);" name="history" id="history" value="|
729
#  	  . $locale->text('history')
730
#  	  . qq|"> |;
731
#  }
732
#  # /button for saving history
733
#
734
#  # mark_as_paid button
735
#  if($form->{id} ne "") {
736
#    print qq|<input type="submit" class="submit" name="action" value="| . $locale->text('mark as paid') . qq|">|;
737
#  }
738
#  # /mark_as_paid button
739
#  print $form->write_trigger(\%myconfig, scalar(@triggers) / 3, @triggers) .
740
#    qq|
741
#
742
#<input type="hidden" name="rowcount" value="$form->{rowcount}">
743
#| .
744
#$cgi->hidden("-name" => "callback", "-value" => $form->{callback})
745
#. $cgi->hidden('-name' => 'draft_id', '-default' => [$form->{draft_id}])
746
#. $cgi->hidden('-name' => 'draft_description', '-default' => [$form->{draft_description}])
747
#. $cgi->hidden('-name' => 'customer_discount', '-value' => [$form->{customer_discount}])
748
#. qq|
749
#</form>
750
#
751
#</body>
752
#
753
# </html>
754
#|;
776 755

  
777 756
  $main::lxdebug->leave_sub();
778 757
}
locale/de/all
1355 1355
  'Sat. Phone'                  => 'Sat. Tel.',
1356 1356
  'Satz %'                      => 'Satz %',
1357 1357
  'Save'                        => 'Speichern',
1358
  'Save Draft'                  => '',
1358 1359
  'Save account first to insert taxkeys' => 'Einstellungen sind nach
1359 1360
  dem Speichern des Kontos verf?gbar...',
1360 1361
  'Save and AP Transaction'     => 'Speichern und Kreditorenbuchung erfassen',
locale/de/is
265 265
  'Street'                      => 'Stra?e',
266 266
  'Subject'                     => 'Betreff',
267 267
  'Subtotal'                    => 'Zwischensumme',
268
  'Tax Included'                => 'Steuer im Preis inbegriffen',
269 268
  'The \'tag\' field must only consist of alphanumeric characters or the carachters - _ ( )' => 'Das Feld \'tag\' darf nur aus alphanumerischen Zeichen und den Zeichen - _ ( ) bestehen.',
270 269
  'The LDAP server "#1:#2" is unreachable. Please check config/authentication.pl.' => 'Der LDAP-Server "#1:#2" ist nicht erreichbar. Bitte &uuml;berpr&uuml;fen Sie die Angaben in config/authentication.pl.',
271 270
  'The config file "config/authentication.pl" contained invalid Perl code:' => 'Die Konfigurationsdatei "config/authentication.pl" enthielt ung&uuml;tigen Perl-Code:',
......
425 424
  'druckvorschau'               => 'preview',
426 425
  'drucken'                     => 'print',
427 426
  'drucken_und_buchen'          => 'print_and_post',
427
  'save_draft'                  => 'save_draft',
428 428
  'entwurf_speichern'           => 'save_draft',
429 429
  'lieferadresse'               => 'ship_to',
430 430
  '?berspringen'                => 'skip',
templates/webpages/is/_payments_master.html
1

  
2

  
3

  
4

  
5

  
6

  
7
  my @column_index;
8
  if ($form->{currency} eq $form->{defaultcurrency}) {
9
    @column_index = qw(datepaid source memo paid AR_paid);
10
  } else {
11
    @column_index = qw(datepaid source memo paid exchangerate AR_paid);
12
  }
13

  
14
  my %column_data;
15
  $column_data{datepaid}     = "<th>" . $locale->text('Date') . "</th>";
16
  $column_data{paid}         = "<th>" . $locale->text('Amount') . "</th>";
17
  $column_data{exchangerate} = "<th>" . $locale->text('Exch') . "</th>";
18
  $column_data{AR_paid}      = "<th>" . $locale->text('Account') . "</th>";
19
  $column_data{source}       = "<th>" . $locale->text('Source') . "</th>";
20
  $column_data{memo}         = "<th>" . $locale->text('Memo') . "</th>";
21

  
22
    <tr>
23

  
24
  map { print "$column_data{$_}\n" } @column_index;
25

  
26
        </tr>
27

  
28
  my @triggers  = ();
29
  my $totalpaid = 0;
30

  
31
  $form->{paidaccounts}++ if ($form->{"paid_$form->{paidaccounts}"});
32

  
33

  
34

  
35
  [% FOREACH i = 1 .. paidaccounts %]
36

  
37
        <tr>
38

  
39

  
40
    $form->{"selectAR_paid_$i"} = $form->{selectAR_paid};
41
    $form->{"selectAR_paid_$i"} =~
42
      s/option>\Q$form->{"AR_paid_$i"}\E/option selected>$form->{"AR_paid_$i"}/;
43

  
44
    # format amounts
45
    $totalpaid += $form->{"paid_$i"};
46
    if ($form->{"paid_$i"}) {
47
      $form->{"paid_$i"} = $form->format_amount(\%myconfig, $form->{"paid_$i"}, 2);
48
    }
49
    $form->{"exchangerate_$i"} = $form->format_amount(\%myconfig, $form->{"exchangerate_$i"});
50

  
51
    if ($form->{"exchangerate_$i"} == 0) {
52
      $form->{"exchangerate_$i"} = "";
53
    }
54
    my $exchangerate = qq|&nbsp;|;
55
    if ($form->{currency} ne $form->{defaultcurrency}) {
56
      if ($form->{"forex_$i"}) {
57
        $exchangerate = qq|<input type="hidden" name="exchangerate_$i" value="$form->{"exchangerate_$i"}">$form->{"exchangerate_$i"}|;
58
      } else {
59
        $exchangerate = qq|<input name="exchangerate_$i" size="10" value="$form->{"exchangerate_$i"}">|;
60
      }
61
    }
62

  
63
    $exchangerate .= qq|<input type="hidden" name="forex_$i" value="$form->{"forex_$i"}">|;
64

  
65
    $column_data{"paid_$i"} =
66
      qq|<td align="center"><input name="paid_$i" size="11" value="$form->{"paid_$i"}" onBlur=\"check_right_number_format(this)\"></td>|;
67
    $column_data{"exchangerate_$i"} = qq|<td align="center">$exchangerate</td>|;
68
    $column_data{"AR_paid_$i"}      =
69
      qq|<td align="center"><select name="AR_paid_$i">$form->{"selectAR_paid_$i"}</select></td>|;
70
    $column_data{"datepaid_$i"} =
71
      qq|<td align="center"><input id="datepaid_$i" name="datepaid_$i"  size="11" title="$myconfig{dateformat}" value="$form->{"datepaid_$i"}" onBlur=\"check_right_date_format(this)\">
72
         <input type="button" name="datepaid_$i" id="trigger_datepaid_$i" value="?"></td>|;
73
    $column_data{"source_$i"} =
74
      qq|<td align=center><input name="source_$i" size="11" value="$form->{"source_$i"}"></td>|;
75
    $column_data{"memo_$i"} =
76
      qq|<td align="center"><input name="memo_$i" size="11" value="$form->{"memo_$i"}"></td>|;
77

  
78
    map { print qq|$column_data{"${_}_$i"}\n| } @column_index;
79
    print "
80
        </tr>\n";
81
    push(@triggers, "datepaid_$i", "BL", "trigger_datepaid_$i");
82
  }
83

  
84
    <tr>
85
      <td></td>
86
      <td></td>
87
      <td align="center">| . $locale->text('Total') . qq|</td>
88
      <td align="center">| . H($form->format_amount(\%myconfig, $totalpaid, 2)) . qq|</td>
89
    </tr>
90
    <tr>
91
      <td></td>
92
      <td></td>
93
      <td align="center">| . $locale->text('Missing amount') . qq|</td>
94
      <td align="center">| . H($form->format_amount(\%myconfig, $paid_missing, 2)) . qq|</td>
95
    </tr>
96

  
97
  map({ print($cgi->hidden("-name" => $_, "-value" => $form->{$_})); } qw(paidaccounts selectAR_paid oldinvtotal));
98

  
99
  <input type="hidden" name="oldtotalpaid" value="$totalpaid">
100
    </table>
templates/webpages/is/form_footer_de.html
1
[%- USE HTML %]
2
[%- USE LxERP %]
3
  <tr>
4
   <td>
5
    <table width="100%">
6
     <tr valign="bottom">
7
      <td>
8
       <table>
9
        <tr>
10
         <th align="left">Bemerkungen</th>
11
         <th align="left">interne Bemerkungen</th>
12
         <th align="right">Zahlungskonditionen</th>
13
        </tr>
14
        <tr valign="top">
15
         <td>
16
          <textarea name="notes" rows="[% rows %]" cols="26" wrap="soft">[% notes %]</textarea>
17
         </td>
18
         <td>
19
          <textarea name="intnotes" rows="[% rows %]" cols="35" wrap="soft">[% intnotes %]</textarea>
20
         </td>
21
         <td>
22
          <select id='payment_id' name="payment_id">
23

  
24
           $payment
25

  
26
          </select>
27
          <script type='text/javascript'>$('#payment_id').onchange(function(){
28
            if (this.value) set_duedate(['payment_id__' + this.value, 'invdate__' + invdate.value],['duedate'])})
29
          </script>
30
         </td>
31
        </tr>
32
        <tr>
33
          <td colspan="2">[% follow_up_text %]</td>
34
        </tr>
35

  
36
       </table>
37
      </td>
38
      <td>
39
       <table>
40
        <tr>
41
         <th  align=left>Ertrag</th>
42
         <td>[% LxERP.format_amount(marge_total, 2, 0) %]</td>
43
        </tr>
44
        <tr>
45
         <th  align=left>Ertrag prozentual</th>
46
         <td>[% LxERP.format_amount(marge_percent, 2, 0) %] %</td>
47
        </tr>
48
        <input type=hidden name="marge_total" value="[% marge_total %]">
49
        <input type=hidden name="marge_percent" value="[% marge_percent %]">
50
       </table>
51
      </td>
52
      <td align="right">
53
  [%- IF taxaccounts %]
54
       <input name="taxincluded" class="checkbox" type="checkbox" [% IF taxincluded %]checked[% END %]>
55
       <b>Steuer im Preis inbegriffen</b>
56
       <br>
57
       <br>
58
  [%- END %]
59
       <table>
60

  
61
        $subtotal
62

  
63
[%# tax %]
64
[% FOREACH item = taxaccounts_array %]
65
[% SET description_ref = item _ 'description' %]
66
[% SET rate_ref        = item _ 'rate' %]
67
[% SET total_ref       = item _ 'total' %]
68
[% SET netto_ref       = item _ 'netto' %]
69
       <tr>
70
        <th align="right">Enthaltene [% $description_ref %]&nbsp;[% $rate_ref * 100 %]%</th>
71
        <td align="right">[% $total_ref %]</td>
72
       </tr>
73
       <tr>
74
        <th align="right">Nettobetrag</th>
75
        <td align="right">[% $netto_ref %]</td>
76
       </tr>
77
[%- END %]
78

  
79
        <tr>
80
         <th align="right">Summe</th>
81
         <td align="right">[% invtotal %]</td>
82
        </tr>
83
       </table>
84
      </td>
85
     </tr>
86
    </table>
87
   </td>
88
  </tr>
89

  
90
[%- IF webdav %]
91
  <tr>
92
   <td><hr size="3" noshade></td>
93
  </tr>
94
  <tr>
95
   <th class="listtop" align="left">Dokumente im Webdav-Repository</th>
96
  </tr>
97
   <table width="100%">
98
    <tr>
99
     <td align="left" width="30%"><b>Dateiname</b></td>
100
     <td align="left" width="70%"><b>Webdavlink</b></td>
101
    </tr>
102
 [%- FOREACH file = WEBDAV %]
103
    <tr>
104
     <td align="left">[% file.name %]</td>
105
     <td align="left"><a href="[% file.link %]">[% file.type %]</a></td>
106
    </tr>
107
 [%- END %]
108
   </table>
109
  </tr>
110
[% END %]
111

  
112

  
113
  <tr>
114
   <td>
115
    <table width="100%">
116
     <tr class="listheading">
117
[% IF is_credit_note %]
118
      <th colspan="6" class="listheading">Zahlungsausg?nge</th>
119
[% ELSE %]
120
      <th colspan="6" class="listheading">Zahlungseing?nge</th>
121
[%- END %]
122
     </tr>
123

  
124

  
125
[%# INCLUDE _payments %]
126

  
127

  
128
    </td>
129
  </tr>
130
  <tr>
131
    <td><hr size="3" noshade></td>
132
  </tr>
133
  <tr>
134
    <td>
135
  [% print_options %]
136
    </td>
137
  </tr>
138
</table>
139

  
140
  [% IF id %]
141

  
142
    <input class="submit" type="submit" accesskey="u" name="action" id="update_button" value="Erneuern">
143
    <input class="submit" type="submit" name="action" value="Lieferadresse">
144
    <input class="submit" type="submit" name="action" value="Drucken">
145
    <input class="submit" type="submit" name="action" value="eMail">
146
[% IF  show_storno %]
147
    <input class="submit" type="submit" name="action" value="Storno">
148
[% END %]
149
    <input class="submit" type="submit" name="action" value="Zahlung buchen">
150
    <input class="submit" type="submit" name="action" value="Als Vorlage verwenden">
151

  
152
[% IF id && is_credit_note %]
153
    <input class="submit" type="submit" name="action" value="Gutschrift">
154
[% END %]
155
[% IF show_delete %]
156
    <input class="submit" type="submit" name="action" value="L?schen">
157
[% END %]
158

  
159
  [%- IF invdate > closedto %]
160
       <input class="submit" type="submit" name="action" value="Auftrag">
161
  [%- END %]
162

  
163
    <input type="button" class="submit" onclick="follow_up_window()" value="Wiedervorlage">
164

  
165
 [% ELSE # no id %]
166
   [% IF invdate > closedto %]
167
      <input class="submit" type="submit" name="action" id="update_button" value="Erneuern">
168
      <input class="submit" type="submit" name="action" value="Lieferadresse">
169
      <input class="submit" type="submit" name="action" value="Druckvorschau">
170
      <input class="submit" type="submit" name="action" value="eMail">
171
      <input class="submit" type="submit" name="action" value="Drucken und Buchen">
172
      <input class="submit" type="submit" name="action" value="Buchen">
173
      <input class="submit" type="submit" name="action" value="Save Draft">
174
   [%- END %]
175
 [% END # id %]
176

  
177
  [% IF id %]
178
      [%#- button for saving history %]
179
      <input type="button" class="submit" onclick="set_history_window([% id | html %]);" name="history" id="history" value="Historie">
180

  
181
      <input type="submit" class="submit" name="action" value="als bezahlt markieren">
182
  [% END %]
183

  
184
<input type="hidden" name="rowcount" value="[% rowcount %]">
185
<input type="hidden" name="callback" value="[% callback %]">
186
<input type="hidden" name="draft_id" value="[% draft_id %]">
187
<input type="hidden" name="draft_description" value="[% draft_description %]">
188
<input type="hidden" name="customer_discount" value="[% customer_discount %]">
189

  
190
</form>
191

  
192
</body>
193

  
194
</html>
templates/webpages/is/form_footer_master.html
1
[%- USE HTML %]
2
[%- USE LxERP %]
3
  <tr>
4
   <td>
5
    <table width="100%">
6
     <tr valign="bottom">
7
      <td>
8
       <table>
9
        <tr>
10
         <th align="left"><translate>Notes</translate></th>
11
         <th align="left"><translate>Internal Notes</translate></th>
12
         <th align="right"><translate>Payment Terms</translate></th>
13
        </tr>
14
        <tr valign="top">
15
         <td>
16
          <textarea name="notes" rows="[% rows %]" cols="26" wrap="soft">[% notes %]</textarea>
17
         </td>
18
         <td>
19
          <textarea name="intnotes" rows="[% rows %]" cols="35" wrap="soft">[% intnotes %]</textarea>
20
         </td>
21
         <td>
22
          <select id='payment_id' name="payment_id">
23

  
24
           $payment
25

  
26
          </select>
27
          <script type='text/javascript'>$('#payment_id').onchange(function(){
28
            if (this.value) set_duedate(['payment_id__' + this.value, 'invdate__' + invdate.value],['duedate'])})
29
          </script>
30
         </td>
31
        </tr>
32
        <tr>
33
          <td colspan="2">[% follow_up_text %]</td>
34
        </tr>
35

  
36
       </table>
37
      </td>
38
      <td>
39
       <table>
40
        <tr>
41
         <th  align=left><translate>Ertrag</translate></th>
42
         <td>[% LxERP.format_amount(marge_total, 2, 0) %]</td>
43
        </tr>
44
        <tr>
45
         <th  align=left><translate>Ertrag prozentual</translate></th>
46
         <td>[% LxERP.format_amount(marge_percent, 2, 0) %] %</td>
47
        </tr>
48
        <input type=hidden name="marge_total" value="[% marge_total %]">
49
        <input type=hidden name="marge_percent" value="[% marge_percent %]">
50
       </table>
51
      </td>
52
      <td align="right">
53
  [%- IF taxaccounts %]
54
       <input name="taxincluded" class="checkbox" type="checkbox" [% IF taxincluded %]checked[% END %]>
55
       <b><translate>Tax Included</translate></b>
56
       <br>
57
       <br>
58
  [%- END %]
59
       <table>
60

  
61
        $subtotal
62

  
63
[%# tax %]
64
[% FOREACH item = taxaccounts_array %]
65
[% SET description_ref = item _ 'description' %]
66
[% SET rate_ref        = item _ 'rate' %]
67
[% SET total_ref       = item _ 'total' %]
68
[% SET netto_ref       = item _ 'netto' %]
69
       <tr>
70
        <th align="right">Enthaltene [% $description_ref %]&nbsp;[% $rate_ref * 100 %]%</th>
71
        <td align="right">[% $total_ref %]</td>
72
       </tr>
73
       <tr>
74
        <th align="right">Nettobetrag</th>
75
        <td align="right">[% $netto_ref %]</td>
76
       </tr>
77
[%- END %]
78

  
79
        <tr>
80
         <th align="right"><translate>Total</translate></th>
81
         <td align="right">[% invtotal %]</td>
82
        </tr>
83
       </table>
84
      </td>
85
     </tr>
86
    </table>
87
   </td>
88
  </tr>
89

  
90
[%- IF webdav %]
91
  <tr>
92
   <td><hr size="3" noshade></td>
93
  </tr>
94
  <tr>
95
   <th class="listtop" align="left">Dokumente im Webdav-Repository</th>
96
  </tr>
97
   <table width="100%">
98
    <tr>
99
     <td align="left" width="30%"><b>Dateiname</b></td>
100
     <td align="left" width="70%"><b>Webdavlink</b></td>
101
    </tr>
102
 [%- FOREACH file = WEBDAV %]
103
    <tr>
104
     <td align="left">[% file.name %]</td>
105
     <td align="left"><a href="[% file.link %]">[% file.type %]</a></td>
106
    </tr>
107
 [%- END %]
108
   </table>
109
  </tr>
110
[% END %]
111

  
112

  
113
  <tr>
114
   <td>
115
    <table width="100%">
116
     <tr class="listheading">
117
[% IF is_credit_note %]
118
      <th colspan="6" class="listheading"><translate>Payments</translate></th>
119
[% ELSE %]
120
      <th colspan="6" class="listheading"><translate>Incoming Payments</translate></th>
121
[%- END %]
122
     </tr>
123

  
124

  
125
[%# INCLUDE _payments %]
126

  
127

  
128
    </td>
129
  </tr>
130
  <tr>
131
    <td><hr size="3" noshade></td>
132
  </tr>
133
  <tr>
134
    <td>
135
  [% print_options %]
136
    </td>
137
  </tr>
138
</table>
139

  
140
  [% IF id %]
141

  
142
    <input class="submit" type="submit" accesskey="u" name="action" id="update_button" value="<translate>Update</translate>">
143
    <input class="submit" type="submit" name="action" value="<translate>Ship to</translate>">
144
    <input class="submit" type="submit" name="action" value="<translate>Print</translate>">
145
    <input class="submit" type="submit" name="action" value="<translate>E-mail</translate>">
146
[% IF  show_storno %]
147
    <input class="submit" type="submit" name="action" value="<translate>Storno</translate>">
148
[% END %]
149
    <input class="submit" type="submit" name="action" value="<translate>Post Payment</translate>">
150
    <input class="submit" type="submit" name="action" value="<translate>Use As Template</translate>">
151

  
152
[% IF id && is_credit_note %]
153
    <input class="submit" type="submit" name="action" value="<translate>Credit Note</translate>">
154
[% END %]
155
[% IF show_delete %]
156
    <input class="submit" type="submit" name="action" value="<translate>Delete</translate>">
157
[% END %]
158

  
159
  [%- IF invdate > closedto %]
160
       <input class="submit" type="submit" name="action" value="<translate>Order</translate>">
161
  [%- END %]
162

  
163
    <input type="button" class="submit" onclick="follow_up_window()" value="<translate>Follow-Up</translate>">
164

  
165
 [% ELSE # no id %]
166
   [% IF invdate > closedto %]
167
      <input class="submit" type="submit" name="action" id="update_button" value="<translate>Update</translate>">
168
      <input class="submit" type="submit" name="action" value="<translate>Ship to</translate>">
169
      <input class="submit" type="submit" name="action" value="<translate>Preview</translate>">
170
      <input class="submit" type="submit" name="action" value="<translate>E-mail</translate>">
171
      <input class="submit" type="submit" name="action" value="<translate>Print and Post</translate>">
172
      <input class="submit" type="submit" name="action" value="<translate>Post</translate>">
173
      <input class="submit" type="submit" name="action" value="<translate>Save Draft</translate>">
174
   [%- END %]
175
 [% END # id %]
176

  
177
  [% IF id %]
178
      [%#- button for saving history %]
179
      <input type="button" class="submit" onclick="set_history_window([% id | html %]);" name="history" id="history" value="<translate>history</translate>">
180

  
181
      <input type="submit" class="submit" name="action" value="<translate>mark as paid</translate>">
182
  [% END %]
183

  
184
<input type="hidden" name="rowcount" value="[% rowcount %]">
185
<input type="hidden" name="callback" value="[% callback %]">
186
<input type="hidden" name="draft_id" value="[% draft_id %]">
187
<input type="hidden" name="draft_description" value="[% draft_description %]">
188
<input type="hidden" name="customer_discount" value="[% customer_discount %]">
189

  
190
</form>
191

  
192
</body>
193

  
194
</html>
templates/webpages/oe/form_footer_de.html
91 91
      <td align="left" width="30%"><b>Dateiname</b></td>
92 92
      <td align="left" width="70%"><b>Webdavlink</b></td>
93 93
     </tr>
94
 [%- FOREACH file=WEBDAV %]
94
 [%- FOREACH file = WEBDAV %]
95 95
      <tr>
96 96
        <td align="left">[% HTML.escape(file.name) %]</td>
97 97
        <td align="left"><a href="[% file.link %]">[% HTML.escape(file.type) %]</a></td>
templates/webpages/oe/form_footer_master.html
91 91
      <td align="left" width="30%"><b>Dateiname</b></td>
92 92
      <td align="left" width="70%"><b>Webdavlink</b></td>
93 93
     </tr>
94
 [%- FOREACH file=WEBDAV %]
94
 [%- FOREACH file = WEBDAV %]
95 95
      <tr>
96 96
        <td align="left">[% HTML.escape(file.name) %]</td>
97 97
        <td align="left"><a href="[% file.link %]">[% HTML.escape(file.type) %]</a></td>

Auch abrufbar als: Unified diff