Skip to content

Commit

Permalink
update the courses professor teach on page
Browse files Browse the repository at this point in the history
  • Loading branch information
RonglinC committed Oct 27, 2023
1 parent 97a1943 commit ab350ed
Showing 1 changed file with 15 additions and 8 deletions.
23 changes: 15 additions & 8 deletions src/web/src/pages/ProfPage.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<template>
<b-container fluid>
<b-breadcrumb :items="breadcrumbNav"></b-breadcrumb>
<div v-if="prof" class="w-90 ml-4 mb-4">
<div v-if="prof" class="w-100">

<b-row>
<b-col>
Expand All @@ -21,8 +21,9 @@
</b-col>
</b-row>
<b-row>
<b-col>
<h6 class="mb-1 d-inline">Teaching: {{ prof.Teaching }}</h6>
<b-col class="mb-4">
<h6 class="mb-1 d-inline">Teaching: </h6>
<li v-for="course in teachingCourses" :key="course">{{course.trim()}}</li>
</b-col>
</b-row>
<b-row>
Expand Down Expand Up @@ -81,11 +82,17 @@ export default {
};
},
computed: {
prof() {
return this.professors.find(
(p) => p.Email.replace("@rpi.edu", "") === this.rcs
);
},
prof() {
return this.professors.find(
(p) => p.Email.replace("@rpi.edu", "") === this.rcs
);
},
teachingCourses() {
if (this.prof && this.prof.Teaching) {
return this.prof.Teaching.split(',');
}
return [];
}
}
};
</script>

0 comments on commit ab350ed

Please sign in to comment.