<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.expertiza.ncsu.edu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Dmehta4</id>
	<title>Expertiza_Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.expertiza.ncsu.edu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Dmehta4"/>
	<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Special:Contributions/Dmehta4"/>
	<updated>2026-06-14T11:37:22Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.41.0</generator>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=155766</id>
		<title>CSC/ECE 517 Spring 2024 - E2438 Improve assessment360 controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=155766"/>
		<updated>2024-04-22T04:28:14Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Introduction==&lt;br /&gt;
The Ruby on Rails framework serves as the foundation for the open-source project [https://expertiza.ncsu.edu/ Expertiza]. Expertiza offers features that let instructors see a comprehensive, 360-degree overview of the course they teach, including all of the assignments, all of the students enrolled in the course, all of their individual assignment scores, averages, and final scores. The assessment360 controller facilitates this feature.&lt;br /&gt;
&lt;br /&gt;
Here is the class diagram of this controller - &lt;br /&gt;
[[File:Class2.png|700px|center|]]&lt;br /&gt;
&lt;br /&gt;
The following two views are mostly under the control of the assessment360 controller:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1) all_students_all_reviews: This view shows all of the student teammate and meta reviews for every program they worked on that semester. It also offers a summary of these review scores collectively.&lt;br /&gt;
&lt;br /&gt;
2) course_student_grade_summary: This view shows the topic, instructor grade, peer score, and summary of each assignment that students have completed. This also applies to the sum and mean of these scores.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The current implementation of the assessment360_controller.rb suffers from several issues such as repetitive elements, cryptic variable names, inaccurate grade calculations, and lack of flexibility in displaying different types of review scores. The objective of this project is to enhance the user interface and functionality of the assessment360_controller.rb in the application.&lt;br /&gt;
&lt;br /&gt;
Following are the issues to be addressed in this project:&lt;br /&gt;
&lt;br /&gt;
===Issues===&lt;br /&gt;
The main goals of this project are as follows:&lt;br /&gt;
* '''Issue #1:''' Refactor the all_students_all_reviews method to accept parameters specifying the type(s) of review scores to be displayed, and suppress columns for scores not selected.&lt;br /&gt;
* '''Issue #2:''' Rename the @teamed_count variable to a more descriptive name or remove it if not used.&lt;br /&gt;
* '''Issue #3:''' Ensure accuracy in grade calculations by including only the assignments that were attempted by the student in average grade calculation.&lt;br /&gt;
* '''Issue #4:''' Enhance the course_student_grade_summary method to include average peer-review scores and instructor-assigned scores. &lt;br /&gt;
* '''Issue #5:''' Columns for various types of review scores should be displayed based on user selection.&lt;br /&gt;
* '''Issue #6:''' Utilize the Bullet gem to minimize database accesses and optimize performance.&lt;br /&gt;
* '''Issue #7:''' Identify and address edge cases from the UI perspective to ensure consistent and clean behavior across different scenarios.&lt;br /&gt;
* '''Issue #8:''' Implement separate columns for student name and student ID to improve readability in the UI.&lt;br /&gt;
* '''Issue #9:''' Replace hyphen '-' with an en-dash '–'.&lt;br /&gt;
&lt;br /&gt;
==Implementation==&lt;br /&gt;
The changes made to the assessment360_controller.rb and related files were necessary to improve the code's readability, maintainability, and adherence to best practices. Let's discuss each change and its significance:&lt;br /&gt;
&lt;br /&gt;
===Files modified===&lt;br /&gt;
&lt;br /&gt;
==== 1. Changes to &amp;lt;code&amp;gt;app/views/assessment360/all_student_all_reviews.html.erb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|Checked and renamed&amp;lt;code&amp;gt;@teamed_count&amp;lt;/code&amp;gt; variable&lt;br /&gt;
|Checked the usage of variable through IDE whether the variable is used. The variable was used to display the total number of teams each student has collaborated with. Thus, it was renamed from &amp;lt;code&amp;gt;@teamed_count&amp;lt;/code&amp;gt; to &amp;lt;code&amp;gt;@student_team_counts&amp;lt;/code&amp;gt; in both &amp;lt;code&amp;gt;app/controller/assessment360_controller.rb&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;app/views/assessment360/all_student_all_reviews.html.erb&amp;lt;/code&amp;gt; files for better readability and understandability of the code.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|-&lt;br /&gt;
|2&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;| Added check boxes to select columns to display &lt;br /&gt;
|Added 2 check boxes (meta reviews and teammate reviews) to select/deselect columns to be displayed. &lt;br /&gt;
|[https://github.com/expertiza/expertiza/pull/2792/commits/9190886b4e4825bdf426500de37e08614c48e19a Commit]&lt;br /&gt;
|-&lt;br /&gt;
|3&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;| Hide empty columns &lt;br /&gt;
|Added checks to ensure column is displayed only when at least one of the rows has a corresponding value to that column in the database. &lt;br /&gt;
|[https://github.com/expertiza/expertiza/pull/2792/commits/8dc145ab7541f590ce811c66ce44455ad635769c Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== 2. Changes to &amp;lt;code&amp;gt;Gemfile&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;config/environments/development.rb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;|Added and initialized the bullet gem&lt;br /&gt;
|To identify and reduce unnecessary database queries, the bullet gem was added and activated to increase the performance of the application.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== 3. Changes to &amp;lt;code&amp;gt;app/views/assessment360/course_student_grade_summary.html.erb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;|Separated student name and student ID into different columns&lt;br /&gt;
|In order to achieve better understanding of the data being displayed, student name and student ID were separated into different columns.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== 4. Changes to &amp;lt;code&amp;gt;app/controllers/assessment360_controller.rb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;|Replaced hyphen '-' with an en-dash '–'&lt;br /&gt;
|Since hyphen was used to represent empty values, it was replaced with an en-dash for enhancing the UI.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|-&lt;br /&gt;
|2&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;| Refactored &amp;lt;code&amp;gt;calc_overall_review_info()&amp;lt;/code&amp;gt;&lt;br /&gt;
|Ensured that if a student has not received a grade for an assignment that row is not considered for calculating the average.&lt;br /&gt;
|[https://github.com/expertiza/expertiza/pull/2792/commits/0846538180ac5139301aba824ab847b2ba9ba58a Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== UI Changes made ==&lt;br /&gt;
&lt;br /&gt;
The assessment360 controller is responsible for the following two views - &lt;br /&gt;
&lt;br /&gt;
'''1) all_students_all_reviews.html.erb''' - This view displays a table of students, their teammate count, and their performance on various assignments. For each assignment, it shows the metareview and teammate review scores. At the end of each row, it displays the aggregate score for metareviews and teammate reviews for each student. The last row of the table provides the class average for each assignment and the overall class average for metareviews and teammate reviews.&lt;br /&gt;
[[File:Review dm.png|1000px|center|]]&lt;br /&gt;
'''Problems''' - &amp;lt;br&amp;gt;&lt;br /&gt;
1) The column is displayed even though all the rows are blank. &amp;lt;br&amp;gt;&lt;br /&gt;
2) The empty blanks can also lead to confusion and thus must be replaced. &amp;lt;br&amp;gt;&lt;br /&gt;
3) Allow user to choose the columns they wish to be displayed. &amp;lt;br&amp;gt;&lt;br /&gt;
4) Separate columns for student name and student ID &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
'''2) course_student_grade_summary.html.erb''' - This view displays a sortable table of students, their assignments, and their grades. For each assignment, it shows the topic, the peer review score, and the instructor's grade. At the end of each row, it displays the total instructor grade for each student. The table can be sorted by student name or total instructor grade.&lt;br /&gt;
[[File:Grade summary.png|1000px|center|]]&lt;br /&gt;
'''Problems''' - &amp;lt;br&amp;gt;&lt;br /&gt;
1) A new column for average peer review score needs to be added. &amp;lt;br&amp;gt;&lt;br /&gt;
2) Allow user to choose the columns they wish to be displayed. &amp;lt;br&amp;gt;&lt;br /&gt;
2) Separate columns for student name and student ID &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Code Snippets ==&lt;br /&gt;
&lt;br /&gt;
[[File:Hashes.png|600px]] &amp;lt;br&amp;gt;&lt;br /&gt;
We created 2 hashes &amp;lt;code&amp;gt;meta_review_exists&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;teammate_review_exists&amp;lt;/code&amp;gt; which track if the respective values exist for each assignment. We use these hashes in our view to decide whether to display columns or not. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Boolean.png|600px]]&amp;lt;br&amp;gt;&lt;br /&gt;
Here we are assigning values to those hashes based on whether the review exists or not for that particular assignment. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Logic.png|600px]]&amp;lt;br&amp;gt;&lt;br /&gt;
This is the new logic for calculating grade averages ensuring that only those grades are considered which have been reviewed for the average calculation so that the calculation is accurate. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Script.png|600px]]&amp;lt;br&amp;gt;&lt;br /&gt;
This is the JavaScript code we wrote to ensure that our view changes dynamically based on selection/deselection of the checkboxes. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Design Principles and Patterns ==&lt;br /&gt;
We have tried to apply the techniques we have learned in the class wherever it was possible. This included DRYing out the code and adding proper comments enhancing its readability and maintainability. &lt;br /&gt;
* We created a method called &amp;lt;code&amp;gt;handleCheckboxChange&amp;lt;/code&amp;gt; which was responsible for listening to various checkbox events, thus helping us to DRY out our code since we did not have to write the same code again for another checkbox. &amp;lt;br&amp;gt;&lt;br /&gt;
== Test Plan==&lt;br /&gt;
&lt;br /&gt;
The following test plan has been identified to ensure that the our changes don't break the existing system and the new code being introduced is thoroughly tested.&lt;br /&gt;
&lt;br /&gt;
=== Manual Testing ===&lt;br /&gt;
The following tests have been identified to ensure that the changes made work as anticipated:&lt;br /&gt;
&lt;br /&gt;
1. Select any course&lt;br /&gt;
[[File:Expertiza-3.png|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
2. Go to the all_students_all_reviews page by clicking on the icon next to the globe icon. &lt;br /&gt;
[[File:Expertiza-2.PNG|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
3. Verify that only those columns are visible with at least one data point. &lt;br /&gt;
&lt;br /&gt;
4. Add checkboxes at the top of the screen and ensure columns are hidden or visible based on the selected checkboxes&lt;br /&gt;
&lt;br /&gt;
5. Go to course_student_grade_summary by clicking on the the globe icon.&lt;br /&gt;
[[File:Expertiza-1.PNG|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
6. Verify that empty data that is shown as '-' (a hyphen) is replaced by an '–' (en-dash).&lt;br /&gt;
&lt;br /&gt;
7. Verify that average peer score column is visible and has correct values.&lt;br /&gt;
&lt;br /&gt;
8. Verify that unattempted assignments or assignments that are not graded are assigned '0' value instead of leaving it blank.&lt;br /&gt;
&lt;br /&gt;
9. Verify that unattempted assignments or assignments that are not graded aren't counted towards the average score. &lt;br /&gt;
&lt;br /&gt;
10. Verify that student name and student ID are in different columns&lt;br /&gt;
&lt;br /&gt;
11. Add checkboxes at the top of the screen and ensure columns are hidden or visible based on the selected checkboxes&lt;br /&gt;
&lt;br /&gt;
==Team==&lt;br /&gt;
===Mentor===&lt;br /&gt;
Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
&lt;br /&gt;
===Team Members===&lt;br /&gt;
1) Daksh Mehta (unityID: dmehta4, GitHub: [https://github.com/ dakshmehta23])&amp;lt;br&amp;gt;&lt;br /&gt;
2) Soham Patil (unityID: sspatil6, GitHub: [https://github.com/ ThErOCk07])&amp;lt;br&amp;gt;&lt;br /&gt;
3) Unnati Bukhariya (unityID: ubukhar2, GitHub: [https://github.com/ unnzzz])&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Relevant Links==&lt;br /&gt;
&lt;br /&gt;
'''1. Youtube Video:''' &lt;br /&gt;
&lt;br /&gt;
'''2. Github forked repository:''' https://github.com/ThErOCk07/expertiza&lt;br /&gt;
&lt;br /&gt;
'''3. Github Pull request:''' https://github.com/expertiza/expertiza/pull/2792&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Class2.png&amp;diff=155765</id>
		<title>File:Class2.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Class2.png&amp;diff=155765"/>
		<updated>2024-04-22T04:26:49Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=155764</id>
		<title>CSC/ECE 517 Spring 2024 - E2438 Improve assessment360 controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=155764"/>
		<updated>2024-04-22T04:07:28Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: /* Relevant Links */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Introduction==&lt;br /&gt;
The Ruby on Rails framework serves as the foundation for the open-source project [https://expertiza.ncsu.edu/ Expertiza]. Expertiza offers features that let instructors see a comprehensive, 360-degree overview of the course they teach, including all of the assignments, all of the students enrolled in the course, all of their individual assignment scores, averages, and final scores. The assessment360 controller facilitates this feature.&lt;br /&gt;
&lt;br /&gt;
The following two views are mostly under the control of the assessment360 controller:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1) all_students_all_reviews: This view shows all of the student teammate and meta reviews for every program they worked on that semester. It also offers a summary of these review scores collectively.&lt;br /&gt;
&lt;br /&gt;
2) course_student_grade_summary: This view shows the topic, instructor grade, peer score, and summary of each assignment that students have completed. This also applies to the sum and mean of these scores.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The current implementation of the assessment360_controller.rb suffers from several issues such as repetitive elements, cryptic variable names, inaccurate grade calculations, and lack of flexibility in displaying different types of review scores. The objective of this project is to enhance the user interface and functionality of the assessment360_controller.rb in the application.&lt;br /&gt;
&lt;br /&gt;
Following are the issues to be addressed in this project:&lt;br /&gt;
&lt;br /&gt;
===Issues===&lt;br /&gt;
The main goals of this project are as follows:&lt;br /&gt;
* '''Issue #1:''' Refactor the all_students_all_reviews method to accept parameters specifying the type(s) of review scores to be displayed, and suppress columns for scores not selected.&lt;br /&gt;
* '''Issue #2:''' Rename the @teamed_count variable to a more descriptive name or remove it if not used.&lt;br /&gt;
* '''Issue #3:''' Ensure accuracy in grade calculations by including only the assignments that were attempted by the student in average grade calculation.&lt;br /&gt;
* '''Issue #4:''' Enhance the course_student_grade_summary method to include average peer-review scores and instructor-assigned scores. &lt;br /&gt;
* '''Issue #5:''' Columns for various types of review scores should be displayed based on user selection.&lt;br /&gt;
* '''Issue #6:''' Utilize the Bullet gem to minimize database accesses and optimize performance.&lt;br /&gt;
* '''Issue #7:''' Identify and address edge cases from the UI perspective to ensure consistent and clean behavior across different scenarios.&lt;br /&gt;
* '''Issue #8:''' Implement separate columns for student name and student ID to improve readability in the UI.&lt;br /&gt;
* '''Issue #9:''' Replace hyphen '-' with an en-dash '–'.&lt;br /&gt;
&lt;br /&gt;
==Implementation==&lt;br /&gt;
The changes made to the assessment360_controller.rb and related files were necessary to improve the code's readability, maintainability, and adherence to best practices. Let's discuss each change and its significance:&lt;br /&gt;
&lt;br /&gt;
===Files modified===&lt;br /&gt;
&lt;br /&gt;
==== 1. Changes to &amp;lt;code&amp;gt;app/views/assessment360/all_student_all_reviews.html.erb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|Checked and renamed&amp;lt;code&amp;gt;@teamed_count&amp;lt;/code&amp;gt; variable&lt;br /&gt;
|Checked the usage of variable through IDE whether the variable is used. The variable was used to display the total number of teams each student has collaborated with. Thus, it was renamed from &amp;lt;code&amp;gt;@teamed_count&amp;lt;/code&amp;gt; to &amp;lt;code&amp;gt;@student_team_counts&amp;lt;/code&amp;gt; in both &amp;lt;code&amp;gt;app/controller/assessment360_controller.rb&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;app/views/assessment360/all_student_all_reviews.html.erb&amp;lt;/code&amp;gt; files for better readability and understandability of the code.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|-&lt;br /&gt;
|2&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;| Added check boxes to select columns to display &lt;br /&gt;
|Added 2 check boxes (meta reviews and teammate reviews) to select/deselect columns to be displayed. &lt;br /&gt;
|[https://github.com/expertiza/expertiza/pull/2792/commits/9190886b4e4825bdf426500de37e08614c48e19a Commit]&lt;br /&gt;
|-&lt;br /&gt;
|3&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;| Hide empty columns &lt;br /&gt;
|Added checks to ensure column is displayed only when at least one of the rows has a corresponding value to that column in the database. &lt;br /&gt;
|[https://github.com/expertiza/expertiza/pull/2792/commits/8dc145ab7541f590ce811c66ce44455ad635769c Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== 2. Changes to &amp;lt;code&amp;gt;Gemfile&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;config/environments/development.rb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;|Added and initialized the bullet gem&lt;br /&gt;
|To identify and reduce unnecessary database queries, the bullet gem was added and activated to increase the performance of the application.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== 3. Changes to &amp;lt;code&amp;gt;app/views/assessment360/course_student_grade_summary.html.erb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;|Separated student name and student ID into different columns&lt;br /&gt;
|In order to achieve better understanding of the data being displayed, student name and student ID were separated into different columns.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== 4. Changes to &amp;lt;code&amp;gt;app/controllers/assessment360_controller.rb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;|Replaced hyphen '-' with an en-dash '–'&lt;br /&gt;
|Since hyphen was used to represent empty values, it was replaced with an en-dash for enhancing the UI.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|-&lt;br /&gt;
|2&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;| Refactored &amp;lt;code&amp;gt;calc_overall_review_info()&amp;lt;/code&amp;gt;&lt;br /&gt;
|Ensured that if a student has not received a grade for an assignment that row is not considered for calculating the average.&lt;br /&gt;
|[https://github.com/expertiza/expertiza/pull/2792/commits/0846538180ac5139301aba824ab847b2ba9ba58a Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== UI Changes made ==&lt;br /&gt;
&lt;br /&gt;
The assessment360 controller is responsible for the following two views - &lt;br /&gt;
&lt;br /&gt;
'''1) all_students_all_reviews.html.erb''' - This view displays a table of students, their teammate count, and their performance on various assignments. For each assignment, it shows the metareview and teammate review scores. At the end of each row, it displays the aggregate score for metareviews and teammate reviews for each student. The last row of the table provides the class average for each assignment and the overall class average for metareviews and teammate reviews.&lt;br /&gt;
[[File:Review dm.png|1000px|center|]]&lt;br /&gt;
'''Problems''' - &amp;lt;br&amp;gt;&lt;br /&gt;
1) The column is displayed even though all the rows are blank. &amp;lt;br&amp;gt;&lt;br /&gt;
2) The empty blanks can also lead to confusion and thus must be replaced. &amp;lt;br&amp;gt;&lt;br /&gt;
3) Allow user to choose the columns they wish to be displayed. &amp;lt;br&amp;gt;&lt;br /&gt;
4) Separate columns for student name and student ID &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
'''2) course_student_grade_summary.html.erb''' - This view displays a sortable table of students, their assignments, and their grades. For each assignment, it shows the topic, the peer review score, and the instructor's grade. At the end of each row, it displays the total instructor grade for each student. The table can be sorted by student name or total instructor grade.&lt;br /&gt;
[[File:Grade summary.png|1000px|center|]]&lt;br /&gt;
'''Problems''' - &amp;lt;br&amp;gt;&lt;br /&gt;
1) A new column for average peer review score needs to be added. &amp;lt;br&amp;gt;&lt;br /&gt;
2) Allow user to choose the columns they wish to be displayed. &amp;lt;br&amp;gt;&lt;br /&gt;
2) Separate columns for student name and student ID &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Code Snippets ==&lt;br /&gt;
&lt;br /&gt;
[[File:Hashes.png|600px]] &amp;lt;br&amp;gt;&lt;br /&gt;
We created 2 hashes &amp;lt;code&amp;gt;meta_review_exists&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;teammate_review_exists&amp;lt;/code&amp;gt; which track if the respective values exist for each assignment. We use these hashes in our view to decide whether to display columns or not. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Boolean.png|600px]]&amp;lt;br&amp;gt;&lt;br /&gt;
Here we are assigning values to those hashes based on whether the review exists or not for that particular assignment. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Logic.png|600px]]&amp;lt;br&amp;gt;&lt;br /&gt;
This is the new logic for calculating grade averages ensuring that only those grades are considered which have been reviewed for the average calculation so that the calculation is accurate. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Script.png|600px]]&amp;lt;br&amp;gt;&lt;br /&gt;
This is the JavaScript code we wrote to ensure that our view changes dynamically based on selection/deselection of the checkboxes. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Design Principles and Patterns ==&lt;br /&gt;
We have tried to apply the techniques we have learned in the class wherever it was possible. This included DRYing out the code and adding proper comments enhancing its readability and maintainability. &lt;br /&gt;
* We created a method called &amp;lt;code&amp;gt;handleCheckboxChange&amp;lt;/code&amp;gt; which was responsible for listening to various checkbox events, thus helping us to DRY out our code since we did not have to write the same code again for another checkbox. &amp;lt;br&amp;gt;&lt;br /&gt;
== Test Plan==&lt;br /&gt;
&lt;br /&gt;
The following test plan has been identified to ensure that the our changes don't break the existing system and the new code being introduced is thoroughly tested.&lt;br /&gt;
&lt;br /&gt;
=== Manual Testing ===&lt;br /&gt;
The following tests have been identified to ensure that the changes made work as anticipated:&lt;br /&gt;
&lt;br /&gt;
1. Select any course&lt;br /&gt;
[[File:Expertiza-3.png|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
2. Go to the all_students_all_reviews page by clicking on the icon next to the globe icon. &lt;br /&gt;
[[File:Expertiza-2.PNG|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
3. Verify that only those columns are visible with at least one data point. &lt;br /&gt;
&lt;br /&gt;
4. Add checkboxes at the top of the screen and ensure columns are hidden or visible based on the selected checkboxes&lt;br /&gt;
&lt;br /&gt;
5. Go to course_student_grade_summary by clicking on the the globe icon.&lt;br /&gt;
[[File:Expertiza-1.PNG|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
6. Verify that empty data that is shown as '-' (a hyphen) is replaced by an '–' (en-dash).&lt;br /&gt;
&lt;br /&gt;
7. Verify that average peer score column is visible and has correct values.&lt;br /&gt;
&lt;br /&gt;
8. Verify that unattempted assignments or assignments that are not graded are assigned '0' value instead of leaving it blank.&lt;br /&gt;
&lt;br /&gt;
9. Verify that unattempted assignments or assignments that are not graded aren't counted towards the average score. &lt;br /&gt;
&lt;br /&gt;
10. Verify that student name and student ID are in different columns&lt;br /&gt;
&lt;br /&gt;
11. Add checkboxes at the top of the screen and ensure columns are hidden or visible based on the selected checkboxes&lt;br /&gt;
&lt;br /&gt;
==Team==&lt;br /&gt;
===Mentor===&lt;br /&gt;
Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
&lt;br /&gt;
===Team Members===&lt;br /&gt;
1) Daksh Mehta (unityID: dmehta4, GitHub: [https://github.com/ dakshmehta23])&amp;lt;br&amp;gt;&lt;br /&gt;
2) Soham Patil (unityID: sspatil6, GitHub: [https://github.com/ ThErOCk07])&amp;lt;br&amp;gt;&lt;br /&gt;
3) Unnati Bukhariya (unityID: ubukhar2, GitHub: [https://github.com/ unnzzz])&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Relevant Links==&lt;br /&gt;
&lt;br /&gt;
'''1. Youtube Video:''' &lt;br /&gt;
&lt;br /&gt;
'''2. Github forked repository:''' https://github.com/ThErOCk07/expertiza&lt;br /&gt;
&lt;br /&gt;
'''3. Github Pull request:''' https://github.com/expertiza/expertiza/pull/2792&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=155763</id>
		<title>CSC/ECE 517 Spring 2024 - E2438 Improve assessment360 controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=155763"/>
		<updated>2024-04-22T04:05:28Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Introduction==&lt;br /&gt;
The Ruby on Rails framework serves as the foundation for the open-source project [https://expertiza.ncsu.edu/ Expertiza]. Expertiza offers features that let instructors see a comprehensive, 360-degree overview of the course they teach, including all of the assignments, all of the students enrolled in the course, all of their individual assignment scores, averages, and final scores. The assessment360 controller facilitates this feature.&lt;br /&gt;
&lt;br /&gt;
The following two views are mostly under the control of the assessment360 controller:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1) all_students_all_reviews: This view shows all of the student teammate and meta reviews for every program they worked on that semester. It also offers a summary of these review scores collectively.&lt;br /&gt;
&lt;br /&gt;
2) course_student_grade_summary: This view shows the topic, instructor grade, peer score, and summary of each assignment that students have completed. This also applies to the sum and mean of these scores.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The current implementation of the assessment360_controller.rb suffers from several issues such as repetitive elements, cryptic variable names, inaccurate grade calculations, and lack of flexibility in displaying different types of review scores. The objective of this project is to enhance the user interface and functionality of the assessment360_controller.rb in the application.&lt;br /&gt;
&lt;br /&gt;
Following are the issues to be addressed in this project:&lt;br /&gt;
&lt;br /&gt;
===Issues===&lt;br /&gt;
The main goals of this project are as follows:&lt;br /&gt;
* '''Issue #1:''' Refactor the all_students_all_reviews method to accept parameters specifying the type(s) of review scores to be displayed, and suppress columns for scores not selected.&lt;br /&gt;
* '''Issue #2:''' Rename the @teamed_count variable to a more descriptive name or remove it if not used.&lt;br /&gt;
* '''Issue #3:''' Ensure accuracy in grade calculations by including only the assignments that were attempted by the student in average grade calculation.&lt;br /&gt;
* '''Issue #4:''' Enhance the course_student_grade_summary method to include average peer-review scores and instructor-assigned scores. &lt;br /&gt;
* '''Issue #5:''' Columns for various types of review scores should be displayed based on user selection.&lt;br /&gt;
* '''Issue #6:''' Utilize the Bullet gem to minimize database accesses and optimize performance.&lt;br /&gt;
* '''Issue #7:''' Identify and address edge cases from the UI perspective to ensure consistent and clean behavior across different scenarios.&lt;br /&gt;
* '''Issue #8:''' Implement separate columns for student name and student ID to improve readability in the UI.&lt;br /&gt;
* '''Issue #9:''' Replace hyphen '-' with an en-dash '–'.&lt;br /&gt;
&lt;br /&gt;
==Implementation==&lt;br /&gt;
The changes made to the assessment360_controller.rb and related files were necessary to improve the code's readability, maintainability, and adherence to best practices. Let's discuss each change and its significance:&lt;br /&gt;
&lt;br /&gt;
===Files modified===&lt;br /&gt;
&lt;br /&gt;
==== 1. Changes to &amp;lt;code&amp;gt;app/views/assessment360/all_student_all_reviews.html.erb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|Checked and renamed&amp;lt;code&amp;gt;@teamed_count&amp;lt;/code&amp;gt; variable&lt;br /&gt;
|Checked the usage of variable through IDE whether the variable is used. The variable was used to display the total number of teams each student has collaborated with. Thus, it was renamed from &amp;lt;code&amp;gt;@teamed_count&amp;lt;/code&amp;gt; to &amp;lt;code&amp;gt;@student_team_counts&amp;lt;/code&amp;gt; in both &amp;lt;code&amp;gt;app/controller/assessment360_controller.rb&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;app/views/assessment360/all_student_all_reviews.html.erb&amp;lt;/code&amp;gt; files for better readability and understandability of the code.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|-&lt;br /&gt;
|2&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;| Added check boxes to select columns to display &lt;br /&gt;
|Added 2 check boxes (meta reviews and teammate reviews) to select/deselect columns to be displayed. &lt;br /&gt;
|[https://github.com/expertiza/expertiza/pull/2792/commits/9190886b4e4825bdf426500de37e08614c48e19a Commit]&lt;br /&gt;
|-&lt;br /&gt;
|3&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;| Hide empty columns &lt;br /&gt;
|Added checks to ensure column is displayed only when at least one of the rows has a corresponding value to that column in the database. &lt;br /&gt;
|[https://github.com/expertiza/expertiza/pull/2792/commits/8dc145ab7541f590ce811c66ce44455ad635769c Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== 2. Changes to &amp;lt;code&amp;gt;Gemfile&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;config/environments/development.rb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;|Added and initialized the bullet gem&lt;br /&gt;
|To identify and reduce unnecessary database queries, the bullet gem was added and activated to increase the performance of the application.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== 3. Changes to &amp;lt;code&amp;gt;app/views/assessment360/course_student_grade_summary.html.erb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;|Separated student name and student ID into different columns&lt;br /&gt;
|In order to achieve better understanding of the data being displayed, student name and student ID were separated into different columns.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== 4. Changes to &amp;lt;code&amp;gt;app/controllers/assessment360_controller.rb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;|Replaced hyphen '-' with an en-dash '–'&lt;br /&gt;
|Since hyphen was used to represent empty values, it was replaced with an en-dash for enhancing the UI.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|-&lt;br /&gt;
|2&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;| Refactored &amp;lt;code&amp;gt;calc_overall_review_info()&amp;lt;/code&amp;gt;&lt;br /&gt;
|Ensured that if a student has not received a grade for an assignment that row is not considered for calculating the average.&lt;br /&gt;
|[https://github.com/expertiza/expertiza/pull/2792/commits/0846538180ac5139301aba824ab847b2ba9ba58a Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== UI Changes made ==&lt;br /&gt;
&lt;br /&gt;
The assessment360 controller is responsible for the following two views - &lt;br /&gt;
&lt;br /&gt;
'''1) all_students_all_reviews.html.erb''' - This view displays a table of students, their teammate count, and their performance on various assignments. For each assignment, it shows the metareview and teammate review scores. At the end of each row, it displays the aggregate score for metareviews and teammate reviews for each student. The last row of the table provides the class average for each assignment and the overall class average for metareviews and teammate reviews.&lt;br /&gt;
[[File:Review dm.png|1000px|center|]]&lt;br /&gt;
'''Problems''' - &amp;lt;br&amp;gt;&lt;br /&gt;
1) The column is displayed even though all the rows are blank. &amp;lt;br&amp;gt;&lt;br /&gt;
2) The empty blanks can also lead to confusion and thus must be replaced. &amp;lt;br&amp;gt;&lt;br /&gt;
3) Allow user to choose the columns they wish to be displayed. &amp;lt;br&amp;gt;&lt;br /&gt;
4) Separate columns for student name and student ID &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
'''2) course_student_grade_summary.html.erb''' - This view displays a sortable table of students, their assignments, and their grades. For each assignment, it shows the topic, the peer review score, and the instructor's grade. At the end of each row, it displays the total instructor grade for each student. The table can be sorted by student name or total instructor grade.&lt;br /&gt;
[[File:Grade summary.png|1000px|center|]]&lt;br /&gt;
'''Problems''' - &amp;lt;br&amp;gt;&lt;br /&gt;
1) A new column for average peer review score needs to be added. &amp;lt;br&amp;gt;&lt;br /&gt;
2) Allow user to choose the columns they wish to be displayed. &amp;lt;br&amp;gt;&lt;br /&gt;
2) Separate columns for student name and student ID &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Code Snippets ==&lt;br /&gt;
&lt;br /&gt;
[[File:Hashes.png|600px]] &amp;lt;br&amp;gt;&lt;br /&gt;
We created 2 hashes &amp;lt;code&amp;gt;meta_review_exists&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;teammate_review_exists&amp;lt;/code&amp;gt; which track if the respective values exist for each assignment. We use these hashes in our view to decide whether to display columns or not. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Boolean.png|600px]]&amp;lt;br&amp;gt;&lt;br /&gt;
Here we are assigning values to those hashes based on whether the review exists or not for that particular assignment. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Logic.png|600px]]&amp;lt;br&amp;gt;&lt;br /&gt;
This is the new logic for calculating grade averages ensuring that only those grades are considered which have been reviewed for the average calculation so that the calculation is accurate. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Script.png|600px]]&amp;lt;br&amp;gt;&lt;br /&gt;
This is the JavaScript code we wrote to ensure that our view changes dynamically based on selection/deselection of the checkboxes. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Design Principles and Patterns ==&lt;br /&gt;
We have tried to apply the techniques we have learned in the class wherever it was possible. This included DRYing out the code and adding proper comments enhancing its readability and maintainability. &lt;br /&gt;
* We created a method called &amp;lt;code&amp;gt;handleCheckboxChange&amp;lt;/code&amp;gt; which was responsible for listening to various checkbox events, thus helping us to DRY out our code since we did not have to write the same code again for another checkbox. &amp;lt;br&amp;gt;&lt;br /&gt;
== Test Plan==&lt;br /&gt;
&lt;br /&gt;
The following test plan has been identified to ensure that the our changes don't break the existing system and the new code being introduced is thoroughly tested.&lt;br /&gt;
&lt;br /&gt;
=== Manual Testing ===&lt;br /&gt;
The following tests have been identified to ensure that the changes made work as anticipated:&lt;br /&gt;
&lt;br /&gt;
1. Select any course&lt;br /&gt;
[[File:Expertiza-3.png|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
2. Go to the all_students_all_reviews page by clicking on the icon next to the globe icon. &lt;br /&gt;
[[File:Expertiza-2.PNG|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
3. Verify that only those columns are visible with at least one data point. &lt;br /&gt;
&lt;br /&gt;
4. Add checkboxes at the top of the screen and ensure columns are hidden or visible based on the selected checkboxes&lt;br /&gt;
&lt;br /&gt;
5. Go to course_student_grade_summary by clicking on the the globe icon.&lt;br /&gt;
[[File:Expertiza-1.PNG|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
6. Verify that empty data that is shown as '-' (a hyphen) is replaced by an '–' (en-dash).&lt;br /&gt;
&lt;br /&gt;
7. Verify that average peer score column is visible and has correct values.&lt;br /&gt;
&lt;br /&gt;
8. Verify that unattempted assignments or assignments that are not graded are assigned '0' value instead of leaving it blank.&lt;br /&gt;
&lt;br /&gt;
9. Verify that unattempted assignments or assignments that are not graded aren't counted towards the average score. &lt;br /&gt;
&lt;br /&gt;
10. Verify that student name and student ID are in different columns&lt;br /&gt;
&lt;br /&gt;
11. Add checkboxes at the top of the screen and ensure columns are hidden or visible based on the selected checkboxes&lt;br /&gt;
&lt;br /&gt;
==Team==&lt;br /&gt;
===Mentor===&lt;br /&gt;
Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
&lt;br /&gt;
===Team Members===&lt;br /&gt;
1) Daksh Mehta (unityID: dmehta4, GitHub: [https://github.com/ dakshmehta23])&amp;lt;br&amp;gt;&lt;br /&gt;
2) Soham Patil (unityID: sspatil6, GitHub: [https://github.com/ ThErOCk07])&amp;lt;br&amp;gt;&lt;br /&gt;
3) Unnati Bukhariya (unityID: ubukhar2, GitHub: [https://github.com/ unnzzz])&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Relevant Links==&lt;br /&gt;
&lt;br /&gt;
'''1. Github repository:''' https://github.com/expertiza/expertiza&lt;br /&gt;
&lt;br /&gt;
'''2. Github forked repository:''' https://github.com/ThErOCk07/expertiza&lt;br /&gt;
&lt;br /&gt;
'''3. Github Pull request:'''&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=155762</id>
		<title>CSC/ECE 517 Spring 2024 - E2438 Improve assessment360 controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=155762"/>
		<updated>2024-04-22T04:00:15Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Introduction==&lt;br /&gt;
The Ruby on Rails framework serves as the foundation for the open-source project [https://expertiza.ncsu.edu/ Expertiza]. Expertiza offers features that let instructors see a comprehensive, 360-degree overview of the course they teach, including all of the assignments, all of the students enrolled in the course, all of their individual assignment scores, averages, and final scores. The assessment360 controller facilitates this feature.&lt;br /&gt;
&lt;br /&gt;
The following two views are mostly under the control of the assessment360 controller:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1) all_students_all_reviews: This view shows all of the student teammate and meta reviews for every program they worked on that semester. It also offers a summary of these review scores collectively.&lt;br /&gt;
&lt;br /&gt;
2) course_student_grade_summary: This view shows the topic, instructor grade, peer score, and summary of each assignment that students have completed. This also applies to the sum and mean of these scores.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The current implementation of the assessment360_controller.rb suffers from several issues such as repetitive elements, cryptic variable names, inaccurate grade calculations, and lack of flexibility in displaying different types of review scores. The objective of this project is to enhance the user interface and functionality of the assessment360_controller.rb in the application.&lt;br /&gt;
&lt;br /&gt;
Following are the issues to be addressed in this project:&lt;br /&gt;
&lt;br /&gt;
===Issues===&lt;br /&gt;
The main goals of this project are as follows:&lt;br /&gt;
* '''Issue #1:''' Refactor the all_students_all_reviews method to accept parameters specifying the type(s) of review scores to be displayed, and suppress columns for scores not selected.&lt;br /&gt;
* '''Issue #2:''' Rename the @teamed_count variable to a more descriptive name or remove it if not used.&lt;br /&gt;
* '''Issue #3:''' Ensure accuracy in grade calculations by including only the assignments that were attempted by the student in average grade calculation.&lt;br /&gt;
* '''Issue #4:''' Enhance the course_student_grade_summary method to include average peer-review scores and instructor-assigned scores. &lt;br /&gt;
* '''Issue #5:''' Columns for various types of review scores should be displayed based on user selection.&lt;br /&gt;
* '''Issue #6:''' Utilize the Bullet gem to minimize database accesses and optimize performance.&lt;br /&gt;
* '''Issue #7:''' Identify and address edge cases from the UI perspective to ensure consistent and clean behavior across different scenarios.&lt;br /&gt;
* '''Issue #8:''' Implement separate columns for student name and student ID to improve readability in the UI.&lt;br /&gt;
* '''Issue #9:''' Replace hyphen '-' with an en-dash '–'.&lt;br /&gt;
&lt;br /&gt;
==Implementation==&lt;br /&gt;
The changes made to the assessment360_controller.rb and related files were necessary to improve the code's readability, maintainability, and adherence to best practices. Let's discuss each change and its significance:&lt;br /&gt;
&lt;br /&gt;
===Files modified===&lt;br /&gt;
&lt;br /&gt;
==== 1. Changes to &amp;lt;code&amp;gt;app/views/assessment360/all_student_all_reviews.html.erb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|Checked and renamed&amp;lt;code&amp;gt;@teamed_count&amp;lt;/code&amp;gt; variable&lt;br /&gt;
|Checked the usage of variable through IDE whether the variable is used. The variable was used to display the total number of teams each student has collaborated with. Thus, it was renamed from &amp;lt;code&amp;gt;@teamed_count&amp;lt;/code&amp;gt; to &amp;lt;code&amp;gt;@student_team_counts&amp;lt;/code&amp;gt; in both &amp;lt;code&amp;gt;app/controller/assessment360_controller.rb&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;app/views/assessment360/all_student_all_reviews.html.erb&amp;lt;/code&amp;gt; files for better readability and understandability of the code.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|-&lt;br /&gt;
|2&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;| Added check boxes to select columns to display &lt;br /&gt;
|Added 2 check boxes (meta reviews and teammate reviews) to select/deselect columns to be displayed. &lt;br /&gt;
|[https://github.com/expertiza/expertiza/pull/2792/commits/9190886b4e4825bdf426500de37e08614c48e19a Commit]&lt;br /&gt;
|-&lt;br /&gt;
|3&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;| Hide empty columns &lt;br /&gt;
|Added checks to ensure column is displayed only when at least one of the rows has a corresponding value to that column in the database. &lt;br /&gt;
|[https://github.com/expertiza/expertiza/pull/2792/commits/8dc145ab7541f590ce811c66ce44455ad635769c Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== 2. Changes to &amp;lt;code&amp;gt;Gemfile&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;config/environments/development.rb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;|Added and initialized the bullet gem&lt;br /&gt;
|To identify and reduce unnecessary database queries, the bullet gem was added and activated to increase the performance of the application.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== 3. Changes to &amp;lt;code&amp;gt;app/views/assessment360/course_student_grade_summary.html.erb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;|Separated student name and student ID into different columns&lt;br /&gt;
|In order to achieve better understanding of the data being displayed, student name and student ID were separated into different columns.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== 4. Changes to &amp;lt;code&amp;gt;app/controllers/assessment360_controller.rb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;|Replaced hyphen '-' with an en-dash '–'&lt;br /&gt;
|Since hyphen was used to represent empty values, it was replaced with an en-dash for enhancing the UI.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|-&lt;br /&gt;
|2&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;| Refactored &amp;lt;code&amp;gt;calc_overall_review_info()&amp;lt;/code&amp;gt;&lt;br /&gt;
|Ensured that if a student has not received a grade for an assignment that row is not considered for calculating the average.&lt;br /&gt;
|[https://github.com/expertiza/expertiza/pull/2792/commits/0846538180ac5139301aba824ab847b2ba9ba58a Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== UI Changes made ==&lt;br /&gt;
&lt;br /&gt;
The assessment360 controller is responsible for the following two views - &lt;br /&gt;
&lt;br /&gt;
'''1) all_students_all_reviews.html.erb''' - This view displays a table of students, their teammate count, and their performance on various assignments. For each assignment, it shows the metareview and teammate review scores. At the end of each row, it displays the aggregate score for metareviews and teammate reviews for each student. The last row of the table provides the class average for each assignment and the overall class average for metareviews and teammate reviews.&lt;br /&gt;
[[File:Review dm.png|1000px|center|]]&lt;br /&gt;
'''Problems''' - &amp;lt;br&amp;gt;&lt;br /&gt;
1) The column is displayed even though all the rows are blank. &amp;lt;br&amp;gt;&lt;br /&gt;
2) The empty blanks can also lead to confusion and thus must be replaced. &amp;lt;br&amp;gt;&lt;br /&gt;
3) Allow user to choose the columns they wish to be displayed. &amp;lt;br&amp;gt;&lt;br /&gt;
4) Separate columns for student name and student ID &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
'''2) course_student_grade_summary.html.erb''' - This view displays a sortable table of students, their assignments, and their grades. For each assignment, it shows the topic, the peer review score, and the instructor's grade. At the end of each row, it displays the total instructor grade for each student. The table can be sorted by student name or total instructor grade.&lt;br /&gt;
[[File:Grade summary.png|1000px|center|]]&lt;br /&gt;
'''Problems''' - &amp;lt;br&amp;gt;&lt;br /&gt;
1) A new column for average peer review score needs to be added. &amp;lt;br&amp;gt;&lt;br /&gt;
2) Allow user to choose the columns they wish to be displayed. &amp;lt;br&amp;gt;&lt;br /&gt;
2) Separate columns for student name and student ID &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Code Snippets ==&lt;br /&gt;
&lt;br /&gt;
[[File:Hashes.png|600px]] &amp;lt;br&amp;gt;&lt;br /&gt;
We created 2 hashes &amp;lt;code&amp;gt;meta_review_exists&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;teammate_review_exists&amp;lt;/code&amp;gt; which track if the respective values exist for each assignment. We use these hashes in our view to decide whether to display columns or not. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Boolean.png|600px]]&amp;lt;br&amp;gt;&lt;br /&gt;
Here we are assigning values to those hashes based on whether the review exists or not for that particular assignment. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Logic.png|600px]]&amp;lt;br&amp;gt;&lt;br /&gt;
This is the new logic for calculating grade averages ensuring that only those grades are considered which have been reviewed for the average calculation so that the calculation is accurate. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Script.png|600px]]&amp;lt;br&amp;gt;&lt;br /&gt;
This is the JavaScript code we wrote to ensure that our view changes dynamically based on selection/deselection of the checkboxes. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Test Plan==&lt;br /&gt;
&lt;br /&gt;
The following test plan has been identified to ensure that the our changes don't break the existing system and the new code being introduced is thoroughly tested.&lt;br /&gt;
&lt;br /&gt;
=== Manual Testing ===&lt;br /&gt;
The following tests have been identified to ensure that the changes made work as anticipated:&lt;br /&gt;
&lt;br /&gt;
1. Select any course&lt;br /&gt;
[[File:Expertiza-3.png|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
2. Go to the all_students_all_reviews page by clicking on the icon next to the globe icon. &lt;br /&gt;
[[File:Expertiza-2.PNG|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
3. Verify that only those columns are visible with at least one data point. &lt;br /&gt;
&lt;br /&gt;
4. Add checkboxes at the top of the screen and ensure columns are hidden or visible based on the selected checkboxes&lt;br /&gt;
&lt;br /&gt;
5. Go to course_student_grade_summary by clicking on the the globe icon.&lt;br /&gt;
[[File:Expertiza-1.PNG|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
6. Verify that empty data that is shown as '-' (a hyphen) is replaced by an '–' (en-dash).&lt;br /&gt;
&lt;br /&gt;
7. Verify that average peer score column is visible and has correct values.&lt;br /&gt;
&lt;br /&gt;
8. Verify that unattempted assignments or assignments that are not graded are assigned '0' value instead of leaving it blank.&lt;br /&gt;
&lt;br /&gt;
9. Verify that unattempted assignments or assignments that are not graded aren't counted towards the average score. &lt;br /&gt;
&lt;br /&gt;
10. Verify that student name and student ID are in different columns&lt;br /&gt;
&lt;br /&gt;
11. Add checkboxes at the top of the screen and ensure columns are hidden or visible based on the selected checkboxes&lt;br /&gt;
&lt;br /&gt;
==Team==&lt;br /&gt;
===Mentor===&lt;br /&gt;
Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
&lt;br /&gt;
===Team Members===&lt;br /&gt;
1) Daksh Mehta (unityID: dmehta4, GitHub: [https://github.com/ dakshmehta23])&amp;lt;br&amp;gt;&lt;br /&gt;
2) Soham Patil (unityID: sspatil6, GitHub: [https://github.com/ ThErOCk07])&amp;lt;br&amp;gt;&lt;br /&gt;
3) Unnati Bukhariya (unityID: ubukhar2, GitHub: [https://github.com/ unnzzz])&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Relevant Links==&lt;br /&gt;
&lt;br /&gt;
'''1. Github repository:''' https://github.com/expertiza/expertiza&lt;br /&gt;
&lt;br /&gt;
'''2. Github forked repository:''' https://github.com/ThErOCk07/expertiza&lt;br /&gt;
&lt;br /&gt;
'''3. Github Pull request:'''&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Script.png&amp;diff=155761</id>
		<title>File:Script.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Script.png&amp;diff=155761"/>
		<updated>2024-04-22T03:49:46Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Logic.png&amp;diff=155760</id>
		<title>File:Logic.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Logic.png&amp;diff=155760"/>
		<updated>2024-04-22T03:49:21Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Hashes.png&amp;diff=155759</id>
		<title>File:Hashes.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Hashes.png&amp;diff=155759"/>
		<updated>2024-04-22T03:49:03Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Boolean.png&amp;diff=155758</id>
		<title>File:Boolean.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Boolean.png&amp;diff=155758"/>
		<updated>2024-04-22T03:48:28Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=155757</id>
		<title>CSC/ECE 517 Spring 2024 - E2438 Improve assessment360 controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=155757"/>
		<updated>2024-04-22T03:28:27Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Introduction==&lt;br /&gt;
The Ruby on Rails framework serves as the foundation for the open-source project [https://expertiza.ncsu.edu/ Expertiza]. Expertiza offers features that let instructors see a comprehensive, 360-degree overview of the course they teach, including all of the assignments, all of the students enrolled in the course, all of their individual assignment scores, averages, and final scores. The assessment360 controller facilitates this feature.&lt;br /&gt;
&lt;br /&gt;
The following two views are mostly under the control of the assessment360 controller:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1) all_students_all_reviews: This view shows all of the student teammate and meta reviews for every program they worked on that semester. It also offers a summary of these review scores collectively.&lt;br /&gt;
&lt;br /&gt;
2) course_student_grade_summary: This view shows the topic, instructor grade, peer score, and summary of each assignment that students have completed. This also applies to the sum and mean of these scores.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The current implementation of the assessment360_controller.rb suffers from several issues such as repetitive elements, cryptic variable names, inaccurate grade calculations, and lack of flexibility in displaying different types of review scores. The objective of this project is to enhance the user interface and functionality of the assessment360_controller.rb in the application.&lt;br /&gt;
&lt;br /&gt;
Following are the issues to be addressed in this project:&lt;br /&gt;
&lt;br /&gt;
===Issues===&lt;br /&gt;
The main goals of this project are as follows:&lt;br /&gt;
* '''Issue #1:''' Refactor the all_students_all_reviews method to accept parameters specifying the type(s) of review scores to be displayed, and suppress columns for scores not selected.&lt;br /&gt;
* '''Issue #2:''' Rename the @teamed_count variable to a more descriptive name or remove it if not used.&lt;br /&gt;
* '''Issue #3:''' Ensure accuracy in grade calculations by including only the assignments that were attempted by the student in average grade calculation.&lt;br /&gt;
* '''Issue #4:''' Enhance the course_student_grade_summary method to include average peer-review scores and instructor-assigned scores. &lt;br /&gt;
* '''Issue #5:''' Columns for various types of review scores should be displayed based on user selection.&lt;br /&gt;
* '''Issue #6:''' Utilize the Bullet gem to minimize database accesses and optimize performance.&lt;br /&gt;
* '''Issue #7:''' Identify and address edge cases from the UI perspective to ensure consistent and clean behavior across different scenarios.&lt;br /&gt;
* '''Issue #8:''' Implement separate columns for student name and student ID to improve readability in the UI.&lt;br /&gt;
* '''Issue #9:''' Replace hyphen '-' with an en-dash '–'.&lt;br /&gt;
&lt;br /&gt;
==Implementation==&lt;br /&gt;
The changes made to the assessment360_controller.rb and related files were necessary to improve the code's readability, maintainability, and adherence to best practices. Let's discuss each change and its significance:&lt;br /&gt;
&lt;br /&gt;
===Files modified===&lt;br /&gt;
&lt;br /&gt;
==== 1. Changes to &amp;lt;code&amp;gt;app/controllers/assessment360_controller.rb&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;app/views/assessment360/all_student_all_reviews.html.erb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|Checked and renamed&amp;lt;code&amp;gt;@teamed_count&amp;lt;/code&amp;gt; variable&lt;br /&gt;
|Checked the usage of variable through IDE whether the variable is used. The variable was used to display the total number of teams each student has collaborated with. Thus, it was renamed from &amp;lt;code&amp;gt;@teamed_count&amp;lt;/code&amp;gt; to &amp;lt;code&amp;gt;@student_team_counts&amp;lt;/code&amp;gt; in both &amp;lt;code&amp;gt;app/controller/assessment360_controller.rb&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;app/views/assessment360/all_student_all_reviews.html.erb&amp;lt;/code&amp;gt; files for better readability and understandability of the code.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|-&lt;br /&gt;
|2&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;| Added check boxes to select columns to display &lt;br /&gt;
|Added 2 check boxes (meta reviews and teammate reviews) to select/deselect columns to be displayed. &lt;br /&gt;
|[https://github.com/expertiza/expertiza/pull/2792/commits/9190886b4e4825bdf426500de37e08614c48e19a Commit]&lt;br /&gt;
|-&lt;br /&gt;
|3&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;| Hide empty columns &lt;br /&gt;
|Added checks to ensure column is displayed only when at least one of the rows has a corresponding value to that column in the database. &lt;br /&gt;
|[https://github.com/expertiza/expertiza/pull/2792/commits/8dc145ab7541f590ce811c66ce44455ad635769c Commit]&lt;br /&gt;
|-&lt;br /&gt;
|4&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;| Refactored &amp;lt;code&amp;gt;calc_overall_review_info()&amp;lt;/code&amp;gt;&lt;br /&gt;
|Ensured that if a student has not received a grade for an assignment that row is not considered for calculating the average.&lt;br /&gt;
|[https://github.com/expertiza/expertiza/pull/2792/commits/0846538180ac5139301aba824ab847b2ba9ba58a Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== 2. Changes to &amp;lt;code&amp;gt;Gemfile&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;config/environments/development.rb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;|Added and initialized the bullet gem&lt;br /&gt;
|To identify and reduce unnecessary database queries, the bullet gem was added and activated to increase the performance of the application.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== 3. Changes to &amp;lt;code&amp;gt;app/views/assessment360/course_student_grade_summary.html.erb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;|Separated student name and student ID into different columns&lt;br /&gt;
|In order to achieve better understanding of the data being displayed, student name and student ID were separated into different columns.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== 4. Changes to &amp;lt;code&amp;gt;app/controllers/assessment360_controller.rb&amp;lt;/code&amp;gt; ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%;&lt;br /&gt;
! &amp;amp;nbsp;#&amp;amp;nbsp; !! Change !! Rationale !! Commit Link&lt;br /&gt;
|-&lt;br /&gt;
|1&lt;br /&gt;
|style=&amp;quot;width: 30%&amp;quot;|Replaced hyphen '-' with an en-dash '–'&lt;br /&gt;
|Since hyphen was used to represent empty values, it was replaced with an en-dash for enhancing the UI.&lt;br /&gt;
|[https://github.com/kartikrawool/expertiza/commit/6403edc25cf0edde623da63f23d92a1a57d67375 Commit]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Team==&lt;br /&gt;
===Mentor===&lt;br /&gt;
Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
&lt;br /&gt;
===Team Members===&lt;br /&gt;
1) Daksh Mehta (unityID: dmehta4, GitHub: [https://github.com/ dakshmehta23])&amp;lt;br&amp;gt;&lt;br /&gt;
2) Soham Patil (unityID: sspatil6, GitHub: [https://github.com/ ThErOCk07])&amp;lt;br&amp;gt;&lt;br /&gt;
3) Unnati Bukhariya (unityID: ubukhar2, GitHub: [https://github.com/ unnzzz])&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The assessment360 controller is responsible for the following two views - &lt;br /&gt;
&lt;br /&gt;
'''1) all_students_all_reviews.html.erb''' - This view displays a table of students, their teammate count, and their performance on various assignments. For each assignment, it shows the metareview and teammate review scores. At the end of each row, it displays the aggregate score for metareviews and teammate reviews for each student. The last row of the table provides the class average for each assignment and the overall class average for metareviews and teammate reviews.&lt;br /&gt;
[[File:Review dm.png|1000px|center|]]&lt;br /&gt;
'''Problems''' - &amp;lt;br&amp;gt;&lt;br /&gt;
1) The column is displayed even though all the rows are blank. &amp;lt;br&amp;gt;&lt;br /&gt;
2) The empty blanks can also lead to confusion and thus must be replaced. &amp;lt;br&amp;gt;&lt;br /&gt;
3) Allow user to choose the columns they wish to be displayed. &amp;lt;br&amp;gt;&lt;br /&gt;
4) Separate columns for student name and student ID &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
'''2) course_student_grade_summary.html.erb''' - This view displays a sortable table of students, their assignments, and their grades. For each assignment, it shows the topic, the peer review score, and the instructor's grade. At the end of each row, it displays the total instructor grade for each student. The table can be sorted by student name or total instructor grade.&lt;br /&gt;
[[File:Grade summary.png|1000px|center|]]&lt;br /&gt;
'''Problems''' - &amp;lt;br&amp;gt;&lt;br /&gt;
1) A new column for average peer review score needs to be added. &amp;lt;br&amp;gt;&lt;br /&gt;
2) Allow user to choose the columns they wish to be displayed. &amp;lt;br&amp;gt;&lt;br /&gt;
2) Separate columns for student name and student ID &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Test Plan==&lt;br /&gt;
&lt;br /&gt;
The following test plan has been identified to ensure that the our changes don't break the existing system and the new code being introduced is thoroughly tested.&lt;br /&gt;
&lt;br /&gt;
=== Manual Testing ===&lt;br /&gt;
The following tests have been identified to ensure that the changes made work as anticipated:&lt;br /&gt;
&lt;br /&gt;
1. Select any course&lt;br /&gt;
[[File:Expertiza-3.png|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
2. Go to the all_students_all_reviews page by clicking on the icon next to the globe icon. &lt;br /&gt;
[[File:Expertiza-2.PNG|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
3. Verify that only those columns are visible with at least one data point. &lt;br /&gt;
&lt;br /&gt;
4. Add checkboxes at the top of the screen and ensure columns are hidden or visible based on the selected checkboxes&lt;br /&gt;
&lt;br /&gt;
5. Go to course_student_grade_summary by clicking on the the globe icon.&lt;br /&gt;
[[File:Expertiza-1.PNG|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
6. Verify that empty data that is shown as '-' (a hyphen) is replaced by an '–' (en-dash).&lt;br /&gt;
&lt;br /&gt;
7. Verify that average peer score column is visible and has correct values.&lt;br /&gt;
&lt;br /&gt;
8. Verify that unattempted assignments or assignments that are not graded are assigned '0' value instead of leaving it blank.&lt;br /&gt;
&lt;br /&gt;
9. Verify that unattempted assignments or assignments that are not graded aren't counted towards the average score. &lt;br /&gt;
&lt;br /&gt;
10. Verify that student name and student ID are in different columns&lt;br /&gt;
&lt;br /&gt;
11. Add checkboxes at the top of the screen and ensure columns are hidden or visible based on the selected checkboxes&lt;br /&gt;
&lt;br /&gt;
== Relevant Links==&lt;br /&gt;
&lt;br /&gt;
'''1. Github repository:''' https://github.com/expertiza/expertiza&lt;br /&gt;
&lt;br /&gt;
'''2. Github forked repository:''' https://github.com/ThErOCk07/expertiza&lt;br /&gt;
&lt;br /&gt;
'''3. Github Pull request:'''&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=154945</id>
		<title>CSC/ECE 517 Spring 2024 - E2438 Improve assessment360 controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=154945"/>
		<updated>2024-04-08T02:03:59Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Problem Statement==&lt;br /&gt;
The objective of this project is to enhance the user interface and functionality of the assessment360_controller.rb in the application. This controller is responsible for displaying course-level data, including review averages, project details for each student, and their corresponding grades. The current implementation suffers from several issues such as repetitive elements, cryptic variable names, inaccurate grade calculations, and lack of flexibility in displaying different types of review scores.&lt;br /&gt;
==Team==&lt;br /&gt;
===Mentor===&lt;br /&gt;
Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
&lt;br /&gt;
===Team Members===&lt;br /&gt;
Daksh Mehta (unityID:dmehta4, GitHub:dakshmehta23)&amp;lt;br&amp;gt;&lt;br /&gt;
Soham Patil (unityID:sspatil6, GitHub:ThErOCk07)&amp;lt;br&amp;gt;&lt;br /&gt;
Unnati Bukhariya (unityID:ubukhar2, GitHub:unnzzz)&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Issues to be addressed==&lt;br /&gt;
The main goals of this project are as follows:&lt;br /&gt;
* '''Issue #1:''' Refactor the all_students_all_reviews method to accept parameters specifying the type(s) of review scores to be displayed, and suppress columns for scores not selected.&lt;br /&gt;
* '''Issue #2:''' Rename the @teamed_count variable to a more descriptive name or remove it if not used.&lt;br /&gt;
* '''Issue #3:''' Ensure accuracy in grade calculations by including only the assignments that were attempted by the student in average grade calculation.&lt;br /&gt;
* '''Issue #4:''' Enhance the course_student_grade_summary method to include average peer-review scores and instructor-assigned scores. &lt;br /&gt;
* '''Issue #5:''' Columns for various types of review scores should be displayed based on user selection.&lt;br /&gt;
* '''Issue #6:''' Utilize the Bullet gem to minimize database accesses and optimize performance.&lt;br /&gt;
* '''Issue #7:''' Identify and address edge cases from the UI perspective to ensure consistent and clean behavior across different scenarios.&lt;br /&gt;
* '''Issue #8:''' Implement separate columns for student name and student ID to improve readability in the UI.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The assessment360 controller is responsible for the following two views - &lt;br /&gt;
&lt;br /&gt;
'''1) all_students_all_reviews.html.erb''' - This view displays a table of students, their teammate count, and their performance on various assignments. For each assignment, it shows the metareview and teammate review scores. At the end of each row, it displays the aggregate score for metareviews and teammate reviews for each student. The last row of the table provides the class average for each assignment and the overall class average for metareviews and teammate reviews.&lt;br /&gt;
[[File:Review dm.png|1000px|center|]]&lt;br /&gt;
'''Problems''' - &amp;lt;br&amp;gt;&lt;br /&gt;
1) The column is displayed even though all the rows are blank. &amp;lt;br&amp;gt;&lt;br /&gt;
2) The empty blanks can also lead to confusion and thus must be replaced. &amp;lt;br&amp;gt;&lt;br /&gt;
3) Allow user to choose the columns they wish to be displayed. &amp;lt;br&amp;gt;&lt;br /&gt;
4) Separate columns for student name and student ID &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
'''2) course_student_grade_summary.html.erb''' - This view displays a sortable table of students, their assignments, and their grades. For each assignment, it shows the topic, the peer review score, and the instructor's grade. At the end of each row, it displays the total instructor grade for each student. The table can be sorted by student name or total instructor grade.&lt;br /&gt;
[[File:Grade summary.png|1000px|center|]]&lt;br /&gt;
'''Problems''' - &amp;lt;br&amp;gt;&lt;br /&gt;
1) A new column for average peer review score needs to be added. &amp;lt;br&amp;gt;&lt;br /&gt;
2) Allow user to choose the columns they wish to be displayed. &amp;lt;br&amp;gt;&lt;br /&gt;
2) Separate columns for student name and student ID &amp;lt;br&amp;gt;&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=154944</id>
		<title>CSC/ECE 517 Spring 2024 - E2438 Improve assessment360 controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=154944"/>
		<updated>2024-04-08T02:02:56Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Problem Statement==&lt;br /&gt;
The objective of this project is to enhance the user interface and functionality of the assessment360_controller.rb in the application. This controller is responsible for displaying course-level data, including review averages, project details for each student, and their corresponding grades. The current implementation suffers from several issues such as repetitive elements, cryptic variable names, inaccurate grade calculations, and lack of flexibility in displaying different types of review scores.&lt;br /&gt;
==Team==&lt;br /&gt;
===Mentor===&lt;br /&gt;
Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
&lt;br /&gt;
===Team Members===&lt;br /&gt;
Daksh Mehta (unityID:dmehta4, GitHub:dakshmehta23)&amp;lt;br&amp;gt;&lt;br /&gt;
Soham Patil (unityID:sspatil6, GitHub:ThErOCk07)&amp;lt;br&amp;gt;&lt;br /&gt;
Unnati Bukhariya (unityID:ubukhar2, GitHub:unnzzz)&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Issues to be addressed==&lt;br /&gt;
The main goals of this project are as follows:&lt;br /&gt;
* '''Issue #1:''' Refactor the all_students_all_reviews method to accept parameters specifying the type(s) of review scores to be displayed, and suppress columns for scores not selected.&lt;br /&gt;
* '''Issue #2:''' Rename the @teamed_count variable to a more descriptive name or remove it if not used.&lt;br /&gt;
* '''Issue #3:''' Ensure accuracy in grade calculations by including only the assignments that were attempted by the student in average grade calculation.&lt;br /&gt;
* '''Issue #4:''' Enhance the course_student_grade_summary method to include average peer-review scores and instructor-assigned scores. &lt;br /&gt;
* '''Issue #5:''' Columns for various types of review scores should be displayed based on user selection.&lt;br /&gt;
* '''Issue #6:''' Utilize the Bullet gem to minimize database accesses and optimize performance.&lt;br /&gt;
* '''Issue #7:''' Identify and address edge cases from the UI perspective to ensure consistent and clean behavior across different scenarios.&lt;br /&gt;
* '''Issue #8:''' Implement separate columns for student name and student ID to improve readability in the UI.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The assessment360 controller is responsible for the following two views - &lt;br /&gt;
&lt;br /&gt;
'''1) all_students_all_reviews.html.erb''' - This view displays a table of students, their teammate count, and their performance on various assignments. For each assignment, it shows the metareview and teammate review scores. At the end of each row, it displays the aggregate score for metareviews and teammate reviews for each student. The last row of the table provides the class average for each assignment and the overall class average for metareviews and teammate reviews.&lt;br /&gt;
[[File:Review dm.png|1000px|center|]]&lt;br /&gt;
'''Problems''' - &amp;lt;br&amp;gt;&lt;br /&gt;
1) The column is displayed even though all the rows are blank. &amp;lt;br&amp;gt;&lt;br /&gt;
2) The empty blanks can also lead to confusion and thus must be replaced. &amp;lt;br&amp;gt;&lt;br /&gt;
3) Allow user to choose the columns they wish to be displayed. &amp;lt;br&amp;gt;&lt;br /&gt;
4) Separate columns for student name and student ID &amp;lt;br&amp;gt;&lt;br /&gt;
'''2) course_student_grade_summary.html.erb''' - This view displays a sortable table of students, their assignments, and their grades. For each assignment, it shows the topic, the peer review score, and the instructor's grade. At the end of each row, it displays the total instructor grade for each student. The table can be sorted by student name or total instructor grade.&lt;br /&gt;
'''Problems''' - &amp;lt;br&amp;gt;&lt;br /&gt;
1) A new column for average peer review score needs to be added. &amp;lt;br&amp;gt;&lt;br /&gt;
2) Allow user to choose the columns they wish to be displayed. &amp;lt;br&amp;gt;&lt;br /&gt;
2) Separate columns for student name and student ID &amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Grade summary.png|1000px|center|]]&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=154941</id>
		<title>CSC/ECE 517 Spring 2024 - E2438 Improve assessment360 controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=154941"/>
		<updated>2024-04-08T01:53:04Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Problem Statement==&lt;br /&gt;
