示例#1
0
 public virtual void Update(AppConfig entity)
 {
     if (entity != null)
     {
         this.Context.Entry<AppConfig>(entity).State = EntityState.Modified;
     }
 }
示例#2
0
 public void Delete(AppConfig entity)
 {
     this.DbEntitySet.Remove(entity);
 }
示例#3
0
 public void Create(AppConfig entity)
 {
     this.DbEntitySet.Add(entity);
 }
示例#4
0
 public virtual void UpdateConfig(AppConfig per)
 {
     this.ThrowIfDisposed();
     if (per == null)
     {
         throw new ArgumentNullException("AppConfig");
     }
     this._configStore.Update(per);
     this.Context.SaveChanges();
 }
示例#5
0
 public virtual async Task UpdateAsync(AppConfig per)
 {
     this.ThrowIfDisposed();
     if (per == null)
     {
         throw new ArgumentNullException("AppConfig");
     }
     this._configStore.Update(per);
     await this.Context.SaveChangesAsync();
 }
示例#6
0
 public virtual int InsertConfig(AppConfig per)
 {
     this.ThrowIfDisposed();
     if (per == null)
     {
         throw new ArgumentNullException("AppConfig");
     }
     this._configStore.Create(per);
     return this.Context.SaveChanges();
 }