<?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=Rbhasin</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=Rbhasin"/>
	<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Special:Contributions/Rbhasin"/>
	<updated>2026-08-06T23:54:23Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.41.0</generator>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1877_Sort_instructor_reports_by_name,_ID,_score,_etc&amp;diff=121487</id>
		<title>E1877 Sort instructor reports by name, ID, score, etc</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1877_Sort_instructor_reports_by_name,_ID,_score,_etc&amp;diff=121487"/>
		<updated>2018-12-11T05:43:43Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Issue 2 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1877 OSS final project for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: Username: super_administrator2 Password: password&lt;br /&gt;
* Youtube Link: https://youtu.be/ZhXLnN5kpW8&lt;br /&gt;
* Github Pull-Request Link: https://github.com/expertiza/expertiza/pull/1287&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows instructors to view kinds of reports of assignments in their courses such as submissions, scores, and review reports. To improve the report views, some table columns such as team name, score, the average should be made sortable by using the same existing sort library.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done? =====&lt;br /&gt;
&lt;br /&gt;
* '''#issue 1:''' For “view submissions” table, sort “Topic name”, “Team name”, “Team member(s)”, “Links” alphabetically.&lt;br /&gt;
[[File:1_1877.png]]&lt;br /&gt;
&lt;br /&gt;
* '''#issue 2:''' For “View scores” table, sort “Team” alphabetically, sort “Average” and “Range” (the first percentage) in both ascending or descending order.&lt;br /&gt;
[[File:2_1877.png]]&lt;br /&gt;
&lt;br /&gt;
* '''#issue 3:''' For “View review report” table, “Reviewer” and “Metric” are already sortable, so we need to make other columns sortable: sort “Review done” by the first number than the second number (e.g., 0/1, 0/2, 0/3, 1/1, 1/5, 2/2...), sort “Team reviewed” alphabetically and sort “Score awarded / Avg. score” (the first percentage) in both ascending or descending order.&lt;br /&gt;
[[File:3_1877.png]]&lt;br /&gt;
&lt;br /&gt;
* '''#issue 4:''' For “Author feedback report” table, change the header name “Review response rejoined” to “Review responded to” and “Last rejoined at” to “Last responded at”. Then, sort “Rejoinder” and “Review “Review responded to” as string (alphabetically), sort “# author feedbacks done” by the first number than the second number (same as “Review done” in the “View review report” table) and sort “Last responded at” as date.&lt;br /&gt;
[[File:4_1877.png]]&lt;br /&gt;
&lt;br /&gt;
* '''#issue 5:''' For “Teammate review report” table, sort the first 3 columns as a string and sort the last column as a date.&lt;br /&gt;
[[File:5_1877.png]]&lt;br /&gt;
&lt;br /&gt;
== Solution ==&lt;br /&gt;
We will be using tablesorter jQuery to sort the table. For table columns which have constraints on them for sorting, we will be creating custom scripts which tablesorter library supports to sort those columns. According to the problem type, we are supposed to perform three kinds of sorting. All these have one thing in common. Adding up the tablesorter script in the body before using them. After including the script, we are supposed to do some modifications in the table tag by including the class. Three types of scenario may arise:&lt;br /&gt;
&lt;br /&gt;
#Sorting by columns alphabetically - To sort the columns alphabetically, the table-head attribute must include sorter-true class with it to enable the sorting alphabetically.&lt;br /&gt;
#Sorting by date - It includes adding of a date default format in the script to denote the sorter type that must be used to sort the column of the date.&lt;br /&gt;
#Sorting by the first number followed by the second number - It will require splitting up of the data into two parts separated by '/' and then sorting the first part, followed by the second part.&lt;br /&gt;
&lt;br /&gt;
=== About jQuery tablesorter 2.0===&lt;br /&gt;
tablesorter is a jQuery plugin for turning a standard HTML table with THEAD and TBODY tags into a sortable table without page refreshes. tablesorter can successfully parse and sort many types of data including linked data in a cell. It has many useful features including:&lt;br /&gt;
&lt;br /&gt;
* Multi-column sorting&lt;br /&gt;
* Multi-tbody sorting&lt;br /&gt;
* Parsers for sorting text, URIs, integers, currency, floats, IP addresses, dates (ISO, long and short formats), time. Add your own easily&lt;br /&gt;
* Support secondary &amp;quot;hidden&amp;quot; sorting (e.g., maintain alphabetical sort when sorting on other criteria)&lt;br /&gt;
* Extensibility via widget system&lt;br /&gt;
* Cross-browser: IE 6.0+, FF 2+, Safari 2.0+, Opera 9.0+&lt;br /&gt;
* Small code size&lt;br /&gt;
&lt;br /&gt;
== UML Design ==&lt;br /&gt;
[[File:6_1877.png | center]]&lt;br /&gt;
&lt;br /&gt;
== Modification of Files ==&lt;br /&gt;
The following files were modified:&lt;br /&gt;
* app/views/assignments/list_submissions.html.erb (issue 1)&lt;br /&gt;
* app/views/grades/_team_title.html.erb (issue 2)&lt;br /&gt;
* app/views/grades/_tabbing.html.erb (issue 2)&lt;br /&gt;
* app/views/grades/_team.html.erb (issue 2)&lt;br /&gt;
* app/views/grades/_team_charts.html.erb (issue 2)&lt;br /&gt;
* app/views/grades/_team_title.html.erb (issue 2)&lt;br /&gt;
* app/views/grades/view.html.erb (issue 2)&lt;br /&gt;
* app/assets/javascripts/grading.js (issue 2)&lt;br /&gt;
* app/views/review_mapping/_review_report.html.erb (issue 3)&lt;br /&gt;
* app/views/review_mapping/_feedback_report.html.erb (issue 4)&lt;br /&gt;
* app/helpers/review_mapping_helper.rb (issue 4)&lt;br /&gt;
* app/views/review_mapping/_teammate_review_report.html.erb (issue 5)&lt;br /&gt;
&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue 1 ===&lt;br /&gt;
We have modified the views/assignments/list_submissions.html.erb by adding the tablesorter class in the table tag. Then with the table head, we added suitable classes and added scripts at the top of the file to sort the table contents within the file.&lt;br /&gt;
&lt;br /&gt;
Added the following script to the file.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
   $(function () {&lt;br /&gt;
     /*Function for sorting the table */&lt;br /&gt;
     $(&amp;quot;#submissionsTable&amp;quot;).tablesorter({&lt;br /&gt;
       sortList: [[0,0]] //sort First Column by default when page loads&lt;br /&gt;
     });&lt;br /&gt;
   });&lt;br /&gt;
 &amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then, we changed the table to this.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;table id =&amp;quot;submissionsTable&amp;quot; class=&amp;quot;table table-striped&amp;quot; style=&amp;quot;margin-top: 50px&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;thead&amp;gt;&lt;br /&gt;
         &amp;lt;% if @assignment.topics? %&amp;gt;&lt;br /&gt;
           &amp;lt;th class=&amp;quot;sorter-true&amp;quot; style=&amp;quot;font-weight: bold; font-size: 15px;&amp;quot;&amp;gt;Topic name&amp;lt;/th&amp;gt;&lt;br /&gt;
         &amp;lt;% end %&amp;gt;&lt;br /&gt;
         &amp;lt;% if @assignment.max_team_size &amp;gt; 1 %&amp;gt;&lt;br /&gt;
           &amp;lt;th class=&amp;quot;sorter-true&amp;quot; style=&amp;quot;font-weight: bold; font-size: 15px;&amp;quot;&amp;gt;Team name&amp;lt;/th&amp;gt;&lt;br /&gt;
           &amp;lt;th class=&amp;quot;sorter-true&amp;quot; style=&amp;quot;font-weight: bold; font-size: 15px;&amp;quot;&amp;gt;Team member(s)&amp;lt;/th&amp;gt;&lt;br /&gt;
         &amp;lt;% else %&amp;gt;&lt;br /&gt;
           &amp;lt;th class=&amp;quot;sorter-true&amp;quot; style=&amp;quot;font-weight: bold; font-size: 15px;&amp;quot;&amp;gt;Participant name&amp;lt;/th&amp;gt;&lt;br /&gt;
         &amp;lt;% end %&amp;gt;  &lt;br /&gt;
         &amp;lt;th class=&amp;quot;sorter-true&amp;quot; style=&amp;quot;font-weight: bold; font-size: 15px;&amp;quot;&amp;gt;Links&amp;lt;/th&amp;gt; &lt;br /&gt;
         &amp;lt;th class=&amp;quot;sorter-false&amp;quot; style=&amp;quot;font-weight: bold; font-size: 15px;&amp;quot;&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
       &amp;lt;/tr&amp;gt;        &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[File:new_1_1877.png]]&lt;br /&gt;
