JS取消分页功能

在这里插入图片描述
$(".k-pager-wrap.k-grid-pager.k-widget.k-floatwrap").hide();

  @(Html.Kendo().Grid<EMS.Models.CallRepair>()
                                                                       .Name("grid")
                                                                       .Columns(columns =>
                                                                       {
                                                                           //columns.Bound(c => c.Id).Filterable(false).Sortable(false).Width(140);
                                                                           columns.Bound(c => c.Begin_Repair_No).Filterable(false).Sortable(false).Width(90);
                                                                           columns.Bound(c => c.MachineNo).Filterable(false).Sortable(false).Width(60);
                                                                           //columns.Bound(c => c.BomPartNo).Filterable(false).Sortable(false).Width(50); 
                                                                           columns.Bound(c => c.PartNo).Filterable(false).Sortable(false).Width(80);
                                                                           columns.Bound(c => c.PartDesc).Filterable(false).Sortable(false).Width(130);
                                                                         
                                                                           //columns.Bound(c => c.Unit).Filterable(false).Sortable(false).Width(30);
                                                                           columns.Bound(c => c.StoreCode).Filterable(false).Sortable(false).Width(60);
                                                                           columns.Bound(c => c.StoreQty).Filterable(false).Sortable(false).Width(50);
                                                                           columns.Bound(c => c.ReqQty).Filterable(false).Sortable(false).Width(50);
                                                                           columns.Bound(c => c.GiQty).Filterable(false).Sortable(false).Width(50);
                                                                           columns.Bound(x => x.AQty).ClientTemplate("<input style=\"width:40px;background-color:yellow \" ID=\"Q_#=Id#\" value=\"0\" type =\"textbox\" onblur=\"Onbb(#=Id#)\"/> ").Sortable(false).Width(60);
                                                                           columns.Bound(c => c.Line_Name).Hidden(true).Filterable(false).Sortable(false).Width(40);
                                                                       })
                                                                       .DefaultOptions()
                                                                                   .Filterable(f => f.Enabled(false))
                                                                                   .Events(e => e.DataBound("boundGridMaintainStatus"))
                                                                                   .DataSource(dataSource => dataSource
                                                                                   .Ajax()
                                                                                   .Batch(true)
                                                                                   .Read(read => read.Action("GetRepairGIInfo", Html.ControllerName(), new { strOrderNumber = Model.Begin_Repair_No }))
                                                                                   .ServerOperation(true)
                                                                                   .Model(m =>
                                                                                   {
                                                                                       m.Id(c => c.Id);

                                                                                   })))
    $(document).ready(function () {
    
    
        $(".k-pager-wrap.k-grid-pager.k-widget.k-floatwrap").hide();

            $("#grid").kendoTooltip({
    
    
                show: function (e) {
    
    
                    if ($.trim(this.content.text()) != "") {
    
    
                        $('[role="tooltip"]').css("visibility", "visible");
                    }
                },
                hide: function () {
    
    
                    $('[role="tooltip"]').css("visibility", "hidden");
                },
                filter: "td:nth-child(n+3)",
                content: function (e) {
    
    
                    var element = e.target[0];
                    if (element.offsetWidth < element.scrollWidth) {
    
    
                        var text = $(e.target).text();
                        return '<div style="min-width:50px;max-width: 500px;">' + text + '</div>';
                    } else {
    
    
                        $('[role="tooltip"]').css("visibility", "hidden");//解决鼠标一开始放在上面出现空模块
                        return "";
                    }
                }
            }).data("kendoToolTip");
        });

猜你喜欢

转载自blog.csdn.net/caoguanghui0804/article/details/112168646