Esempio n. 1
0
        public CustomerMayDetail(CustomerMayChoose conn)
            : this()
        {
            this.xrLabelReportName.Text = "‘ªÊÕÙ~¿îÃ÷¼šÙ~";
            DataSet ds = this.xobillmanager.SelectMayShou(conn.Customer1, conn.Customer2, conn.Employee1, conn.Employee2, conn.StartDate, conn.EndDate);

            if (ds == null || ds.Tables.Count == 0)
            {
                throw new global::Helper.InvalidValueException();
            }

            this.DataSource            = ds.Tables[0];
            this.xrLabelDateRange.Text = conn.StartDate.ToString("yyyy-MM-dd") + " ~ " + conn.EndDate.ToString("yyyy-MM-dd");
            // this.xrTableEmp.DataBindings.Add("Text", this.DataSource, "CusomerName");
            this.xrTableEmp.DataBindings.Add("Text", this.DataSource, "Employee1Name");

            this.xrTableSourceInvoiceDate.DataBindings.Add("Text", this.DataSource, "InvoiceDate", "{0:yyyy-MM-dd}");
            this.xrTableInvoiceIds.DataBindings.Add("Text", this.DataSource, "InvoiceId");
            this.xrTableMoney.DataBindings.Add("Text", this.DataSource, "Total", global::Helper.DateTimeParse.GetFormatA(BL.V.SetDataFormat.XSZJXiao.Value));
            this.xrTableHasMoneys.DataBindings.Add("Text", this.DataSource, "HasMoney", global::Helper.DateTimeParse.GetFormatA(BL.V.SetDataFormat.XSZJXiao.Value));
            this.xrTableNoMoneys.DataBindings.Add("Text", this.DataSource, "NoHeXiao", global::Helper.DateTimeParse.GetFormatA(BL.V.SetDataFormat.XSZJXiao.Value));

            this.xrTableSourceNames.DataBindings.Add("Text", this.DataSource, "SourceName");
            this.xrTableCustomer.DataBindings.Add("Text", this.DataSource, "CusomerName");
        }
Esempio n. 2
0
        /// <summary>
        /// 重写父类方法
        /// </summary>
        protected override void OnOK()
        {
            if (this.condition == null)
            {
                this.condition = new CustomerMayChoose();
            }
            condition.Employee1 = this.newChooseEmp1.EditValue as Model.Employee;
            condition.Employee2 = this.newChooseEmp2.EditValue as Model.Employee;
            condition.Customer1 = this.newChooseCustomer1.EditValue as Model.Customer;
            condition.Customer2 = this.newChooseCustomer2.EditValue as Model.Customer;
            if (global::Helper.DateTimeParse.DateTimeEquls(this.dateEditStartDate.DateTime, new DateTime()))
            {
                this.condition.StartDate = global::Helper.DateTimeParse.NullDate;
            }

            else
            {
                this.condition.StartDate = this.dateEditStartDate.DateTime;
            }


            if (global::Helper.DateTimeParse.DateTimeEquls(this.dateEditEndDate.DateTime, new DateTime()))
            {
                this.condition.EndDate = global::Helper.DateTimeParse.EndDate;
            }

            else
            {
                this.condition.EndDate = this.dateEditEndDate.DateTime;
            }


            //condition.YJDate = this.dateEditJZ.DateTime;
            //condition.Hasother = this.checkEdit1.Checked;
        }
Esempio n. 3
0
 public CustomerMayDetailB(CustomerMayChoose conn)
     : this()
 {
     this.xrLabelReportName.Text = "‘ªÊÕÙ~¿îÃ÷¼š±í";
     this.xrLabelDateRange.Text  = conn.StartDate.ToString("yyyy-MM-dd") + " ~ " + conn.EndDate.ToString("yyyy-MM-dd");
 }