protected void Page_Load(object sender, EventArgs e)
        {
            ctlCostCenterTexboxAutoCompleteUpdatePanel.Update();
            CallOnObjectLookUpCalling();
            ctlCostCenterAutoComplete.BehaviorID = String.Format("CostCenterAutoCompleteEx{0}", ctlCostCenter.ClientID);
            SetAutoCompleteEvent();


            // companyId will be set by Objectcalling
            long costCenterID = UIHelper.ParseLong(CostCenterCode.ToString());
            SCGAutoCompleteParameter parameter = new SCGAutoCompleteParameter();

            parameter.CostCenterID = costCenterID;
            parameter.CompanyID    = CompanyId.Value;

            JavaScriptSerializer serializer = new JavaScriptSerializer();

            ctlCostCenterAutoComplete.ContextKey    = serializer.Serialize(parameter);
            ctlCostCenterAutoComplete.UseContextKey = true;

            //if (!Page.IsPostBack)
            //  BuildAutoCompleteParameter();
        }
示例#2
0
        /// <inheritdoc/>
        public string ToDelimitedString()
        {
            CultureInfo culture = CultureInfo.CurrentCulture;

            return(string.Format(
                       culture,
                       StringHelper.StringFormatSequence(0, 39, Configuration.FieldSeparator),
                       Id,
                       PrimaryKeyValueStf?.ToDelimitedString(),
                       StaffIdentifierList != null ? string.Join(Configuration.FieldRepeatSeparator, StaffIdentifierList.Select(x => x.ToDelimitedString())) : null,
                       StaffName != null ? string.Join(Configuration.FieldRepeatSeparator, StaffName.Select(x => x.ToDelimitedString())) : null,
                       StaffType != null ? string.Join(Configuration.FieldRepeatSeparator, StaffType) : null,
                       AdministrativeSex,
                       DateTimeOfBirth.HasValue ? DateTimeOfBirth.Value.ToString(Consts.DateTimeFormatPrecisionSecond, culture) : null,
                       ActiveInactiveFlag,
                       Department != null ? string.Join(Configuration.FieldRepeatSeparator, Department.Select(x => x.ToDelimitedString())) : null,
                       HospitalServiceStf != null ? string.Join(Configuration.FieldRepeatSeparator, HospitalServiceStf.Select(x => x.ToDelimitedString())) : null,
                       Phone != null ? string.Join(Configuration.FieldRepeatSeparator, Phone.Select(x => x.ToDelimitedString())) : null,
                       OfficeHomeAddressBirthplace != null ? string.Join(Configuration.FieldRepeatSeparator, OfficeHomeAddressBirthplace.Select(x => x.ToDelimitedString())) : null,
                       InstitutionActivationDate != null ? string.Join(Configuration.FieldRepeatSeparator, InstitutionActivationDate.Select(x => x.ToDelimitedString())) : null,
                       InstitutionInactivationDate != null ? string.Join(Configuration.FieldRepeatSeparator, InstitutionInactivationDate.Select(x => x.ToDelimitedString())) : null,
                       BackupPersonId != null ? string.Join(Configuration.FieldRepeatSeparator, BackupPersonId.Select(x => x.ToDelimitedString())) : null,
                       EmailAddress != null ? string.Join(Configuration.FieldRepeatSeparator, EmailAddress) : null,
                       PreferredMethodOfContact?.ToDelimitedString(),
                       MaritalStatus?.ToDelimitedString(),
                       JobTitle,
                       JobCodeClass?.ToDelimitedString(),
                       EmploymentStatusCode?.ToDelimitedString(),
                       AdditionalInsuredOnAuto,
                       DriversLicenseNumberStaff?.ToDelimitedString(),
                       CopyAutoIns,
                       AutoInsExpires.HasValue ? AutoInsExpires.Value.ToString(Consts.DateFormatPrecisionDay, culture) : null,
                       DateLastDmvReview.HasValue ? DateLastDmvReview.Value.ToString(Consts.DateFormatPrecisionDay, culture) : null,
                       DateNextDmvReview.HasValue ? DateNextDmvReview.Value.ToString(Consts.DateFormatPrecisionDay, culture) : null,
                       Race?.ToDelimitedString(),
                       EthnicGroup?.ToDelimitedString(),
                       ReactivationApprovalIndicator,
                       Citizenship != null ? string.Join(Configuration.FieldRepeatSeparator, Citizenship.Select(x => x.ToDelimitedString())) : null,
                       DateTimeOfDeath.HasValue ? DateTimeOfDeath.Value.ToString(Consts.DateTimeFormatPrecisionSecond, culture) : null,
                       DeathIndicator,
                       InstitutionRelationshipTypeCode?.ToDelimitedString(),
                       InstitutionRelationshipPeriod?.ToDelimitedString(),
                       ExpectedReturnDate.HasValue ? ExpectedReturnDate.Value.ToString(Consts.DateFormatPrecisionDay, culture) : null,
                       CostCenterCode != null ? string.Join(Configuration.FieldRepeatSeparator, CostCenterCode.Select(x => x.ToDelimitedString())) : null,
                       GenericClassificationIndicator,
                       InactiveReasonCode?.ToDelimitedString()
                       ).TrimEnd(Configuration.FieldSeparator.ToCharArray()));
        }