Merge branch 'MDL-34691_assign_overdue_by' of https://github.com/SWiT/moodle
[moodle.git] / mod / assign / renderer.php
index 3ca0232..c44f451 100644 (file)
@@ -168,11 +168,8 @@ class mod_assign_renderer extends plugin_renderer_base {
 
             $o .= $this->output->continue_button($cancelurl);
         } else {
 
             $o .= $this->output->continue_button($cancelurl);
         } else {
-            // All submission plugins ready - confirm the student really does want to submit for marking
-            $continueurl = new moodle_url('/mod/assign/view.php', array('id' => $page->coursemoduleid,
-                                                                        'action' => 'confirmsubmit',
-                                                                        'sesskey' => sesskey()));
-            $o .= $this->output->confirm(get_string('confirmsubmission', 'mod_assign'), $continueurl, $cancelurl);
+            // All submission plugins ready - show the confirmation form (may contain submission statement)
+            $o .= $this->moodleform($page->confirmform);
         }
         $o .= $this->output->container_end();
 
         }
         $o .= $this->output->container_end();
 
@@ -324,7 +321,7 @@ class mod_assign_renderer extends plugin_renderer_base {
         }
 
         foreach ($status->feedbackplugins as $plugin) {
         }
 
         foreach ($status->feedbackplugins as $plugin) {
-            if ($plugin->is_enabled() && $plugin->is_visible() && !$plugin->is_empty($status->grade)) {
+            if ($plugin->is_enabled() && $plugin->is_visible() && !empty($status->grade) && !$plugin->is_empty($status->grade)) {
                 $row = new html_table_row();
                 $cell1 = new html_table_cell($plugin->get_name());
                 $pluginfeedback = new assign_feedback_plugin_feedback($plugin, $status->grade, assign_feedback_plugin_feedback::SUMMARY, $status->coursemoduleid, $status->returnaction, $status->returnparams);
                 $row = new html_table_row();
                 $cell1 = new html_table_cell($plugin->get_name());
                 $pluginfeedback = new assign_feedback_plugin_feedback($plugin, $status->grade, assign_feedback_plugin_feedback::SUMMARY, $status->coursemoduleid, $status->returnaction, $status->returnparams);