Fixes for the reports. General clean up all around. Better usage of log_lvl.

This commit is contained in:
Scott Idem
2024-08-16 13:14:18 -04:00
parent ca563fdf1f
commit 37801ca769
15 changed files with 161 additions and 58 deletions

View File

@@ -260,17 +260,23 @@ export async function handle_search__event_badge(
export function handle_db_save_ae_obj_li__badge(
{
obj_type,
obj_li
obj_li,
log_lvl = 0
}: {
obj_type: string,
obj_li: any
obj_li: any,
log_lvl?: number
}
) {
console.log(`*** handle_db_save_ae_obj_li__badge() ***`);
if (log_lvl) {
console.log(`*** handle_db_save_ae_obj_li__badge() ***`);
}
if (obj_li && obj_li.length) {
obj_li.forEach(async function (obj: any) {
// console.log(`ae_obj ${obj_type}:`, obj);
if (log_lvl) {
console.log(`ae_obj ${obj_type}:`, obj);
}
try {
const id_random = await db_events.badges.put({