protected void EgvCompany_RowDataBound(object sender, GridViewRowEventArgs e)
 {
     if (e.Row.RowType == DataControlRowType.DataRow)
     {
         CompanyInfo dataItem = e.Row.DataItem as CompanyInfo;
         Label       label    = e.Row.FindControl("LblStatusInField") as Label;
         Label       label2   = e.Row.FindControl("LblCompanySize") as Label;
         Label       label3   = e.Row.FindControl("LblManagementForms") as Label;
         label.Text  = Choiceset.GetDataText("PE_Company", "StatusInField", dataItem.StatusInField);
         label2.Text = Choiceset.GetDataText("PE_Company", "CompanySize", dataItem.CompanySize);
         label3.Text = Choiceset.GetDataText("PE_Company", "ManagementForms", dataItem.ManagementForms);
     }
 }
 private void ShowInfo()
 {
     EasyOne.Model.Crm.CompanyInfo compayById = Company.GetCompayById(this.m_CompanyId);
     this.LblCompanyName.Text       = compayById.CompanyName;
     this.LblCountry.Text           = compayById.Country;
     this.LblProvince.Text          = compayById.Province;
     this.LblCity.Text              = compayById.City;
     this.LblAddress.Text           = compayById.Address;
     this.LblZipCode.Text           = compayById.ZipCode;
     this.LblAnnualSales.Text       = compayById.AnnualSales;
     this.LblBankAccount.Text       = compayById.BankAccount;
     this.LblBankOfDeposit.Text     = compayById.BankOfDeposit;
     this.LblBusinessScope.Text     = compayById.BusinessScope;
     this.LblCompanyPic.Text        = compayById.CompanyPic;
     this.LblCompanyIntro.Text      = compayById.CompanyIntro;
     this.LblCompanySize.Text       = Choiceset.GetDataText("PE_Company", "CompanySize", compayById.CompanySize);
     this.LblFax.Text               = compayById.Fax;
     this.LblHomepage.Text          = compayById.Homepage;
     this.LblPhone.Text             = compayById.Phone;
     this.LblRegisteredCapital.Text = compayById.RegisteredCapital;
     this.LblTaxNum.Text            = compayById.TaxNum;
     this.LblStatusInField.Text     = Choiceset.GetDataText("PE_Company", "StatusInField", compayById.StatusInField);
     this.LblManagementForms.Text   = Choiceset.GetDataText("PE_Company", "ManagementForms", compayById.ManagementForms);
 }
Beispiel #3
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;
            }
        }