Ejemplo n.º 1
0
        private void lookUpEditCollectionAccount_EditValueChanged(object sender, EventArgs e)
        {
            string collectionAccount = "";

            if (this.lookUpEditCollectionAccount.EditValue != null)
            {
                collectionAccount = this.lookUpEditCollectionAccount.EditValue.ToString();
            }
            IList <Model.AtBillsIncome> billList = billIncomeManager.SelectAtBillsIncomeByBillsOften("0", collectionAccount);

            bList = new List <Model.AtBillsIncome>();
            if (billList != null)
            {
                foreach (Model.AtBillsIncome i in billList)
                {
                    Model.AtBankAccount at = bankAccountManager.Get(i.CollectionAccount);
                    Model.Customer      cu = new BL.CustomerManager().Get(i.PassingObject);
                    if (at != null)
                    {
                        i.C = at.BankAccountName;
                    }
                    if (cu != null)
                    {
                        i.A = cu.ToString();
                    }
                    bList.Add(i);
                }
            }
            this.bindingSourcestringbillsOften.DataSource = billList;
        }
Ejemplo n.º 2
0
        private void Binds()
        {
            IList <Model.AtBillsIncome> billList = billIncomeManager.SelectDuiXianByDate(this.dateEdit1.DateTime, this.dateEdit2.DateTime, this.dateEditDaoQi1.EditValue == null ? global::Helper.DateTimeParse.NullDate : this.dateEditDaoQi1.DateTime, this.dateEditDaoQi2.EditValue == null ? global::Helper.DateTimeParse.EndDate : this.dateEditDaoQi2.DateTime, "1", this.comboBoxProduceType.SelectedIndex.ToString());

            bList = new List <Model.AtBillsIncome>();
            if (billList != null)
            {
                foreach (Model.AtBillsIncome i in billList)
                {
                    //if (i.BillsOften == "托收中" || i.BillsOften == "票貼中" || i.BillsOften == "尚未兌現")
                    {
                        //  Model.AtBankAccount at = bankAccountManager.Get(i.CollectionAccount);
                        if (this.comboBoxProduceType.SelectedIndex == 0)
                        {
                            Model.Customer cu = new BL.CustomerManager().Get(i.PassingObject);
                            i.B = cu.ToString();
                        }
                        else
                        {
                            Model.Supplier su = new BL.SupplierManager().Get(i.PassingObject);
                            // i.A = cu.Id;
                            i.B = su.ToString();
                        }
                        //if (at != null)
                        //{
                        //    i.C = at.BankAccountName;
                        //}

                        bList.Add(i);
                    }
                }
            }
            this.bindingSourcestringbillsOften.DataSource = bList;
        }
Ejemplo n.º 3
0
        public BillCollectionForm()
        {
            InitializeComponent();
            IList <Model.AtBillsIncome> billList = billIncomeManager.SelectAtBillsIncomeByBillsOften("0", null);

            bList = new List <Model.AtBillsIncome>();
            if (billList != null)
            {
                foreach (Model.AtBillsIncome i in billList)
                {
                    Model.AtBankAccount at = bankAccountManager.Get(i.CollectionAccount);
                    Model.Customer      cu = new BL.CustomerManager().Get(i.PassingObject);
                    if (at != null)
                    {
                        i.C = at.BankAccountName;
                    }
                    if (cu != null)
                    {
                        i.A = cu.ToString();
                    }
                    bList.Add(i);
                }
            }
            this.bindingSourcestringbillsOften.DataSource = billList;
            //this.bindingSourceAtBankAccount.DataSource = bankAccountManager.Select();
        }