&lt;br /&gt;
=== Issue 2 ===&lt;br /&gt;
We have modified the /view.html.erb, _teams.html.erb, _team_title.html.erb and _team.html.erb by adding the tablesorter class in the table tag. In this section, we were facing some issues and the code was highly unstructured. Also, the JavaScript was not proper in terms of usability and there were some elements which were not working properly as the code was static. We cleaned the code in these four files including the assets/javascripts/grading.js file. To make the view expandable, we made this change to the grading.js file. Also as the view which expanded on clicking of plus sign(beside Team Name) was added as a row, we made it as a columns and are expanding this column using javascript and css. We made this change as tablesorter library was sorting the expanded view as well and spoiling the table structure on sorting the table by Team name.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
//E1877: changes made to adjust width of expandables&lt;br /&gt;
var offsets = obj.getBoundingClientRect();&lt;br /&gt;
obj.style.width=&amp;quot;calc(100vw - 103px)&amp;quot;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[File:new_2_1877.png]]&lt;br /&gt;
&lt;br /&gt;
=== Issue 3 ===&lt;br /&gt;
We have modified the views/review_mapping/_review_report.html.erb file and also added a custom script to sort &amp;quot;Reviews done&amp;quot; and &amp;quot;Score awarded / Avg. score&amp;quot;. To sort &amp;quot;team reviewed&amp;quot;, we used tablesorter which is similar to the issue#1. Following script has been added for custom sort.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    $(function () {&lt;br /&gt;
        // E1877: Function for sorting the table */&lt;br /&gt;
        $(&amp;quot;#report_Table&amp;quot;).tablesorter({&lt;br /&gt;
           // E1877: sortList: [[1, 0]], sort First Column by default when page loads&lt;br /&gt;
            textSorter: {&lt;br /&gt;
                3: function (value1, value2) {&lt;br /&gt;
                    //E1877: splitting by % and comparisons of values&lt;br /&gt;
                    var result1 = value1.split(&amp;quot;%&amp;quot;);&lt;br /&gt;
                    var result2 = value2.split(&amp;quot;%&amp;quot;);&lt;br /&gt;
                    if (parseInt(result1[0]) &amp;gt; parseInt(result2[0])) {&lt;br /&gt;
                        return 1;&lt;br /&gt;
                    }&lt;br /&gt;
                    else if (parseInt(result1[0]) &amp;lt; parseInt(result2[0])) {&lt;br /&gt;
                        return -1;&lt;br /&gt;
                    }&lt;br /&gt;
                    else {&lt;br /&gt;
                        return 0;&lt;br /&gt;
                    }&lt;br /&gt;
                }&lt;br /&gt;
            },&lt;br /&gt;
            headers: {&lt;br /&gt;
                2: {&lt;br /&gt;
                    sorter: 'averageParser' //E1877: custom Parser to parse Metrics data for the custom parser&lt;br /&gt;
                }&lt;br /&gt;
            }&lt;br /&gt;
        });&lt;br /&gt;
    });&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[File:new_3_1877.png]]&lt;br /&gt;
&lt;br /&gt;
=== Issue 4 ===&lt;br /&gt;
Initially, we referred to /views/review_mapping/_feedback_report.html.erb file for making the changes. In this, we started by renaming the column which was quite easy. Then we applied tablesorter for &amp;quot;Rejoinder&amp;quot; and “Review responded to”. For &amp;quot;Last responded at&amp;quot;, we added the date feature which is set to MM/DD/YYYY format. Again for the “# author feedbacks done”, we used the same script which was used in Issue#3. The script after adding date has been added below:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
   $(function () {&lt;br /&gt;
     /*Function for sorting the table */&lt;br /&gt;
     $(&amp;quot;#authorFeedback&amp;quot;).tablesorter({&lt;br /&gt;
         dateFormat : &amp;quot;mmddyyyy&amp;quot;, //E1877: set the default date format&lt;br /&gt;
       sortList: [[0,0]] // E1877: sort First Column by default when page loads&lt;br /&gt;
     });&lt;br /&gt;
   });&lt;br /&gt;
 &amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have demonstrated the implementation part of the image below. You can see the arrow marks beside the table header. This has been implemented with all the other issues as well. You can refer to our YouTube video for further reference.&lt;br /&gt;
&lt;br /&gt;
[[File:sol_4.png|center]]&lt;br /&gt;
&lt;br /&gt;
=== Issue 5 ===&lt;br /&gt;
To solve this issue, we used the same tablesorter jquery plugin as used in issue 1 combined with the date data member as used in issue 4. We have modified the /views/review_mapping/_teammate_review_report.html.erb file to complete the solution.&lt;br /&gt;
&lt;br /&gt;
[[File:new_5_1877.png]]&lt;br /&gt;
&lt;br /&gt;
== Testing Plan ==&lt;br /&gt;
=== Functional Testing ===&lt;br /&gt;
&lt;br /&gt;
===== For issue 1 =====&lt;br /&gt;
# Login as a super_admininstrator2.&lt;br /&gt;
# Click Assignments tab next to Courses&lt;br /&gt;
# Select the &amp;quot;View submissions&amp;quot; icon for the assignment for which you want to see the report of&lt;br /&gt;
# Sort the table by clicking on headers&lt;br /&gt;
&lt;br /&gt;
===== For issue 2 =====&lt;br /&gt;
# Login as a super_admininstrator2.&lt;br /&gt;
# Click Assignments tab next to Courses&lt;br /&gt;
# Select the &amp;quot;View Scores&amp;quot; icon for the assignment for which you want to see the report of&lt;br /&gt;
# Sort the table by clicking on headers&lt;br /&gt;
&lt;br /&gt;
===== For issue 3 =====&lt;br /&gt;
# Login as a super_admininstrator2.&lt;br /&gt;
# Click Assignments tab next to Courses&lt;br /&gt;
# Select the &amp;quot;View report&amp;quot; icon for the assignment for which you want to see the report of&lt;br /&gt;
# Sort the table by clicking on headers&lt;br /&gt;
&lt;br /&gt;
===== For issue 4 =====&lt;br /&gt;
# Login as a super_admininstrator2.&lt;br /&gt;
# Click Assignments tab next to Courses&lt;br /&gt;
# Select the &amp;quot;View report&amp;quot; icon for the assignment for which you want to see the report of&lt;br /&gt;
# Select the &amp;quot;Author Feedback report&amp;quot; from the drop-down menu&lt;br /&gt;
# Sort the table by clicking on headers&lt;br /&gt;
&lt;br /&gt;
===== For issue 5 =====&lt;br /&gt;
# Login as a super_admininstrator2.&lt;br /&gt;
# Click Assignments tab next to Courses&lt;br /&gt;
# Select the &amp;quot;View submissions&amp;quot; icon for the assignment for which you want to see the report of&lt;br /&gt;
# Select the &amp;quot;Teammate Review report&amp;quot; from the drop-down menu&lt;br /&gt;
# Sort the table by clicking on headers&lt;br /&gt;
&lt;br /&gt;
== Team Information ==&lt;br /&gt;
#Ayush Arnav (aarnav@ncsu.edu)&lt;br /&gt;
#Rayan Dasoriya (rdasori@ncsu.edu)&lt;br /&gt;
#Rashik Bhasin (rbhasin@ncsu.edu)&lt;br /&gt;
#Prakshatkumar Shah (pmshah2@ncsu.edu)&lt;br /&gt;
#'''Mentor:''' Xiao Ma (xma21@ncsu.edu)&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
#[https://github.com/expertiza/expertiza Expertiza on GitHub]&lt;br /&gt;
#[https://github.com/expertiza/expertiza/pull/1287 GitHub Pull Request]&lt;br /&gt;
#[http://expertiza.ncsu.edu/ The Live Expertiza Website] &lt;br /&gt;
#[https://mottie.github.io/tablesorter/docs/ tablesorter jQuery]&lt;br /&gt;
#Clean Code: A handbook of agile software craftsmanship. Author: Robert C Martin&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1877_Sort_instructor_reports_by_name,_ID,_score,_etc&amp;diff=119666</id>
		<title>E1877 Sort instructor reports by name, ID, score, etc</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1877_Sort_instructor_reports_by_name,_ID,_score,_etc&amp;diff=119666"/>
		<updated>2018-11-13T07:10:22Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Files modified */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1877 OSS final project for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: super_administrator2 password: password&lt;br /&gt;
