Skip to content

Commit

Permalink
Prereqs are now displayed in the course detail view
Browse files Browse the repository at this point in the history
  • Loading branch information
LarveyOfficial committed Oct 22, 2024
1 parent 3ffe71f commit 4dfc91f
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ package com.mtucoursesmobile.michigantechcourses.classes
data class MTUCourses(
val id: String, val year: Int, val semester: String, val subject: String, val crse: String,
val title: String, val description: String?, val updatedAt: String, val deletedAt: String?,
val prereqs: String, val offered: List<String>?, val minCredits: Double, val maxCredits: Double
val prereqs: String?, val offered: List<String>?, val minCredits: Double, val maxCredits: Double
)

Original file line number Diff line number Diff line change
Expand Up @@ -295,11 +295,21 @@ fun CourseDetailView(
description = description
)

foundCourse.prereqs?.let {
Text(
"Prerequisites: $it",
modifier = Modifier.padding(
top = 4.dp,
start = 4.dp
),
style = MaterialTheme.typography.labelMedium
)
}

HorizontalDivider(
Modifier
.padding(vertical = 8.dp)
.padding(top = 4.dp)
.padding(top = 2.dp)
)
Text(
text = "Course Sections:",
Expand Down

0 comments on commit 4dfc91f

Please sign in to comment.