Esempio n. 1
0
    /// <summary>
    /// Save the Changes in the Global attributes of the Franchisee.
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void Save_Click(object sender, ImageClickEventArgs e)
    {
        var eGlobalAttributes = new EGlobalAttributes
        {
            AppointmentSlot      = 0,
            NumberOfPictures     = Convert.ToInt32(txtOtherPicture.Text),
            DaysToChangePassword = Convert.ToInt32(txtPasswordDay.Text),
            ScheduleTemplateID   =
                Convert.ToInt32(ddlEventScheduleTemp.SelectedValue),
            GlobalCutOffDate          = txtGCutoffDate.Text,
            SystemVersion             = Convert.ToString(txtSystemVersion.Text),
            Eventdistance             = Convert.ToInt64(txtEventdistance.Text),
            AdministratorEmailAddress =
                Convert.ToString(txtAdministratorEmailAddress.Text),
            CouponPrefix        = Convert.ToString(txtCouponPrefix.Text),
            DisplayQABar        = txtDisplayQABar.Text,
            MaxDollarCommission =
                Convert.ToDecimal(txtMaxCommissionDollarAdvocate.Text),
            MaxDollarCommissionSalesRep =
                Convert.ToDecimal(txtMaxCommissionDollarSalesRep.Text),
            MaxPercentCommission =
                Convert.ToDecimal(txtMaxCommissionPercentAdvocate.Text),
            MaxPercentCommissionSalesRep =
                Convert.ToDecimal(txtMaxCommissionPercentSalesRep.Text),
            CancellationFee           = Convert.ToDecimal(CancellationFeeTextbox.Text),
            HealthYesCompetitor       = txtHealthYesCompetitor.Text,
            EventStartTime            = ddlHHStartTime.SelectedItem.Text + ":" + ddlMMStartTime.SelectedItem.Text + " " + ddlAMPMStartTime.SelectedValue,
            EventEndTime              = ddlHHEndTime.SelectedItem.Text + ":" + ddlMMEndTime.SelectedItem.Text + " " + ddlAMPMEndTime.SelectedValue,
            MinimumPurchaseAmount     = Convert.ToDecimal(txtMinumPurchaseAmount.Text),
            IncomingPhoneLineRequired = IncomingPhoneLineRequiredYes.Checked ? Boolean.TrueString : Boolean.FalseString,
            EnableAlaCarte            = EnableAlacarteYes.Checked ? Boolean.TrueString : Boolean.FalseString,
            AreaCode                                            = txtAreaCode.Text,
            EnableBarCode                                       = EnableBarCodeYes.Checked ? Boolean.TrueString : Boolean.FalseString,
            UpsellPackage                                       = UpsellPackageYes.Checked ? Boolean.TrueString : Boolean.FalseString,
            UpsellCd                                            = UpsellCdYes.Checked ? Boolean.TrueString : Boolean.FalseString,
            UpsellAlaCarte                                      = UpsellAlaCarteYes.Checked ? Boolean.TrueString : Boolean.FalseString,
            MaxNoOfEventToShowOnline                            = Convert.ToInt32(MaxNoOfEventToShowOnlineTextbox.Text),
            MaxNoOfAppointmentSlotsToShowOnline                 = Convert.ToInt32(MaxNoOfAppointmentSlotsToShowOnlineTextbox.Text),
            EventListPageSizeOnline                             = Convert.ToInt32(EventListPageSizeOnlineTextbox.Text),
            PaperSize                                           = PaperSizeDropDownList.SelectedValue,
            DisplayPremiumVersiononPortal                       = DisplayPremVersionYes.Checked ? bool.TrueString : bool.FalseString,
            EnableResultDeliveryNotification                    = EnableDelNotificationYes.Checked ? bool.TrueString : bool.FalseString,
            EnableNewsletterPrompt                              = EnableNewsletterYes.Checked ? bool.TrueString : bool.FalseString,
            SourceCodeLabel                                     = SourceCodeLabelText.Text,
            CutOffHourNumberforOnlineEventSelection             = Convert.ToInt32(CutoffHoursforOnlineEventSelTextBox.Text),
            DisplayRescheduleAppointmentPortal                  = DisplayRescheduleAppointmentYes.Checked ? bool.TrueString : bool.FalseString,
            ShowBasicBiometric                                  = ShowBasicBiometricYes.Checked ? bool.TrueString : bool.FalseString,
            EnableQuickOnsiteRegistration                       = EnableQuickOnsiteRegistrationYes.Checked ? bool.TrueString : bool.FalseString,
            PayLaterOnlineRegistration                          = PayLaterOnlineRegistrationYes.Checked ? bool.TrueString : bool.FalseString,
            RestrictAvailableTimeSlotForCorporate               = RestrictAvailableTimeSlotForCorporateYes.Checked ? bool.TrueString : bool.FalseString,
            ScreeningReminderNotification                       = ScreeningReminderNotificationYes.Checked ? bool.TrueString : bool.FalseString,
            IsHipaaEnabled                                      = HipaaEnabledYes.Checked ? bool.TrueString : bool.FalseString,
            EnableDynamicSlot                                   = EnableDynamicSlotYes.Checked ? bool.TrueString : bool.FalseString,
            LunchStartTime                                      = ddlHHLunchStartTime.SelectedItem.Text + ":" + ddlMMLunchStartTime.SelectedItem.Text + " " + ddlAMPMLunchStartTime.SelectedValue,
            SendEmptyQueueEvaluationReminder                    = SendEmptyQueueEvaluationReminderYes.Checked ? bool.TrueString : bool.FalseString,
            EventBookingThreshold                               = Convert.ToInt32(EventBookingTresholdTextbox.Text),
            PackageSelectionInfo                                = PackageSelectionInfoYes.Checked ? bool.TrueString : bool.FalseString,
            EnableSmsNotification                               = SmsEnabledYes.Checked ? bool.TrueString : bool.FalseString,
            EnablePhysicianPartnerCustomerResultFaxNotification = FaxEnabledYes.Checked ? bool.TrueString : bool.FalseString,
            EnableAWVCustomerResultFaxNotification              = AWVFaxEnabledYes.Checked ? bool.TrueString : bool.FalseString,
            AskPreQualificationQuestion                         = AskPreQualificationQuestionYes.Checked ? bool.TrueString : bool.FalseString,
            PasswordExpirationDays                              = passwordExpiryDaysCount.Text,
            PreviousPasswordNonRepetitionCount                  = previousPasswordNonRepetitionCount.Text,
            OtpNotificationMediumEmail                          = otpEmail.Checked ? bool.TrueString : bool.FalseString,
            OtpNotificationMediumSms                            = otpSms.Checked ? bool.TrueString : bool.FalseString,
            OtpExpirationMinutes                                = Convert.ToInt32(otpExpirationMinutes.Text),
            OtpMisMatchAttemptCount                             = Convert.ToInt32(otpMisMatchAttemptCount.Text),

            OtpByGoogleAuthenticator            = googleAuthenticator.Checked ? bool.TrueString : bool.FalseString,
            AllowSafeComputerRemember           = allowSafeComputerRemember.Checked ? bool.TrueString : bool.FalseString,
            SafeDeviceExpiryDays                = Convert.ToInt32(safeDeviceExpiryDays.Text),
            AlertBeforePasswordExpirationInDays = Convert.ToInt32(alertBeforePasswordExpirationInDays.Text),
            EnableVoiceMailNotification         = VoiceMailEnabledYes.Checked ? bool.TrueString : bool.FalseString,
        };


        var   franchisorDal = new FranchisorDAL();
        Int64 returnresult  = franchisorDal.SaveFranchisorGlobalAttributes(eGlobalAttributes);

        divErrorMsg.Visible = true;
    }