Esempio n. 1
0
        /// <summary>
        /// 对增删查改页面使用的Ajax表格操作列进行标准的设置
        /// 添加以下按钮
        /// - 查看按钮(如果编辑Url不是空)
        /// </summary>
        /// <typeparam name="TBuilder">构建器的类型</typeparam>
        /// <param name="column">操作列</param>
        /// <param name="request">搜索请求</param>
        public static void StandardSetupForCrudPage <TBuilder>(
            this AjaxTableActionColumn column, AjaxTableSearchRequest request)
            where TBuilder : class, ICrudPageBuilder, new()
        {
            var app = new TBuilder();

            if (!string.IsNullOrEmpty(app.EditUrl))
            {
                column.AddEditActionForCrudPage <TBuilder>();
            }
        }