예제 #1
0
        public void Edit(EditAdvertisementViewModel model)
        {
            Advertisement getAdv = advertisementService.getAdvertisementId(model.AdvertisementId);

            getAdv.AdvertisementName = model.AdvertisementName;
            getAdv.Description       = model.Description;
            getAdv.Cost = model.Cost;
            advertisementService.save();
        }
예제 #2
0
        public ActionResult Edit(EditAdvertisementViewModel model)
        {
            if (ModelState.IsValid)
            {
                editAdvertisement.Edit(model);
                return(RedirectToAction("UserAdvertisement", "User"));
            }

            return(View());
        }