* Youtube link: &lt;br /&gt;
*Github Pull Request Link: https://github.com/expertiza/expertiza/pull/1287&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows instructors to view kinds of reports of assignments in their courses such as submissions, scores, and review reports. To improve the report views, some table columns such as team name, score, average should be made sortable by using the same existing sort library.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* For “view submissions” table, sort “Topic name”, “Team name”, “Team member(s)”, “Links” alphabetically.&lt;br /&gt;
&lt;br /&gt;
* For “View scores” table, sort “Team” alphabetically, sort “Average” and “Range” (the first percentage) in both ascending or descending order.&lt;br /&gt;
&lt;br /&gt;
* For “View review report” table, “Reviewer” and “Metric” are already sortable, so we need to make other columns sortable: sort “Review done” by the first number then the second number (e.g., 0/1, 0/2, 0/3, 1/1, 1/5, 2/2...), sort “Team reviewed” alphabetically and sort “Score awarded / Avg. score” (the first percentage) in both ascending or descending order.&lt;br /&gt;
&lt;br /&gt;
* For “Author feedback report” table, change the header name “Review response rejoined” to “Review responded to” and “Last rejoined at” to “Last responded at”. Then, sort “Rejoinder” and “Review “Review responded to” as string (alphabetically), sort “# author feedbacks done” by the first number then the second number (same as “Review done” in the “View review report” table) and sort “Last responded at” as date.&lt;br /&gt;
&lt;br /&gt;
* For “Teammate review report” table, sort the first 3 columns as string and sort the last column as date.&lt;br /&gt;
&lt;br /&gt;
== Our understanding from the problem statement ==&lt;br /&gt;
We will be using tablesorter jQuery to sort the table. For table columns which have constraints on them for sorting, we will be creating custom scripts which tablesorter library supports to sort those columns.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/assignments/list_submissions.html.erb&lt;br /&gt;
*&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
* &lt;br /&gt;
&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== For “view submissions” table, sort “Topic name”, “Team name”, “Team member(s)”, “Links” alphabetically. ===&lt;br /&gt;
*&lt;br /&gt;
&lt;br /&gt;
== Testing Plan ==&lt;br /&gt;
=== Functional Testing ===&lt;br /&gt;
&lt;br /&gt;
===== For “view submissions” table, sort “Topic name”, “Team name”, “Team member(s)”, “Links” alphabetically. =====&lt;br /&gt;
# Login as an super_admininstrator2.&lt;br /&gt;
# Click Assignments tab next to Courses&lt;br /&gt;
# Select the &amp;quot;View submissions&amp;quot; icon for the assignment for which you want to see the report of&lt;br /&gt;
# Sort the table by clicking on headers&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1877_Sort_instructor_reports_by_name,_ID,_score,_etc&amp;diff=119665</id>
		<title>E1877 Sort instructor reports by name, ID, score, etc</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1877_Sort_instructor_reports_by_name,_ID,_score,_etc&amp;diff=119665"/>
		<updated>2018-11-13T07:09:20Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Solutions Implemented */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1877 OSS final project for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: super_administrator2 password: password&lt;br /&gt;
* Youtube link: &lt;br /&gt;
*Github Pull Request Link: https://github.com/expertiza/expertiza/pull/1287&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows instructors to view kinds of reports of assignments in their courses such as submissions, scores, and review reports. To improve the report views, some table columns such as team name, score, average should be made sortable by using the same existing sort library.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* For “view submissions” table, sort “Topic name”, “Team name”, “Team member(s)”, “Links” alphabetically.&lt;br /&gt;
&lt;br /&gt;
* For “View scores” table, sort “Team” alphabetically, sort “Average” and “Range” (the first percentage) in both ascending or descending order.&lt;br /&gt;
&lt;br /&gt;
* For “View review report” table, “Reviewer” and “Metric” are already sortable, so we need to make other columns sortable: sort “Review done” by the first number then the second number (e.g., 0/1, 0/2, 0/3, 1/1, 1/5, 2/2...), sort “Team reviewed” alphabetically and sort “Score awarded / Avg. score” (the first percentage) in both ascending or descending order.&lt;br /&gt;
&lt;br /&gt;
* For “Author feedback report” table, change the header name “Review response rejoined” to “Review responded to” and “Last rejoined at” to “Last responded at”. Then, sort “Rejoinder” and “Review “Review responded to” as string (alphabetically), sort “# author feedbacks done” by the first number then the second number (same as “Review done” in the “View review report” table) and sort “Last responded at” as date.&lt;br /&gt;
&lt;br /&gt;
* For “Teammate review report” table, sort the first 3 columns as string and sort the last column as date.&lt;br /&gt;
&lt;br /&gt;
== Our understanding from the problem statement ==&lt;br /&gt;
We will be using tablesorter jQuery to sort the table. For table columns which have constraints on them for sorting, we will be creating custom scripts which tablesorter library supports to sort those columns.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/assignments/list_submissions.html.erb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
* &lt;br /&gt;
&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== For “view submissions” table, sort “Topic name”, “Team name”, “Team member(s)”, “Links” alphabetically. ===&lt;br /&gt;
*&lt;br /&gt;
&lt;br /&gt;
== Testing Plan ==&lt;br /&gt;
=== Functional Testing ===&lt;br /&gt;
&lt;br /&gt;
===== For “view submissions” table, sort “Topic name”, “Team name”, “Team member(s)”, “Links” alphabetically. =====&lt;br /&gt;
# Login as an super_admininstrator2.&lt;br /&gt;
# Click Assignments tab next to Courses&lt;br /&gt;
# Select the &amp;quot;View submissions&amp;quot; icon for the assignment for which you want to see the report of&lt;br /&gt;
# Sort the table by clicking on headers&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1877_Sort_instructor_reports_by_name,_ID,_score,_etc&amp;diff=119664</id>
		<title>E1877 Sort instructor reports by name, ID, score, etc</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1877_Sort_instructor_reports_by_name,_ID,_score,_etc&amp;diff=119664"/>
		<updated>2018-11-13T07:08:55Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: Created page with &amp;quot;This wiki page describes the changes made according to the specification of E1877 OSS final project for Fall 2018. ---- == Peer Review Information == The following credentials ar...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1877 OSS final project for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: super_administrator2 password: password&lt;br /&gt;
* Youtube link: &lt;br /&gt;
*Github Pull Request Link: https://github.com/expertiza/expertiza/pull/1287&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows instructors to view kinds of reports of assignments in their courses such as submissions, scores, and review reports. To improve the report views, some table columns such as team name, score, average should be made sortable by using the same existing sort library.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* For “view submissions” table, sort “Topic name”, “Team name”, “Team member(s)”, “Links” alphabetically.&lt;br /&gt;
&lt;br /&gt;
* For “View scores” table, sort “Team” alphabetically, sort “Average” and “Range” (the first percentage) in both ascending or descending order.&lt;br /&gt;
&lt;br /&gt;
* For “View review report” table, “Reviewer” and “Metric” are already sortable, so we need to make other columns sortable: sort “Review done” by the first number then the second number (e.g., 0/1, 0/2, 0/3, 1/1, 1/5, 2/2...), sort “Team reviewed” alphabetically and sort “Score awarded / Avg. score” (the first percentage) in both ascending or descending order.&lt;br /&gt;
&lt;br /&gt;
* For “Author feedback report” table, change the header name “Review response rejoined” to “Review responded to” and “Last rejoined at” to “Last responded at”. Then, sort “Rejoinder” and “Review “Review responded to” as string (alphabetically), sort “# author feedbacks done” by the first number then the second number (same as “Review done” in the “View review report” table) and sort “Last responded at” as date.&lt;br /&gt;
&lt;br /&gt;
* For “Teammate review report” table, sort the first 3 columns as string and sort the last column as date.&lt;br /&gt;
&lt;br /&gt;
== Our understanding from the problem statement ==&lt;br /&gt;
We will be using tablesorter jQuery to sort the table. For table columns which have constraints on them for sorting, we will be creating custom scripts which tablesorter library supports to sort those columns.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/assignments/list_submissions.html.erb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
* &lt;br /&gt;
&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== For “view submissions” table, sort “Topic name”, “Team name”, “Team member(s)”, “Links” alphabetically. ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Testing Plan ==&lt;br /&gt;
=== Functional Testing ===&lt;br /&gt;
&lt;br /&gt;
===== For “view submissions” table, sort “Topic name”, “Team name”, “Team member(s)”, “Links” alphabetically. =====&lt;br /&gt;
# Login as an super_admininstrator2.&lt;br /&gt;
# Click Assignments tab next to Courses&lt;br /&gt;
# Select the &amp;quot;View submissions&amp;quot; icon for the assignment for which you want to see the report of&lt;br /&gt;
# Sort the table by clicking on headers&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=119272</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=119272"/>
		<updated>2018-11-10T04:29:49Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Testing Plan */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link: https://www.youtube.com/watch?v=_0UU0r4IOf4&amp;amp;feature=youtu.be&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
