public ActionResult Details(int id) { try { LogBLL.Insert(new LogDado("Details", "ContaReceber", _idUsuario)); using (var db = new Context()) { var _bll = new BLL.ContaReceberBLL(db, _idUsuario); var _contaReceber = _bll.FindSingle(e => e.idContaReceber == id, u => u.Cliente, u => u.Projeto.Cliente); return View(ContaReceberVM.GetContaReceber(_contaReceber)); } } catch (Exception ex) { RP.Util.Entity.ErroLog.Add(ex, Session.SessionID, _idUsuario); return RedirectToAction("Index", "Erro", new { area = string.Empty }); } }
public ActionResult Receber(int id) { try { using (var db = new Context()) { var _bll = new BLL.ContaReceberBLL(db, _idUsuario); var _contaReceber = _bll.FindSingle(e => e.idContaReceber == id, u => u.Cliente, u => u.Projeto.Cliente); var _result = ContaReceberVM.GetContaReceber(_contaReceber); _result.pagamento = DateTime.Now; _result.valorPago = _result.valorConta; return View(_result); } } catch (Exception ex) { RP.Util.Entity.ErroLog.Add(ex, Session.SessionID, _idUsuario); return RedirectToAction("Index", "Erro", new { area = string.Empty }); } }