Beispiel #1
0
        public ActionResult Ekle()
        {
            var talepViewModel = new TalepDetayFirmaViewModel()
            {
                Konular = _refTalepKonuRepository.TalepKonuListesi()
            };

            return(View("Duzenle", talepViewModel));
        }
Beispiel #2
0
 public ActionResult Duzenle(TalepDetayFirmaViewModel talepDetayFirmaViewModel)
 {
     if (ModelState.IsValid)
     {
         var talep          = Mapper.Map <TalepDetayFirmaViewModel, TalepDetayFirma>(talepDetayFirmaViewModel);
         var firmaKullanici = (FirmaKullanici)Session["CurrentFirmaKullanici"];
         talep.VergiNo          = firmaKullanici.VergiNo;
         talep.FirmaKullaniciId = firmaKullanici.Id;
         talep.TalepTarih       = DateTime.Now;
         talep.CevapDurum       = false;
         _talepDetayFirmaRepository.TalepKaydetGuncelle(talep);
         return(RedirectToAction("Liste"));
     }
     else
     {
         var talepViewModel = new TalepDetayFirmaViewModel()
         {
             Konular = _refTalepKonuRepository.TalepKonuListesi()
         };
         return(View("Duzenle", talepViewModel));
     }
 }