private void ToExamine() { Guid id = Guid.Parse(Request.QueryString["CompanyId"]); CompanyType type = (CompanyType)byte.Parse(Request.QueryString["CompanyType"]); AccountBaseType accounType = (AccountBaseType)byte.Parse(Request.QueryString["AccountType"]); AuditType auditType = (AuditType)int.Parse(Request.QueryString["AuditType"]); var address = ChinaPay.B3B.TransactionWeb.PublicClass.AddressShow.GetAddressBaseInfo(hfldAddressCode.Value); bool isUpgrade = false; CompanyUpgrade companyUpgrade = null; if (auditType == AuditType.ApplyAudit) { isUpgrade = true; companyUpgrade = CompanyUpgradeService.QueryCompanyUpgrade(id); } if ((type == CompanyType.Provider && !isUpgrade) || (isUpgrade && companyUpgrade.Type == CompanyType.Provider)) { AccountCombineService.AuditProviderInfo(id, GetProviderAuditInfo(address, isUpgrade)); } else { if (accounType == AccountBaseType.Individual) { AccountCombineService.AuditSupplier(id, GetSupplierIndividualAuditInfo(address, isUpgrade)); } else { AccountCombineService.AuditSupplier(id, GetSupplierEnterpriseInfo(address, isUpgrade)); } } }
private void Update() { var address = ChinaPay.B3B.TransactionWeb.PublicClass.AddressShow.GetAddressBaseInfo(hfldAddressCode.Value); if (address == null || string.IsNullOrEmpty(address.CountyCode)) { throw new ArgumentNullException("请选择所地"); } string strCompanyId = Request.QueryString["CompanyId"]; string strAccountType = Request.QueryString["AccountType"]; if (!string.IsNullOrEmpty(strCompanyId) && !string.IsNullOrEmpty(strAccountType)) { AccountBaseType accountType = (AccountBaseType)byte.Parse(strAccountType); Guid id = Guid.Parse(strCompanyId); if (accountType == AccountBaseType.Individual) { AccountCombineService.UpdateIndividualInfo(GetIndividualInfo(address)); } else { AccountCombineService.UpdateEnterpriseInfo(GetEnterpriseInfo(address)); } } }
private CompanyInfo GetCompanyInfo() { AddressInfo address = AddressInfo.GetAddress(this.hidAddress.Value); if (address == null || string.IsNullOrEmpty(address.CountyCode)) { throw new ArgumentNullException("请选择所地"); } string companyId = Request.QueryString["CompanyId"]; CompanyType companyType = (CompanyType)byte.Parse(Request.QueryString["CompanyType"]); AccountBaseType accountType = (AccountBaseType)byte.Parse(Request.QueryString["AccountType"]); return(new CompanyInfo { CompanyId = Guid.Parse(companyId), CompanyType = companyType, AccountType = accountType, CompanyName = this.txtCompanyName.Text.Trim(), Area = address.AreaCode, Province = address.ProvinceCode, City = address.CityCode, District = address.CountyCode, AbbreviateName = this.txtCompanyShortName.Text.Trim(), ZipCode = this.txtPostCode.Text.Trim(), Address = this.txtAddress.Text.Trim(), Faxes = this.txtFaxes.Text.Trim(), OfficePhones = this.txtCompanyPhone.Text.Trim(), ManagerEmail = this.txtEmail.Text.Trim(), ManagerName = this.txtPrincipal.Text.Trim(), ManagerCellphone = this.txtPrincipalPhone.Text.Trim(), Contact = this.txtLinkman.Text.Trim(), ContactPhone = this.txtLinkManPhone.Text.Trim(), EmergencyContact = this.txtUrgencyLinkMan.Text.Trim(), EmergencyCall = this.txtUrgencyLinkManPhone.Text.Trim(), ManagerQQ = this.txtQQ.Text.Trim(), }); }