Add name column to account management interface

main
sudoer777 2021-12-02 13:26:29 -07:00
parent e9e085e804
commit d72e20b067
1 changed files with 9 additions and 1 deletions

View File

@ -302,6 +302,10 @@ CATEGORIES.push(new Category(
async function listAccountHeaders() { async function listAccountHeaders() {
const headerRow = document.createElement('tr'); const headerRow = document.createElement('tr');
const nameHeader = document.createElement('th');
nameHeader.textContent = "Name";
headerRow.appendChild(nameHeader);
const emailHeader = document.createElement('th'); const emailHeader = document.createElement('th');
emailHeader.textContent = "Email"; emailHeader.textContent = "Email";
headerRow.appendChild(emailHeader); headerRow.appendChild(emailHeader);
@ -317,6 +321,10 @@ CATEGORIES.push(new Category(
itemsListTable.appendChild(headerRow); itemsListTable.appendChild(headerRow);
}, },
function listAccount(account, row) { function listAccount(account, row) {
const nameCell = document.createElement('td');
nameCell.textContent = account.name;
row.appendChild(nameCell);
const emailCell = document.createElement('td'); const emailCell = document.createElement('td');
emailCell.textContent = account.email; emailCell.textContent = account.email;
row.appendChild(emailCell); row.appendChild(emailCell);