<?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=Aksahoo</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=Aksahoo"/>
	<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Special:Contributions/Aksahoo"/>
	<updated>2026-08-15T00:12:24Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.41.0</generator>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1824:_Let_course_staff_as_well_as_students_do_reviews&amp;diff=117389</id>
		<title>CSC/ECE 517 Spring 2018- Project E1824: Let course staff as well as students do reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1824:_Let_course_staff_as_well_as_students_do_reviews&amp;diff=117389"/>
		<updated>2018-05-04T00:17:04Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* External Links */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction''' ==&lt;br /&gt;
&lt;br /&gt;
The way Expertiza is set up right now is that only peers can review your work. However, there are cases when the course staff (Instructor/ TAs) would want to submit reviews as well. This project aims to implement this feature by allowing course staff to review the project on the same metrics as other students who review the project. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''Problem Statement''' ==&lt;br /&gt;
&lt;br /&gt;
Peer review is a great way for students to learn about how well they have developed their application. However there are some problems with this:&lt;br /&gt;
* Sometimes, the peer reviews may not be thorough and the team/person's work reviewed might not reflect the actual status of the development.&lt;br /&gt;
* The reviewer might not know how well they are reviewing the peers work. They might not entirely know as to what tone to use or what suggestions to put forward.&lt;br /&gt;
&lt;br /&gt;
By letting course staff perform reviews as well, the reviewer and the reviewee are both benefited, which can improve the overall learning experience.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Current scenario ===&lt;br /&gt;
&lt;br /&gt;
This is how some of the pages we are concerned with, currently look.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Submissions page for an assignment in Instructor View ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File: Submissions_instr.jpeg | center]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== A typical Scores table in a Student View ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File: Grades_view_team_current.png | center]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''Proposed Solutions and Implementation''' ==&lt;br /&gt;
&lt;br /&gt;
We performed the following changes to let staff perform reviews as well:&lt;br /&gt;
&lt;br /&gt;
'''Step 1: Add a way for the instructors to perform a review.'''&lt;br /&gt;
&lt;br /&gt;
To do this, we added links for performing/viewing/editing/updating a review in the assignment submissions view. &lt;br /&gt;
When the instructor/TA reviews a work for the first time, he is added as a participant and a review response mapping is created. &lt;br /&gt;
&lt;br /&gt;
Files edited:&lt;br /&gt;
* '''View: ''' ''app/views/assignments/list_submissions.html.erb'' - To add links in the instructor view&lt;br /&gt;
* '''Controller: ''' ''app/controllers/review_mapping_controller.rb''  - Method: add_instructor_as_reviewer&lt;br /&gt;
&lt;br /&gt;
Code snippet from the controller:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  def add_instructor_as_reviewer&lt;br /&gt;
    assignment_team = AssignmentTeam.find(params[:team_id])&lt;br /&gt;
    reviewer = AssignmentParticipant.where(user_id: params[:reviewer_id], parent_id: assignment_team.parent_id).first&lt;br /&gt;
    if reviewer.nil?&lt;br /&gt;
      reviewer = AssignmentParticipant.create(parent_id: assignment_team.parent_id, user_id: session[:user].id, can_submit: false, can_review: true,&lt;br /&gt;
                                              can_take_quiz: false, handle: 'handle')&lt;br /&gt;
&lt;br /&gt;
    end&lt;br /&gt;
    @review_map_id=ReviewResponseMap.where(reviewee_id: assignment_team.id, reviewer_id: reviewer.id,&lt;br /&gt;
                             reviewed_object_id: params[:assignment_id]).first&lt;br /&gt;
    @review_map_id=assignment_team.assign_reviewer(reviewer) if @review_map_id.nil?&lt;br /&gt;
    redirect_to controller: 'response', action: 'new', id: @review_map_id.map_id&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &lt;br /&gt;
[[File:Instructor review view.PNG | center]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In the second case, we can see a 'Perform review' link. This is the initial state when instructor review has not been added to the submission.&lt;br /&gt;
Once the instructor adds a review and submits it, we can see the 'View review'. In case he just saves the review, an 'Edit review' link will appear.&lt;br /&gt;
If the review deadline of one round is passed, the 'Edit review' link becomes 'Update review' link. This follows in line with what the student sees while performing a review. However, the course staff will be allowed to perform a review even if the deadline for reviewing has passed.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Step 2: Add the instructor review in ''Your Scores'' table in case he has reviewed your work. Provide a highlight/way to make it look distinct.'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Files edited:&lt;br /&gt;
* '''Assets: ''' ''app/assets/stylesheets/grades.scss'' - To make an instructor performed review distinct from other reviews&lt;br /&gt;
* '''View: ''' ''app/views/grades/view_team.html.erb'' - Modified the &amp;quot;Others work&amp;quot; page to include the instructor review as well as ensure the score is not used.&lt;br /&gt;
* '''Models: ''' &lt;br /&gt;
** ''app/models/answer.rb'' - Method: compute_scores | Modification in logic to ensure instructor review scores are not counted in the overall score of the student.&lt;br /&gt;
** ''app/models/vm_question_response_score_cell.rb'' - Included a new variable called 'is_instructor_review' to identify an instructor review&lt;br /&gt;
** ''app/models/vm_question_response_row.rb'' - Change in average_score_for_row method to not include an instructor review score&lt;br /&gt;
** ''app/models/vm_question_response.rb'' - Modified the add_answer method to include the is_instructor_review to each row_score object&lt;br /&gt;
&lt;br /&gt;
Code snippet from the add_answer method:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  participant= Participant.find(ResponseMap.find(Response.find(response_id).map_id).reviewer_id)&lt;br /&gt;
  user_id = participant.user_id&lt;br /&gt;
  course =  Course.find(@assignment.course_id)&lt;br /&gt;
  row.score_row.push(VmQuestionResponseScoreCell.new(answer.answer, color_code, answer.comments,&lt;br /&gt;
                     course.is_ta_or_instructor?(user_id), vm_tag_prompts))&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:View_team.PNG | center]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
A student should be able to make out if an instructor has reviewed his/his team's work. In case the instructor performs a review on the team's work, it will highlight the instructor's review with a golden border as seen in the round two score table along with explicitly stating that it is an 'Instructor review'.&lt;br /&gt;
The average peer review score for the team has been modified to exclude the instructor's scores. Same has been taken into account for the average score calculated for each row.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Additional Files modified:&lt;br /&gt;
* '''Controllers: '''&lt;br /&gt;
** ''app/controllers/response_controller.rb'' - Change in re-directions in case of an instructor taking him back to the submissions page.&lt;br /&gt;
* '''Models: '''&lt;br /&gt;
** ''app/models/assignment.rb'' - Method: number_of_current_round_for_instructor | To allow an instructor to review an assignment even after the due date&lt;br /&gt;
** ''app/models/course.rb'' - Method: is_ta_or_instructor? | To identify whether the user is a TA or an instructor of the current course&lt;br /&gt;
&lt;br /&gt;
Code snippet from the model:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  def is_ta_or_instructor?(user_id)&lt;br /&gt;
    instructors = TaMapping.where(course_id: self.id).collect { |x| x.ta_id}&lt;br /&gt;
    instructors.push(self.instructor_id)&lt;br /&gt;
    return user_id.in?(instructors)&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== '''Test Plan''' ==&lt;br /&gt;
&lt;br /&gt;
'''Features testing:''' Many of our changes are reflected on views (user interface). Following is the list of tests that are conducted with rspec/capybara.&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;should let instructor/TAs perform a review for the submission of latest finished round if instructor/TAs has not started a review for the submission yet&amp;quot;&lt;br /&gt;
# it &amp;quot;should let instructor/TAs save a review&amp;quot;&lt;br /&gt;
# it &amp;quot;should let instructor/TAs review a previously saved review&amp;quot;&lt;br /&gt;
# it &amp;quot;should let instructor/TAs edit a previously saved review&amp;quot;&lt;br /&gt;
# it &amp;quot;should allow instructor/TAs perform a review after the deadline for reviewing has passed&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
describe &amp;quot;instructor review testing&amp;quot; do&lt;br /&gt;
  before(:each) do&lt;br /&gt;
    create(:assignment, name: &amp;quot;TestAssignment&amp;quot;, directory_path: 'test_assignment')&lt;br /&gt;
    create_list(:participant, 3)&lt;br /&gt;
    create(:assignment_node)&lt;br /&gt;
    create(:deadline_type, name: &amp;quot;submission&amp;quot;)&lt;br /&gt;
    create(:deadline_type, name: &amp;quot;review&amp;quot;)&lt;br /&gt;
    create(:deadline_type, name: &amp;quot;metareview&amp;quot;)&lt;br /&gt;
    create(:deadline_type, name: &amp;quot;drop_topic&amp;quot;)&lt;br /&gt;
    create(:deadline_type, name: &amp;quot;signup&amp;quot;)&lt;br /&gt;
    create(:deadline_type, name: &amp;quot;team_formation&amp;quot;)&lt;br /&gt;
    create(:deadline_right)&lt;br /&gt;
    create(:deadline_right, name: 'Late')&lt;br /&gt;
    create(:deadline_right, name: 'OK')&lt;br /&gt;
    create(:assignment_due_date, deadline_type: DeadlineType.where(name: 'review').first, due_at: Time.now.in_time_zone + 1.day)&lt;br /&gt;
    create(:topic)&lt;br /&gt;
    create(:topic, topic_name: &amp;quot;TestReview&amp;quot;)&lt;br /&gt;
    create(:team_user, user: User.where(role_id: 2).first)&lt;br /&gt;
    create(:team_user, user: User.where(role_id: 2).second)&lt;br /&gt;
    create(:assignment_team)&lt;br /&gt;
    create(:team_user, user: User.where(role_id: 2).third, team: AssignmentTeam.second)&lt;br /&gt;
    create(:signed_up_team)&lt;br /&gt;
    create(:signed_up_team, team_id: 2, topic: SignUpTopic.second)&lt;br /&gt;
    create(:assignment_questionnaire)&lt;br /&gt;
    create(:question)&lt;br /&gt;
    create(:review_response_map, reviewer_id: User.find_by(name: &amp;quot;instructor6&amp;quot;).id, reviewee: AssignmentTeam.second)&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;lets instructor perform a review and saves&amp;quot; do&lt;br /&gt;
    assignment = Assignment.first&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit &amp;quot;/assignments/list_submissions?id=#{assignment.id}&amp;quot;&lt;br /&gt;
    expect(page).to have_content 'Perform review'&lt;br /&gt;
    all(:link, 'Perform review')[1].click&lt;br /&gt;
    fill_in &amp;quot;responses[0][comment]&amp;quot;, with: &amp;quot;DRY&amp;quot;&lt;br /&gt;
    select 5, from: &amp;quot;responses[0][score]&amp;quot;&lt;br /&gt;
    click_button &amp;quot;Save Review&amp;quot;&lt;br /&gt;
    expect(page).to have_content &amp;quot;Your response was successfully saved.&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;lets instructor view a saved review&amp;quot; do&lt;br /&gt;
    assignment = Assignment.first&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit &amp;quot;/assignments/list_submissions?id=#{assignment.id}&amp;quot;&lt;br /&gt;
    all(:link, 'Perform review')[1].click&lt;br /&gt;
    fill_in &amp;quot;responses[0][comment]&amp;quot;, with: &amp;quot;Hello world&amp;quot;&lt;br /&gt;
    click_button &amp;quot;Save Review&amp;quot;&lt;br /&gt;
    visit &amp;quot;/assignments/list_submissions?id=#{assignment.id}&amp;quot;&lt;br /&gt;
    expect(page).to have_content 'View review'&lt;br /&gt;
    click_link &amp;quot;View review&amp;quot;&lt;br /&gt;
    expect(page).to have_content &amp;quot;show review&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;lets instructor edit a saved review and saves&amp;quot; do&lt;br /&gt;
    assignment = Assignment.first&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit &amp;quot;/assignments/list_submissions?id=#{assignment.id}&amp;quot;&lt;br /&gt;
    all(:link, 'Perform review')[1].click&lt;br /&gt;
    fill_in &amp;quot;responses[0][comment]&amp;quot;, with: &amp;quot;Good job&amp;quot;&lt;br /&gt;
    click_button &amp;quot;Save Review&amp;quot;&lt;br /&gt;
    visit &amp;quot;/assignments/list_submissions?id=#{assignment.id}&amp;quot;&lt;br /&gt;
    expect(page).to have_content 'Edit review'&lt;br /&gt;
    click_link &amp;quot;Edit review&amp;quot;&lt;br /&gt;
    expect(page).to have_text &amp;quot;Good job&amp;quot;&lt;br /&gt;
    fill_in &amp;quot;review[comments]&amp;quot;, with: &amp;quot;Excellent work&amp;quot;&lt;br /&gt;
    click_button &amp;quot;Save Review&amp;quot;&lt;br /&gt;
    expect(page.current_path).to eq &amp;quot;/assignments/list_submissions&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;allows instructor perform a review and saves after deadline for reviewing has passed&amp;quot; do&lt;br /&gt;
    assignment = Assignment.first&lt;br /&gt;
    due_date = AssignmentDueDate.first&lt;br /&gt;
    due_date.due_at = Time.now.in_time_zone - 1.day&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit &amp;quot;/assignments/list_submissions?id=#{assignment.id}&amp;quot;&lt;br /&gt;
    expect(page).to have_content 'Perform review'&lt;br /&gt;
    all(:link, 'Perform review')[1].click&lt;br /&gt;
    fill_in &amp;quot;responses[0][comment]&amp;quot;, with: &amp;quot;DRY&amp;quot;&lt;br /&gt;
    select 5, from: &amp;quot;responses[0][score]&amp;quot;&lt;br /&gt;
    click_button &amp;quot;Save Review&amp;quot;&lt;br /&gt;
    expect(page).to have_content &amp;quot;Your response was successfully saved.&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Controllers testing:''' review_mapping_controller#add_instructor_as_reviewer&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  describe '#add_instructor_as_reviewer' do&lt;br /&gt;
    context 'when instructor is not a participant for the assignment and review_response_map has not been created' do&lt;br /&gt;
      it 'adds instructor as a participant for the assignment and creates review_response_map and redirects to responses#new' do&lt;br /&gt;
        allow(AssignmentTeam).to receive(:find).with('1').and_return(team2)&lt;br /&gt;
        allow(AssignmentParticipant).to receive_message_chain(:where, :first)&lt;br /&gt;
          .with(user_id: 1, parent_id: '1').with(no_args).and_return(nil)&lt;br /&gt;
        allow(AssignmentParticipant).to receive(:create)&lt;br /&gt;
          .with(parent_id: '1', user_id: 1, can_submit: false, can_review: true, can_take_quiz: false, handle: 'handle').and_return(participant)&lt;br /&gt;
        allow(ReviewResponseMap).to receive_message_chain(:where, :first)&lt;br /&gt;
          .with(reviewee_id: '1', reviewer_id: 1, reviewed_object_id: '1').with(no_args).and_return(nil)&lt;br /&gt;
        allow(team2).to receive(:assign_reviewer)&lt;br /&gt;
          .with(participant).and_return(review_response_map)&lt;br /&gt;
        params = {id: 1, team_id: 1, assignment_id: 1}&lt;br /&gt;
        session = {user: build(:instructor, id: 1)}&lt;br /&gt;
        get :add_instructor_as_reviewer, params, session&lt;br /&gt;
        expect(response).to redirect_to '/response/new?id=1'&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    context 'when instructor is already a participant for the assignment and review_response_map has been created' do&lt;br /&gt;
      it 'does not need to add instructor as a participant for the assignment or create review_repsonse_map and redirects to response#new' do&lt;br /&gt;
        allow(AssignmentTeam).to receive(:find).with('1').and_return(team2)&lt;br /&gt;
        allow(AssignmentParticipant).to receive_message_chain(:where, :first)&lt;br /&gt;
          .with(user_id: 1, parent_id: '1').with(no_args).and_return(participant)&lt;br /&gt;
        allow(ReviewResponseMap).to receive_message_chain(:where, :first)&lt;br /&gt;
          .with(reviewee_id: '1', reviewer_id: 1, reviewed_object_id: '1').with(no_args).and_return(review_response_map)&lt;br /&gt;
        params = {id: 1, team_id: 1, assignment_id: 1}&lt;br /&gt;
        session = {user: build(:instructor, id: 1)}&lt;br /&gt;
        get :add_instructor_as_reviewer, params, session&lt;br /&gt;
        expect(response).to redirect_to '/response/new?id=1'&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''More testing:''' &lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;should let instructor/TAs update a review for the submission of latest finished round if instructor/TAs performed and saved a review for the previous round&amp;quot;&lt;br /&gt;
# it &amp;quot;should show &amp;quot;Instructor review&amp;quot; when a student views feedback on his/her submission if an instructor/TA has reviewed his/his team's work&amp;quot;&lt;br /&gt;
# it &amp;quot;should exclude the instructor's/TA's review score when calculating the average peer review score for the team&amp;quot;&lt;br /&gt;
# it &amp;quot;should exclude the instructor's/TA's review score when calculating the average score for each question in the review&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== '''External Links''' ==&lt;br /&gt;
* Forked Repository: https://github.com/kushalnawalakha/expertiza&lt;br /&gt;
* Pull Request: https://github.com/expertiza/expertiza/pull/1182&lt;br /&gt;
* Deployment: http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000/&lt;br /&gt;
* Screencast Demo Link: https://youtu.be/_r0qHcaaq1o&lt;br /&gt;
&lt;br /&gt;
== '''Team Members''' ==&lt;br /&gt;
*Ashis Sahoo&lt;br /&gt;
*Satvik Shetty&lt;br /&gt;
*Xiaohui Ellis&lt;br /&gt;
*Kushal Nawalakha&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''References''' ==&lt;br /&gt;
&lt;br /&gt;
Expertiza&lt;br /&gt;
* https://expertiza.ncsu.edu/ &lt;br /&gt;
&lt;br /&gt;
Expertiza Github&lt;br /&gt;
* https://github.com/expertiza/expertiza&lt;br /&gt;
&lt;br /&gt;
Expertiza Documentation&lt;br /&gt;
* http://wiki.expertiza.ncsu.edu/index.php/Expertiza_documentation&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1824:_Let_course_staff_as_well_as_students_do_reviews&amp;diff=117262</id>
		<title>CSC/ECE 517 Spring 2018- Project E1824: Let course staff as well as students do reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1824:_Let_course_staff_as_well_as_students_do_reviews&amp;diff=117262"/>
		<updated>2018-04-29T08:24:34Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* External Links */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction''' ==&lt;br /&gt;
&lt;br /&gt;
The way Expertiza is set up right now is that only peers can review your work. However, there are cases when the instructor would want to submit reviews as well. This project aims to implement this feature by allowing instructors to review the project on the same metrics as other students who review the project. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''Problem Statement''' ==&lt;br /&gt;
&lt;br /&gt;
Peer review is a great way for students to learn about how well they have developed their application. However there are some problems with this:&lt;br /&gt;
* Sometimes, the peer reviews may not be thorough and the team/person's work reviewed might not reflect the actual status of the development.&lt;br /&gt;
* The reviewer might not know how well they are reviewing the peer's work. They might not entirely know as to what tone to use or what suggestions to put forward.&lt;br /&gt;
&lt;br /&gt;
By letting course staff perform reviews as well, the reviewer and the reviewee are both benefited, which can improve the overall learning experience.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Current scenario ===&lt;br /&gt;
&lt;br /&gt;
This is how some of the pages we are concerned with, currently look.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Submissions page for an assignment in Instructor View ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File: Submissions_instr.jpeg | center]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== A typical Scores table in a Student View ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File: Grades_view_team_current.png | center]]&lt;br /&gt;
&lt;br /&gt;
== '''Proposed Solutions''' ==&lt;br /&gt;
&lt;br /&gt;
We propose to perform the following changes to let staff perform reviews as well:&lt;br /&gt;
&lt;br /&gt;
'''Step 1: Add a ''Perform review'' link in the assignment submissions page view for the instructors.'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Files to be edited:&lt;br /&gt;
* '''View: ''' ''app/views/assignments/list_submissions.html.erb''&lt;br /&gt;
* '''Controller: ''' ''app/controllers/response_controller.rb''  - Add authorization for instructors to perform review&lt;br /&gt;
&lt;br /&gt;
[[File:Instructor review view.PNG | center]]&lt;br /&gt;
&lt;br /&gt;
In the second case, we can see a 'Perform Review' link. This is the initial state when instructor review has not been added to the submission.&lt;br /&gt;
Once the instructor adds a review, we can see the 'View Review' and 'Edit Review' links, as seen in the first case.&lt;br /&gt;
If the review deadline of one round is passed, the 'Edit Review' link becomes 'Update Review' link. The course staff will be allowed to perform a review even if the deadline for reviewing has passed.&lt;br /&gt;
&lt;br /&gt;
'''Step 2: Add instructor review in ''Your Scores'' table in case he has reviewed your work. Provide a highlight/way to make it look distinct.'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Files to be edited:&lt;br /&gt;
* '''View: ''' ''app/views/grades/view_team.html.erb''&lt;br /&gt;
* '''Controller: ''' ''app/controllers/grades_controller.rb'' - Method: view_team&lt;br /&gt;
&lt;br /&gt;
[[File:View_team.PNG | center]]&lt;br /&gt;
&lt;br /&gt;
A student should be able to make out if an instructor has reviewed his/his team's work. In case the instructor performs a review on the team's work, it will highlight the instructor's review as seen in the round two score table.&lt;br /&gt;
The average peer review score for the team has been modified to exclude the instructor's scores. Same has been taken into account for the average score calculated for each row.&lt;br /&gt;
&lt;br /&gt;
== '''Test Plan''' ==&lt;br /&gt;
&lt;br /&gt;
Many of our changes would be reflected on views (user interface). Following is the list of tests that should be conducted with rspec/capybara:&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;should see the Perform Review link (beside Assign Grade link) for each submission after a list of submissions are pulled up by an instructor if the final due date for the assignment has passed&amp;quot;&lt;br /&gt;
# it &amp;quot;should see the Perform Review link only for each submission after a list of submissions are pulled up by an instructor if the final due date for the assignment has not passed and review period has started and review deadline has not passed&amp;quot;&lt;br /&gt;
# it &amp;quot;should see neither Perform Review link nor Assign Grade link after a list of submissions are pulled up by an instructor if the final due date for the assignment has not passed and review period has not started&amp;quot;&lt;br /&gt;
# it &amp;quot;should pull up a review page for the submission of the team after the Perform Review link is clicked on by an instructor&amp;quot;&lt;br /&gt;
# it &amp;quot;should show highlighted reviews done by instructors when a student views feedback on his/her submission&amp;quot;&lt;br /&gt;
# it &amp;quot;should pull up a calibration report when a student wants to see the difference between his/her reviews on other's submission and the instructor's&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''External Links''' ==&lt;br /&gt;
* Forked Repository: https://github.com/kushalnawalakha/expertiza&lt;br /&gt;
* Pull Request: https://github.com/expertiza/expertiza/pull/1182&lt;br /&gt;
* Deployment: http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000/&lt;br /&gt;
&lt;br /&gt;
== '''Team Members''' ==&lt;br /&gt;
*Ashis Sahoo&lt;br /&gt;
*Satvik Shetty&lt;br /&gt;
*Xiaohui Ellis&lt;br /&gt;
*Kushal Nawalakha&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''References''' ==&lt;br /&gt;
&lt;br /&gt;
Expertiza&lt;br /&gt;
* https://expertiza.ncsu.edu/ &lt;br /&gt;
&lt;br /&gt;
Expertiza Github&lt;br /&gt;
* https://github.com/expertiza/expertiza&lt;br /&gt;
&lt;br /&gt;
Expertiza Documentation&lt;br /&gt;
* http://wiki.expertiza.ncsu.edu/index.php/Expertiza_documentation&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1824:_Let_course_staff_as_well_as_students_do_reviews&amp;diff=117261</id>
		<title>CSC/ECE 517 Spring 2018- Project E1824: Let course staff as well as students do reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1824:_Let_course_staff_as_well_as_students_do_reviews&amp;diff=117261"/>
		<updated>2018-04-29T06:59:17Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Proposed Solutions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction''' ==&lt;br /&gt;