The objective of this project is to enhance the user interface and functionality of the assessment360_controller.rb in the application. This controller is responsible for displaying course-level data, including review averages, project details for each student, and their corresponding grades. The current implementation suffers from several issues such as repetitive elements, cryptic variable names, inaccurate grade calculations, and lack of flexibility in displaying different types of review scores.&lt;br /&gt;
==Team==&lt;br /&gt;
===Mentor===&lt;br /&gt;
Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
&lt;br /&gt;
===Team Members===&lt;br /&gt;
Daksh Mehta (unityID:dmehta4, GitHub:dakshmehta23)&amp;lt;br&amp;gt;&lt;br /&gt;
Soham Patil (unityID:sspatil6, GitHub:ThErOCk07)&amp;lt;br&amp;gt;&lt;br /&gt;
Unnati Bukhariya (unityID:ubukhar2, GitHub:unnzzz)&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Issues to be addressed==&lt;br /&gt;
The main goals of this project are as follows:&lt;br /&gt;
* '''Issue #1:''' Refactor the all_students_all_reviews method to accept parameters specifying the type(s) of review scores to be displayed, and suppress columns for scores not selected.&lt;br /&gt;
* '''Issue #2:''' Rename the @teamed_count variable to a more descriptive name or remove it if not used.&lt;br /&gt;
* '''Issue #3:''' Ensure accuracy in grade calculations by including only the assignments that were attempted by the student in average grade calculation.&lt;br /&gt;
* '''Issue #4:''' Enhance the course_student_grade_summary method to include average peer-review scores and instructor-assigned scores. &lt;br /&gt;
* '''Issue #5:''' Columns for various types of review scores should be displayed based on user selection.&lt;br /&gt;
* '''Issue #6:''' Utilize the Bullet gem to minimize database accesses and optimize performance.&lt;br /&gt;
* '''Issue #7:''' Identify and address edge cases from the UI perspective to ensure consistent and clean behavior across different scenarios.&lt;br /&gt;
* '''Issue #8:''' Implement separate columns for student name and student ID to improve readability in the UI.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The assessment360 controller is responsible for the following two views - &lt;br /&gt;
&lt;br /&gt;
1) '''all_students_all_reviews.html.erb''' - This view displays a table of students, their teammate count, and their performance on various assignments. For each assignment, it shows the metareview and teammate review scores. At the end of each row, it displays the aggregate score for metareviews and teammate reviews for each student. The last row of the table provides the class average for each assignment and the overall class average for metareviews and teammate reviews.&lt;br /&gt;
[[File:Review dm.png|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
2) '''course_student_grade_summary.html.erb''' - This view displays a sortable table of students, their assignments, and their grades. For each assignment, it shows the topic, the peer review score, and the instructor's grade. At the end of each row, it displays the total instructor grade for each student. The table can be sorted by student name or total instructor grade.&lt;br /&gt;
[[File:Grade summary.png|1000px|center|]]&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Review_dm.png&amp;diff=154940</id>
		<title>File:Review dm.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Review_dm.png&amp;diff=154940"/>
		<updated>2024-04-08T01:52:48Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Grade_summary.png&amp;diff=154939</id>
		<title>File:Grade summary.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Grade_summary.png&amp;diff=154939"/>
		<updated>2024-04-08T01:50:21Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=154938</id>
		<title>CSC/ECE 517 Spring 2024 - E2438 Improve assessment360 controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=154938"/>
		<updated>2024-04-08T01:50:04Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Problem Statement==&lt;br /&gt;
The objective of this project is to enhance the user interface and functionality of the assessment360_controller.rb in the application. This controller is responsible for displaying course-level data, including review averages, project details for each student, and their corresponding grades. The current implementation suffers from several issues such as repetitive elements, cryptic variable names, inaccurate grade calculations, and lack of flexibility in displaying different types of review scores.&lt;br /&gt;
==Team==&lt;br /&gt;
===Mentor===&lt;br /&gt;
Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
&lt;br /&gt;
===Team Members===&lt;br /&gt;
Daksh Mehta (unityID:dmehta4, GitHub:dakshmehta23)&amp;lt;br&amp;gt;&lt;br /&gt;
Soham Patil (unityID:sspatil6, GitHub:ThErOCk07)&amp;lt;br&amp;gt;&lt;br /&gt;
Unnati Bukhariya (unityID:ubukhar2, GitHub:unnzzz)&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Issues to be addressed==&lt;br /&gt;
The main goals of this project are as follows:&lt;br /&gt;
* '''Issue #1:''' Refactor the all_students_all_reviews method to accept parameters specifying the type(s) of review scores to be displayed, and suppress columns for scores not selected.&lt;br /&gt;
* '''Issue #2:''' Rename the @teamed_count variable to a more descriptive name or remove it if not used.&lt;br /&gt;
* '''Issue #3:''' Ensure accuracy in grade calculations by including only the assignments that were attempted by the student in average grade calculation.&lt;br /&gt;
* '''Issue #4:''' Enhance the course_student_grade_summary method to include average peer-review scores and instructor-assigned scores. &lt;br /&gt;
* '''Issue #5:''' Columns for various types of review scores should be displayed based on user selection.&lt;br /&gt;
* '''Issue #6:''' Utilize the Bullet gem to minimize database accesses and optimize performance.&lt;br /&gt;
* '''Issue #7:''' Identify and address edge cases from the UI perspective to ensure consistent and clean behavior across different scenarios.&lt;br /&gt;
* '''Issue #8:''' Implement separate columns for student name and student ID to improve readability in the UI.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The assessment360 controller is responsible for the following two views - &lt;br /&gt;
&lt;br /&gt;
1) '''all_students_all_reviews.html.erb''' - This view displays a table of students, their teammate count, and their performance on various assignments. For each assignment, it shows the metareview and teammate review scores. At the end of each row, it displays the aggregate score for metareviews and teammate reviews for each student. The last row of the table provides the class average for each assignment and the overall class average for metareviews and teammate reviews.&lt;br /&gt;
&lt;br /&gt;
2) '''course_student_grade_summary.html.erb''' - This view displays a sortable table of students, their assignments, and their grades. For each assignment, it shows the topic, the peer review score, and the instructor's grade. At the end of each row, it displays the total instructor grade for each student. The table can be sorted by student name or total instructor grade.&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=154937</id>
		<title>CSC/ECE 517 Spring 2024 - E2438 Improve assessment360 controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=154937"/>
		<updated>2024-04-08T01:18:34Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Problem Statement==&lt;br /&gt;
