Pokaż
Ignoruj:
Data:
2009-11-24 12:24:57 (16 years ago)
Autor:
alina
Opis:

re #215 zmiana parametrow w konstruktorze PlatnosciController?, dostosowanie testow do zmiany

Pliki:
1 zmodyfikowane

Legenda:

Bez zmian
Dodane
Usunięte
  • trunk/eCard/eCardMVC/Platnosci/Controllers/MerchantController.cs

    r881 r896  
    3030        public const string KODOWANIE = "ISO-8859-2"; 
    3131        private int ORDERNUMBER = 122; 
     32        private string merchantId; 
    3233 
    33         private string merchantId; 
    34         private readonly PlatnosciDataContext _context; 
    35         private readonly IRepository<PlatnosciEcard> _rep; 
     34        private readonly IRepository<vPlatnosciEcard> _repVPayment; 
     35        private readonly IRepository<PlatnosciEcard> _repPayment;         
    3636        private FunkcjePlatnosci _func; 
    3737 
    3838        public MerchantController() 
    39         {    
    40             _rep = new Repository<PlatnosciEcard>(new DataContext1()); 
    41             _context = new PlatnosciDataContext(); 
     39        { 
     40            _repVPayment = new Repository<vPlatnosciEcard>(new DataContext1()); 
     41            _repPayment = new Repository<PlatnosciEcard>(new DataContext1()); 
    4242            _func = new FunkcjePlatnosci(); 
    4343        } 
     
    4848 
    4949            int id1 = Convert.ToInt32(payer.Id_faktury); 
    50             vPlatnosciEcard platnosc = _rep.FindInvoiceById(id1).SingleOrDefault(); 
     50            vPlatnosciEcard platnosc = _repVPayment.Find(p => p.ID_faktury == id1).SingleOrDefault(); 
    5151                  
    5252            if (platnosc == null) 
     
    115115            if (platnosc != null) 
    116116            {                 
    117                // _rep.Insert(platnosc); 
     117                //_repPayment.Insert(platnosc); 
    118118                return true; 
    119119            }