/// <summary> /// 添加一条视频审核记录 /// </summary> /// <param name="info"></param> /// <returns></returns> public bool AddApproveInfo(VideoApproveView info) { if (info == null) { return(false); } this._videoRepository.IncomeUpload(info.ApproveContent, info.ApproveRemark, info.VideoId, (info.Status == 4), info.CreateAdminId); var video = (from v in this._videoRepository.GetEntityList() where v.State == false && v.Id == info.VideoId select v).FirstOrDefault(); if (video != null) { if (video.VideoState == 3) { //TODO insert 刘强添加标签 try { this._tagsBusiness = ((Autofac.IContainer)HttpRuntime.Cache["containerKey"]).Resolve <ITagsBusiness>(); //上传视频的人 this._tagsBusiness.UserId = info.CreateAdminId; this._tagsBusiness.AsyncCreateTags(); } catch (Exception ex) { #if !DEBUG LogBuilder.Log4Net.Error("更新标签失败", ex.MostInnerException()); #else Console.WriteLine(LanguageUtil.Translate("api_Business_VideoApprove_AddApproveInfo_updateTagsFailed") + ex.MostInnerException().Message); #endif } } this._videoBusiness = ((Autofac.IContainer)HttpRuntime.Cache["containerKey"]).Resolve <IVideoBusiness>(); this._videoBusiness.UpdateAVideoIndex(video); //审核时改变了分类 video.CategoryId = info.CategoryId; this._videoRepository.UpdateEntity(video); } return(true); }
public VideoController(IVideoBusiness videoBusiness, IBannerVideoBusiness bannerVideoBusiness, ICategoryBusiness categoryBusiness) { this._videoBusiness = videoBusiness; this._bannerVideoBusiness = bannerVideoBusiness; this._categoryBusiness = categoryBusiness; }
public UserController(IUserBusiness userBusiness, IVideoBusiness videoBusiness) { this._userBusiness = userBusiness; this._videoBusiness = videoBusiness; }
public VideoService(IVideoBusiness VideoBiz) { _VideoBiz = VideoBiz; }
public UserSpecialController(IUserSpecialBusiness userspecialbusiness, IVideoBusiness videoBusiness) { this._userspecialbusiness = userspecialbusiness; this._videoBusiness = videoBusiness; }