Exemplo n.º 1
0
        /// <summary>
        /// Shows the view.
        /// </summary>
        /// <param name="settings">The settings.</param>
        public void ShowView(List <AttributeValue> settings)
        {
            lUserName.Text = GetSettingValue(settings, "UserName");
            lPassword.Text = "********";

            using (var rockContext = new RockContext())
            {
                var packages = new DefinedValueService(rockContext)
                               .GetByDefinedTypeGuid(Rock.SystemGuid.DefinedType.BACKGROUND_CHECK_TYPES.AsGuid())
                               .Where(v => v.ForeignId == 1 && v.IsActive)
                               .Select(v => v.Value.Substring(TYPENAME_PREFIX.Length))
                               .ToList();
                lPackages.Text = packages.AsDelimited("<br/>");
            }

            nbSSLWarning.Visible             = !GetSettingValue(settings, "ReturnURL").StartsWith("https://");
            nbSSLWarning.NotificationBoxType = NotificationBoxType.Warning;

            pnlNew.Visible         = false;
            pnlViewDetails.Visible = true;
            pnlEditDetails.Visible = false;
            pnlPackages.Visible    = false;

            HideSecondaryBlocks(false);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Shows the view.
        /// </summary>
        /// <param name="settings">The settings.</param>
        public void ShowView(List <AttributeValue> settings)
        {
            ShowHighlightLabels(settings);

            lUserName.Text = GetSettingValue(settings, "UserName");
            lPassword.Text = "********";

            using (var rockContext = new RockContext())
            {
                var packages = new DefinedValueService(rockContext)
                               .GetByDefinedTypeGuid(Rock.SystemGuid.DefinedType.PROTECT_MY_MINISTRY_PACKAGES.AsGuid())
                               .Select(v => v.Value)
                               .ToList();
                lPackages.Text = packages.AsDelimited("<br/>");
            }

            nbSSLWarning.Visible             = !GetSettingValue(settings, "ReturnURL").StartsWith("https://");
            nbSSLWarning.NotificationBoxType = GetSettingValue(settings, "TestMode").AsBoolean() ? NotificationBoxType.Warning : NotificationBoxType.Danger;

            pnlNew.Visible         = false;
            pnlViewDetails.Visible = true;
            pnlEditDetails.Visible = false;
            pnlPackages.Visible    = false;

            HideSecondaryBlocks(false);
        }
Exemplo n.º 3
0
        /// <summary>
        /// Display the packages.
        /// </summary>
        private void DisplayPackages()
        {
            using (var rockContext = new RockContext())
            {
                var packages = new DefinedValueService(rockContext)
                               .GetByDefinedTypeGuid(Rock.SystemGuid.DefinedType.BACKGROUND_CHECK_TYPES.AsGuid())
                               .Where(v => v.ForeignId == 2 && v.IsActive)
                               .Select(v => v.Value.Substring(CheckrConstants.CHECKR_TYPENAME_PREFIX.Length))
                               .ToList();


                lPackages.Text = packages.AsDelimited("<br/>");
            }
        }
Exemplo n.º 4
0
        /// <summary>
        /// Shows the view.
        /// </summary>
        /// <param name="settings">The settings.</param>
        public void ShowView(List <AttributeValue> settings)
        {
            ShowHighlightLabels(settings);

            lUserName.Text = GetSettingValue(settings, "UserName");
            lPassword.Text = "********";

            using (var rockContext = new RockContext())
            {
                var packages = new DefinedValueService(rockContext)
                               .GetByDefinedTypeGuid(Rock.SystemGuid.DefinedType.PROTECT_MY_MINISTRY_PACKAGES.AsGuid())
                               .Select(v => v.Value)
                               .ToList();
                lPackages.Text = packages.AsDelimited("<br/>");
            }

            pnlNew.Visible         = false;
            pnlViewDetails.Visible = true;
            pnlEditDetails.Visible = false;
            pnlPackages.Visible    = false;

            HideSecondaryBlocks(false);
        }