Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 89b26688

Von Sven Schöling vor mehr als 9 Jahren hinzugefügt

  • ID 89b2668811eac6023ad58322e2f9970ddb6a27c9
  • Vorgänger c653b98f
  • Nachfolger 766ed2a6

PriceSource: Rabattbehandlung

Unterschiede anzeigen:

bin/mozilla/ir.pl
511 511
        if ($sellprice) {
512 512
          $form->{"sellprice_$i"} = $sellprice;
513 513
        } else {
514
          my $record        = _make_record();
515
          my $price_source  = SL::PriceSource->new(record_item => $record->items->[$i-1], record => $record);
516
          my $best_price    = $price_source->best_price;
517
          my $best_discount = $price_source->best_discount;
518

  
519
          if ($best_price) {
520
            $::form->{"sellprice_$i"}           = $best_price->price;
521
            $::form->{"active_price_source_$i"} = $best_price->source;
522
          }
523
          if ($best_discount) {
524
            $::form->{"discount_$i"}               = $best_discount->discount;
525
            $::form->{"active_discount_source_$i"} = $best_discount->source;
526
          }
527

  
514 528
          # if there is an exchange rate adjust sellprice
515 529
          $form->{"sellprice_$i"} /= $exchangerate;
516 530
        }

Auch abrufbar als: Unified diff