The objective of this project is to enhance the user interface and functionality of the assessment360_controller.rb in the application. This controller is responsible for displaying course-level data, including review averages, project details for each student, and their corresponding grades. The current implementation suffers from several issues such as repetitive elements, cryptic variable names, inaccurate grade calculations, and lack of flexibility in displaying different types of review scores.&lt;br /&gt;
==Team==&lt;br /&gt;
===Mentor===&lt;br /&gt;
Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
&lt;br /&gt;
===Team Members===&lt;br /&gt;
Daksh Mehta (unityID:dmehta4, GitHub:dakshmehta23)&amp;lt;br&amp;gt;&lt;br /&gt;
Soham Patil (unityID:sspatil6, GitHub:ThErOCk07)&amp;lt;br&amp;gt;&lt;br /&gt;
Unnati Bukhariya (unityID:ubukhar2, GitHub:unnzzz)&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Issues to be addressed==&lt;br /&gt;
The main goals of this project are as follows:&lt;br /&gt;
* '''Issue #1:''' Refactor the all_students_all_reviews method to accept parameters specifying the type(s) of review scores to be displayed, and suppress columns for scores not selected.&lt;br /&gt;
* '''Issue #2:''' Rename the @teamed_count variable to a more descriptive name or remove it if not used.&lt;br /&gt;
* '''Issue #3:''' Ensure accuracy in grade calculations by including only the assignments that were attempted by the student in average grade calculation.&lt;br /&gt;
* '''Issue #4:''' Enhance the course_student_grade_summary method to include average peer-review scores and instructor-assigned scores. &lt;br /&gt;
* '''Issue #5:''' Columns for various types of review scores should be displayed based on user selection.&lt;br /&gt;
* '''Issue #6:''' Utilize the Bullet gem to minimize database accesses and optimize performance.&lt;br /&gt;
* '''Issue #7:''' Identify and address edge cases from the UI perspective to ensure consistent and clean behavior across different scenarios.&lt;br /&gt;
* '''Issue #8:''' Implement separate columns for student name and student ID to improve readability in the UI.&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=154936</id>
		<title>CSC/ECE 517 Spring 2024 - E2438 Improve assessment360 controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2438_Improve_assessment360_controller&amp;diff=154936"/>
		<updated>2024-04-08T01:07:51Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: Created page with &amp;quot;init&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;init&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153918</id>
		<title>CSC/ECE 517 Spring 2024 - E2408. Refactor course.rb and course team.rb models</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153918"/>
		<updated>2024-03-24T22:57:48Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==E2408. Refactor course.rb and course_team.rb models==&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
