我设法修复了查询,使datatables可以使用分页,但是完全分页不起作用,知道吗,为什么
<cfquery name="qFiltered">
SELECT #aColumnArray#
FROM #arguments.tn#
WHERE 1=1
<cfif cleanSearchCriteria NEQ "">
AND (
0 = 1
<cfloop list="#aColumnArray#" index="sSearch">
OR
#sSearch# LIKE <cfqueryparam value="%#cleanSearchCriteria#%" cfsqltype="cf_sql_varchar" />
</cfloop>
)
</cfif>
<cfif FilterOrderBy NEQ "">ORDER BY #FilterOrderBy#</cfif>
OFFSET #startRow#-1 ROWS FETCH NEXT #endRow# ROWS ONLY;
</cfquery>
我的js代码
$('#DataSetList').DataTable({
autoWidth: false,
pagingType: "full_numbers",
order: [[ 1, "desc" ]],
serverSide: true,
processing: true,
ajax: "table.cfc?method=getDataForTable
});
我错过什么了吗
暂无答案!
目前还没有任何答案,快来回答吧!