mirror of
https://github.com/cwinfo/powerdns-admin.git
synced 2024-11-08 14:40:27 +00:00
Add 'getDataTable' function from old template.
This commit is contained in:
parent
e7bc0a1d6e
commit
4164f34fa4
@ -24,4 +24,22 @@ function applyChanges(data, url, showResult) {
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
function getTableData(table) {
|
||||
var rData = []
|
||||
|
||||
// reformat - pretty format
|
||||
var records = []
|
||||
table.rows().every(function() {
|
||||
var r = this.data();
|
||||
var record = {}
|
||||
record["record_name"] = r[0].trim();
|
||||
record["record_type"] = r[1].trim();
|
||||
record["record_status"] = r[2].trim();
|
||||
record["record_ttl"] = r[3].trim();
|
||||
record["record_data"] = r[4].trim();
|
||||
records.push(record);
|
||||
});
|
||||
return records
|
||||
}
|
Loading…
Reference in New Issue
Block a user