* app/views/suggestion/list.html.erb&lt;br /&gt;
* app/controllers/suggestion_controller.rb&lt;br /&gt;
* db/schema.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
* db/migrate/20181027001119_add_feedback_to_suggestion.rb&lt;br /&gt;
&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_add_signup_topics.html.erb''' we initialize the new topic with max_choosers as 1.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;% @sign_up_topic = SignUpTopic.new %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic = @sign_up_topic %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic.max_choosers=1 %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Topics table before changes =====&lt;br /&gt;
&lt;br /&gt;
[[File:topic_3.png]]&lt;br /&gt;
&lt;br /&gt;
===== Topics table after changes =====&lt;br /&gt;
&lt;br /&gt;
[[File:topic_4.png]]&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is added using Tablesorter css, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
&lt;br /&gt;
To use Tablesorter in app/views/sign_up_sheet/_add_signup_topics.html.erb, we added this script:-&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
  $(function () {&lt;br /&gt;
    /*Function for sorting the table */&lt;br /&gt;
    $(&amp;quot;.sortable&amp;quot;).tablesorter({&lt;br /&gt;
      sortList: [[0,0]] //sort First Column by default when page loads&lt;br /&gt;
    });&lt;br /&gt;
  });&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And made this change to the current table in html:-&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;table class=&amp;quot;table table-striped sortable&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;thead&amp;gt;&lt;br /&gt;
      &amp;lt;tr&amp;gt;&amp;lt;%= render :partial =&amp;gt; '/sign_up_sheet/table_header' %&amp;gt;&amp;lt;/tr&amp;gt;	      &lt;br /&gt;
      &amp;lt;tr&amp;gt;&amp;lt;%= render :partial =&amp;gt; '/sign_up_sheet/table_header' %&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/thead&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then to make Topic to be sortable, we added this in app/views/sign_up_sheet/_table_header.html.erb:-&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;th class=&amp;quot;sorter-true&amp;quot; width=&amp;quot;5%&amp;quot;&amp;gt;Topic #&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Sorting in ascending order''':-&lt;br /&gt;
