如何在 Kendo UI Grid 中扩展过滤器菜单的宽度

How to extend width of filter menu in KendoUI Grid

我使用KendoUI Grid 来显示数据。当我在配置指南中使用columns.filterable时,显示的数据太长了。

如上图所示

并且我调查并使用 .k-multicheck-wrap 来扩展宽度。

但是我遇到的 css class 问题会影响到所有过滤器菜单。

所以我想影响上传时间列

您可以使用 jquery 和 filterMenuInit 事件。此事件仅触发一次 - 当您单击过滤器图标时。在那里你可以施展魔法。

filterMenuInit: function(e){
    if(e.field == "UploadedBy")
        {
            e.container.css({"width": "800px"});
        }
},

Dojo example