Esempio n. 1
0
        public async Task <IActionResult> Update(UpdateAdInputModel inputModel)
        {
            var isUpdated = await adService.UpdateAdByIdAsync(inputModel.AdId);

            if (!isUpdated)
            {
                TempData["UpdateAdMessage"] = UnSuccessfullyUpdatesAdMessage;
            }
            else
            {
                TempData["UpdateAdMessage"] = SuccessfullyUpdatedAdMessage;
            }

            return(RedirectToAction("ActiveAds"));
        }