summaryrefslogtreecommitdiff
path: root/contents/ui/main.qml
diff options
context:
space:
mode:
authorFrederick Yin <fkfd@fkfd.me>2022-04-07 18:27:19 +0800
committerFrederick Yin <fkfd@fkfd.me>2022-04-07 18:27:19 +0800
commit1c67f456bc1117c68fc7a76fc7bedde78a8f530c (patch)
treef5675f22e173daed273d5fe8107973eb36317a33 /contents/ui/main.qml
parentfb5547888f3357df1f8ec1be330c87f8306e9086 (diff)
Remove delete button
Diffstat (limited to 'contents/ui/main.qml')
-rw-r--r--contents/ui/main.qml8
1 files changed, 0 insertions, 8 deletions
diff --git a/contents/ui/main.qml b/contents/ui/main.qml
index 1c7d25f..f4eed97 100644
--- a/contents/ui/main.qml
+++ b/contents/ui/main.qml
@@ -52,8 +52,6 @@ Item {
for (let course of courses) {
callApi(`/courses/${course[0]}/activity_stream`, 10, activityStream => {
// Get activity stream for each course
- let announcementCount = 0
- let assignmentCount = 0
activityStream.forEach(activity => {
let important = plasmoid.configuration.importantActivities.includes(
activity.id.toString()
@@ -63,25 +61,21 @@ Item {
announcementsModel.append({
type: "announcement",
activityId: activity.id,
- index: announcementCount,
course: course[1],
title: activity.title,
url: activity.html_url,
important,
})
- announcementCount++
} else if (activity.type == "Submission") {
assignmentsModel.append({
type: "assignment",
activityId: activity.id,
- index: assignmentCount,
course: course[1],
title: activity.title,
due: activity.assignment.due_at,
url: activity.html_url,
important,
})
- assignmentCount++
}
})
})
@@ -113,7 +107,6 @@ Item {
id: announcementsModel
ListElement {
type: "announcement"
- index: 0
course: "CS101"
title: "Title"
url: "https://xkcd.com"
@@ -145,7 +138,6 @@ Item {
id: assignmentsModel
ListElement {
type: "assignment"
- index: 0
course: "EE210"
title: "Title"
due: "2022-12-31T23:59:59Z"