== Team ==&lt;br /&gt;
=== Members ===&lt;br /&gt;
&lt;br /&gt;
* Daksh Mehta, (unityID:dmehta4, GitHub:dakshmehta23)&lt;br /&gt;
* Soham Patil, (unityID:sspatil6@ncsu.edu, GitHub:ThErOCk07)&lt;br /&gt;
* Unnati Bukhariya, (unityID:ubukhar2@ncsu.edu, GitHub:unnzzz)&lt;br /&gt;
&lt;br /&gt;
=== Mentor ===&lt;br /&gt;
* Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
== Expertiza Overview ==&lt;br /&gt;
&lt;br /&gt;
===Background===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source software written using Ruby on Rails which functions as a learning management software system. It has many different functions and abilities including the ability to create assignments, quizzes, assignment groups, and topics, and also a complete mechanism for providing peer reviews and feedback for other groups and other teammates. It is used in select courses at NC State and by professors at several other colleges and universities.&lt;br /&gt;
&lt;br /&gt;
course.rb and course_team.rb models are objects containing information about the course and their associated teams respectively. CourseTeams are used when an instructor wants to use the same teams for the entire semester. CourseTeam  is one subclass of Team ; AssignmentTeam is the other.  An AssignmentTeam is a team that is created for students to do a single assignment.  It is possible to copy CourseTeams to an assignment, where they become AssignmentTeams, or vice versa.&lt;br /&gt;
&lt;br /&gt;
The Course and CourseTeam models had some code smells/issues that were fixed. There were a few methods in these models that shouldn’t be in those models, and a few methods that are no longer used. Certain method names were refactored in order to better understand their functionality.&lt;br /&gt;
&lt;br /&gt;
== Requirements ==&lt;br /&gt;
&lt;br /&gt;
The following changes were made to the models course.rb and course_team.rb&lt;br /&gt;
=== Changes in course.rb ===&lt;br /&gt;
* '''Removal of get_participant Method'''&lt;br /&gt;
        The method get_participant was removed.&lt;br /&gt;
        A global search revealed it was unused throughout the app.&lt;br /&gt;
        Consequently, the method and its respective RSpec test were removed.&lt;br /&gt;
