コード例 #1
0
ファイル: Main.cs プロジェクト: Rillanon/FP-PMS
 private void applyCreditToolStripMenuItem_Click(object sender, EventArgs e)
 {
     var claimantChoose = new Accounting.Invoice.claimantSelectViewForm();
     claimantChoose.ShowDialog();
     if (claimantChoose.DialogResult == DialogResult.OK)
     {
         var newCreditApplyForm = new Accounting.Credit.addCreditViewForm(claimantChoose.myClaimant);
         newCreditApplyForm.ShowDialog();
         newCreditApplyForm.Dispose();
     }
     claimantChoose.Dispose();
 }
コード例 #2
0
ファイル: Main.cs プロジェクト: Rillanon/FP-PMS
        private void multipleReceiptsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            var claimantChoose = new Accounting.Invoice.claimantSelectViewForm();
            claimantChoose.ShowDialog();
            if (claimantChoose.DialogResult == DialogResult.OK)
            {
                var newDateInterval = new Report.dateIntervalDialog();
                newDateInterval.ShowDialog();

                if (newDateInterval.DialogResult == DialogResult.OK)
                {
                    var newReceiptForm = new Accounting.Receipt.receiptViewForm(claimantChoose.myClaimant);
                    newReceiptForm.removeBtnEvent();
                    newReceiptForm.okBtn.Click += new EventHandler(receiptOkBtnClick);
                    newReceiptForm.IsMulti = true;
                    newReceiptForm.ShowDialog();

                    if (newReceiptForm.DialogResult == DialogResult.OK)
                    {
                        var foo = new Accounting.Receipt.multiReceiptViewForm(claimantChoose.myClaimant, newDateInterval.startDate, newDateInterval.endDate,
                            newReceiptForm.myReceipt, newReceiptForm.myPaymentLines);

                        foo.ShowDialog();
                        foo.Dispose();
                        newReceiptForm.Dispose();
                    }
                    else
                    { newReceiptForm.Dispose(); }
                }
                newDateInterval.Dispose();
            }
            claimantChoose.Dispose();
        }
コード例 #3
0
ファイル: Main.cs プロジェクト: Rillanon/FP-PMS
        private void cancelInvoiceToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (staticProperties.userLevel == 1)
            {
                var claimantChoose = new Accounting.Invoice.claimantSelectViewForm();
                claimantChoose.ShowDialog();
                if (claimantChoose.DialogResult == DialogResult.OK)
                {
                    var newDateInterval = new Report.dateIntervalDialog();
                    newDateInterval.ShowDialog();

                    if (newDateInterval.DialogResult == DialogResult.OK)
                    {
                        var foo = new Accounting.Invoice.cancellInvoiceViewForm(claimantChoose.myClaimant, newDateInterval.startDate, newDateInterval.endDate);

                        foo.ShowDialog();
                        foo.Dispose();
                    }
                    newDateInterval.Dispose();
                }
                claimantChoose.Dispose();
            }
            else
            {
                MessageBox.Show("General user can not access this function.");
            }
        }
コード例 #4
0
ファイル: Main.cs プロジェクト: Rillanon/FP-PMS
        private void invoiceByClaimantToolStripMenuItem_Click(object sender, EventArgs e)
        {
            var claimantChoose = new Accounting.Invoice.claimantSelectViewForm();
            claimantChoose.ShowDialog();
            if (claimantChoose.DialogResult == DialogResult.OK)
            {
                var newDateInterval = new Report.dateIntervalDialog();
                newDateInterval.ShowDialog();

                if (newDateInterval.DialogResult == DialogResult.OK)
                {
                    var foo = new Claimant.claimantInvoiceViewForm(claimantChoose.myClaimant, newDateInterval.startDate, newDateInterval.endDate);

                    foo.ShowDialog();
                    foo.Dispose();
                }
                newDateInterval.Dispose();
            }
            claimantChoose.Dispose();
        }
コード例 #5
0
ファイル: invoiceController.cs プロジェクト: Rillanon/FP-PMS
        //When making a blank invoice.
        public void chooseClaimant()
        {
            myClaimantSelectForm = new claimantSelectViewForm();
            myClaimantSelectForm.ShowDialog();

            if (myClaimantSelectForm.DialogResult == DialogResult.OK)
            {
                myClaimant = myClaimantSelectForm.myClaimant;
                this.newInvoice();
                myClaimantSelectForm.Dispose();
            }
        }