public async Task<int> Delete(CollegeKpi stat) { await _repository.DeleteAsync(stat); return _repository.SaveChanges(); }
public async Task<IHttpActionResult> Post(CollegeKpi stat) { if (!ModelState.IsValid) return BadRequest(ModelState); await _service.Post(stat); return Ok(); }
public async Task<CollegeKpi> Post(CollegeKpi stat) { var item = await _repository.InsertOrUpdateAsync(stat); _repository.SaveChanges(); return item; }