<?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=Rpothir</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=Rpothir"/>
	<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Special:Contributions/Rpothir"/>
	<updated>2026-06-05T20:05:57Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.41.0</generator>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108865</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108865"/>
		<updated>2017-05-03T05:21:36Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Validating user entries */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
[https://en.wikipedia.org/wiki/React_(JavaScript_library) ReactJS] is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips - Needed to increase the proximity of the tool tips in the assignments tab.&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]] &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Add/Edit topics in Assignment ===&lt;br /&gt;
In current implementation whenever a topic is added to the assignment, a request is sent to the server and user is redirected to a form in another page. Upon creation of topic user is rendered back to edit assignment page. This process involves lot of redirection. Now, the task is to avoid this redirection of pages and create a interactive ReactJS form for adding and editing topic.&lt;br /&gt;
&lt;br /&gt;
Currently this logic is implemented in new method in sign_up_controller.rb file and is invoked in the _add_topics.rb ruby injection file. With this action new.html.erb page is rendered. This should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Add topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Add_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
Similar is the case for editing a topic. For editing a topic user is rendered to a form in edit page and again redirected to edit assignment page.&lt;br /&gt;
&lt;br /&gt;
'''Edit Topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Edit_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab_assignment.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintenance like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as&lt;br /&gt;
&lt;br /&gt;
This is essential in both new assignment or editing assignment page.&lt;br /&gt;
&lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* Though mentioned a mandatory no special characters, it was not properly implemented. System is accepting the special characters.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Vaidatinguser.PNG]]&lt;br /&gt;
&lt;br /&gt;
'''UML Diagram'''&lt;br /&gt;
&lt;br /&gt;
The following diagram depicts the flow of events leading to validations.&lt;br /&gt;
&lt;br /&gt;
[[File:Uml for validation.png]]&lt;br /&gt;
&lt;br /&gt;
==Implementation==&lt;br /&gt;
&lt;br /&gt;
Here is the main code for the regular expression check in Name of assignment and sub directory fields. Now, each time when a create button is clicked, the page is not checked with the model constraints but the reactjs component only. So, without reloading each time the checks are shown on the page as shown in the figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:Validate.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
=== Assignment Creation ===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
Below is the mock view of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
=== Assignment Edition ===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
Below is the mock display of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:Edit-new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
=== Addition of topics ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_add_topics.html.erb'' when New Topic link is clicked. This should show a form in that page to create topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/new.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle creation of topic and saving it to database.&lt;br /&gt;
&lt;br /&gt;
=== Editing topic ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_all_actions.html.erb'' when edit action is clicked. This should show a form in that page to edit topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/edit.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle editing  of topic and updating it to database.&lt;br /&gt;
&lt;br /&gt;
=== Make the table in topics tab sortable by its header ===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
=== Validating user entries ===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Correcting the code in edit assignment page too.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
=== Fixing Tooltips ===&lt;br /&gt;
On exploring, it was noticed that all the existing tooltips work. However, we intend to increase the proximity of the tooltips in the assignment tab by increasing the size of the images.&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red in rspec and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
&lt;br /&gt;
====Topic Creation/Editing====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Click 'New Topic' link or 'edit' action in topics table for a particular topic&lt;br /&gt;
* A pop window or form should be displayed in the same page&lt;br /&gt;
* Add topic details in that window/ form&lt;br /&gt;
* Save it&lt;br /&gt;
* Created or modified topic should be seen in topics table&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
Another way to check is from editing page too.&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit icon page.&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment which is updated with special characters is shown in the table.&lt;br /&gt;
&lt;br /&gt;
===Automation testing===&lt;br /&gt;
The above tests all will be automated using rspec. Rspec Mock-ups will be created for checking the navigation flow of newly created React JS components.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
&lt;br /&gt;
We will try to convert edit assignment page in to React JS. Design pages more clearly.&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;br /&gt;
#''https://github.com/expertiza/expertiza/pull/855&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Validation.PNG&amp;diff=108864</id>
		<title>File:Validation.PNG</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Validation.PNG&amp;diff=108864"/>
		<updated>2017-05-03T05:14:53Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Validate.PNG&amp;diff=108863</id>
		<title>File:Validate.PNG</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Validate.PNG&amp;diff=108863"/>
		<updated>2017-05-03T03:26:56Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108609</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108609"/>
		<updated>2017-04-23T19:24:30Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Validating user entries */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
[https://en.wikipedia.org/wiki/React_(JavaScript_library) ReactJS] is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips - Needed to increase the proximity of the tool tips in the assignments tab.&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]] &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Add/Edit topics in Assignment ===&lt;br /&gt;
In current implementation whenever a topic is added to the assignment, a request is sent to the server and user is redirected to a form in another page. Upon creation of topic user is rendered back to edit assignment page. This process involves lot of redirection. Now, the task is to avoid this redirection of pages and create a interactive ReactJS form for adding and editing topic.&lt;br /&gt;
&lt;br /&gt;
Currently this logic is implemented in new method in sign_up_controller.rb file and is invoked in the _add_topics.rb ruby injection file. With this action new.html.erb page is rendered. This should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Add topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Add_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
Similar is the case for editing a topic. For editing a topic user is rendered to a form in edit page and again redirected to edit assignment page.&lt;br /&gt;
&lt;br /&gt;
'''Edit Topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Edit_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab_assignment.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintenance like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as&lt;br /&gt;
&lt;br /&gt;
This is essential in both new assignment or editing assignment page.&lt;br /&gt;
&lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* Though mentioned a mandatory no special characters, it was not properly implemented. System is accepting the special characters.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Vaidatinguser.PNG]]&lt;br /&gt;
&lt;br /&gt;
'''UML Diagram'''&lt;br /&gt;
&lt;br /&gt;
The following diagram depicts the flow of events leading to validations.&lt;br /&gt;
&lt;br /&gt;
[[File:Uml for validation.png]]&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
=== Assignment Creation ===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
Below is the mock view of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
=== Assignment Edition ===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
Below is the mock display of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:Edit-new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
=== Addition of topics ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_add_topics.html.erb'' when New Topic link is clicked. This should show a form in that page to create topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/new.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle creation of topic and saving it to database.&lt;br /&gt;
&lt;br /&gt;
=== Editing topic ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_all_actions.html.erb'' when edit action is clicked. This should show a form in that page to edit topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/edit.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle editing  of topic and updating it to database.&lt;br /&gt;
&lt;br /&gt;
=== Make the table in topics tab sortable by its header ===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
=== Validating user entries ===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Correcting the code in edit assignment page too.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
=== Fixing Tooltips ===&lt;br /&gt;
On exploring, it was noticed that all the existing tooltips work. However, we intend to increase the proximity of the tooltips in the assignment tab by increasing the size of the images.&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red in rspec and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
&lt;br /&gt;
====Topic Creation/Editing====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Click 'New Topic' link or 'edit' action in topics table for a particular topic&lt;br /&gt;
* A pop window or form should be displayed in the same page&lt;br /&gt;
* Add topic details in that window/ form&lt;br /&gt;
* Save it&lt;br /&gt;
* Created or modified topic should be seen in topics table&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
Another way to check is from editing page too.&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit icon page.&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment which is updated with special characters is shown in the table.&lt;br /&gt;
&lt;br /&gt;
===Automation testing===&lt;br /&gt;
The above tests all will be automated using rspec. Rspec Mock-ups will be created for checking the navigation flow of newly created React JS components.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
&lt;br /&gt;
We will try to convert edit assignment page in to React JS. Design pages more clearly.&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;br /&gt;
#''https://github.com/expertiza/expertiza/pull/855&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108608</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108608"/>
		<updated>2017-04-23T19:23:43Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Validating user entries */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
