Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision f95e112a

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

  • ID f95e112a3d7b4d3d2b54873ecd0288f8f79d5d2a
  • Vorgänger 53c21645
  • Nachfolger b895ab3c

get_exchangerate nach check_exchangerate migriert

Die Funktion ist bis auf die eingehenden Parameter identisch

Unterschiede anzeigen:

SL/CP.pm
136 136

  
137 137
    # if this is a foreign currency transaction get exchangerate
138 138
    $ref->{exchangerate} =
139
      $form->get_exchangerate($dbh, $ref->{curr}, $ref->{transdate}, $buysell)
139
      $form->check_exchangerate($myconfig, $ref->{curr}, $ref->{transdate}, $buysell)
140 140
      if ($form->{currency} ne $form->{defaultcurrency});
141 141
    push @{ $form->{PR} }, $ref;
142 142
  }
SL/Form.pm
2604 2604

  
2605 2605
    # get exchangerate for currency
2606 2606
    $self->{exchangerate} =
2607
      $self->get_exchangerate($dbh, $self->{currency}, $self->{transdate}, $fld);
2607
      $self->check_exchangerate($myconfig, $self->{currency}, $self->{transdate}, $fld);
2608 2608
    my $index = 0;
2609 2609

  
2610 2610
    # store amounts in {acc_trans}{$key} for multiple accounts
2611 2611
    while (my $ref = $sth->fetchrow_hashref("NAME_lc")) {
2612 2612
      $ref->{exchangerate} =
2613
        $self->get_exchangerate($dbh, $self->{currency}, $ref->{transdate}, $fld);
2613
        $self->check_exchangerate($myconfig, $self->{currency}, $ref->{transdate}, $fld);
2614 2614
      if (!($xkeyref{ $ref->{accno} } =~ /tax/)) {
2615 2615
        $index++;
2616 2616
      }
......
2662 2662

  
2663 2663
      # get exchangerate for currency
2664 2664
      $self->{exchangerate} =
2665
        $self->get_exchangerate($dbh, $self->{currency}, $self->{transdate}, $fld);
2665
        $self->check_exchangerate($myconfig, $self->{currency}, $self->{transdate}, $fld);
2666 2666

  
2667 2667
    }
2668 2668

  
SL/IR.pm
1009 1009
  $form->{mtime} = $form->{itime} if !$form->{mtime};
1010 1010
  $form->{lastmtime} = $form->{mtime};
1011 1011

  
1012
  $form->{exchangerate}  = $form->get_exchangerate($dbh, $form->{currency}, $form->{invdate}, "sell");
1012
  $form->{exchangerate}  = $form->check_exchangerate($myconfig, $form->{currency}, $form->{invdate}, "sell");
1013 1013

  
1014 1014
  # get shipto
1015 1015
  $query = qq|SELECT * FROM shipto WHERE (trans_id = ?) AND (module = 'AP')|;
SL/IS.pm
2312 2312
    $form->{mtime} = $form->{itime} if !$form->{mtime};
2313 2313
    $form->{lastmtime} = $form->{mtime};
2314 2314

  
2315
    $form->{exchangerate} = $form->get_exchangerate($dbh, $form->{currency}, $form->{invdate}, "buy");
2315
    $form->{exchangerate} = $form->check_exchangerate($myconfig, $form->{currency}, $form->{invdate}, "buy");
2316 2316

  
2317 2317
    foreach my $vc (qw(customer vendor)) {
2318 2318
      next if !$form->{"delivery_${vc}_id"};
SL/OE.pm
1410 1410

  
1411 1411
  }
1412 1412

  
1413
  $form->{exchangerate} = $form->get_exchangerate($dbh, $form->{currency}, $form->{transdate}, ($form->{vc} eq 'customer') ? "buy" : "sell");
1413
  $form->{exchangerate} = $form->check_exchangerate($myconfig, $form->{currency}, $form->{transdate}, ($form->{vc} eq 'customer') ? "buy" : "sell");
1414 1414

  
1415 1415
  Common::webdav_folder($form);
1416 1416

  

Auch abrufbar als: Unified diff