public static string MakeFormsAjax(this AjaxHelper helper)
        {
            const string template =
                @"$.ajaxFormsExtensions.MakeFormsAjax();";

            return(JQueryHelpers.WrapWithJQueryReadyAndScriptTag(template).ToString());
        }
Beispiel #2
0
        public static HtmlTag ContextDataForRequests(this HtmlHelper helper, object parameters)
        {
            const string template       = @"$.pageActions.contextDataForRequests = {0};";
            var          parametersJson = JsonUtil.ToJson(parameters);
            var          script         = string.Format(template, parametersJson);

            return(JQueryHelpers.WrapWithJQueryReadyAndScriptTag(script));
        }
Beispiel #3
0
        public static HtmlTag RefreshFilterForm(this HtmlHelper helper, string filterForm)
        {
            const string template =
                @"$.pageActions.RefreshFilterForm('{0}')";
            var script = string.Format(template, filterForm);

            return(JQueryHelpers.WrapWithJQueryReadyAndScriptTag(script));
        }
Beispiel #4
0
        public static HtmlTag ButtonAction(string buttonName, string action)
        {
            const string template =
                @"$.pageActions.ButtonAction('{0}','{1}');";
            var script = string.Format(template, buttonName, action);

            return(JQueryHelpers.WrapWithJQueryReadyAndScriptTag(script));
        }
        public static string FilterForm(this AjaxHelper helper, string formSelector, string targetSelector)
        {
            const string template =
                @"$.ajaxFormsExtensions.FilterForm('{0}','{1}');";
            var script = string.Format(template, formSelector, targetSelector);

            return(JQueryHelpers.WrapWithJQueryReadyAndScriptTag(script).ToString());
        }
        public static HtmlTag SelectList(string name)
        {
            var script = string.Format(Template, name);

            return(JQueryHelpers.WrapWithJQueryReadyAndScriptTag(script));
        }