コード例 #1
0
        public TopicRepliesModel GetReplies(int tid, string user, string showType)
        {
            try
            {
                var response =
                    TasksService.GetRepliesForUser(new GetRepliesForUserRequest
                {
                    TopicId  = tid,
                    User     = user,
                    Start    = DateTime.Now,
                    End      = DateTime.Now.AddMonths(-6),
                    ShowType = (RepliesShowType)Enum.Parse(typeof(RepliesShowType), showType)
                });

                return(new TopicRepliesModel(tid, response.Replies, response.HasOldReplies));
            }
            catch (Exception ex)
            {
                throw new HttpResponseException(HttpStatusCode.BadRequest);
            }
        }