Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 40a94352

Von Jan Büren vor fast 2 Jahren hinzugefügt

  • ID 40a94352008a84eef179efb96ded65fd2f16a2df
  • Vorgänger f0fa67d2
  • Nachfolger fe243aca

Wechselkurs beim Laden des Belegs in form_header oder retrieve_invoice holen

Unterschiede anzeigen:

bin/mozilla/ap.pl
353 353
  # build the popup menus
354 354
  $form->{taxincluded} = ($form->{id}) ? $form->{taxincluded} : "checked";
355 355

  
356
  # currencies
357
  $form->{defaultcurrency} = $form->get_default_currency(\%myconfig);
358

  
359 356
  $::form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all_sorted;
360 357

  
361 358
  $form->{employee} = "$form->{employee}--$form->{employee_id}";
......
413 410

  
414 411
  $form->{readonly} = $readonly;
415 412

  
416
  $form->{forex} = $form->check_exchangerate( \%myconfig, $form->{currency}, $form->{transdate}, 'sell');
417
  if ( $form->{forex} ) {
418
    $form->{exchangerate} = $form->{forex};
413
  # currencies
414
  $form->{defaultcurrency} = $form->get_default_currency(\%myconfig);
415
  if ($form->{currency} ne $form->{defaultcurrency}) {
416
    ($form->{exchangerate}, $form->{record_forex}) = $form->check_exchangerate(\%myconfig, $form->{currency}, $form->{transdate}, "sell", $form->{id}, 'ap');
419 417
  }
420 418

  
421 419
  # format amounts
422
  $form->{exchangerate}    = $form->{exchangerate} ? $form->format_amount(\%myconfig, $form->{exchangerate}) : '';
423 420
  $form->{creditlimit}     = $form->format_amount(\%myconfig, $form->{creditlimit}, 0, "0");
424 421
  $form->{creditremaining} = $form->format_amount(\%myconfig, $form->{creditremaining}, 0, "0");
425 422

  
......
698 695

  
699 696
  map { $form->{invtotal} += $form->{"amount_$_"} } (1 .. $form->{rowcount});
700 697

  
701
  $form->{forex}        = $form->check_exchangerate( \%myconfig, $form->{currency}, $form->{transdate}, 'sell');
702
  $form->{exchangerate} = $form->{forex} if $form->{forex};
703

  
704 698
  $form->{invdate} = $form->{transdate};
705 699

  
706 700
  if (($form->{previous_vendor_id} || $form->{vendor_id}) != $form->{vendor_id}) {

Auch abrufbar als: Unified diff