public PaperPublishHouseViewModel GetPaperPublishHosuse(int?id)
        {
            var publichHouse = new PaperPublishHouseViewModel();

            PaperPublishHouses tempPublishHouse = _publishHouseRepository.FindById(id);

            Mapper.Map(tempPublishHouse, publichHouse);

            return(publichHouse);
        }
Ejemplo n.º 2
0
        public ActionResult Edit(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            PaperPublishHouseViewModel paperPublishHous = _publishHouseService.GetPaperPublishHosuse(id);

            if (paperPublishHous == null)
            {
                return(HttpNotFound());
            }
            return(View(paperPublishHous));
        }
Ejemplo n.º 3
0
 public ActionResult DeleteConfirmed(PaperPublishHouseViewModel model)
 {
     _publishHouseService.DeletePublishHouse(model.Id);
     return(RedirectToAction("Index", "Base"));
 }