public ServicePaymentFormModel ConvertPaymentToModel(tbPayment payment) { try { ServicePaymentFormModel model = new ServicePaymentFormModel() { id = payment.pay_id, usuario = this.getUsuerNameByIdUser(payment.usu_id), estado_pago = payment.pst_id, concepto = payment.pay_concepto, monto = this.ConvertIntToString(payment.pay_monto), producto = this.ConvertProductoCode(payment.pay_producto), cuotas = payment.pay_cuotas, url_formulario = payment.pay_url_formulario, url_formulario_custom = payment.pay_url_formulario_custom, emails = payment.pay_email_to, emails_enviados = payment.pay_cantidad_mails_enviados, informacion_adicional = payment.pay_informacion_adicional, fecha = payment.pay_fecha.ToString("dd/MM/yyyy HH:mm:ss") }; return(model); } catch (Exception ex) { throw ex; } }
public ServicePaymentModel ConvertPaymentToModel(tbPayment payment) { try { ServicePaymentFormModel modelForm = base.ConvertPaymentToModel(payment); this.id = modelForm.id; this.usuario = modelForm.usuario; this.concepto = modelForm.concepto; this.monto = modelForm.monto; this.producto = modelForm.producto; this.cuotas = modelForm.cuotas; this.url_formulario = modelForm.url_formulario; this.emails = modelForm.emails; this.emails_enviados = modelForm.emails_enviados; this.estado_pago = modelForm.estado_pago; this.informacion_adicional = modelForm.informacion_adicional; this.fecha = modelForm.fecha; return(this); } catch (Exception ex) { throw ex; } }