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.
我有两个表,一个包含发票项目的发票表和一个包含发票总额的表。
我希望两个表保持在一起,当它们不适合一个页面时,第一个表应该拆分,但第一个表的最后一行应该保留在第二个表旁边。
两个表都有不同的列数和不同的样式。
那可能吗?
拆分第一个表并将其与下一个合并,你可以试试这个
var firstTable=$("#firstTable"); var secondTable=$("#secondTable"); var lastRowFirstTable=firstTable.find("tbody tr:last-child").html(); secondTable.find("tbody").prepend(lastRowFirstTable);