&lt;br /&gt;
* '''Rename copy_participants Method'''&lt;br /&gt;
        Renamed the method to copy_assignment_participants.&lt;br /&gt;
        This new name accurately reflects the method's purpose, which is specific to assignments, enhancing clarity and understanding.&lt;br /&gt;
&lt;br /&gt;
* '''Error Handling Enhancement'''&lt;br /&gt;
        Refactored add_participant and copy_assignment_participants methods for improved error handling and readability.&lt;br /&gt;
        Introduced a new method, handle_errors, to centralize error handling and separate it from main function logic.&lt;br /&gt;
&lt;br /&gt;
* '''Other Changes'''&lt;br /&gt;
        Utilized find_by instead of where.first for SQL queries to the model.&lt;br /&gt;
        Employed errors.any? instead of unless errors.empty? for better readability.&lt;br /&gt;
        Added comments throughout the code for improved documentation and understanding.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Changes in course_team.rb  ===&lt;br /&gt;
&lt;br /&gt;
* '''Removal of add_member method'''&lt;br /&gt;
        The method add_member was removed.&lt;br /&gt;
        As Course_team is a subclass of Team, it inherited the add_member functionality from the superclass. Hence, it was removed for better coherence and modularity.&lt;br /&gt;
&lt;br /&gt;
* '''Removal of assignment_id method'''&lt;br /&gt;
        The method assignment_id was removed.&lt;br /&gt;
        The assignment_id method wasn't utilized anywhere in the code and therefore had to be removed to reduce redundancy.&lt;br /&gt;
