public async Task <bool> Delete(ServiceFacility entity) { try { _dbContext.ServiceFacilities.Remove(entity); await _dbContext.SaveChangesAsync(); return(true); } catch (Exception e) { return(false); } }
public async Task <bool> Insert(ServiceFacility entity) { try { await _dbContext.ServiceFacilities.AddAsync(entity); await _dbContext.SaveChangesAsync(); return(true); } catch (Exception e) { return(false); } }
public int Insert(ServiceFacility model) { var stmtId = "ServiceFacility.Insert"; return((int)Dao.Insert(stmtId, model)); }