[https://en.wikipedia.org/wiki/React_(JavaScript_library) ReactJS] is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips - Needed to increase the proximity of the tool tips in the assignments tab.&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]] &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Add/Edit topics in Assignment ===&lt;br /&gt;
In current implementation whenever a topic is added to the assignment, a request is sent to the server and user is redirected to a form in another page. Upon creation of topic user is rendered back to edit assignment page. This process involves lot of redirection. Now, the task is to avoid this redirection of pages and create a interactive ReactJS form for adding and editing topic.&lt;br /&gt;
&lt;br /&gt;
Currently this logic is implemented in new method in sign_up_controller.rb file and is invoked in the _add_topics.rb ruby injection file. With this action new.html.erb page is rendered. This should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Add topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Add_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
Similar is the case for editing a topic. For editing a topic user is rendered to a form in edit page and again redirected to edit assignment page.&lt;br /&gt;
&lt;br /&gt;
'''Edit Topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Edit_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab_assignment.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintenance like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as&lt;br /&gt;
&lt;br /&gt;
This is essential in both new assignment or editing assignment page.&lt;br /&gt;
&lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* Though mentioned a mandatory no special characters, it was not properly implemented. System is accepting the special characters.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:validatinguser.png]]&lt;br /&gt;
&lt;br /&gt;
'''UML Diagram'''&lt;br /&gt;
&lt;br /&gt;
The following diagram depicts the flow of events leading to validations.&lt;br /&gt;
&lt;br /&gt;
[[File:Uml for validation.png]]&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
=== Assignment Creation ===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
Below is the mock view of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
=== Assignment Edition ===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
Below is the mock display of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:Edit-new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
=== Addition of topics ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_add_topics.html.erb'' when New Topic link is clicked. This should show a form in that page to create topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/new.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle creation of topic and saving it to database.&lt;br /&gt;
&lt;br /&gt;
=== Editing topic ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_all_actions.html.erb'' when edit action is clicked. This should show a form in that page to edit topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/edit.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle editing  of topic and updating it to database.&lt;br /&gt;
&lt;br /&gt;
=== Make the table in topics tab sortable by its header ===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
=== Validating user entries ===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Correcting the code in edit assignment page too.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
=== Fixing Tooltips ===&lt;br /&gt;
On exploring, it was noticed that all the existing tooltips work. However, we intend to increase the proximity of the tooltips in the assignment tab by increasing the size of the images.&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red in rspec and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
&lt;br /&gt;
====Topic Creation/Editing====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Click 'New Topic' link or 'edit' action in topics table for a particular topic&lt;br /&gt;
* A pop window or form should be displayed in the same page&lt;br /&gt;
* Add topic details in that window/ form&lt;br /&gt;
* Save it&lt;br /&gt;
* Created or modified topic should be seen in topics table&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
Another way to check is from editing page too.&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit icon page.&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment which is updated with special characters is shown in the table.&lt;br /&gt;
&lt;br /&gt;
===Automation testing===&lt;br /&gt;
The above tests all will be automated using rspec. Rspec Mock-ups will be created for checking the navigation flow of newly created React JS components.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
&lt;br /&gt;
We will try to convert edit assignment page in to React JS. Design pages more clearly.&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;br /&gt;
#''https://github.com/expertiza/expertiza/pull/855&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Vaidatinguser.PNG&amp;diff=108607</id>
		<title>File:Vaidatinguser.PNG</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Vaidatinguser.PNG&amp;diff=108607"/>
		<updated>2017-04-23T19:22:06Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108606</id>
		<title>File:Userentries.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108606"/>
		<updated>2017-04-23T19:21:18Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: uploaded a new version of &amp;amp;quot;File:Userentries.png&amp;amp;quot;: Reverted to version as of 19:35, 7 April 2017&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108605</id>
		<title>File:Userentries.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108605"/>
		<updated>2017-04-23T19:21:02Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: uploaded a new version of &amp;amp;quot;File:Userentries.png&amp;amp;quot;: Reverted to version as of 19:18, 23 April 2017&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108604</id>
		<title>File:Userentries.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108604"/>
		<updated>2017-04-23T19:20:28Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: uploaded a new version of &amp;amp;quot;File:Userentries.png&amp;amp;quot;: Reverted to version as of 19:16, 23 April 2017&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108603</id>
		<title>File:Userentries.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108603"/>
		<updated>2017-04-23T19:18:15Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: uploaded a new version of &amp;amp;quot;File:Userentries.png&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108602</id>
		<title>File:Userentries.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108602"/>
		<updated>2017-04-23T19:16:06Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: uploaded a new version of &amp;amp;quot;File:Userentries.png&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108601</id>
		<title>File:Userentries.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108601"/>
		<updated>2017-04-23T19:14:14Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: uploaded a new version of &amp;amp;quot;File:Userentries.png&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108600</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108600"/>
		<updated>2017-04-23T19:13:36Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Validating user entries */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
[https://en.wikipedia.org/wiki/React_(JavaScript_library) ReactJS] is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips - Needed to increase the proximity of the tool tips in the assignments tab.&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]] &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Add/Edit topics in Assignment ===&lt;br /&gt;
In current implementation whenever a topic is added to the assignment, a request is sent to the server and user is redirected to a form in another page. Upon creation of topic user is rendered back to edit assignment page. This process involves lot of redirection. Now, the task is to avoid this redirection of pages and create a interactive ReactJS form for adding and editing topic.&lt;br /&gt;
&lt;br /&gt;
Currently this logic is implemented in new method in sign_up_controller.rb file and is invoked in the _add_topics.rb ruby injection file. With this action new.html.erb page is rendered. This should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Add topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Add_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
Similar is the case for editing a topic. For editing a topic user is rendered to a form in edit page and again redirected to edit assignment page.&lt;br /&gt;
&lt;br /&gt;
'''Edit Topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Edit_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab_assignment.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintenance like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as&lt;br /&gt;
&lt;br /&gt;
This is essential in both new assignment or editing assignment page.&lt;br /&gt;
&lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* Though mentioned a mandatory no special characters, it was not properly implemented. System is accepting the special characters.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Userentries.png]]&lt;br /&gt;
&lt;br /&gt;
'''UML Diagram'''&lt;br /&gt;
&lt;br /&gt;
The following diagram depicts the flow of events leading to validations.&lt;br /&gt;
&lt;br /&gt;
[[File:Uml for validation.png]]&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
=== Assignment Creation ===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
Below is the mock view of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
=== Assignment Edition ===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
Below is the mock display of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:Edit-new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
=== Addition of topics ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_add_topics.html.erb'' when New Topic link is clicked. This should show a form in that page to create topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/new.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle creation of topic and saving it to database.&lt;br /&gt;
&lt;br /&gt;
=== Editing topic ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_all_actions.html.erb'' when edit action is clicked. This should show a form in that page to edit topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/edit.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle editing  of topic and updating it to database.&lt;br /&gt;
&lt;br /&gt;
=== Make the table in topics tab sortable by its header ===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
=== Validating user entries ===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Correcting the code in edit assignment page too.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
=== Fixing Tooltips ===&lt;br /&gt;
On exploring, it was noticed that all the existing tooltips work. However, we intend to increase the proximity of the tooltips in the assignment tab by increasing the size of the images.&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red in rspec and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
&lt;br /&gt;
====Topic Creation/Editing====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Click 'New Topic' link or 'edit' action in topics table for a particular topic&lt;br /&gt;
* A pop window or form should be displayed in the same page&lt;br /&gt;
* Add topic details in that window/ form&lt;br /&gt;
* Save it&lt;br /&gt;
* Created or modified topic should be seen in topics table&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
Another way to check is from editing page too.&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit icon page.&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment which is updated with special characters is shown in the table.&lt;br /&gt;
&lt;br /&gt;
===Automation testing===&lt;br /&gt;
The above tests all will be automated using rspec. Rspec Mock-ups will be created for checking the navigation flow of newly created React JS components.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
&lt;br /&gt;
We will try to convert edit assignment page in to React JS. Design pages more clearly.&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;br /&gt;
#''https://github.com/expertiza/expertiza/pull/855&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108599</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108599"/>
		<updated>2017-04-23T19:11:45Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Validating user entries */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
