Skip to content

Commit 86cfad3

Browse files
authored
Merge pull request #2869 from uw-it-aca/qa
Qa
2 parents 496e860 + 5bbf123 commit 86cfad3

File tree

10 files changed

+127
-68
lines changed

10 files changed

+127
-68
lines changed

docker/prod-values.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
autoscaling:
22
enabled: true
3-
minReplicas: 8
3+
minReplicas: 3
44
maxReplicas: 80
55
targetAverageUtilization: 100
66
resources:

myuw_vue/components/_common/course/course-mode/modality.vue

+14-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
<template>
2-
<uw-card-property title="Course Mode" :sr-only-title="!showRowHeading">
2+
<uw-card-property
3+
v-if="notInPerson"
4+
title="Course Mode"
5+
:sr-only-title="!showRowHeading"
6+
>
37
<uw-course-mode
48
:section="section"
59
:include-t-s-c="showRowHeading"
@@ -29,5 +33,14 @@ export default {
2933
default: false,
3034
},
3135
},
36+
computed: {
37+
notInPerson() {
38+
// MUWM-5210
39+
return (
40+
this.section.is_asynchronous ||
41+
this.section.is_synchronous ||
42+
this.section.is_hybrid);
43+
}
44+
},
3245
};
3346
</script>

myuw_vue/components/_common/course/meeting/schedule.vue

+11-3
Original file line numberDiff line numberDiff line change
@@ -36,22 +36,30 @@
3636
:headers="`days-${meeting.id}`"
3737
colspan="3" class="p-0"
3838
>
39-
<span class="text-muted">Class does not meet</span>
39+
<span v-if="isAsyHyb(meeting)" class="text-muted">
40+
No meeting time (coursework online)
41+
</span>
42+
<span v-else class="text-muted">Class does not meet</span>
4043
</td>
4144

4245
<td v-else-if="meeting.days_tbd"
4346
:headers="`days-${meeting.id}`"
4447
colspan="3" class="p-0"
4548
>
46-
<span v-if="isAsyHyb(meeting)" class="text-muted">No meeting time</span>
49+
<span v-if="isAsyHyb(meeting)" class="text-muted">
50+
No meeting time (coursework online)
51+
</span>
4752
<span v-else class="text-muted">Days and times to be arranged</span>
4853
</td>
4954

5055
<td v-else-if="meeting.no_meeting"
5156
:headers="`days-${meeting.id}`"
5257
colspan="3" class="p-0"
5358
>
54-
<span class="text-muted">No classroom meeting: online learning</span>
59+
<span v-if="isAsyHyb(meeting)" class="text-muted">
60+
No meeting time (coursework online)
61+
</span>
62+
<span v-else class="text-muted">No classroom meeting: Online learning</span>
5563
</td>
5664

5765
<template v-else-if="meeting.start_time && meeting.end_time">

myuw_vue/components/_common/visual_schedule/course-section.vue

