mirror of
https://github.com/vrana/adminer.git
synced 2025-08-13 18:14:07 +02:00
Allow loading more data with inline edit (bug #3605531)
This commit is contained in:
@@ -502,12 +502,10 @@ function selectLoadMore(a, limit, loading) {
|
||||
if (href) {
|
||||
a.removeAttribute('href');
|
||||
return ajax(href, function (request) {
|
||||
document.getElementById('table').innerHTML += request.responseText;
|
||||
var rows = 0;
|
||||
request.responseText.replace(/(^|\n)<tr/g, function () {
|
||||
rows++;
|
||||
});
|
||||
if (rows < limit) {
|
||||
var tbody = document.createElement('tbody');
|
||||
tbody.innerHTML = request.responseText;
|
||||
document.getElementById('table').appendChild(tbody);
|
||||
if (tbody.children.length < limit) {
|
||||
a.parentNode.removeChild(a);
|
||||
} else {
|
||||
a.href = href.replace(/\d+$/, function (page) {
|
||||
|
Reference in New Issue
Block a user