Пример #1
0
        protected void DropDeliverType_SelectedIndexChanged(object sender, EventArgs e)
        {
            DeliverTypeInfo deliverTypeById = new DeliverTypeInfo();

            deliverTypeById = DeliverType.GetDeliverTypeById(DataConverter.CLng(this.DropDeliverType.SelectedValue));
            if (!deliverTypeById.IsNull)
            {
                this.LblDeliverTypeIntro.Text = deliverTypeById.Intro;
            }
        }
Пример #2
0
        private void BindControl(OrderInfo info)
        {
            this.LblOrderNum.Text   = info.OrderNum;
            this.HlkUserName.Text   = info.UserName;
            this.HlkAgentName.Text  = info.AgentName;
            this.HlkClientName.Text = info.ClientName;
            if (this.IsAdminPage)
            {
                this.HlkUserName.NavigateUrl   = string.Format("~/Admin/User/UserShow.aspx?UserName={0}", base.Server.UrlEncode(info.UserName));
                this.HlkClientName.NavigateUrl = string.Format("~/Admin/Crm/ClientShow.aspx?ClientId={0}", info.ClientId);
                this.HlkAgentName.NavigateUrl  = string.Format("~/Admin/User/UserShow.aspx?UserName={0}", base.Server.UrlEncode(info.AgentName));
            }
            this.CliendId = info.ClientId;
            if (info.NeedInvoice)
            {
                this.LblNeedInvoice.Text = "√";
            }
            else
            {
                this.LblNeedInvoice.Text      = "\x00d7";
                this.LblNeedInvoice.ForeColor = Color.FromArgb(0xff0000);
            }
            if (info.Invoiced)
            {
                this.LblInvoiced.Text = "√";
            }
            else
            {
                this.LblInvoiced.Text      = "\x00d7";
                this.LblInvoiced.ForeColor = Color.FromArgb(0xff0000);
            }
            this.LblStatus.Text = BaseUserControl.EnumToHtml <OrderStatus>(info.Status);
            switch (Order.GetPayStatus(info))
            {
            case PayStatus.WaitForPay:
                this.LblMoneyTotal.Text = BaseUserControl.EnumToHtml <PayStatus>(PayStatus.WaitForPay);
                break;

            case PayStatus.ReceivedEarnest:
                this.LblMoneyTotal.Text = BaseUserControl.EnumToHtml <PayStatus>(PayStatus.ReceivedEarnest);
                break;

            case PayStatus.Payoff:
                this.LblMoneyTotal.Text = BaseUserControl.EnumToHtml <PayStatus>(PayStatus.Payoff);
                break;
            }
            this.LblDeliverStatus.Text = BaseUserControl.EnumToHtml <DeliverStatus>(info.DeliverStatus);
            if (info.NeedInvoice)
            {
                this.LblInvoiceContent.Text = info.InvoiceContent;
            }
            this.LblRemark.Text            = info.Remark;
            this.LblBeginDate.Text         = info.BeginDate.ToString("yyyy-MM-dd");
            this.LblInputTime.Text         = info.InputTime.ToString("yyyy-MM-dd HH:mm:ss");
            this.LblContacterName.Text     = info.ContacterName;
            this.LblAddress.Text           = info.Address;
            this.LblZipCode.Text           = info.ZipCode;
            this.LblMobile.Text            = info.Mobile;
            this.LblPhone.Text             = info.Phone;
            this.LblEmail.Text             = info.Email;
            this.LblPaymentType.Text       = PaymentType.GetPaymentTypeById(info.PaymentType).TypeName;
            this.LblDeliverType.Text       = DeliverType.GetDeliverTypeById(info.DeliverType).TypeName;
            this.LblOutOfStockProject.Text = BaseUserControl.EnumToHtml <OutOfStockProject>(info.OutOfStockProject);
            this.LblDeliverTime.Text       = info.DeliveryTime;
            if (this.IsAdminPage)
            {
                this.LblMemo.Text            = info.Memo;
                this.LblMemo.Visible         = true;
                this.LtrMemoTitle.Visible    = true;
                this.ShowFunctionary.Visible = true;
                this.LblFunctionary.Text     = info.Functionary;
                this.LblOrderType.Text       = Choiceset.GetDataText("PE_Orders", "OrderType", info.OrderType);
            }
            else
            {
                this.LblMemo.Visible         = false;
                this.LtrMemoTitle.Visible    = false;
                this.ShowFunctionary.Visible = false;
            }
        }