// // GET: /Manage/YogaPicture/Details/5 /// <summary> /// 审核 /// </summary> /// <param name="id"></param> /// <returns></returns> public ActionResult Details(int id, DateTime?CreateTime, string FName) { ViewBag.Uid = id; ViewYogaPicture picInfo = new ViewYogaPicture(); if (CreateTime != null) { picInfo = client.GetYogaPictureByCreateTime(id, CreateTime.Value); } else if (!string.IsNullOrEmpty(FName)) { picInfo = client.GetYogaPictureById(id, FName); } else { picInfo = client.GetYogaPictureById(id); } if (picInfo == null) { return(Content("<script>alert('已经全部删除!');window.location='/YogaPicture/IndexSearch';</script>")); } //获取相册名称(文件夹) string fileInfo = GetAllFolder(id); string[] ids = fileInfo.Split(','); if (ids.Count() > 0) { List <SelectListItem> selectlist = new List <SelectListItem> { }; foreach (var i in ids) { if (!string.IsNullOrEmpty(i)) { selectlist.Add(new SelectListItem { Text = i, Value = i, Selected = false }); } } ViewData["FName"] = selectlist; } // #region ViewBag.picInfo = picInfo; ViewYogisModels model = modelclient.GetYogisModelsById(id); if (model != null) { if (!string.IsNullOrEmpty(model.RealName)) { ViewBag.Name = model.RealName; } else { ViewYogaUserDetail detEntity = userDetclient.GetYogaUserDetailById(id); if (detEntity != null) { if (!string.IsNullOrEmpty(detEntity.RealName_cn)) { ViewBag.Name = detEntity.RealName_cn; } } else { ViewYogaUser userEntity = userclient.GetYogaUserById(id); if (userEntity != null) { if (!string.IsNullOrEmpty(userEntity.NickName)) { ViewBag.Name = userEntity.NickName; } } } } } else { ViewYogaUserDetail detEntity = userDetclient.GetYogaUserDetailById(id); if (detEntity != null) { if (!string.IsNullOrEmpty(detEntity.RealName_cn)) { ViewBag.Name = detEntity.RealName_cn; } } else { ViewYogaUser userEntity = userclient.GetYogaUserById(id); if (userEntity != null) { if (!string.IsNullOrEmpty(userEntity.NickName)) { ViewBag.Name = userEntity.NickName; } } } } #endregion if (!string.IsNullOrEmpty(FName)) { list = client.GetBackUidList(id, FName); } else if (CreateTime != null) { ViewBag.CreateTime = CreateTime; list = client.GetBackUidList(id, CreateTime.Value); } else { list = client.GetBackUidList(id); } ViewBag.list = list; return(View()); }