public T Get(dynamic pkValue) { var where = new WhereGrouping(WhereSpliceType.And); where.WhereItems.Add(new Where(this.DbService.Mapper.PrimaryKey.Name, pkValue, CompareType.等于)); return(this.DbService.SelectSingle(where, null, null)); }
public T Get <TForeign>(dynamic pkValue, JoinType join) where TForeign : DataEntity, new() { var where = new WhereGrouping(WhereSpliceType.And); where.WhereItems.Add(new Where(this.DbService.Mapper.PrimaryKey.Name, pkValue, CompareType.等于)); return(this.DbService.SelectSingle <TForeign>(where, join, null)); }
public dynamic Delete(dynamic pkValue) { var where = new WhereGrouping(WhereSpliceType.And); where.WhereItems.Add(new Where(this.DbService.Mapper.PrimaryKey.Name, pkValue, CompareType.等于)); return(this.DbService.Delete(where)); }