<?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=Dpatel14</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=Dpatel14"/>
	<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Special:Contributions/Dpatel14"/>
	<updated>2026-06-06T10:31:40Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.41.0</generator>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113675</id>
		<title>CSC/ECE 517 Fall 2017/E17AA Nomination for Badges</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113675"/>
		<updated>2017-11-18T20:13:04Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: /* Snapshots */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Problem Statement==&lt;br /&gt;
&lt;br /&gt;
The purpose of the project is to implement a way to allow students to nominate badges to other students while reviewing their work. The professor should also be able to see the nominations to each student in a single page. &lt;br /&gt;
&lt;br /&gt;
==Pre-Conditions==&lt;br /&gt;
&lt;br /&gt;
These are the pre-conditions that needs to hold true for each functionality to work&lt;br /&gt;
&lt;br /&gt;
:· The maximum number of students that can be assigned to the project cannot be more than 1. &lt;br /&gt;
:· For students to nominate badges, the professor must have provided a list of pre-decided badges possible for that project. &lt;br /&gt;
:· Students can nominate for badges without providing a justification only if the instructor has not kept the justification field mandatory.&lt;br /&gt;
&lt;br /&gt;
==Implementation Steps==&lt;br /&gt;
&lt;br /&gt;
:· Provide professors an option to add all possible badges to a project.&lt;br /&gt;
:· Also provide the professor an option to make the justification field mandatory or not.&lt;br /&gt;
:· Allow students to nominate badges while peer reviewing.&lt;br /&gt;
:· Show a summary of all nominated badges to professor in a single page.&lt;br /&gt;
&lt;br /&gt;
==Modifications To Be Done==&lt;br /&gt;
&lt;br /&gt;
*Files to be Modified&lt;br /&gt;
:· Add the code to include the selection of relevant badges and the justification text box Assignment_badges_controller.rb.&lt;br /&gt;
:· Add the badges model to assignment_questionnaire.rb.&lt;br /&gt;
:· Add the code to display the nomination summary on the page student_task/list page&lt;br /&gt;
&lt;br /&gt;
*Tables to be Modified&lt;br /&gt;
:· We’ll be creating a table named “badges”, with the following attributes: &lt;br /&gt;
   id: primary key&lt;br /&gt;
   name: varchar&lt;br /&gt;
   description: varchar&lt;br /&gt;
&lt;br /&gt;
:· We’ll be creating a table named “assignment_questionnaires_badges”, with the following attributes: &lt;br /&gt;
   Id: Primary key&lt;br /&gt;
   assignment_id: foreign key&lt;br /&gt;
   questionnaire_id: foreign key&lt;br /&gt;
   badge_id: foreign key&lt;br /&gt;
&lt;br /&gt;
==Execution Flow==&lt;br /&gt;
  [[File:Oodd5.PNG]]&lt;br /&gt;
&lt;br /&gt;
Once the instructor logs in, they can either select badges for existing assignments or go to a view which displays all the nominations.&lt;br /&gt;
&lt;br /&gt;
Once the instructor selects the badges for the existing assignments, the students can login and provide nominations for badges during peer review.&lt;br /&gt;
&lt;br /&gt;
==Design==&lt;br /&gt;
  [[File:Oodd2.PNG]]&lt;br /&gt;
&lt;br /&gt;
An instructor can add a badge to the badges table which will be also added to an assignment table as a probable nomination badge. The instructor can also view all the nominations done by the students during the peer review of an assignment.&lt;br /&gt;
&lt;br /&gt;
The students on the other hand, while doing the peer review, can provide nominations for badges provided by the instructor for a particular assignment.&lt;br /&gt;
&lt;br /&gt;
==Snapshots==&lt;br /&gt;
&lt;br /&gt;
Note: Currently the images contain dummy data because the data will be available from the project [http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E17A2_Lightweight_Badging_System E17A2]&lt;br /&gt;
&lt;br /&gt;
Below are the changes which are planned:&lt;br /&gt;
&lt;br /&gt;
:·Added a new icon to the assignments which will redirect to a summary of the nominations for the assignment&lt;br /&gt;
  [[File:Summary_Icon.PNG]]&lt;br /&gt;
:·The new view for the instructor where the instructor can see the list of nominations for the assignment (This will be in the path /assignments/:id/nominations)&lt;br /&gt;
  [[File:New_View_For_Instructor.PNG]]&lt;br /&gt;
:·The instructor can decide whether to keep the justification mandatory or not. This will be added under the review strategy tab.&lt;br /&gt;
  [[File:Instructor_Review_Strategy.jpg]]&lt;br /&gt;
