第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號安全,請及時綁定郵箱和手機立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

從控制器操作獲取數(shù)據(jù)到 jquery 數(shù)據(jù)表

從控制器操作獲取數(shù)據(jù)到 jquery 數(shù)據(jù)表

蕪湖不蕪 2021-08-20 15:00:08
我正在嘗試以 JSON 格式從控制器操作中獲取一些數(shù)據(jù),然后使用 AJAX 將其發(fā)送到 DataTables,數(shù)據(jù)已顯示,但當(dāng)我搜索或排序數(shù)據(jù)時,數(shù)據(jù)消失并顯示“未找到數(shù)據(jù)”消息,也不再有任何頁面這只是一張長桌。HTML表格:<table id="demoGrid" class="table  table table-hover dt-responsive nowrap" width="100%" cellspacing="0">    <thead>        <tr class="styleHeaderTab">            <th class="th-sm">                Matricule            </th>            <th class="th-sm">                Intitulé            </th>            <th class="th-sm">                Nombre de compte            </th>            <th class="">            </th>        </tr>    </thead>    <tbody id="chargeHolder"></tbody></table>腳本:$(document).ready(() => getActif());$('#demoGrid').dataTable({        "language": {            "search": "Rechercher",            "lengthMenu": "Afficher _MENU_ chargés par page",            "info": "Page: _PAGE_ / _PAGES_",            "paginate": {                "next": "Suivante",                "previous": "Précédente"            }        }    });function getActif() {        $.ajax({            url: '/ChargeAffaire/GetActif',            method: 'get',            dataType: 'json',            error: (err) => console.log(err),            success: (res) => {                let s="";                for (let i=0;i<res.length;i++) {                    s +=`<tr>                            <td>${res[i].matricule}</td>                            <td>${res[i].intitule}</td>                            <td> 59</td>
查看完整描述

2 回答

  • 2 回答
  • 0 關(guān)注
  • 184 瀏覽
慕課專欄
更多

添加回答

舉報

0/150
提交
取消
微信客服

購課補貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動學(xué)習(xí)伙伴

公眾號

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號