Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一个使用 jQuery UI 可排序的表。第一列包含每行的订单号。对行进行排序时,如何自动对第一列中的数字(按升序)进行排序?这意味着只有第一列中的数字会被排序。
提前致谢!
var position = 1; $('table tbody tr').each(function () { $('td:first', $(this)).text(position); position += 1; });
您可以放置排序完成时发生的此功能(对于可排序 UI,它是“停止”)