public ActionResult Gallery(int id) { var model = _rotatingImageGroupServices.GetGroupGallery(id); if (model == null) { SetErrorMessage(LocalizedResourceServices.T("AdminModule:::RotatingImageGroups:::Messages:::UpdateFailure:::Rotating Image Group not founded.")); return(RedirectToAction("Index")); } return(View(model)); }
/// <summary> /// Render curly bracket /// </summary> /// <param name="parameters"></param> /// <returns></returns> public string Render(string[] parameters) { ParseParams(parameters); var model = _rotatingImageGroupServices.GetGroupGallery(GroupId); if (model == null) { return(_localizedResourceServices.T("CurlyBracketsRendering:::RotatingImages:::Messages:::GroupNotFounded:::Group id is invalid. Please check the data again.")); } var template = _templateServices.GetTemplateByName(Template) ?? _templateServices.GetTemplateByName(DefaultTemplate); return(_templateServices.Parse(template.Content, model, null, template.CacheName)); }