public int InsertStory(StoryInfo story, int moduleId, int tabId)
{
using (IDataContext ctx = DataContext.Instance())
{
var rep = ctx.GetRepository<StoryInfo>();
rep.Insert(story);
var contentItem = new ContentItem()
{
Content = GetStoryContent(story.StoryId),
ContentTypeId = ContentTypeId,
Indexed = false,
ContentKey = "#view/" + story.StoryId.ToString(),
ModuleID = moduleId,
TabID = tabId
};
story.ContentItemID = Util.GetContentController().AddContentItem(contentItem);
rep.Update(story);
return story.StoryId;
}
}