&lt;br /&gt;
* '''Refactoring Course.find(id) to Course.find(course_id)'''&lt;br /&gt;
        Any instances of Course.find(course_id) were replaced with Course.find(course_id) for better understandability of the code.&lt;br /&gt;
&lt;br /&gt;
* '''Refactoring copy method to copy_to_assignment_team'''&lt;br /&gt;
        The copy method copied a Course team to an assignment team and thus refactored to copy_to_assigment_team making the code easy to understand.&lt;br /&gt;
&lt;br /&gt;
* '''Refactoring the course_team.rb for importing and exporting csv files'''&lt;br /&gt;
        Refactored the course_team.rb file to adhere more closely to the Single Responsibility Principle (SRP). &lt;br /&gt;
        Removed the export and import methods from the model to create a more structured and uniform class.&lt;br /&gt;
&lt;br /&gt;
* '''Creating &amp;quot;team_csv_handler&amp;quot; as a common mechanism for handling csv files'''&lt;br /&gt;
        We extracted the import and export functions into a new class named TeamCsvHandler.&lt;br /&gt;
        This new class is responsible solely for handling CSV operations related to teams, so that each class has a distinct reponsibility.&lt;br /&gt;
        Eliminated the need to duplicate code for exporting , importing and displaying the csv files in the model.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Other Changes ===&lt;br /&gt;
