Beispiel #1
0
        public ActionResult Delete(int[] ids)
        {
            try
            {
                if (ids.Length != 0)
                {
                    var numArray = ids;
                    for (var i = 0; i < numArray.Length; i++)
                    {
                        var num       = numArray[i];
                        var slideShow = _slideShowService.Get(x => x.Id == num);

                        _slideShowService.Delete(slideShow);

                        //Delete localize
                        var ieLocalizedProperty = _localizedPropertyService.GetByEntityId(num);

                        _localizedPropertyService.BatchDelete(ieLocalizedProperty);
                    }
                }
            }
            catch (Exception ex)
            {
                ExtentionUtils.Log(string.Concat("SlideShow.Delete: ", ex.Message));
            }

            return(RedirectToAction("Index"));
        }
 public async Task <ActionResult> Get(int slideShowItemId)
 {
     return(Json(await _slideShowService.Get(slideShowItemId), JsonRequestBehavior.AllowGet));
 }