Exemple #1
0
        public HttpResponseMessage Delete(int id)
        {
            BlogTagService.Delete(id);

            SuccessResponse response = new SuccessResponse();

            return(Request.CreateResponse(HttpStatusCode.OK, response));
        }
Exemple #2
0
        public IActionResult Delete(BlogTagMD metaData)
        {
            var result = _service.Delete(metaData);

            if (!result.Status)
            {
                result.Data.TagOptions = _service.GetOptions();
                ViewBag.ErrorMessage   = result.Message;
                ViewBag.BlogId         = result.Data.BlogId;

                return(View(result.Data));
            }

            return(RedirectToAction("Index", "BlogTag", new { blogId = metaData.BlogId }));
        }