Gitlab CSE Unil

Commit 3331e78b authored by M. Chardon's avatar M. Chardon
Browse files

patch maj moodle3.5-editpdf

parent 5be8c22e
...@@ -40,6 +40,7 @@ define(['jquery', './global'], ...@@ -40,6 +40,7 @@ define(['jquery', './global'],
// next value instance ID. // next value instance ID.
return(++instanceCount); return(++instanceCount);
}; };
// I return an initialized object. // I return an initialized object.
/** /**
* Annotation class. * Annotation class.
......
...@@ -94,19 +94,18 @@ class convert_submissions extends scheduled_task { ...@@ -94,19 +94,18 @@ class convert_submissions extends scheduled_task {
} }
mtrace('Convert ' . count($users) . ' submission attempt(s) for assignment ' . $assignmentid); mtrace('Convert ' . count($users) . ' submission attempt(s) for assignment ' . $assignmentid);
$keepinqueue = false;
foreach ($users as $userid) {
$combineddocument = document_services::get_combined_pdf_for_attempt($assignment, $userid, $attemptnumber);
switch ($combineddocument->get_status()) {
case combined_document::STATUS_READY:
case combined_document::STATUS_PENDING_INPUT:
// The document has not been converted yet or is somehow still ready.
$keepinqueue = true;
continue;
}
foreach ($users as $userid) {
try { try {
$combineddocument = document_services::get_combined_pdf_for_attempt($assignment, $userid, $attemptnumber);
$status = $combineddocument->get_status();
switch ($combineddocument->get_status()) {
case combined_document::STATUS_READY:
case combined_document::STATUS_PENDING_INPUT:
// The document has not been converted yet or is somehow still ready.
continue;
}
document_services::get_page_images_for_attempt( document_services::get_page_images_for_attempt(
$assignment, $userid, $attemptnumber, false $assignment, $userid, $attemptnumber, false
); );
...@@ -115,14 +114,11 @@ class convert_submissions extends scheduled_task { ...@@ -115,14 +114,11 @@ class convert_submissions extends scheduled_task {
); );
} catch (\moodle_exception $e) { } catch (\moodle_exception $e) {
mtrace('Conversion failed with error:' . $e->errorcode); mtrace('Conversion failed with error:' . $e->errorcode);
$keepinqueue = true;
} }
} }
if (!$keepinqueue) { // Remove from queue.
// Remove from queue unless requested not to. $DB->delete_records('assignfeedback_editpp_queue', array('id' => $record->id));
$DB->delete_records('assignfeedback_editpp_queue', array('id' => $record->id));
}
} }
} }
......
...@@ -229,8 +229,8 @@ ...@@ -229,8 +229,8 @@
.moodle-dialogue-base .moodle-dialogue.assignfeedback_editpdfplus_dropdown .moodle-dialogue-bd { .moodle-dialogue-base .moodle-dialogue.assignfeedback_editpdfplus_dropdown .moodle-dialogue-bd {
padding: 0; padding: 0;
} }
.assignfeedback_editpdfplus_dropdown .moodle-dialogue-hd, .moodle-dialogue-base .assignfeedback_editpdfplus_dropdown .moodle-dialogue-wrap .moodle-dialogue-hd,
.assignfeedback_editpdfplus_dropdown .moodle-dialogue-ft { .moodle-dialogue-base .assignfeedback_editpdfplus_dropdown .moodle-dialogue-wrap .moodle-dialogue-ft {
display: none; display: none;
} }
.assignfeedback_editpdfplus_menu li hr { .assignfeedback_editpdfplus_menu li hr {
......
...@@ -31,7 +31,7 @@ use \assignfeedback_editpdfplus\pdf; ...@@ -31,7 +31,7 @@ use \assignfeedback_editpdfplus\pdf;
use \assignfeedback_editpdfplus\bdd\annotation; use \assignfeedback_editpdfplus\bdd\annotation;
global $CFG; global $CFG;
require_once($CFG->dirroot . '/mod/assign/tests/base_test.php'); require_once($CFG->dirroot . '/mod/assign/tests/generator.php');
/** /**
* Unit tests for assignfeedback_editpdfplus\comments_quick_list * Unit tests for assignfeedback_editpdfplus\comments_quick_list
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
defined('MOODLE_INTERNAL') || die(); defined('MOODLE_INTERNAL') || die();
$plugin->version = 2018060100; $plugin->version = 2018072300;
$plugin->requires = 2018050800; // Requires this Moodle version. $plugin->requires = 2018050800; // Requires this Moodle version.
$plugin->maturity = MATURITY_STABLE; $plugin->maturity = MATURITY_STABLE;
$plugin->release = "2.0 (Build: 2017100400)"; $plugin->release = "2.0 (Build: 2017100400)";
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment