Beispiel #1
0
        public string CreatePage(int topicId, DateTime?reDate)
        {
            Topic topic = topicBLL.GetTopic(topicId);
            Dictionary <string, string> dic = null;

            if (topic.TopicTypeGenerate != "最新")
            {
                dic = new Dictionary <string, string>();
                dic.Add("newsdate", topic.CreatedTime.ToString());
            }
            if (topic.TopicTypeGenerate == "每日")
            {
                dic.Add("reDate", reDate.ToString());
            }
            if (HtmlServer.CreateTemplatePage(topic.TemplateId, dic))
            {
                return("发布成功");
            }
            return("发布失败");
        }