Exemplo n.º 1
0
        private void btnPayFatura_Click(object sender, EventArgs e)
        {
            frmPayInvoice pay = new frmPayInvoice(report, ctrReport.Context);

            pay.ShowDialog();
            ctrReport = new ReportController();
            LoadFilds(date, ctrReport.GenerateByCreditCard(date, report.CreditCards[0]));
        }
Exemplo n.º 2
0
        private void FrmReport_Load(object sender, EventArgs e)
        {
            lbHolder.Text = "Titular: ";
            if (this.Payment is null)
            {
                ctrDash.LoadReport(date);
                report            = ctrDash.report;
                pnPayment.Visible = false;
                lbHolder.Visible  = false;
                lbName.Visible    = false;
            }
            else
            {
                pnReport.Visible  = false;
                pnPayment.Visible = true;
                if (this.Payment is Account)
                {
                    lbPayment.Text       = $"{ctrDash.GenerateCaptionHolder(Payment.Holder)} - {((Account)Payment).Bank}";
                    lbName.Text         += Payment.Holder;
                    lbName.Visible       = true;
                    lbHolder.Visible     = true;
                    btnPayFatura.Visible = false;
                    report = ctrReport.GenerateByAccount(date, ((Account)this.Payment));
                }
                else
                {
                    lbPayment.Text         = $"{ctrDash.GenerateCaptionHolder(Payment.Holder)} - {((CreditCard)Payment).Issuer}";
                    lbName.Text           += Payment.Holder;
                    lbName.Visible         = true;
                    lbHolder.Visible       = true;
                    lbCaptionRevenue2.Text = "Limite";
                    report = ctrReport.GenerateByCreditCard(date, ((CreditCard)this.Payment));
                }

                ctrDash.report = report;
            }

            LoadFilds(date, report);
            editDate = true;
        }