Skip to content

Commit

Permalink
user table - sizing update
Browse files Browse the repository at this point in the history
  • Loading branch information
camillereaves authored Nov 28, 2023
1 parent d121869 commit c3c4c05
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion public/js/dashboard_secondary.js
Original file line number Diff line number Diff line change
Expand Up @@ -136,9 +136,13 @@ function loadDataTables() {
async function initializeTable(entries, tableId, scope) {
const tableBody = document.querySelector(`#${tableId} tbody`);
let tableSizing = 5;
if (entries.size < 5) {
if (scope != "account_approvals" && entries.size < 5) {
tableSizing = entries.size;
}
if(scope == "account_approvals" && entries.length < 5){
tableSizing = entries.length;

}
for (let i = 0; i < tableSizing; i++) {
if (scope == "all_users_pending") {
const entry = entries.docs[i];
Expand Down

0 comments on commit c3c4c05

Please sign in to comment.