+62-45
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,9 @@ export default {
5050
type: Object,
5151
required: true,
5252
},
53-
isFinalsCard: {
53+
isFinalsTab: {
5454
type: Boolean,
55-
default: false,
55+
required: true,
5656
},
5757
day: {
5858
type: String,
@@ -62,6 +62,10 @@ export default {
6262
type: Object,
6363
required: true,
6464
},
65+
meetingsWithoutTime: {
66+
type: Boolean,
67+
required: false,
68+
},
6569
},
6670
computed: {
6771
quarter() {
@@ -112,51 +116,77 @@ export default {
112116
this.meetingData.section.course_number
113117
}-${this.meetingData.section.section_id}`;
114118
},
115-
isOnline () {
116-
return (this.meetingData && this.meetingData.meeting &&
117-
this.meetingData.meeting.building_tbd &&
118-
(this.meetingData.section.is_asynchronous ||
119-
this.meetingData.section.is_synchronous ||
120-
this.meetingData.section.is_hybrid) &&
121-
!(this.meetingData.meeting.wont_meet ||
122-
this.meetingData.meeting.no_meeting ||
123-
this.meetingData.meeting.days_tbd)
119+
isInPerson() { // MUWM-5099
120+
return (
121+
this.meetingData.section &&
122+
!(this.meetingData.section.is_asynchronous ||
123+
this.meetingData.section.is_synchronous ||
124+
this.meetingData.section.is_hybrid));
125+
},
126+
wontMeet() {
127+
return (
128+
!this.meetingData.meeting ||
129+
this.meetingData.meeting.wont_meet
130+
);
131+
},
132+
hasBuildingRoom() {
133+
return (
134+
this.meetingData.meeting &&
135+
'building' in this.meetingData.meeting && this.meetingData.meeting.building != '*' &&
136+
'room' in this.meetingData.meeting && this.meetingData.meeting.room != '*'
124137
);
125138
},
126139
meetingLocation() {
127-
if (this.isOnline) { // MUWM-5099
128-
return 'Online';
129-
}
130-
if (this.meetingData.meeting && this.meetingData.meeting.no_meeting) {
131-
return 'No meeting';
140+
if (this.meetingsWithoutTime || this.wontMeet) {
141+
// MUWM-5208
142+
if (this.isFinalsTab) {
143+
return '';
144+
}
145+
if (!this.isInPerson) {
146+
return 'Online';
147+
}
148+
return '';
132149
}
133-
if (!this.isRoomTBD()) {
150+
if (this.hasBuildingRoom) {
134151
return `${
135152
this.meetingData.meeting.building
136153
} ${this.meetingData.meeting.room}`;
137154
}
155+
if (!this.isInPerson) {
156+
// MUWM-5208
157+
if (!this.isFinalsTab) {
158+
return 'Online';
159+
}
160+
return 'TBD';
161+
}
138162
return 'Room TBD';
139163
},
140164
ariaMeetingLocation() {
141-
if (this.isOnline) { // MUWM-5099
142-
return 'Online';
143-
}
144-
if (this.meetingData.meeting && this.meetingData.meeting.no_meeting) {
165+
if (this.meetingsWithoutTime || this.wontMeet) {
166+
// MUWM-5208
167+
if (this.isFinalsTab) {
168+
return 'Location: None';
169+
}
170+
if (!this.isInPerson) {
171+
return 'Location: Online';
172+
}
145173
return 'Location: None';
146174
}
147-
if (!this.isRoomTBD()) {
148-
return `Building: ${
175+
if (this.hasBuildingRoom) {
176+
return `${
149177
this.meetingData.meeting.building
150-
} Room: ${this.meetingData.meeting.room}`;
178+
} ${this.meetingData.meeting.room}`;
179+
}
180+
if (!this.isInPerson && !this.isFinalsTab) {
181+
// MUWM-5208
182+
return 'Location: Online';
151183
}
152-
return 'Location: Room TBD';
184+
return 'Location: TBD';
153185
},
154186
meetingLocationUrl() {
155-
if (
156-
!this.meetingData.section.is_remote &&
157-
!this.isRoomTBD() &&
158-
'latitude' in this.meetingData.meeting &&
159-
'longitude' in this.meetingData.meeting
187+
if (this.hasBuildingRoom &&
188+
'latitude' in this.meetingData.meeting &&
189+
'longitude' in this.meetingData.meeting
160190
) {
161191
return `http://maps.google.com/maps?q=${
162192
this.meetingData.meeting.latitude
@@ -169,8 +199,9 @@ export default {
169199
showConfirmLink() {
170200
return (
171201
this.meetingData.section.is_teaching &&
172-
this.isFinalsCard &&
202+
this.isFinalsTab &&
173203
this.meetingData.section.is_primary_section &&
204+
this.meetingData.section.final_exam &&
174205
!this.meetingData.section.final_exam.no_exam_or_nontraditional &&
175206
!this.meetingData.section.final_exam.is_confirmed
176207
);
@@ -220,20 +251,6 @@ export default {
220251
getMFM(t) {
221252
return (t.hour() * 60) + t.minute();
222253
},
223-
isRoomTBD() {
224-
return (
225-
this.meetingData.meeting == null ||
226-
(
227-
this.meetingData.meeting.room_tbd ||
228-
!(
229-
'building' in this.meetingData.meeting &&
230-
this.meetingData.meeting.building != '*' &&
231-
'room' in this.meetingData.meeting &&
232-
this.meetingData.meeting.room != '*'
233-
)
234-
)
235-
);
236-
},
237254
},
238255
};
239256
</script>

myuw_vue/components/_common/visual_schedule/schedule-tab.vue

+14-10
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@
6565
v-for="(meetingData, j) in
6666
meetingMap[day][formatToUnique(time)]"
6767
:key="j" :meeting-data="meetingData"
68-
:is-finals-card="isFinalsTab" :day="day" :term="term"
68+
:is-finals-tab="isFinalsTab" :day="day" :term="term"
6969
/>
7070
</div>
7171
</div>
@@ -102,7 +102,7 @@
102102
v-for="(meetingData, j) in
103103
meetingMap[mobile['current']][formatToUnique(time)]"
104104
:key="j" :meeting-data="meetingData" :term="term"
105-
:is-finals-card="isFinalsTab" :day="mobile['current']"
105+
:is-finals-tab="isFinalsTab" :day="mobile['current']"
106106
/>
107107
</div>
108108
</div>
@@ -112,13 +112,13 @@
112112

113113
<!-- eos message display -->
114114
<div v-if="period.eosData.length > 0 && !isFinalsTab" class="mb-2">
115-
<p class="text-muted myuw-text-md mb-1">
115+
<p class="myuw-text-md mb-1">
116116
Meeting time notes:
117117
</p>
118118
<uw-course-section
119119
v-for="(eosSection, i) in period.eosData" :key="i"
120120
:meeting-data="{section: eosSection}" :term="term"
121-
:is-finals-card="false" class="d-inline-block w-auto me-2"
121+
:is-finals-tab="false" class="d-inline-block w-auto me-2"
122122
>
123123
<ol class="m-0 px-4 text-start">
124124
<li v-for="(meeting, j) in eosSection.meetings" :key="j">
@@ -144,18 +144,22 @@
144144

145145
<!-- no meeting specified notes -->
146146
<div v-if="meetingsWithoutTime.length > 0">
147-
<p v-if="!isFinalsTab" class="text-muted myuw-text-md mb-1">
147+
<p v-if="!isFinalsTab" class="myuw-text-md mb-1">
148148
No meeting time specified in the selected date range:
149149
</p>
150-
<p v-else class="text-muted myuw-text-md mb-1">
151-
Courses with final exam meeting times to be determined or courses with
152-
no final exam:
150+
<p v-else class="myuw-text-md mb-1">
151+
Courses with final exam meeting times to be determined or courses with no final exam:
153152
</p>
154153
<div v-for="(meeting, i) in meetingsWithoutTime" :key="i"
155154
class="d-inline-block w-auto me-2"
156155
style="min-width:110px;"
157156
>
158-
<uw-course-section :meeting-data="meeting" :term="term" />
157+
<uw-course-section
158+
:meeting-data="meeting"
159+
:term="term"
160+
:is-finals-tab="isFinalsTab"
161+
meetings-without-time
162+
/>
159163
</div>
160164
</div>
161165
</div>
@@ -254,7 +258,7 @@ export default {
254258
},
255259
created() {
256260
// Set if this tab is for finals
257-
this.isFinalsTab = this.period.id == 'finals';
261+
this.isFinalsTab = (this.period.id === 'finals');
258262
if (!(
259263
this.period.earliestMeetingTime &&
260264
this.period.latestMeetingTime

myuw_vue/components/_common/visual_schedule/schedule.vue

+1-1
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
</uw-tabs>
4040

4141
<div v-else>
42-
<p class="text-muted myuw-text-md mb-1">
42+
<p class="myuw-text-md mb-1">
4343
No meeting time specified:
4444
</p>
4545
<div v-for="(meeting, i) in allMeetings" :key="i"

myuw_vue/components/academics/adviser.vue

+1-1
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ export default {
164164
},
165165
showCard() {
166166
return (this.isUndergrad || this.studEmployee && !this.isGrad)
167-
&& !this.isPCE && !this.isApplicant;
167+
&& !this.isPCE;
168168
}
169169
},
170170
created() {

myuw_vue/components/home/inst_course_summary/section.vue

+14-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,11 @@
3232
Course Mode:
3333
</h4>
3434
<span>
35-
<uw-course-mode class="d-inline" :section="section" hide-info-link/>
35+
<uw-course-mode
36+
v-if="notInPerson"
37+
class="d-inline"
38+
:section="section"
39+
hide-info-link/>
3640
</span>
3741
</div>
3842
<div class="d-inline ms-1">
@@ -150,6 +154,15 @@ export default {
150154
faSquareFull,
151155
};
152156
},
157+
computed: {
158+
notInPerson() {
159+
// MUWM-5210
160+
return (
161+
this.section.is_asynchronous ||
162+
this.section.is_synchronous ||
163+
this.section.is_hybrid);
164+
}
165+
},
153166
methods: {
154167
getLinkedSections(pSection) {
155168
return this.$parent.sections.filter(

myuw_vue/tests/inst-summary.test.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ describe('Instructor Teaching Summary', () => {
197197
const wrapper = mount(InstructorCourseSummery, { store, localVue });
198198
await new Promise((r) => setTimeout(r, 30));
199199
const cmodes = wrapper.findAllComponents(UwCourseMode);
200-
expect(cmodes.length).toBe(4);
200+
expect(cmodes.length).toBe(2);
201201
console.log(cmodes[0]);
202202
expect(cmodes.at(0).vm.hideInfoLink).toBe(true);
203203
expect(cmodes.at(0).vm.asyncMsg.length > 0).toBe(true);

myuw_vue/tests/visual-schedule.test.js

+8-4
Original file line numberDiff line numberDiff line change
@@ -170,17 +170,21 @@ describe('Vue SFC Tests', () => {
170170
).toHaveLength(1);
171171
});
172172

173-
it('Check MUWM-5099', async () => {
173+
it('Check MUWM-5099 MUWM-5208', async () => {
174174
store.state.user.affiliations.student = false;
175175
store.state.user.affiliations.instructor = true;
176176
axios.get.mockResolvedValue({ data: mockScheduleBill5099, status: 200 });
177177
const wrapper = mount(VisualSchedule, { store, localVue });
178178

179179
await new Promise(setImmediate);
180180
const sections = wrapper.findAllComponents(CourseSection);
181-
expect(sections.at(0).vm.isOnline).toBe(true);
181+
expect(sections.at(0).vm.isFinalsTab).toBe(false);
182+
expect(sections.at(0).vm.isInPerson).toBe(false);
183+
expect(sections.at(0).vm.hasBuildingRoom).toBe(false);
182184
expect(sections.at(0).vm.meetingLocation).toBe('Online');
183-
expect(sections.at(0).vm.ariaMeetingLocation).toBe('Online');
184-
expect(sections.at(1).vm.isOnline).toBe(false);
185+
expect(sections.at(0).vm.ariaMeetingLocation).toBe('Location: Online');
186+
expect(sections.at(2).vm.isInPerson).toBe(false);
187+
expect(sections.at(2).vm.hasBuildingRoom).toBe(false);
188+
expect(sections.at(2).vm.meetingLocation).toBe('Online');
185189
});
186190
});

0 commit comments

Comments
 (0)