<?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=Tkothar</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=Tkothar"/>
	<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Special:Contributions/Tkothar"/>
	<updated>2026-05-06T16:47:54Z</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/E17A2_Lightweight_Badging_System&amp;diff=112690</id>
		<title>CSC/ECE 517 Fall 2017/E17A2 Lightweight Badging System</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17A2_Lightweight_Badging_System&amp;diff=112690"/>
		<updated>2017-11-08T05:27:26Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Problem Statement */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__TOC__&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Team Contact&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Priyanka Jain: [mailto:pjain15@ncsu.edu pjain15@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Zhewei Hu: [mailto:zhu6@ncsu.edu zhu6@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Project Description&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;strong&amp;gt;The full project topic description can be found [https://docs.google.com/document/d/1WYiXxhYyycp9a3I0GTC-4KFgHrg65Tf27ijJNQvxhmk/edit#heading=h.u6i7q1mdz0zl here]&amp;lt;/strong&amp;gt;.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
The goal of this project is to create a simple badging system for Expertiza, allowing students to earn badges when they meet certain predefined criteria while using the platform.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
This project is concerned with two preliminary badges — &amp;quot;Good Reviewer&amp;quot; and &amp;quot;Good Teammate&amp;quot; — but the design will be such that the badging system can be easily extended to include more badges in the future.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
Per the full project topic description, the badges will be designed using [https://credly.com Credly].&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
Previous work on this project topic revealed that any text included on the badges is too small to read, so all text should be removed from the badges and instead appear when the badges are hovered over.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
The &amp;quot;Good Reviewer&amp;quot; badge will be awarded to students who receive very high review grades.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
The &amp;quot;Good Teammate&amp;quot; badge will be awarded to team members who receive very high teammate review scores.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
By default, the &amp;quot;threshold&amp;quot; for earning these badges will be set to a score of 95, but this value will be configurable on a per-assignment basis by the instructor.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
A new &amp;quot;Badges&amp;quot; tab will be added for instructors on the &amp;quot;Edit Assignment&amp;quot; page where instructors can add badges and configure the badge criteria for a given assignment.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
Badges a student has earned can be seen when they view their &amp;quot;Task List&amp;quot; page, and an instructor will be able to view all badges earned by students when they view the &amp;quot;Participants List&amp;quot; page.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
Please refer to the &amp;quot;Preliminary Mocks&amp;quot; section below for further detail.&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Project Requirements&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
1. Create badges using Credly (do not include text)&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;1.1. Create the &amp;quot;Good Reviewer&amp;quot; Badge&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;1.2. Create the &amp;quot;Good Teammate&amp;quot; Badge&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;1.3. Store these badge images in the &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;app/assets/images/badges&amp;lt;/span&amp;gt; directory&lt;br /&gt;
&lt;br /&gt;
2. Create tables for the badging system&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.1. Create a table named &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;badges&amp;lt;/span&amp;gt; with the following attributes&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.1.1. &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;id&amp;lt;/span&amp;gt; — &amp;lt;em&amp;gt;primary key&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.1.2. &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;name&amp;lt;/span&amp;gt; — &amp;lt;em&amp;gt;varchar&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.1.3. &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;description&amp;lt;/span&amp;gt; — &amp;lt;em&amp;gt;varchar&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.2. Create a mapping table named &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;assignment_badges&amp;lt;/span&amp;gt; with the following attributes&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.2.1 &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;id&amp;lt;/span&amp;gt; — &amp;lt;em&amp;gt;primary key&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.2.2 &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;badge_id&amp;lt;/span&amp;gt; — &amp;lt;em&amp;gt;foreign key&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.2.3 &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;assignment_id&amp;lt;/span&amp;gt; — &amp;lt;em&amp;gt;foreign key&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.2.4 &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;threshold&amp;lt;/span&amp;gt; — &amp;lt;em&amp;gt;int&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.3. Create a mapping table named &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;awarded_badges&amp;lt;/span&amp;gt; with the following attributes&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.3.1. &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;id&amp;lt;/span&amp;gt; — primary key&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.3.2. &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;badge_id&amp;lt;/span&amp;gt; — foreign key&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.3.3. &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;participant_id&amp;lt;/span&amp;gt; — foreign key&lt;br /&gt;
&lt;br /&gt;
3. Change the UI so that instructors can add and configure badges, and students can view their badges&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;3.1. Add a new &amp;quot;Badges&amp;quot; tab to the &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;assignments/edit&amp;lt;/span&amp;gt; page&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;3.2. Add badge icons to the &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;student_task/list&amp;lt;/span&amp;gt; page for students to view&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;3.3. Add badge icons to the &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;participants/list&amp;lt;/span&amp;gt; page for instructors to view&lt;br /&gt;
&lt;br /&gt;
4. Write feature tests to verify the modifications&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;4.1. Include tests in the a new &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;badge_system_spec.rb&amp;lt;/span&amp;gt; file in the &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;spec/features&amp;lt;/span&amp;gt; directory&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Preliminary Mocks&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[File:Badge-Good-Reviewer-Small.png|none|frame|Good Reviewer Badge]]&lt;br /&gt;
&lt;br /&gt;
[[File:Badge-Good-Teammate-Small.png|none|frame|Good Teammate Badge]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Overview of Work Completed&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Testing&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Files Modified&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;New Files&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Edited Files&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;References&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Videos summarizing the previous team's work on this project topic can be found  [https://www.youtube.com/playlist?list=PLdDBHYYDZueeGNdQtzS2FfI-eC0-SK6cb here].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Problem Statement=&lt;br /&gt;
To create a simple badging system for Expertiza such that the students can be badged when certain criteria are matched.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Badging feature allows students to be badged on expertiza based on the matching of certain criteria. ‘Good Reviewer’ and ‘Good Teammate’ badges can be given to students based on the scores given to them by instructors or the other teammates.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;A ‘Good Reviewer’ badge is assigned when a student gets review score of more than a particular threshold or more than 95 by default. &lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Similarly, a 'Good teammate' badge is assigned when the teammate review score is greater than a particular threshold, defaulted to 95.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;The criterion to receive the badges are configurable for the instructors and can be changed for different tasks and assignments.&lt;br /&gt;
&lt;br /&gt;
=Requirement Specification=&lt;br /&gt;
&lt;br /&gt;
1. Creating badges for 'Good Reviewer' and 'Good Teammate'.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;2. Create a table named “badges” where the badges and their description can be stored.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;3. Create a mapping table named “assignment_badges”, for mapping badges with assignments and storing the specific thresholds&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;4. Create a mapping table named “awarded_badges”, to map student with badges.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;5. Providing means to configure the badging criteria by adding 'Calibration' tab in Assignments/edit page.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;6. Adding badges in student/task list to allow the viewing of badges associated with students.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;7. Adding badges to participants/list for an instructor to view.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;8. Implement feature tests to verify the new feature addition.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;9. Adding hover feature on each badge to allow the viewer to read the description of the badge without taking up column width or height.&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17A2_Lightweight_Badging_System&amp;diff=112689</id>
		<title>CSC/ECE 517 Fall 2017/E17A2 Lightweight Badging System</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E17A2_Lightweight_Badging_System&amp;diff=112689"/>
		<updated>2017-11-08T05:24:11Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Requirement Specification */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__TOC__&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Team Contact&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Priyanka Jain: [mailto:pjain15@ncsu.edu pjain15@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Zhewei Hu: [mailto:zhu6@ncsu.edu zhu6@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Project Description&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;strong&amp;gt;The full project topic description can be found [https://docs.google.com/document/d/1WYiXxhYyycp9a3I0GTC-4KFgHrg65Tf27ijJNQvxhmk/edit#heading=h.u6i7q1mdz0zl here]&amp;lt;/strong&amp;gt;.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
The goal of this project is to create a simple badging system for Expertiza, allowing students to earn badges when they meet certain predefined criteria while using the platform.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
This project is concerned with two preliminary badges — &amp;quot;Good Reviewer&amp;quot; and &amp;quot;Good Teammate&amp;quot; — but the design will be such that the badging system can be easily extended to include more badges in the future.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
Per the full project topic description, the badges will be designed using [https://credly.com Credly].&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
Previous work on this project topic revealed that any text included on the badges is too small to read, so all text should be removed from the badges and instead appear when the badges are hovered over.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
The &amp;quot;Good Reviewer&amp;quot; badge will be awarded to students who receive very high review grades.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
The &amp;quot;Good Teammate&amp;quot; badge will be awarded to team members who receive very high teammate review scores.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
By default, the &amp;quot;threshold&amp;quot; for earning these badges will be set to a score of 95, but this value will be configurable on a per-assignment basis by the instructor.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
A new &amp;quot;Badges&amp;quot; tab will be added for instructors on the &amp;quot;Edit Assignment&amp;quot; page where instructors can add badges and configure the badge criteria for a given assignment.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
Badges a student has earned can be seen when they view their &amp;quot;Task List&amp;quot; page, and an instructor will be able to view all badges earned by students when they view the &amp;quot;Participants List&amp;quot; page.&lt;br /&gt;
&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt;&lt;br /&gt;
Please refer to the &amp;quot;Preliminary Mocks&amp;quot; section below for further detail.&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Project Requirements&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
1. Create badges using Credly (do not include text)&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;1.1. Create the &amp;quot;Good Reviewer&amp;quot; Badge&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;1.2. Create the &amp;quot;Good Teammate&amp;quot; Badge&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;1.3. Store these badge images in the &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;app/assets/images/badges&amp;lt;/span&amp;gt; directory&lt;br /&gt;
&lt;br /&gt;
2. Create tables for the badging system&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.1. Create a table named &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;badges&amp;lt;/span&amp;gt; with the following attributes&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.1.1. &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;id&amp;lt;/span&amp;gt; — &amp;lt;em&amp;gt;primary key&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.1.2. &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;name&amp;lt;/span&amp;gt; — &amp;lt;em&amp;gt;varchar&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.1.3. &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;description&amp;lt;/span&amp;gt; — &amp;lt;em&amp;gt;varchar&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.2. Create a mapping table named &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;assignment_badges&amp;lt;/span&amp;gt; with the following attributes&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.2.1 &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;id&amp;lt;/span&amp;gt; — &amp;lt;em&amp;gt;primary key&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.2.2 &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;badge_id&amp;lt;/span&amp;gt; — &amp;lt;em&amp;gt;foreign key&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.2.3 &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;assignment_id&amp;lt;/span&amp;gt; — &amp;lt;em&amp;gt;foreign key&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.2.4 &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;threshold&amp;lt;/span&amp;gt; — &amp;lt;em&amp;gt;int&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.3. Create a mapping table named &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;awarded_badges&amp;lt;/span&amp;gt; with the following attributes&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.3.1. &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;id&amp;lt;/span&amp;gt; — primary key&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.3.2. &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;badge_id&amp;lt;/span&amp;gt; — foreign key&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;2.3.3. &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;participant_id&amp;lt;/span&amp;gt; — foreign key&lt;br /&gt;
&lt;br /&gt;
3. Change the UI so that instructors can add and configure badges, and students can view their badges&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;3.1. Add a new &amp;quot;Badges&amp;quot; tab to the &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;assignments/edit&amp;lt;/span&amp;gt; page&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;3.2. Add badge icons to the &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;student_task/list&amp;lt;/span&amp;gt; page for students to view&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;3.3. Add badge icons to the &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;participants/list&amp;lt;/span&amp;gt; page for instructors to view&lt;br /&gt;
&lt;br /&gt;
4. Write feature tests to verify the modifications&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;4.1. Include tests in the a new &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;badge_system_spec.rb&amp;lt;/span&amp;gt; file in the &amp;lt;span style=&amp;quot;font-family: menlo; color: cornflowerblue&amp;quot;&amp;gt;spec/features&amp;lt;/span&amp;gt; directory&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Preliminary Mocks&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[File:Badge-Good-Reviewer-Small.png|none|frame|Good Reviewer Badge]]&lt;br /&gt;
&lt;br /&gt;
[[File:Badge-Good-Teammate-Small.png|none|frame|Good Teammate Badge]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Overview of Work Completed&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Testing&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Files Modified&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;New Files&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;Edited Files&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= &amp;lt;em&amp;gt;&amp;lt;strong&amp;gt;References&amp;lt;/strong&amp;gt;&amp;lt;/em&amp;gt; =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 10px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Videos summarizing the previous team's work on this project topic can be found  [https://www.youtube.com/playlist?list=PLdDBHYYDZueeGNdQtzS2FfI-eC0-SK6cb here].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Problem Statement=&lt;br /&gt;
&lt;br /&gt;
To create a simple badging system for Expertiza such that the students can be badged when certain criteria are matched.&lt;br /&gt;
&lt;br /&gt;
Badging feature allows students to be badged on expertiza based on the matching of certain criteria. ‘Good Reviewer’ and ‘Good Teammate’ badges can be given to students based on the scores given to them by instructors or the other teammates.&lt;br /&gt;
 &lt;br /&gt;
A ‘Good Reviewer’ badge is assigned when a student gets review score of more than a particular threshold or more than 95 by default. &lt;br /&gt;
Similarly, a 'Good teammate' badge is assigned when the teammate review score is greater than a particular threshold, defaulted to 95.&lt;br /&gt;
The criterion to receive the badges are configurable for the instructors and can be changed for different tasks and assignments.&lt;br /&gt;
&lt;br /&gt;
=Requirement Specification=&lt;br /&gt;
&lt;br /&gt;
1. Creating badges for 'Good Reviewer' and 'Good Teammate'.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;2. Create a table named “badges” where the badges and their description can be stored.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;3. Create a mapping table named “assignment_badges”, for mapping badges with assignments and storing the specific thresholds&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;4. Create a mapping table named “awarded_badges”, to map student with badges.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;5. Providing means to configure the badging criteria by adding 'Calibration' tab in Assignments/edit page.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;6. Adding badges in student/task list to allow the viewing of badges associated with students.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;7. Adding badges to participants/list for an instructor to view.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;8. Implement feature tests to verify the new feature addition.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;9. Adding hover feature on each badge to allow the viewer to read the description of the badge without taking up column width or height.&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111264</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111264"/>
		<updated>2017-11-02T18:43:39Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Plan of Work and Implementation Process */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source web application devloped on the Ruby on Rails platform that helps students to create reusable learning objects through peer review, and also supports document submission and team projects.&lt;br /&gt;
&lt;br /&gt;
Expertiza includes several variations of import functionality, and allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewers (reviewing contributors to assignments).&lt;br /&gt;
* A list of meta-reviewers (reviewing reviewers).&lt;br /&gt;
&amp;lt;!-- * A list of topics for an existing assignment --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing rows of data, with each individual value of a row separated by a given delimiter.&lt;br /&gt;
&lt;br /&gt;
Expertiza allows four specifications for delimiters:&lt;br /&gt;
&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other (any custom delimiter provided by the user as text)&lt;br /&gt;
&lt;br /&gt;
All of these import functions are routed through the Import File Controller, which is responsible for parsing file data and delegating the import process to the appropriate model.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza-based OSS project which deals primarily with the Import File Controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110], detailed on the Expertiza Github. A significant problem with the existing import functions is that they are not implemented consistently, and there are rigid restrictions placed on how the columns should be ordered in the given import files. In the current implementation, rows are taken is arrays, with the column numbers of specific fields hard-coded into the helper methods for different imports. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly interface so that users can easily and reliably take advantage of Expertiza's various import functions.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue, we have enhanced the interface and the import process, keeping the core methods of import intact, but expanding its functionality to increase its reliability, robustness, and ease-of-use. In the new interface, the system will display what will be imported in an easy-to-read grid before the import is finalized, letting the user verify the correctness of the data and, if necessary, choose from a dropdown menu which columns need to be rearranged. The default ordering is the same as what is currently required by Expertiza, unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
In our implementation of the import method, we have made the use of hash data structure. During the import process, we create an array of hashes, in which each row of the array corresponds to a row of the original import file. In each hash, keys refer to the field name, and values refer to the actual value of that field that will be saved to the database. This greatly improved the flexibility of the import process, since the order of the data in the import files is no longer required to be in one specific order only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Test Plan and Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== User Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the User model with several varying examples, and also demonstrates that the original error messaging system is preserved with our new implementation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assigment Participant and Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Participant and Course Participant models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team and Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/JFX4VZItSyQ Team Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Team and Course Team models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Reviewer and Meta-reviewer Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/01XV12nygLE Review Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Review Response Map and Metareview Response Map models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Plan of Work and Implementation Process =&lt;br /&gt;
&lt;br /&gt;
In this project we have tried to make the import process more flexible. As stated in the previous section, in the old implementation, user had to import the files with restriction to the order of columns required. We tried to make this process flexible for the user, so that user is able to easily specify the order of columns using drop down menus.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is view used for the previous implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is the view with our implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
On the code side of imports, we have improved the implementation significantly. Previously, the import process used hard coded index values to retrieve specific columns from the import file -&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    user = User.find_by_name(row[0])&lt;br /&gt;
&lt;br /&gt;
    if user.nil?&lt;br /&gt;
      attributes = ImportFileHelper.define_attributes(row)&lt;br /&gt;
      user = ImportFileHelper.create_new_user(attributes, session)&lt;br /&gt;
      password = user.reset_password # the password is reset&lt;br /&gt;
      MailerHelper.send_mail_to_user(user, &amp;quot;Your Expertiza account has been created.&amp;quot;, &amp;quot;user_welcome&amp;quot;, password).deliver&lt;br /&gt;
    else&lt;br /&gt;
      user.email = row[2].strip                                      # ***** Use of hard-coded index values *****&lt;br /&gt;
      user.fullname = row[1].strip&lt;br /&gt;
      user.parent_id = (session[:user]).id&lt;br /&gt;
      user.save&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This was the reason why columns were needed to be in a restricted order. But in our approach, we divide the rows of data provided in import files into hashes. Accessing data from hashes is flexible as we just need the keys to access certain values which we specify during our import process and thus we know ,before hand, what key to use to access a specific value whenever needed. Following is a snippet from the &amp;quot;User.rb&amp;quot; to demonstrate our usage of hash.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    user = User.find_by_name(row_hash[:name])&lt;br /&gt;
&lt;br /&gt;
    if user.nil?&lt;br /&gt;
      attributes = ImportFileHelper.define_attributes(row_hash)&lt;br /&gt;
      user = ImportFileHelper.create_new_user(attributes, session)&lt;br /&gt;
      password = user.reset_password&lt;br /&gt;
      MailerHelper.send_mail_to_user(user, &amp;quot;Your Expertiza account has been created.&amp;quot;, &amp;quot;user_welcome&amp;quot;, password).deliver&lt;br /&gt;
    else&lt;br /&gt;
      user.email = row_hash[:email]                                  # ***** No hard-coded index values required *****&lt;br /&gt;
      user.fullname = row_hash[:fullname]                            # ***** Direct use of field name for setting up user parameters for import *****&lt;br /&gt;
      user.parent_id = (session[:user]).id&lt;br /&gt;
      user.save&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The import process in the previous implementation imports is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on this view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_file&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the error which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* &amp;quot;import_file&amp;quot; converts the data from import file into a multidimensional array in which each row represents a row from the import file. Following is an example -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[  [ 'name','fullname','email ],&lt;br /&gt;
   [ 'ppatel16','Pushpendra Patel','ppatel@ncsu.edu' ],&lt;br /&gt;
   [ 'tkothar','Tanay Kothari','tkothar@ncsu.edu' ],&lt;br /&gt;
   [ 'tmdement','Timothy Dement','tmdement@ncsu.edu' ] ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
	 &lt;br /&gt;
*This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
Import process of using our implementation is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* When user submits the options to import,  the file is parsed row-by-row. It is divided into a &amp;quot;header&amp;quot; which contains the column names and a &amp;quot;body&amp;quot; which contains all the data to be imported in form of a multi-dimensional array.&lt;br /&gt;
* &amp;quot;show&amp;quot; action of the Import File controller is called and user is redirected to &amp;quot;show&amp;quot; view the same controller. On this view user can use drop downs to select which field of the import data is which.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on the &amp;quot;show&amp;quot; view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_from_hash&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the errors which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* In the &amp;quot;import_from_hash&amp;quot; method, each row of the multidimensional array (body) is converted from into a hash. Following is an example of such a converted hash -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[  { :name =&amp;gt; 'ppatel16',&lt;br /&gt;
     :fullname =&amp;gt; 'Pushpendra Patel',&lt;br /&gt;
     :email =&amp;gt; 'ppatel16@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tkothar',&lt;br /&gt;
     :fullname =&amp;gt; 'Tanay Kothari',&lt;br /&gt;
     :email =&amp;gt; 'tkothar@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tmdement',&lt;br /&gt;
     :fullname =&amp;gt; 'Timothy Dement',&lt;br /&gt;
     :email =&amp;gt; 'tmdement@ncsu.edu } ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
We have also fixed the ''checkIfFileExist()'' method so that if the user doesn't select the file and click on import button it gives him/her an error stating that &amp;quot;No file has been selected to import&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111263</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111263"/>
		<updated>2017-11-02T18:41:20Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Plan of Work and Implementation Process */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source web application devloped on the Ruby on Rails platform that helps students to create reusable learning objects through peer review, and also supports document submission and team projects.&lt;br /&gt;
&lt;br /&gt;
Expertiza includes several variations of import functionality, and allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewers (reviewing contributors to assignments).&lt;br /&gt;
* A list of meta-reviewers (reviewing reviewers).&lt;br /&gt;
&amp;lt;!-- * A list of topics for an existing assignment --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing rows of data, with each individual value of a row separated by a given delimiter.&lt;br /&gt;
&lt;br /&gt;
Expertiza allows four specifications for delimiters:&lt;br /&gt;
&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other (any custom delimiter provided by the user as text)&lt;br /&gt;
&lt;br /&gt;
All of these import functions are routed through the Import File Controller, which is responsible for parsing file data and delegating the import process to the appropriate model.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza-based OSS project which deals primarily with the Import File Controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110], detailed on the Expertiza Github. A significant problem with the existing import functions is that they are not implemented consistently, and there are rigid restrictions placed on how the columns should be ordered in the given import files. In the current implementation, rows are taken is arrays, with the column numbers of specific fields hard-coded into the helper methods for different imports. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly interface so that users can easily and reliably take advantage of Expertiza's various import functions.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue, we have enhanced the interface and the import process, keeping the core methods of import intact, but expanding its functionality to increase its reliability, robustness, and ease-of-use. In the new interface, the system will display what will be imported in an easy-to-read grid before the import is finalized, letting the user verify the correctness of the data and, if necessary, choose from a dropdown menu which columns need to be rearranged. The default ordering is the same as what is currently required by Expertiza, unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
In our implementation of the import method, we have made the use of hash data structure. During the import process, we create an array of hashes, in which each row of the array corresponds to a row of the original import file. In each hash, keys refer to the field name, and values refer to the actual value of that field that will be saved to the database. This greatly improved the flexibility of the import process, since the order of the data in the import files is no longer required to be in one specific order only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Test Plan and Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== User Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the User model with several varying examples, and also demonstrates that the original error messaging system is preserved with our new implementation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assigment Participant and Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Participant and Course Participant models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team and Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/JFX4VZItSyQ Team Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Team and Course Team models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Reviewer and Meta-reviewer Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/01XV12nygLE Review Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Review Response Map and Metareview Response Map models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Plan of Work and Implementation Process =&lt;br /&gt;
&lt;br /&gt;
In this project we have tried to make the import process more flexible. As stated in the previous section, in the old implementation, user had to import the files with restriction to the order of columns required. We tried to make this process flexible for the user, so that user is able to easily specify the order of columns using drop down menus.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is view used for the previous implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is the view with our implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
On the code side of imports, we have improved the implementation significantly. Previously, the import process used hard coded index values to retrieve specific columns from the import file -&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    user = User.find_by_name(row[0])&lt;br /&gt;
&lt;br /&gt;
    if user.nil?&lt;br /&gt;
      attributes = ImportFileHelper.define_attributes(row)&lt;br /&gt;
      user = ImportFileHelper.create_new_user(attributes, session)&lt;br /&gt;
      password = user.reset_password # the password is reset&lt;br /&gt;
      MailerHelper.send_mail_to_user(user, &amp;quot;Your Expertiza account has been created.&amp;quot;, &amp;quot;user_welcome&amp;quot;, password).deliver&lt;br /&gt;
    else&lt;br /&gt;
      user.email = row[2].strip                                      # ***** Use of hard-coded index values *****&lt;br /&gt;
      user.fullname = row[1].strip&lt;br /&gt;
      user.parent_id = (session[:user]).id&lt;br /&gt;
      user.save&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This was the reason why columns were needed to be in a restricted order. But in our approach, we divide the rows of data provided in import files into hashes. Accessing data from hashes is flexible as we just need the keys to access certain values which we specify during our import process and thus we know ,before hand, what key to use to access a specific value whenever needed. Following is a snippet from the &amp;quot;User.rb&amp;quot; to demonstrate our usage of hash.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    user = User.find_by_name(row_hash[:name])&lt;br /&gt;
&lt;br /&gt;
    if user.nil?&lt;br /&gt;
      attributes = ImportFileHelper.define_attributes(row_hash)&lt;br /&gt;
      user = ImportFileHelper.create_new_user(attributes, session)&lt;br /&gt;
      password = user.reset_password&lt;br /&gt;
      MailerHelper.send_mail_to_user(user, &amp;quot;Your Expertiza account has been created.&amp;quot;, &amp;quot;user_welcome&amp;quot;, password).deliver&lt;br /&gt;
    else&lt;br /&gt;
      user.email = row_hash[:email]                                  # ***** No hard-coded index values required *****&lt;br /&gt;
      user.fullname = row_hash[:fullname]                            # ***** Direct use of field name for setting up user parameters for import *****&lt;br /&gt;
      user.parent_id = (session[:user]).id&lt;br /&gt;
      user.save&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The import process in the previous implementation of &amp;quot;User&amp;quot; imports is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on this view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_file&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the error which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* &amp;quot;import_file&amp;quot; converts the data from import file into a multidimensional array in which each row represents a row from the import file. Following is an example -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[  [ 'name','fullname','email ],&lt;br /&gt;
   [ 'ppatel16','Pushpendra Patel','ppatel@ncsu.edu' ],&lt;br /&gt;
   [ 'tkothar','Tanay Kothari','tkothar@ncsu.edu' ],&lt;br /&gt;
   [ 'tmdement','Timothy Dement','tmdement@ncsu.edu' ] ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
	 &lt;br /&gt;
*This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
Import process of &amp;quot;Users&amp;quot; using our implementation is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* When user submits the options to import,  the file is parsed row-by-row. It is divided into a &amp;quot;header&amp;quot; which contains the column names and a &amp;quot;body&amp;quot; which contains all the data to be imported in form of a multi-dimensional array.&lt;br /&gt;
* &amp;quot;show&amp;quot; action of the Import File controller is called and user is redirected to &amp;quot;show&amp;quot; view the same controller. On this view user can use drop downs to select which field of the import data is which.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on the &amp;quot;show&amp;quot; view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_from_hash&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the errors which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* In the &amp;quot;import_from_hash&amp;quot; method, each row of the multidimensional array (body) is converted from into a hash. Following is an example of such a converted hash -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[  { :name =&amp;gt; 'ppatel16',&lt;br /&gt;
     :fullname =&amp;gt; 'Pushpendra Patel',&lt;br /&gt;
     :email =&amp;gt; 'ppatel16@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tkothar',&lt;br /&gt;
     :fullname =&amp;gt; 'Tanay Kothari',&lt;br /&gt;
     :email =&amp;gt; 'tkothar@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tmdement',&lt;br /&gt;
     :fullname =&amp;gt; 'Timothy Dement',&lt;br /&gt;
     :email =&amp;gt; 'tmdement@ncsu.edu } ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
We have also fixed the ''checkIfFileExist()'' method so that if the user doesn't select the file and click on import button it gives him/her an error stating that &amp;quot;No file has been selected to import&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111262</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111262"/>
		<updated>2017-11-02T18:40:04Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Plan of Work and Implementation Process */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source web application devloped on the Ruby on Rails platform that helps students to create reusable learning objects through peer review, and also supports document submission and team projects.&lt;br /&gt;
&lt;br /&gt;
Expertiza includes several variations of import functionality, and allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewers (reviewing contributors to assignments).&lt;br /&gt;
* A list of meta-reviewers (reviewing reviewers).&lt;br /&gt;
&amp;lt;!-- * A list of topics for an existing assignment --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing rows of data, with each individual value of a row separated by a given delimiter.&lt;br /&gt;
&lt;br /&gt;
Expertiza allows four specifications for delimiters:&lt;br /&gt;
&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other (any custom delimiter provided by the user as text)&lt;br /&gt;
&lt;br /&gt;
All of these import functions are routed through the Import File Controller, which is responsible for parsing file data and delegating the import process to the appropriate model.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza-based OSS project which deals primarily with the Import File Controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110], detailed on the Expertiza Github. A significant problem with the existing import functions is that they are not implemented consistently, and there are rigid restrictions placed on how the columns should be ordered in the given import files. In the current implementation, rows are taken is arrays, with the column numbers of specific fields hard-coded into the helper methods for different imports. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly interface so that users can easily and reliably take advantage of Expertiza's various import functions.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue, we have enhanced the interface and the import process, keeping the core methods of import intact, but expanding its functionality to increase its reliability, robustness, and ease-of-use. In the new interface, the system will display what will be imported in an easy-to-read grid before the import is finalized, letting the user verify the correctness of the data and, if necessary, choose from a dropdown menu which columns need to be rearranged. The default ordering is the same as what is currently required by Expertiza, unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
In our implementation of the import method, we have made the use of hash data structure. During the import process, we create an array of hashes, in which each row of the array corresponds to a row of the original import file. In each hash, keys refer to the field name, and values refer to the actual value of that field that will be saved to the database. This greatly improved the flexibility of the import process, since the order of the data in the import files is no longer required to be in one specific order only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Test Plan and Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== User Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the User model with several varying examples, and also demonstrates that the original error messaging system is preserved with our new implementation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assigment Participant and Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Participant and Course Participant models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team and Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/JFX4VZItSyQ Team Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Team and Course Team models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Reviewer and Meta-reviewer Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/01XV12nygLE Review Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Review Response Map and Metareview Response Map models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Plan of Work and Implementation Process =&lt;br /&gt;
&lt;br /&gt;
In this project we have tried to make the import process more flexible. As stated in the previous section, in the old implementation, user had to import the files with restriction to the order of columns required. We tried to make this process flexible for the user, so that user is able to easily specify the order of columns using drop down menus.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is view used for the previous implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is the view with our implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the code side of imports, we have improved the implementation significantly. Previously, the import process used hard coded index values to retrieve specific columns from the import file -&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    user = User.find_by_name(row[0])&lt;br /&gt;
&lt;br /&gt;
    if user.nil?&lt;br /&gt;
      attributes = ImportFileHelper.define_attributes(row)&lt;br /&gt;
      user = ImportFileHelper.create_new_user(attributes, session)&lt;br /&gt;
      password = user.reset_password # the password is reset&lt;br /&gt;
      MailerHelper.send_mail_to_user(user, &amp;quot;Your Expertiza account has been created.&amp;quot;, &amp;quot;user_welcome&amp;quot;, password).deliver&lt;br /&gt;
    else&lt;br /&gt;
      user.email = row[2].strip                                      # ***** Use of hard-coded index values *****&lt;br /&gt;
      user.fullname = row[1].strip&lt;br /&gt;
      user.parent_id = (session[:user]).id&lt;br /&gt;
      user.save&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This was the reason why columns were needed to be in a restricted order. But in our approach, we divide the rows of data provided in import files into hashes. Accessing data from hashes is flexible as we just need the keys to access certain values which we specify during our import process and thus we know ,before hand, what key to use to access a specific value whenever needed. Following is a snippet from the &amp;quot;User.rb&amp;quot; to demonstrate our usage of hash.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    user = User.find_by_name(row_hash[:name])&lt;br /&gt;
&lt;br /&gt;
    if user.nil?&lt;br /&gt;
      attributes = ImportFileHelper.define_attributes(row_hash)&lt;br /&gt;
      user = ImportFileHelper.create_new_user(attributes, session)&lt;br /&gt;
      password = user.reset_password&lt;br /&gt;
      MailerHelper.send_mail_to_user(user, &amp;quot;Your Expertiza account has been created.&amp;quot;, &amp;quot;user_welcome&amp;quot;, password).deliver&lt;br /&gt;
    else&lt;br /&gt;
      user.email = row_hash[:email]                                  # ***** No hard-coded index values required *****&lt;br /&gt;
      user.fullname = row_hash[:fullname]                            # ***** Direct use of field name for setting up user parameters for import *****&lt;br /&gt;
      user.parent_id = (session[:user]).id&lt;br /&gt;
      user.save&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The import process in the previous implementation of &amp;quot;User&amp;quot; imports is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on this view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_file&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the error which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* &amp;quot;import_file&amp;quot; converts the data from import file into a multidimensional array in which each row represents a row from the import file. Following is an example -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[  [ 'name','fullname','email ],&lt;br /&gt;
   [ 'ppatel16','Pushpendra Patel','ppatel@ncsu.edu' ],&lt;br /&gt;
   [ 'tkothar','Tanay Kothari','tkothar@ncsu.edu' ],&lt;br /&gt;
   [ 'tmdement','Timothy Dement','tmdement@ncsu.edu' ] ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
	 &lt;br /&gt;
*This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
Import process of &amp;quot;Users&amp;quot; using our implementation is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* When user submits the options to import,  the file is parsed row-by-row. It is divided into a &amp;quot;header&amp;quot; which contains the column names and a &amp;quot;body&amp;quot; which contains all the data to be imported in form of a multi-dimensional array.&lt;br /&gt;
* &amp;quot;show&amp;quot; action of the Import File controller is called and user is redirected to &amp;quot;show&amp;quot; view the same controller. On this view user can use drop downs to select which field of the import data is which.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on the &amp;quot;show&amp;quot; view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_from_hash&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the errors which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* In the &amp;quot;import_from_hash&amp;quot; method, each row of the multidimensional array (body) is converted from into a hash. Following is an example of such a converted hash -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[  { :name =&amp;gt; 'ppatel16',&lt;br /&gt;
     :fullname =&amp;gt; 'Pushpendra Patel',&lt;br /&gt;
     :email =&amp;gt; 'ppatel16@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tkothar',&lt;br /&gt;
     :fullname =&amp;gt; 'Tanay Kothari',&lt;br /&gt;
     :email =&amp;gt; 'tkothar@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tmdement',&lt;br /&gt;
     :fullname =&amp;gt; 'Timothy Dement',&lt;br /&gt;
     :email =&amp;gt; 'tmdement@ncsu.edu } ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
We have also fixed the ''checkIfFileExist()'' method so that if the user doesn't select the file and click on import button it gives him/her an error stating that &amp;quot;No file has been selected to import&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111261</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111261"/>
		<updated>2017-11-02T18:37:50Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Plan of Work and Implementation Process */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source web application devloped on the Ruby on Rails platform that helps students to create reusable learning objects through peer review, and also supports document submission and team projects.&lt;br /&gt;
&lt;br /&gt;
Expertiza includes several variations of import functionality, and allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewers (reviewing contributors to assignments).&lt;br /&gt;
* A list of meta-reviewers (reviewing reviewers).&lt;br /&gt;
&amp;lt;!-- * A list of topics for an existing assignment --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing rows of data, with each individual value of a row separated by a given delimiter.&lt;br /&gt;
&lt;br /&gt;
Expertiza allows four specifications for delimiters:&lt;br /&gt;
&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other (any custom delimiter provided by the user as text)&lt;br /&gt;
&lt;br /&gt;
All of these import functions are routed through the Import File Controller, which is responsible for parsing file data and delegating the import process to the appropriate model.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza-based OSS project which deals primarily with the Import File Controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110], detailed on the Expertiza Github. A significant problem with the existing import functions is that they are not implemented consistently, and there are rigid restrictions placed on how the columns should be ordered in the given import files. In the current implementation, rows are taken is arrays, with the column numbers of specific fields hard-coded into the helper methods for different imports. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly interface so that users can easily and reliably take advantage of Expertiza's various import functions.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue, we have enhanced the interface and the import process, keeping the core methods of import intact, but expanding its functionality to increase its reliability, robustness, and ease-of-use. In the new interface, the system will display what will be imported in an easy-to-read grid before the import is finalized, letting the user verify the correctness of the data and, if necessary, choose from a dropdown menu which columns need to be rearranged. The default ordering is the same as what is currently required by Expertiza, unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
In our implementation of the import method, we have made the use of hash data structure. During the import process, we create an array of hashes, in which each row of the array corresponds to a row of the original import file. In each hash, keys refer to the field name, and values refer to the actual value of that field that will be saved to the database. This greatly improved the flexibility of the import process, since the order of the data in the import files is no longer required to be in one specific order only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Test Plan and Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== User Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the User model with several varying examples, and also demonstrates that the original error messaging system is preserved with our new implementation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assigment Participant and Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Participant and Course Participant models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team and Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/JFX4VZItSyQ Team Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Team and Course Team models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Reviewer and Meta-reviewer Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/01XV12nygLE Review Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Review Response Map and Metareview Response Map models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Plan of Work and Implementation Process =&lt;br /&gt;
&lt;br /&gt;
In this project we have tried to make the import process more flexible. As stated in the previous section, in the old implementation, user had to import the files with restriction to the order of columns required. We tried to make this process flexible for the user, so that user is able to easily specify the order of columns using drop down menus.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is view used for the previous implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is the view with our implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the code side of imports, we have improved the implementation significantly. Previously, the import process used hard coded index values to retrieve specific columns from the import file -&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    user = User.find_by_name(row[0])&lt;br /&gt;
&lt;br /&gt;
    if user.nil?&lt;br /&gt;
      attributes = ImportFileHelper.define_attributes(row)&lt;br /&gt;
      user = ImportFileHelper.create_new_user(attributes, session)&lt;br /&gt;
      password = user.reset_password # the password is reset&lt;br /&gt;
      MailerHelper.send_mail_to_user(user, &amp;quot;Your Expertiza account has been created.&amp;quot;, &amp;quot;user_welcome&amp;quot;, password).deliver&lt;br /&gt;
    else&lt;br /&gt;
      user.email = row[2].strip                                      # ***** Use of hard-coded index values *****&lt;br /&gt;
      user.fullname = row[1].strip&lt;br /&gt;
      user.parent_id = (session[:user]).id&lt;br /&gt;
      user.save&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This was the reason why columns were needed to be in a restricted order. But in our approach, we divide the rows of data provided in import files into hashes. Accessing data from hashes is flexible as we just need the keys to access certain values which we specify during our import process and thus we know ,before hand, what key to use to access a specific value whenever needed. Following is a snippet from the &amp;quot;User.rb&amp;quot; to demonstrate our usage of hash.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    user = User.find_by_name(row_hash[:name])&lt;br /&gt;
&lt;br /&gt;
    if user.nil?&lt;br /&gt;
      attributes = ImportFileHelper.define_attributes(row_hash)&lt;br /&gt;
      user = ImportFileHelper.create_new_user(attributes, session)&lt;br /&gt;
      password = user.reset_password&lt;br /&gt;
      MailerHelper.send_mail_to_user(user, &amp;quot;Your Expertiza account has been created.&amp;quot;, &amp;quot;user_welcome&amp;quot;, password).deliver&lt;br /&gt;
    else&lt;br /&gt;
      user.email = row_hash[:email]                                  # ***** No hard-coded index values required *****&lt;br /&gt;
      user.fullname = row_hash[:fullname]                            # ***** Direct use of field name for setting up user parameters for import *****&lt;br /&gt;
      user.parent_id = (session[:user]).id&lt;br /&gt;
      user.save&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The import process in the previous implementation of &amp;quot;User&amp;quot; imports is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on this view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_file&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the error which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* &amp;quot;import_file&amp;quot; converts the data from import file into a multidimensional array in which each row represents a row from the import file. Following is an example -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  [ 'name','fullname','email ]&lt;br /&gt;
  [ 'ppatel16','Pushpendra Patel','ppatel@ncsu.edu' ]&lt;br /&gt;
  [ 'tkothar','Tanay Kothari','tkothar@ncsu.edu' ]&lt;br /&gt;
  [ 'tmdement','Timothy Dement','tmdement@ncsu.edu' ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
	 &lt;br /&gt;
*This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
Import process of &amp;quot;Users&amp;quot; using our implementation is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* When user submits the options to import,  the file is parsed row-by-row. It is divided into a &amp;quot;header&amp;quot; which contains the column names and a &amp;quot;body&amp;quot; which contains all the data to be imported in form of a multi-dimensional array.&lt;br /&gt;
* &amp;quot;show&amp;quot; action of the Import File controller is called and user is redirected to &amp;quot;show&amp;quot; view the same controller. On this view user can use drop downs to select which field of the import data is which.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on the &amp;quot;show&amp;quot; view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_from_hash&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the errors which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* In the &amp;quot;import_from_hash&amp;quot; method, each row of the multidimensional array (body) is converted from into a hash. Following is an example of such a converted hash -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[  { :name =&amp;gt; 'ppatel16',&lt;br /&gt;
     :fullname =&amp;gt; 'Pushpendra Patel',&lt;br /&gt;
     :email =&amp;gt; 'ppatel16@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tkothar',&lt;br /&gt;
     :fullname =&amp;gt; 'Tanay Kothari',&lt;br /&gt;
     :email =&amp;gt; 'tkothar@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tmdement',&lt;br /&gt;
     :fullname =&amp;gt; 'Timothy Dement',&lt;br /&gt;
     :email =&amp;gt; 'tmdement@ncsu.edu } ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
We have also fixed the ''checkIfFileExist()'' method so that if the user doesn't select the file and click on import button it gives him/her an error stating that &amp;quot;No file has been selected to import&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111257</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111257"/>
		<updated>2017-11-02T18:34:12Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Plan of Work and Implementation Process */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source web application devloped on the Ruby on Rails platform that helps students to create reusable learning objects through peer review, and also supports document submission and team projects.&lt;br /&gt;
&lt;br /&gt;
Expertiza includes several variations of import functionality, and allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewers (reviewing contributors to assignments).&lt;br /&gt;
* A list of meta-reviewers (reviewing reviewers).&lt;br /&gt;
&amp;lt;!-- * A list of topics for an existing assignment --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing rows of data, with each individual value of a row separated by a given delimiter.&lt;br /&gt;
&lt;br /&gt;
Expertiza allows four specifications for delimiters:&lt;br /&gt;
&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other (any custom delimiter provided by the user as text)&lt;br /&gt;
&lt;br /&gt;
All of these import functions are routed through the Import File Controller, which is responsible for parsing file data and delegating the import process to the appropriate model.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza-based OSS project which deals primarily with the Import File Controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110], detailed on the Expertiza Github. A significant problem with the existing import functions is that they are not implemented consistently, and there are rigid restrictions placed on how the columns should be ordered in the given import files. In the current implementation, rows are taken is arrays, with the column numbers of specific fields hard-coded into the helper methods for different imports. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly interface so that users can easily and reliably take advantage of Expertiza's various import functions.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue, we have enhanced the interface and the import process, keeping the core methods of import intact, but expanding its functionality to increase its reliability, robustness, and ease-of-use. In the new interface, the system will display what will be imported in an easy-to-read grid before the import is finalized, letting the user verify the correctness of the data and, if necessary, choose from a dropdown menu which columns need to be rearranged. The default ordering is the same as what is currently required by Expertiza, unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
In our implementation of the import method, we have made the use of hash data structure. During the import process, we create an array of hashes, in which each row of the array corresponds to a row of the original import file. In each hash, keys refer to the field name, and values refer to the actual value of that field that will be saved to the database. This greatly improved the flexibility of the import process, since the order of the data in the import files is no longer required to be in one specific order only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Test Plan and Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== User Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the User model with several varying examples, and also demonstrates that the original error messaging system is preserved with our new implementation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assigment Participant and Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Participant and Course Participant models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team and Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/JFX4VZItSyQ Team Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Team and Course Team models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Reviewer and Meta-reviewer Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/01XV12nygLE Review Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Review Response Map and Metareview Response Map models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Plan of Work and Implementation Process =&lt;br /&gt;
&lt;br /&gt;
In this project we have tried to make the import process more flexible. As stated in the previous section, in the old implementation, user had to import the files with restriction to the order of columns required. We tried to make this process flexible for the user, so that user is able to easily specify the order of columns using drop down menus.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is view used for the previous implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is the view with our implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the code side of imports, we have improved the implementation significantly. Previously, the import process used hard coded index values to retrieve specific columns from the import file -&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt;Code to show hard coded index values &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This was the reason why columns were needed to be in a restricted order. But in our approach, we divide the rows of data provided in import files into hashes. Accessing data from hashes is flexible as we just need the keys to access certain values which we specify during our import process and thus we know ,before hand, what key to use to access a specific value whenever needed. Following is a snippet from the &amp;quot;User.rb&amp;quot; to demonstrate our usage of hash.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    user = User.find_by_name(row_hash[:name])&lt;br /&gt;
&lt;br /&gt;
    if user.nil?&lt;br /&gt;
      attributes = ImportFileHelper.define_attributes(row_hash)&lt;br /&gt;
      user = ImportFileHelper.create_new_user(attributes, session)&lt;br /&gt;
      password = user.reset_password&lt;br /&gt;
      MailerHelper.send_mail_to_user(user, &amp;quot;Your Expertiza account has been created.&amp;quot;, &amp;quot;user_welcome&amp;quot;, password).deliver&lt;br /&gt;
    else&lt;br /&gt;
      user.email = row_hash[:email]                                  # ***** No hard-coded index values required *****&lt;br /&gt;
      user.fullname = row_hash[:fullname]                            # ***** Direct use of field name for setting up user parameters for import *****&lt;br /&gt;
      user.parent_id = (session[:user]).id&lt;br /&gt;
      user.save&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The import process in the previous implementation of &amp;quot;User&amp;quot; imports is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on this view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_file&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the error which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* &amp;quot;import_file&amp;quot; converts the data from import file into a multidimensional array in which each row represents a row from the import file. Following is an example -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  [ 'name','fullname','email ]&lt;br /&gt;
  [ 'ppatel16','Pushpendra Patel','ppatel@ncsu.edu' ]&lt;br /&gt;
  [ 'tkothar','Tanay Kothari','tkothar@ncsu.edu' ]&lt;br /&gt;
  [ 'tmdement','Timothy Dement','tmdement@ncsu.edu' ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
	 &lt;br /&gt;
*This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
Import process of &amp;quot;Users&amp;quot; using our implementation is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* When user submits the options to import,  the file is parsed row-by-row. It is divided into a &amp;quot;header&amp;quot; which contains the column names and a &amp;quot;body&amp;quot; which contains all the data to be imported in form of a multi-dimensional array.&lt;br /&gt;
* &amp;quot;show&amp;quot; action of the Import File controller is called and user is redirected to &amp;quot;show&amp;quot; view the same controller. On this view user can use drop downs to select which field of the import data is which.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on the &amp;quot;show&amp;quot; view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_from_hash&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the errors which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* In the &amp;quot;import_from_hash&amp;quot; method, each row of the multidimensional array (body) is converted from into a hash. Following is an example of such a converted hash -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[  { :name =&amp;gt; 'ppatel16',&lt;br /&gt;
     :fullname =&amp;gt; 'Pushpendra Patel',&lt;br /&gt;
     :email =&amp;gt; 'ppatel16@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tkothar',&lt;br /&gt;
     :fullname =&amp;gt; 'Tanay Kothari',&lt;br /&gt;
     :email =&amp;gt; 'tkothar@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tmdement',&lt;br /&gt;
     :fullname =&amp;gt; 'Timothy Dement',&lt;br /&gt;
     :email =&amp;gt; 'tmdement@ncsu.edu } ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
We have also fixed the ''checkIfFileExist()'' method so that if the user doesn't select the file and click on import button it gives him/her an error stating that &amp;quot;No file has been selected to import&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111256</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111256"/>
		<updated>2017-11-02T18:27:51Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Plan of Work and Implementation Process */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source web application devloped on the Ruby on Rails platform that helps students to create reusable learning objects through peer review, and also supports document submission and team projects.&lt;br /&gt;
&lt;br /&gt;
Expertiza includes several variations of import functionality, and allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewers (reviewing contributors to assignments).&lt;br /&gt;
* A list of meta-reviewers (reviewing reviewers).&lt;br /&gt;
&amp;lt;!-- * A list of topics for an existing assignment --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing rows of data, with each individual value of a row separated by a given delimiter.&lt;br /&gt;
&lt;br /&gt;
Expertiza allows four specifications for delimiters:&lt;br /&gt;
&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other (any custom delimiter provided by the user as text)&lt;br /&gt;
&lt;br /&gt;
All of these import functions are routed through the Import File Controller, which is responsible for parsing file data and delegating the import process to the appropriate model.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza-based OSS project which deals primarily with the Import File Controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110], detailed on the Expertiza Github. A significant problem with the existing import functions is that they are not implemented consistently, and there are rigid restrictions placed on how the columns should be ordered in the given import files. In the current implementation, rows are taken is arrays, with the column numbers of specific fields hard-coded into the helper methods for different imports. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly interface so that users can easily and reliably take advantage of Expertiza's various import functions.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue, we have enhanced the interface and the import process, keeping the core methods of import intact, but expanding its functionality to increase its reliability, robustness, and ease-of-use. In the new interface, the system will display what will be imported in an easy-to-read grid before the import is finalized, letting the user verify the correctness of the data and, if necessary, choose from a dropdown menu which columns need to be rearranged. The default ordering is the same as what is currently required by Expertiza, unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
In our implementation of the import method, we have made the use of hash data structure. During the import process, we create an array of hashes, in which each row of the array corresponds to a row of the original import file. In each hash, keys refer to the field name, and values refer to the actual value of that field that will be saved to the database. This greatly improved the flexibility of the import process, since the order of the data in the import files is no longer required to be in one specific order only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Test Plan and Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== User Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the User model with several varying examples, and also demonstrates that the original error messaging system is preserved with our new implementation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assigment Participant and Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Participant and Course Participant models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team and Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/JFX4VZItSyQ Team Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Team and Course Team models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Reviewer and Meta-reviewer Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/01XV12nygLE Review Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Review Response Map and Metareview Response Map models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Plan of Work and Implementation Process =&lt;br /&gt;
&lt;br /&gt;
In this project we have tried to make the import process more flexible. As stated in the previous section, in the old implementation, user had to import the files with restriction to the order of columns required. We tried to make this process flexible for the user, so that user is able to easily specify the order of columns using drop down menus.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is view used for the previous implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is the view with our implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the code side of imports, we have improved the implementation significantly. Previously, the import process used hard coded index values to retrieve specific columns from the import file -&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt;Code to show hard coded index values &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This was the reason why columns were needed to be in a restricted order. But in our approach, we divide the rows of data provided in import files into hashes. Accessing data from hashes is flexible as we just need the keys to access certain values which we specify during our import process and thus we know ,before hand, what key to use to access a specific value whenever needed.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt;Code to show hash implementation&amp;lt;/big&amp;gt;&amp;lt;/span?&lt;br /&gt;
&lt;br /&gt;
The import process in the previous implementation of &amp;quot;User&amp;quot; imports is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on this view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_file&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the error which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* &amp;quot;import_file&amp;quot; converts the data from import file into a multidimensional array in which each row represents a row from the import file. Following is an example -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  [ 'name','fullname','email ]&lt;br /&gt;
  [ 'ppatel16','Pushpendra Patel','ppatel@ncsu.edu' ]&lt;br /&gt;
  [ 'tkothar','Tanay Kothari','tkothar@ncsu.edu' ]&lt;br /&gt;
  [ 'tmdement','Timothy Dement','tmdement@ncsu.edu' ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
	 &lt;br /&gt;
*This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
Import process of &amp;quot;Users&amp;quot; using our implementation is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* When user submits the options to import,  the file is parsed row-by-row. It is divided into a &amp;quot;header&amp;quot; which contains the column names and a &amp;quot;body&amp;quot; which contains all the data to be imported in form of a multi-dimensional array.&lt;br /&gt;
* &amp;quot;show&amp;quot; action of the Import File controller is called and user is redirected to &amp;quot;show&amp;quot; view the same controller. On this view user can use drop downs to select which field of the import data is which.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on the &amp;quot;show&amp;quot; view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_from_hash&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the errors which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* In the &amp;quot;import_from_hash&amp;quot; method, each row of the multidimensional array (body) is converted from into a hash. Following is an example of such a converted hash -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[  { :name =&amp;gt; 'ppatel16',&lt;br /&gt;
     :fullname =&amp;gt; 'Pushpendra Patel',&lt;br /&gt;
     :email =&amp;gt; 'ppatel16@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tkothar',&lt;br /&gt;
     :fullname =&amp;gt; 'Tanay Kothari',&lt;br /&gt;
     :email =&amp;gt; 'tkothar@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tmdement',&lt;br /&gt;
     :fullname =&amp;gt; 'Timothy Dement',&lt;br /&gt;
     :email =&amp;gt; 'tmdement@ncsu.edu } ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
We have also fixed the ''checkIfFileExist()'' method so that if the user doesn't select the file and click on import button it gives him/her an error stating that &amp;quot;No file has been selected to import&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111255</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111255"/>
		<updated>2017-11-02T18:27:20Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Plan of Work and Implementation Process */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source web application devloped on the Ruby on Rails platform that helps students to create reusable learning objects through peer review, and also supports document submission and team projects.&lt;br /&gt;
&lt;br /&gt;
Expertiza includes several variations of import functionality, and allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewers (reviewing contributors to assignments).&lt;br /&gt;
* A list of meta-reviewers (reviewing reviewers).&lt;br /&gt;
&amp;lt;!-- * A list of topics for an existing assignment --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing rows of data, with each individual value of a row separated by a given delimiter.&lt;br /&gt;
&lt;br /&gt;
Expertiza allows four specifications for delimiters:&lt;br /&gt;
&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other (any custom delimiter provided by the user as text)&lt;br /&gt;
&lt;br /&gt;
All of these import functions are routed through the Import File Controller, which is responsible for parsing file data and delegating the import process to the appropriate model.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza-based OSS project which deals primarily with the Import File Controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110], detailed on the Expertiza Github. A significant problem with the existing import functions is that they are not implemented consistently, and there are rigid restrictions placed on how the columns should be ordered in the given import files. In the current implementation, rows are taken is arrays, with the column numbers of specific fields hard-coded into the helper methods for different imports. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly interface so that users can easily and reliably take advantage of Expertiza's various import functions.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue, we have enhanced the interface and the import process, keeping the core methods of import intact, but expanding its functionality to increase its reliability, robustness, and ease-of-use. In the new interface, the system will display what will be imported in an easy-to-read grid before the import is finalized, letting the user verify the correctness of the data and, if necessary, choose from a dropdown menu which columns need to be rearranged. The default ordering is the same as what is currently required by Expertiza, unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
In our implementation of the import method, we have made the use of hash data structure. During the import process, we create an array of hashes, in which each row of the array corresponds to a row of the original import file. In each hash, keys refer to the field name, and values refer to the actual value of that field that will be saved to the database. This greatly improved the flexibility of the import process, since the order of the data in the import files is no longer required to be in one specific order only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Test Plan and Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== User Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the User model with several varying examples, and also demonstrates that the original error messaging system is preserved with our new implementation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assigment Participant and Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Participant and Course Participant models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team and Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/JFX4VZItSyQ Team Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Team and Course Team models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Reviewer and Meta-reviewer Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/01XV12nygLE Review Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Review Response Map and Metareview Response Map models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Plan of Work and Implementation Process =&lt;br /&gt;
&lt;br /&gt;
In this project we have tried to make the import process more flexible. As stated in the previous section, in the old implementation, user had to import the files with restriction to the order of columns required. We tried to make this process flexible for the user, such that user is able to easily specify the order of columns using drop down menus.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is view used for the previous implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is the view with our implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the code side of imports, we have improved the implementation significantly. Previously, the import process used hard coded index values to retrieve specific columns from the import file -&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt;Code to show hard coded index values &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This was the reason why columns were needed to be in a restricted order. But in our approach, we divide the rows of data provided in import files into hashes. Accessing data from hashes is flexible as we just need the keys to access certain values which we specify during our import process and thus we know ,before hand, what key to use to access a specific value whenever needed.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt;Code to show hash implementation&amp;lt;/big&amp;gt;&amp;lt;/span?&lt;br /&gt;
&lt;br /&gt;
The import process in the previous implementation of &amp;quot;User&amp;quot; imports is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on this view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_file&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the error which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* &amp;quot;import_file&amp;quot; converts the data from import file into a multidimensional array in which each row represents a row from the import file. Following is an example -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  [ 'name','fullname','email ]&lt;br /&gt;
  [ 'ppatel16','Pushpendra Patel','ppatel@ncsu.edu' ]&lt;br /&gt;
  [ 'tkothar','Tanay Kothari','tkothar@ncsu.edu' ]&lt;br /&gt;
  [ 'tmdement','Timothy Dement','tmdement@ncsu.edu' ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
	 &lt;br /&gt;
*This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
Import process of &amp;quot;Users&amp;quot; using our implementation is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* When user submits the options to import,  the file is parsed row-by-row. It is divided into a &amp;quot;header&amp;quot; which contains the column names and a &amp;quot;body&amp;quot; which contains all the data to be imported in form of a multi-dimensional array.&lt;br /&gt;
* &amp;quot;show&amp;quot; action of the Import File controller is called and user is redirected to &amp;quot;show&amp;quot; view the same controller. On this view user can use drop downs to select which field of the import data is which.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on the &amp;quot;show&amp;quot; view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_from_hash&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the errors which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* In the &amp;quot;import_from_hash&amp;quot; method, each row of the multidimensional array (body) is converted from into a hash. Following is an example of such a converted hash -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[  { :name =&amp;gt; 'ppatel16',&lt;br /&gt;
     :fullname =&amp;gt; 'Pushpendra Patel',&lt;br /&gt;
     :email =&amp;gt; 'ppatel16@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tkothar',&lt;br /&gt;
     :fullname =&amp;gt; 'Tanay Kothari',&lt;br /&gt;
     :email =&amp;gt; 'tkothar@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tmdement',&lt;br /&gt;
     :fullname =&amp;gt; 'Timothy Dement',&lt;br /&gt;
     :email =&amp;gt; 'tmdement@ncsu.edu } ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
We have also fixed the ''checkIfFileExist()'' method so that if the user doesn't select the file and click on import button it gives him/her an error stating that &amp;quot;No file has been selected to import&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111253</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111253"/>
		<updated>2017-11-02T18:26:23Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Plan of Work and Implementation Process */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source web application devloped on the Ruby on Rails platform that helps students to create reusable learning objects through peer review, and also supports document submission and team projects.&lt;br /&gt;
&lt;br /&gt;
Expertiza includes several variations of import functionality, and allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewers (reviewing contributors to assignments).&lt;br /&gt;
* A list of meta-reviewers (reviewing reviewers).&lt;br /&gt;
&amp;lt;!-- * A list of topics for an existing assignment --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing rows of data, with each individual value of a row separated by a given delimiter.&lt;br /&gt;
&lt;br /&gt;
Expertiza allows four specifications for delimiters:&lt;br /&gt;
&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other (any custom delimiter provided by the user as text)&lt;br /&gt;
&lt;br /&gt;
All of these import functions are routed through the Import File Controller, which is responsible for parsing file data and delegating the import process to the appropriate model.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza-based OSS project which deals primarily with the Import File Controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110], detailed on the Expertiza Github. A significant problem with the existing import functions is that they are not implemented consistently, and there are rigid restrictions placed on how the columns should be ordered in the given import files. In the current implementation, rows are taken is arrays, with the column numbers of specific fields hard-coded into the helper methods for different imports. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly interface so that users can easily and reliably take advantage of Expertiza's various import functions.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue, we have enhanced the interface and the import process, keeping the core methods of import intact, but expanding its functionality to increase its reliability, robustness, and ease-of-use. In the new interface, the system will display what will be imported in an easy-to-read grid before the import is finalized, letting the user verify the correctness of the data and, if necessary, choose from a dropdown menu which columns need to be rearranged. The default ordering is the same as what is currently required by Expertiza, unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
In our implementation of the import method, we have made the use of hash data structure. During the import process, we create an array of hashes, in which each row of the array corresponds to a row of the original import file. In each hash, keys refer to the field name, and values refer to the actual value of that field that will be saved to the database. This greatly improved the flexibility of the import process, since the order of the data in the import files is no longer required to be in one specific order only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Test Plan and Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== User Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the User model with several varying examples, and also demonstrates that the original error messaging system is preserved with our new implementation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assigment Participant and Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Participant and Course Participant models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team and Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/JFX4VZItSyQ Team Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Team and Course Team models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Reviewer and Meta-reviewer Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/01XV12nygLE Review Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Review Response Map and Metareview Response Map models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Plan of Work and Implementation Process =&lt;br /&gt;
&lt;br /&gt;
In this project we have tried to make the import process more flexible. As stated in the previous section, in the old implementation, user had to import the files with restriction to the order of columns required. We tried to make this process flexible for the user, such that user is able to easily specify the order of columns using drop down menus.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is view used for the previous implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is the view with our implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the code side of imports, we have improved the implementation significantly. Previously, the import process used hard coded index values to retrieve specific columns from the import file -&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt;Code to show hard coded index values &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This was the reason why columns were needed to be in a restricted order. But in our approach, we divide the rows of data provided in import files into hashes. Accessing data from hashes is flexible as we just need the keys to access certain values which we specify during our import process and thus we know ,before hand, what key to use to access a specific value whenever needed.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt;Code to show hash implementation&amp;lt;/big&amp;gt;&amp;lt;/span?&lt;br /&gt;
&lt;br /&gt;
The import process in the previous implementation of &amp;quot;User&amp;quot; imports is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on this view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_file&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the error which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* &amp;quot;import_file&amp;quot; converts the data from import file into a multidimensional array in which each row represents a row from the import file. Following is an example -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  [ 'name','fullname','email ]&lt;br /&gt;
  [ 'ppatel16','Pushpendra Patel','ppatel@ncsu.edu' ]&lt;br /&gt;
  [ 'tkothar','Tanay Kothari','tkothar@ncsu.edu' ]&lt;br /&gt;
  [ 'tmdement','Timothy Dement','tmdement@ncsu.edu' ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
	 &lt;br /&gt;
*This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
Import process of &amp;quot;Users&amp;quot; using our implementation is as follows -&lt;br /&gt;
* User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
* User is redirected to &amp;quot;start&amp;quot; view of Import File controller.&lt;br /&gt;
* User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
* When user submits the options to import,  the file is parsed row-by-row. It is divided into a &amp;quot;header&amp;quot; which contains the column names and a &amp;quot;body&amp;quot; which contains all the data to be imported in form of a multi-dimensional array.&lt;br /&gt;
* &amp;quot;show&amp;quot; action of the Import File controller is called and user is redirected to &amp;quot;show&amp;quot; view the same controller. On this view user can use drop downs to select which field of the import data is which.&lt;br /&gt;
* Once the user clicks &amp;quot;Import&amp;quot; button on the &amp;quot;show&amp;quot; view, &amp;quot;import&amp;quot; method of the Import File controller is called which in turn calls the &amp;quot;import_from_hash&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the error which might be encountered during the import process and displays it to the user.&lt;br /&gt;
* In the &amp;quot;import_from_hash&amp;quot; method, each row of the multidimensional array (body) is converted from into a hash. Following is an example of such a converted hash -&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[  { :name =&amp;gt; 'ppatel16',&lt;br /&gt;
     :fullname =&amp;gt; 'Pushpendra Patel',&lt;br /&gt;
     :email =&amp;gt; 'ppatel16@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tkothar',&lt;br /&gt;
     :fullname =&amp;gt; 'Tanay Kothari',&lt;br /&gt;
     :email =&amp;gt; 'tkothar@ncsu.edu' },&lt;br /&gt;
   { :name =&amp;gt; 'tmdement',&lt;br /&gt;
     :fullname =&amp;gt; 'Timothy Dement',&lt;br /&gt;
     :email =&amp;gt; 'tmdement@ncsu.edu } ]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* This method now checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
* &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
We have also fixed the ''checkIfFileExist()'' method so that if the user doesn't select the file and click on import button it gives him/her an error stating that &amp;quot;No file has been selected to import&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111229</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111229"/>
		<updated>2017-11-02T17:53:35Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Plan of Work and Implementation Process */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source web application devloped on the Ruby on Rails platform that helps students to create reusable learning objects through peer review, and also supports document submission and team projects.&lt;br /&gt;
&lt;br /&gt;
Expertiza includes several variations of import functionality, and allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewers (reviewing contributors to assignments).&lt;br /&gt;
* A list of meta-reviewers (reviewing reviewers).&lt;br /&gt;
&amp;lt;!-- * A list of topics for an existing assignment --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing rows of data, with each individual value of a row separated by a given delimiter.&lt;br /&gt;
&lt;br /&gt;
Expertiza allows four specifications for delimiters:&lt;br /&gt;
&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other (any custom delimiter provided by the user as text)&lt;br /&gt;
&lt;br /&gt;
All of these import functions are routed through the Import File Controller, which is responsible for parsing file data and delegating the import process to the appropriate model.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza-based OSS project which deals primarily with the Import File Controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110], detailed on the Expertiza Github. A significant problem with the existing import functions is that they are not implemented consistently, and there are rigid restrictions placed on how the columns should be ordered in the given import files. In the current implementation, rows are taken is arrays, with the column numbers of specific fields hard-coded into the helper methods for different imports. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly interface so that users can easily and reliably take advantage of Expertiza's various import functions.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue, we have enhanced the interface and the import process, keeping the core methods of import intact, but expanding its functionality to increase its reliability, robustness, and ease-of-use. In the new interface, the system will display what will be imported in an easy-to-read grid before the import is finalized, letting the user verify the correctness of the data and, if necessary, choose from a dropdown menu which columns need to be rearranged. The default ordering is the same as what is currently required by Expertiza, unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
In our implementation of the import method, we have made the use of hash data structure. During the import process, we create an array of hashes, in which each row of the array corresponds to a row of the original import file. In each hash, keys refer to the field name, and values refer to the actual value of that field that will be saved to the database. This greatly improved the flexibility of the import process, since the order of the data in the import files is no longer required to be in one specific order only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Test Plan and Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== User Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the User model with several varying examples, and also demonstrates that the original error messaging system is preserved with our new implementation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assigment Participant and Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Participant and Course Participant models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team and Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/JFX4VZItSyQ Team Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Team and Course Team models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Reviewer and Meta-reviewer Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/01XV12nygLE Review Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Review Response Map and Metareview Response Map models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Plan of Work and Implementation Process =&lt;br /&gt;
&lt;br /&gt;
In this project we have tried to make the import process more flexible. As stated in the previous section, in the old implementation, user had to import the files with restriction to the order of columns required. We tried to make this process flexible for the user, such that user is able to easily specify the order of columns using drop down menus.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is view used for the previous implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is the view with our implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the code side of imports, we have improved the implementation significantly. Previously, the import process used hard coded index values to retrieve specific columns from the import file -&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt;Code to show hard coded index values &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This was the reason why columns were needed to be in a restricted order. But in our approach, we divide the rows of data provided in import files into hashes. Accessing data from hashes is flexible as we just need the keys to access certain values which we specify during our import process and thus we know ,before hand, what key to use to access a specific value whenever needed.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt;Code to show hash implementation&amp;lt;/big&amp;gt;&amp;lt;/span?&lt;br /&gt;
&lt;br /&gt;
The import process in the previous implementation is as follows -&lt;br /&gt;
# User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
# User is redirected to &amp;quot;start&amp;quot; view of import file controller.&lt;br /&gt;
# User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
# &amp;quot;import&amp;quot; method of the Import File Controller is called which in turn calls the &amp;quot;import_file&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the error which might be encountered during the import process and displays it to the user.&lt;br /&gt;
# &amp;quot;import_file&amp;quot; method checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
# &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
Import process using our implementation is as follows -&lt;br /&gt;
# User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
# User is redirected to &amp;quot;start&amp;quot; view of import file controller.&lt;br /&gt;
# User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
We have also fixed the ''checkIfFileExist()'' method so that if the user doesn't select the file and click on import button it gives him/her an error stating that &amp;quot;No file has been selected to import&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111228</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111228"/>
		<updated>2017-11-02T17:51:37Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Plan of Work and Implementation Process */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source web application devloped on the Ruby on Rails platform that helps students to create reusable learning objects through peer review, and also supports document submission and team projects.&lt;br /&gt;
&lt;br /&gt;
Expertiza includes several variations of import functionality, and allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewers (reviewing contributors to assignments).&lt;br /&gt;
* A list of meta-reviewers (reviewing reviewers).&lt;br /&gt;
&amp;lt;!-- * A list of topics for an existing assignment --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing rows of data, with each individual value of a row separated by a given delimiter.&lt;br /&gt;
&lt;br /&gt;
Expertiza allows four specifications for delimiters:&lt;br /&gt;
&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other (any custom delimiter provided by the user as text)&lt;br /&gt;
&lt;br /&gt;
All of these import functions are routed through the Import File Controller, which is responsible for parsing file data and delegating the import process to the appropriate model.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza-based OSS project which deals primarily with the Import File Controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110], detailed on the Expertiza Github. A significant problem with the existing import functions is that they are not implemented consistently, and there are rigid restrictions placed on how the columns should be ordered in the given import files. In the current implementation, rows are taken is arrays, with the column numbers of specific fields hard-coded into the helper methods for different imports. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly interface so that users can easily and reliably take advantage of Expertiza's various import functions.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue, we have enhanced the interface and the import process, keeping the core methods of import intact, but expanding its functionality to increase its reliability, robustness, and ease-of-use. In the new interface, the system will display what will be imported in an easy-to-read grid before the import is finalized, letting the user verify the correctness of the data and, if necessary, choose from a dropdown menu which columns need to be rearranged. The default ordering is the same as what is currently required by Expertiza, unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
In our implementation of the import method, we have made the use of hash data structure. During the import process, we create an array of hashes, in which each row of the array corresponds to a row of the original import file. In each hash, keys refer to the field name, and values refer to the actual value of that field that will be saved to the database. This greatly improved the flexibility of the import process, since the order of the data in the import files is no longer required to be in one specific order only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Test Plan and Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== User Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the User model with several varying examples, and also demonstrates that the original error messaging system is preserved with our new implementation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assigment Participant and Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Participant and Course Participant models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team and Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/JFX4VZItSyQ Team Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Team and Course Team models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Reviewer and Meta-reviewer Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/01XV12nygLE Review Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Review Response Map and Metareview Response Map models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Plan of Work and Implementation Process =&lt;br /&gt;
&lt;br /&gt;
In this project we have tried to make the import process more flexible. As stated in the previous section, in the old implementation, user had to import the files with restriction to the order of columns required. We tried to make this process flexible for the user, such that user is able to easily specify the order of columns using drop down menus.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is view used for the previous implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt; Here is the view with our implementation of the User Imports - &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the code side of imports, we have improved the implementation significantly. Previously, the import process used hard coded index values to retrieve specific columns from the import file -&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt;Code to show hard coded index values &amp;lt;/big&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This was the reason why columns were needed to be in a restricted order. But in our approach, we divide the rows of data provided in import files into hashes. Accessing data from hashes is flexible as we just need the keys to access certain values which we specify during our import process and thus we know ,before hand, what key to use to access a specific value whenever needed.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;&amp;lt;big&amp;gt;Code to show hash implementation&amp;lt;/big&amp;gt;&amp;lt;/span?&lt;br /&gt;
&lt;br /&gt;
The import process in the previous implementation is as follows -&lt;br /&gt;
1. User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
2. User is redirected to &amp;quot;start&amp;quot; view of import file controller.&lt;br /&gt;
3. User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
4. &amp;quot;import&amp;quot; method of the Import File Controller is called which in turn calls the &amp;quot;import_file&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the error which might be encountered during the import process and displays it to the user.&lt;br /&gt;
5. &amp;quot;import_file&amp;quot; method checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
6. &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
Import process using our implementation is as follows -&lt;br /&gt;
1. User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
2. User is redirected to &amp;quot;start&amp;quot; view of import file controller.&lt;br /&gt;
3. User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
We have also fixed the ''checkIfFileExist()'' method so that if the user doesn't select the file and click on import button it gives him/her an error stating that &amp;quot;No file has been selected to import&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111226</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111226"/>
		<updated>2017-11-02T17:50:17Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Plan of Work and Implementation Process */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source web application devloped on the Ruby on Rails platform that helps students to create reusable learning objects through peer review, and also supports document submission and team projects.&lt;br /&gt;
&lt;br /&gt;
Expertiza includes several variations of import functionality, and allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewers (reviewing contributors to assignments).&lt;br /&gt;
* A list of meta-reviewers (reviewing reviewers).&lt;br /&gt;
&amp;lt;!-- * A list of topics for an existing assignment --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing rows of data, with each individual value of a row separated by a given delimiter.&lt;br /&gt;
&lt;br /&gt;
Expertiza allows four specifications for delimiters:&lt;br /&gt;
&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other (any custom delimiter provided by the user as text)&lt;br /&gt;
&lt;br /&gt;
All of these import functions are routed through the Import File Controller, which is responsible for parsing file data and delegating the import process to the appropriate model.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza-based OSS project which deals primarily with the Import File Controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110], detailed on the Expertiza Github. A significant problem with the existing import functions is that they are not implemented consistently, and there are rigid restrictions placed on how the columns should be ordered in the given import files. In the current implementation, rows are taken is arrays, with the column numbers of specific fields hard-coded into the helper methods for different imports. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly interface so that users can easily and reliably take advantage of Expertiza's various import functions.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue, we have enhanced the interface and the import process, keeping the core methods of import intact, but expanding its functionality to increase its reliability, robustness, and ease-of-use. In the new interface, the system will display what will be imported in an easy-to-read grid before the import is finalized, letting the user verify the correctness of the data and, if necessary, choose from a dropdown menu which columns need to be rearranged. The default ordering is the same as what is currently required by Expertiza, unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
In our implementation of the import method, we have made the use of hash data structure. During the import process, we create an array of hashes, in which each row of the array corresponds to a row of the original import file. In each hash, keys refer to the field name, and values refer to the actual value of that field that will be saved to the database. This greatly improved the flexibility of the import process, since the order of the data in the import files is no longer required to be in one specific order only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Test Plan and Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== User Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the User model with several varying examples, and also demonstrates that the original error messaging system is preserved with our new implementation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assigment Participant and Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Participant and Course Participant models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team and Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/JFX4VZItSyQ Team Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Team and Course Team models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Reviewer and Meta-reviewer Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/01XV12nygLE Review Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Review Response Map and Metareview Response Map models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Plan of Work and Implementation Process =&lt;br /&gt;
&lt;br /&gt;
In this project we have tried to make the import process more flexible. As stated in the previous section, in the old implementation, user had to import the files with restriction to the order of columns required. We tried to make this process flexible for the user, such that user is able to easily specify the order of columns using drop down menus.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; Here is view used for the previous implementation of the User Imports - &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; Here is the view with our implementation of the User Imports - &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the code side of imports, we have improved the implementation significantly. Previously, the import process used hard coded index values to retrieve specific columns from the import file -&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt;Code to show hard coded index values &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This was the reason why columns were needed to be in a restricted order. But in our approach, we divide the rows of data provided in import files into hashes. Accessing data from hashes is flexible as we just need the keys to access certain values which we specify during our import process and thus we know ,before hand, what key to use to access a specific value whenever needed.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt;Code to show hash implementation&amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The import process in the previous implementation is as follows -&lt;br /&gt;
1. User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
2. User is redirected to &amp;quot;start&amp;quot; view of import file controller.&lt;br /&gt;
3. User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
4. &amp;quot;import&amp;quot; method of the Import File Controller is called which in turn calls the &amp;quot;import_file&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the error which might be encountered during the import process and displays it to the user.&lt;br /&gt;
5. &amp;quot;import_file&amp;quot; method checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
6. &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
Import process using our implementation is as follows -&lt;br /&gt;
1. User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
2. User is redirected to &amp;quot;start&amp;quot; view of import file controller.&lt;br /&gt;
3. User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
We have also fixed the ''checkIfFileExist()'' method so that if the user doesn't select the file and click on import button it gives him/her an error stating that &amp;quot;No file has been selected to import&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111225</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=111225"/>
		<updated>2017-11-02T17:49:59Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Added Features */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source web application devloped on the Ruby on Rails platform that helps students to create reusable learning objects through peer review, and also supports document submission and team projects.&lt;br /&gt;
&lt;br /&gt;
Expertiza includes several variations of import functionality, and allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewers (reviewing contributors to assignments).&lt;br /&gt;
* A list of meta-reviewers (reviewing reviewers).&lt;br /&gt;
&amp;lt;!-- * A list of topics for an existing assignment --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing rows of data, with each individual value of a row separated by a given delimiter.&lt;br /&gt;
&lt;br /&gt;
Expertiza allows four specifications for delimiters:&lt;br /&gt;
&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other (any custom delimiter provided by the user as text)&lt;br /&gt;
&lt;br /&gt;
All of these import functions are routed through the Import File Controller, which is responsible for parsing file data and delegating the import process to the appropriate model.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza-based OSS project which deals primarily with the Import File Controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110], detailed on the Expertiza Github. A significant problem with the existing import functions is that they are not implemented consistently, and there are rigid restrictions placed on how the columns should be ordered in the given import files. In the current implementation, rows are taken is arrays, with the column numbers of specific fields hard-coded into the helper methods for different imports. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly interface so that users can easily and reliably take advantage of Expertiza's various import functions.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue, we have enhanced the interface and the import process, keeping the core methods of import intact, but expanding its functionality to increase its reliability, robustness, and ease-of-use. In the new interface, the system will display what will be imported in an easy-to-read grid before the import is finalized, letting the user verify the correctness of the data and, if necessary, choose from a dropdown menu which columns need to be rearranged. The default ordering is the same as what is currently required by Expertiza, unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
In our implementation of the import method, we have made the use of hash data structure. During the import process, we create an array of hashes, in which each row of the array corresponds to a row of the original import file. In each hash, keys refer to the field name, and values refer to the actual value of that field that will be saved to the database. This greatly improved the flexibility of the import process, since the order of the data in the import files is no longer required to be in one specific order only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Test Plan and Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== User Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the User model with several varying examples, and also demonstrates that the original error messaging system is preserved with our new implementation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assigment Participant and Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Participant and Course Participant models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team and Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/JFX4VZItSyQ Team Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Assignment Team and Course Team models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Reviewer and Meta-reviewer Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/01XV12nygLE Review Import Demo]&lt;br /&gt;
&lt;br /&gt;
This video demonstrates the enhanced import features for the Review Response Map and Metareview Response Map models with several varying examples.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Plan of Work and Implementation Process =&lt;br /&gt;
&lt;br /&gt;
In this project we have tried to make the import process more flexible. As stated in the previous section, in the old implementation, user had to import the files with restriction to the order of columns required. We tried to make this process flexible for the user, such that user is able to easily specify the order of columns using drop down menus.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; Here is view used for the previous implementation of the User Imports - &amp;lt;big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; Here is the view with our implementation of the User Imports - &amp;lt;big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the code side of imports, we have improved the implementation significantly. Previously, the import process used hard coded index values to retrieve specific columns from the import file -&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt;Code to show hard coded index values &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This was the reason why columns were needed to be in a restricted order. But in our approach, we divide the rows of data provided in import files into hashes. Accessing data from hashes is flexible as we just need the keys to access certain values which we specify during our import process and thus we know ,before hand, what key to use to access a specific value whenever needed.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt;Code to show hash implementation&amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The import process in the previous implementation is as follows -&lt;br /&gt;
1. User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
2. User is redirected to &amp;quot;start&amp;quot; view of import file controller.&lt;br /&gt;
3. User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
4. &amp;quot;import&amp;quot; method of the Import File Controller is called which in turn calls the &amp;quot;import_file&amp;quot; method of the same controller. &amp;quot;import&amp;quot; method collects the error which might be encountered during the import process and displays it to the user.&lt;br /&gt;
5. &amp;quot;import_file&amp;quot; method checks which model is to be used to import the data and calls &amp;quot;import&amp;quot; method of the respective models.&lt;br /&gt;
6. &amp;quot;import&amp;quot; method of respective model performs the import based on hard coded order of columns.&lt;br /&gt;
&lt;br /&gt;
Import process using our implementation is as follows -&lt;br /&gt;
1. User initiates import process via links for importing files on different views for different models.&lt;br /&gt;
2. User is redirected to &amp;quot;start&amp;quot; view of import file controller.&lt;br /&gt;
3. User uploads the file containing data to be imported. User also modifies the options used for import on the &amp;quot;start&amp;quot; view.&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
We have also fixed the ''checkIfFileExist()'' method so that if the user doesn't select the file and click on import button it gives him/her an error stating that &amp;quot;No file has been selected to import&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110744</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110744"/>
		<updated>2017-10-28T03:50:41Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Demonstrations */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is web application devloped on Ruby on Rails platform. It helps students to create reusable learning objects through peer review. It also supports document submission and team projects. Expertiza allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewer assignments.&lt;br /&gt;
* A list of meta-reviewer assignments.&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing data. The data should be formatted as different rows represented as lines of text in the file. The rows should contain values separated using delimiters. There can be 4 types of delimiters:&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other - Any custom delimiter provided by the user as text&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza based OSS project which deals primarily with the Import File controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110] on the Expertiza Github. The problem with these imports is that they are not implemented consistently. There are restrictions to how the columns should be ordered in the import file. In the current implementation, rows are taken is arrays and the column number of specific fields required in imports are hardcoded in the helper methods of different imports. This is the reason, why order of columns is restricted during an import. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly user-interface to the users so that they are able easily import users, participants, topics, etc.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue we have changed the interface and the import process to an extent, keeping the core methods of import intact with just few required minor changes. In the new interface, upon importing, the system would then display what was imported, and let the user choose from a dropdown which field was which. The default ordering is the same as what is currently required by Expertiza unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
In our implementation of the import method, we have made the use of hash data structure. We create an array of hashes, in which each row of the array corresponds to a row inside the import file. In each hash, its key is the field name and value is the actual value of that field which will be entered in the database corresponding to the model being imported. This helps in making the sequence of columns flexible while saving the data as we no longer depend on the position of fields of data being imported from the file.&lt;br /&gt;
&lt;br /&gt;
= Added Features =&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
We have also fixed the ''checkIfFileExist()'' method so that if the user doesn't select the file and click on import button it gives him/her an error stating that &amp;quot;No file has been selected to import&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
= Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== User Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assigment Participant and Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team and Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Reviewer and Meta-reviewer Import ===&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110742</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110742"/>
		<updated>2017-10-28T03:49:29Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Solution */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is web application devloped on Ruby on Rails platform. It helps students to create reusable learning objects through peer review. It also supports document submission and team projects. Expertiza allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewer assignments.&lt;br /&gt;
* A list of meta-reviewer assignments.&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing data. The data should be formatted as different rows represented as lines of text in the file. The rows should contain values separated using delimiters. There can be 4 types of delimiters:&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other - Any custom delimiter provided by the user as text&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza based OSS project which deals primarily with the Import File controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110] on the Expertiza Github. The problem with these imports is that they are not implemented consistently. There are restrictions to how the columns should be ordered in the import file. In the current implementation, rows are taken is arrays and the column number of specific fields required in imports are hardcoded in the helper methods of different imports. This is the reason, why order of columns is restricted during an import. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly user-interface to the users so that they are able easily import users, participants, topics, etc.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue we have changed the interface and the import process to an extent, keeping the core methods of import intact with just few required minor changes. In the new interface, upon importing, the system would then display what was imported, and let the user choose from a dropdown which field was which. The default ordering is the same as what is currently required by Expertiza unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
In our implementation of the import method, we have made the use of hash data structure. We create an array of hashes, in which each row of the array corresponds to a row inside the import file. In each hash, its key is the field name and value is the actual value of that field which will be entered in the database corresponding to the model being imported. This helps in making the sequence of columns flexible while saving the data as we no longer depend on the position of fields of data being imported from the file.&lt;br /&gt;
&lt;br /&gt;
= Added Features =&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
We have also fixed the ''checkIfFileExist()'' method so that if the user doesn't select the file and click on import button it gives him/her an error stating that &amp;quot;No file has been selected to import&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
= Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignent Participant and Course Participant Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignment Team and Course Team Import ==&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110729</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110729"/>
		<updated>2017-10-28T03:39:48Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Topic Description */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is web application devloped on Ruby on Rails platform. It helps students to create reusable learning objects through peer review. It also supports document submission and team projects. Expertiza allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewer assignments.&lt;br /&gt;
* A list of meta-reviewer assignments.&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing data. The data should be formatted as different rows represented as lines of text in the file. The rows should contain values separated using delimiters. There can be 4 types of delimiters:&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other - Any custom delimiter provided by the user as text&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza based OSS project which deals primarily with the Import File controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110] on the Expertiza Github. The problem with these imports is that they are not implemented consistently. There are restrictions to how the columns should be ordered in the import file. In the current implementation, rows are taken is arrays and the column number of specific fields required in imports are hardcoded in the helper methods of different imports. This is the reason, why order of columns is restricted during an import. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly user-interface to the users so that they are able easily import users, participants, topics, etc.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue we have changed the interface and the import process to an extent, keeping the core methods of import intact with just few required minor changes. In the new interface, upon importing, the system would then display what was imported, and let the user choose from a dropdown which field was which. The default ordering is the same as what is currently required by Expertiza unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
In our implementation of the import method, we have made the use of hash data structure. We create an array of hashes, in which key of the hash is the field name and value is the actual value of that field which will be entered in the table. This helps in making the sequence of columns flexible while saving the data as we no longer depend on the sequence of data being imported form the file.&lt;br /&gt;
&lt;br /&gt;
= Added Features =&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
We have also fixed the ''checkIfFileExist()'' method so that if the user doesn't select the file and click on import button it gives him/her an error stating that &amp;quot;No file has been selected to import&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
= Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignent Participant and Course Participant Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignment Team and Course Team Import ==&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110688</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110688"/>
		<updated>2017-10-28T03:13:10Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Models */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is web application devloped on Ruby on Rails platform. It helps students to create reusable learning objects through peer review. It also supports document submission and team projects. Expertiza allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewer assignments.&lt;br /&gt;
* A list of meta-reviewer assignments.&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing data. The data should be formatted as different rows represented as lines of text in the file. The rows should contain values separated using delimiters. There can be 4 types of delimiters:&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other - Any custom delimiter provided by the user as text&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza based OSS project which deals primarily with the Import File controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110] on the Expertiza Github. The problem with these imports is that they are not implemented consistently. There are restrictions to how the columns should be ordered in the import file. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly user-interface to the users so that they are able easily import users, participants, topics, etc.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue we have changed the interface and the import process to an extent, keeping the core methods of import intact with just few required minor changes. In the new interface, upon importing, the system would then display what was imported, and let the user choose from a dropdown which field was which. The default ordering is the same as what is currently required by Expertiza unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
= Added Features =&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
Here is a list of models and their respective methods that we had to modify to enhance the import functionality:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
= Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignent Participant and Course Participant Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignment Team and Course Team Import ==&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110683</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110683"/>
		<updated>2017-10-28T03:10:46Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Topic Description */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
=== Backgroud ===&lt;br /&gt;
&lt;br /&gt;
Expertiza is web application devloped on Ruby on Rails platform. It helps students to create reusable learning objects through peer review. It also supports document submission and team projects. Expertiza allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewer assignments.&lt;br /&gt;
* A list of meta-reviewer assignments.&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing data. The data should be formatted as different rows represented as lines of text in the file. The rows should contain values separated using delimiters. There can be 4 types of delimiters:&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other - Any custom delimiter provided by the user as text&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza based OSS project which deals primarily with the Import File controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110] on the Expertiza Github. The problem with these imports is that they are not implemented consistently. There are restrictions to how the columns should be ordered in the import file. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly user-interface to the users so that they are able easily import users, participants, topics, etc.&lt;br /&gt;
&lt;br /&gt;
=== Solution ===&lt;br /&gt;
&lt;br /&gt;
To resolve this issue we have changed the interface and the import process to an extent, keeping the core methods of import intact with just few required minor changes. In the new interface, upon importing, the system would then display what was imported, and let the user choose from a dropdown which field was which. The default ordering is the same as what is currently required by Expertiza unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
= Added Features =&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
There is a list of models we had to modify for enhancing the import functionality, which are listed below along with the original methods we needed to modify:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
= Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignent Participant and Course Participant Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignment Team and Course Team Import ==&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110681</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110681"/>
		<updated>2017-10-28T03:09:51Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; '''Background''' &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Expertiza is web application devloped on Ruby on Rails platform. It helps students to create reusable learning objects through peer review. It also supports document submission and team projects. Expertiza allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewer assignments.&lt;br /&gt;
* A list of meta-reviewer assignments.&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing data. The data should be formatted as different rows represented as lines of text in the file. The rows should contain values separated using delimiters. There can be 4 types of delimiters:&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other - Any custom delimiter provided by the user as text&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; '''Problem Statement''' &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza based OSS project which deals primarily with the Import File controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110] on the Expertiza Github. The problem with these imports is that they are not implemented consistently. There are restrictions to how the columns should be ordered in the import file. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly user-interface to the users so that they are able easily import users, participants, topics, etc.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; '''Solution''' &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To resolve this issue we have changed the interface and the import process to an extent, keeping the core methods of import intact with just few required minor changes. In the new interface, upon importing, the system would then display what was imported, and let the user choose from a dropdown which field was which. The default ordering is the same as what is currently required by Expertiza unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
= Added Features =&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
=== Assets ===&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
&lt;br /&gt;
=== Config ===&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
&lt;br /&gt;
=== Helpers ===&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
=== Models ===&lt;br /&gt;
&lt;br /&gt;
There is a list of models we had to modify for enhancing the import functionality, which are listed below along with the original methods we needed to modify:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
=== Views ===&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
= Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignent Participant and Course Participant Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignment Team and Course Team Import ==&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110669</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110669"/>
		<updated>2017-10-28T03:05:09Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Topic Description */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; '''Background''' &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Expertiza is web application devloped on Ruby on Rails platform. It helps students to create reusable learning objects through peer review. It also supports document submission and team projects. Expertiza allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewer assignments.&lt;br /&gt;
* A list of meta-reviewer assignments.&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing data. The data should be formatted as different rows represented as lines of text in the file. The rows should contain values separated using delimiters. There can be 4 types of delimiters:&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other - Any custom delimiter provided by the user as text&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; '''Problem Statement''' &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza based OSS project which deals primarily with the Import File controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110] on the Expertiza Github. The problem with these imports is that they are not implemented consistently. There are restrictions to how the columns should be ordered in the import file. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly user-interface to the users so that they are able easily import users, participants, topics, etc.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; '''Solution''' &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To resolve this issue we have changed the interface and the import process to an extent, keeping the core methods of import intact with just few required minor changes. In the new interface, upon importing, the system would then display what was imported, and let the user choose from a dropdown which field was which. The default ordering is the same as what is currently required by Expertiza unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
= Added Features =&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
== Assets ==&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
&lt;br /&gt;
== Config ==&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
== Controllers ==&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
== Helpers ==&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
== Models ==&lt;br /&gt;
&lt;br /&gt;
There is a list of models we had to modify for enhancing the import functionality, which are listed below along with the original methods we needed to modify:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
== Views ==&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
= Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignent Participant and Course Participant Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignment Team and Course Team Import ==&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110660</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110660"/>
		<updated>2017-10-28T03:00:57Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Topic Description */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; '''Background''' &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Expertiza is web application devloped on Ruby on Rails platform. It helps students to create reusable learning objects through peer review. It also supports document submission and team projects. Expertiza allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing course.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewer assignments.&lt;br /&gt;
* A list of meta-reviewer assignments.&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing data. The data should be formatted as different rows represented as lines of text in the file. The rows should contain values separated using delimiters. There can be 4 types of delimiters:&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other - A custom delimiter provided by the user as text&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; '''Problem Statement''' &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza based OSS project which deals primarily with the Import File controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110] on the Expertiza Github. The problem with these imports is that they are not implemented consistently. There are restrictions to how the columns should be ordered in the import file. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly user-interface to the users so that they are able easily import users, participants, topics, etc.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; '''Solution''' &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To resolve this issue we have changed the interface and the import process to an extent, keeping the core methods of import intact with just few required minor changes. In the new interface, upon importing, the system would then display what was imported, and let the user choose from a dropdown which field was which. The default ordering is the same as what is currently required by Expertiza unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
= Added Features =&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
== Assets ==&lt;br /&gt;
&lt;br /&gt;
To implement the functionality of non-duplicate column names, we created two new methods ''checkIfUserColumnDuplicate()'' and ''checkIfParticipateColumnDuplicate()'' in the shared.js .&lt;br /&gt;
&lt;br /&gt;
== Config ==&lt;br /&gt;
&lt;br /&gt;
We needed to change the ''routes.rb'' so that the new partial views can be implemented.&lt;br /&gt;
&lt;br /&gt;
== Controllers ==&lt;br /&gt;
&lt;br /&gt;
For the enhancement of the import functionality, we modified the import_file_controller. In this controller, we modified one existing method ''import()'', other than that we had to declare some additional methods ''import_from_hash()'', ''hash_rows_with_headers()'', ''parse_to_hash()'', ''parse_to_grid()'' and ''show()''.&lt;br /&gt;
== Helpers ==&lt;br /&gt;
&lt;br /&gt;
As we changed the original implementation from array to hash we need to also modify the import_file_helper a little bit.&lt;br /&gt;
&lt;br /&gt;
== Models ==&lt;br /&gt;
&lt;br /&gt;
There is a list of models we had to modify for enhancing the import functionality, which are listed below along with the original methods we needed to modify:&lt;br /&gt;
&lt;br /&gt;
#assignment_participant : ''self.import()''&lt;br /&gt;
#course_participant : ''self.import()''&lt;br /&gt;
#course_team : ''add_member()''&lt;br /&gt;
#metareview_response_map : ''self.import()''&lt;br /&gt;
#review_response_map : ''self.import()''&lt;br /&gt;
#team : ''import_team_members()'' and ''self.import()''&lt;br /&gt;
#user : ''self.import()''&lt;br /&gt;
&lt;br /&gt;
== Views ==&lt;br /&gt;
&lt;br /&gt;
To use the import functionality in a new and enhanced way, we modified one of the existing view and added new views, listed below:&lt;br /&gt;
&lt;br /&gt;
Views Modified:&lt;br /&gt;
#''start.html.erb''&lt;br /&gt;
&lt;br /&gt;
Views Created:&lt;br /&gt;
#''_metareviewer.html.erb''&lt;br /&gt;
#''_participant.html.erb''&lt;br /&gt;
#''show.html.erb''&lt;br /&gt;
#''_reviewer.html.erb''&lt;br /&gt;
#''_team.html.erb''&lt;br /&gt;
#''_user.html.erb''&lt;br /&gt;
&lt;br /&gt;
= Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignent Participant and Course Participant Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignment Team and Course Team Import ==&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110565</id>
		<title>CSC/ECE 517 Fall 2017/E1776 Enhance Imports</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2017/E1776_Enhance_Imports&amp;diff=110565"/>
		<updated>2017-10-28T01:41:21Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: /* Topic Description */  Added&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;padding: 25px 25px 25px 25px&amp;quot;&amp;gt;&lt;br /&gt;
= Team Contact =&lt;br /&gt;
&lt;br /&gt;
; MEMBERS:&lt;br /&gt;
&lt;br /&gt;
:Pushpendra Patel: [mailto:ppatel16@ncsu.edu ppatel16@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Tanay Kothari: [mailto:tkothar@ncsu.edu tkothar@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
:Timothy Dement: [mailto:tmdement@ncsu.edu tmdement@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
; MENTOR:&lt;br /&gt;
&lt;br /&gt;
:Ferry Pramudianto: [mailto:fferry@ncsu.edu fferry@ncsu.edu]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Topic Description =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; '''Background''' &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Expertiza is web application devloped on Ruby on Rails platform. It helps students to create reusable learning objects through peer review. It also supports document submission and team projects. Expertiza allows the instructors to import following data:&lt;br /&gt;
&lt;br /&gt;
* A list of users.&lt;br /&gt;
* A list of participants for an existing assignment.&lt;br /&gt;
* A list of participants for an existing score.&lt;br /&gt;
* A list of teams for an existing assignment&lt;br /&gt;
* A list of teams for an existing course.&lt;br /&gt;
* A list of reviewer assignments.&lt;br /&gt;
* A list of meta-reviewer assignments.&lt;br /&gt;
&lt;br /&gt;
These imports are done by uploading a file containing data. The data should be formatted as different rows represented as lines of text in the file. The rows should contain values separated using delimiters. There can be 4 types of delimiters -&lt;br /&gt;
# Comma&lt;br /&gt;
# Space&lt;br /&gt;
# Tab&lt;br /&gt;
# Other - A custom delimiter provided by the user as text&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; '''Problem Statement''' &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The following is an Expertiza based OSS project which deals primarily with the Import File controller. This project is associated with fixing [https://github.com/expertiza/expertiza/issues/110 issue #110] on the Expertiza Github. The problem with these imports is that they are not implemented consistently. There are restrictions to how the columns should be ordered in the import file. The aim of this project is to improve the import functionality as well as provide a flexible and user-friendly user-interface to the users so that they are able easily import users, participants, topics, etc.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;big&amp;gt; '''Solution''' &amp;lt;/big&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To resolve this issue, we have changed the interface and the import process to an extent keeping the core methods of import intact with just required minor changes. In the new interface, upon importing, the system would then display what was imported, and let the user choose from a dropdown which field was which. The default ordering is the same as what is currently required by Expertiza unless a specific order is provided by the user as a header in the import file.&lt;br /&gt;
&lt;br /&gt;
= Added Features =&lt;br /&gt;
&lt;br /&gt;
= Files Changed =&lt;br /&gt;
&lt;br /&gt;
= Demonstrations =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/HaaXKxfqzes User Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignent Participant and Course Participant Import ==&lt;br /&gt;
&lt;br /&gt;
[https://youtu.be/BGGPjJrkEjI Participant Import Demo]&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assignment Team and Course Team Import ==&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- &lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
LINK TO YOUTUBE VIDEO&lt;br /&gt;
&lt;br /&gt;
DESCRIPTION&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Navigating Expertiza =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== User Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the User import process, first select the &amp;quot;User&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Users.png|none|frame|Manage Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, scroll to the bottom of the page and click the &amp;quot;Import Users&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Users.png|none|frame|Import Users]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the User import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Participant Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Participants, Assignment Participants and Course Participants.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Participant import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Assignment-Participant.png|none|frame|Add Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import assignment participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Participant.png|none|Import Assignment Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Assignment Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Participant Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Participant import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate course and click the &amp;quot;Add Participants&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Add-Course-Participant.png|none|frame|Add Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import course participants&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Participant.png|none|frame|Import Course Participant]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Participant import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Team Import ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two types of Teams, Assignment Teams and Course Teams.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Assignment Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Assignment Team import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Assignment-Teams.png|none|frame|Create Assignment Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Assignment-Teams.png|none|Import Assignment Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will be redirected to the Assignment Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Course Team Import ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To begin the Course Team import process, first select the &amp;quot;Courses&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Courses.png|none|frame|Manage Courses]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Courses&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Create Teams&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Create-Course-Teams.png|none|frame|Create Course Team]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page and click the &amp;quot;Import Teams&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Course-Teams.png|none|Import Course Teams]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Course Team import page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reviewer and Metareviewer Import ==&lt;br /&gt;
&lt;br /&gt;
To begin the Reviewer and Metareviewer import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Assign reviewers&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Assign-Reviewers.png|none|Assign Reviewers]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Finally, scroll to the bottom of the page, and click either the &amp;quot;Import reviewer mappings&amp;quot; link or the &amp;quot;Import meta reviewer mappings&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Reviewer-Mappings.png|none|Import Reviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Metareviewer-Mappings.png|none|Import Metareviewer Mappings]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to either the Reviewer import page or the Metareviewer import page.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
== &amp;lt;span style=&amp;quot;font-weight:bold;color:red&amp;quot;&amp;gt;[UNDER CONSTRUCTION] Topic Import&amp;lt;/span&amp;gt; ==&lt;br /&gt;
&lt;br /&gt;
To begin the Topic import process, first select the &amp;quot;Assignments&amp;quot; link from the &amp;quot;Manage&amp;quot; drop-down menu.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Manage-Assignments.png|none|frame|Manage Assignments]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Make sure that &amp;quot;Assignments&amp;quot; is highlighted on the &amp;quot;Manage content&amp;quot; page, then locate the appropriate assignment and click the &amp;quot;Edit&amp;quot; button.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Edit-Assignment.png|none|frame|Edit Assignment]]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next, select the &amp;quot;Topics&amp;quot; tab, scroll to the bottom of the page and click the &amp;quot;Import topics&amp;quot; link.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Import-Topics.png|none|frame|Import Topics]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If topics have not been set up yet on the given assignment, you will receive an alert that will need to be accepted before continuing.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0px 0px 0px 25px&amp;quot;&amp;gt;&lt;br /&gt;
[[File:Topic-Alert.png|none|frame|Topic Alert]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You will then be redirected to the Topic import page.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=MainPage&amp;diff=110034</id>
		<title>MainPage</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=MainPage&amp;diff=110034"/>
		<updated>2017-10-27T18:37:44Z</updated>

		<summary type="html">&lt;p&gt;Tkothar: Reverting Homepage Edits - I believe this was a mistake done by some student who, instead of the OSS project page of his team, modified the homepage itself. I am reverting back the changes till the time when the page was correctly written.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Expertiza==&lt;br /&gt;
* [[Expertiza documentation]]&lt;br /&gt;
&lt;br /&gt;
==Course-Specific Topics==&lt;br /&gt;
&lt;br /&gt;
* [[CSC/ECE 517 Summer 2008]]&lt;br /&gt;
* [[CSC/ECE 517 Fall 2010]]&lt;br /&gt;
* [[CSC/ECE 517 Fall 2011]]&lt;br /&gt;
* [[CSC/ECE 517 Fall 2012]]&lt;br /&gt;
* [[CSC/ECE 517 Fall 2013]]&lt;br /&gt;
* [[CSC/ECE 517 Fall 2014]]&lt;br /&gt;
* [[CSC/ECE 517 Fall 2015]]&lt;br /&gt;
* [[CSC/ECE 517 Fall 2016]]&lt;br /&gt;
* [[CSC/ECE 517 Spring 2014]]&lt;br /&gt;
* [[CSC/ECE 517 Spring 2015]]&lt;br /&gt;
* [[CSC/ECE 517 Spring 2016]]&lt;br /&gt;
* [[CSC/ECE 517 Spring 2017]]&lt;br /&gt;
* [[CSC/ECE 517 Fall 2017]]&lt;br /&gt;
* [[CSC 456 Spring 2011|CSC 456 Spring 2012]]&lt;br /&gt;
* [[ECE 633]]&lt;br /&gt;
* [[KCU]]&lt;br /&gt;
* [[Progress reports]]&lt;br /&gt;
&lt;br /&gt;
==Application Behavior==&lt;br /&gt;
* [[Grading]]&lt;br /&gt;
&lt;br /&gt;
==Metaprogramming==&lt;br /&gt;
* [[CSC/ECE_517_Spring_2013/ch1b_1k_hf|Lecture on Metaprogramming]]&lt;br /&gt;
&lt;br /&gt;
==Development==&lt;br /&gt;
&lt;br /&gt;
''Expertiza now has a Java dependency, so the machine you are using to develop Expertiza on should have the JVM installed.''&lt;br /&gt;
&lt;br /&gt;
* [[Setting Up a Development Machine]]&lt;br /&gt;
* [[Creating a Linux Development Environment for Expertiza - Installation Guide]]&lt;br /&gt;
* [[Using git and github for projects]]&lt;br /&gt;
* [[Using heroku to deploy your projects]]&lt;br /&gt;
* [[How to Begin a Project from the Current Expertiza Repository]]&lt;br /&gt;
* [[Git]]&lt;br /&gt;
* [[How to Change a User's Password on a Development Machine]]&lt;br /&gt;
* [[Debugging Rails]]&lt;br /&gt;
&lt;br /&gt;
==Production==&lt;br /&gt;
* [[Deploying to Production]]&lt;br /&gt;
* [[Downloading Production Data]]&lt;br /&gt;
* [[Accessing the Production Server]]&lt;br /&gt;
&lt;br /&gt;
==Testing==&lt;br /&gt;
* [[Using Cucumber with Expertiza]]&lt;br /&gt;
* [[Rails Testing Overview]]&lt;br /&gt;
* [[Expertiza Continuous Integration]]&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
* [[Object-Oriented Design and Programming]]&lt;/div&gt;</summary>
		<author><name>Tkothar</name></author>
	</entry>
</feed>