public void Delete() { SysProduct pro = new SysProduct(); pro.ProductId = 58; _dba.Delete(pro); var dt = _dba.QueryDataTable("select * from sys_product where ProductName=@ProductName", new { ProductName = "zwb" }); Console.WriteLine(DataTableUtil.ToString(dt)); }
public void Delete() { SysProduct pro = new SysProduct(); pro.ProductId = 58; _dba.Delete(pro); var dt = _dba.QueryDataTable("select * from sys_product where ProductName=@ProductName", new { ProductName = "zwb" }); Console.WriteLine(DataTableUtil.ToString(dt)); }
public void Update() { SysProduct pro = new SysProduct(); pro.ProductId = 59; pro.ProductName = "zwb"; pro.RecordStatus = "Inactive"; _dba.Update(pro); var dt = _dba.QueryDataTable("select * from sys_product where ProductName=@ProductName", new { ProductName = "zwb" }); Console.WriteLine(DataTableUtil.ToString(dt)); }
public void Insert() { SysProduct pro = new SysProduct(); pro.ProductName = "zwb"; pro.RecordStatus = "Active"; _dba.Insert(pro); var dt = _dba.QueryDataTable("select * from sys_product where ProductName=@ProductName", new { ProductName = "zwb" }); Console.WriteLine(DataTableUtil.ToString(dt)); }