[https://en.wikipedia.org/wiki/React_(JavaScript_library) ReactJS] is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips - Needed to increase the proximity of the tool tips in the assignments tab.&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]] &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Add/Edit topics in Assignment ===&lt;br /&gt;
In current implementation whenever a topic is added to the assignment, a request is sent to the server and user is redirected to a form in another page. Upon creation of topic user is rendered back to edit assignment page. This process involves lot of redirection. Now, the task is to avoid this redirection of pages and create a interactive ReactJS form for adding and editing topic.&lt;br /&gt;
&lt;br /&gt;
Currently this logic is implemented in new method in sign_up_controller.rb file and is invoked in the _add_topics.rb ruby injection file. With this action new.html.erb page is rendered. This should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Add topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Add_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
Similar is the case for editing a topic. For editing a topic user is rendered to a form in edit page and again redirected to edit assignment page.&lt;br /&gt;
&lt;br /&gt;
'''Edit Topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Edit_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab_assignment.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintenance like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as&lt;br /&gt;
&lt;br /&gt;
This is essential in both new assignment or editing assignment page.&lt;br /&gt;
&lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* Though mentioned a mandatory no special characters, it was not properly implemented. System is accepting the special characters.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Userentries.png]]&lt;br /&gt;
&lt;br /&gt;
'''UML Diagram'''&lt;br /&gt;
&lt;br /&gt;
The following diagram depicts the flow of events leading to validations.&lt;br /&gt;
&lt;br /&gt;
[[File:Uml for validation.png]]&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
=== Assignment Creation ===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
Below is the mock view of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
=== Assignment Edition ===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
Below is the mock display of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:Edit-new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
=== Addition of topics ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_add_topics.html.erb'' when New Topic link is clicked. This should show a form in that page to create topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/new.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle creation of topic and saving it to database.&lt;br /&gt;
&lt;br /&gt;
=== Editing topic ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_all_actions.html.erb'' when edit action is clicked. This should show a form in that page to edit topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/edit.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle editing  of topic and updating it to database.&lt;br /&gt;
&lt;br /&gt;
=== Make the table in topics tab sortable by its header ===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
=== Validating user entries ===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Correcting the code in edit assignment page too.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
=== Fixing Tooltips ===&lt;br /&gt;
On exploring, it was noticed that all the existing tooltips work. However, we intend to increase the proximity of the tooltips in the assignment tab by increasing the size of the images.&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red in rspec and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
&lt;br /&gt;
====Topic Creation/Editing====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Click 'New Topic' link or 'edit' action in topics table for a particular topic&lt;br /&gt;
* A pop window or form should be displayed in the same page&lt;br /&gt;
* Add topic details in that window/ form&lt;br /&gt;
* Save it&lt;br /&gt;
* Created or modified topic should be seen in topics table&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
===Automation testing===&lt;br /&gt;
The above tests all will be automated using rspec. Rspec Mock-ups will be created for checking the navigation flow of newly created React JS components.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
&lt;br /&gt;
We will try to convert edit assignment page in to React JS. Design pages more clearly.&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;br /&gt;
#''https://github.com/expertiza/expertiza/pull/855&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108598</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108598"/>
		<updated>2017-04-23T19:10:51Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Validating user entries */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
[https://en.wikipedia.org/wiki/React_(JavaScript_library) ReactJS] is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips - Needed to increase the proximity of the tool tips in the assignments tab.&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]] &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Add/Edit topics in Assignment ===&lt;br /&gt;
In current implementation whenever a topic is added to the assignment, a request is sent to the server and user is redirected to a form in another page. Upon creation of topic user is rendered back to edit assignment page. This process involves lot of redirection. Now, the task is to avoid this redirection of pages and create a interactive ReactJS form for adding and editing topic.&lt;br /&gt;
&lt;br /&gt;
Currently this logic is implemented in new method in sign_up_controller.rb file and is invoked in the _add_topics.rb ruby injection file. With this action new.html.erb page is rendered. This should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Add topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Add_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
Similar is the case for editing a topic. For editing a topic user is rendered to a form in edit page and again redirected to edit assignment page.&lt;br /&gt;
&lt;br /&gt;
'''Edit Topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Edit_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab_assignment.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintenance like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as&lt;br /&gt;
&lt;br /&gt;
This is essential in both new assignment or editing assignment page.&lt;br /&gt;
&lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* Though mentioned a mandatory no special characters, it was not properly implemented. System is accepting the special characters.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Userentries.png]]&lt;br /&gt;
&lt;br /&gt;
'''UML Diagram'''&lt;br /&gt;
&lt;br /&gt;
The following diagram depicts the flow of events leading to validations.&lt;br /&gt;
&lt;br /&gt;
[[File:Uml for validation.png]]&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
=== Assignment Creation ===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
Below is the mock view of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
=== Assignment Edition ===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
Below is the mock display of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:Edit-new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
=== Addition of topics ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_add_topics.html.erb'' when New Topic link is clicked. This should show a form in that page to create topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/new.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle creation of topic and saving it to database.&lt;br /&gt;
&lt;br /&gt;
=== Editing topic ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_all_actions.html.erb'' when edit action is clicked. This should show a form in that page to edit topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/edit.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle editing  of topic and updating it to database.&lt;br /&gt;
&lt;br /&gt;
=== Make the table in topics tab sortable by its header ===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
=== Validating user entries ===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Create alert messages to notify user if any important check boxes are missed.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
=== Fixing Tooltips ===&lt;br /&gt;
On exploring, it was noticed that all the existing tooltips work. However, we intend to increase the proximity of the tooltips in the assignment tab by increasing the size of the images.&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red in rspec and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
&lt;br /&gt;
====Topic Creation/Editing====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Click 'New Topic' link or 'edit' action in topics table for a particular topic&lt;br /&gt;
* A pop window or form should be displayed in the same page&lt;br /&gt;
* Add topic details in that window/ form&lt;br /&gt;
* Save it&lt;br /&gt;
* Created or modified topic should be seen in topics table&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
===Automation testing===&lt;br /&gt;
The above tests all will be automated using rspec. Rspec Mock-ups will be created for checking the navigation flow of newly created React JS components.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
&lt;br /&gt;
We will try to convert edit assignment page in to React JS. Design pages more clearly.&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;br /&gt;
#''https://github.com/expertiza/expertiza/pull/855&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108472</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108472"/>
		<updated>2017-04-13T01:39:22Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Problem Statement */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
