コード例 #1
0
        private List <IBinderValue> getNewTopic(int count, Type ownerType)
        {
            if (count <= 0)
            {
                count = 10;
            }

            List <ForumTopic> list = db.find <ForumTopic>(TopicStatus.GetShowCondition() + " and OwnerType=:otype order by Id desc")
                                     .set("otype", ownerType.FullName)
                                     .list(count);

            return(SysForumTopicService.populateBinderValue(list));
        }
コード例 #2
0
        public virtual List <IBinderValue> GetNewBoardTopic(String ids, int count)
        {
            if (count <= 0)
            {
                count = 10;
            }

            String sids = checkIds(ids);

            if (strUtil.IsNullOrEmpty(sids))
            {
                return(new List <IBinderValue>());
            }

            String bd = " and ForumBoardId in ( " + sids + " )";

            List <ForumTopic> list = db.find <ForumTopic>(TopicStatus.GetShowCondition() + bd + " and OwnerType=:otype order by Id desc")
                                     .set("otype", typeof(Site).FullName)
                                     .list(count);

            return(SysForumTopicService.populateBinderValue(list));
        }