&lt;br /&gt;
* The test corresponding to get_participant Method was removed from course_spec.rb&lt;br /&gt;
* The test corresponding to copy_participants Method was renamed to copy_assignment_participants.&lt;br /&gt;
&lt;br /&gt;
== Testing ==&lt;br /&gt;
&lt;br /&gt;
To validate the refactored models, we conducted UI testing. We mapped UI buttons and functionalities to their corresponding models and executed relevant tasks to verify the expected outcomes.&lt;br /&gt;
*'''Adding team members to a team'''&lt;br /&gt;
[[File:E2408 1.png|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
[[File:E2408 2.png|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*'''Running RSpec Tests'''&lt;br /&gt;
&lt;br /&gt;
[[File:E2408 3.png|1000px|center|]]&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
* '''GitHub Repo:''' https://github.com/dakshmehta23/expertiza&lt;br /&gt;
* '''Pull Request:''' https://github.com/expertiza/expertiza/pull/2752&lt;br /&gt;
* '''VCL URL:'''&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:E2408_3.png&amp;diff=153915</id>
		<title>File:E2408 3.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:E2408_3.png&amp;diff=153915"/>
		<updated>2024-03-24T22:55:53Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153894</id>
		<title>CSC/ECE 517 Spring 2024 - E2408. Refactor course.rb and course team.rb models</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153894"/>
		<updated>2024-03-24T22:50:07Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: /* Testing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==E2408. Refactor course.rb and course_team.rb models==&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
== Team ==&lt;br /&gt;
=== Members ===&lt;br /&gt;
&lt;br /&gt;
* Daksh Mehta, (unityID:dmehta4, GitHub:dakshmehta23)&lt;br /&gt;
* Soham Patil, (unityID:sspatil6@ncsu.edu, GitHub:ThErOCk07)&lt;br /&gt;
* Unnati Bukhariya, (unityID:ubukhar2@ncsu.edu, GitHub:unnzzz)&lt;br /&gt;
&lt;br /&gt;
=== Mentor ===&lt;br /&gt;
* Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
== Expertiza Overview ==&lt;br /&gt;
&lt;br /&gt;
===Background===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source software written using Ruby on Rails which functions as a learning management software system. It has many different functions and abilities including the ability to create assignments, quizzes, assignment groups, and topics, and also a complete mechanism for providing peer reviews and feedback for other groups and other teammates. It is used in select courses at NC State and by professors at several other colleges and universities.&lt;br /&gt;
&lt;br /&gt;
course.rb and course_team.rb models are objects containing information about the course and their associated teams respectively. CourseTeams are used when an instructor wants to use the same teams for the entire semester. CourseTeam  is one subclass of Team ; AssignmentTeam is the other.  An AssignmentTeam is a team that is created for students to do a single assignment.  It is possible to copy CourseTeams to an assignment, where they become AssignmentTeams, or vice versa.&lt;br /&gt;
&lt;br /&gt;
The Course and CourseTeam models had some code smells/issues that were fixed. There were a few methods in these models that shouldn’t be in those models, and a few methods that are no longer used. Certain method names were refactored in order to better understand their functionality.&lt;br /&gt;
&lt;br /&gt;
== Requirements ==&lt;br /&gt;
&lt;br /&gt;
The following changes were made to the models course.rb and course_team.rb&lt;br /&gt;
=== Changes in course.rb ===&lt;br /&gt;
* '''Removal of get_participant Method'''&lt;br /&gt;
        The method get_participant was removed.&lt;br /&gt;
        A global search revealed it was unused throughout the app.&lt;br /&gt;
        Consequently, the method and its respective RSpec test were removed.&lt;br /&gt;
&lt;br /&gt;
* '''Rename copy_participants Method'''&lt;br /&gt;
        Renamed the method to copy_assignment_participants.&lt;br /&gt;
        This new name accurately reflects the method's purpose, which is specific to assignments, enhancing clarity and understanding.&lt;br /&gt;
&lt;br /&gt;
* '''Error Handling Enhancement'''&lt;br /&gt;
        Refactored add_participant and copy_assignment_participants methods for improved error handling and readability.&lt;br /&gt;
        Introduced a new method, handle_errors, to centralize error handling and separate it from main function logic.&lt;br /&gt;
&lt;br /&gt;
* '''Other Changes'''&lt;br /&gt;
        Utilized find_by instead of where.first for SQL queries to the model.&lt;br /&gt;
        Employed errors.any? instead of unless errors.empty? for better readability.&lt;br /&gt;
        Added comments throughout the code for improved documentation and understanding.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Changes in course_team.rb  ===&lt;br /&gt;
&lt;br /&gt;
* '''Removal of add_member method'''&lt;br /&gt;
        The method add_member was removed.&lt;br /&gt;
        As Course_team is a subclass of Team, it inherited the add_member functionality from the superclass. Hence, it was removed for better coherence and modularity.&lt;br /&gt;
&lt;br /&gt;
* '''Removal of assignment_id method'''&lt;br /&gt;
        The method assignment_id was removed.&lt;br /&gt;
        The assignment_id method wasn't utilized anywhere in the code and therefore had to be removed to reduce redundancy.&lt;br /&gt;
&lt;br /&gt;
* '''Refactoring Course.find(id) to Course.find(course_id)'''&lt;br /&gt;
        Any instances of Course.find(course_id) were replaced with Course.find(course_id) for better understandability of the code.&lt;br /&gt;
&lt;br /&gt;
* '''Refactoring copy method to copy_to_assignment_team'''&lt;br /&gt;
        The copy method copied a Course team to an assignment team and thus refactored to copy_to_assigment_team making the code easy to understand.&lt;br /&gt;
&lt;br /&gt;
=== Other Changes ===&lt;br /&gt;
&lt;br /&gt;
* The test corresponding to get_participant Method was removed from course_spec.rb&lt;br /&gt;
* The test corresponding to copy_participants Method was renamed to copy_assignment_participants.&lt;br /&gt;
&lt;br /&gt;
== Testing ==&lt;br /&gt;
&lt;br /&gt;
To validate the refactored models, we conducted UI testing. We mapped UI buttons and functionalities to their corresponding models and executed relevant tasks to verify the expected outcomes.&lt;br /&gt;
*Adding team members to a team&lt;br /&gt;
[[File:E2408 1.png|1000px|left|]]&lt;br /&gt;
[[File:E2408 2.png|1000px|left|]]&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
* '''GitHub Repo:''' https://github.com/dakshmehta23/expertiza&lt;br /&gt;
* '''Pull Request:''' https://github.com/expertiza/expertiza/pull/2752&lt;br /&gt;
* '''VCL URL:'''&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:E2408_2.png&amp;diff=153893</id>
		<title>File:E2408 2.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:E2408_2.png&amp;diff=153893"/>
		<updated>2024-03-24T22:49:37Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153882</id>
		<title>CSC/ECE 517 Spring 2024 - E2408. Refactor course.rb and course team.rb models</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153882"/>
		<updated>2024-03-24T22:46:42Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: /* Testing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==E2408. Refactor course.rb and course_team.rb models==&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
== Team ==&lt;br /&gt;
=== Members ===&lt;br /&gt;
&lt;br /&gt;
* Daksh Mehta, (unityID:dmehta4, GitHub:dakshmehta23)&lt;br /&gt;
* Soham Patil, (unityID:sspatil6@ncsu.edu, GitHub:ThErOCk07)&lt;br /&gt;
* Unnati Bukhariya, (unityID:ubukhar2@ncsu.edu, GitHub:unnzzz)&lt;br /&gt;
&lt;br /&gt;
=== Mentor ===&lt;br /&gt;
* Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
== Expertiza Overview ==&lt;br /&gt;
&lt;br /&gt;
===Background===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source software written using Ruby on Rails which functions as a learning management software system. It has many different functions and abilities including the ability to create assignments, quizzes, assignment groups, and topics, and also a complete mechanism for providing peer reviews and feedback for other groups and other teammates. It is used in select courses at NC State and by professors at several other colleges and universities.&lt;br /&gt;
&lt;br /&gt;
course.rb and course_team.rb models are objects containing information about the course and their associated teams respectively. CourseTeams are used when an instructor wants to use the same teams for the entire semester. CourseTeam  is one subclass of Team ; AssignmentTeam is the other.  An AssignmentTeam is a team that is created for students to do a single assignment.  It is possible to copy CourseTeams to an assignment, where they become AssignmentTeams, or vice versa.&lt;br /&gt;
&lt;br /&gt;
The Course and CourseTeam models had some code smells/issues that were fixed. There were a few methods in these models that shouldn’t be in those models, and a few methods that are no longer used. Certain method names were refactored in order to better understand their functionality.&lt;br /&gt;
&lt;br /&gt;
== Requirements ==&lt;br /&gt;
&lt;br /&gt;
The following changes were made to the models course.rb and course_team.rb&lt;br /&gt;
=== Changes in course.rb ===&lt;br /&gt;
* '''Removal of get_participant Method'''&lt;br /&gt;
        The method get_participant was removed.&lt;br /&gt;
        A global search revealed it was unused throughout the app.&lt;br /&gt;
        Consequently, the method and its respective RSpec test were removed.&lt;br /&gt;
&lt;br /&gt;
* '''Rename copy_participants Method'''&lt;br /&gt;
        Renamed the method to copy_assignment_participants.&lt;br /&gt;
        This new name accurately reflects the method's purpose, which is specific to assignments, enhancing clarity and understanding.&lt;br /&gt;
&lt;br /&gt;
* '''Error Handling Enhancement'''&lt;br /&gt;
        Refactored add_participant and copy_assignment_participants methods for improved error handling and readability.&lt;br /&gt;
        Introduced a new method, handle_errors, to centralize error handling and separate it from main function logic.&lt;br /&gt;
&lt;br /&gt;
* '''Other Changes'''&lt;br /&gt;
        Utilized find_by instead of where.first for SQL queries to the model.&lt;br /&gt;
        Employed errors.any? instead of unless errors.empty? for better readability.&lt;br /&gt;
        Added comments throughout the code for improved documentation and understanding.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Changes in course_team.rb  ===&lt;br /&gt;
&lt;br /&gt;
* '''Removal of add_member method'''&lt;br /&gt;
        The method add_member was removed.&lt;br /&gt;
        As Course_team is a subclass of Team, it inherited the add_member functionality from the superclass. Hence, it was removed for better coherence and modularity.&lt;br /&gt;
&lt;br /&gt;
* '''Removal of assignment_id method'''&lt;br /&gt;
        The method assignment_id was removed.&lt;br /&gt;
        The assignment_id method wasn't utilized anywhere in the code and therefore had to be removed to reduce redundancy.&lt;br /&gt;
&lt;br /&gt;
* '''Refactoring Course.find(id) to Course.find(course_id)'''&lt;br /&gt;
        Any instances of Course.find(course_id) were replaced with Course.find(course_id) for better understandability of the code.&lt;br /&gt;
&lt;br /&gt;
* '''Refactoring copy method to copy_to_assignment_team'''&lt;br /&gt;
        The copy method copied a Course team to an assignment team and thus refactored to copy_to_assigment_team making the code easy to understand.&lt;br /&gt;
&lt;br /&gt;
=== Other Changes ===&lt;br /&gt;
&lt;br /&gt;
* The test corresponding to get_participant Method was removed from course_spec.rb&lt;br /&gt;
* The test corresponding to copy_participants Method was renamed to copy_assignment_participants.&lt;br /&gt;
&lt;br /&gt;
== Testing ==&lt;br /&gt;
&lt;br /&gt;
To validate the refactored models, we conducted UI testing. We mapped UI buttons and functionalities to their corresponding models and executed relevant tasks to verify the expected outcomes.&lt;br /&gt;
[[File:e2408_1.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
* '''GitHub Repo:''' https://github.com/dakshmehta23/expertiza&lt;br /&gt;
* '''Pull Request:''' https://github.com/expertiza/expertiza/pull/2752&lt;br /&gt;
* '''VCL URL:'''&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:E2408_1.png&amp;diff=153877</id>
		<title>File:E2408 1.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:E2408_1.png&amp;diff=153877"/>
		<updated>2024-03-24T22:45:36Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153832</id>
		<title>CSC/ECE 517 Spring 2024 - E2408. Refactor course.rb and course team.rb models</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153832"/>
		<updated>2024-03-24T22:24:08Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==E2408. Refactor course.rb and course_team.rb models==&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
== Team ==&lt;br /&gt;
=== Members ===&lt;br /&gt;
&lt;br /&gt;
* Daksh Mehta, (unityID:dmehta4, GitHub:dakshmehta23)&lt;br /&gt;
* Soham Patil, (unityID:sspatil6@ncsu.edu, GitHub:ThErOCk07)&lt;br /&gt;
* Unnati Bukhariya, (unityID:ubukhar2@ncsu.edu, GitHub:unnzzz)&lt;br /&gt;
&lt;br /&gt;
=== Mentor ===&lt;br /&gt;
* Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
== Expertiza Overview ==&lt;br /&gt;
&lt;br /&gt;
===Background===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source software written using Ruby on Rails which functions as a learning management software system. It has many different functions and abilities including the ability to create assignments, quizzes, assignment groups, and topics, and also a complete mechanism for providing peer reviews and feedback for other groups and other teammates. It is used in select courses at NC State and by professors at several other colleges and universities.&lt;br /&gt;
&lt;br /&gt;
course.rb and course_team.rb models are objects containing information about the course and their associated teams respectively. CourseTeams are used when an instructor wants to use the same teams for the entire semester. CourseTeam  is one subclass of Team ; AssignmentTeam is the other.  An AssignmentTeam is a team that is created for students to do a single assignment.  It is possible to copy CourseTeams to an assignment, where they become AssignmentTeams, or vice versa.&lt;br /&gt;
&lt;br /&gt;
The Course and CourseTeam models had some code smells/issues that were fixed. There were a few methods in these models that shouldn’t be in those models, and a few methods that are no longer used. Certain method names were refactored in order to better understand their functionality.&lt;br /&gt;
&lt;br /&gt;
== Requirements ==&lt;br /&gt;
&lt;br /&gt;
The following changes were made to the models course.rb and course_team.rb&lt;br /&gt;
=== Changes in course.rb ===&lt;br /&gt;
* '''Removal of get_participant Method'''&lt;br /&gt;
        The method get_participant was removed.&lt;br /&gt;
        A global search revealed it was unused throughout the app.&lt;br /&gt;
        Consequently, the method and its respective RSpec test were removed.&lt;br /&gt;
&lt;br /&gt;
* '''Rename copy_participants Method'''&lt;br /&gt;
        Renamed the method to copy_assignment_participants.&lt;br /&gt;
        This new name accurately reflects the method's purpose, which is specific to assignments, enhancing clarity and understanding.&lt;br /&gt;
&lt;br /&gt;
* '''Error Handling Enhancement'''&lt;br /&gt;
        Refactored add_participant and copy_assignment_participants methods for improved error handling and readability.&lt;br /&gt;
        Introduced a new method, handle_errors, to centralize error handling and separate it from main function logic.&lt;br /&gt;
&lt;br /&gt;
* '''Other Changes'''&lt;br /&gt;
        Utilized find_by instead of where.first for SQL queries to the model.&lt;br /&gt;
        Employed errors.any? instead of unless errors.empty? for better readability.&lt;br /&gt;
        Added comments throughout the code for improved documentation and understanding.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Changes in course_team.rb  ===&lt;br /&gt;
&lt;br /&gt;
* '''Removal of add_member Method'''&lt;br /&gt;
        The method add_member was removed.&lt;br /&gt;
        As Course_team is a subclass of Team, it inherited the add_member functionality from the superclass. Hence, it was removed for better coherence and modularity.&lt;br /&gt;
&lt;br /&gt;
* Delete assignment_id method in CourseTeam class since it is no longer required.&lt;br /&gt;
* Refactor Course.find(id) to Course.find(course_id) for better understandability of the code.&lt;br /&gt;
* Refactor the copy method in CourseTeam class to something that better describes its functionality.&lt;br /&gt;
&lt;br /&gt;
=== Other Changes ===&lt;br /&gt;
&lt;br /&gt;
* The test corresponding to get_participant Method was removed from course_spec.rb&lt;br /&gt;
* The test corresponding to copy_participants Method was renamed to copy_assignment_participants.&lt;br /&gt;
&lt;br /&gt;
== Testing ==&lt;br /&gt;
&lt;br /&gt;
To validate the refactored models, we conducted UI testing. We mapped UI buttons and functionalities to their corresponding models and executed relevant tasks to verify the expected outcomes.&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
* '''GitHub Repo:''' https://github.com/dakshmehta23/expertiza&lt;br /&gt;
* '''Pull Request:''' https://github.com/expertiza/expertiza/pull/2752&lt;br /&gt;
* '''VCL URL:'''&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153728</id>
		<title>CSC/ECE 517 Spring 2024 - E2408. Refactor course.rb and course team.rb models</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153728"/>
		<updated>2024-03-24T20:59:04Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==E2408. Refactor course.rb and course_team.rb models==&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
== Team ==&lt;br /&gt;
=== Members ===&lt;br /&gt;
&lt;br /&gt;
* Daksh Mehta, (unityID:dmehta4, GitHub:dakshmehta23)&lt;br /&gt;
* Soham Patil, (unityID:sspatil6@ncsu.edu, GitHub:ThErOCk07)&lt;br /&gt;
* Unnati Bukhariya, (unityID:ubukhar2@ncsu.edu, GitHub:unnzzz)&lt;br /&gt;
&lt;br /&gt;
=== Mentor ===&lt;br /&gt;
* Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
== Expertiza Overview ==&lt;br /&gt;
&lt;br /&gt;
===Background===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source software written using Ruby on Rails which functions as a learning management software system. It has many different functions and abilities including the ability to create assignments, quizzes, assignment groups, and topics, and also a complete mechanism for providing peer reviews and feedback for other groups and other teammates. It is used in select courses at NC State and by professors at several other colleges and universities.&lt;br /&gt;
&lt;br /&gt;
course.rb and course_team.rb models are objects containing information about the course and their associated teams respectively. CourseTeams are used when an instructor wants to use the same teams for the entire semester. CourseTeam  is one subclass of Team ; AssignmentTeam is the other.  An AssignmentTeam is a team that is created for students to do a single assignment.  It is possible to copy CourseTeams to an assignment, where they become AssignmentTeams, or vice versa.&lt;br /&gt;
&lt;br /&gt;
The Course and CourseTeam models had some code smells/issues that were fixed. There were a few methods in these models that shouldn’t be in those models, and a few methods that are no longer used. Certain method names were refactored in order to better understand their functionality.&lt;br /&gt;
&lt;br /&gt;
== Requirements ==&lt;br /&gt;
&lt;br /&gt;
The following changes were made to the models course.rb and course_team.rb&lt;br /&gt;
=== Changes in course.rb ===&lt;br /&gt;
* '''Removal of get_participant Method'''&lt;br /&gt;
        The method get_participant was removed.&lt;br /&gt;
        A global search revealed it was unused throughout the app.&lt;br /&gt;
        Consequently, the method and its respective RSpec test were removed.&lt;br /&gt;
&lt;br /&gt;
* '''Rename copy_participants Method'''&lt;br /&gt;
        Renamed the method to copy_assignment_participants.&lt;br /&gt;
        This new name accurately reflects the method's purpose, which is specific to assignments, enhancing clarity and understanding.&lt;br /&gt;
&lt;br /&gt;
* '''Error Handling Enhancement'''&lt;br /&gt;
        Refactored add_participant and copy_assignment_participants methods for improved error handling and readability.&lt;br /&gt;
        Introduced a new method, handle_errors, to centralize error handling and separate it from main function logic.&lt;br /&gt;
&lt;br /&gt;
* '''Other Changes'''&lt;br /&gt;
        Utilized find_by instead of where.first for SQL queries to the model.&lt;br /&gt;
        Employed errors.any? instead of unless errors.empty? for better readability.&lt;br /&gt;
        Added comments throughout the code for improved documentation and understanding.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Changes in course_team.rb  ===&lt;br /&gt;
&lt;br /&gt;
* '''Removal of add_member Method'''&lt;br /&gt;
        The method add_member was removed.&lt;br /&gt;
        As Course_team is a subclass of Team, it inherited the add_member functionality from the superclass. Hence, it was removed for better coherence and modularity.&lt;br /&gt;
&lt;br /&gt;
* Delete assignment_id method in CourseTeam class since it is no longer required.&lt;br /&gt;
* Refactor Course.find(id) to Course.find(course_id) for better understandability of the code.&lt;br /&gt;
* Refactor the copy method in CourseTeam class to something that better describes its functionality.&lt;br /&gt;
&lt;br /&gt;
=== Other Changes ===&lt;br /&gt;
&lt;br /&gt;
* The test corresponding to get_participant Method was removed from course_spec.rb&lt;br /&gt;
* The test corresponding to copy_participants Method was renamed to copy_assignment_participants.&lt;br /&gt;
&lt;br /&gt;
== Testing ==&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
* '''GitHub Repo:''' https://github.com/dakshmehta23/expertiza&lt;br /&gt;
* '''Pull Request:''' https://github.com/expertiza/expertiza/pull/2752&lt;br /&gt;
* '''VCL URL:'''&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153727</id>
		<title>CSC/ECE 517 Spring 2024 - E2408. Refactor course.rb and course team.rb models</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153727"/>
		<updated>2024-03-24T20:56:00Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==E2408. Refactor course.rb and course_team.rb models==&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
== Team ==&lt;br /&gt;
=== Members ===&lt;br /&gt;
&lt;br /&gt;
* Daksh Mehta, (unityID:dmehta4, GitHub:dakshmehta23)&lt;br /&gt;
* Soham Patil, (unityID:sspatil6@ncsu.edu, GitHub:ThErOCk07)&lt;br /&gt;
* Unnati Bukhariya, (unityID:ubukhar2@ncsu.edu, GitHub:unnzzz)&lt;br /&gt;
&lt;br /&gt;
=== Mentor ===&lt;br /&gt;
* Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
== Expertiza Overview ==&lt;br /&gt;
&lt;br /&gt;
===Background===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source software written using Ruby on Rails which functions as a learning management software system. It has many different functions and abilities including the ability to create assignments, quizzes, assignment groups, and topics, and also a complete mechanism for providing peer reviews and feedback for other groups and other teammates. It is used in select courses at NC State and by professors at several other colleges and universities.&lt;br /&gt;
&lt;br /&gt;
course.rb and course_team.rb models are objects containing information about the course and their associated teams respectively. CourseTeams are used when an instructor wants to use the same teams for the entire semester. CourseTeam  is one subclass of Team ; AssignmentTeam is the other.  An AssignmentTeam is a team that is created for students to do a single assignment.  It is possible to copy CourseTeams to an assignment, where they become AssignmentTeams, or vice versa.&lt;br /&gt;
&lt;br /&gt;
The Course and CourseTeam models had some code smells/issues that were fixed. There were a few methods in these models that shouldn’t be in those models, and a few methods that are no longer used. Certain method names were refactored in order to better understand their functionality.&lt;br /&gt;
&lt;br /&gt;
== Requirements ==&lt;br /&gt;
&lt;br /&gt;
The following changes were made to the models course.rb and course_team.rb&lt;br /&gt;
=== Changes in course.rb ===&lt;br /&gt;
* '''Removal of get_participant Method'''&lt;br /&gt;
        The method get_participant was removed.&lt;br /&gt;
        A global search revealed it was unused throughout the app.&lt;br /&gt;
        Consequently, the method and its respective RSpec test were removed.&lt;br /&gt;
&lt;br /&gt;
* '''Rename copy_participants Method'''&lt;br /&gt;
        Renamed the method to copy_assignment_participants.&lt;br /&gt;
        This new name accurately reflects the method's purpose, which is specific to assignments, enhancing clarity and understanding.&lt;br /&gt;
&lt;br /&gt;
* '''Error Handling Enhancement'''&lt;br /&gt;
        Refactored add_participant and copy_assignment_participants methods for improved error handling and readability.&lt;br /&gt;
        Introduced a new method, handle_errors, to centralize error handling and separate it from main function logic.&lt;br /&gt;
&lt;br /&gt;
* '''Other Changes'''&lt;br /&gt;
        Utilized find_by instead of where.first for SQL queries to the model.&lt;br /&gt;
        Employed errors.any? instead of unless errors.empty? for better readability.&lt;br /&gt;
        Added comments throughout the code for improved documentation and understanding.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Changes in course_team.rb  ===&lt;br /&gt;
&lt;br /&gt;
* '''Removal of add_member Method'''&lt;br /&gt;
        The method add_member was removed.&lt;br /&gt;
        As Course_team is a subclass of Team, it inherited the add_member functionality from the superclass. Hence, it was removed for better coherence and modularity.&lt;br /&gt;
&lt;br /&gt;
* Delete assignment_id method in CourseTeam class since it is no longer required.&lt;br /&gt;
* Refactor Course.find(id) to Course.find(course_id) for better understandability of the code.&lt;br /&gt;
* Refactor the copy method in CourseTeam class to something that better describes its functionality.&lt;br /&gt;
&lt;br /&gt;
=== Other Changes ===&lt;br /&gt;
&lt;br /&gt;
* The test corresponding to get_participant Method was removed from course_spec.rb&lt;br /&gt;
* The test corresponding to copy_participants Method was renamed to copy_assignment_participants.&lt;br /&gt;
&lt;br /&gt;
== Testing ==&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153715</id>
		<title>CSC/ECE 517 Spring 2024 - E2408. Refactor course.rb and course team.rb models</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153715"/>
		<updated>2024-03-24T20:43:15Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==E2408. Refactor course.rb and course_team.rb models==&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
== Team ==&lt;br /&gt;
=== Members ===&lt;br /&gt;
&lt;br /&gt;
* Daksh Mehta, (unityID:dmehta4, GitHub:dakshmehta23)&lt;br /&gt;
* Soham Patil, (unityID:sspatil6@ncsu.edu, GitHub:ThErOCk07)&lt;br /&gt;
* Unnati Bukhariya, (unityID:ubukhar2@ncsu.edu, GitHub:unnzzz)&lt;br /&gt;
&lt;br /&gt;
=== Mentor ===&lt;br /&gt;
* Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
== Expertiza Overview ==&lt;br /&gt;
&lt;br /&gt;
===Background===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source software written using Ruby on Rails which functions as a learning management software system. It has many different functions and abilities including the ability to create assignments, quizzes, assignment groups, and topics, and also a complete mechanism for providing peer reviews and feedback for other groups and other teammates. It is used in select courses at NC State and by professors at several other colleges and universities.&lt;br /&gt;
&lt;br /&gt;
course.rb and course_team.rb models are objects containing information about the course and their associated teams respectively. CourseTeams are used when an instructor wants to use the same teams for the entire semester. CourseTeam  is one subclass of Team ; AssignmentTeam is the other.  An AssignmentTeam is a team that is created for students to do a single assignment.  It is possible to copy CourseTeams to an assignment, where they become AssignmentTeams, or vice versa.&lt;br /&gt;
&lt;br /&gt;
The Course and CourseTeam models had some code smells/issues that were fixed. There were a few methods in these models that shouldn’t be in those models, and a few methods that are no longer used. Certain method names were refactored in order to better understand their functionality.&lt;br /&gt;
&lt;br /&gt;
== Requirements ==&lt;br /&gt;
&lt;br /&gt;
The following changes were made to the models course.rb and course_team.rb&lt;br /&gt;
=== course.rb ===&lt;br /&gt;
* The method get_participant was removed.&lt;br /&gt;
We performed a global search to see where all this method is being used. It was found that the function was not used anywhere else in the app and hence it was removed along with its respective rspec test.&lt;br /&gt;
* The method add_member was removed.&lt;br /&gt;
We found that add_member was present in the team class. Since Course_team is a subclass of Team it makes sense to leave the functionality in Team class itself to make the code more coherent and modular.&lt;br /&gt;
* Rename copy_participants.&lt;br /&gt;
After reading the function definition it made sense to rename the method to copy_assignment_participants since the method is specific to assignments. The new function name gives a better idea and clarity about what the function does.&lt;br /&gt;
* Improve error handling. &lt;br /&gt;
The methods add_participant and copy_assignment_participants were refactored to improve the error handling and code readability. We created a new method called &amp;quot;handle_errors&amp;quot; to raise any errors that the methods may encounter. This helped us to separate the error handling from the main function logic and made the code easier to understand.&lt;br /&gt;
* Others&lt;br /&gt;
Some other small changes were made such as using find_by instead of where.first to make SQL queries to the model, using &amp;quot;errors.any?&amp;quot; instead of unless &amp;quot;errors.empty?&amp;quot;  and adding comments to the code.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== course_team.rb  ===&lt;br /&gt;
* Delete assignment_id method in CourseTeam class since it is no longer required.&lt;br /&gt;
* Refactor Course.find(id) to Course.find(course_id) for better understandability of the code.&lt;br /&gt;
* Refactor the copy method in CourseTeam class to something that better describes its functionality.&lt;br /&gt;
&lt;br /&gt;
=== Other Changes ===&lt;br /&gt;
&lt;br /&gt;
Fixed tests to incorporate the new changes in the code.&lt;br /&gt;
&lt;br /&gt;
== Implementation ==&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153639</id>
		<title>CSC/ECE 517 Spring 2024 - E2408. Refactor course.rb and course team.rb models</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2024_-_E2408._Refactor_course.rb_and_course_team.rb_models&amp;diff=153639"/>
		<updated>2024-03-24T20:12:08Z</updated>

		<summary type="html">&lt;p&gt;Dmehta4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==E2408. Refactor course.rb and course_team.rb models==&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
== Team ==&lt;br /&gt;
=== Members ===&lt;br /&gt;
&lt;br /&gt;
* Daksh Mehta, (unityID:dmehta4, GitHub:dakshmehta23)&lt;br /&gt;
* Soham Patil, (unityID:sspatil6@ncsu.edu, GitHub:ThErOCk07)&lt;br /&gt;
* Unnati Bukhariya, (unityID:ubukhar2@ncsu.edu, GitHub:unnzzz)&lt;br /&gt;
&lt;br /&gt;
=== Mentor ===&lt;br /&gt;
* Ameya Vaichalkar, (unityID:agvaicha, GitHub:ameyagv)&lt;br /&gt;
== Expertiza Overview ==&lt;br /&gt;
&lt;br /&gt;
===Background===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source software written using Ruby on Rails which functions as a learning management software system. It has many different functions and abilities including the ability to create assignments, quizzes, assignment groups, and topics, and also a complete mechanism for providing peer reviews and feedback for other groups and other teammates. It is used in select courses at NC State and by professors at several other colleges and universities.&lt;br /&gt;
&lt;br /&gt;
course.rb and course_team.rb models are objects containing information about the course and their associated teams respectively. CourseTeams are used when an instructor wants to use the same teams for the entire semester. CourseTeam  is one subclass of Team ; AssignmentTeam is the other.  An AssignmentTeam is a team that is created for students to do a single assignment.  It is possible to copy CourseTeams to an assignment, where they become AssignmentTeams, or vice versa.&lt;br /&gt;
&lt;br /&gt;
The Course and CourseTeam models had some code smells/issues that were fixed. There were a few methods in these models that shouldn’t be in those models, and a few methods that are no longer used. Certain method names were refactored in order to better understand their functionality.&lt;br /&gt;
&lt;br /&gt;
== Requirements ==&lt;br /&gt;
&lt;br /&gt;
The following changes were made to the models course.rb and course_team.rb&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== course.rb ===&lt;br /&gt;
&lt;br /&gt;
=== course_team.rb  ===&lt;br /&gt;
* Delete assignment_id method in CourseTeam class since it is no longer required.&lt;br /&gt;
* Refactor Course.find(id) to Course.find(course_id) for better understandability of the code.&lt;br /&gt;
* Refactor the copy method in CourseTeam class to something that better describes its functionality.&lt;br /&gt;
&lt;br /&gt;
=== Other Changes ===&lt;br /&gt;
&lt;br /&gt;
Fixed tests to incorporate the new changes in the code.&lt;br /&gt;
&lt;br /&gt;
== Implementation ==&lt;/div&gt;</summary>
		<author><name>Dmehta4</name></author>
	</entry>
</feed>