public static void Insert(BookTagViewModel target) { var dao = new BookTagDao(); dao.Insert(target.ToEntity()); s_logger.Debug($"INSERT BookTag:{target}"); }
public override void DropTable(IConnection connection) { var dao = new BookTagDao(); dao.DropTable(); ++ModifiedCount; }
public static void Delete(BookTagViewModel deleteEntity) { var dao = new BookTagDao(); dao.Delete(new Dictionary <string, object>() { { "BookID", deleteEntity.BookID }, { "TagID", deleteEntity.TagID } }); }
public static bool Exists(BookTagViewModel target) { var dao = new BookTagDao(); return(dao.CountBy(new Dictionary <string, object>() { { "BookID", target.BookID }, { "TagID", target.TagID } }) > 0); }
public override void CreateTable(IConnection connection) { var dao = new BookTagDao(); dao.CreateTableIfNotExists(); ++ModifiedCount; dao.CreateIndexIfNotExists(); ++ModifiedCount; }
public static long CountAll() { var dao = new BookTagDao(); return(dao.CountAll()); }
public static IEnumerable <BookTagViewModel> FindAll() { var dao = new BookTagDao(); return(dao.FindAll().ToViewModel()); }