using System; using System.Collections.Generic; using System.Data.SqlClient;//引用数据库客户端 using System.Linq; using System.Text; using System.Threading.Tasks; using System.Reflection; using System.Data; namespace PubilcHelper { public class DBHelper { //…
约束 public abstract class BaseModel { public int Id { get; set; } } 连接字符串 public static readonly string Customers = ConfigurationManager.ConnectionStrings["Customers"].ToString(); 通用数据库字符串 public class SqlBuilder<T> where T : BaseModel { pu…