[[File:Edit_ascending.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Sorting in descending order''':-&lt;br /&gt;
[[File:Edit_descending.png]]&lt;br /&gt;
&lt;br /&gt;
=== Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
We should allow instructors to give feedback when accepting or rejecting topic suggestions. As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/suggestion/list.html.erb''',added an additional editable textbox and a submit button. On click of the button the feedback provided in the text box is saved to the database in a table name suggestions, column name feedback.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table class=&amp;quot;general&amp;quot; cellpadding=5 width=100% border=1&amp;gt;&lt;br /&gt;
    &amp;lt;tr&amp;gt;&lt;br /&gt;
      &amp;lt;th&amp;gt;Title&amp;lt;/th&amp;gt;&lt;br /&gt;
      &amp;lt;th&amp;gt;Status&amp;lt;/th&amp;gt;&lt;br /&gt;
      &amp;lt;th&amp;gt;Submitter's user name&amp;lt;/th&amp;gt;&lt;br /&gt;
      &amp;lt;th&amp;gt;Action&amp;lt;/th&amp;gt;&lt;br /&gt;
      &amp;lt;!-- New Headers --&amp;gt;&lt;br /&gt;
      &amp;lt;th&amp;gt;Feedback&amp;lt;/th&amp;gt;&lt;br /&gt;
      &amp;lt;th&amp;gt;Save&amp;lt;/th&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;% for suggestion in @suggestions %&amp;gt;&lt;br /&gt;
      &amp;lt;tr class=&amp;quot;listingRow&amp;quot;&amp;gt;&lt;br /&gt;
	&amp;lt;!-- Creating form to have an action on the new submit feedback button --&amp;gt;&lt;br /&gt;
	&amp;lt;!-- Adding id and type in the params object which is required to reload the same page again --&amp;gt;&lt;br /&gt;
	&amp;lt;%= form_for :suggestion, :url =&amp;gt; update_feedback_suggestion_index_path(:suggestion_id =&amp;gt; suggestion.id, :id =&amp;gt; params[:id], :type =&amp;gt; params[:type])   	do |f| %&amp;gt;&lt;br /&gt;
        &amp;lt;td style=&amp;quot;max-width: 200px&amp;quot;&amp;gt;&amp;lt;%=h suggestion.title %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
        &amp;lt;td align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;%=h suggestion.status %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
        &amp;lt;td align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;%=h suggestion.unityID %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
        &amp;lt;td align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;%= link_to 'View', :action =&amp;gt; 'show', :id =&amp;gt; suggestion %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
	&amp;lt;td align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;%= f.text_field :feedback %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
	&amp;lt;td align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;%= f.submit 'Save Feedback' %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
	&amp;lt;% end %&amp;gt;&lt;br /&gt;
      &amp;lt;/tr&amp;gt;&lt;br /&gt;
    &amp;lt;% end %&amp;gt;&lt;br /&gt;
  &amp;lt;/table&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/controllers/suggestion_controller.rb''' ,added an additional method to save the changes in the feedback text box to database.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  # Method to save/update feedback given by the instructor in the suggestions table in feedback column&lt;br /&gt;
  # After saving the data we redirect the user to the same page&lt;br /&gt;
  def update_feedback&lt;br /&gt;
    Suggestion.find(params[:suggestion_id]).update_attributes(feedback: params[:suggestion][:feedback])&lt;br /&gt;
    redirect_to list_suggestion_index_path(:id =&amp;gt; params[:id], :type =&amp;gt; params[:type])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''db/migrate/20181027001119_add_feedback_to_suggestion.rb''' ,added migration scripts. Script is adding a column name &amp;quot;feedback&amp;quot; in the suggestions table.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  class AddFeedbackToSuggestion &amp;lt; ActiveRecord::Migration&lt;br /&gt;
   def change&lt;br /&gt;
    add_column :suggestions, :feedback, :string&lt;br /&gt;
   end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''expertiza/db/schema.rb''' ,schema changes as effect of adding column in table suggestions.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  create_table &amp;quot;suggestions&amp;quot;, force: :cascade do |t|&lt;br /&gt;
    t.integer &amp;quot;assignment_id&amp;quot;,     limit: 4&lt;br /&gt;
    t.string  &amp;quot;title&amp;quot;,             limit: 255&lt;br /&gt;
    t.text    &amp;quot;description&amp;quot;,       limit: 65535&lt;br /&gt;
    t.string  &amp;quot;status&amp;quot;,            limit: 255&lt;br /&gt;
    t.string  &amp;quot;unityID&amp;quot;,           limit: 255&lt;br /&gt;
    t.string  &amp;quot;signup_preference&amp;quot;, limit: 255&lt;br /&gt;
    t.string  &amp;quot;feedback&amp;quot;,          limit: 255&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Suggestions list page before changes =====&lt;br /&gt;
&lt;br /&gt;
[[File:BeforeFeedbackPage.png]]&lt;br /&gt;
&lt;br /&gt;
===== Suggestions list page after changes =====&lt;br /&gt;
&lt;br /&gt;
[[File:AfterFeedbackPage.png]]&lt;br /&gt;
&lt;br /&gt;
== Testing Plan ==&lt;br /&gt;
=== Functional Testing ===&lt;br /&gt;
&lt;br /&gt;
===== Issue #971: Change create topic UI into AJAX =====&lt;br /&gt;
# Login as an instructor.&lt;br /&gt;
# Click Assignments tab next to Courses&lt;br /&gt;
# Select the assignment for which a new topic has to be added&lt;br /&gt;
# Click the edit icon for the assignment and go to Topics tab&lt;br /&gt;
# You will be able to see the topics list in a table format. Click on add icon on the right side corner of the table header&lt;br /&gt;
# Fill in the details and click save topic&lt;br /&gt;
&lt;br /&gt;
If a user tries to set number of slots as zero, a warning pops up and prohibits the user from doing so.&lt;br /&gt;
===== Warning message when max_choosers is set to zero =====&lt;br /&gt;
&lt;br /&gt;
[[File:topic_5.png]]&lt;br /&gt;
&lt;br /&gt;
===== Issue #926 We need a way to sort topics by topic number in assignment#edit page =====&lt;br /&gt;
As we have shown this in video:-&lt;br /&gt;
# Login as an instructor.&lt;br /&gt;
# Click Assignments tab next to Courses&lt;br /&gt;
# Click the edit icon for the specific assignment and go to Topics tab&lt;br /&gt;
# You will be able to see the topics list in a table format sorted in ascending order by 'Topic# '. &lt;br /&gt;
# Click on 'Topic# ' icon to sort the table in descending order based on 'Topic# ', and if you click it again after that it sorts the table in ascending order based on 'Topic# '.&lt;br /&gt;
&lt;br /&gt;
===== Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions =====&lt;br /&gt;
# Login as an instructor.&lt;br /&gt;
# Click Manage -&amp;gt; Assignments.&lt;br /&gt;
# After clicking on the Assignment tab, a page will show all the assignments. &lt;br /&gt;
# Click the view suggestions icon on the right bottom corner.&lt;br /&gt;
# You will be able to see a list of suggestions given by the students for that particular topic.&lt;br /&gt;
# Add feedback in the feedback text box and click save feedback button to save it.&lt;br /&gt;
# To verify if the feedback was saved to the table, query suggestions table and match the feedback in the feedback column to the feedback given.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=119269</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=119269"/>
		<updated>2018-11-10T04:07:03Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Testing Plan */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link: https://www.youtube.com/watch?v=_0UU0r4IOf4&amp;amp;feature=youtu.be&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
* app/views/suggestion/list.html.erb&lt;br /&gt;
* app/controllers/suggestion_controller.rb&lt;br /&gt;
* db/schema.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
* db/migrate/20181027001119_add_feedback_to_suggestion.rb&lt;br /&gt;
&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_add_signup_topics.html.erb''' we initialize the new topic with max_choosers as 1.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;% @sign_up_topic = SignUpTopic.new %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic = @sign_up_topic %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic.max_choosers=1 %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Topics table before changes =====&lt;br /&gt;
&lt;br /&gt;
[[File:topic_3.png]]&lt;br /&gt;
&lt;br /&gt;
===== Topics table after changes =====&lt;br /&gt;
&lt;br /&gt;
[[File:topic_4.png]]&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is added using Tablesorter css, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
&lt;br /&gt;
To use Tablesorter in app/views/sign_up_sheet/_add_signup_topics.html.erb, we added this script:-&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
  $(function () {&lt;br /&gt;
    /*Function for sorting the table */&lt;br /&gt;
    $(&amp;quot;.sortable&amp;quot;).tablesorter({&lt;br /&gt;
      sortList: [[0,0]] //sort First Column by default when page loads&lt;br /&gt;
    });&lt;br /&gt;
  });&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And made this change to the current table in html:-&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;table class=&amp;quot;table table-striped sortable&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;thead&amp;gt;&lt;br /&gt;
      &amp;lt;tr&amp;gt;&amp;lt;%= render :partial =&amp;gt; '/sign_up_sheet/table_header' %&amp;gt;&amp;lt;/tr&amp;gt;	      &lt;br /&gt;
      &amp;lt;tr&amp;gt;&amp;lt;%= render :partial =&amp;gt; '/sign_up_sheet/table_header' %&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/thead&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then to make Topic to be sortable, we added this in app/views/sign_up_sheet/_table_header.html.erb:-&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;th class=&amp;quot;sorter-true&amp;quot; width=&amp;quot;5%&amp;quot;&amp;gt;Topic #&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Sorting in ascending order''':-&lt;br /&gt;
[[File:Edit_ascending.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Sorting in descending order''':-&lt;br /&gt;
[[File:Edit_descending.png]]&lt;br /&gt;
&lt;br /&gt;
=== Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
We should allow instructors to give feedback when accepting or rejecting topic suggestions. As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/suggestion/list.html.erb''',added an additional editable textbox and a submit button. On click of the button the feedback provided in the text box is saved to the database in a table name suggestions, column name feedback.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table class=&amp;quot;general&amp;quot; cellpadding=5 width=100% border=1&amp;gt;&lt;br /&gt;
    &amp;lt;tr&amp;gt;&lt;br /&gt;
      &amp;lt;th&amp;gt;Title&amp;lt;/th&amp;gt;&lt;br /&gt;
      &amp;lt;th&amp;gt;Status&amp;lt;/th&amp;gt;&lt;br /&gt;
      &amp;lt;th&amp;gt;Submitter's user name&amp;lt;/th&amp;gt;&lt;br /&gt;
      &amp;lt;th&amp;gt;Action&amp;lt;/th&amp;gt;&lt;br /&gt;
      &amp;lt;!-- New Headers --&amp;gt;&lt;br /&gt;
      &amp;lt;th&amp;gt;Feedback&amp;lt;/th&amp;gt;&lt;br /&gt;
      &amp;lt;th&amp;gt;Save&amp;lt;/th&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;% for suggestion in @suggestions %&amp;gt;&lt;br /&gt;
      &amp;lt;tr class=&amp;quot;listingRow&amp;quot;&amp;gt;&lt;br /&gt;
	&amp;lt;!-- Creating form to have an action on the new submit feedback button --&amp;gt;&lt;br /&gt;
	&amp;lt;!-- Adding id and type in the params object which is required to reload the same page again --&amp;gt;&lt;br /&gt;
	&amp;lt;%= form_for :suggestion, :url =&amp;gt; update_feedback_suggestion_index_path(:suggestion_id =&amp;gt; suggestion.id, :id =&amp;gt; params[:id], :type =&amp;gt; params[:type])   	do |f| %&amp;gt;&lt;br /&gt;
        &amp;lt;td style=&amp;quot;max-width: 200px&amp;quot;&amp;gt;&amp;lt;%=h suggestion.title %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
        &amp;lt;td align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;%=h suggestion.status %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
        &amp;lt;td align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;%=h suggestion.unityID %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
        &amp;lt;td align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;%= link_to 'View', :action =&amp;gt; 'show', :id =&amp;gt; suggestion %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
	&amp;lt;td align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;%= f.text_field :feedback %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
	&amp;lt;td align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;%= f.submit 'Save Feedback' %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
	&amp;lt;% end %&amp;gt;&lt;br /&gt;
      &amp;lt;/tr&amp;gt;&lt;br /&gt;
    &amp;lt;% end %&amp;gt;&lt;br /&gt;
  &amp;lt;/table&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/controllers/suggestion_controller.rb''' ,added an additional method to save the changes in the feedback text box to database.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  # Method to save/update feedback given by the instructor in the suggestions table in feedback column&lt;br /&gt;
  # After saving the data we redirect the user to the same page&lt;br /&gt;
  def update_feedback&lt;br /&gt;
    Suggestion.find(params[:suggestion_id]).update_attributes(feedback: params[:suggestion][:feedback])&lt;br /&gt;
    redirect_to list_suggestion_index_path(:id =&amp;gt; params[:id], :type =&amp;gt; params[:type])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''db/migrate/20181027001119_add_feedback_to_suggestion.rb''' ,added migration scripts. Script is adding a column name &amp;quot;feedback&amp;quot; in the suggestions table.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  class AddFeedbackToSuggestion &amp;lt; ActiveRecord::Migration&lt;br /&gt;
   def change&lt;br /&gt;
    add_column :suggestions, :feedback, :string&lt;br /&gt;
   end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''expertiza/db/schema.rb''' ,schema changes as effect of adding column in table suggestions.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  create_table &amp;quot;suggestions&amp;quot;, force: :cascade do |t|&lt;br /&gt;
    t.integer &amp;quot;assignment_id&amp;quot;,     limit: 4&lt;br /&gt;
    t.string  &amp;quot;title&amp;quot;,             limit: 255&lt;br /&gt;
    t.text    &amp;quot;description&amp;quot;,       limit: 65535&lt;br /&gt;
    t.string  &amp;quot;status&amp;quot;,            limit: 255&lt;br /&gt;
    t.string  &amp;quot;unityID&amp;quot;,           limit: 255&lt;br /&gt;
    t.string  &amp;quot;signup_preference&amp;quot;, limit: 255&lt;br /&gt;
    t.string  &amp;quot;feedback&amp;quot;,          limit: 255&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== Suggestions list page before changes =====&lt;br /&gt;
&lt;br /&gt;
[[File:BeforeFeedbackPage.png]]&lt;br /&gt;
&lt;br /&gt;
===== Suggestions list page after changes =====&lt;br /&gt;
&lt;br /&gt;
[[File:AfterFeedbackPage.png]]&lt;br /&gt;
&lt;br /&gt;
== Testing Plan ==&lt;br /&gt;
=== Functional Testing ===&lt;br /&gt;
&lt;br /&gt;
===== Issue #971: Change create topic UI into AJAX =====&lt;br /&gt;
# Login as an instructor.&lt;br /&gt;
# Click Assignments tab next to Courses&lt;br /&gt;
# Select the assignment for which a new topic has to be added&lt;br /&gt;
# Click the edit icon for the assignment and go to Topics tab&lt;br /&gt;
# You will be able to see the topics list in a table format. Click on add icon on the right side corner of the table header&lt;br /&gt;
# Fill in the details and click save topic&lt;br /&gt;
&lt;br /&gt;
If a user tries to set number of slots as zero, a warning pops up and prohibits the user from doing so.&lt;br /&gt;
===== Warning message when max_choosers is set to zero =====&lt;br /&gt;
&lt;br /&gt;
[[File:topic_5.png]]&lt;br /&gt;
&lt;br /&gt;
===== Issue #926 We need a way to sort topics by topic number in assignment#edit page =====&lt;br /&gt;
# Login as an instructor.&lt;br /&gt;
# Click Assignments tab next to Courses&lt;br /&gt;
# Click the edit icon for the specific assignment and go to Topics tab&lt;br /&gt;
# You will be able to see the topics list in a table format sorted in ascending order by 'Topic# '. &lt;br /&gt;
# Click on 'Topic# ' icon to sort the table in descending order based on 'Topic# ', and if you click it again after that it sorts the table in ascending order based on 'Topic# '.&lt;br /&gt;
&lt;br /&gt;
===== Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions =====&lt;br /&gt;
# Login as an instructor.&lt;br /&gt;
# Click Manage -&amp;gt; Assignments.&lt;br /&gt;
# After clicking on the Assignment tab, a page will show all the assignments. &lt;br /&gt;
# Click the view suggestions icon on the right bottom corner.&lt;br /&gt;
# You will be able to see a list of suggestions given by the students for that particular topic.&lt;br /&gt;
# Add feedback in the feedback text box and click save feedback button to save it.&lt;br /&gt;
# To verify if the feedback was saved to the table, query suggestions table and match the feedback in the feedback column to the feedback given.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118105</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118105"/>
		<updated>2018-11-02T20:08:35Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* We should allow instructors to give feedback when accepting or rejecting topic suggestions. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link:&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_add_signup_topics.html.erb''' we initialize the new topic with max_choosers as 1.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;% @sign_up_topic = SignUpTopic.new %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic = @sign_up_topic %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic.max_choosers=1 %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[File:topic_2.png]]&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is added using Tablesorter css, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
&lt;br /&gt;
To use Tablesorter in app/views/sign_up_sheet/_add_signup_topics.html.erb, we added this script:-&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
  $(function () {&lt;br /&gt;
    /*Function for sorting the table */&lt;br /&gt;
    $(&amp;quot;.sortable&amp;quot;).tablesorter({&lt;br /&gt;
      sortList: [[0,0]] //sort First Column by default when page loads&lt;br /&gt;
    });&lt;br /&gt;
  });&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And made this change to the current table in html:-&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;table class=&amp;quot;table table-striped sortable&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;thead&amp;gt;&lt;br /&gt;
      &amp;lt;tr&amp;gt;&amp;lt;%= render :partial =&amp;gt; '/sign_up_sheet/table_header' %&amp;gt;&amp;lt;/tr&amp;gt;	      &lt;br /&gt;
      &amp;lt;tr&amp;gt;&amp;lt;%= render :partial =&amp;gt; '/sign_up_sheet/table_header' %&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/thead&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then to make Topic to be sortable, we added this in app/views/sign_up_sheet/_table_header.html.erb:-&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;th class=&amp;quot;sorter-true&amp;quot; width=&amp;quot;5%&amp;quot;&amp;gt;Topic #&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Sorting in ascending order''':-&lt;br /&gt;
[[File:Edit_ascending.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Sorting in descending order''':-&lt;br /&gt;
[[File:Edit_descending.png]]&lt;br /&gt;
&lt;br /&gt;
=== Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
A possible solution would be to add a column in the views&amp;gt;suggestion&amp;gt;list.html.erb with a textbox in the table and “send” button and handle sending the comments when the send button is pressed in suggestion_controller.rb. Add an extra column called “feedback” in the suggestion table to store instructor’s comments to the suggested topics.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118099</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118099"/>
		<updated>2018-11-02T20:02:25Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Issue #926 We need a way to sort topics by topic number in assignment#edit page. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link:&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_add_signup_topics.html.erb''' we initialize the new topic with max_choosers as 1.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;% @sign_up_topic = SignUpTopic.new %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic = @sign_up_topic %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic.max_choosers=1 %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;display:inline;width: 220px;&amp;gt;&lt;br /&gt;
[[Image:Topic1.PNG|800px|Image: 800 pixels]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is added using Tablesorter css, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
&lt;br /&gt;
To use Tablesorter in app/views/sign_up_sheet/_add_signup_topics.html.erb, we added this script:-&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
  $(function () {&lt;br /&gt;
    /*Function for sorting the table */&lt;br /&gt;
    $(&amp;quot;.sortable&amp;quot;).tablesorter({&lt;br /&gt;
      sortList: [[0,0]] //sort First Column by default when page loads&lt;br /&gt;
    });&lt;br /&gt;
  });&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And made this change to the current table in html:-&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;table class=&amp;quot;table table-striped sortable&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;thead&amp;gt;&lt;br /&gt;
      &amp;lt;tr&amp;gt;&amp;lt;%= render :partial =&amp;gt; '/sign_up_sheet/table_header' %&amp;gt;&amp;lt;/tr&amp;gt;	      &lt;br /&gt;
      &amp;lt;tr&amp;gt;&amp;lt;%= render :partial =&amp;gt; '/sign_up_sheet/table_header' %&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/thead&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then to make Topic to be sortable, we added this in app/views/sign_up_sheet/_table_header.html.erb:-&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;th class=&amp;quot;sorter-true&amp;quot; width=&amp;quot;5%&amp;quot;&amp;gt;Topic #&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Sorting in ascending order''':-&lt;br /&gt;
[[File:Edit_ascending.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Sorting in descending order''':-&lt;br /&gt;
[[File:Edit_descending.png]]&lt;br /&gt;
&lt;br /&gt;
=== We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
A possible solution would be to add a column in the views&amp;gt;suggestion&amp;gt;list.html.erb with a textbox in the table and “send” button and handle sending the comments when the send button is pressed in suggestion_controller.rb. Add an extra column called “feedback” in the suggestion table to store instructor’s comments to the suggested topics.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118097</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118097"/>
		<updated>2018-11-02T20:01:27Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Issue #926 We need a way to sort topics by topic number in assignment#edit page. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link:&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_add_signup_topics.html.erb''' we initialize the new topic with max_choosers as 1.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;% @sign_up_topic = SignUpTopic.new %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic = @sign_up_topic %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic.max_choosers=1 %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;display:inline;width: 220px;&amp;gt;&lt;br /&gt;
[[Image:Topic1.PNG|800px|Image: 800 pixels]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is added using Tablesorter css, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
&lt;br /&gt;
To use Tablesorter in app/views/sign_up_sheet/_add_signup_topics.html.erb, we added this script:-&lt;br /&gt;
&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
  $(function () {&lt;br /&gt;
    /*Function for sorting the table */&lt;br /&gt;
    $(&amp;quot;.sortable&amp;quot;).tablesorter({&lt;br /&gt;
      sortList: [[0,0]] //sort First Column by default when page loads&lt;br /&gt;
    });&lt;br /&gt;
  });&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And made this change to the current table in html:-&lt;br /&gt;
&amp;lt;table class=&amp;quot;table table-striped sortable&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;thead&amp;gt;&lt;br /&gt;
      &amp;lt;tr&amp;gt;&amp;lt;%= render :partial =&amp;gt; '/sign_up_sheet/table_header' %&amp;gt;&amp;lt;/tr&amp;gt;	      &lt;br /&gt;
      &amp;lt;tr&amp;gt;&amp;lt;%= render :partial =&amp;gt; '/sign_up_sheet/table_header' %&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/thead&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then to make Topic to be sortable, we added this in app/views/sign_up_sheet/_table_header.html.erb:-&lt;br /&gt;
&amp;lt;th class=&amp;quot;sorter-true&amp;quot; width=&amp;quot;5%&amp;quot;&amp;gt;Topic #&amp;lt;/th&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Sorting in ascending order''':-&lt;br /&gt;
[[File:Edit_ascending.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Sorting in descending order''':-&lt;br /&gt;
[[File:Edit_descending.png]]&lt;br /&gt;
&lt;br /&gt;
=== We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
A possible solution would be to add a column in the views&amp;gt;suggestion&amp;gt;list.html.erb with a textbox in the table and “send” button and handle sending the comments when the send button is pressed in suggestion_controller.rb. Add an extra column called “feedback” in the suggestion table to store instructor’s comments to the suggested topics.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118083</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118083"/>
		<updated>2018-11-02T19:45:01Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Issue #926 We need a way to sort topics by topic number in assignment#edit page. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link:&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_add_signup_topics.html.erb''' we initialize the new topic with max_choosers as 1.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;% @sign_up_topic = SignUpTopic.new %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic = @sign_up_topic %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic.max_choosers=1 %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[File:Capture.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is taken care by Js-Grid by itself, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
&lt;br /&gt;
'''Sorting in ascending order''':-&lt;br /&gt;
[[File:Edit_ascending.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Sorting in descending order''':-&lt;br /&gt;
[[File:Edit_descending.png]]&lt;br /&gt;
&lt;br /&gt;
=== We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
A possible solution would be to add a column in the views&amp;gt;suggestion&amp;gt;list.html.erb with a textbox in the table and “send” button and handle sending the comments when the send button is pressed in suggestion_controller.rb. Add an extra column called “feedback” in the suggestion table to store instructor’s comments to the suggested topics.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118082</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118082"/>
		<updated>2018-11-02T19:44:42Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Issue #926 We need a way to sort topics by topic number in assignment#edit page. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link:&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_add_signup_topics.html.erb''' we initialize the new topic with max_choosers as 1.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;% @sign_up_topic = SignUpTopic.new %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic = @sign_up_topic %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic.max_choosers=1 %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[File:Capture.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is taken care by Js-Grid by itself, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
&lt;br /&gt;
Sorting in ascending order:-&lt;br /&gt;
[[File:Edit_ascending.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Sorting in descending order:-&lt;br /&gt;
[[File:Edit_descending.png]]&lt;br /&gt;
&lt;br /&gt;
=== We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
A possible solution would be to add a column in the views&amp;gt;suggestion&amp;gt;list.html.erb with a textbox in the table and “send” button and handle sending the comments when the send button is pressed in suggestion_controller.rb. Add an extra column called “feedback” in the suggestion table to store instructor’s comments to the suggested topics.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118080</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118080"/>
		<updated>2018-11-02T19:44:23Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Issue #926 We need a way to sort topics by topic number in assignment#edit page. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link:&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_add_signup_topics.html.erb''' we initialize the new topic with max_choosers as 1.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;% @sign_up_topic = SignUpTopic.new %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic = @sign_up_topic %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic.max_choosers=1 %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[File:Capture.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is taken care by Js-Grid by itself, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
&lt;br /&gt;
Sorting in ascending order&lt;br /&gt;
[[File:Edit_ascending.png]]&lt;br /&gt;
&lt;br /&gt;
Sorting in descending order&lt;br /&gt;
[[File:Edit_descending.png]]&lt;br /&gt;
&lt;br /&gt;
=== We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
A possible solution would be to add a column in the views&amp;gt;suggestion&amp;gt;list.html.erb with a textbox in the table and “send” button and handle sending the comments when the send button is pressed in suggestion_controller.rb. Add an extra column called “feedback” in the suggestion table to store instructor’s comments to the suggested topics.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118078</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118078"/>
		<updated>2018-11-02T19:43:46Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Issue #926 We need a way to sort topics by topic number in assignment#edit page. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link:&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_add_signup_topics.html.erb''' we initialize the new topic with max_choosers as 1.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;% @sign_up_topic = SignUpTopic.new %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic = @sign_up_topic %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic.max_choosers=1 %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[File:Capture.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is taken care by Js-Grid by itself, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
Sorting in ascending order&lt;br /&gt;
[[File:Edit_ascending.png]]&lt;br /&gt;
&lt;br /&gt;
Sorting in descending order&lt;br /&gt;
[[File:Edit_descending.png]]&lt;br /&gt;
&lt;br /&gt;
=== We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
A possible solution would be to add a column in the views&amp;gt;suggestion&amp;gt;list.html.erb with a textbox in the table and “send” button and handle sending the comments when the send button is pressed in suggestion_controller.rb. Add an extra column called “feedback” in the suggestion table to store instructor’s comments to the suggested topics.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118077</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118077"/>
		<updated>2018-11-02T19:43:17Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Issue #926 We need a way to sort topics by topic number in assignment#edit page. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link:&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_add_signup_topics.html.erb''' we initialize the new topic with max_choosers as 1.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;% @sign_up_topic = SignUpTopic.new %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic = @sign_up_topic %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic.max_choosers=1 %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[File:Capture.jpg]]&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is taken care by Js-Grid by itself, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
Sorting in ascending order&lt;br /&gt;
[[File:Edit_ascending.png]]&lt;br /&gt;
&lt;br /&gt;
Sorting in decending order&lt;br /&gt;
&lt;br /&gt;
=== We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
A possible solution would be to add a column in the views&amp;gt;suggestion&amp;gt;list.html.erb with a textbox in the table and “send” button and handle sending the comments when the send button is pressed in suggestion_controller.rb. Add an extra column called “feedback” in the suggestion table to store instructor’s comments to the suggested topics.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118074</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118074"/>
		<updated>2018-11-02T19:38:27Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Issue #926 We need a way to sort topics by topic number in assignment#edit page. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link:&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_add_signup_topics.html.erb''' we initialize the new topic with max_choosers as 1.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;% @sign_up_topic = SignUpTopic.new %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic = @sign_up_topic %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic.max_choosers=1 %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Capture.PNG]]&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is taken care by Js-Grid by itself, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
Sorting in ascending order&lt;br /&gt;
[[File:Edit_ascending.png]]&lt;br /&gt;
Sorting in decending order:-&lt;br /&gt;
[[File:Edit_descending]]&lt;br /&gt;
&lt;br /&gt;
=== We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
A possible solution would be to add a column in the views&amp;gt;suggestion&amp;gt;list.html.erb with a textbox in the table and “send” button and handle sending the comments when the send button is pressed in suggestion_controller.rb. Add an extra column called “feedback” in the suggestion table to store instructor’s comments to the suggested topics.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Edit_descending.png&amp;diff=118073</id>
		<title>File:Edit descending.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Edit_descending.png&amp;diff=118073"/>
		<updated>2018-11-02T19:37:45Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: descending edit topics&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;descending edit topics&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118070</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118070"/>
		<updated>2018-11-02T19:30:56Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Issue #926 We need a way to sort topics by topic number in assignment#edit page. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link:&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_add_signup_topics.html.erb''' we initialize the new topic with max_choosers as 1.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;% @sign_up_topic = SignUpTopic.new %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic = @sign_up_topic %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic.max_choosers=1 %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is taken care by Js-Grid by itself, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
Sorting in ascending order&lt;br /&gt;
[[File:Edit_ascending.png]]&lt;br /&gt;
Sorting in decending order:-&lt;br /&gt;
[[File:Edit_decending.png]]&lt;br /&gt;
&lt;br /&gt;
=== We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
A possible solution would be to add a column in the views&amp;gt;suggestion&amp;gt;list.html.erb with a textbox in the table and “send” button and handle sending the comments when the send button is pressed in suggestion_controller.rb. Add an extra column called “feedback” in the suggestion table to store instructor’s comments to the suggested topics.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118069</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118069"/>
		<updated>2018-11-02T19:30:21Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Issue #926 We need a way to sort topics by topic number in assignment#edit page. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link:&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_add_signup_topics.html.erb''' we initialize the new topic with max_choosers as 1.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;% @sign_up_topic = SignUpTopic.new %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic = @sign_up_topic %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic.max_choosers=1 %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is taken care by Js-Grid by itself, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
Sorting in decending order&lt;br /&gt;
[[File:Edit_ascending.png]]&lt;br /&gt;
Sorting in decending order:-&lt;br /&gt;
[[File:Edit_ascending.png]]&lt;br /&gt;
&lt;br /&gt;
=== We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
A possible solution would be to add a column in the views&amp;gt;suggestion&amp;gt;list.html.erb with a textbox in the table and “send” button and handle sending the comments when the send button is pressed in suggestion_controller.rb. Add an extra column called “feedback” in the suggestion table to store instructor’s comments to the suggested topics.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Edit_ascending.png&amp;diff=118067</id>
		<title>File:Edit ascending.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Edit_ascending.png&amp;diff=118067"/>
		<updated>2018-11-02T19:27:26Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: Edit_ascending.png&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Edit_ascending.png&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118064</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118064"/>
		<updated>2018-11-02T19:21:08Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Issue #926 We need a way to sort topics by topic number in assignment#edit page. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link:&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. To enable AJAX the sign_up_sheet_controller.rb must be modified so that it renders JSON to handle the table/form. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_add_signup_topics.html.erb''' we initialize the new topic with max_choosers as 1.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;% @sign_up_topic = SignUpTopic.new %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic = @sign_up_topic %&amp;gt;&lt;br /&gt;
  &amp;lt;% @topic.max_choosers=1 %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is taken care by Js-Grid by itself, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
&lt;br /&gt;
=== We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
A possible solution would be to add a column in the views&amp;gt;suggestion&amp;gt;list.html.erb with a textbox in the table and “send” button and handle sending the comments when the send button is pressed in suggestion_controller.rb. Add an extra column called “feedback” in the suggestion table to store instructor’s comments to the suggested topics.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118062</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118062"/>
		<updated>2018-11-02T19:20:27Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Issue #926 We need a way to sort topics by topic number in assignment#edit page. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link:&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. To enable AJAX the sign_up_sheet_controller.rb must be modified so that it renders JSON to handle the table/form. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is taken care by Js-Grid by itself, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
[[File:ascending.png]]&lt;br /&gt;
&lt;br /&gt;
=== We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
A possible solution would be to add a column in the views&amp;gt;suggestion&amp;gt;list.html.erb with a textbox in the table and “send” button and handle sending the comments when the send button is pressed in suggestion_controller.rb. Add an extra column called “feedback” in the suggestion table to store instructor’s comments to the suggested topics.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118061</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118061"/>
		<updated>2018-11-02T19:17:36Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Issue #926 We need a way to sort topics by topic number in assignment#edit page. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link:&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
* app/controllers/sign_up_sheet_controller.rb&lt;br /&gt;
* app/views/assignments/edit.html.erb&lt;br /&gt;
* app/controllers/assignments_controller.rb&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. To enable AJAX the sign_up_sheet_controller.rb must be modified so that it renders JSON to handle the table/form. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/edit.html.erb''' we added an additional editable &amp;lt;tr&amp;gt; table element which is appended to the table when the add button is clicked in the topics table.&lt;br /&gt;
It submits a ajax request when the 'save topic button is clicked'&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
  &amp;lt;table class=&amp;quot;table table-striped&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;tr id=&amp;quot;add_topic&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;%= form_for :topic, :url =&amp;gt; sign_up_sheet_index_path(:id =&amp;gt; @assignment_form.assignment.id),:html =&amp;gt; { :onsubmit =&amp;gt; &amp;quot;return showZeroSlotWarning()&amp;quot;,autocomplete: &amp;quot;off&amp;quot;  }  do |f| %&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_identifier %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.text_field :topic_name %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.number_field :max_choosers, min: 0 %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
          &amp;lt;td&amp;gt;&amp;lt;%= f.submit %&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
      &amp;lt;% end %&amp;gt;&lt;br /&gt;
    &amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    function showZeroSlotWarning(){&lt;br /&gt;
        if ($('#topic_max_choosers').val() == 0){&lt;br /&gt;
            alert(&amp;quot;If you create a topic with 0 slots,  students cannot assign this topic.&amp;quot;);&lt;br /&gt;
            return false;&lt;br /&gt;
        }&lt;br /&gt;
    };&lt;br /&gt;
    function addCreateTopicSection(){&lt;br /&gt;
        $(&amp;quot;#topic_table_header&amp;quot;).after($(&amp;quot;#add_topic&amp;quot;));&lt;br /&gt;
        $(&amp;quot;#add_topic&amp;quot;).toggle();&lt;br /&gt;
    };&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the file '''app/views/assignments/_table_header.html.erb''' we added an additional editable &amp;lt;th&amp;gt; table element which adds a add topic button which toggles the editable row for creating topics.&lt;br /&gt;
&amp;lt;pre style=&amp;quot;color: black; border:1px;&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;th width=&amp;quot;3%&amp;quot; align=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;a id=&amp;quot;myLink&amp;quot; title=&amp;quot;Add&amp;quot;&lt;br /&gt;
         href=&amp;quot;#&amp;quot; style=&amp;quot;color: #00aa00; font-size: 26px;&amp;quot; onclick=&amp;quot;addCreateTopicSection();return false;&amp;quot;&amp;gt;+&amp;lt;/a&amp;gt;&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
The task is to sort the Topics according to the topic number. This functionality is taken care by Js-Grid by itself, where clicking the topic# will toggle the topics in the ascending/descending order.&lt;br /&gt;
&lt;br /&gt;
=== We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
A possible solution would be to add a column in the views&amp;gt;suggestion&amp;gt;list.html.erb with a textbox in the table and “send” button and handle sending the comments when the send button is pressed in suggestion_controller.rb. Add an extra column called “feedback” in the suggestion table to store instructor’s comments to the suggested topics.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Ascending.png&amp;diff=118059</id>
		<title>File:Ascending.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Ascending.png&amp;diff=118059"/>
		<updated>2018-11-02T19:15:57Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: uploaded a new version of &amp;amp;quot;File:Ascending.png&amp;amp;quot;: ascending.png&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118049</id>
		<title>E1827 Topic management</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=E1827_Topic_management&amp;diff=118049"/>
		<updated>2018-11-02T18:39:57Z</updated>

		<summary type="html">&lt;p&gt;Rbhasin: /* Files modified */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This wiki page describes the changes made according to the specification of E1827 OSS assignment for Fall 2018.&lt;br /&gt;
----&lt;br /&gt;
== Peer Review Information ==&lt;br /&gt;
The following credentials are recommended for testing the changes:&lt;br /&gt;
&lt;br /&gt;
* Instructor Login: username: instructor6 password: password&lt;br /&gt;
* Youtube link:&lt;br /&gt;
----&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Background ===&lt;br /&gt;
Expertiza is a web portal which can be used to manage assignments related to a course. It provides a platform to view assignments, manage teams, select topics and work on improvement through anonymous peer reviews.&lt;br /&gt;
&lt;br /&gt;
=== Problem Statement ===&lt;br /&gt;
Expertiza allows the instructor to define different topics that students or teams could choose from as their assignment. Each topic can have 0 or more slots that indicate the number of students or teams that can sign up for that topic. We identified several ideas that can improve user experience when managing the topics. Thus, we would like you to introduce new features to implement these ideas.&lt;br /&gt;
&lt;br /&gt;
===== What needs to be done?: =====&lt;br /&gt;
&lt;br /&gt;
* Issue #971 Change create topic UI into AJAX.&lt;br /&gt;
&lt;br /&gt;
* Issue #926 We need a way to sort topics by topic number in assignment#edit page.&lt;br /&gt;
&lt;br /&gt;
* Issue #718 We should allow instructors to give feedback when accepting or rejecting topic suggestions.&lt;br /&gt;
----&lt;br /&gt;
== Files modified ==&lt;br /&gt;
The following files were modified&lt;br /&gt;
* app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
* app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
*app/views/sign_up_sheet/_table_line.html.erb&lt;br /&gt;
*app/views/sign_up_sheet/_add_signup_topics.html.erb&lt;br /&gt;
*app/views/sign_up_sheet/_table_header.html.erb&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
== Files Added ==&lt;br /&gt;
The following files were added&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
*&lt;br /&gt;
----&lt;br /&gt;
== Solutions Implemented ==&lt;br /&gt;
=== Issue #971 Change create topic UI into AJAX ===&lt;br /&gt;
Currently, when instructors manually enter topics, they have to go back and forth between the list of the topic page (views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb) and the create topic page (views&amp;gt;sign_up_sheet&amp;gt;new.html.erb). This should be done via AJAX so that the adding a new topic can be done through an editable grid or a popup form without leaving the list of topic page. Then and the list should be automatically updated when a new topic is entered. To enable AJAX the sign_up_sheet_controller.rb must be modified so that it renders JSON to handle the table/form. &lt;br /&gt;
&lt;br /&gt;
In addition, when adding a topic, the default slot should be 1 instead of 0. the current warning message that shows up when the slot is 0, can't be closed properly and should be fixed (if the form is made popup in the future, the warning should be on the same page as the form e.g., highlight the field and print an instruction to change the # of slot).&lt;br /&gt;
&lt;br /&gt;
=== Issue #926 We need a way to sort topics by topic number in assignment#edit page.  ===&lt;br /&gt;
Use the TableSorter css that is already used by several tables in Expertiza (see its documentation here) to enable sorting of the topics by the table headers in views&amp;gt;sign_up_sheet&amp;gt;_add_signup_topics.html.erb.&lt;br /&gt;
&lt;br /&gt;
=== We should allow instructors to give feedback when accepting or rejecting topic suggestions.  ===&lt;br /&gt;
As it is, one can give feedback on topics suggested by students only when the instructor wants the topic to be revised, not when (s)he is approving or rejecting it. Feedback should be possible in any of these cases.&lt;br /&gt;
&lt;br /&gt;
A possible solution would be to add a column in the views&amp;gt;suggestion&amp;gt;list.html.erb with a textbox in the table and “send” button and handle sending the comments when the send button is pressed in suggestion_controller.rb. Add an extra column called “feedback” in the suggestion table to store instructor’s comments to the suggested topics.&lt;/div&gt;</summary>
		<author><name>Rbhasin</name></author>
	</entry>
</feed>