[https://en.wikipedia.org/wiki/React_(JavaScript_library) ReactJS] is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips - Needed to increase the proximity of the tool tips in the assignments tab.&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]] &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Add/Edit topics in Assignment ===&lt;br /&gt;
In current implementation whenever a topic is added to the assignment, a request is sent to the server and user is redirected to a form in another page. Upon creation of topic user is rendered back to edit assignment page. This process involves lot of redirection. Now, the task is to avoid this redirection of pages and create a interactive ReactJS form for adding and editing topic.&lt;br /&gt;
&lt;br /&gt;
Currently this logic is implemented in new method in sign_up_controller.rb file and is invoked in the _add_topics.rb ruby injection file. With this action new.html.erb page is rendered. This should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Add topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Add_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
Similar is the case for editing a topic. For editing a topic user is rendered to a form in edit page and again redirected to edit assignment page.&lt;br /&gt;
&lt;br /&gt;
'''Edit Topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Edit_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab_assignment.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintainence like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as &lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Userentries.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
=== Assignment Creation ===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
Below is the mock view of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
=== Assignment Edition ===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
Below is the mock display of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:Edit-new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
=== Addition of topics ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_add_topics.html.erb'' when New Topic link is clicked. This should show a form in that page to create topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/new.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle creation of topic and saving it to database.&lt;br /&gt;
&lt;br /&gt;
=== Editing topic ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_all_actions.html.erb'' when edit action is clicked. This should show a form in that page to edit topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/edit.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle editing  of topic and updating it to database.&lt;br /&gt;
&lt;br /&gt;
=== Make the table in topics tab sortable by its header ===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
=== Validating user entries ===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Create alert messages to notify user if any important check boxes are missed.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
===UML Diagram===&lt;br /&gt;
&lt;br /&gt;
The following diagram depicts the flow for future.&lt;br /&gt;
&lt;br /&gt;
[[File:Uml for validation.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red in rspec and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
&lt;br /&gt;
====Topic Creation/Editing====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Click 'New Topic' link or 'edit' action in topics table for a particular topic&lt;br /&gt;
* A pop window or form should be displayed in the same page&lt;br /&gt;
* Add topic details in that window/ form&lt;br /&gt;
* Save it&lt;br /&gt;
* Created or modified topic should be seen in topics table&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
===Automation testing===&lt;br /&gt;
The above tests all will be automated using rspec. Rspec Mock-ups will be created for checking the navigation flow of newly created React JS components.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
&lt;br /&gt;
We will try to convert edit assignment page in to React JS. Design pages more clearly.&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;br /&gt;
#''https://github.com/expertiza/expertiza/pull/855&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108471</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108471"/>
		<updated>2017-04-13T01:38:10Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Problem Statement */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
[https://en.wikipedia.org/wiki/React_(JavaScript_library) ReactJS] is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips - Needed to increase the proximity of the tool tips in the assignment tab by increasing the size of the image.&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]] &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Add/Edit topics in Assignment ===&lt;br /&gt;
In current implementation whenever a topic is added to the assignment, a request is sent to the server and user is redirected to a form in another page. Upon creation of topic user is rendered back to edit assignment page. This process involves lot of redirection. Now, the task is to avoid this redirection of pages and create a interactive ReactJS form for adding and editing topic.&lt;br /&gt;
&lt;br /&gt;
Currently this logic is implemented in new method in sign_up_controller.rb file and is invoked in the _add_topics.rb ruby injection file. With this action new.html.erb page is rendered. This should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Add topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Add_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
Similar is the case for editing a topic. For editing a topic user is rendered to a form in edit page and again redirected to edit assignment page.&lt;br /&gt;
&lt;br /&gt;
'''Edit Topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Edit_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab_assignment.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintainence like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as &lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Userentries.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
=== Assignment Creation ===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
Below is the mock view of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
=== Assignment Edition ===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
Below is the mock display of what our implementation is going to look like:&lt;br /&gt;
&lt;br /&gt;
[[File:Edit-new_imp.png]]&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
=== Addition of topics ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_add_topics.html.erb'' when New Topic link is clicked. This should show a form in that page to create topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/new.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle creation of topic and saving it to database.&lt;br /&gt;
&lt;br /&gt;
=== Editing topic ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_all_actions.html.erb'' when edit action is clicked. This should show a form in that page to edit topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/edit.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle editing  of topic and updating it to database.&lt;br /&gt;
&lt;br /&gt;
=== Make the table in topics tab sortable by its header ===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
=== Validating user entries ===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Create alert messages to notify user if any important check boxes are missed.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
==== Files to be modified ====&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
===UML Diagram===&lt;br /&gt;
&lt;br /&gt;
The following diagram depicts the flow for future.&lt;br /&gt;
&lt;br /&gt;
[[File:Uml for validation.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red in rspec and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
&lt;br /&gt;
====Topic Creation/Editing====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Click 'New Topic' link or 'edit' action in topics table for a particular topic&lt;br /&gt;
* A pop window or form should be displayed in the same page&lt;br /&gt;
* Add topic details in that window/ form&lt;br /&gt;
* Save it&lt;br /&gt;
* Created or modified topic should be seen in topics table&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Login as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
===Automation testing===&lt;br /&gt;
The above tests all will be automated using rspec. Rspec Mock-ups will be created for checking the navigation flow of newly created React JS components.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
&lt;br /&gt;
We will try to convert edit assignment page in to React JS. Design pages more clearly.&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;br /&gt;
#''https://github.com/expertiza/expertiza/pull/855&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108274</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108274"/>
		<updated>2017-04-10T17:43:52Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Validating user entries */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
ReactJS is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips that don’t work&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Add/Edit topics in Assignment ===&lt;br /&gt;
In current implementation whenever a topic is added to the assignment, a request is sent to the server and user is redirected to a form in another page. Opon creation of topic user is rendered back to edit assignment page. This process involves lot of redirection. Now, the task is to avoid this redirection of pages and create a interactive React JS form for adding and editing topic.&lt;br /&gt;
&lt;br /&gt;
Currently this logic is implemented in new method in sign_up_controller.rb file and is invoked in the _add_topics.rb ruby injection file. With this action new.html.erb page is rendered. This should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Add topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Add_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
Similar is the case for editing a topic. For editing a topic user is rendered to a form in edit page and again redirected to edit assignment page.&lt;br /&gt;
&lt;br /&gt;
'''Edit Topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Edit_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab_assignment.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintainence like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as &lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Userentries.png]]&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
=== Addition of topics ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_add_topics.html.erb'' when New Topic link is clicked. This should show a form in that page to create topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/new.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle creation of topic and saving it to database.&lt;br /&gt;
&lt;br /&gt;
=== Editing topic ===&lt;br /&gt;
* An interactive React JS component should be created and should be called by the ruby injection page ''sign_up_sheet/_all_actions.html.erb'' when edit action is clicked. This should show a form in that page to edit topic.&lt;br /&gt;
* Delete/avoid usage of ''sign_up_sheet/edit.html.erb'' page.&lt;br /&gt;
* Implement an React JS functional component to handle editing  of topic and updating it to database.&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Create alert messages to notify user if any important check boxes are missed.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
The following diagram depicts the flow for future.&lt;br /&gt;
&lt;br /&gt;
[[File:Uml for validation.png]]&lt;br /&gt;
&lt;br /&gt;
===Files to be modified===&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red in rspec and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
&lt;br /&gt;
=== Topic Creation/Editing ===&lt;br /&gt;
* Login as an instructor ''(instructor6/password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Click 'New Topic' link or 'edit' action in topics table for a particular topic&lt;br /&gt;
* A pop window or form should be displayed in the same page&lt;br /&gt;
* Add topic details in that window/ form&lt;br /&gt;
* Save it&lt;br /&gt;
* Created or modified topic should be seen in topics table&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Login as an instructor ''(instructor6/password)''&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
===Automation testing===&lt;br /&gt;
The above tests all will be automated using rspec. Rspec Mock-ups will be created for checking the navigation flow of newly created React JS components.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
&lt;br /&gt;
We will try to convert edit assignment page in to React JS. Design pages more clearly.&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;br /&gt;
#''https://github.com/expertiza/expertiza/pull/855&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Uml_for_validation.png&amp;diff=108273</id>
		<title>File:Uml for validation.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Uml_for_validation.png&amp;diff=108273"/>
		<updated>2017-04-10T17:43:03Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: uploaded a new version of &amp;amp;quot;File:Uml for validation.png&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Uml_for_validation.png&amp;diff=108272</id>
		<title>File:Uml for validation.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Uml_for_validation.png&amp;diff=108272"/>
		<updated>2017-04-10T17:39:49Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: uploaded a new version of &amp;amp;quot;File:Uml for validation.png&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Uml_for_validation.png&amp;diff=108271</id>
		<title>File:Uml for validation.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Uml_for_validation.png&amp;diff=108271"/>
		<updated>2017-04-10T17:34:01Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108101</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108101"/>
		<updated>2017-04-07T22:10:08Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Test Plan */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
ReactJS is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips that don’t work&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Add/Delete topics in Assignment ===&lt;br /&gt;
In current implementation whenever a topic is added to the assignment, a request is sent to the server and user is redirected to a form in another page. Opon creation of topic user is rendered back to edit assignment page. This process involves lot of redirection. Now, the task is to avoid this redirection of pages and create a interactive React JS form for adding and editing topic.&lt;br /&gt;
&lt;br /&gt;
'''Add topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Add_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
Similar is the case for editing a topic. For editing a topic user is rendered to a form in edit page and again redirected to edit assignment page.&lt;br /&gt;
&lt;br /&gt;
'''Edit Topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Edit_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_asgmnt.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintainence like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as &lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Userentries.png]]&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
=== Addition of topics ===&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Create alert messages to notify user if any important check boxes are missed.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
===Files to be modified===&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red in rspec and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108063</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108063"/>
		<updated>2017-04-07T19:40:49Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Validating user entries */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
ReactJS is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips that don’t work&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Add/Delete topics in Assignment ===&lt;br /&gt;
In current implementation whenever a topic is added to the assignment, a request is sent to the server and user is redirected to a form in another page. Opon creation of topic user is rendered back to edit assignment page. This process involves lot of redirection. Now, the task is to avoid this redirection of pages and create a interactive React JS form for adding and editing topic.&lt;br /&gt;
&lt;br /&gt;
'''Add topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Add_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
Similar is the case for editing a topic. For editing a topic user is rendered to a form in edit page and again redirected to edit assignment page.&lt;br /&gt;
&lt;br /&gt;
'''Edit Topic:'''&lt;br /&gt;
&lt;br /&gt;
[[File:Edit_topic_form.PNG]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintainence like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as &lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Userentries.png]]&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
=== Addition of topics ===&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Create alert messages to notify user if any important check boxes are missed.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
===Files to be modified===&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108062</id>
		<title>File:Userentries.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108062"/>
		<updated>2017-04-07T19:39:43Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: uploaded a new version of &amp;amp;quot;File:Userentries.png&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108060</id>
		<title>File:Userentries.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Userentries.png&amp;diff=108060"/>
		<updated>2017-04-07T19:35:07Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:WhatsApp_Image_2017-04-07_at_3.21.59_PM.jpeg&amp;diff=108056</id>
		<title>File:WhatsApp Image 2017-04-07 at 3.21.59 PM.jpeg</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:WhatsApp_Image_2017-04-07_at_3.21.59_PM.jpeg&amp;diff=108056"/>
		<updated>2017-04-07T19:26:20Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: uploaded a new version of &amp;amp;quot;File:WhatsApp Image 2017-04-07 at 3.21.59 PM.jpeg&amp;amp;quot;: Validating user entries current imlementation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Current implementation on validating user entries&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:WhatsApp_Image_2017-04-07_at_3.21.59_PM.jpeg&amp;diff=108054</id>
		<title>File:WhatsApp Image 2017-04-07 at 3.21.59 PM.jpeg</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:WhatsApp_Image_2017-04-07_at_3.21.59_PM.jpeg&amp;diff=108054"/>
		<updated>2017-04-07T19:24:55Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: Current implementation on validating user entries&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Current implementation on validating user entries&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108044</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108044"/>
		<updated>2017-04-07T18:17:14Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Current Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
ReactJS is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips that don’t work&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintainence like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as &lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Create alert messages to notify user if any important check boxes are missed.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
===Files to be modified===&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108043</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108043"/>
		<updated>2017-04-07T18:16:06Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Validating user entries */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
ReactJS is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips that don’t work&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintainence like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as &lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Create alert messages to notify user if any important check boxes are missed.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
===Files to be modified===&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108042</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108042"/>
		<updated>2017-04-07T18:14:49Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* ReactJS */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
ReactJS is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips that don’t work&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintainence like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as &lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* User can add sub directories in similar way as assignment name.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Create alert messages to notify user if any important check boxes are missed.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
===Files to be modified===&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108041</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108041"/>
		<updated>2017-04-07T18:14:28Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* ReactJS */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
[ReactJS] is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips that don’t work&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintainence like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as &lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* User can add sub directories in similar way as assignment name.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Create alert messages to notify user if any important check boxes are missed.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
===Files to be modified===&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108040</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108040"/>
		<updated>2017-04-07T18:12:07Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Validating user entries */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
ReactJS is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. Also, edit page is reloaded whenever a topic is added. The task is to convert this pages into ReactJS components.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips that don’t work&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintainence like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as &lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* User can add sub directories in similar way as assignment name.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Add the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Create alert messages to notify user if any important check boxes are missed.&lt;br /&gt;
* Create validation for edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
===Files to be modified===&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108038</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108038"/>
		<updated>2017-04-07T18:06:16Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* ReactJS */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
ReactJS is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. The task is to convert this form into ReactJS component.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips that don’t work&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintainence like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as &lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* User can add sub directories in similar way as assignment name.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Adding the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Alert messages to notify user if any important check boxes are missed.&lt;br /&gt;
* Validating edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
===Files to be modified===&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108037</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108037"/>
		<updated>2017-04-07T18:05:17Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Test Plan */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
ReactJS is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale &lt;br /&gt;
&lt;br /&gt;
===Pros===&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. The task is to convert this form into ReactJS component.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips that don’t work&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintainence like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as &lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* User can add sub directories in similar way as assignment name.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Adding the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Alert messages to notify user if any important check boxes are missed.&lt;br /&gt;
* Validating edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
===Files to be modified===&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
Rails development is the Test Driven development, which helps in ensuring the implementation of all proposed implementations. We will be writing all the implementations proposed as tests that will eventually be red and try to make them green by adding to the development part.&lt;br /&gt;
&lt;br /&gt;
For now the manual testing of these current implementations can help in testing the functionality from UI.&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
====Validating user entries====&lt;br /&gt;
*Log in as an instructor ''(user-name:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Try adding the assignment using the weird names, with special symbols, ignoring check boxes&lt;br /&gt;
*Verify if the assignment is shown in the table.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108036</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108036"/>
		<updated>2017-04-07T17:49:33Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Proposed Solution */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
ReactJS is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale &lt;br /&gt;
&lt;br /&gt;
===Pros===&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. The task is to convert this form into ReactJS component.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips that don’t work&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintainence like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as &lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* User can add sub directories in similar way as assignment name.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The following tasks are to be implemented to achieve users validation,&lt;br /&gt;
* Adding the regular expression validation to avoid special characters in the names of assignment or directories.&lt;br /&gt;
* Alert messages to notify user if any important check boxes are missed.&lt;br /&gt;
* Validating edge cases like giving empty values.&lt;br /&gt;
&lt;br /&gt;
===Files to be modified===&lt;br /&gt;
As, the project needs to be implemented in reactJS, which helps in reducing the complexing binding in MVC framework, only changing the javascript file can help to achieve this without changing model,&lt;br /&gt;
* app/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(username:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(username:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
We will automate the tests following the same steps described above using rspec.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108035</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=108035"/>
		<updated>2017-04-07T17:35:31Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Validating user entries */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
ReactJS is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale &lt;br /&gt;
&lt;br /&gt;
===Pros===&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. The task is to convert this form into ReactJS component.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips that don’t work&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
[[File:Create1.JPG]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Create2.JPG]]&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
[[File:Edit.jpg]]&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable using ReactJS by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintainence like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as &lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* User can add sub directories in similar way as assignment name.&lt;br /&gt;
* Neglecting check boxes may lead to confusion with deadlines.&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The new implementation will use ReactJS to generate a drop-down window on clicking on the New Assignment button (private/public) , providing same features as before. Database entry is made on submitting the form and the form is closed.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/assets/javascripts/tree_display.jsx.erb&lt;br /&gt;
*apps/controllers/assignments_controller.rb&lt;br /&gt;
*apps/controllers/tree_display_controller.rb&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation, in the new implementation, using ReactJS, when the edit assignment button is clicked, instead of making a server request and rendering a new view, a drop down window appears and saving the details will make the database entry.Since all the processing is done on the client side there will be decrease in the number of server requests.&lt;br /&gt;
&lt;br /&gt;
====Files to be modified====&lt;br /&gt;
*apps/views/tree_display/list.html.erb&lt;br /&gt;
*apps/views/assignments/edit.html.erb&lt;br /&gt;
*apps/views/assignments/edit/_general.html.erb&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Following sub-tasks identified to implement sortable feature for topics table.&lt;br /&gt;
* Modify sign_up_sheet/_table_header.html.erb partial to change the table header fields to sortable type.&lt;br /&gt;
* Add sort functionality using ReactJS for each column that is meaningful to be sorted.&lt;br /&gt;
&lt;br /&gt;
==Test Plan==&lt;br /&gt;
===Manual Testing===&lt;br /&gt;
Steps to manually test the feature are as follows: &lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(username:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the 'New public assignment' or 'New private assignment' button&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make valid entries for the available fields and click on 'create'.&lt;br /&gt;
*Verify if new assignment is successfully created.&lt;br /&gt;
&lt;br /&gt;
====Assignment Creation====&lt;br /&gt;
*Log in as an instructor ''(username:instructor6 password:password)''&lt;br /&gt;
*Go to Manage-&amp;gt;Assignments and click on the Assignments tab.&lt;br /&gt;
*Click on the Edit button for any of the available assignment.&lt;br /&gt;
*Verify if drop-down window is displayed.&lt;br /&gt;
*Make changes and click on 'save'.&lt;br /&gt;
*Verify if the changes made are successfully updated.&lt;br /&gt;
 &lt;br /&gt;
====Make the table in topics tab sortable by its header====&lt;br /&gt;
* Create an assignment&lt;br /&gt;
* Add 2 topics to the assignment&lt;br /&gt;
* Click sort on Topic ID and check if they are sorted&lt;br /&gt;
* Click sort on Topic title and check if they are sorted&lt;br /&gt;
* Similarly test using other columns&lt;br /&gt;
&lt;br /&gt;
We will automate the tests following the same steps described above using rspec.&lt;br /&gt;
&lt;br /&gt;
==Future Work==&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#''http://railscasts.com/episodes/228-sortable-table-columns sortable-columns''&lt;br /&gt;
#''https://www.airpair.com/reactjs/posts/reactjs-a-guide-for-rails-developers adding-reactjs''&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=107994</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=107994"/>
		<updated>2017-04-07T03:37:33Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Current Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
This page is a part of CSC/ECE 517 Final Project for Spring 2017 to describe the changes made by us to the open source software project Expertiza. We are converting the assignment creation form to ReactJS. Following contains a brief introduction to Expertiza, ReactJS followed by the problems we are tackling, our strategy for the implementation and the test plan.&lt;br /&gt;
   &lt;br /&gt;
==Expertiza==&lt;br /&gt;
Expertiza is a Ruby on Rails based web application where students can submit and peer review learning objects such as codes, articles, websites etc., It is an open source software project funded by National Science Foundation(NSF). The instructor has the capability to create assignments with varied specifications such as topics, courses, team size, level of reviews etc., later review the submitted work and provide feedback. Students can enter their submissions and also review others' work. &lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
ReactJS is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale &lt;br /&gt;
&lt;br /&gt;
===Pros===&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
The Assignment Create and Edit Form are multi level forms. It consists of multiple inputs  and user interactions. Many input types have dependency on interactions by the user. For example, on check for a particular checkbox, remaining form is displayed. The task is to convert this form into ReactJS component.&lt;br /&gt;
&lt;br /&gt;
'''Tasks to be done'''&lt;br /&gt;
*Organize the form layout, create several mockups and validate them to your users&lt;br /&gt;
*Make the table in topics tab sortable by its header&lt;br /&gt;
*Allow users to edit / add topics in the table instead of loading a new page&lt;br /&gt;
*Implement the new layout and convert the javascript to a ReactJS component&lt;br /&gt;
*Validate user entries&lt;br /&gt;
*Fix tooltips that don’t work&lt;br /&gt;
&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
===Assignment Creation===&lt;br /&gt;
The assignment creation form consists of multiple inputs and requires interactions from the user. The current implementation is mostly in HTML with data validations being done by JQuery. When a user wants to create a new assignment by clicking the new assignment button, a server request is generated and new view is rendered. Again, another server request to make database entry is generated once the user fills in the data and clicks on 'save' button and again a new view is rendered. This kind of implementation doesn't support dynamic view rendering hence lacks the fluidity in overall user experience that one would expect.&lt;br /&gt;
&lt;br /&gt;
===Assignment Edition===&lt;br /&gt;
Similar to assignment creation page, edit page lacks the dynamic view rendering which makes the user experience cumbersome. Every time user wants to make changes to the assignment, a server request is generated and new view is rendered. The save button hit on completion will again generate another server request and render a new view.&lt;br /&gt;
&lt;br /&gt;
===Make the table in topics tab sortable by its header===&lt;br /&gt;
Currently after creating an assignment, we can add topics related to the assignment. The &amp;quot;Topics&amp;quot; tab in the edit assignment form shows the list of topics that are added to the assignment. The picture below shows the current page for displaying the list of topics of an assignment. The list is not sortable. The task is to make it sortable by topic id, topic name, Num. of slots, Available slots, Num. on waitlist columns as sorting on remaining columns doesn't give any meaningful display.&lt;br /&gt;
&lt;br /&gt;
[[File:topics_tab.png]]&lt;br /&gt;
&lt;br /&gt;
===Validating user entries===&lt;br /&gt;
The entries for the assignment creation are not according to any restrictions, that can add problem to database maintainence like sorting the entries, comparing them, retrieving. There are many such problem causing situations in the new assignment form, such as &lt;br /&gt;
* User can add the number as new assignment name or he can give only special characters for it like &amp;quot;$$$$&amp;quot;.&lt;br /&gt;
* User can add sub directories in similar way as assignment name.&lt;br /&gt;
&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
==Test Plan==&lt;br /&gt;
==Future Work==&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=107984</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=107984"/>
		<updated>2017-04-07T02:00:09Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* ReactJS */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
&lt;br /&gt;
==Expertiza==&lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
ReactJS is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
* It has every functionality that an user interface required&lt;br /&gt;
* Easy data binding.&lt;br /&gt;
* Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
* Fast and efficient&lt;br /&gt;
* Easy to scale &lt;br /&gt;
&lt;br /&gt;
===Pros===&lt;br /&gt;
&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
==Test Plan==&lt;br /&gt;
==Future Work==&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=107927</id>
		<title>CSC/ECE 517 Spring 2017/Convert Assignment Creation Form to ReactJS</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2017/Convert_Assignment_Creation_Form_to_ReactJS&amp;diff=107927"/>
		<updated>2017-04-06T00:53:21Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
&lt;br /&gt;
==Expertiza==&lt;br /&gt;
&lt;br /&gt;
==ReactJS==&lt;br /&gt;
ReactJS is the javascript framework developed by Facebook to solve the specific problem, ''UI rendering''. It is developed to solve the problem with complex binding in MVC framework using only one-way data binding. It is used for dynamic reloading of the page. It helps in reloading only the particular component required using Virtual DOM, which makes it fast by temporarily storing DOM&lt;br /&gt;
&lt;br /&gt;
'''Reasons for using ReactJS'''&lt;br /&gt;
It has every functionality that an user interface required&lt;br /&gt;
Easy data binding.&lt;br /&gt;
Only single component changes are stored/changed without reloading the complete page.&lt;br /&gt;
Fast and efficient&lt;br /&gt;
Easy to scale &lt;br /&gt;
&lt;br /&gt;
===Pros===&lt;br /&gt;
==Problem Statement==&lt;br /&gt;
==Current Implementation==&lt;br /&gt;
==Proposed Solution==&lt;br /&gt;
==Test Plan==&lt;br /&gt;
==Future Work==&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=User:Rpothir&amp;diff=107666</id>
		<title>User:Rpothir</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=User:Rpothir&amp;diff=107666"/>
		<updated>2017-03-31T21:08:51Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Test Plan and Development */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the work on the OSS project titled '''E1716-Improve email notifications''' for the course CSC/ECE 517,  Spring 2017.&lt;br /&gt;
&lt;br /&gt;
== Expertiza==&lt;br /&gt;
&lt;br /&gt;
Expertiza is an online collaboration tool for the students and instructors. It is an open source project developed on Ruby on Rails platform. It has several features that help the users to contribute jointly by creating the list of users by importing CSV file, assigning work, share the work, giving reviews, forming teams and finally notifying every action using email notifications.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
== Motivation ==&lt;br /&gt;
&lt;br /&gt;
Though expertiza is a great platform, there are quite a few enhancements in sending emails to users on the reviews, deadlines and accounts creations. So this contribution helps in learning to contribute to open source projects. &lt;br /&gt;
&lt;br /&gt;
==Description of the current project ==&lt;br /&gt;
The existing functionality implements the email notifications' feature in response to certain events. However, there are cases where email notifications are sent which are redundant as well as cases where email notifications need to be sent but are not sent. The current project aims at improving this email-notification functionality. For example, Expertiza uses a peer review system wherein, after the first round of submission, submitted work is peer reviewed. Using the recommendations made and the improvements suggested in the peer reviews, an assignment participant can then proceed to improve his work. Thus, a participant is notified via email whenever a review for his/her submitted work is provided. Similarly, a reviewer is notified via email when a new submission is made for the work that he/she reviewed. Now, if the participant makes an improvement in his/her submission after the last round of reviews has been done, sending an email to the reviewer regarding this is redundant. However, in the current state of application, a reviewer is notified in this case too. Thus, there are similar cases, where the email notification needs to be enabled/disabled and that is the objective of our project.&lt;br /&gt;
&lt;br /&gt;
==Peer Review Information==&lt;br /&gt;
For users intending to view the deployed Expertiza associated with this assignment, the user login credentials are below:&lt;br /&gt;
user_name:            'expertiza.development@gmail.com' &lt;br /&gt;
password:              'qwer@1234'&lt;br /&gt;
&lt;br /&gt;
The issues/tasks that needed modifications were identified:&lt;br /&gt;
&lt;br /&gt;
1. Notify an instructor by e-mail when a student suggests a topic.&lt;br /&gt;
&lt;br /&gt;
2. The email message telling reviewers to revise their reviews should not be sent after the last review deadline has passed.&lt;br /&gt;
&lt;br /&gt;
3.Send out an email to the invitee when a participant sends out an invitation to another participant to join a team.  &lt;br /&gt;
&lt;br /&gt;
4. The student who issued the invitation should also be e-mailed when the invitee joins the team.&lt;br /&gt;
&lt;br /&gt;
5. Create an option (in the instructor’s profile) to get a copy of ‘e-mails being sent to students (this is so the instructor can verify correct functioning of the system).&lt;br /&gt;
&lt;br /&gt;
6.When students' accounts are created by importing a CSV file on the Users page, they receive e-mails with their user-ID and password. But if an account is created by adding them as participants to an assignment when they don't already have an account, e-mail is not sent. Students should receive e-mails upon account creation, regardless of how their account is created. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Test Plan and Development ==&lt;br /&gt;
&lt;br /&gt;
'''Topic Suggestion'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Test plan:'''&lt;br /&gt;
&lt;br /&gt;
The mail should be sent to the instructor as soon as a new topic is suggested by the student. Since the process going here is a method call and mailer invocation, corresponding tests to check whether the emails are sent to instructor have been written in the RSpec.&lt;br /&gt;
&lt;br /&gt;
[[File:suggestion test.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Development:'''&lt;br /&gt;
&lt;br /&gt;
Earlier Scenario: &lt;br /&gt;
&lt;br /&gt;
Some of the assignments have an option to suggest a topic to the instructor. But when a student suggests a topic, this event is not notified to the instructor leaving it to go unnoticed and the student must mail the instructor regarding the suggestion.&lt;br /&gt;
&lt;br /&gt;
Updates/Changes: &lt;br /&gt;
&lt;br /&gt;
The suggestions controller is modified so that whenever a student suggests a topic, an email is sent to the professor. The changes made are shown below.&lt;br /&gt;
&lt;br /&gt;
Updated the controllers/suggestion_controller.rb so that whenever a new suggestion is getting saved it must invoke the mailer function. This is also being done when the suggestion is getting accepted too.&lt;br /&gt;
[[File:suggestion save.jpg]]&lt;br /&gt;
&lt;br /&gt;
The mailer function as shown below contains the to address which is the instructor's email address, the subject along with the topic name and body with the proposer's details. This function invokes the suggestion_topic function in the mailer which send the mail.&lt;br /&gt;
&lt;br /&gt;
[[File:suggestion mail call.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As mentioned above the function defined in the mailer send the mail in the following format to the instructor.&lt;br /&gt;
&lt;br /&gt;
[[File:suggestion mailer.jpg]]&lt;br /&gt;
&lt;br /&gt;
The mail format and view would be&lt;br /&gt;
&lt;br /&gt;
[[File:suggestion view.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Inviting a participant to join the team'''&lt;br /&gt;
&lt;br /&gt;
'''Test Plan'''&lt;br /&gt;
&lt;br /&gt;
The main features to test in this particular task is to make sure that the defined methods are getting called at right times with the right parameters. Also, it is required to test whether the mailer is invoked at right time thereby avoiding unnecessary emails. Here, both the controller and mailers are being tested. The RSpec tests for both the invitation and acceptance are mentioned below. &lt;br /&gt;
&lt;br /&gt;
[[File:invitation test.jpg]]&lt;br /&gt;
&lt;br /&gt;
'''Development'''&lt;br /&gt;
&lt;br /&gt;
Earlier Scenario:&lt;br /&gt;
&lt;br /&gt;
Whenever a user invites another participant to join the team, he/she can just add them in expertiza and must wait until the participant logs into expertiza to see the invitation. &lt;br /&gt;
&lt;br /&gt;
Changes/Updates:&lt;br /&gt;
&lt;br /&gt;
We have included the mailer call whenever a user is inviting a participant so that an email is sent out stating that an invitation is pending.&lt;br /&gt;
&lt;br /&gt;
Whenever a new invitation is created and set into waiting status, the email is call is made in controllers/invitation_controller.rb &lt;br /&gt;
&lt;br /&gt;
[[File:invitation call.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The email call calls a function named 'accept_invitation' in the invitation controller where the appropriate fields required for the email are gathered and the mailer is called.&lt;br /&gt;
&lt;br /&gt;
[[File:invitation fun.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In the mailer, the 'accept_invitation' function is invoked where the to address is addressed to the participant who is being invited.&lt;br /&gt;
&lt;br /&gt;
[[File:invitation mailer.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The format of the mail being set is customized in views/mailer/accept_invitation.html.erb as shown below.&lt;br /&gt;
&lt;br /&gt;
[[File:invitation view.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Notification regarding the Accepted Invitation'''&lt;br /&gt;
&lt;br /&gt;
Earlier scenario: &lt;br /&gt;
&lt;br /&gt;
As mentioned earlier, whenever a participant accepts the team invitation the user who sent the invitation gets to know about the news only after logging into Expertiza which may take longer to form the team. &lt;br /&gt;
&lt;br /&gt;
Changes/Updates:&lt;br /&gt;
&lt;br /&gt;
So here, we have included a mailer so that whenever a participant accepts the team request, an email is sent to the user who invited him/her. This makes sure that the user who invited has been notified immediately after the team request has been accepted thereby avoiding delays in team formation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Whenever a new invitation is accepted the status is confirmed and the email call is made in controllers/invitation_controller.rb &lt;br /&gt;
&lt;br /&gt;
[[File:accepted call.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The email call calls a function named 'accepted_invitation' in the invitation controller where the appropriate fields required for the email are gathered and the mailer is called.&lt;br /&gt;
&lt;br /&gt;
[[File:accepted fun.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In the mailer, the 'accepted_invitation' function is invoked where the to address is addressed to the user who invited the participant to join the team in the first place.&lt;br /&gt;
&lt;br /&gt;
[[File:accepted mailer.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The format of the mail being set is customized in views/mailer/accepted_invitation.html.erb as shown below.&lt;br /&gt;
&lt;br /&gt;
[[File:accepted view.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Copy of emails to Instructor'''&lt;br /&gt;
&lt;br /&gt;
Proposal: &lt;br /&gt;
&lt;br /&gt;
To creation an option to get a copy of ‘e-mails being sent to students so the instructor can verify correct functioning of the system.&lt;br /&gt;
&lt;br /&gt;
Changes: &lt;br /&gt;
&lt;br /&gt;
In regard with the proposal, we created an option in the instructor profile which allows the instructor to get all the emails that are being sent to the students. On consultation with the instructor, the instructor email was added as cc in the mails being sent. For this, a new migration is done on database to add a new column of Boolean data type. &lt;br /&gt;
&lt;br /&gt;
In the profile of the instructor a check box is added to facilitate instructors to receive the copy of mails sent to students.&lt;br /&gt;
&lt;br /&gt;
[[File:copy_of_all_mails.jpg]]&lt;br /&gt;
&lt;br /&gt;
Inside the mailer, the option is checked and if satisfied, all the generic mails are also forwarded to the instructor.&lt;br /&gt;
&lt;br /&gt;
[[File:mailer.jpg]]&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=User:Rpothir&amp;diff=107662</id>
		<title>User:Rpothir</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=User:Rpothir&amp;diff=107662"/>
		<updated>2017-03-31T20:09:36Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: /* Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the work on the OSS project titled '''E1716-Improve email notifications''' for the course CSC/ECE 517,  Spring 2017.&lt;br /&gt;
&lt;br /&gt;
== Expertiza==&lt;br /&gt;
&lt;br /&gt;
Expertiza is an online collaboration tool for the students and instructors. It is an open source project developed on Ruby on Rails platform. It has several features that help the users to contribute jointly by creating the list of users by importing CSV file, assigning work, share the work, giving reviews, forming teams and finally notifying every action using email notifications.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
== Motivation ==&lt;br /&gt;
&lt;br /&gt;
Though expertiza is a great platform, there are quite a few enhancements in sending emails to users on the reviews, deadlines and accounts creations. So this contribution helps in learning to contribute to open source projects. &lt;br /&gt;
&lt;br /&gt;
==Description of the current project ==&lt;br /&gt;
The existing functionality implements the email notifications' feature in response to certain events. However, there are cases where email notifications are sent which are redundant as well as cases where email notifications need to be sent but are not sent. The current project aims at improving this email-notification functionality. For example, Expertiza uses a peer review system wherein, after the first round of submission, submitted work is peer reviewed. Using the recommendations made and the improvements suggested in the peer reviews, an assignment participant can then proceed to improve his work. Thus, a participant is notified via email whenever a review for his/her submitted work is provided. Similarly, a reviewer is notified via email when a new submission is made for the work that he/she reviewed. Now, if the participant makes an improvement in his/her submission after the last round of reviews has been done, sending an email to the reviewer regarding this is redundant. However, in the current state of application, a reviewer is notified in this case too. Thus, there are similar cases, where the email notification needs to be enabled/disabled and that is the objective of our project.&lt;br /&gt;
&lt;br /&gt;
==Peer Review Information==&lt;br /&gt;
For users intending to view the deployed Expertiza associated with this assignment, the user login credentials are below:&lt;br /&gt;
user_name:            'expertiza.development@gmail.com' &lt;br /&gt;
password:              'qwer@1234'&lt;br /&gt;
&lt;br /&gt;
The issues/tasks that needed modifications were identified:&lt;br /&gt;
&lt;br /&gt;
1. Notify an instructor by e-mail when a student suggests a topic.&lt;br /&gt;
&lt;br /&gt;
2. The email message telling reviewers to revise their reviews should not be sent after the last review deadline has passed.&lt;br /&gt;
&lt;br /&gt;
3.Send out an email to the invitee when a participant sends out an invitation to another participant to join a team.  &lt;br /&gt;
&lt;br /&gt;
4. The student who issued the invitation should also be e-mailed when the invitee joins the team.&lt;br /&gt;
&lt;br /&gt;
5. Create an option (in the instructor’s profile) to get a copy of ‘e-mails being sent to students (this is so the instructor can verify correct functioning of the system).&lt;br /&gt;
&lt;br /&gt;
6.When students' accounts are created by importing a CSV file on the Users page, they receive e-mails with their user-ID and password. But if an account is created by adding them as participants to an assignment when they don't already have an account, e-mail is not sent. Students should receive e-mails upon account creation, regardless of how their account is created. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Test Plan and Development ==&lt;br /&gt;
&lt;br /&gt;
'''Topic Suggestion'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Test plan:'''&lt;br /&gt;
&lt;br /&gt;
The mail should be sent to the instructor as soon as a new topic is suggested by the student. Since the process going here is a method call and mailer invocation, corresponding tests to check whether the mails are sent to instructor have been written in the RSpec.&lt;br /&gt;
&lt;br /&gt;
[[File:suggestion test.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Development:'''&lt;br /&gt;
&lt;br /&gt;
Earlier Scenario: &lt;br /&gt;
&lt;br /&gt;
Some of the assignments have an option to suggest a topic to the instructor. But when a student suggests a topic, this event is not notified to the instructor leaving it to go unnoticed and the student must mail the instructor regarding the suggestion.&lt;br /&gt;
&lt;br /&gt;
Updates/Changes: &lt;br /&gt;
&lt;br /&gt;
The suggestions controller is modified so that whenever a student suggests a topic, an email is sent to the professor. The changes made are shown below.&lt;br /&gt;
&lt;br /&gt;
Updated the controllers/suggestion_controller.rb so that whenever a new suggestion is getting saved it must invoke the mailer function. This is also being done when the suggestion is getting accepted too.&lt;br /&gt;
[[File:suggestion save.jpg]]&lt;br /&gt;
&lt;br /&gt;
The mailer function as shown below contains the to: address which is the instructor's email address, the subject along with the topic name and body with the proposer's details. This function invokes the suggestion_topic function in the mailer which send the mail.&lt;br /&gt;
&lt;br /&gt;
[[File:suggestion mail call.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As mentioned above the function defined in the mailer send the mail in the following format to the instructor.&lt;br /&gt;
&lt;br /&gt;
[[File:suggestion mailer.jpg]]&lt;br /&gt;
&lt;br /&gt;
The mail format and view would be&lt;br /&gt;
&lt;br /&gt;
[[File:suggestion view.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Inviting a participant to join the team'''&lt;br /&gt;
&lt;br /&gt;
'''Test Plan'''&lt;br /&gt;
&lt;br /&gt;
The main features to test in this particular task is to make sure that the defined methods are getting called at right times with the right parameters. Also, it is required to test whether the mailer is invoked at right time thereby avoiding unnecessary emails. Here, both the controller and mailers are being tested. The RSpec tests for both the invitation and acceptance are mentioned below. &lt;br /&gt;
&lt;br /&gt;
[[File:invitation test.jpg]]&lt;br /&gt;
&lt;br /&gt;
'''Development'''&lt;br /&gt;
&lt;br /&gt;
Earlier Scenario:&lt;br /&gt;
&lt;br /&gt;
Whenever a user invites another participant to join the team, he/she can just add them in expertiza and must wait until the participant logs into expertiza to see the invitation. &lt;br /&gt;
&lt;br /&gt;
Changes/Updates:&lt;br /&gt;
&lt;br /&gt;
We have included the mailer call whenever a user is inviting a participant so that an email is sent out stating that an invitation is pending.&lt;br /&gt;
&lt;br /&gt;
Whenever a new invitation is created and set into waiting status, the email is call is made in controllers/invitation_controller.rb &lt;br /&gt;
&lt;br /&gt;
[[File:invitation call.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The email call calls a function named 'accept_invitation' in the invitation controller where the appropriate fields required for the email are gathered and the mailer is called.&lt;br /&gt;
&lt;br /&gt;
[[File:invitation fun.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In the mailer, the 'accept_invitation' function is invoked where the to address is addressed to the participant who is being invited.&lt;br /&gt;
&lt;br /&gt;
[[File:invitation mailer.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The format of the mail being set is customized in views/mailer/accept_invitation.html.erb as shown below.&lt;br /&gt;
&lt;br /&gt;
[[File:invitation view.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Notification regarding the Accepted Invitation'''&lt;br /&gt;
&lt;br /&gt;
Earlier scenario: &lt;br /&gt;
&lt;br /&gt;
As mentioned earlier, whenever a participant accepts the team invitation the user who sent the invitation gets to know about the news only after logging into Expertiza which may take longer to form the team. &lt;br /&gt;
&lt;br /&gt;
Changes/Updates:&lt;br /&gt;
&lt;br /&gt;
So here, we have included a mailer so that whenever a participant accepts the team request, an email is sent to the user who invited him/her. This makes sure that the user who invited has been notified immediately after the team request has been accepted thereby avoiding delays in team formation.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Whenever a new invitation is accepted the status is confirmed and the email call is made in controllers/invitation_controller.rb &lt;br /&gt;
&lt;br /&gt;
[[File:accepted call.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The email call calls a function named 'accepted_invitation' in the invitation controller where the appropriate fields required for the email are gathered and the mailer is called.&lt;br /&gt;
&lt;br /&gt;
[[File:accepted fun.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In the mailer, the 'accepted_invitation' function is invoked where the to address is addressed to the user who invited the participant to join the team in the first place.&lt;br /&gt;
&lt;br /&gt;
[[File:accepted mailer.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The format of the mail being set is customized in views/mailer/accepted_invitation.html.erb as shown below.&lt;br /&gt;
&lt;br /&gt;
[[File:accepted view.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Copy of emails to Instructor'''&lt;br /&gt;
&lt;br /&gt;
Proposal: In&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=User:Rpothir&amp;diff=106965</id>
		<title>User:Rpothir</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=User:Rpothir&amp;diff=106965"/>
		<updated>2017-03-19T01:03:06Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The wiki page describes the work on OSS project titled '''E1716-Improve email notifications''' for Spring 2017&lt;br /&gt;
&lt;br /&gt;
== Expertiza==&lt;br /&gt;
&lt;br /&gt;
Expertiza is an online collaboration tool for the students and instructors. It is an open source project developed on Ruby on Rails platform. It has several features that helps users to contribute jointly by creating the list of users by importing csv file, assigning work, share the work, giving reviews, forming teams and finally notifying every action using email notifications.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
== Motivation ==&lt;br /&gt;
&lt;br /&gt;
Though expertiza is a great platform, there are quite a few enhancements in sending emails to users on the reviews, deadlines and accounts creations. So this contribution helps in learning to contribute to an open source projects.&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=User:Rpothir&amp;diff=106964</id>
		<title>User:Rpothir</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=User:Rpothir&amp;diff=106964"/>
		<updated>2017-03-18T18:11:10Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: Added introduction&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The wiki page describes the work on OSS project titled '''E1716-Improve email notifications''' for Spring 2017&lt;br /&gt;
&lt;br /&gt;
== Expertiza==&lt;br /&gt;
&lt;br /&gt;
Expertiza is an online collaboration tool for the students and instructors. It is an open source project developed on Ruby on Rails platform. It has several features that helps users to contribute jointly by creating the list of users by importing csv file, assigning work, share the work, giving reviews, forming teams and finally notifying every action using email notifications.&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=User:Rpothir&amp;diff=106963</id>
		<title>User:Rpothir</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=User:Rpothir&amp;diff=106963"/>
		<updated>2017-03-18T17:41:06Z</updated>

		<summary type="html">&lt;p&gt;Rpothir: just started page&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The wiki page describes the work on OSS project titled '''E1716-Improve email notifications''' for Spring 2017&lt;/div&gt;</summary>
		<author><name>Rpothir</name></author>
	</entry>
</feed>