public override void Remove(T item) { WidgetBasePartService.Remove(item.ID); }
public override T GetSingle(Expression <Func <T, bool> > filter) { var widgetBase = WidgetBasePartService.GetSingle(Expression.Lambda <Func <WidgetBasePart, bool> >(filter.Body, filter.Parameters)); return(widgetBase.CopyTo(JsonConvert.DeserializeObject <T>(widgetBase.ExtendData ?? "{}")) as T); }
public override void Remove(Expression <Func <T, bool> > filter) { WidgetBasePartService.Remove(Expression.Lambda <Func <WidgetBasePart, bool> >(filter.Body, filter.Parameters)); }
public override void RemoveRange(params T[] items) { WidgetBasePartService.RemoveRange(items.Select(m => m.ToWidgetBasePart()).ToArray()); }
public override T Get(params object[] primaryKeys) { var item = WidgetBasePartService.Get(primaryKeys); return(item.CopyTo(JsonConvert.DeserializeObject <T>(item.ExtendData ?? "{}")) as T); }
public override void Update(T item, bool saveImmediately = true) { item.ExtendData = JsonConvert.SerializeObject(item); WidgetBasePartService.Update(item.ToWidgetBasePart(), saveImmediately); }
public override void Remove(T item, bool saveImmediately = true) { WidgetBasePartService.Remove(item.ID); }
public override void Add(T item) { item.ID = Guid.NewGuid().ToString("N"); item.ExtendData = JsonConvert.SerializeObject(item); WidgetBasePartService.Add(item.ToWidgetBasePart()); }
public override ServiceResult <T> UpdateRange(params T[] items) { WidgetBasePartService.UpdateRange(items.Select(m => m.ToWidgetBasePart()).ToArray()); return(base.UpdateRange(items)); }
public override ServiceResult <T> Update(T item, bool saveImmediately = true) { WidgetBasePartService.Update(item.ToWidgetBasePart()); return(base.Update(item, saveImmediately)); }
public override void Remove(T item, bool saveImmediately = true) { base.Remove(item, saveImmediately); WidgetBasePartService.Remove(item.ToWidgetBasePart()); }
public override void Update(T item, bool saveImmediately = true) { WidgetBasePartService.Update(item.ToWidgetBasePart()); base.Update(item, saveImmediately); }