public static SqlCP Condition(this object instance, SqlCondition condition) { SqlCP cp = new SqlCP(); cp.Instance = instance; cp.Query = condition.Query; cp.Tails = condition.Tails; cp.Order = condition.Order; condition.Claer(); return(cp); }
protected ReturnResult DeleteResult(SqlCP cp, string msg = "删除失败!", ForceDelete flag = ForceDelete.No) { return(Result(driver.Delete(cp, flag), msg)); }
protected ReturnResult ModifyResult(SqlCP cp, string msg = "更新失败!") { return(Result(driver.Modify(cp), msg)); }
protected ReturnResult GetsResult(SqlCP cp, string msg = "查询失败!") { return(Result(driver.Gets(cp), msg)); }
protected ReturnPageResult GetsPageResult(SqlCP <T> cp_value, string msg = "查询失败!") { return(Result(driver.Gets(cp_value), driver.CountWithCondition(cp_value), msg)); }