public ActionResult EditarFormaPag() { FormasPagamentoBLL formaBLL = new FormasPagamentoBLL(); MLL.FormaPagamento forma = formaBLL.ObterPorId(formaBLL.DescriptografaID(Request.QueryString["codigo"])); return(View(forma)); }
public string ExcluirFormaPagamento(int codigo) { FormasPagamentoBLL formaBLL = new FormasPagamentoBLL(); MLL.FormaPagamento forma = formaBLL.ObterPorId(codigo); return(formaBLL.ExcluirFormaPag(forma).ToString()); }
public MLL.FormaPagamento ObterPorId(int id) { FormaPagamentoDAL formaDAL = new FormaPagamentoDAL(db); MLL.FormaPagamento forma = formaDAL.obtemPorId(id); return(forma); }
public JObject EditarFormaPag(MLL.FormaPagamento forma) { JObject obj = new JObject(); FormaPagamentoDAL formaDAL = new FormaPagamentoDAL(db); if (formaDAL.Editar(forma)) { obj.Add(new JProperty("ok", "ok")); } else { obj.Add(new JProperty("erro", formaDAL.erro)); } return(obj); }
public string ExcluirFormaPag(MLL.FormaPagamento formaPag) { string result = ""; FormaPagamentoDAL formaDAL = new FormaPagamentoDAL(db); if (formaDAL.Remover(formaPag)) { result = "ok"; } else { result = "erro - " + formaDAL.erro; } return(result); }
public string EditarFormaPag(MLL.FormaPagamento formaPag) { FormasPagamentoBLL formaBLL = new FormasPagamentoBLL(); return(formaBLL.EditarFormaPag(formaPag).ToString()); }
public string CadastrarFormaPagamento(MLL.FormaPagamento formaPag) { FormasPagamentoBLL formaBLL = new FormasPagamentoBLL(); return(formaBLL.CadastrarFormaPag(formaPag).ToString()); }