&lt;br /&gt;
The way Expertiza is set up right now is that only peers can review your work. However, there are cases when the instructor would want to submit reviews as well. This project aims to implement this feature by allowing instructors to review the project on the same metrics as other students who review the project. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''Problem Statement''' ==&lt;br /&gt;
&lt;br /&gt;
Peer review is a great way for students to learn about how well they have developed their application. However there are some problems with this:&lt;br /&gt;
* Sometimes, the peer reviews may not be thorough and the team/person's work reviewed might not reflect the actual status of the development.&lt;br /&gt;
* The reviewer might not know how well they are reviewing the peer's work. They might not entirely know as to what tone to use or what suggestions to put forward.&lt;br /&gt;
&lt;br /&gt;
By letting course staff perform reviews as well, the reviewer and the reviewee are both benefited, which can improve the overall learning experience.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Current scenario ===&lt;br /&gt;
&lt;br /&gt;
This is how some of the pages we are concerned with, currently look.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Submissions page for an assignment in Instructor View ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File: Submissions_instr.jpeg | center]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== A typical Scores table in a Student View ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File: Grades_view_team_current.png | center]]&lt;br /&gt;
&lt;br /&gt;
== '''Proposed Solutions''' ==&lt;br /&gt;
&lt;br /&gt;
We propose to perform the following changes to let staff perform reviews as well:&lt;br /&gt;
&lt;br /&gt;
'''Step 1: Add a ''Perform review'' link in the assignment submissions page view for the instructors.'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Files to be edited:&lt;br /&gt;
* '''View: ''' ''app/views/assignments/list_submissions.html.erb''&lt;br /&gt;
* '''Controller: ''' ''app/controllers/response_controller.rb''  - Add authorization for instructors to perform review&lt;br /&gt;
&lt;br /&gt;
[[File:Instructor review view.PNG | center]]&lt;br /&gt;
&lt;br /&gt;
In the second case, we can see a 'Perform Review' link. This is the initial state when instructor review has not been added to the submission.&lt;br /&gt;
Once the instructor adds a review, we can see the 'View Review' and 'Edit Review' links, as seen in the first case.&lt;br /&gt;
If the review deadline of one round is passed, the 'Edit Review' link becomes 'Update Review' link. The course staff will be allowed to perform a review even if the deadline for reviewing has passed.&lt;br /&gt;
&lt;br /&gt;
'''Step 2: Add instructor review in ''Your Scores'' table in case he has reviewed your work. Provide a highlight/way to make it look distinct.'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Files to be edited:&lt;br /&gt;
* '''View: ''' ''app/views/grades/view_team.html.erb''&lt;br /&gt;
* '''Controller: ''' ''app/controllers/grades_controller.rb'' - Method: view_team&lt;br /&gt;
&lt;br /&gt;
[[File:View_team.PNG | center]]&lt;br /&gt;
&lt;br /&gt;
A student should be able to make out if an instructor has reviewed his/his team's work. In case the instructor performs a review on the team's work, it will highlight the instructor's review as seen in the round two score table.&lt;br /&gt;
The average peer review score for the team has been modified to exclude the instructor's scores. Same has been taken into account for the average score calculated for each row.&lt;br /&gt;
&lt;br /&gt;
== '''Test Plan''' ==&lt;br /&gt;
&lt;br /&gt;
Many of our changes would be reflected on views (user interface). Following is the list of tests that should be conducted with rspec/capybara:&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;should see the Perform Review link (beside Assign Grade link) for each submission after a list of submissions are pulled up by an instructor if the final due date for the assignment has passed&amp;quot;&lt;br /&gt;
# it &amp;quot;should see the Perform Review link only for each submission after a list of submissions are pulled up by an instructor if the final due date for the assignment has not passed and review period has started and review deadline has not passed&amp;quot;&lt;br /&gt;
# it &amp;quot;should see neither Perform Review link nor Assign Grade link after a list of submissions are pulled up by an instructor if the final due date for the assignment has not passed and review period has not started&amp;quot;&lt;br /&gt;
# it &amp;quot;should pull up a review page for the submission of the team after the Perform Review link is clicked on by an instructor&amp;quot;&lt;br /&gt;
# it &amp;quot;should show highlighted reviews done by instructors when a student views feedback on his/her submission&amp;quot;&lt;br /&gt;
# it &amp;quot;should pull up a calibration report when a student wants to see the difference between his/her reviews on other's submission and the instructor's&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''External Links''' ==&lt;br /&gt;
* Forked Repository: https://github.com/kushalnawalakha/expertiza&lt;br /&gt;
* Deployment: http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''Team Members''' ==&lt;br /&gt;
*Ashis Sahoo&lt;br /&gt;
*Satvik Shetty&lt;br /&gt;
*Xiaohui Ellis&lt;br /&gt;
*Kushal Nawalakha&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''References''' ==&lt;br /&gt;
&lt;br /&gt;
Expertiza&lt;br /&gt;
* https://expertiza.ncsu.edu/ &lt;br /&gt;
&lt;br /&gt;
Expertiza Github&lt;br /&gt;
* https://github.com/expertiza/expertiza&lt;br /&gt;
&lt;br /&gt;
Expertiza Documentation&lt;br /&gt;
* http://wiki.expertiza.ncsu.edu/index.php/Expertiza_documentation&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:View_team.PNG&amp;diff=117260</id>
		<title>File:View team.PNG</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:View_team.PNG&amp;diff=117260"/>
		<updated>2018-04-29T06:50:00Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1824:_Let_course_staff_as_well_as_students_do_reviews&amp;diff=117256</id>
		<title>CSC/ECE 517 Spring 2018- Project E1824: Let course staff as well as students do reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1824:_Let_course_staff_as_well_as_students_do_reviews&amp;diff=117256"/>
		<updated>2018-04-29T05:04:40Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Proposed Solutions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction''' ==&lt;br /&gt;
&lt;br /&gt;
The way Expertiza is set up right now is that only peers can review your work. However, there are cases when the instructor would want to submit reviews as well. This project aims to implement this feature by allowing instructors to review the project on the same metrics as other students who review the project. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''Problem Statement''' ==&lt;br /&gt;
&lt;br /&gt;
Peer review is a great way for students to learn about how well they have developed their application. However there are some problems with this:&lt;br /&gt;
* Sometimes, the peer reviews may not be thorough and the team/person's work reviewed might not reflect the actual status of the development.&lt;br /&gt;
* The reviewer might not know how well they are reviewing the peer's work. They might not entirely know as to what tone to use or what suggestions to put forward.&lt;br /&gt;
&lt;br /&gt;
By letting course staff perform reviews as well, the reviewer and the reviewee are both benefited, which can improve the overall learning experience.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Current scenario ===&lt;br /&gt;
&lt;br /&gt;
This is how some of the pages we are concerned with, currently look.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Submissions page for an assignment in Instructor View ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File: Submissions_instr.jpeg | center]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== A typical Scores table in a Student View ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File: Grades_view_team_current.png | center]]&lt;br /&gt;
&lt;br /&gt;
== '''Proposed Solutions''' ==&lt;br /&gt;
&lt;br /&gt;
We propose to perform the following changes to let staff perform reviews as well:&lt;br /&gt;
&lt;br /&gt;
'''Step 1: Add a ''Perform review'' link in the assignment submissions page view for the instructors.'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Files to be edited:&lt;br /&gt;
* '''View: ''' ''app/views/assignments/list_submissions.html.erb''&lt;br /&gt;
* '''Controller: ''' ''app/controllers/response_controller.rb''  - Add authorization for instructors to perform review&lt;br /&gt;
&lt;br /&gt;
[[File:Instructor review view.PNG | center]]&lt;br /&gt;
&lt;br /&gt;
In the second case, we can see a 'Perform Review' link. This is the initial state when instructor review has not been added to the submission.&lt;br /&gt;
Once the instructor adds a review, we can see the 'View Review' and 'Edit Review' links, as seen in the first case.&lt;br /&gt;
If the review deadline of one round is passed, the 'Edit Review' link becomes 'Update Review' link. The course staff will be allowed to perform a review even if the deadline for reviewing has passed.&lt;br /&gt;
&lt;br /&gt;
In the second case, an intermediate submission deadline has passed and hence there is a link only for performing a review.&lt;br /&gt;
&lt;br /&gt;
In the third case, if no submission deadline has passed, there won't be a link for Performing a review nor assigning a grade. [No, it should be dependent on whether reviewing is allowed during the current assignment phase.]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Step 2: Add instructor review in ''Your Scores'' table in case he has reviewed your work. Provide a highlight/way to make it look distinct.'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Files to be edited:&lt;br /&gt;
* '''View: ''' ''app/views/grades/view_team.html.erb''&lt;br /&gt;
* '''Controller: ''' ''app/controllers/grades_controller.rb'' - Method: view_team&lt;br /&gt;
&lt;br /&gt;
[[File: Grades_view_team_instr.png | center]]&lt;br /&gt;
&lt;br /&gt;
A student should be able to make out if an instructor has reviewed his/his team's work. In case the instructor performs a review on the team's work, it will highlight the instructor's review.&lt;br /&gt;
&lt;br /&gt;
== '''Test Plan''' ==&lt;br /&gt;
&lt;br /&gt;
Many of our changes would be reflected on views (user interface). Following is the list of tests that should be conducted with rspec/capybara:&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;should see the Perform Review link (beside Assign Grade link) for each submission after a list of submissions are pulled up by an instructor if the final due date for the assignment has passed&amp;quot;&lt;br /&gt;
# it &amp;quot;should see the Perform Review link only for each submission after a list of submissions are pulled up by an instructor if the final due date for the assignment has not passed and review period has started and review deadline has not passed&amp;quot;&lt;br /&gt;
# it &amp;quot;should see neither Perform Review link nor Assign Grade link after a list of submissions are pulled up by an instructor if the final due date for the assignment has not passed and review period has not started&amp;quot;&lt;br /&gt;
# it &amp;quot;should pull up a review page for the submission of the team after the Perform Review link is clicked on by an instructor&amp;quot;&lt;br /&gt;
# it &amp;quot;should show highlighted reviews done by instructors when a student views feedback on his/her submission&amp;quot;&lt;br /&gt;
# it &amp;quot;should pull up a calibration report when a student wants to see the difference between his/her reviews on other's submission and the instructor's&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''External Links''' ==&lt;br /&gt;
* Forked Repository: https://github.com/kushalnawalakha/expertiza&lt;br /&gt;
* Deployment: http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''Team Members''' ==&lt;br /&gt;
*Ashis Sahoo&lt;br /&gt;
*Satvik Shetty&lt;br /&gt;
*Xiaohui Ellis&lt;br /&gt;
*Kushal Nawalakha&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''References''' ==&lt;br /&gt;
&lt;br /&gt;
Expertiza&lt;br /&gt;
* https://expertiza.ncsu.edu/ &lt;br /&gt;
&lt;br /&gt;
Expertiza Github&lt;br /&gt;
* https://github.com/expertiza/expertiza&lt;br /&gt;
&lt;br /&gt;
Expertiza Documentation&lt;br /&gt;
* http://wiki.expertiza.ncsu.edu/index.php/Expertiza_documentation&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1824:_Let_course_staff_as_well_as_students_do_reviews&amp;diff=117255</id>
		<title>CSC/ECE 517 Spring 2018- Project E1824: Let course staff as well as students do reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1824:_Let_course_staff_as_well_as_students_do_reviews&amp;diff=117255"/>
		<updated>2018-04-29T05:03:26Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Problem Statement */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction''' ==&lt;br /&gt;
&lt;br /&gt;
The way Expertiza is set up right now is that only peers can review your work. However, there are cases when the instructor would want to submit reviews as well. This project aims to implement this feature by allowing instructors to review the project on the same metrics as other students who review the project. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''Problem Statement''' ==&lt;br /&gt;
&lt;br /&gt;
Peer review is a great way for students to learn about how well they have developed their application. However there are some problems with this:&lt;br /&gt;
* Sometimes, the peer reviews may not be thorough and the team/person's work reviewed might not reflect the actual status of the development.&lt;br /&gt;
* The reviewer might not know how well they are reviewing the peer's work. They might not entirely know as to what tone to use or what suggestions to put forward.&lt;br /&gt;
&lt;br /&gt;
By letting course staff perform reviews as well, the reviewer and the reviewee are both benefited, which can improve the overall learning experience.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Current scenario ===&lt;br /&gt;
&lt;br /&gt;
This is how some of the pages we are concerned with, currently look.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Submissions page for an assignment in Instructor View ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File: Submissions_instr.jpeg | center]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== A typical Scores table in a Student View ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File: Grades_view_team_current.png | center]]&lt;br /&gt;
&lt;br /&gt;
== '''Proposed Solutions''' ==&lt;br /&gt;
&lt;br /&gt;
We propose to perform the following changes to let staff perform reviews as well:&lt;br /&gt;
&lt;br /&gt;
'''Step 1: Add a ''Perform review'' link in the assignment submissions page view for the instructors.'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Files to be edited:&lt;br /&gt;
* '''View: ''' ''app/views/assignments/list_submissions.html.erb''&lt;br /&gt;
* '''Controller: ''' ''app/controllers/response_controller.rb''  - Add authorization for instructors to perform review&lt;br /&gt;
&lt;br /&gt;
[[File:Instructor review view.PNG | center]]&lt;br /&gt;
&lt;br /&gt;
In the second case, we can see a 'Perform Review' link. This is the initial state when instructor review has not been added to the submission.&lt;br /&gt;
Once the instructor adds a review, we can see the 'View Review' and 'Edit Review' links, as seen in the first case.&lt;br /&gt;
If the review deadline of one round is passed, the 'Edit Review' link becomes 'Update Review' link. The course staff will be allowed to perform a review even if the deadline for reviewing has passed.&lt;br /&gt;
&lt;br /&gt;
In the second case, an intermediate submission deadline has passed and hence there is a link only for performing a review.&lt;br /&gt;
&lt;br /&gt;
In the third case, if no submission deadline has passed, there won't be a link for Performing a review nor assigning a grade. [No, it should be dependent on whether reviewing is allowed during the current assignment phase.]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Step 2: Add instructor review in ''Your Scores'' table in case he has reviewed your work. Provide a highlight/way to make it look distinct.'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Files to be edited:&lt;br /&gt;
* '''View: ''' ''app/views/grades/view_team.html.erb''&lt;br /&gt;
* '''Controller: ''' ''app/controllers/grades_controller.rb'' - Method: view_team&lt;br /&gt;
&lt;br /&gt;
[[File: Grades_view_team_instr.png | center]]&lt;br /&gt;
&lt;br /&gt;
A student should be able to make out if an instructor has reviewed his/his team's work. In case the instructor performs a review on the team's work, it will highlight the intructor's review.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Step 3: If instructor has reviewed the same work as you have reviewed, provide a way to show his review as well in ''Others work'''''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Files to be edited:&lt;br /&gt;
* '''View: ''' ''app/views/student_review/list.html.erb''&lt;br /&gt;
* '''Controller: ''' ''app/controllers/student_review_controller.rb'' - Method: view_team&lt;br /&gt;
&lt;br /&gt;
[[File: Others_work_proposed.jpeg | center]]&lt;br /&gt;
&lt;br /&gt;
If the instructor has reviewed the work of a team you have reviewed, there will be a link to view how the instructor has reviewed the same work. In case the instructor has not reviewed the work (like in case of review 4), there won't be any ''Instructor's Review'' link&lt;br /&gt;
&lt;br /&gt;
== '''Test Plan''' ==&lt;br /&gt;
&lt;br /&gt;
Many of our changes would be reflected on views (user interface). Following is the list of tests that should be conducted with rspec/capybara:&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;should see the Perform Review link (beside Assign Grade link) for each submission after a list of submissions are pulled up by an instructor if the final due date for the assignment has passed&amp;quot;&lt;br /&gt;
# it &amp;quot;should see the Perform Review link only for each submission after a list of submissions are pulled up by an instructor if the final due date for the assignment has not passed and review period has started and review deadline has not passed&amp;quot;&lt;br /&gt;
# it &amp;quot;should see neither Perform Review link nor Assign Grade link after a list of submissions are pulled up by an instructor if the final due date for the assignment has not passed and review period has not started&amp;quot;&lt;br /&gt;
# it &amp;quot;should pull up a review page for the submission of the team after the Perform Review link is clicked on by an instructor&amp;quot;&lt;br /&gt;
# it &amp;quot;should show highlighted reviews done by instructors when a student views feedback on his/her submission&amp;quot;&lt;br /&gt;
# it &amp;quot;should pull up a calibration report when a student wants to see the difference between his/her reviews on other's submission and the instructor's&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''External Links''' ==&lt;br /&gt;
* Forked Repository: https://github.com/kushalnawalakha/expertiza&lt;br /&gt;
* Deployment: http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''Team Members''' ==&lt;br /&gt;
*Ashis Sahoo&lt;br /&gt;
*Satvik Shetty&lt;br /&gt;
*Xiaohui Ellis&lt;br /&gt;
*Kushal Nawalakha&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''References''' ==&lt;br /&gt;
&lt;br /&gt;
Expertiza&lt;br /&gt;
* https://expertiza.ncsu.edu/ &lt;br /&gt;
&lt;br /&gt;
Expertiza Github&lt;br /&gt;
* https://github.com/expertiza/expertiza&lt;br /&gt;
&lt;br /&gt;
Expertiza Documentation&lt;br /&gt;
* http://wiki.expertiza.ncsu.edu/index.php/Expertiza_documentation&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1824:_Let_course_staff_as_well_as_students_do_reviews&amp;diff=117249</id>
		<title>CSC/ECE 517 Spring 2018- Project E1824: Let course staff as well as students do reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1824:_Let_course_staff_as_well_as_students_do_reviews&amp;diff=117249"/>
		<updated>2018-04-29T04:55:25Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Proposed Solutions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction''' ==&lt;br /&gt;
&lt;br /&gt;
The way Expertiza is set up right now is that only peers can review your work. However, there are cases when the instructor would want to submit reviews as well. This project aims to implement this feature by allowing instructors to review the project on the same metrics as other students who review the project. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''Problem Statement''' ==&lt;br /&gt;
&lt;br /&gt;
Peer review is a great way for students to learn about how well they have developed their application. However there are some problems with this:&lt;br /&gt;
* Sometimes, the peer reviews may not be thorough and the team/person's work reviewed might not reflect the actual status of the development.&lt;br /&gt;
* The reviewer might not know how well they are reviewing the peer's work. They might not entirely know as to what tone to use or what suggestions to put forward.&lt;br /&gt;
&lt;br /&gt;
By letting course staff perform reviews as well, the reviewer and the reviewee are both benefited, which can improve the overall learning experience.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Current scenario ===&lt;br /&gt;
&lt;br /&gt;
This is how some of the pages we are concerned with, currently look.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Submissions page for an assignment in Instructor View ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File: Submissions_instr.jpeg | center]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== A typical Scores table in a Student View ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File: Grades_view_team_current.png | center]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== Others work reviewed in a Student View ====&lt;br /&gt;
&lt;br /&gt;
[[File: Others_work_current.jpeg | center]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''Proposed Solutions''' ==&lt;br /&gt;
&lt;br /&gt;
We propose to perform the following changes to let staff perform reviews as well:&lt;br /&gt;
&lt;br /&gt;
'''Step 1: Add a ''Perform review'' link in the assignment submissions page view for the instructors.'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Files to be edited:&lt;br /&gt;
* '''View: ''' ''app/views/assignments/list_submissions.html.erb''&lt;br /&gt;
* '''Controller: ''' ''app/controllers/response_controller.rb''  - Add authorization for instructors to perform review&lt;br /&gt;
&lt;br /&gt;
[[File:Instructor review view.PNG | center]]&lt;br /&gt;
&lt;br /&gt;
In the second case, we can see a 'Perform Review' link. This is the initial state when instructor review has not been added to the submission.&lt;br /&gt;
Once the instructor adds a review, we can see the 'View Review' and 'Edit Review' links, as seen in the first case.&lt;br /&gt;
If the review deadline of one round is passed, the 'Edit Review' link becomes 'Update Review' link. The course staff will be allowed to perform a review even if the deadline for reviewing has passed.&lt;br /&gt;
&lt;br /&gt;
In the second case, an intermediate submission deadline has passed and hence there is a link only for performing a review.&lt;br /&gt;
&lt;br /&gt;
In the third case, if no submission deadline has passed, there won't be a link for Performing a review nor assigning a grade. [No, it should be dependent on whether reviewing is allowed during the current assignment phase.]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Step 2: Add instructor review in ''Your Scores'' table in case he has reviewed your work. Provide a highlight/way to make it look distinct.'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Files to be edited:&lt;br /&gt;
* '''View: ''' ''app/views/grades/view_team.html.erb''&lt;br /&gt;
* '''Controller: ''' ''app/controllers/grades_controller.rb'' - Method: view_team&lt;br /&gt;
&lt;br /&gt;
[[File: Grades_view_team_instr.png | center]]&lt;br /&gt;
&lt;br /&gt;
A student should be able to make out if an instructor has reviewed his/his team's work. In case the instructor performs a review on the team's work, it will highlight the intructor's review.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Step 3: If instructor has reviewed the same work as you have reviewed, provide a way to show his review as well in ''Others work'''''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Files to be edited:&lt;br /&gt;
* '''View: ''' ''app/views/student_review/list.html.erb''&lt;br /&gt;
* '''Controller: ''' ''app/controllers/student_review_controller.rb'' - Method: view_team&lt;br /&gt;
&lt;br /&gt;
[[File: Others_work_proposed.jpeg | center]]&lt;br /&gt;
&lt;br /&gt;
If the instructor has reviewed the work of a team you have reviewed, there will be a link to view how the instructor has reviewed the same work. In case the instructor has not reviewed the work (like in case of review 4), there won't be any ''Instructor's Review'' link&lt;br /&gt;
&lt;br /&gt;
== '''Test Plan''' ==&lt;br /&gt;
&lt;br /&gt;
Many of our changes would be reflected on views (user interface). Following is the list of tests that should be conducted with rspec/capybara:&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;should see the Perform Review link (beside Assign Grade link) for each submission after a list of submissions are pulled up by an instructor if the final due date for the assignment has passed&amp;quot;&lt;br /&gt;
# it &amp;quot;should see the Perform Review link only for each submission after a list of submissions are pulled up by an instructor if the final due date for the assignment has not passed and review period has started and review deadline has not passed&amp;quot;&lt;br /&gt;
# it &amp;quot;should see neither Perform Review link nor Assign Grade link after a list of submissions are pulled up by an instructor if the final due date for the assignment has not passed and review period has not started&amp;quot;&lt;br /&gt;
# it &amp;quot;should pull up a review page for the submission of the team after the Perform Review link is clicked on by an instructor&amp;quot;&lt;br /&gt;
# it &amp;quot;should show highlighted reviews done by instructors when a student views feedback on his/her submission&amp;quot;&lt;br /&gt;
# it &amp;quot;should pull up a calibration report when a student wants to see the difference between his/her reviews on other's submission and the instructor's&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''External Links''' ==&lt;br /&gt;
* Forked Repository: https://github.com/kushalnawalakha/expertiza&lt;br /&gt;
* Deployment: http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''Team Members''' ==&lt;br /&gt;
*Ashis Sahoo&lt;br /&gt;
*Satvik Shetty&lt;br /&gt;
*Xiaohui Ellis&lt;br /&gt;
*Kushal Nawalakha&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== '''References''' ==&lt;br /&gt;
&lt;br /&gt;
Expertiza&lt;br /&gt;
* https://expertiza.ncsu.edu/ &lt;br /&gt;
&lt;br /&gt;
Expertiza Github&lt;br /&gt;
* https://github.com/expertiza/expertiza&lt;br /&gt;
&lt;br /&gt;
Expertiza Documentation&lt;br /&gt;
* http://wiki.expertiza.ncsu.edu/index.php/Expertiza_documentation&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Instructor_review_view.PNG&amp;diff=117236</id>
		<title>File:Instructor review view.PNG</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Instructor_review_view.PNG&amp;diff=117236"/>
		<updated>2018-04-29T04:42:00Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=116711</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=116711"/>
		<updated>2018-04-17T17:04:12Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* External Links */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment made available by other students:&lt;br /&gt;
## In the same assignment, available after deadline.&lt;br /&gt;
## In an old assignment, selected by the instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are completed.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
def create_assignment_team(assignment_name, parent_id)&lt;br /&gt;
  assignment_team = AssignmentTeam.new&lt;br /&gt;
  assignment_team.name = assignment_name&lt;br /&gt;
  assignment_team.parent_id = parent_id&lt;br /&gt;
  assignment_team.save!&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def init_test&lt;br /&gt;
  # create assignment and topic&lt;br /&gt;
  assignment = build(Assignment)&lt;br /&gt;
  course = Course.new&lt;br /&gt;
  course.name = &amp;quot;SampleSubmissionTestCourse&amp;quot;&lt;br /&gt;
  course.save&lt;br /&gt;
  assignment.course_id = course.id&lt;br /&gt;
  assignment.save&lt;br /&gt;
&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_1&amp;quot;, assignment.id)&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_2&amp;quot;, assignment.id)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def visit_sample_submissions_page&lt;br /&gt;
  visit '/student_task/list'&lt;br /&gt;
  click_on &amp;quot;Example Assignment&amp;quot;&lt;br /&gt;
  click_on &amp;quot;Sample Submissions&amp;quot;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
describe &amp;quot;sample submission test&amp;quot; do&lt;br /&gt;
  before(:each) { init_test }&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;is able to make an assignment public&amp;quot; do&lt;br /&gt;
    visit '/student_task/list'&lt;br /&gt;
    find(:css, &amp;quot;#makeSubPublic[teamid='6050']&amp;quot;).trigger(&amp;quot;click&amp;quot;)&lt;br /&gt;
    click_button 'OK'&lt;br /&gt;
    expect(page).to have_http_status(200)&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot; do # Set deadline after current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see current assignment submissions if deadline is met&amp;quot; do # Set deadline before current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot; do&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot; do # Instructor makes submission available.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sample Submissions View ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Test Plan ==&lt;br /&gt;
&lt;br /&gt;
Many of our changes are reflected on views (user interface). So we build tests with rspec/capybara. Following is the list of tests that conduct:&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;is able to make an assignment public&amp;quot;&lt;br /&gt;
# it &amp;quot;is able to view sample submissions page&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot;&lt;br /&gt;
# it &amp;quot;should see current assignment submissions if deadline is met&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot;&lt;br /&gt;
# it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
def create_assignment_team(assignment_name, parent_id)&lt;br /&gt;
  assignment_team = AssignmentTeam.new&lt;br /&gt;
  assignment_team.name = assignment_name&lt;br /&gt;
  assignment_team.parent_id = parent_id&lt;br /&gt;
  assignment_team.save!&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def init_test&lt;br /&gt;
  # create assignment and topic&lt;br /&gt;
  assignment = build(Assignment)&lt;br /&gt;
  course = Course.new&lt;br /&gt;
  course.name = &amp;quot;SampleSubmissionTestCourse&amp;quot;&lt;br /&gt;
  course.save&lt;br /&gt;
  assignment.course_id = course.id&lt;br /&gt;
  assignment.save&lt;br /&gt;
&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_1&amp;quot;, assignment.id)&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_2&amp;quot;, assignment.id)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def visit_sample_submissions_page&lt;br /&gt;
  visit '/student_task/list'&lt;br /&gt;
  click_on &amp;quot;Example Assignment&amp;quot;&lt;br /&gt;
  click_on &amp;quot;Sample Submissions&amp;quot;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
describe &amp;quot;sample submission test&amp;quot; do&lt;br /&gt;
  before(:each) { init_test }&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;is able to make an assignment public&amp;quot; do&lt;br /&gt;
    visit '/student_task/list'&lt;br /&gt;
    find(:css, &amp;quot;#makeSubPublic[teamid='6050']&amp;quot;).trigger(&amp;quot;click&amp;quot;)&lt;br /&gt;
    click_button 'OK'&lt;br /&gt;
    expect(page).to have_http_status(200)&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot; do # Set deadline after current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see current assignment submissions if deadline is met&amp;quot; do # Set deadline before current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot; do&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot; do # Instructor makes submission available.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Future Scope ==&lt;br /&gt;
# Publishing sample reviews made by students: This feature will require students to allow their review to be published as a sample review. This can then be made available to future students.&lt;br /&gt;
&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
# link to the git pull request [https://github.com/expertiza/expertiza/pull/1169]&lt;br /&gt;
# link to the deployed application [http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
# Link to expertiza website: [https://expertiza.ncsu.edu/]&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=116011</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=116011"/>
		<updated>2018-04-04T21:26:42Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Current status of Development */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment made available by other students:&lt;br /&gt;
## In the same assignment, available after deadline.&lt;br /&gt;
## In an old assignment, selected by the instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are completed.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
def create_assignment_team(assignment_name, parent_id)&lt;br /&gt;
  assignment_team = AssignmentTeam.new&lt;br /&gt;
  assignment_team.name = assignment_name&lt;br /&gt;
  assignment_team.parent_id = parent_id&lt;br /&gt;
  assignment_team.save!&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def init_test&lt;br /&gt;
  # create assignment and topic&lt;br /&gt;
  assignment = build(Assignment)&lt;br /&gt;
  course = Course.new&lt;br /&gt;
  course.name = &amp;quot;SampleSubmissionTestCourse&amp;quot;&lt;br /&gt;
  course.save&lt;br /&gt;
  assignment.course_id = course.id&lt;br /&gt;
  assignment.save&lt;br /&gt;
&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_1&amp;quot;, assignment.id)&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_2&amp;quot;, assignment.id)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def visit_sample_submissions_page&lt;br /&gt;
  visit '/student_task/list'&lt;br /&gt;
  click_on &amp;quot;Example Assignment&amp;quot;&lt;br /&gt;
  click_on &amp;quot;Sample Submissions&amp;quot;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
describe &amp;quot;sample submission test&amp;quot; do&lt;br /&gt;
  before(:each) { init_test }&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;is able to make an assignment public&amp;quot; do&lt;br /&gt;
    visit '/student_task/list'&lt;br /&gt;
    find(:css, &amp;quot;#makeSubPublic[teamid='6050']&amp;quot;).trigger(&amp;quot;click&amp;quot;)&lt;br /&gt;
    click_button 'OK'&lt;br /&gt;
    expect(page).to have_http_status(200)&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot; do # Set deadline after current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see current assignment submissions if deadline is met&amp;quot; do # Set deadline before current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot; do&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot; do # Instructor makes submission available.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sample Submissions View ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Test Plan ==&lt;br /&gt;
&lt;br /&gt;
Many of our changes are reflected on views (user interface). So we build tests with rspec/capybara. Following is the list of tests that conduct:&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;is able to make an assignment public&amp;quot;&lt;br /&gt;
# it &amp;quot;is able to view sample submissions page&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot;&lt;br /&gt;
# it &amp;quot;should see current assignment submissions if deadline is met&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot;&lt;br /&gt;
# it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
def create_assignment_team(assignment_name, parent_id)&lt;br /&gt;
  assignment_team = AssignmentTeam.new&lt;br /&gt;
  assignment_team.name = assignment_name&lt;br /&gt;
  assignment_team.parent_id = parent_id&lt;br /&gt;
  assignment_team.save!&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def init_test&lt;br /&gt;
  # create assignment and topic&lt;br /&gt;
  assignment = build(Assignment)&lt;br /&gt;
  course = Course.new&lt;br /&gt;
  course.name = &amp;quot;SampleSubmissionTestCourse&amp;quot;&lt;br /&gt;
  course.save&lt;br /&gt;
  assignment.course_id = course.id&lt;br /&gt;
  assignment.save&lt;br /&gt;
&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_1&amp;quot;, assignment.id)&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_2&amp;quot;, assignment.id)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def visit_sample_submissions_page&lt;br /&gt;
  visit '/student_task/list'&lt;br /&gt;
  click_on &amp;quot;Example Assignment&amp;quot;&lt;br /&gt;
  click_on &amp;quot;Sample Submissions&amp;quot;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
describe &amp;quot;sample submission test&amp;quot; do&lt;br /&gt;
  before(:each) { init_test }&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;is able to make an assignment public&amp;quot; do&lt;br /&gt;
    visit '/student_task/list'&lt;br /&gt;
    find(:css, &amp;quot;#makeSubPublic[teamid='6050']&amp;quot;).trigger(&amp;quot;click&amp;quot;)&lt;br /&gt;
    click_button 'OK'&lt;br /&gt;
    expect(page).to have_http_status(200)&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot; do # Set deadline after current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see current assignment submissions if deadline is met&amp;quot; do # Set deadline before current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot; do&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot; do # Instructor makes submission available.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Future Scope ==&lt;br /&gt;
# Publishing sample reviews made by students: This feature will require students to allow their review to be published as a sample review. This can then be made available to future students.&lt;br /&gt;
&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
# link to the git pull request [https://github.com/expertiza/expertiza/pull/1164]&lt;br /&gt;
# link to the deployed application [http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
# Link to expertiza website: [https://expertiza.ncsu.edu/]&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=116010</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=116010"/>
		<updated>2018-04-04T04:21:19Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment made available by other students:&lt;br /&gt;
## In the same assignment, available after deadline.&lt;br /&gt;
## In an old assignment, selected by the instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
def create_assignment_team(assignment_name, parent_id)&lt;br /&gt;
  assignment_team = AssignmentTeam.new&lt;br /&gt;
  assignment_team.name = assignment_name&lt;br /&gt;
  assignment_team.parent_id = parent_id&lt;br /&gt;
  assignment_team.save!&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def init_test&lt;br /&gt;
  # create assignment and topic&lt;br /&gt;
  assignment = build(Assignment)&lt;br /&gt;
  course = Course.new&lt;br /&gt;
  course.name = &amp;quot;SampleSubmissionTestCourse&amp;quot;&lt;br /&gt;
  course.save&lt;br /&gt;
  assignment.course_id = course.id&lt;br /&gt;
  assignment.save&lt;br /&gt;
&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_1&amp;quot;, assignment.id)&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_2&amp;quot;, assignment.id)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def visit_sample_submissions_page&lt;br /&gt;
  visit '/student_task/list'&lt;br /&gt;
  click_on &amp;quot;Example Assignment&amp;quot;&lt;br /&gt;
  click_on &amp;quot;Sample Submissions&amp;quot;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
describe &amp;quot;sample submission test&amp;quot; do&lt;br /&gt;
  before(:each) { init_test }&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;is able to make an assignment public&amp;quot; do&lt;br /&gt;
    visit '/student_task/list'&lt;br /&gt;
    find(:css, &amp;quot;#makeSubPublic[teamid='6050']&amp;quot;).trigger(&amp;quot;click&amp;quot;)&lt;br /&gt;
    click_button 'OK'&lt;br /&gt;
    expect(page).to have_http_status(200)&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot; do # Set deadline after current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see current assignment submissions if deadline is met&amp;quot; do # Set deadline before current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot; do&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot; do # Instructor makes submission available.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sample Submissions View ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Test Plan ==&lt;br /&gt;
&lt;br /&gt;
Many of our changes are reflected on views (user interface). So we build tests with rspec/capybara. Following is the list of tests that conduct:&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;is able to make an assignment public&amp;quot;&lt;br /&gt;
# it &amp;quot;is able to view sample submissions page&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot;&lt;br /&gt;
# it &amp;quot;should see current assignment submissions if deadline is met&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot;&lt;br /&gt;
# it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
def create_assignment_team(assignment_name, parent_id)&lt;br /&gt;
  assignment_team = AssignmentTeam.new&lt;br /&gt;
  assignment_team.name = assignment_name&lt;br /&gt;
  assignment_team.parent_id = parent_id&lt;br /&gt;
  assignment_team.save!&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def init_test&lt;br /&gt;
  # create assignment and topic&lt;br /&gt;
  assignment = build(Assignment)&lt;br /&gt;
  course = Course.new&lt;br /&gt;
  course.name = &amp;quot;SampleSubmissionTestCourse&amp;quot;&lt;br /&gt;
  course.save&lt;br /&gt;
  assignment.course_id = course.id&lt;br /&gt;
  assignment.save&lt;br /&gt;
&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_1&amp;quot;, assignment.id)&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_2&amp;quot;, assignment.id)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def visit_sample_submissions_page&lt;br /&gt;
  visit '/student_task/list'&lt;br /&gt;
  click_on &amp;quot;Example Assignment&amp;quot;&lt;br /&gt;
  click_on &amp;quot;Sample Submissions&amp;quot;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
describe &amp;quot;sample submission test&amp;quot; do&lt;br /&gt;
  before(:each) { init_test }&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;is able to make an assignment public&amp;quot; do&lt;br /&gt;
    visit '/student_task/list'&lt;br /&gt;
    find(:css, &amp;quot;#makeSubPublic[teamid='6050']&amp;quot;).trigger(&amp;quot;click&amp;quot;)&lt;br /&gt;
    click_button 'OK'&lt;br /&gt;
    expect(page).to have_http_status(200)&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot; do # Set deadline after current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see current assignment submissions if deadline is met&amp;quot; do # Set deadline before current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot; do&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot; do # Instructor makes submission available.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Future Scope ==&lt;br /&gt;
# Publishing sample reviews made by students: This feature will require students to allow their review to be published as a sample review. This can then be made available to future students.&lt;br /&gt;
&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
# link to the git pull request [https://github.com/expertiza/expertiza/pull/1164]&lt;br /&gt;
# link to the deployed application [http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
# Link to expertiza website: [https://expertiza.ncsu.edu/]&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=116002</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=116002"/>
		<updated>2018-04-03T22:36:24Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Developed Code */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment made available by other students:&lt;br /&gt;
## In the same assignment, available after deadline.&lt;br /&gt;
## In an old assignment, selected by the instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
def create_assignment_team(assignment_name, parent_id)&lt;br /&gt;
  assignment_team = AssignmentTeam.new&lt;br /&gt;
  assignment_team.name = assignment_name&lt;br /&gt;
  assignment_team.parent_id = parent_id&lt;br /&gt;
  assignment_team.save!&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def init_test&lt;br /&gt;
  # create assignment and topic&lt;br /&gt;
  assignment = build(Assignment)&lt;br /&gt;
  course = Course.new&lt;br /&gt;
  course.name = &amp;quot;SampleSubmissionTestCourse&amp;quot;&lt;br /&gt;
  course.save&lt;br /&gt;
  assignment.course_id = course.id&lt;br /&gt;
  assignment.save&lt;br /&gt;
&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_1&amp;quot;, assignment.id)&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_2&amp;quot;, assignment.id)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def visit_sample_submissions_page&lt;br /&gt;
  visit '/student_task/list'&lt;br /&gt;
  click_on &amp;quot;Example Assignment&amp;quot;&lt;br /&gt;
  click_on &amp;quot;Sample Submissions&amp;quot;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
describe &amp;quot;sample submission test&amp;quot; do&lt;br /&gt;
  before(:each) { init_test }&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;is able to make an assignment public&amp;quot; do&lt;br /&gt;
    visit '/student_task/list'&lt;br /&gt;
    find(:css, &amp;quot;#makeSubPublic[teamid='6050']&amp;quot;).trigger(&amp;quot;click&amp;quot;)&lt;br /&gt;
    click_button 'OK'&lt;br /&gt;
    expect(page).to have_http_status(200)&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot; do # Set deadline after current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see current assignment submissions if deadline is met&amp;quot; do # Set deadline before current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot; do&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot; do # Instructor makes submission available.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sample Submissions View ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Test Plan ==&lt;br /&gt;
&lt;br /&gt;
Many of our changes are reflected on views (user interface). So we build tests with rspec/capybara. Following is the list of tests that conduct:&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;is able to make an assignment public&amp;quot;&lt;br /&gt;
# it &amp;quot;is able to view sample submissions page&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot;&lt;br /&gt;
# it &amp;quot;should see current assignment submissions if deadline is met&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot;&lt;br /&gt;
# it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
def create_assignment_team(assignment_name, parent_id)&lt;br /&gt;
  assignment_team = AssignmentTeam.new&lt;br /&gt;
  assignment_team.name = assignment_name&lt;br /&gt;
  assignment_team.parent_id = parent_id&lt;br /&gt;
  assignment_team.save!&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def init_test&lt;br /&gt;
  # create assignment and topic&lt;br /&gt;
  assignment = build(Assignment)&lt;br /&gt;
  course = Course.new&lt;br /&gt;
  course.name = &amp;quot;SampleSubmissionTestCourse&amp;quot;&lt;br /&gt;
  course.save&lt;br /&gt;
  assignment.course_id = course.id&lt;br /&gt;
  assignment.save&lt;br /&gt;
&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_1&amp;quot;, assignment.id)&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_2&amp;quot;, assignment.id)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def visit_sample_submissions_page&lt;br /&gt;
  visit '/student_task/list'&lt;br /&gt;
  click_on &amp;quot;Example Assignment&amp;quot;&lt;br /&gt;
  click_on &amp;quot;Sample Submissions&amp;quot;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
describe &amp;quot;sample submission test&amp;quot; do&lt;br /&gt;
  before(:each) { init_test }&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;is able to make an assignment public&amp;quot; do&lt;br /&gt;
    visit '/student_task/list'&lt;br /&gt;
    find(:css, &amp;quot;#makeSubPublic[teamid='6050']&amp;quot;).trigger(&amp;quot;click&amp;quot;)&lt;br /&gt;
    click_button 'OK'&lt;br /&gt;
    expect(page).to have_http_status(200)&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot; do # Set deadline after current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see current assignment submissions if deadline is met&amp;quot; do # Set deadline before current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot; do&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot; do # Instructor makes submission available.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
# link to the git pull request [https://github.com/expertiza/expertiza/pull/1164]&lt;br /&gt;
# link to the deployed application [http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
# Link to expertiza website: [https://expertiza.ncsu.edu/]&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115995</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115995"/>
		<updated>2018-04-03T13:20:04Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Test Plan */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment made available by other students:&lt;br /&gt;
## In the same assignment, available after deadline.&lt;br /&gt;
## In an old assignment, selected by the instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sample Submissions View ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Test Plan ==&lt;br /&gt;
&lt;br /&gt;
Many of our changes are reflected on views (user interface). So we build tests with rspec/capybara. Following is the list of tests that conduct:&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;is able to make an assignment public&amp;quot;&lt;br /&gt;
# it &amp;quot;is able to view sample submissions page&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot;&lt;br /&gt;
# it &amp;quot;should see current assignment submissions if deadline is met&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot;&lt;br /&gt;
# it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
def create_assignment_team(assignment_name, parent_id)&lt;br /&gt;
  assignment_team = AssignmentTeam.new&lt;br /&gt;
  assignment_team.name = assignment_name&lt;br /&gt;
  assignment_team.parent_id = parent_id&lt;br /&gt;
  assignment_team.save!&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def init_test&lt;br /&gt;
  # create assignment and topic&lt;br /&gt;
  assignment = build(Assignment)&lt;br /&gt;
  course = Course.new&lt;br /&gt;
  course.name = &amp;quot;SampleSubmissionTestCourse&amp;quot;&lt;br /&gt;
  course.save&lt;br /&gt;
  assignment.course_id = course.id&lt;br /&gt;
  assignment.save&lt;br /&gt;
&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_1&amp;quot;, assignment.id)&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_2&amp;quot;, assignment.id)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def visit_sample_submissions_page&lt;br /&gt;
  visit '/student_task/list'&lt;br /&gt;
  click_on &amp;quot;Example Assignment&amp;quot;&lt;br /&gt;
  click_on &amp;quot;Sample Submissions&amp;quot;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
describe &amp;quot;sample submission test&amp;quot; do&lt;br /&gt;
  before(:each) { init_test }&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;is able to make an assignment public&amp;quot; do&lt;br /&gt;
    visit '/student_task/list'&lt;br /&gt;
    find(:css, &amp;quot;#makeSubPublic[teamid='6050']&amp;quot;).trigger(&amp;quot;click&amp;quot;)&lt;br /&gt;
    click_button 'OK'&lt;br /&gt;
    expect(page).to have_http_status(200)&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot; do # Set deadline after current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see current assignment submissions if deadline is met&amp;quot; do # Set deadline before current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot; do&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot; do # Instructor makes submission available.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
# link to the git pull request [https://github.com/expertiza/expertiza/pull/1164]&lt;br /&gt;
# link to the deployed application [http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
# Link to expertiza website: [https://expertiza.ncsu.edu/]&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115994</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115994"/>
		<updated>2018-04-03T13:18:07Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Test Plan */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment made available by other students:&lt;br /&gt;
## In the same assignment, available after deadline.&lt;br /&gt;
## In an old assignment, selected by the instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sample Submissions View ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Test Plan ==&lt;br /&gt;
&lt;br /&gt;
Many of our changes are reflected on views (user interface). So we build tests with capybara. Following is the list of tests that conduct:&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;is able to make an assignment public&amp;quot;&lt;br /&gt;
# it &amp;quot;is able to view sample submissions page&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot;&lt;br /&gt;
# it &amp;quot;should see current assignment submissions if deadline is met&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot;&lt;br /&gt;
# it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
def create_assignment_team(assignment_name, parent_id)&lt;br /&gt;
  assignment_team = AssignmentTeam.new&lt;br /&gt;
  assignment_team.name = assignment_name&lt;br /&gt;
  assignment_team.parent_id = parent_id&lt;br /&gt;
  assignment_team.save!&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def init_test&lt;br /&gt;
  # create assignment and topic&lt;br /&gt;
  assignment = build(Assignment)&lt;br /&gt;
  course = Course.new&lt;br /&gt;
  course.name = &amp;quot;SampleSubmissionTestCourse&amp;quot;&lt;br /&gt;
  course.save&lt;br /&gt;
  assignment.course_id = course.id&lt;br /&gt;
  assignment.save&lt;br /&gt;
&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_1&amp;quot;, assignment.id)&lt;br /&gt;
  create_assignemnt_team(&amp;quot;ss_assignment_team_2&amp;quot;, assignment.id)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
def visit_sample_submissions_page&lt;br /&gt;
  visit '/student_task/list'&lt;br /&gt;
  click_on &amp;quot;Example Assignment&amp;quot;&lt;br /&gt;
  click_on &amp;quot;Sample Submissions&amp;quot;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
describe &amp;quot;sample submission test&amp;quot; do&lt;br /&gt;
  before(:each) { init_test }&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;is able to make an assignment public&amp;quot; do&lt;br /&gt;
    visit '/student_task/list'&lt;br /&gt;
    find(:css, &amp;quot;#makeSubPublic[teamid='6050']&amp;quot;).trigger(&amp;quot;click&amp;quot;)&lt;br /&gt;
    click_button 'OK'&lt;br /&gt;
    expect(page).to have_http_status(200)&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot; do # Set deadline after current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see current assignment submissions if deadline is met&amp;quot; do # Set deadline before current time.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from current assignment made public yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot; do&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot; do # Instructor makes submission available.&lt;br /&gt;
    visit_sample_submissions_page&lt;br /&gt;
    expect(page).to_not have_content &amp;quot;No sample submissions from previous assignment made available yet&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
# link to the git pull request [https://github.com/expertiza/expertiza/pull/1164]&lt;br /&gt;
# link to the deployed application [http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
# Link to expertiza website: [https://expertiza.ncsu.edu/]&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115918</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115918"/>
		<updated>2018-04-03T03:45:34Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* References */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment made available by other students:&lt;br /&gt;
## In the same assignment, available after deadline.&lt;br /&gt;
## In an old assignment, selected by the instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sample Submissions View ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Test Plan ==&lt;br /&gt;
&lt;br /&gt;
Many of our changes are reflected on views (user interface). So we build tests with capybara. Following is the list of tests that conduct:&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;is able to make an assignment public&amp;quot;&lt;br /&gt;
# it &amp;quot;is able to view sample submissions page&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot;&lt;br /&gt;
# it &amp;quot;should see current assignment submissions if deadline is met&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot;&lt;br /&gt;
# it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
# link to the git pull request [https://github.com/expertiza/expertiza/pull/1164]&lt;br /&gt;
# link to the deployed application [http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
# Link to expertiza website: [https://expertiza.ncsu.edu/]&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115916</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115916"/>
		<updated>2018-04-03T03:43:27Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Test Plan */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment made available by other students:&lt;br /&gt;
## In the same assignment, available after deadline.&lt;br /&gt;
## In an old assignment, selected by the instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sample Submissions View ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Test Plan ==&lt;br /&gt;
&lt;br /&gt;
Many of our changes are reflected on views (user interface). So we build tests with capybara. Following is the list of tests that conduct:&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;is able to make an assignment public&amp;quot;&lt;br /&gt;
# it &amp;quot;is able to view sample submissions page&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot;&lt;br /&gt;
# it &amp;quot;should see current assignment submissions if deadline is met&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot;&lt;br /&gt;
# it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
# link to the git pull request [https://github.com/expertiza/expertiza/pull/1164]&lt;br /&gt;
# link to the deployed application [http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115915</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115915"/>
		<updated>2018-04-03T03:42:54Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Test Plan */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment made available by other students:&lt;br /&gt;
## In the same assignment, available after deadline.&lt;br /&gt;
## In an old assignment, selected by the instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sample Submissions View ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Test Plan ==&lt;br /&gt;
&lt;br /&gt;
Many of our changes are reflected on views (user interface). So we build tests with capybara.&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;is able to make an assignment public&amp;quot;&lt;br /&gt;
# it &amp;quot;is able to view sample submissions page&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot;&lt;br /&gt;
# it &amp;quot;should see current assignment submissions if deadline is met&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot;&lt;br /&gt;
# it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
# link to the git pull request [https://github.com/expertiza/expertiza/pull/1164]&lt;br /&gt;
# link to the deployed application [http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115909</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115909"/>
		<updated>2018-04-03T03:39:30Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* External Links */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment made available by other students:&lt;br /&gt;
## In the same assignment, available after deadline.&lt;br /&gt;
## In an old assignment, selected by the instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sample Submissions View ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Test Plan ==&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;is able to make an assignment public&amp;quot;&lt;br /&gt;
# it &amp;quot;is able to view sample submissions page&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot;&lt;br /&gt;
# it &amp;quot;should see current assignment submissions if deadline is met&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot;&lt;br /&gt;
# it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
# link to the git pull request [https://github.com/expertiza/expertiza/pull/1164]&lt;br /&gt;
# link to the deployed application [http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115908</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115908"/>
		<updated>2018-04-03T03:38:56Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Tests */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment made available by other students:&lt;br /&gt;
## In the same assignment, available after deadline.&lt;br /&gt;
## In an old assignment, selected by the instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sample Submissions View ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Test Plan ==&lt;br /&gt;
&lt;br /&gt;
# it &amp;quot;is able to make an assignment public&amp;quot;&lt;br /&gt;
# it &amp;quot;is able to view sample submissions page&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see current assignment submissions if deadline is not met&amp;quot;&lt;br /&gt;
# it &amp;quot;should see current assignment submissions if deadline is met&amp;quot;&lt;br /&gt;
# it &amp;quot;should not see instructor selected submissions if instructor has not selected them&amp;quot;&lt;br /&gt;
# it &amp;quot;should see instructor selected submissions if instructor has selected them&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
# link to the pull request [https://github.com/expertiza/expertiza/pull/1164]&lt;br /&gt;
# link to the deployed application [http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115794</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115794"/>
		<updated>2018-04-03T01:39:55Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Problem Statement */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment made available by other students:&lt;br /&gt;
## In the same assignment, available after deadline.&lt;br /&gt;
## In an old assignment, selected by the instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sample Submissions View ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
# link to the pull request [https://github.com/expertiza/expertiza/pull/1164]&lt;br /&gt;
# link to the deployed application [http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115792</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115792"/>
		<updated>2018-04-03T01:36:26Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* External Links */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sample Submissions View ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
# link to the pull request [https://github.com/expertiza/expertiza/pull/1164]&lt;br /&gt;
# link to the deployed application [http://ec2-13-59-7-94.us-east-2.compute.amazonaws.com:3000]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115788</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115788"/>
		<updated>2018-04-03T01:28:31Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Application Screenshots */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sample Submissions View ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115787</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115787"/>
		<updated>2018-04-03T01:27:40Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Application Screenshots */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Application Screenshots ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115786</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115786"/>
		<updated>2018-04-03T01:27:22Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Application Screenshots */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Application Screenshots ==&lt;br /&gt;
&lt;br /&gt;
1. The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
2. The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
3. The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115784</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115784"/>
		<updated>2018-04-03T01:26:26Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Application Screenshots */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Application Screenshots ==&lt;br /&gt;
&lt;br /&gt;
The first screenshot of the application is taken when the deadline for the current assignment has not crossed and the instructor also has not given any sample assignment for this assignment.&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
The second screenshot of the application is taken when the deadline for the current assignment has not crossed but the instructor has selected a sample assignment for viewing against this assignment.&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
The third screenshot of the application is taken when both the deadline for the current assignment has crossed and the instructor has selected a sample assignment for viewing.&lt;br /&gt;
[[Image:Assignments available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115773</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115773"/>
		<updated>2018-04-03T01:21:04Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Application Screenshots */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Application Screenshots ==&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignments not made public.PNG]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment submission date not passed.PNG]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Assignment available.PNG]]&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Assignments_available.PNG&amp;diff=115772</id>
		<title>File:Assignments available.PNG</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Assignments_available.PNG&amp;diff=115772"/>
		<updated>2018-04-03T01:20:41Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Assignment_submission_date_not_passed.PNG&amp;diff=115770</id>
		<title>File:Assignment submission date not passed.PNG</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Assignment_submission_date_not_passed.PNG&amp;diff=115770"/>
		<updated>2018-04-03T01:19:50Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Assignments_not_made_public.PNG&amp;diff=115769</id>
		<title>File:Assignments not made public.PNG</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Assignments_not_made_public.PNG&amp;diff=115769"/>
		<updated>2018-04-03T01:18:45Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115767</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115767"/>
		<updated>2018-04-03T01:17:49Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Application Screenshots ==&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115765</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115765"/>
		<updated>2018-04-03T01:11:52Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Developed Code */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115764</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115764"/>
		<updated>2018-04-03T01:09:24Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Developed Code */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
   def sample_sub_options&lt;br /&gt;
    assignments = Assignment.all&lt;br /&gt;
    options = []&lt;br /&gt;
    assignments.each do |assignment|&lt;br /&gt;
      course_name = &amp;quot;&amp;quot;&lt;br /&gt;
      if assignment.course_id and assignment.course_id != 0 and !Course.find(assignment.course_id).nil?&lt;br /&gt;
        course_name = Course.find(assignment.course_id).name&lt;br /&gt;
      end&lt;br /&gt;
      options &amp;lt;&amp;lt; [course_name + '- ' + assignment.name, assignment.id]&lt;br /&gt;
    end&lt;br /&gt;
    options.uniq.sort&lt;br /&gt;
    options.unshift(['-----------', nil])&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115760</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115760"/>
		<updated>2018-04-03T01:05:38Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Developed Code */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- Adding sample submissions for students to refer to --&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= label_tag('assignment_form[assignment][sample_assignment_id]', 'Sample Assignment:') %&amp;gt;&lt;br /&gt;
      &amp;lt;img src=&amp;quot;/assets/info.png&amp;quot; title='- Select an assignment that students can refer sample submission from.'&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td style='padding:5px'&amp;gt;&amp;lt;%= select('assignment_form[assignment]', 'sample_assignment_id', sample_sub_options, :selected =&amp;gt; @assignment_form.assignment.sample_assignment_id) %&amp;gt; &lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115754</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115754"/>
		<updated>2018-04-03T01:01:41Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Development so far */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Developed Code ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115753</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115753"/>
		<updated>2018-04-03T01:01:09Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Development so far */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Development so far ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;&lt;br /&gt;
  &amp;lt;%= link_to &amp;quot;Sample Submissions&amp;quot;, controller: 'sample_submissions', :action =&amp;gt; 'index', :id =&amp;gt; @assignment.id %&amp;gt;&lt;br /&gt;
    (View sample work submitted by other participants/teams)&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115749</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115749"/>
		<updated>2018-04-03T00:57:15Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Development so far */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Development so far ==&lt;br /&gt;
1. Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% if !participant.team.nil? %&amp;gt;&lt;br /&gt;
    &amp;lt;td align=center&amp;gt;&lt;br /&gt;
        &amp;lt;input id=&amp;quot;makeSubPublic&amp;quot; teamid=&amp;quot;&amp;lt;%= participant.team.id %&amp;gt;&amp;quot; type=&amp;quot;checkbox&amp;quot; onclick=&amp;quot;publishConfirmation(this)&amp;quot; &amp;lt;% if participant.team.make_public %&amp;gt;checked&amp;lt;% end %&amp;gt;&amp;gt;&lt;br /&gt;
    &amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2. Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class AddSampleAssignmentToAssignments &amp;lt; ActiveRecord::Migration&lt;br /&gt;
  def change&lt;br /&gt;
    add_column :assignments, :sample_assignment_id, :integer, index: true&lt;br /&gt;
    add_foreign_key :assignments, :assignments, column: :sample_assignment_id&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
3. Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# To give permission for making a submission available to others&lt;br /&gt;
  def make_public&lt;br /&gt;
    @team = Team.find(params[:id])&lt;br /&gt;
    @team.make_public = params[:status]&lt;br /&gt;
    @team.save&lt;br /&gt;
    respond_to do |format|&lt;br /&gt;
      format.html { head :no_content }&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
4. Add views for sample submissions&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- View to display sample submissions to the student --&amp;gt;&lt;br /&gt;
&amp;lt;h2&amp;gt;Sample Submissions for &amp;lt;%= @assignment.name%&amp;gt;:&amp;lt;/h2&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions by students of the current course --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by peers:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_due_date==nil or @assignment_due_date&amp;gt;Time.new() %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;Will be available once the assignment submission is completed&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% elsif @assignment_teams==[] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from current assignment made public yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;li&amp;gt;&lt;br /&gt;
                &amp;lt;ul&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                      &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                  &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/ul&amp;gt;&lt;br /&gt;
              &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Displaying sample submissions from a previous assignment chosen by the instructor --&amp;gt;&lt;br /&gt;
&amp;lt;h3&amp;gt;Submissions made public by instructor:&amp;lt;/h3&amp;gt;&lt;br /&gt;
&amp;lt;% if @assignment_teams_professor == [] %&amp;gt;&lt;br /&gt;
    &amp;lt;br&amp;gt;&amp;lt;i&amp;gt;No sample submissions from previous assignments made available yet&amp;lt;/i&amp;gt;&lt;br /&gt;
&amp;lt;% else %&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;% @assignment_teams_professor.each do |assignment_team| %&amp;gt;&lt;br /&gt;
          &amp;lt;% if assignment_team.hyperlinks != [] %&amp;gt;&lt;br /&gt;
              &amp;lt;ul&amp;gt;&lt;br /&gt;
                &amp;lt;li&amp;gt;&lt;br /&gt;
                  &amp;lt;h4&amp;gt;Team name : &amp;lt;%=assignment_team.name%&amp;gt;&amp;lt;/h4&amp;gt;&lt;br /&gt;
                  &amp;lt;% assignment_team.hyperlinks.each do |assignment_link| %&amp;gt;&lt;br /&gt;
                    &amp;lt;li&amp;gt;&amp;lt;a href=&amp;quot;&amp;lt;%=assignment_link%&amp;gt;&amp;quot;&amp;gt;&amp;lt;%=assignment_link%&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
                &amp;lt;%end%&amp;gt;&lt;br /&gt;
                &amp;lt;/li&amp;gt;&lt;br /&gt;
              &amp;lt;/ul&amp;gt;&lt;br /&gt;
          &amp;lt;%end%&amp;gt;&lt;br /&gt;
      &amp;lt;% end%&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;a href=&amp;quot;javascript:window.history.back()&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
5. Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
6. Add drop down in assignments/edit/_general view.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
7. Add controller code for the drop down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
8. Add column sample_assignment_id to table assignment.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
9. Add test scripts for all the functionality.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115737</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115737"/>
		<updated>2018-04-03T00:36:55Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Development so far */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Development so far ==&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115733</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115733"/>
		<updated>2018-04-03T00:29:48Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Project Tasks */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
# Add test scripts for all the functionality.&lt;br /&gt;
&lt;br /&gt;
== Current status of Development ==&lt;br /&gt;
All tasks mentioned in Project tasks are implemented.&lt;br /&gt;
&lt;br /&gt;
== Development so far ==&lt;br /&gt;
We have already added a link to the student_task/view:&lt;br /&gt;
[[File:Sample_link.png]]&lt;br /&gt;
&lt;br /&gt;
We have also added the relevant views and controllers.&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115727</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115727"/>
		<updated>2018-04-03T00:27:20Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Tasks to be completed */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Project Tasks ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column make_public to table teams for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods.&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
# Add drop down in assignments/edit/_general view.&lt;br /&gt;
# Add controller code for the drop down.&lt;br /&gt;
# Add column sample_assignment_id to table assignment.&lt;br /&gt;
&lt;br /&gt;
== Development so far ==&lt;br /&gt;
We have already added a link to the student_task/view:&lt;br /&gt;
[[File:Sample_link.png]]&lt;br /&gt;
&lt;br /&gt;
We have also added the relevant views and controllers.&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115726</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115726"/>
		<updated>2018-04-03T00:22:20Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Proposed Design */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.  &lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Tasks to be completed ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column grant_permission[----] to table [--------------------------] for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&lt;br /&gt;
== Development so far ==&lt;br /&gt;
We have already added a link to the student_task/view:&lt;br /&gt;
[[File:Sample_link.png]]&lt;br /&gt;
&lt;br /&gt;
We have also added the relevant views and controllers.&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115722</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115722"/>
		<updated>2018-04-03T00:21:01Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Proposed Design */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.&lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[Image:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Tasks to be completed ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column grant_permission[----] to table [--------------------------] for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&lt;br /&gt;
== Development so far ==&lt;br /&gt;
We have already added a link to the student_task/view:&lt;br /&gt;
[[File:Sample_link.png]]&lt;br /&gt;
&lt;br /&gt;
We have also added the relevant views and controllers.&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Application_Flow_Instructor.png&amp;diff=115721</id>
		<title>File:Application Flow Instructor.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Application_Flow_Instructor.png&amp;diff=115721"/>
		<updated>2018-04-03T00:20:29Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: uploaded a new version of &amp;amp;quot;File:Application Flow Instructor.png&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115710</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115710"/>
		<updated>2018-04-03T00:15:33Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Proposed Design */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.&lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
&lt;br /&gt;
[[File:Application Flow Instructor.png]]&lt;br /&gt;
&lt;br /&gt;
== Tasks to be completed ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column grant_permission[----] to table [--------------------------] for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&lt;br /&gt;
== Development so far ==&lt;br /&gt;
We have already added a link to the student_task/view:&lt;br /&gt;
[[File:Sample_link.png]]&lt;br /&gt;
&lt;br /&gt;
We have also added the relevant views and controllers.&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Application_Flow_Instructor.png&amp;diff=115706</id>
		<title>File:Application Flow Instructor.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Application_Flow_Instructor.png&amp;diff=115706"/>
		<updated>2018-04-03T00:15:02Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115607</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115607"/>
		<updated>2018-04-02T22:29:20Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Problem Statement */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment:&lt;br /&gt;
## Made available by other students in the same assignment, available after deadline.&lt;br /&gt;
## Made available by instructor from sample submissions made in an old assignment.&lt;br /&gt;
# Add a feature for instructor to select a previous assignment to show sample submissions for a new assignment.&lt;br /&gt;
&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.&lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
== Tasks to be completed ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column grant_permission[----] to table [--------------------------] for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&lt;br /&gt;
== Development so far ==&lt;br /&gt;
We have already added a link to the student_task/view:&lt;br /&gt;
[[File:Sample_link.png]]&lt;br /&gt;
&lt;br /&gt;
We have also added the relevant views and controllers.&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115604</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115604"/>
		<updated>2018-04-02T22:08:32Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Proposed Design */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature to allow a student to publish their reviews other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment, made available by others.&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
The proposed features will involve two kinds of users : Students and Instructors.&lt;br /&gt;
Students will use the application to make their submissions public and view published reviews.&lt;br /&gt;
Instructors will use the application to make submissions from a previous assignment available as sample submissions for a current assignment. Only those submissions will be visible which were previously made public by the students.&lt;br /&gt;
[[File:Application Flow Student.png]]&lt;br /&gt;
&lt;br /&gt;
== Tasks to be completed ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column grant_permission[----] to table [--------------------------] for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&lt;br /&gt;
== Development so far ==&lt;br /&gt;
We have already added a link to the student_task/view:&lt;br /&gt;
[[File:Sample_link.png]]&lt;br /&gt;
&lt;br /&gt;
We have also added the relevant views and controllers.&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Application_Flow_Student.png&amp;diff=115603</id>
		<title>File:Application Flow Student.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Application_Flow_Student.png&amp;diff=115603"/>
		<updated>2018-04-02T22:04:47Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115449</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115449"/>
		<updated>2018-03-27T23:17:27Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: /* Development so far */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature to allow a student to publish their reviews other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment, made available by others.&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
&lt;br /&gt;
== Tasks to be completed ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column grant_permission[----] to table [--------------------------] for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&lt;br /&gt;
== Development so far ==&lt;br /&gt;
We have already added a link to the student_task/view:&lt;br /&gt;
[[File:Sample_link.png]]&lt;br /&gt;
&lt;br /&gt;
We have also added the relevant views and controllers.&lt;br /&gt;
&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115448</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115448"/>
		<updated>2018-03-27T22:56:54Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature to allow a student to publish their reviews other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment, made available by others.&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
&lt;br /&gt;
== Tasks to be completed ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column grant_permission[----] to table [--------------------------] for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&lt;br /&gt;
== Development so far ==&lt;br /&gt;
We have already added a link to the student_task/view:&lt;br /&gt;
[[File:Sample_link.png]]&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;br /&gt;
== References ==&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115447</id>
		<title>CSC/ECE 517 Spring 2018- Project E1810: Show sample submissions and reviews</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2018-_Project_E1810:_Show_sample_submissions_and_reviews&amp;diff=115447"/>
		<updated>2018-03-27T22:55:37Z</updated>

		<summary type="html">&lt;p&gt;Aksahoo: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a web based open source peer reviewing tool developed and maintained by current and past students of [https://en.wikipedia.org/wiki/North_Carolina_State_University North Carolina State University]. Peer review is a great way for a student to learn how to approach a project and get ideas for their own projects. Currently, there is no way for a student to view another student's work, unless they are reviewing the other student's work.&lt;br /&gt;
&lt;br /&gt;
== Problem Statement ==&lt;br /&gt;
The objective of this project is to:&lt;br /&gt;
# Add a feature to allow teams to publish their work for other students to see.&lt;br /&gt;
# Add a feature to allow a student to publish their reviews other students to see.&lt;br /&gt;
# Add a feature for a student to view sample submissions for a given assignment, made available by others.&lt;br /&gt;
== Proposed Design ==&lt;br /&gt;
&lt;br /&gt;
== Tasks to be completed ==&lt;br /&gt;
The tasks that need to be completed as part of this project can be listed as follows:&lt;br /&gt;
# Add checkbox against each assignment in student_tasks/list view to allow student to publish their work&lt;br /&gt;
# Add column grant_permission[----] to table [--------------------------] for storing user permission (published or not) for each project.&lt;br /&gt;
# Add controller for Sample submissions and implement corresponding methods&lt;br /&gt;
# Add views for sample submissions&lt;br /&gt;
# Make changes to  page student_task/view which would have link to sample submissions for each project.&lt;br /&gt;
&lt;br /&gt;
== Development so far ==&lt;br /&gt;
We have already added a link to the student_task/view:&lt;br /&gt;
[[File:Sample_link.png]]&lt;br /&gt;
== Tests ==&lt;br /&gt;
== External Links ==&lt;br /&gt;
# link to forked repository [https://github.com/ashiskumar123/expertiza]&lt;/div&gt;</summary>
		<author><name>Aksahoo</name></author>
	</entry>
</feed>