bootgrid jquery选择行

时间:2017-03-21 16:05:24

标签: jquery asp.net ajax jquery-bootgrid

我在我的asp.net mvc中使用B​​ootgrid jquery,并且我正在尝试使行可选,我尝试了我在网上找到但它仍然无法正常工作,它显示没有选择功能

<table class="table  table-condensed table-hover table-striped col-md-12" id="tbl-Produits">
    <thead>
        <tr>

            <td data-column-id="Nom">Nom du Produit</td>
            <td data-column-id="Type"> Type du Produit</td>

            <td data-column-id="LastVersion">Dernière version </td>
            </tr>
    </thead>
    <tbody></tbody>
</table>

<script type="text/javascript">
    $(document).ready(function () {
        var ProduitsGrid = $("#tbl-Produits").bootgrid({
            ajax: true,
            selection: true,
            multiSelect: false,
            rowSelect: true,
            url: "@Url.Action("getall")",.....

1 个答案:

答案 0 :(得分:2)

您需要为一列设置data-identifier =“true”。 正如文档所说:

  

确保在一个数据属性data-identifier =“true”上设置   列标题。

See here