How to clear layui table

爱喝马黛茶的安东尼
Release: 2019-07-11 11:13:36
Original
11802 people have browsed it

How to clear layui table

Listen to checkbox events:

var checkedArr=[];
table.on('checkbox(demo)', function(obj){if (obj.type=='all') 。
Copy after login

How to clear layui table

Enter code:

return;if (obj.checked){
checkedArr.push(obj.data.LAY_TABLE_INDEX); 
//checkedArr[obj.data.id] = obj.data.LAY_TABLEINDEX}
else
{delete checkedArr[obj.data.LAY_TABLE_INDE 
//delete checkedArr[obj.data.id。
Copy after login

How to clear layui table

Related recommendations: "layui framework tutorial"

Get the content of the selected row in the table and get the unique value needed for deletion, usually the id.

How to clear layui table

Add the item to be deleted to the array.

How to clear layui table

To determine whether it is selected, send an ajax request with the parameter id.

How to clear layui table

The above is the detailed content of How to clear layui table. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!