public NovelReadRecordInfo GetRecentChapterByType(string userName, int contentType) { if (string.IsNullOrEmpty(userName)) { return(null); } using (var conn = DbConnection(DbOperation.Read)) { var repo = new Repository.LogRepo(conn); return(repo.GetRecentChapterByType(userName, contentType)); } }
public int ChapterReadLogLocalSync(NovelReadRecordInfo novelReadRecordInfo) { if (novelReadRecordInfo == null) { return(0); } using (var conn = DbConnection(DbOperation.Write)) { var repo = new Repository.LogRepo(conn); return(repo.ChapterReadLogLocalSync(novelReadRecordInfo)); } }
public int ChapterReadLog(ChapterLogInfo chapterLogInfo, NovelReadRecordInfo novelReadRecordInfo) { if (chapterLogInfo == null || novelReadRecordInfo == null) { return(0); } using (var conn = DbConnection(DbOperation.Write)) { var repo = new Repository.LogRepo(conn); return(repo.ChapterReadLog(chapterLogInfo, novelReadRecordInfo)); } }
public int NovelReadLog(NovelLogInfo model) { if (model == null) { return(0); } using (var conn = DbConnection(DbOperation.Write)) { var repo = new Repository.LogRepo(conn); return(repo.NovelReadLog(model)); } }
public IEnumerable <NovelReadRecordInfo> GetRecentChapterListExceptType(string userName, int exceptContentType, int top = 5) { if (string.IsNullOrEmpty(userName)) { return(null); } using (var conn = DbConnection(DbOperation.Read)) { var repo = new Repository.LogRepo(conn); return(repo.GetRecentChapterListExceptType(userName, exceptContentType, top)); } }
public int CreateUserInfo(UserLogInfo model) { if (model == null) { return(0); } using (var conn = DbConnection(DbOperation.Write)) { var repo = new Repository.LogRepo(conn); return(repo.CreateUserInfo(model)); } }