protected void InitialQuickLink() { try { CY.GFive.Core.Business.NewsModule module = CY.GFive.Core.Business.NewsModule.SelectByName("校报专栏"); if (module != null) { NewsParper = module; } if ((module = CY.GFive.Core.Business.NewsModule.SelectByName("学籍查询")) != null) { RecordQuery = module; } if ((module = CY.GFive.Core.Business.NewsModule.SelectByName("心理咨询")) != null) { PsychologyAdvisory = module; } if ((module = CY.GFive.Core.Business.NewsModule.SelectByName("学生园地")) != null) { GardenPlot = module; } if ((module = CY.GFive.Core.Business.NewsModule.SelectByName("在线投票")) != null) { Vote = module; } if ((module = CY.GFive.Core.Business.NewsModule.SelectByName("视频在线")) != null) { Video = module; } } catch (Exception ex) { throw ex; } }
protected void Initial(ref List<CY.GFive.Core.Business.NewsContent> EnRollInfos, ref CY.GFive.Core.Business.NewsContent EnRollInfo, ref CY.GFive.Core.Business.NewsModule moduleAdmission) { try { moduleAdmission = CY.GFive.Core.Business.NewsModule.SelectByName("招生动态"); if (moduleAdmission != null) {// EnRollInfos = CY.GFive.Core.Business.NewsContent.GetNewsContentDynamic(" top 6 ", "[ModuleID]='" + moduleAdmission.Id + "'", "[PublishTime] DESC").ToList(); EnRollInfo = CY.GFive.Core.Business.NewsContent.GetEnrollSingleTon(moduleAdmission); } } catch (Exception ex) { throw ex; } }
protected void Initial(ref List<CY.GFive.Core.Business.NewsContent> newscontents, ref CY.GFive.Core.Business.NewsModule module) { try { module = CY.GFive.Core.Business.NewsModule.GetAllNewsModule().Where(item => item.Name.Contains("短期培训项目")).FirstOrDefault(); if (module != null) { newscontents = CY.GFive.Core.Business.NewsContent.Search(new CY.GFive.Core.Business.NewsSearchJson { Module = (Guid?)module.Id }, new CY.GFive.Core.Business.PagingInfo()).OrderBy(item => item.PublishTime).Reverse().ToList(); if (newscontents != null) { newscontents = newscontents.Take(6).ToList(); } } } catch (Exception ex) { throw ex; } }
public void rpJobInfoDataBind() { try { moduleJobInfo = CY.GFive.Core.Business.NewsModule.SelectByName("用人单位"); if (moduleJobInfo != null) { List<CY.GFive.Core.Business.NewsContent> newsListJobInfo = CY.GFive.Core.Business.NewsContent.GetNewsContentDynamic(" top 6 ", "[ModuleID]='" + moduleJobInfo.Id + "'", "[PublishTime] DESC").ToList(); if (newsListJobInfo != null) { rpJobInfo.DataSource = newsListJobInfo; rpJobInfo.DataBind(); } } } catch (Exception ex) { throw ex; } }