public void Delete(string id) { var proposal = proposalService.GetById(id); proposalService.Delete(proposal); proposalService.Save(); }
public IActionResult GetById(int id) { var result = _proposalService.GetById(id); if (result.Success) { return(Ok(result)); } return(BadRequest(result.Message)); }
public async Task <IActionResult> GetById(int proposalId) { var proposal = await _proposalService.GetById(proposalId); return(new ObjectResult(proposal)); }
public ProposalModel GetById(int id) { return(_proposalService.GetById(id)); }