diff --git a/mod/assignment/lang/en/assignment.php b/mod/assignment/lang/en/assignment.php
index c1d7cbb..71bfb59 100644
--- a/mod/assignment/lang/en/assignment.php
+++ b/mod/assignment/lang/en/assignment.php
@@ -150,6 +150,7 @@ $string['notes'] = 'Notes';
 $string['notesempty'] = 'No entry';
 $string['notesupdateerror'] = 'Error when updating notes';
 $string['notgradedyet'] = 'Not graded yet';
+$string['norequiregrading'] = 'There are no assignments required grading';
 $string['notsubmittedyet'] = 'Not submitted yet';
 $string['onceassignmentsent'] = 'Once the assignment is sent for marking, you will no longer be able to delete or attach file(s). Do you want to continue?';
 $string['operation'] = 'Operation';
diff --git a/mod/assignment/lib.php b/mod/assignment/lib.php
index c27ca95..2239cda 100644
--- a/mod/assignment/lib.php
+++ b/mod/assignment/lib.php
@@ -1264,14 +1264,16 @@ class assignment_base {
         // Start working -- this is necessary as soon as the niceties are over
         $table->setup();
 
-        if (empty($users)) {
-            echo $OUTPUT->heading(get_string('nosubmitusers','assignment'));
-            echo '</div>';
-            return true;
-        }
         if ($this->assignment->assignmenttype=='upload' || $this->assignment->assignmenttype=='online' || $this->assignment->assignmenttype=='uploadsingle') { //TODO: this is an ugly hack, where is the plugin spirit? (skodak)
             echo '<div style="text-align:right"><a href="submissions.php?id='.$this->cm->id.'&amp;download=zip">'.get_string('downloadall', 'assignment').'</a></div>';
         }
+
+        /*if (empty($users)) {
+            echo $OUTPUT->heading(get_string('nosubmitusers','assignment'));
+            echo '</div>';
+            return true;
+        }*/
+
     /// Construct the SQL
 
         list($where, $params) = $table->get_sql_where();
@@ -1290,179 +1292,188 @@ class assignment_base {
         }
 
         $ufields = user_picture::fields('u');
+        if (!empty($users)) {
+            $select = "SELECT $ufields,
+                              s.id AS submissionid, s.grade, s.submissioncomment,
+                              s.timemodified, s.timemarked,
+                              COALESCE(SIGN(SIGN(s.timemarked) + SIGN(s.timemarked - s.timemodified)), 0) AS status ";
+            $sql = 'FROM {user} u '.
+                   'LEFT JOIN {assignment_submissions} s ON u.id = s.userid
+                    AND s.assignment = '.$this->assignment->id.' '.
+                   'WHERE '.$where.'u.id IN ('.implode(',',$users).') ';
+
+            $ausers = $DB->get_records_sql($select.$sql.$sort, $params, $table->get_page_start(), $table->get_page_size());
+
+            $table->pagesize($perpage, count($users));
+
+            ///offset used to calculate index of student in that particular query, needed for the pop up to know who's next
+            $offset = $page * $perpage;
+            $strupdate = get_string('update');
+            $strgrade  = get_string('grade');
+            $grademenu = make_grades_menu($this->assignment->grade);
+
+            if ($ausers !== false) {
+                $grading_info = grade_get_grades($this->course->id, 'mod', 'assignment', $this->assignment->id, array_keys($ausers));
+                $endposition = $offset + $perpage;
+                $currentposition = 0;
+                foreach ($ausers as $auser) {
+                    if ($currentposition == $offset && $offset < $endposition) {
+                        $final_grade = $grading_info->items[0]->grades[$auser->id];
+                        $grademax = $grading_info->items[0]->grademax;
+                        $final_grade->formatted_grade = round($final_grade->grade,2) .' / ' . round($grademax,2);
+                        $locked_overridden = 'locked';
+                        if ($final_grade->overridden) {
+                            $locked_overridden = 'overridden';
+                        }
 
-        $select = "SELECT $ufields,
-                          s.id AS submissionid, s.grade, s.submissioncomment,
-                          s.timemodified, s.timemarked,
-                          COALESCE(SIGN(SIGN(s.timemarked) + SIGN(s.timemarked - s.timemodified)), 0) AS status ";
-        $sql = 'FROM {user} u '.
-               'LEFT JOIN {assignment_submissions} s ON u.id = s.userid
-                AND s.assignment = '.$this->assignment->id.' '.
-               'WHERE '.$where.'u.id IN ('.implode(',',$users).') ';
-
-        $ausers = $DB->get_records_sql($select.$sql.$sort, $params, $table->get_page_start(), $table->get_page_size());
-
-        $table->pagesize($perpage, count($users));
-
-        ///offset used to calculate index of student in that particular query, needed for the pop up to know who's next
-        $offset = $page * $perpage;
-        $strupdate = get_string('update');
-        $strgrade  = get_string('grade');
-        $grademenu = make_grades_menu($this->assignment->grade);
-
-        if ($ausers !== false) {
-            $grading_info = grade_get_grades($this->course->id, 'mod', 'assignment', $this->assignment->id, array_keys($ausers));
-            $endposition = $offset + $perpage;
-            $currentposition = 0;
-            foreach ($ausers as $auser) {
-                if ($currentposition == $offset && $offset < $endposition) {
-                    $final_grade = $grading_info->items[0]->grades[$auser->id];
-                    $grademax = $grading_info->items[0]->grademax;
-                    $final_grade->formatted_grade = round($final_grade->grade,2) .' / ' . round($grademax,2);
-                    $locked_overridden = 'locked';
-                    if ($final_grade->overridden) {
-                        $locked_overridden = 'overridden';
-                    }
+                    /// Calculate user status
+                        $auser->status = ($auser->timemarked > 0) && ($auser->timemarked >= $auser->timemodified);
+                        $picture = $OUTPUT->user_picture($auser);
 
-                /// Calculate user status
-                    $auser->status = ($auser->timemarked > 0) && ($auser->timemarked >= $auser->timemodified);
-                    $picture = $OUTPUT->user_picture($auser);
+                        if (empty($auser->submissionid)) {
+                            $auser->grade = -1; //no submission yet
+                        }
 
-                    if (empty($auser->submissionid)) {
-                        $auser->grade = -1; //no submission yet
-                    }
+                        if (!empty($auser->submissionid)) {
+                        ///Prints student answer and student modified date
+                        ///attach file or print link to student answer, depending on the type of the assignment.
+                        ///Refer to print_student_answer in inherited classes.
+                            if ($auser->timemodified > 0) {
+                                $studentmodified = '<div id="ts'.$auser->id.'">'.$this->print_student_answer($auser->id)
+                                                 . userdate($auser->timemodified).'</div>';
+                            } else {
+                                $studentmodified = '<div id="ts'.$auser->id.'">&nbsp;</div>';
+                            }
+                        ///Print grade, dropdown or text
+                            if ($auser->timemarked > 0) {
+                                $teachermodified = '<div id="tt'.$auser->id.'">'.userdate($auser->timemarked).'</div>';
+
+                                if ($final_grade->locked or $final_grade->overridden) {
+                                    $grade = '<div id="g'.$auser->id.'" class="'. $locked_overridden .'">'.$final_grade->formatted_grade.'</div>';
+                                } else if ($quickgrade) {
+                                    $attributes = array();
+                                    $attributes['tabindex'] = $tabindex++;
+                                    $menu = html_writer::select(make_grades_menu($this->assignment->grade), 'menu['.$auser->id.']', $auser->grade, array(-1=>get_string('nograde')), $attributes);
+                                    $grade = '<div id="g'.$auser->id.'">'. $menu .'</div>';
+                                } else {
+                                    $grade = '<div id="g'.$auser->id.'">'.$this->display_grade($auser->grade).'</div>';
+                                }
+
+                            } else {
+                                $teachermodified = '<div id="tt'.$auser->id.'">&nbsp;</div>';
+                                if ($final_grade->locked or $final_grade->overridden) {
+                                    $grade = '<div id="g'.$auser->id.'" class="'. $locked_overridden .'">'.$final_grade->formatted_grade.'</div>';
+                                } else if ($quickgrade) {
+                                    $attributes = array();
+                                    $attributes['tabindex'] = $tabindex++;
+                                    $menu = html_writer::select(make_grades_menu($this->assignment->grade), 'menu['.$auser->id.']', $auser->grade, array(-1=>get_string('nograde')), $attributes);
+                                    $grade = '<div id="g'.$auser->id.'">'.$menu.'</div>';
+                                } else {
+                                    $grade = '<div id="g'.$auser->id.'">'.$this->display_grade($auser->grade).'</div>';
+                                }
+                            }
+                        ///Print Comment
+                            if ($final_grade->locked or $final_grade->overridden) {
+                                $comment = '<div id="com'.$auser->id.'">'.shorten_text(strip_tags($final_grade->str_feedback),15).'</div>';
 
-                    if (!empty($auser->submissionid)) {
-                    ///Prints student answer and student modified date
-                    ///attach file or print link to student answer, depending on the type of the assignment.
-                    ///Refer to print_student_answer in inherited classes.
-                        if ($auser->timemodified > 0) {
-                            $studentmodified = '<div id="ts'.$auser->id.'">'.$this->print_student_answer($auser->id)
-                                             . userdate($auser->timemodified).'</div>';
+                            } else if ($quickgrade) {
+                                $comment = '<div id="com'.$auser->id.'">'
+                                         . '<textarea tabindex="'.$tabindex++.'" name="submissioncomment['.$auser->id.']" id="submissioncomment'
+                                         . $auser->id.'" rows="2" cols="20">'.($auser->submissioncomment).'</textarea></div>';
+                            } else {
+                                $comment = '<div id="com'.$auser->id.'">'.shorten_text(strip_tags($auser->submissioncomment),15).'</div>';
+                            }
                         } else {
                             $studentmodified = '<div id="ts'.$auser->id.'">&nbsp;</div>';
-                        }
-                    ///Print grade, dropdown or text
-                        if ($auser->timemarked > 0) {
-                            $teachermodified = '<div id="tt'.$auser->id.'">'.userdate($auser->timemarked).'</div>';
+                            $teachermodified = '<div id="tt'.$auser->id.'">&nbsp;</div>';
+                            $status          = '<div id="st'.$auser->id.'">&nbsp;</div>';
 
                             if ($final_grade->locked or $final_grade->overridden) {
-                                $grade = '<div id="g'.$auser->id.'" class="'. $locked_overridden .'">'.$final_grade->formatted_grade.'</div>';
-                            } else if ($quickgrade) {
+                                $grade = '<div id="g'.$auser->id.'">'.$final_grade->formatted_grade . '</div>';
+                            } else if ($quickgrade) {   // allow editing
                                 $attributes = array();
                                 $attributes['tabindex'] = $tabindex++;
                                 $menu = html_writer::select(make_grades_menu($this->assignment->grade), 'menu['.$auser->id.']', $auser->grade, array(-1=>get_string('nograde')), $attributes);
-                                $grade = '<div id="g'.$auser->id.'">'. $menu .'</div>';
+                                $grade = '<div id="g'.$auser->id.'">'.$menu.'</div>';
                             } else {
-                                $grade = '<div id="g'.$auser->id.'">'.$this->display_grade($auser->grade).'</div>';
+                                $grade = '<div id="g'.$auser->id.'">-</div>';
                             }
 
-                        } else {
-                            $teachermodified = '<div id="tt'.$auser->id.'">&nbsp;</div>';
                             if ($final_grade->locked or $final_grade->overridden) {
-                                $grade = '<div id="g'.$auser->id.'" class="'. $locked_overridden .'">'.$final_grade->formatted_grade.'</div>';
+                                $comment = '<div id="com'.$auser->id.'">'.$final_grade->str_feedback.'</div>';
                             } else if ($quickgrade) {
-                                $attributes = array();
-                                $attributes['tabindex'] = $tabindex++;
-                                $menu = html_writer::select(make_grades_menu($this->assignment->grade), 'menu['.$auser->id.']', $auser->grade, array(-1=>get_string('nograde')), $attributes);
-                                $grade = '<div id="g'.$auser->id.'">'.$menu.'</div>';
+                                $comment = '<div id="com'.$auser->id.'">'
+                                         . '<textarea tabindex="'.$tabindex++.'" name="submissioncomment['.$auser->id.']" id="submissioncomment'
+                                         . $auser->id.'" rows="2" cols="20">'.($auser->submissioncomment).'</textarea></div>';
                             } else {
-                                $grade = '<div id="g'.$auser->id.'">'.$this->display_grade($auser->grade).'</div>';
+                                $comment = '<div id="com'.$auser->id.'">&nbsp;</div>';
                             }
                         }
-                    ///Print Comment
-                        if ($final_grade->locked or $final_grade->overridden) {
-                            $comment = '<div id="com'.$auser->id.'">'.shorten_text(strip_tags($final_grade->str_feedback),15).'</div>';
-
-                        } else if ($quickgrade) {
-                            $comment = '<div id="com'.$auser->id.'">'
-                                     . '<textarea tabindex="'.$tabindex++.'" name="submissioncomment['.$auser->id.']" id="submissioncomment'
-                                     . $auser->id.'" rows="2" cols="20">'.($auser->submissioncomment).'</textarea></div>';
-                        } else {
-                            $comment = '<div id="com'.$auser->id.'">'.shorten_text(strip_tags($auser->submissioncomment),15).'</div>';
-                        }
-                    } else {
-                        $studentmodified = '<div id="ts'.$auser->id.'">&nbsp;</div>';
-                        $teachermodified = '<div id="tt'.$auser->id.'">&nbsp;</div>';
-                        $status          = '<div id="st'.$auser->id.'">&nbsp;</div>';
-
-                        if ($final_grade->locked or $final_grade->overridden) {
-                            $grade = '<div id="g'.$auser->id.'">'.$final_grade->formatted_grade . '</div>';
-                        } else if ($quickgrade) {   // allow editing
-                            $attributes = array();
-                            $attributes['tabindex'] = $tabindex++;
-                            $menu = html_writer::select(make_grades_menu($this->assignment->grade), 'menu['.$auser->id.']', $auser->grade, array(-1=>get_string('nograde')), $attributes);
-                            $grade = '<div id="g'.$auser->id.'">'.$menu.'</div>';
-                        } else {
-                            $grade = '<div id="g'.$auser->id.'">-</div>';
-                        }
 
-                        if ($final_grade->locked or $final_grade->overridden) {
-                            $comment = '<div id="com'.$auser->id.'">'.$final_grade->str_feedback.'</div>';
-                        } else if ($quickgrade) {
-                            $comment = '<div id="com'.$auser->id.'">'
-                                     . '<textarea tabindex="'.$tabindex++.'" name="submissioncomment['.$auser->id.']" id="submissioncomment'
-                                     . $auser->id.'" rows="2" cols="20">'.($auser->submissioncomment).'</textarea></div>';
+                        if (empty($auser->status)) { /// Confirm we have exclusively 0 or 1
+                            $auser->status = 0;
                         } else {
-                            $comment = '<div id="com'.$auser->id.'">&nbsp;</div>';
+                            $auser->status = 1;
                         }
-                    }
-
-                    if (empty($auser->status)) { /// Confirm we have exclusively 0 or 1
-                        $auser->status = 0;
-                    } else {
-                        $auser->status = 1;
-                    }
 
-                    $buttontext = ($auser->status == 1) ? $strupdate : $strgrade;
+                        $buttontext = ($auser->status == 1) ? $strupdate : $strgrade;
 
-                    ///No more buttons, we use popups ;-).
-                    $popup_url = '/mod/assignment/submissions.php?id='.$this->cm->id
-                               . '&amp;userid='.$auser->id.'&amp;mode=single'.'&amp;filter='.$filter.'&amp;offset='.$offset++;
+                        ///No more buttons, we use popups ;-).
+                        $popup_url = '/mod/assignment/submissions.php?id='.$this->cm->id
+                                   . '&amp;userid='.$auser->id.'&amp;mode=single'.'&amp;filter='.$filter.'&amp;offset='.$offset++;
 
-                    $button = $OUTPUT->action_link($popup_url, $buttontext);
+                        $button = $OUTPUT->action_link($popup_url, $buttontext);
 
-                    $status  = '<div id="up'.$auser->id.'" class="s'.$auser->status.'">'.$button.'</div>';
+                        $status  = '<div id="up'.$auser->id.'" class="s'.$auser->status.'">'.$button.'</div>';
 
-                    $finalgrade = '<span id="finalgrade_'.$auser->id.'">'.$final_grade->str_grade.'</span>';
+                        $finalgrade = '<span id="finalgrade_'.$auser->id.'">'.$final_grade->str_grade.'</span>';
 
-                    $outcomes = '';
+                        $outcomes = '';
 
-                    if ($uses_outcomes) {
+                        if ($uses_outcomes) {
 
-                        foreach($grading_info->outcomes as $n=>$outcome) {
-                            $outcomes .= '<div class="outcome"><label>'.$outcome->name.'</label>';
-                            $options = make_grades_menu(-$outcome->scaleid);
+                            foreach($grading_info->outcomes as $n=>$outcome) {
+                                $outcomes .= '<div class="outcome"><label>'.$outcome->name.'</label>';
+                                $options = make_grades_menu(-$outcome->scaleid);
 
-                            if ($outcome->grades[$auser->id]->locked or !$quickgrade) {
-                                $options[0] = get_string('nooutcome', 'grades');
-                                $outcomes .= ': <span id="outcome_'.$n.'_'.$auser->id.'">'.$options[$outcome->grades[$auser->id]->grade].'</span>';
-                            } else {
-                                $attributes = array();
-                                $attributes['tabindex'] = $tabindex++;
-                                $attributes['id'] = 'outcome_'.$n.'_'.$auser->id;
-                                $outcomes .= ' '.html_writer::select($options, 'outcome_'.$n.'['.$auser->id.']', $outcome->grades[$auser->id]->grade, array(0=>get_string('nooutcome', 'grades')), $attributes);
+                                if ($outcome->grades[$auser->id]->locked or !$quickgrade) {
+                                    $options[0] = get_string('nooutcome', 'grades');
+                                    $outcomes .= ': <span id="outcome_'.$n.'_'.$auser->id.'">'.$options[$outcome->grades[$auser->id]->grade].'</span>';
+                                } else {
+                                    $attributes = array();
+                                    $attributes['tabindex'] = $tabindex++;
+                                    $attributes['id'] = 'outcome_'.$n.'_'.$auser->id;
+                                    $outcomes .= ' '.html_writer::select($options, 'outcome_'.$n.'['.$auser->id.']', $outcome->grades[$auser->id]->grade, array(0=>get_string('nooutcome', 'grades')), $attributes);
+                                }
+                                $outcomes .= '</div>';
                             }
-                            $outcomes .= '</div>';
                         }
-                    }
 
-                    $userlink = '<a href="' . $CFG->wwwroot . '/user/view.php?id=' . $auser->id . '&amp;course=' . $course->id . '">' . fullname($auser, has_capability('moodle/site:viewfullnames', $this->context)) . '</a>';
-                    $row = array($picture, $userlink, $grade, $comment, $studentmodified, $teachermodified, $status, $finalgrade);
-                    if ($uses_outcomes) {
-                        $row[] = $outcomes;
-                    }
+                        $userlink = '<a href="' . $CFG->wwwroot . '/user/view.php?id=' . $auser->id . '&amp;course=' . $course->id . '">' . fullname($auser, has_capability('moodle/site:viewfullnames', $this->context)) . '</a>';
+                        $row = array($picture, $userlink, $grade, $comment, $studentmodified, $teachermodified, $status, $finalgrade);
+                        if ($uses_outcomes) {
+                            $row[] = $outcomes;
+                        }
 
-                    $table->add_data($row);
+                        $table->add_data($row);
+                    }
+                    $currentposition++;
                 }
-                $currentposition++;
             }
+        } else {
+            $ab = new stdClass();
+            $ab->id = 0;
+            foreach ($tablecolumns as $col) {
+                $ab->$col = '';
+            }
+            $table->define_columns(array('message'));
+            $table->column_class('message', 'noheader');
+            $table->add_data(array(get_string('norequiregrading', 'assignment')));
         }
-
         $table->print_html();  /// Print the whole table
 
         /// Print quickgrade form around the table
-        if ($quickgrade && $table->started_output){
+        if ($quickgrade && $table->started_output && !empty($users)){
             $mailinfopref = false;
             if (get_user_preferences('assignment_mailinfo', 1)) {
                 $mailinfopref = true;
diff --git a/mod/assignment/styles.css b/mod/assignment/styles.css
index 62a660e..d8aae04 100644
--- a/mod/assignment/styles.css
+++ b/mod/assignment/styles.css
@@ -23,6 +23,7 @@
 #page-mod-assignment-submissions .submissions .grade,
 #page-mod-assignment-submissions .submissions .outcome,
 #page-mod-assignment-submissions .submissions .finalgrade {text-align: right;}
+#page-mod-assignment-submissions .submissions .header.noheader {display:none;}
 #page-mod-assignment-submissions .qgprefs #optiontable {text-align:right;margin-left:auto;}
 