:·The instructor can decide which badges to be allowed for nomination for the assignment from the list of all the available badges. Multiple selection is possible. This has been added as a new tab called &amp;quot;Available Badges for Nominations&amp;quot;&lt;br /&gt;
  [[File:Nominations_Tab.PNG]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  [[File:Bades_List.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
We will be creating test cases in the files &lt;br /&gt;
:·peer review.rb :Check with peer reviewer will be able to nominate badges&lt;br /&gt;
:·review_assignment_spec.rb:Check whether user is able to review assignment with Team Size=1&lt;br /&gt;
:·team_creation_spec.rb:Check the Team Size&lt;br /&gt;
:·review_mapping_spec.rb:Check whether reviewer is correctly mapped to the enrolled course&lt;br /&gt;
:·Write feature tests to verify the modifications:Include tests in the a new badge_system_spec.rb file in the spec/features directory&lt;br /&gt;
&lt;br /&gt;
*UI design Testing:&lt;br /&gt;
:·Check if peer reviewer is able to nominate for badges with drop down list and contains text boxes for justification.&lt;br /&gt;
:·Check if instructor is able to view the summary of all nominations.&lt;br /&gt;
:·Cosmetic Inconsistencies – The screen look, feel and design should match the other screens in your application.&lt;br /&gt;
&lt;br /&gt;
==Reference Links==&lt;br /&gt;
*[https://github.com/expertiza/expertiza/tree/master/app/views Expertiza Github Master Branch]&lt;br /&gt;
*[http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2015_E1575_Share_the_data_in_Expertiza_to_a_remote_server_via_PRML_format Expertiza Database Schema]&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113674</id>
		<title>CSC/ECE 517 Fall 2017/E17AA Nomination for Badges</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113674"/>
		<updated>2017-11-18T20:10:44Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: /* Snapshots */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Problem Statement==&lt;br /&gt;
&lt;br /&gt;
The purpose of the project is to implement a way to allow students to nominate badges to other students while reviewing their work. The professor should also be able to see the nominations to each student in a single page. &lt;br /&gt;
&lt;br /&gt;
==Pre-Conditions==&lt;br /&gt;
&lt;br /&gt;
These are the pre-conditions that needs to hold true for each functionality to work&lt;br /&gt;
&lt;br /&gt;
:· The maximum number of students that can be assigned to the project cannot be more than 1. &lt;br /&gt;
:· For students to nominate badges, the professor must have provided a list of pre-decided badges possible for that project. &lt;br /&gt;
:· Students can nominate for badges without providing a justification only if the instructor has not kept the justification field mandatory.&lt;br /&gt;
&lt;br /&gt;
==Implementation Steps==&lt;br /&gt;
&lt;br /&gt;
:· Provide professors an option to add all possible badges to a project.&lt;br /&gt;
:· Also provide the professor an option to make the justification field mandatory or not.&lt;br /&gt;
:· Allow students to nominate badges while peer reviewing.&lt;br /&gt;
:· Show a summary of all nominated badges to professor in a single page.&lt;br /&gt;
&lt;br /&gt;
==Modifications To Be Done==&lt;br /&gt;
&lt;br /&gt;
*Files to be Modified&lt;br /&gt;
:· Add the code to include the selection of relevant badges and the justification text box Assignment_badges_controller.rb.&lt;br /&gt;
:· Add the badges model to assignment_questionnaire.rb.&lt;br /&gt;
:· Add the code to display the nomination summary on the page student_task/list page&lt;br /&gt;
&lt;br /&gt;
*Tables to be Modified&lt;br /&gt;
:· We’ll be creating a table named “badges”, with the following attributes: &lt;br /&gt;
   id: primary key&lt;br /&gt;
   name: varchar&lt;br /&gt;
   description: varchar&lt;br /&gt;
&lt;br /&gt;
:· We’ll be creating a table named “assignment_questionnaires_badges”, with the following attributes: &lt;br /&gt;
   Id: Primary key&lt;br /&gt;
   assignment_id: foreign key&lt;br /&gt;
   questionnaire_id: foreign key&lt;br /&gt;
   badge_id: foreign key&lt;br /&gt;
&lt;br /&gt;
==Execution Flow==&lt;br /&gt;
  [[File:Oodd5.PNG]]&lt;br /&gt;
&lt;br /&gt;
Once the instructor logs in, they can either select badges for existing assignments or go to a view which displays all the nominations.&lt;br /&gt;
&lt;br /&gt;
Once the instructor selects the badges for the existing assignments, the students can login and provide nominations for badges during peer review.&lt;br /&gt;
&lt;br /&gt;
==Design==&lt;br /&gt;
  [[File:Oodd2.PNG]]&lt;br /&gt;
&lt;br /&gt;
An instructor can add a badge to the badges table which will be also added to an assignment table as a probable nomination badge. The instructor can also view all the nominations done by the students during the peer review of an assignment.&lt;br /&gt;
&lt;br /&gt;
The students on the other hand, while doing the peer review, can provide nominations for badges provided by the instructor for a particular assignment.&lt;br /&gt;
&lt;br /&gt;
==Snapshots==&lt;br /&gt;
&lt;br /&gt;
Note: Currently the images contain dummy data because the data will be available from the project http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2017/E17A2_Lightweight_Badging_System&lt;br /&gt;
Below are the changes which are planned:&lt;br /&gt;
&lt;br /&gt;
:·Added a new icon to the assignments which will redirect to a summary of the nominations for the assignment&lt;br /&gt;
  [[File:Summary_Icon.PNG]]&lt;br /&gt;
:·The new view for the instructor where the instructor can see the list of nominations for the assignment (This will be in the path /assignments/:id/nominations)&lt;br /&gt;
  [[File:New_View_For_Instructor.PNG]]&lt;br /&gt;
:·The instructor can decide whether to keep the justification mandatory or not. This will be added under the review strategy tab.&lt;br /&gt;
  [[File:Instructor_Review_Strategy.jpg]]&lt;br /&gt;
:·The instructor can decide which badges to be allowed for nomination for the assignment from the list of all the available badges. Multiple selection is possible. This has been added as a new tab called &amp;quot;Available Badges for Nominations&amp;quot;&lt;br /&gt;
  [[File:Nominations_Tab.PNG]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  [[File:Bades_List.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
We will be creating test cases in the files &lt;br /&gt;
:·peer review.rb :Check with peer reviewer will be able to nominate badges&lt;br /&gt;
:·review_assignment_spec.rb:Check whether user is able to review assignment with Team Size=1&lt;br /&gt;
:·team_creation_spec.rb:Check the Team Size&lt;br /&gt;
:·review_mapping_spec.rb:Check whether reviewer is correctly mapped to the enrolled course&lt;br /&gt;
:·Write feature tests to verify the modifications:Include tests in the a new badge_system_spec.rb file in the spec/features directory&lt;br /&gt;
&lt;br /&gt;
*UI design Testing:&lt;br /&gt;
:·Check if peer reviewer is able to nominate for badges with drop down list and contains text boxes for justification.&lt;br /&gt;
:·Check if instructor is able to view the summary of all nominations.&lt;br /&gt;
:·Cosmetic Inconsistencies – The screen look, feel and design should match the other screens in your application.&lt;br /&gt;
&lt;br /&gt;
==Reference Links==&lt;br /&gt;
*[https://github.com/expertiza/expertiza/tree/master/app/views Expertiza Github Master Branch]&lt;br /&gt;
*[http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2015_E1575_Share_the_data_in_Expertiza_to_a_remote_server_via_PRML_format Expertiza Database Schema]&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113673</id>
		<title>CSC/ECE 517 Fall 2017/E17AA Nomination for Badges</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113673"/>
		<updated>2017-11-18T20:08:54Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Problem Statement==&lt;br /&gt;
&lt;br /&gt;
The purpose of the project is to implement a way to allow students to nominate badges to other students while reviewing their work. The professor should also be able to see the nominations to each student in a single page. &lt;br /&gt;
&lt;br /&gt;
==Pre-Conditions==&lt;br /&gt;
&lt;br /&gt;
These are the pre-conditions that needs to hold true for each functionality to work&lt;br /&gt;
&lt;br /&gt;
:· The maximum number of students that can be assigned to the project cannot be more than 1. &lt;br /&gt;
:· For students to nominate badges, the professor must have provided a list of pre-decided badges possible for that project. &lt;br /&gt;
:· Students can nominate for badges without providing a justification only if the instructor has not kept the justification field mandatory.&lt;br /&gt;
&lt;br /&gt;
==Implementation Steps==&lt;br /&gt;
&lt;br /&gt;
:· Provide professors an option to add all possible badges to a project.&lt;br /&gt;
:· Also provide the professor an option to make the justification field mandatory or not.&lt;br /&gt;
:· Allow students to nominate badges while peer reviewing.&lt;br /&gt;
:· Show a summary of all nominated badges to professor in a single page.&lt;br /&gt;
&lt;br /&gt;
==Modifications To Be Done==&lt;br /&gt;
&lt;br /&gt;
*Files to be Modified&lt;br /&gt;
:· Add the code to include the selection of relevant badges and the justification text box Assignment_badges_controller.rb.&lt;br /&gt;
:· Add the badges model to assignment_questionnaire.rb.&lt;br /&gt;
:· Add the code to display the nomination summary on the page student_task/list page&lt;br /&gt;
&lt;br /&gt;
*Tables to be Modified&lt;br /&gt;
:· We’ll be creating a table named “badges”, with the following attributes: &lt;br /&gt;
   id: primary key&lt;br /&gt;
   name: varchar&lt;br /&gt;
   description: varchar&lt;br /&gt;
&lt;br /&gt;
:· We’ll be creating a table named “assignment_questionnaires_badges”, with the following attributes: &lt;br /&gt;
   Id: Primary key&lt;br /&gt;
   assignment_id: foreign key&lt;br /&gt;
   questionnaire_id: foreign key&lt;br /&gt;
   badge_id: foreign key&lt;br /&gt;
&lt;br /&gt;
==Execution Flow==&lt;br /&gt;
  [[File:Oodd5.PNG]]&lt;br /&gt;
&lt;br /&gt;
Once the instructor logs in, they can either select badges for existing assignments or go to a view which displays all the nominations.&lt;br /&gt;
&lt;br /&gt;
Once the instructor selects the badges for the existing assignments, the students can login and provide nominations for badges during peer review.&lt;br /&gt;
&lt;br /&gt;
==Design==&lt;br /&gt;
  [[File:Oodd2.PNG]]&lt;br /&gt;
&lt;br /&gt;
An instructor can add a badge to the badges table which will be also added to an assignment table as a probable nomination badge. The instructor can also view all the nominations done by the students during the peer review of an assignment.&lt;br /&gt;
&lt;br /&gt;
The students on the other hand, while doing the peer review, can provide nominations for badges provided by the instructor for a particular assignment.&lt;br /&gt;
&lt;br /&gt;
==Snapshots==&lt;br /&gt;
Below are the changes which are planned:&lt;br /&gt;
&lt;br /&gt;
:·Added a new icon to the assignments which will redirect to a summary of the nominations for the assignment&lt;br /&gt;
  [[File:Summary_Icon.PNG]]&lt;br /&gt;
:·The new view for the instructor where the instructor can see the list of nominations for the assignment (This will be in the path /assignments/:id/nominations)&lt;br /&gt;
  [[File:New_View_For_Instructor.PNG]]&lt;br /&gt;
:·The instructor can decide whether to keep the justification mandatory or not. This will be added under the review strategy tab.&lt;br /&gt;
  [[File:Instructor_Review_Strategy.jpg]]&lt;br /&gt;
:·The instructor can decide which badges to be allowed for nomination for the assignment from the list of all the available badges. Multiple selection is possible. This has been added as a new tab called &amp;quot;Available Badges for Nominations&amp;quot;&lt;br /&gt;
  [[File:Nominations_Tab.PNG]]&lt;br /&gt;
  [[File:Bades_List.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
We will be creating test cases in the files &lt;br /&gt;
:·peer review.rb :Check with peer reviewer will be able to nominate badges&lt;br /&gt;
:·review_assignment_spec.rb:Check whether user is able to review assignment with Team Size=1&lt;br /&gt;
:·team_creation_spec.rb:Check the Team Size&lt;br /&gt;
:·review_mapping_spec.rb:Check whether reviewer is correctly mapped to the enrolled course&lt;br /&gt;
:·Write feature tests to verify the modifications:Include tests in the a new badge_system_spec.rb file in the spec/features directory&lt;br /&gt;
&lt;br /&gt;
*UI design Testing:&lt;br /&gt;
:·Check if peer reviewer is able to nominate for badges with drop down list and contains text boxes for justification.&lt;br /&gt;
:·Check if instructor is able to view the summary of all nominations.&lt;br /&gt;
:·Cosmetic Inconsistencies – The screen look, feel and design should match the other screens in your application.&lt;br /&gt;
&lt;br /&gt;
==Reference Links==&lt;br /&gt;
*[https://github.com/expertiza/expertiza/tree/master/app/views Expertiza Github Master Branch]&lt;br /&gt;
*[http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2015_E1575_Share_the_data_in_Expertiza_to_a_remote_server_via_PRML_format Expertiza Database Schema]&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Bades_List.PNG&amp;diff=113672</id>
		<title>File:Bades List.PNG</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Bades_List.PNG&amp;diff=113672"/>
		<updated>2017-11-18T20:08:32Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Nominations_Tab.PNG&amp;diff=113671</id>
		<title>File:Nominations Tab.PNG</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Nominations_Tab.PNG&amp;diff=113671"/>
		<updated>2017-11-18T20:07:14Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Instructor_Review_Strategy.jpg&amp;diff=113670</id>
		<title>File:Instructor Review Strategy.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Instructor_Review_Strategy.jpg&amp;diff=113670"/>
		<updated>2017-11-18T20:04:18Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:New_View_For_Instructor.PNG&amp;diff=113669</id>
		<title>File:New View For Instructor.PNG</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:New_View_For_Instructor.PNG&amp;diff=113669"/>
		<updated>2017-11-18T19:59:35Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Summary_Icon.PNG&amp;diff=113668</id>
		<title>File:Summary Icon.PNG</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Summary_Icon.PNG&amp;diff=113668"/>
		<updated>2017-11-18T19:55:25Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113658</id>
		<title>CSC/ECE 517 Fall 2017/E17AA Nomination for Badges</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113658"/>
		<updated>2017-11-17T01:57:06Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: /* Implementation Steps */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Problem Statement==&lt;br /&gt;
&lt;br /&gt;
The purpose of the project is to implement a way to allow students to nominate badges to other students while reviewing their work. The professor should also be able to see the nominations to each student in a single page. &lt;br /&gt;
&lt;br /&gt;
==Pre-Conditions==&lt;br /&gt;
&lt;br /&gt;
These are the pre-conditions that needs to hold true for each functionality to work&lt;br /&gt;
&lt;br /&gt;
:· The maximum number of students that can be assigned to the project cannot be more than 1. &lt;br /&gt;
:· For students to nominate badges, the professor must have provided a list of pre-decided badges possible for that project. &lt;br /&gt;
:· Students can nominate for badges without providing a justification only if the instructor has not kept the justification field mandatory.&lt;br /&gt;
&lt;br /&gt;
==Implementation Steps==&lt;br /&gt;
&lt;br /&gt;
:· Provide professors an option to add all possible badges to a project.&lt;br /&gt;
:· Also provide the professor an option to make the justification field mandatory or not.&lt;br /&gt;
:· Allow students to nominate badges while peer reviewing.&lt;br /&gt;
:· Show a summary of all nominated badges to professor in a single page.&lt;br /&gt;
&lt;br /&gt;
==Modifications To Be Done==&lt;br /&gt;
&lt;br /&gt;
*Files to be Modified&lt;br /&gt;
:· Add the code to include the selection of relevant badges and the justification text box Assignment_questionnaire_controller.rb.&lt;br /&gt;
:· Add the badges model to assignment_questionnaire.rb.&lt;br /&gt;
:· Add the code to display the nomination summary on the page student_task/list page&lt;br /&gt;
&lt;br /&gt;
*Tables to be Modified&lt;br /&gt;
:· We’ll be creating a table named “badges”, with the following attributes: &lt;br /&gt;
   id: primary key&lt;br /&gt;
   name: varchar&lt;br /&gt;
   description: varchar&lt;br /&gt;
&lt;br /&gt;
:· We’ll be creating a table named “assignment_questionnaires_badges”, with the following attributes: &lt;br /&gt;
   Id: Primary key&lt;br /&gt;
   assignment_id: foreign key&lt;br /&gt;
   questionnaire_id: foreign key&lt;br /&gt;
   badge_id: foreign key&lt;br /&gt;
&lt;br /&gt;
==Execution Flow==&lt;br /&gt;
  [[File:Oodd5.PNG]]&lt;br /&gt;
&lt;br /&gt;
Once the instructor logs in, they can either select badges for existing assignments or go to a view which displays all the nominations.&lt;br /&gt;
&lt;br /&gt;
Once the instructor selects the badges for the existing assignments, the students can login and provide nominations for badges during peer review.&lt;br /&gt;
&lt;br /&gt;
==Design==&lt;br /&gt;
  [[File:Oodd2.PNG]]&lt;br /&gt;
&lt;br /&gt;
An instructor can add a badge to the badges table which will be also added to an assignment table as a probable nomination badge. The instructor can also view all the nominations done by the students during the peer review of an assignment.&lt;br /&gt;
&lt;br /&gt;
The students on the other hand, while doing the peer review, can provide nominations for badges provided by the instructor for a particular assignment.&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
We will be creating test cases in the files &lt;br /&gt;
:·peer review.rb :Check with peer reviewer will be able to nominate badges&lt;br /&gt;
:·review_assignment_spec.rb:Check whether user is able to review assignment with Team Size=1&lt;br /&gt;
:·team_creation_spec.rb:Check the Team Size&lt;br /&gt;
:·review_mapping_spec.rb:Check whether reviewer is correctly mapped to the enrolled course&lt;br /&gt;
:·Write feature tests to verify the modifications:Include tests in the a new badge_system_spec.rb file in the spec/features directory&lt;br /&gt;
&lt;br /&gt;
*UI design Testing:&lt;br /&gt;
:·Check if peer reviewer is able to nominate for badges with drop down list and contains text boxes for justification.&lt;br /&gt;
:·Check if instructor is able to view the summary of all nominations.&lt;br /&gt;
:·Cosmetic Inconsistencies – The screen look, feel and design should match the other screens in your application.&lt;br /&gt;
&lt;br /&gt;
==Reference Links==&lt;br /&gt;
*[https://github.com/expertiza/expertiza/tree/master/app/views Expertiza Github Master Branch]&lt;br /&gt;
*[http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2015_E1575_Share_the_data_in_Expertiza_to_a_remote_server_via_PRML_format Expertiza Database Schema]&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113657</id>
		<title>CSC/ECE 517 Fall 2017/E17AA Nomination for Badges</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113657"/>
		<updated>2017-11-17T01:56:02Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: /* Pre-Conditions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Problem Statement==&lt;br /&gt;
&lt;br /&gt;
The purpose of the project is to implement a way to allow students to nominate badges to other students while reviewing their work. The professor should also be able to see the nominations to each student in a single page. &lt;br /&gt;
&lt;br /&gt;
==Pre-Conditions==&lt;br /&gt;
&lt;br /&gt;
These are the pre-conditions that needs to hold true for each functionality to work&lt;br /&gt;
&lt;br /&gt;
:· The maximum number of students that can be assigned to the project cannot be more than 1. &lt;br /&gt;
:· For students to nominate badges, the professor must have provided a list of pre-decided badges possible for that project. &lt;br /&gt;
:· Students can nominate for badges without providing a justification only if the instructor has not kept the justification field mandatory.&lt;br /&gt;
&lt;br /&gt;
==Implementation Steps==&lt;br /&gt;
&lt;br /&gt;
:· Provide professors an option to add all possible badges to a project. &lt;br /&gt;
:· Allow students to nominate badges while peer reviewing.&lt;br /&gt;
:· Show a summary of all nominated badges to professor in a single page.&lt;br /&gt;
&lt;br /&gt;
==Modifications To Be Done==&lt;br /&gt;
&lt;br /&gt;
*Files to be Modified&lt;br /&gt;
:· Add the code to include the selection of relevant badges and the justification text box Assignment_questionnaire_controller.rb.&lt;br /&gt;
:· Add the badges model to assignment_questionnaire.rb.&lt;br /&gt;
:· Add the code to display the nomination summary on the page student_task/list page&lt;br /&gt;
&lt;br /&gt;
*Tables to be Modified&lt;br /&gt;
:· We’ll be creating a table named “badges”, with the following attributes: &lt;br /&gt;
   id: primary key&lt;br /&gt;
   name: varchar&lt;br /&gt;
   description: varchar&lt;br /&gt;
&lt;br /&gt;
:· We’ll be creating a table named “assignment_questionnaires_badges”, with the following attributes: &lt;br /&gt;
   Id: Primary key&lt;br /&gt;
   assignment_id: foreign key&lt;br /&gt;
   questionnaire_id: foreign key&lt;br /&gt;
   badge_id: foreign key&lt;br /&gt;
&lt;br /&gt;
==Execution Flow==&lt;br /&gt;
  [[File:Oodd5.PNG]]&lt;br /&gt;
&lt;br /&gt;
Once the instructor logs in, they can either select badges for existing assignments or go to a view which displays all the nominations.&lt;br /&gt;
&lt;br /&gt;
Once the instructor selects the badges for the existing assignments, the students can login and provide nominations for badges during peer review.&lt;br /&gt;
&lt;br /&gt;
==Design==&lt;br /&gt;
  [[File:Oodd2.PNG]]&lt;br /&gt;
&lt;br /&gt;
An instructor can add a badge to the badges table which will be also added to an assignment table as a probable nomination badge. The instructor can also view all the nominations done by the students during the peer review of an assignment.&lt;br /&gt;
&lt;br /&gt;
The students on the other hand, while doing the peer review, can provide nominations for badges provided by the instructor for a particular assignment.&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
We will be creating test cases in the files &lt;br /&gt;
:·peer review.rb :Check with peer reviewer will be able to nominate badges&lt;br /&gt;
:·review_assignment_spec.rb:Check whether user is able to review assignment with Team Size=1&lt;br /&gt;
:·team_creation_spec.rb:Check the Team Size&lt;br /&gt;
:·review_mapping_spec.rb:Check whether reviewer is correctly mapped to the enrolled course&lt;br /&gt;
:·Write feature tests to verify the modifications:Include tests in the a new badge_system_spec.rb file in the spec/features directory&lt;br /&gt;
&lt;br /&gt;
*UI design Testing:&lt;br /&gt;
:·Check if peer reviewer is able to nominate for badges with drop down list and contains text boxes for justification.&lt;br /&gt;
:·Check if instructor is able to view the summary of all nominations.&lt;br /&gt;
:·Cosmetic Inconsistencies – The screen look, feel and design should match the other screens in your application.&lt;br /&gt;
&lt;br /&gt;
==Reference Links==&lt;br /&gt;
*[https://github.com/expertiza/expertiza/tree/master/app/views Expertiza Github Master Branch]&lt;br /&gt;
*[http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2015_E1575_Share_the_data_in_Expertiza_to_a_remote_server_via_PRML_format Expertiza Database Schema]&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113656</id>
		<title>CSC/ECE 517 Fall 2017/E17AA Nomination for Badges</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113656"/>
		<updated>2017-11-17T01:54:11Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: /* Design */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Problem Statement==&lt;br /&gt;
&lt;br /&gt;
The purpose of the project is to implement a way to allow students to nominate badges to other students while reviewing their work. The professor should also be able to see the nominations to each student in a single page. &lt;br /&gt;
&lt;br /&gt;
==Pre-Conditions==&lt;br /&gt;
&lt;br /&gt;
These are the pre-conditions that needs to hold true for each functionality to work&lt;br /&gt;
&lt;br /&gt;
:· The maximum number of students that can be assigned to the project cannot be more then 1. &lt;br /&gt;
:· For students to nominate badges, the professor must have provided a list of pre-decided badges possible for that project. &lt;br /&gt;
:· For students to be able to nominate badged without justification only if the project does not have a mandatory justification requirement.&lt;br /&gt;
&lt;br /&gt;
==Implementation Steps==&lt;br /&gt;
&lt;br /&gt;
:· Provide professors an option to add all possible badges to a project. &lt;br /&gt;
:· Allow students to nominate badges while peer reviewing.&lt;br /&gt;
:· Show a summary of all nominated badges to professor in a single page.&lt;br /&gt;
&lt;br /&gt;
==Modifications To Be Done==&lt;br /&gt;
&lt;br /&gt;
*Files to be Modified&lt;br /&gt;
:· Add the code to include the selection of relevant badges and the justification text box Assignment_questionnaire_controller.rb.&lt;br /&gt;
:· Add the badges model to assignment_questionnaire.rb.&lt;br /&gt;
:· Add the code to display the nomination summary on the page student_task/list page&lt;br /&gt;
&lt;br /&gt;
*Tables to be Modified&lt;br /&gt;
:· We’ll be creating a table named “badges”, with the following attributes: &lt;br /&gt;
   id: primary key&lt;br /&gt;
   name: varchar&lt;br /&gt;
   description: varchar&lt;br /&gt;
&lt;br /&gt;
:· We’ll be creating a table named “assignment_questionnaires_badges”, with the following attributes: &lt;br /&gt;
   Id: Primary key&lt;br /&gt;
   assignment_id: foreign key&lt;br /&gt;
   questionnaire_id: foreign key&lt;br /&gt;
   badge_id: foreign key&lt;br /&gt;
&lt;br /&gt;
==Execution Flow==&lt;br /&gt;
  [[File:Oodd5.PNG]]&lt;br /&gt;
&lt;br /&gt;
Once the instructor logs in, they can either select badges for existing assignments or go to a view which displays all the nominations.&lt;br /&gt;
&lt;br /&gt;
Once the instructor selects the badges for the existing assignments, the students can login and provide nominations for badges during peer review.&lt;br /&gt;
&lt;br /&gt;
==Design==&lt;br /&gt;
  [[File:Oodd2.PNG]]&lt;br /&gt;
&lt;br /&gt;
An instructor can add a badge to the badges table which will be also added to an assignment table as a probable nomination badge. The instructor can also view all the nominations done by the students during the peer review of an assignment.&lt;br /&gt;
&lt;br /&gt;
The students on the other hand, while doing the peer review, can provide nominations for badges provided by the instructor for a particular assignment.&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
We will be creating test cases in the files &lt;br /&gt;
:·peer review.rb :Check with peer reviewer will be able to nominate badges&lt;br /&gt;
:·review_assignment_spec.rb:Check whether user is able to review assignment with Team Size=1&lt;br /&gt;
:·team_creation_spec.rb:Check the Team Size&lt;br /&gt;
:·review_mapping_spec.rb:Check whether reviewer is correctly mapped to the enrolled course&lt;br /&gt;
:·Write feature tests to verify the modifications:Include tests in the a new badge_system_spec.rb file in the spec/features directory&lt;br /&gt;
&lt;br /&gt;
*UI design Testing:&lt;br /&gt;
:·Check if peer reviewer is able to nominate for badges with drop down list and contains text boxes for justification.&lt;br /&gt;
:·Check if instructor is able to view the summary of all nominations.&lt;br /&gt;
:·Cosmetic Inconsistencies – The screen look, feel and design should match the other screens in your application.&lt;br /&gt;
&lt;br /&gt;
==Reference Links==&lt;br /&gt;
*[https://github.com/expertiza/expertiza/tree/master/app/views Expertiza Github Master Branch]&lt;br /&gt;
*[http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2015_E1575_Share_the_data_in_Expertiza_to_a_remote_server_via_PRML_format Expertiza Database Schema]&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113655</id>
		<title>CSC/ECE 517 Fall 2017/E17AA Nomination for Badges</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113655"/>
		<updated>2017-11-17T01:54:02Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: /* Design */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Problem Statement==&lt;br /&gt;
&lt;br /&gt;
The purpose of the project is to implement a way to allow students to nominate badges to other students while reviewing their work. The professor should also be able to see the nominations to each student in a single page. &lt;br /&gt;
&lt;br /&gt;
==Pre-Conditions==&lt;br /&gt;
&lt;br /&gt;
These are the pre-conditions that needs to hold true for each functionality to work&lt;br /&gt;
&lt;br /&gt;
:· The maximum number of students that can be assigned to the project cannot be more then 1. &lt;br /&gt;
:· For students to nominate badges, the professor must have provided a list of pre-decided badges possible for that project. &lt;br /&gt;
:· For students to be able to nominate badged without justification only if the project does not have a mandatory justification requirement.&lt;br /&gt;
&lt;br /&gt;
==Implementation Steps==&lt;br /&gt;
&lt;br /&gt;
:· Provide professors an option to add all possible badges to a project. &lt;br /&gt;
:· Allow students to nominate badges while peer reviewing.&lt;br /&gt;
:· Show a summary of all nominated badges to professor in a single page.&lt;br /&gt;
&lt;br /&gt;
==Modifications To Be Done==&lt;br /&gt;
&lt;br /&gt;
*Files to be Modified&lt;br /&gt;
:· Add the code to include the selection of relevant badges and the justification text box Assignment_questionnaire_controller.rb.&lt;br /&gt;
:· Add the badges model to assignment_questionnaire.rb.&lt;br /&gt;
:· Add the code to display the nomination summary on the page student_task/list page&lt;br /&gt;
&lt;br /&gt;
*Tables to be Modified&lt;br /&gt;
:· We’ll be creating a table named “badges”, with the following attributes: &lt;br /&gt;
   id: primary key&lt;br /&gt;
   name: varchar&lt;br /&gt;
   description: varchar&lt;br /&gt;
&lt;br /&gt;
:· We’ll be creating a table named “assignment_questionnaires_badges”, with the following attributes: &lt;br /&gt;
   Id: Primary key&lt;br /&gt;
   assignment_id: foreign key&lt;br /&gt;
   questionnaire_id: foreign key&lt;br /&gt;
   badge_id: foreign key&lt;br /&gt;
&lt;br /&gt;
==Execution Flow==&lt;br /&gt;
  [[File:Oodd5.PNG]]&lt;br /&gt;
&lt;br /&gt;
Once the instructor logs in, they can either select badges for existing assignments or go to a view which displays all the nominations.&lt;br /&gt;
&lt;br /&gt;
Once the instructor selects the badges for the existing assignments, the students can login and provide nominations for badges during peer review.&lt;br /&gt;
&lt;br /&gt;
==Design==&lt;br /&gt;
  [[File:Oodd2.PNG]]&lt;br /&gt;
&lt;br /&gt;
An instructor can add a badge to the badges table which will be also added to an assignment table as a probable nomination badge. The instructor can also view all the nominations done by the students during the peer review of an assignment.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The students on the other hand, while doing the peer review, can provide nominations for badges provided by the instructor for a particular assignment.&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
We will be creating test cases in the files &lt;br /&gt;
:·peer review.rb :Check with peer reviewer will be able to nominate badges&lt;br /&gt;
:·review_assignment_spec.rb:Check whether user is able to review assignment with Team Size=1&lt;br /&gt;
:·team_creation_spec.rb:Check the Team Size&lt;br /&gt;
:·review_mapping_spec.rb:Check whether reviewer is correctly mapped to the enrolled course&lt;br /&gt;
:·Write feature tests to verify the modifications:Include tests in the a new badge_system_spec.rb file in the spec/features directory&lt;br /&gt;
&lt;br /&gt;
*UI design Testing:&lt;br /&gt;
:·Check if peer reviewer is able to nominate for badges with drop down list and contains text boxes for justification.&lt;br /&gt;
:·Check if instructor is able to view the summary of all nominations.&lt;br /&gt;
:·Cosmetic Inconsistencies – The screen look, feel and design should match the other screens in your application.&lt;br /&gt;
&lt;br /&gt;
==Reference Links==&lt;br /&gt;
*[https://github.com/expertiza/expertiza/tree/master/app/views Expertiza Github Master Branch]&lt;br /&gt;
*[http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2015_E1575_Share_the_data_in_Expertiza_to_a_remote_server_via_PRML_format Expertiza Database Schema]&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113654</id>
		<title>CSC/ECE 517 Fall 2017/E17AA Nomination for Badges</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113654"/>
		<updated>2017-11-17T01:50:24Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: /* Execution Flow */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Problem Statement==&lt;br /&gt;
&lt;br /&gt;
The purpose of the project is to implement a way to allow students to nominate badges to other students while reviewing their work. The professor should also be able to see the nominations to each student in a single page. &lt;br /&gt;
&lt;br /&gt;
==Pre-Conditions==&lt;br /&gt;
&lt;br /&gt;
These are the pre-conditions that needs to hold true for each functionality to work&lt;br /&gt;
&lt;br /&gt;
:· The maximum number of students that can be assigned to the project cannot be more then 1. &lt;br /&gt;
:· For students to nominate badges, the professor must have provided a list of pre-decided badges possible for that project. &lt;br /&gt;
:· For students to be able to nominate badged without justification only if the project does not have a mandatory justification requirement.&lt;br /&gt;
&lt;br /&gt;
==Implementation Steps==&lt;br /&gt;
&lt;br /&gt;
:· Provide professors an option to add all possible badges to a project. &lt;br /&gt;
:· Allow students to nominate badges while peer reviewing.&lt;br /&gt;
:· Show a summary of all nominated badges to professor in a single page.&lt;br /&gt;
&lt;br /&gt;
==Modifications To Be Done==&lt;br /&gt;
&lt;br /&gt;
*Files to be Modified&lt;br /&gt;
:· Add the code to include the selection of relevant badges and the justification text box Assignment_questionnaire_controller.rb.&lt;br /&gt;
:· Add the badges model to assignment_questionnaire.rb.&lt;br /&gt;
:· Add the code to display the nomination summary on the page student_task/list page&lt;br /&gt;
&lt;br /&gt;
*Tables to be Modified&lt;br /&gt;
:· We’ll be creating a table named “badges”, with the following attributes: &lt;br /&gt;
   id: primary key&lt;br /&gt;
   name: varchar&lt;br /&gt;
   description: varchar&lt;br /&gt;
&lt;br /&gt;
:· We’ll be creating a table named “assignment_questionnaires_badges”, with the following attributes: &lt;br /&gt;
   Id: Primary key&lt;br /&gt;
   assignment_id: foreign key&lt;br /&gt;
   questionnaire_id: foreign key&lt;br /&gt;
   badge_id: foreign key&lt;br /&gt;
&lt;br /&gt;
==Execution Flow==&lt;br /&gt;
  [[File:Oodd5.PNG]]&lt;br /&gt;
&lt;br /&gt;
Once the instructor logs in, they can either select badges for existing assignments or go to a view which displays all the nominations.&lt;br /&gt;
&lt;br /&gt;
Once the instructor selects the badges for the existing assignments, the students can login and provide nominations for badges during peer review.&lt;br /&gt;
&lt;br /&gt;
==Design==&lt;br /&gt;
  [[File:Oodd2.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
We will be creating test cases in the files &lt;br /&gt;
:·peer review.rb :Check with peer reviewer will be able to nominate badges&lt;br /&gt;
:·review_assignment_spec.rb:Check whether user is able to review assignment with Team Size=1&lt;br /&gt;
:·team_creation_spec.rb:Check the Team Size&lt;br /&gt;
:·review_mapping_spec.rb:Check whether reviewer is correctly mapped to the enrolled course&lt;br /&gt;
:·Write feature tests to verify the modifications:Include tests in the a new badge_system_spec.rb file in the spec/features directory&lt;br /&gt;
&lt;br /&gt;
*UI design Testing:&lt;br /&gt;
:·Check if peer reviewer is able to nominate for badges with drop down list and contains text boxes for justification.&lt;br /&gt;
:·Check if instructor is able to view the summary of all nominations.&lt;br /&gt;
:·Cosmetic Inconsistencies – The screen look, feel and design should match the other screens in your application.&lt;br /&gt;
&lt;br /&gt;
==Reference Links==&lt;br /&gt;
*[https://github.com/expertiza/expertiza/tree/master/app/views Expertiza Github Master Branch]&lt;br /&gt;
*[http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2015_E1575_Share_the_data_in_Expertiza_to_a_remote_server_via_PRML_format Expertiza Database Schema]&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113653</id>
		<title>CSC/ECE 517 Fall 2017/E17AA Nomination for Badges</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17AA_Nomination_for_Badges&amp;diff=113653"/>
		<updated>2017-11-17T01:50:14Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: /* Execution Flow */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Problem Statement==&lt;br /&gt;
&lt;br /&gt;
The purpose of the project is to implement a way to allow students to nominate badges to other students while reviewing their work. The professor should also be able to see the nominations to each student in a single page. &lt;br /&gt;
&lt;br /&gt;
==Pre-Conditions==&lt;br /&gt;
&lt;br /&gt;
These are the pre-conditions that needs to hold true for each functionality to work&lt;br /&gt;
&lt;br /&gt;
:· The maximum number of students that can be assigned to the project cannot be more then 1. &lt;br /&gt;
:· For students to nominate badges, the professor must have provided a list of pre-decided badges possible for that project. &lt;br /&gt;
:· For students to be able to nominate badged without justification only if the project does not have a mandatory justification requirement.&lt;br /&gt;
&lt;br /&gt;
==Implementation Steps==&lt;br /&gt;
&lt;br /&gt;
:· Provide professors an option to add all possible badges to a project. &lt;br /&gt;
:· Allow students to nominate badges while peer reviewing.&lt;br /&gt;
:· Show a summary of all nominated badges to professor in a single page.&lt;br /&gt;
&lt;br /&gt;
==Modifications To Be Done==&lt;br /&gt;
&lt;br /&gt;
*Files to be Modified&lt;br /&gt;
:· Add the code to include the selection of relevant badges and the justification text box Assignment_questionnaire_controller.rb.&lt;br /&gt;
:· Add the badges model to assignment_questionnaire.rb.&lt;br /&gt;
:· Add the code to display the nomination summary on the page student_task/list page&lt;br /&gt;
&lt;br /&gt;
*Tables to be Modified&lt;br /&gt;
:· We’ll be creating a table named “badges”, with the following attributes: &lt;br /&gt;
   id: primary key&lt;br /&gt;
   name: varchar&lt;br /&gt;
   description: varchar&lt;br /&gt;
&lt;br /&gt;
:· We’ll be creating a table named “assignment_questionnaires_badges”, with the following attributes: &lt;br /&gt;
   Id: Primary key&lt;br /&gt;
   assignment_id: foreign key&lt;br /&gt;
   questionnaire_id: foreign key&lt;br /&gt;
   badge_id: foreign key&lt;br /&gt;
&lt;br /&gt;
==Execution Flow==&lt;br /&gt;
  [[File:Oodd5.PNG]]&lt;br /&gt;
&lt;br /&gt;
Once the instructor logs in, they can either select badges for existing assignments or go to a view which displays all the nominations.&lt;br /&gt;
Once the instructor selects the badges for the existing assignments, the students can login and provide nominations for badges during peer review.&lt;br /&gt;
&lt;br /&gt;
==Design==&lt;br /&gt;
  [[File:Oodd2.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
We will be creating test cases in the files &lt;br /&gt;
:·peer review.rb :Check with peer reviewer will be able to nominate badges&lt;br /&gt;
:·review_assignment_spec.rb:Check whether user is able to review assignment with Team Size=1&lt;br /&gt;
:·team_creation_spec.rb:Check the Team Size&lt;br /&gt;
:·review_mapping_spec.rb:Check whether reviewer is correctly mapped to the enrolled course&lt;br /&gt;
:·Write feature tests to verify the modifications:Include tests in the a new badge_system_spec.rb file in the spec/features directory&lt;br /&gt;
&lt;br /&gt;
*UI design Testing:&lt;br /&gt;
:·Check if peer reviewer is able to nominate for badges with drop down list and contains text boxes for justification.&lt;br /&gt;
:·Check if instructor is able to view the summary of all nominations.&lt;br /&gt;
:·Cosmetic Inconsistencies – The screen look, feel and design should match the other screens in your application.&lt;br /&gt;
&lt;br /&gt;
==Reference Links==&lt;br /&gt;
*[https://github.com/expertiza/expertiza/tree/master/app/views Expertiza Github Master Branch]&lt;br /&gt;
*[http://wiki.expertiza.ncsu.edu/index.php/CSC/ECE_517_Fall_2015_E1575_Share_the_data_in_Expertiza_to_a_remote_server_via_PRML_format Expertiza Database Schema]&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1771_Refactor_team.rb&amp;diff=111866</id>
		<title>CSC/ECE 517 Fall 2017/E1771 Refactor team.rb</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1771_Refactor_team.rb&amp;diff=111866"/>
		<updated>2017-11-05T22:02:53Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
Expertiza is an open source webapp built on Ruby on Rails stack. It provides a platform to students with various features like peer-reviewing projects, submitting work, form teams, viewing grades etc. The project is being built and maintained by students and faculty at NCSU.&lt;br /&gt;
== Mentor and Members ==&lt;br /&gt;
'''Mentor: Zhewei Hu (zhu6@ncsu.edu)'''&lt;br /&gt;
&lt;br /&gt;
1. Darshil Patel (dpatel14@ncsu.edu)&lt;br /&gt;
&lt;br /&gt;
2. Srujan Barai (sjbarai@ncsu.edu)&lt;br /&gt;
&lt;br /&gt;
3. Shikhar Sharma (ssharm29@ncsu.edu)&lt;br /&gt;
== About team.rb ==&lt;br /&gt;
team.rb is the default class to interact with the team table. team.rb has 2 subclasses assignment_team.rb and course_team.rb.&lt;br /&gt;
== Issue ==&lt;br /&gt;
team.rb is a fairly complex file. It contains a lot of methods that are long and hard to understand. &lt;br /&gt;
These methods need to be broken down into simpler and more specific methods that are easier to read/understand. Also, the few instances of code duplication that exist should be removed&lt;br /&gt;
== Tasks accomplished ==&lt;br /&gt;
    · Refactor self.randomize_all_by_parent method&lt;br /&gt;
        · Split into several simpler methods and assign reasonable names&lt;br /&gt;
        · Extract duplicated code into separate methods&lt;br /&gt;
    · Rename method and change all other places it is used&lt;br /&gt;
        · has_user →  user?&lt;br /&gt;
        · get_node_type → node_type&lt;br /&gt;
        · get_author_names → author_names&lt;br /&gt;
    · Pass &amp;amp;:destroy as an argument to each instead of a block&lt;br /&gt;
        · L22&lt;br /&gt;
    · Use find_by instead of dynamic method&lt;br /&gt;
        · L63, L153, L162&lt;br /&gt;
    · Use find_by instead of where.first&lt;br /&gt;
        · L166, L181 &lt;br /&gt;
    · Complete the pending tests in team_spec.rb, and write integration tests for newly-created methods. Refactor corresponding methods, and only then finish pending tests.&lt;br /&gt;
Elaborating the edits made: &lt;br /&gt;
== Refactor self.randomize_all_by_parent method ==&lt;br /&gt;
Previous code:&lt;br /&gt;
  def self.randomize_all_by_parent(parent, team_type, min_team_size)&lt;br /&gt;
    participants = Participant.where(parent_id: parent.id, type: parent.class.to_s + &amp;quot;Participant&amp;quot;)&lt;br /&gt;
    participants = participants.sort { rand(3) - 1 }&lt;br /&gt;
    users = participants.map {|p| User.find(p.user_id) }.to_a&lt;br /&gt;
    # find teams still need team members and users who are not in any team&lt;br /&gt;
    teams = Team.where(parent_id: parent.id, type: parent.class.to_s + &amp;quot;Team&amp;quot;).to_a&lt;br /&gt;
    teams_num = teams.size&lt;br /&gt;
    i = 0&lt;br /&gt;
    teams_num.times do&lt;br /&gt;
      teams_users = TeamsUser.where(team_id: teams[i].id)&lt;br /&gt;
      teams_users.each do |teams_user|&lt;br /&gt;
        users.delete(User.find(teams_user.user_id))&lt;br /&gt;
      end&lt;br /&gt;
      if Team.size(teams.first.id) &amp;gt;= min_team_size&lt;br /&gt;
        teams.delete(teams.first)&lt;br /&gt;
      else&lt;br /&gt;
        i += 1&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
    # sort teams by decreasing team size&lt;br /&gt;
    teams.sort_by {|team| Team.size(team.id) }.reverse!&lt;br /&gt;
    # insert users who are not in any team to teams still need team members&lt;br /&gt;
    if !users.empty? and !teams.empty?&lt;br /&gt;
      teams.each do |team|&lt;br /&gt;
        curr_team_size = Team.size(team.id)&lt;br /&gt;
        member_num_difference = min_team_size - curr_team_size&lt;br /&gt;
        for i in (1..member_num_difference).to_a&lt;br /&gt;
          team.add_member(users.first, parent.id)&lt;br /&gt;
          users.delete(users.first)&lt;br /&gt;
          break if users.empty?&lt;br /&gt;
        end&lt;br /&gt;
        break if users.empty?&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
    # If all the existing teams are fill to the min_team_size and we still have more users, create teams for them.&lt;br /&gt;
    unless users.empty?&lt;br /&gt;
      num_of_teams = users.length.fdiv(min_team_size).ceil&lt;br /&gt;
      nextTeamMemberIndex = 0&lt;br /&gt;
      for i in (1..num_of_teams).to_a&lt;br /&gt;
        team = Object.const_get(team_type + 'Team').create(name: &amp;quot;Team&amp;quot; + i.to_s, parent_id: parent.id)&lt;br /&gt;
        TeamNode.create(parent_id: parent.id, node_object_id: team.id)&lt;br /&gt;
        min_team_size.times do&lt;br /&gt;
          break if nextTeamMemberIndex &amp;gt;= users.length&lt;br /&gt;
          user = users[nextTeamMemberIndex]&lt;br /&gt;
          team.add_member(user, parent.id)&lt;br /&gt;
          nextTeamMemberIndex += 1&lt;br /&gt;
        end&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
This method has been edited and divided into following methods:&lt;br /&gt;
== sort_teams_by_members_reverse() ==&lt;br /&gt;
 def self.sort_teams_by_members_reverse(teams)&lt;br /&gt;
     teams.sort_by { |team| Team.size(team.id) }.reverse!&lt;br /&gt;
  end&lt;br /&gt;
== assign_single_users_to_teams ==&lt;br /&gt;
 def self.assign_single_users_to_teams(min_team_size, parent, teams, users)&lt;br /&gt;
    teams.each do |team|&lt;br /&gt;
      curr_team_size = Team.size(team.id)&lt;br /&gt;
      member_num_difference = min_team_size - curr_team_size&lt;br /&gt;
      for i in (1..member_num_difference).to_a&lt;br /&gt;
        team.add_member(users.first, parent.id)&lt;br /&gt;
        users.delete(users.first)&lt;br /&gt;
        break if users.empty?&lt;br /&gt;
      end&lt;br /&gt;
      break if users.empty?&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
== create_team_from_single_users ==&lt;br /&gt;
 def self.create_team_from_single_users(min_team_size, parent, team_type, users)&lt;br /&gt;
    num_of_teams = users.length.fdiv(min_team_size).ceil&lt;br /&gt;
    nextTeamMemberIndex = 0&lt;br /&gt;
    for i in (1..num_of_teams).to_a&lt;br /&gt;
      team = Object.const_get(team_type + 'Team').create(name: &amp;quot;Team&amp;quot; + i.to_s, parent_id: parent.id)&lt;br /&gt;
      TeamNode.create(parent_id: parent.id, node_object_id: team.id)&lt;br /&gt;
      min_team_size.times do&lt;br /&gt;
        break if nextTeamMemberIndex &amp;gt;= users.length&lt;br /&gt;
        user = users[nextTeamMemberIndex]&lt;br /&gt;
        team.add_member(user, parent.id)&lt;br /&gt;
        nextTeamMemberIndex += 1&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
== Rename method and change all other places it is used ==&lt;br /&gt;
Renamed the methods '''has_user to user?''', '''get_node_type → node_type''' and '''get_author_names → author_names''' and also updated the function calls so that they call the correct (newly renamed) methods&lt;br /&gt;
== Pass &amp;amp;:destroy as an argument to each instead of a block ==&lt;br /&gt;
 TeamsUser.where(team_id: self.id).each{ |teams_user| teams_user.destroy }&lt;br /&gt;
was refactored to&lt;br /&gt;
 TeamsUser.where(team_id: self.id).each(&amp;amp;:destroy)&lt;br /&gt;
== Use find_by instead of dynamic method ==&lt;br /&gt;
 parent = TeamNode.find_by_node_object_id(self.id)&lt;br /&gt;
&lt;br /&gt;
 return team_name unless Team.find_by_name(team_name)&lt;br /&gt;
&lt;br /&gt;
 user = User.find_by_name(row[index].to_s.strip)&lt;br /&gt;
&lt;br /&gt;
were changed to&lt;br /&gt;
 parent = TeamNode.find_by(node_object_id: self.id)&lt;br /&gt;
&lt;br /&gt;
 return team_name unless Team.find_by(name: team_name)&lt;br /&gt;
&lt;br /&gt;
 user = User.find_by(name: row[index].to_s.strip)&lt;br /&gt;
== Use find_by instead of where.first ==&lt;br /&gt;
 participant = AssignmentParticipant.where(user_id: user.id, parent_id: self.parent_id).first&lt;br /&gt;
&lt;br /&gt;
 if AssignmentParticipant.where(parent_id: assignment_id, user_id: user.id).first.nil?&lt;br /&gt;
&lt;br /&gt;
 if CourseParticipant.where(parent_id: course_id, user_id: user.id).first.nil?&lt;br /&gt;
&lt;br /&gt;
were updated to&lt;br /&gt;
 participant = AssignmentParticipant.find_by(user_id: user.id, parent_id: self.parent_id)&lt;br /&gt;
&lt;br /&gt;
 if AssignmentParticipant.find_by(parent_id: assignment_id, user_id: user.id).nil?&lt;br /&gt;
&lt;br /&gt;
 if CourseParticipant.find_by(parent_id: course_id, user_id: user.id).nil?&lt;br /&gt;
&lt;br /&gt;
== Test Cases ==&lt;br /&gt;
We have completed all the pending tests in the file team_spec.rb and all the test cases are passing. This can be checked in the pull request which is linked below.&lt;br /&gt;
&lt;br /&gt;
== Pull Request ==&lt;br /&gt;
Github Link to Pull Request: [https://github.com/expertiza/expertiza/pull/1043]&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1771_Refactor_team.rb&amp;diff=111849</id>
		<title>CSC/ECE 517 Fall 2017/E1771 Refactor team.rb</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1771_Refactor_team.rb&amp;diff=111849"/>
		<updated>2017-11-05T21:28:37Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open source webapp built on Ruby on Rails stack. It provides a platform to students with various features like peer-reviewing projects, submitting work, form teams, viewing grades etc. The project is being built and maintained by students and faculty at NCSU.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Mentor and Members ==&lt;br /&gt;
'''Mentor: Zhewei Hu (zhu6@ncsu.edu)'''&lt;br /&gt;
&lt;br /&gt;
1. Darshil Patel (dpatel14@ncsu.edu)&lt;br /&gt;
&lt;br /&gt;
2. Srujan Barai (sjbarai@ncsu.edu)&lt;br /&gt;
&lt;br /&gt;
3. Shikhar Sharma (ssharm29@ncsu.edu)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About team.rb ==&lt;br /&gt;
&lt;br /&gt;
team.rb is the default class to interact with the team table. team.rb has 2 subclasses assignment_team.rb and course_team.rb.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Issue ==&lt;br /&gt;
&lt;br /&gt;
team.rb is a fairly complex file. It contains a lot of methods that are long and hard to understand. &lt;br /&gt;
These methods need to be broken down into simpler and more specific methods that are easier to read/understand. Also, the few instances of code duplication that exist should be removed&lt;br /&gt;
&lt;br /&gt;
== Tasks accomplished ==&lt;br /&gt;
&lt;br /&gt;
    · Refactor self.randomize_all_by_parent method&lt;br /&gt;
        · Split into several simpler methods and assign reasonable names&lt;br /&gt;
        · Extract duplicated code into separate methods&lt;br /&gt;
    · Rename method and change all other places it is used&lt;br /&gt;
        · has_user →  user?&lt;br /&gt;
        · get_node_type → node_type&lt;br /&gt;
        · get_author_names → author_names&lt;br /&gt;
    · Pass &amp;amp;:destroy as an argument to each instead of a block&lt;br /&gt;
        · L22&lt;br /&gt;
    · Use find_by instead of dynamic method&lt;br /&gt;
        · L63, L153, L162&lt;br /&gt;
    · Use find_by instead of where.first&lt;br /&gt;
        · L166, L181 &lt;br /&gt;
    · Complete the pending tests in team_spec.rb, and write integration tests for newly-created methods. Refactor corresponding methods, and only then finish pending tests.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Elaborating the edits made: &lt;br /&gt;
&lt;br /&gt;
== Refactor self.randomize_all_by_parent method ==&lt;br /&gt;
&lt;br /&gt;
Previous code:&lt;br /&gt;
&lt;br /&gt;
  def self.randomize_all_by_parent(parent, team_type, min_team_size)&lt;br /&gt;
    participants = Participant.where(parent_id: parent.id, type: parent.class.to_s + &amp;quot;Participant&amp;quot;)&lt;br /&gt;
    participants = participants.sort { rand(3) - 1 }&lt;br /&gt;
    users = participants.map {|p| User.find(p.user_id) }.to_a&lt;br /&gt;
    # find teams still need team members and users who are not in any team&lt;br /&gt;
    teams = Team.where(parent_id: parent.id, type: parent.class.to_s + &amp;quot;Team&amp;quot;).to_a&lt;br /&gt;
    teams_num = teams.size&lt;br /&gt;
    i = 0&lt;br /&gt;
    teams_num.times do&lt;br /&gt;
      teams_users = TeamsUser.where(team_id: teams[i].id)&lt;br /&gt;
      teams_users.each do |teams_user|&lt;br /&gt;
        users.delete(User.find(teams_user.user_id))&lt;br /&gt;
      end&lt;br /&gt;
      if Team.size(teams.first.id) &amp;gt;= min_team_size&lt;br /&gt;
        teams.delete(teams.first)&lt;br /&gt;
      else&lt;br /&gt;
        i += 1&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
    # sort teams by decreasing team size&lt;br /&gt;
    teams.sort_by {|team| Team.size(team.id) }.reverse!&lt;br /&gt;
    # insert users who are not in any team to teams still need team members&lt;br /&gt;
    if !users.empty? and !teams.empty?&lt;br /&gt;
      teams.each do |team|&lt;br /&gt;
        curr_team_size = Team.size(team.id)&lt;br /&gt;
        member_num_difference = min_team_size - curr_team_size&lt;br /&gt;
        for i in (1..member_num_difference).to_a&lt;br /&gt;
          team.add_member(users.first, parent.id)&lt;br /&gt;
          users.delete(users.first)&lt;br /&gt;
          break if users.empty?&lt;br /&gt;
        end&lt;br /&gt;
        break if users.empty?&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
    # If all the existing teams are fill to the min_team_size and we still have more users, create teams for them.&lt;br /&gt;
    unless users.empty?&lt;br /&gt;
      num_of_teams = users.length.fdiv(min_team_size).ceil&lt;br /&gt;
      nextTeamMemberIndex = 0&lt;br /&gt;
      for i in (1..num_of_teams).to_a&lt;br /&gt;
        team = Object.const_get(team_type + 'Team').create(name: &amp;quot;Team&amp;quot; + i.to_s, parent_id: parent.id)&lt;br /&gt;
        TeamNode.create(parent_id: parent.id, node_object_id: team.id)&lt;br /&gt;
        min_team_size.times do&lt;br /&gt;
          break if nextTeamMemberIndex &amp;gt;= users.length&lt;br /&gt;
          user = users[nextTeamMemberIndex]&lt;br /&gt;
          team.add_member(user, parent.id)&lt;br /&gt;
          nextTeamMemberIndex += 1&lt;br /&gt;
        end&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
This method has been edited and divided into following methods:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== sort_teams_by_members_reverse() ==&lt;br /&gt;
&lt;br /&gt;
 def self.sort_teams_by_members_reverse(teams)&lt;br /&gt;
     teams.sort_by { |team| Team.size(team.id) }.reverse!&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== assign_single_users_to_teams ==&lt;br /&gt;
&lt;br /&gt;
 def self.assign_single_users_to_teams(min_team_size, parent, teams, users)&lt;br /&gt;
    teams.each do |team|&lt;br /&gt;
      curr_team_size = Team.size(team.id)&lt;br /&gt;
      member_num_difference = min_team_size - curr_team_size&lt;br /&gt;
      for i in (1..member_num_difference).to_a&lt;br /&gt;
        team.add_member(users.first, parent.id)&lt;br /&gt;
        users.delete(users.first)&lt;br /&gt;
        break if users.empty?&lt;br /&gt;
      end&lt;br /&gt;
      break if users.empty?&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== create_team_from_single_users ==&lt;br /&gt;
&lt;br /&gt;
 def self.create_team_from_single_users(min_team_size, parent, team_type, users)&lt;br /&gt;
    num_of_teams = users.length.fdiv(min_team_size).ceil&lt;br /&gt;
    nextTeamMemberIndex = 0&lt;br /&gt;
    for i in (1..num_of_teams).to_a&lt;br /&gt;
      team = Object.const_get(team_type + 'Team').create(name: &amp;quot;Team&amp;quot; + i.to_s, parent_id: parent.id)&lt;br /&gt;
      TeamNode.create(parent_id: parent.id, node_object_id: team.id)&lt;br /&gt;
      min_team_size.times do&lt;br /&gt;
        break if nextTeamMemberIndex &amp;gt;= users.length&lt;br /&gt;
        user = users[nextTeamMemberIndex]&lt;br /&gt;
        team.add_member(user, parent.id)&lt;br /&gt;
        nextTeamMemberIndex += 1&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
== Pull Request ==&lt;br /&gt;
Github Link to Pull Request: [https://github.com/expertiza/expertiza/pull/1043]&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017&amp;diff=111845</id>
		<title>CSC/ECE 517 Fall 2017</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017&amp;diff=111845"/>
		<updated>2017-11-05T21:22:19Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''Design Project Documentation'''&lt;br /&gt;
*[[CSC/ECE 517 Fall 2017/E17A8. Use a profiler to identify the problems / pages that take some time to load &amp;amp; fix them]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2017/E1793. Help students find teams to join]]&lt;br /&gt;
&lt;br /&gt;
'''Writing Assignment 2'''&lt;br /&gt;
*[[CSC/ECE 517 Fall 2017/E1779. Fix teammate advertisements and requests to join a team]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1773 Investigate and Fix Expertiza Production Version Runtime Exceptions.rb]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1774 Metareview fixes and improvements.rb]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1788 OSS project Maroon Heatmap fixes]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2017/E1781 Topic Management]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1745_Refactor_response_controller.rb]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1752 Refactor assignments controller]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1776_Enhance_Imports]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1756 TLD Refactor response.rb]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1772_Refactor reputation_web_service_controller.rb]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/M1754_Mutation Testing on Servo]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1753 OSS project bidding tests]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1766_Test team functionality]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2017/E1767 Improve imports]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1786_OSS project Juniper Bookmark Enhancements]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1787_OSS project Bronze Score calculations]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1763 Fix Staggered-Deadline Assignments]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2017/E1757 Introduce a Student View for instructors]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2017/E1769_Refactor assignment_form.rb]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2017/E1754_Feature_test_of_rubric_advice]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2017/E1782 OSS Project Red Assignment Directories]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2017/E1748 Add past-due assignments to task list]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2017/E1761 Test First Development Refactor assignment.rb]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1780_OSS_Project_Teal_Email_Notification_Enhancements]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1762 Test various kinds of response-map hierarchies]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1759 ]]&lt;br /&gt;
*[[CSC/ECE_517_Fall_2017/E1749_Test First Development Refactor questionnaire_controller.rb]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2017/E1777 Coherent specification of review requirements.rb]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2017/E1771_Refactor_team.rb]]&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1771_Refactor_team.rb&amp;diff=111007</id>
		<title>CSC/ECE 517 Fall 2017/E1771 Refactor team.rb</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1771_Refactor_team.rb&amp;diff=111007"/>
		<updated>2017-10-30T19:55:20Z</updated>

		<summary type="html">&lt;p&gt;Dpatel14: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open source webapp built on Ruby on Rails stack. It provides a platform to students with various features like peer-reviewing projects, submitting work, form teams, viewing grades etc. The project is being built and maintained by students and faculty at NCSU.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About team.rb ==&lt;br /&gt;
&lt;br /&gt;
team.rb is the default class to interact with the team table. team.rb has 2 subclasses assignment_team.rb and course_team.rb.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Issue ==&lt;br /&gt;
&lt;br /&gt;
team.rb is a fairly complex file. It contains a lot of methods that are long and hard to understand. &lt;br /&gt;
These methods need to be broken down into simpler and more specific methods that are easier to read/understand. Also, the few instances of code duplication that exist should be removed&lt;br /&gt;
&lt;br /&gt;
== Tasks accomplished ==&lt;br /&gt;
&lt;br /&gt;
    · Refactor self.randomize_all_by_parent method&lt;br /&gt;
        · Split into several simpler methods and assign reasonable names&lt;br /&gt;
        · Extract duplicated code into separate methods&lt;br /&gt;
    · Rename method and change all other places it is used&lt;br /&gt;
        · has_user →  user?&lt;br /&gt;
        · get_node_type → node_type&lt;br /&gt;
        · get_author_names → author_names&lt;br /&gt;
    · Pass &amp;amp;:destroy as an argument to each instead of a block&lt;br /&gt;
        · L22&lt;br /&gt;
    · Use find_by instead of dynamic method&lt;br /&gt;
        · L63, L153, L162&lt;br /&gt;
    · Use find_by instead of where.first&lt;br /&gt;
        · L166, L181 &lt;br /&gt;
    · Complete the pending tests in team_spec.rb, and write integration tests for newly-created methods. Refactor corresponding methods, and only then finish pending tests.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Elaborating the edits made: &lt;br /&gt;
&lt;br /&gt;
== Refactor self.randomize_all_by_parent method ==&lt;br /&gt;
&lt;br /&gt;
Previous code:&lt;br /&gt;
&lt;br /&gt;
  def self.randomize_all_by_parent(parent, team_type, min_team_size)&lt;br /&gt;
    participants = Participant.where(parent_id: parent.id, type: parent.class.to_s + &amp;quot;Participant&amp;quot;)&lt;br /&gt;
    participants = participants.sort { rand(3) - 1 }&lt;br /&gt;
    users = participants.map {|p| User.find(p.user_id) }.to_a&lt;br /&gt;
    # find teams still need team members and users who are not in any team&lt;br /&gt;
    teams = Team.where(parent_id: parent.id, type: parent.class.to_s + &amp;quot;Team&amp;quot;).to_a&lt;br /&gt;
    teams_num = teams.size&lt;br /&gt;
    i = 0&lt;br /&gt;
    teams_num.times do&lt;br /&gt;
      teams_users = TeamsUser.where(team_id: teams[i].id)&lt;br /&gt;
      teams_users.each do |teams_user|&lt;br /&gt;
        users.delete(User.find(teams_user.user_id))&lt;br /&gt;
      end&lt;br /&gt;
      if Team.size(teams.first.id) &amp;gt;= min_team_size&lt;br /&gt;
        teams.delete(teams.first)&lt;br /&gt;
      else&lt;br /&gt;
        i += 1&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
    # sort teams by decreasing team size&lt;br /&gt;
    teams.sort_by {|team| Team.size(team.id) }.reverse!&lt;br /&gt;
    # insert users who are not in any team to teams still need team members&lt;br /&gt;
    if !users.empty? and !teams.empty?&lt;br /&gt;
      teams.each do |team|&lt;br /&gt;
        curr_team_size = Team.size(team.id)&lt;br /&gt;
        member_num_difference = min_team_size - curr_team_size&lt;br /&gt;
        for i in (1..member_num_difference).to_a&lt;br /&gt;
          team.add_member(users.first, parent.id)&lt;br /&gt;
          users.delete(users.first)&lt;br /&gt;
          break if users.empty?&lt;br /&gt;
        end&lt;br /&gt;
        break if users.empty?&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
    # If all the existing teams are fill to the min_team_size and we still have more users, create teams for them.&lt;br /&gt;
    unless users.empty?&lt;br /&gt;
      num_of_teams = users.length.fdiv(min_team_size).ceil&lt;br /&gt;
      nextTeamMemberIndex = 0&lt;br /&gt;
      for i in (1..num_of_teams).to_a&lt;br /&gt;
        team = Object.const_get(team_type + 'Team').create(name: &amp;quot;Team&amp;quot; + i.to_s, parent_id: parent.id)&lt;br /&gt;
        TeamNode.create(parent_id: parent.id, node_object_id: team.id)&lt;br /&gt;
        min_team_size.times do&lt;br /&gt;
          break if nextTeamMemberIndex &amp;gt;= users.length&lt;br /&gt;
          user = users[nextTeamMemberIndex]&lt;br /&gt;
          team.add_member(user, parent.id)&lt;br /&gt;
          nextTeamMemberIndex += 1&lt;br /&gt;
        end&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
This method has been edited and divided into following methods:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== sort_teams_by_members_reverse() ==&lt;br /&gt;
&lt;br /&gt;
 def self.sort_teams_by_members_reverse(teams)&lt;br /&gt;
     teams.sort_by { |team| Team.size(team.id) }.reverse!&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== assign_single_users_to_teams ==&lt;br /&gt;
&lt;br /&gt;
 def self.assign_single_users_to_teams(min_team_size, parent, teams, users)&lt;br /&gt;
    teams.each do |team|&lt;br /&gt;
      curr_team_size = Team.size(team.id)&lt;br /&gt;
      member_num_difference = min_team_size - curr_team_size&lt;br /&gt;
      for i in (1..member_num_difference).to_a&lt;br /&gt;
        team.add_member(users.first, parent.id)&lt;br /&gt;
        users.delete(users.first)&lt;br /&gt;
        break if users.empty?&lt;br /&gt;
      end&lt;br /&gt;
      break if users.empty?&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== create_team_from_single_users ==&lt;br /&gt;
&lt;br /&gt;
 def self.create_team_from_single_users(min_team_size, parent, team_type, users)&lt;br /&gt;
    num_of_teams = users.length.fdiv(min_team_size).ceil&lt;br /&gt;
    nextTeamMemberIndex = 0&lt;br /&gt;
    for i in (1..num_of_teams).to_a&lt;br /&gt;
      team = Object.const_get(team_type + 'Team').create(name: &amp;quot;Team&amp;quot; + i.to_s, parent_id: parent.id)&lt;br /&gt;
      TeamNode.create(parent_id: parent.id, node_object_id: team.id)&lt;br /&gt;
      min_team_size.times do&lt;br /&gt;
        break if nextTeamMemberIndex &amp;gt;= users.length&lt;br /&gt;
        user = users[nextTeamMemberIndex]&lt;br /&gt;
        team.add_member(user, parent.id)&lt;br /&gt;
        nextTeamMemberIndex += 1&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
== Pull Request ==&lt;br /&gt;
Github Link to Pull Request: [https://github.com/expertiza/expertiza/pull/1043]&lt;/div&gt;</summary>
		<author><name>Dpatel14</name></author>
	</entry>
</feed>