Emmanuel Frimpong Asante
commited on
Commit
·
bd571a4
1
Parent(s):
e03a8bb
update space
Browse files
backend/app/static/js/dashboard.js
CHANGED
@@ -27,12 +27,13 @@ async function loadDashboardData() {
|
|
27 |
recentTasksContainer.innerHTML = recentTasks.length
|
28 |
? recentTasks.map(task => `
|
29 |
<li class="list-group-item">
|
30 |
-
${task.task_description}
|
31 |
-
(Due: ${new Date(task.due_date).toLocaleDateString()})
|
32 |
</li>
|
33 |
`).join('')
|
34 |
: '<li class="list-group-item">No recent tasks available.</li>';
|
35 |
|
|
|
36 |
// Update Recent Health Records Section
|
37 |
const recentHealthRecords = data.recentHealthRecords || [];
|
38 |
const recentHealthRecordsContainer = document.getElementById('recentHealthRecords');
|
|
|
27 |
recentTasksContainer.innerHTML = recentTasks.length
|
28 |
? recentTasks.map(task => `
|
29 |
<li class="list-group-item">
|
30 |
+
${task.task_description ? task.task_description : 'No description available'}
|
31 |
+
(Due: ${task.due_date ? new Date(task.due_date).toLocaleDateString() : 'No due date'})
|
32 |
</li>
|
33 |
`).join('')
|
34 |
: '<li class="list-group-item">No recent tasks available.</li>';
|
35 |
|
36 |
+
|
37 |
// Update Recent Health Records Section
|
38 |
const recentHealthRecords = data.recentHealthRecords || [];
|
39 |
const recentHealthRecordsContainer = document.getElementById('recentHealthRecords');
|