Rock.Web.UI.Controls.GridFilter.RegisterJavaScript C# (CSharp) Method

RegisterJavaScript() private method

Registers the java script.
private RegisterJavaScript ( ) : void
return void
        private void RegisterJavaScript()
        {
            const string scriptKey = "grid-filter-script";
            const string script = @"
            $('div.grid-filter header').click(function () {
            $('i.toggle-filter', this).toggleClass('fa-chevron-down fa-chevron-up');
            var $hf = $('input', this).first();
            if($hf.val() != 'true') {
            $hf.val('true');
            } else {
            $hf.val('false');
            }
            $(this).siblings('div').slideToggle();
            });
            ";
            ScriptManager.RegisterStartupScript( this, this.GetType(), scriptKey, script, true );
        }