Skip to content

Commit

Permalink
Merge pull request #623 from turnitin/develop
Browse files Browse the repository at this point in the history
Release 2021060801
  • Loading branch information
jmcgettrick authored Jun 8, 2021
2 parents ccf756e + 55978f9 commit 6bc4f85
Show file tree
Hide file tree
Showing 51 changed files with 834 additions and 950 deletions.
14 changes: 14 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,17 @@
### Date: 2021-Jun-08
### Release: v2021060801

---

####Support for Moodle 3.11
You can now confidently use this integration with Moodle 3.11.

####Submit button is no longer visible after the due date
The submit button will no longer be shown to students who have already submitted to the assignment when the due date has passed. The current functionality will remain for users who have not already submitted.

####Delete parts without errors
The option to delete a part will now only show after there is more than one part used. When there is only one part, we’ll no longer show the deletion option to prevent the assignment from potentially breaking.

### Date: 2020-Nov-18
### Release: v2020111801

Expand Down
21 changes: 9 additions & 12 deletions backup/moodle2/backup_turnitintooltwo_stepslib.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,12 @@ protected function define_structure() {

// Define each element separated.
$turnitintooltwo = new backup_nested_element('turnitintooltwo', array('id'), array(
'type', 'name', 'grade', 'numparts', 'tiiaccount', 'defaultdtstart', 'defaultdtdue', 'defaultdtpost',
'type', 'name', 'grade', 'numparts', 'tiiaccount', 'defaultdtstart', 'defaultdtdue', 'defaultdtpost',
'anon', 'portfolio', 'allowlate', 'reportgenspeed', 'submitpapersto', 'spapercheck', 'internetcheck',
'journalcheck', 'institution_check', 'maxfilesize', 'intro', 'introformat', 'timecreated', 'timemodified',
'journalcheck', 'institution_check', 'maxfilesize', 'intro', 'introformat', 'timecreated', 'timemodified',
'studentreports', 'dateformat', 'usegrademark', 'gradedisplay', 'autoupdates', 'commentedittime', 'commentmaxsize',
'autosubmission', 'shownonsubmission', 'excludebiblio', 'excludequoted', 'excludevalue', 'excludetype', 'erater',
'erater_handbook', 'erater_dictionary', 'erater_spelling', 'erater_grammar', 'erater_usage', 'erater_mechanics',
'autosubmission', 'shownonsubmission', 'excludebiblio', 'excludequoted', 'excludevalue', 'excludetype', 'erater',
'erater_handbook', 'erater_dictionary', 'erater_spelling', 'erater_grammar', 'erater_usage', 'erater_mechanics',
'erater_style', 'transmatch', 'rubric', 'allownonor'
));

Expand All @@ -67,14 +67,11 @@ protected function define_structure() {
$submissions = new backup_nested_element('submissions');

$submission = new backup_nested_element('submission', array('id'), array(
'userid', 'submission_part', 'submission_title',
'submission_type', 'submission_filename', 'submission_objectid',
'submission_score', 'submission_grade', 'submission_gmimaged',
'submission_status', 'submission_queued', 'submission_attempts',
'submission_modified', 'submission_parent', 'submission_nmuserid',
'submission_nmfirstname', 'submission_nmlastname', 'submission_unanon',
'submission_anonreason', 'submission_transmatch', 'submission_orcapable',
'submission_acceptnothing', 'tiiuserid'));
'userid', 'submission_part', 'submission_title', 'submission_type', 'submission_filename',
'submission_objectid', 'submission_score', 'submission_grade', 'submission_gmimaged', 'submission_attempts',
'submission_modified', 'submission_parent', 'submission_nmuserid', 'submission_nmfirstname',
'submission_nmlastname', 'submission_unanon', 'submission_anonreason', 'submission_transmatch',
'submission_orcapable', 'submission_acceptnothing', 'tiiuserid'));

// Build the tree.
$submissions->add_child($submission);
Expand Down
3 changes: 1 addition & 2 deletions classes/view/members.php
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,7 @@ public function build_members_table ($displayrole="students") {
$coursemodule = $this->coursemodule;
$role = $this->get_role_for_display_role($displayrole);

return $turnitintooltwoview
->init_tii_member_by_role_table($coursemodule, $turnitintooltwoassignment, $role);
return $turnitintooltwoview->init_tii_member_by_role_table($coursemodule, $turnitintooltwoassignment, $role);
}

/**
Expand Down
6 changes: 2 additions & 4 deletions db/install.xml
Original file line number Diff line number Diff line change
Expand Up @@ -136,10 +136,8 @@
<FIELD NAME="submission_objectid" TYPE="int" LENGTH="20" NOTNULL="false" UNSIGNED="false" SEQUENCE="false" PREVIOUS="submission_filename" NEXT="submission_score"/>
<FIELD NAME="submission_score" TYPE="int" LENGTH="10" NOTNULL="false" UNSIGNED="false" SEQUENCE="false" PREVIOUS="submission_objectid" NEXT="submission_grade"/>
<FIELD NAME="submission_grade" TYPE="int" LENGTH="10" NOTNULL="false" UNSIGNED="false" SEQUENCE="false" PREVIOUS="submission_score" NEXT="submission_gmimaged"/>
<FIELD NAME="submission_gmimaged" TYPE="int" LENGTH="10" NOTNULL="false" UNSIGNED="false" DEFAULT="0" SEQUENCE="false" PREVIOUS="submission_grade" NEXT="submission_status"/>
<FIELD NAME="submission_status" TYPE="text" LENGTH="medium" NOTNULL="false" SEQUENCE="false" COMMENT="Turnitin Submission Status" PREVIOUS="submission_gmimaged" NEXT="submission_queued"/>
<FIELD NAME="submission_queued" TYPE="int" LENGTH="10" NOTNULL="false" UNSIGNED="false" DEFAULT="0" SEQUENCE="false" PREVIOUS="submission_status" NEXT="submission_attempts"/>
<FIELD NAME="submission_attempts" TYPE="int" LENGTH="10" NOTNULL="true" UNSIGNED="false" DEFAULT="0" SEQUENCE="false" PREVIOUS="submission_queued" NEXT="submission_modified"/>
<FIELD NAME="submission_gmimaged" TYPE="int" LENGTH="10" NOTNULL="false" UNSIGNED="false" DEFAULT="0" SEQUENCE="false" PREVIOUS="submission_grade" NEXT="submission_attempts"/>
<FIELD NAME="submission_attempts" TYPE="int" LENGTH="10" NOTNULL="true" UNSIGNED="false" DEFAULT="0" SEQUENCE="false" PREVIOUS="submission_gmimaged" NEXT="submission_modified"/>
<FIELD NAME="submission_modified" TYPE="int" LENGTH="10" NOTNULL="true" UNSIGNED="false" DEFAULT="0" SEQUENCE="false" PREVIOUS="submission_attempts" NEXT="submission_parent"/>
<FIELD NAME="submission_parent" TYPE="int" LENGTH="10" NOTNULL="false" UNSIGNED="false" DEFAULT="0" SEQUENCE="false" PREVIOUS="submission_modified" NEXT="submission_nmuserid"/>
<FIELD NAME="submission_nmuserid" TYPE="char" LENGTH="100" NOTNULL="false" UNSIGNED="false" SEQUENCE="false" PREVIOUS="submission_parent" NEXT="submission_nmfirstname"/>
Expand Down
27 changes: 27 additions & 0 deletions db/upgrade.php
Original file line number Diff line number Diff line change
Expand Up @@ -304,5 +304,32 @@ function xmldb_turnitintooltwo_upgrade($oldversion) {
upgrade_mod_savepoint(true, 2020081401, 'turnitintooltwo');
}

if ($oldversion < 2021060801) {
// Drop unused fields
$table = new xmldb_table('turnitintooltwo_submissions');
$field = new xmldb_field('submission_status');
if (!$dbman->field_exists($table, $field)) {
$dbman->drop_field($table, $field);
}

$field = new xmldb_field('submission_queued');
if (!$dbman->field_exists($table, $field)) {
$dbman->drop_field($table, $field);
}

// Remove erater settings
set_config('useerater', null, 'turnitintooltwo');
set_config('default_erater', null, 'turnitintooltwo');
set_config('default_erater_handbook', null, 'turnitintooltwo');
set_config('default_erater_dictionary', null, 'turnitintooltwo');
set_config('default_erater_spelling', null, 'turnitintooltwo');
set_config('default_erater_grammar', null, 'turnitintooltwo');
set_config('default_erater_usage', null, 'turnitintooltwo');
set_config('default_erater_mechanics', null, 'turnitintooltwo');
set_config('default_erater_style', null, 'turnitintooltwo');

upgrade_mod_savepoint(true, 2021060801, 'turnitintooltwo');
}

return true;
}
2 changes: 1 addition & 1 deletion jquery/turnitintooltwo-2020111101.js
Original file line number Diff line number Diff line change
Expand Up @@ -679,7 +679,7 @@
if (proceed) {
dvWindow = window.open('', '_blank');
var loading = '<div style="text-align:center;">';
loading += '<img src="' + M.cfg.wwwroot + '/mod/turnitintooltwo/pix/tiiIcon.svg" style="width:100px; height: 100px">';
loading += '<img src="' + M.cfg.wwwroot + '/mod/turnitintooltwo/pix/tii-icon.png" style="width:100px; height: 100px">';
loading += '<p style="font-family: Arial, Helvetica, sans-serif;">' + M.str.turnitintooltwo.loadingdv + '</p>';
loading += '</div>';
$(dvWindow.document.body).html(loading);
Expand Down
4 changes: 2 additions & 2 deletions jquery/turnitintooltwo-2020111101.min.js

Large diffs are not rendered by default.

14 changes: 6 additions & 8 deletions lang/ar/turnitintooltwo.php
Original file line number Diff line number Diff line change
Expand Up @@ -210,11 +210,10 @@
$string['turnitintutorsallenrolled'] = 'جميع المدرسين مسجلين في Turnitin';
$string['turnitintutors_desc'] = 'المدرسين المختارين ادناه هم مسجلين كمدرسين في الفصل الدراسي Turnitin. المدرسين المسجلين يمكنهم الوصول الى هذا الدرس من خلال تسجيل الدخول في موقع ويب Turnitin';
$string['duplicatesfound'] = 'تم إيجاد نسخ مكررة من نفس مهمة Turnitin، تحدث التكرارات عندما يكون واحد أو أكثر من مهام Moodle مرتبطة مع نفس مهمة Turnitin من خلال API. يعرف عن هذا أنه يسبب هذه المشكلة، بالتحديد الإرسالات التي ترسل إلى أحد التكرارات في صندوق وارد المهام للبقية. لتصحيح هذا يجب أن تحذف المهمة المكررة أو تعيد تعيين الدورات التي تكون فيها مهمة مكررة.<br /><br />المهام المكررة التالية قد وجدت:';
$string['erater'] = 'تفعيل الفحص النحوي e-rater';
$string['eraternoun'] = 'E-rater';
$string['erater_handbook'] = 'ETS&copy; كتيب';
$string['erater_dictionary'] = 'قاموس e-rater';
$string['erater_categories'] = 'فئات e-rater';
$string['erater'] = 'تفعيل الفحص النحوي';
$string['erater_handbook'] = 'كتيب النحو';
$string['erater_dictionary'] = 'القاموس';
$string['erater_categories'] = 'فئات الملاحظات';
$string['erater_spelling'] = 'الاملاء';
$string['erater_grammar'] = 'القواعد';
$string['erater_usage'] = 'الاستخدام';
Expand All @@ -228,8 +227,8 @@
$string['erater_dictionary_enus'] = 'القواميس الانكليزية الامريكية';
$string['erater_dictionary_engb'] = 'القواميس الانكليزية البريطانية';
$string['erater_dictionary_en'] = 'كلا من القواميس الانكليزية الامريكية والبريطانية';
$string['turnitinuseerater'] = 'تفعيل ;ETS&copy;';
$string['turnitinuseerater_desc'] = 'اختر ما إذا كنت ستقوم بتمكين ETS&copy; التدقيق النحوي.<br /><i>(قم بتمكين هذا الخيار فقط إذا كان ETS&copy; e-rater تم تمكينه على حساب Turnitin لديك)</i>';
$string['turnitinuseerater'] = 'تمكين الملاحظات النحوية';
$string['turnitinuseerater_desc'] = 'اختر ما إذا كان يمكن للملفات المرسلة أن تتلقى تدقيقًا نحويًا.<br /><i>(يجب أيضًا تمكين الملاحظات النحوية في حساب Turnitin الخاص بك).</i>';
$string['student_read'] = 'قام الطالب بعرض هذا المستند في:';
$string['student_notread'] = 'لم يقم الطالب بعرض هذا المستند';
$string['relinkusers'] = 'اعادة ربط المستخدمين';
Expand Down Expand Up @@ -257,7 +256,6 @@
$string['migrationcoursegeterror'] = 'تعذر الحصول على أي من الدروس من Turnitin';
$string['migrationassignmentgeterror'] = 'تعذر الحصول على أي من المهام من Turnitin';
$string['getassignmenterror'] = 'تعذر الحصول على مهام الترحيل من Turnitin';
$string['checkupdateavailableerror'] = 'تعذر التحقق من وجود تحديث لإصدار Moodle Direct';
$string['maxmarkserror'] = 'الحد الأقصى للعلامات يجب أن يكون بين 0 و 100';
$string['nosubmissiondataavailable'] = 'بيانات تسليم اخر غير متوفرة';
$string['nointegration'] = 'لا تكامل';
Expand Down
12 changes: 4 additions & 8 deletions lang/ca/turnitintooltwo.php
Original file line number Diff line number Diff line change
Expand Up @@ -212,11 +212,10 @@
$string['turnitintutorsallenrolled'] = 'Tots els tutors estan inscrits en Turnitin';
$string['turnitintutors_desc'] = 'El tutors seleccionats a sota estan inscrits com a tutors en aquesta classe Turnitin. Els tutors inscrits poden aconseguir accés a aquesta classe iniciant sessió en la pàgina web de Turnitin.';
$string['duplicatesfound'] = 'S´han trobat còpies duplicades de les mateixes assignacions Turnitin, els duplicats es produeixen quan una o més assignacions de Moodle Direct està connectada a la mateixa assignació Turnitin a través de l´API de Turnitin. Es conegut que això pot causar problemes, la major part dels lliuraments fets a un dels duplicats apareixeran en la safata d´entrada dels lliuraments dels altres. Per arreglar això vosté hauria d´eliminar les assignacions duplicades o reajustar el curs on s´hi troben les assignacions duplicades.<br /><br /> S´han trobat els següents duplicats:';
$string['erater'] = 'Activar la revisió ortogràfica de e-rater';
$string['eraternoun'] = 'E-rater';
$string['erater_handbook'] = 'Manual de ETS&copy;';
$string['erater_dictionary'] = 'Diccionari de e-rater';
$string['erater_categories'] = 'Categories de e-rater';
$string['erater'] = 'Activar la revisió ortogràfica';
$string['erater_handbook'] = 'Manual';
$string['erater_dictionary'] = 'Diccionari';
$string['erater_categories'] = 'Categories';
$string['erater_spelling'] = 'Ortografia';
$string['erater_grammar'] = 'Gramàtica';
$string['erater_usage'] = 'Ús';
Expand All @@ -230,8 +229,6 @@
$string['erater_dictionary_enus'] = 'Diccionari d´anglès (Estats Units)';
$string['erater_dictionary_engb'] = 'Diccionari d´anglès (Regne Unit)';
$string['erater_dictionary_en'] = 'Diccionari d´anglès (EUA i Regne Unit)';
$string['turnitinuseerater'] = 'Activat ETS&copy;';
$string['turnitinuseerater_desc'] = 'Triar entre activar ETS&copy; revisió de gramàtica.<br /><i>(Activar aquesta opció si ETS&copy; e-rater està activat en la teva compte Turnitin)</i>';
$string['student_read'] = 'L\&#39;estudiant ha vist el treball a:';
$string['student_notread'] = 'L\&#39;estudiant no ha vist aquest treball.';
$string['relinkusers'] = 'Tornar a vincular els usuaris';
Expand Down Expand Up @@ -259,7 +256,6 @@
$string['migrationcoursegeterror'] = 'No s\&#39;ha pogut recuperar cap classe de Turnitin';
$string['migrationassignmentgeterror'] = 'No s\&#39;ha pogut recuperar cap dels exercicis de Turnitin';
$string['getassignmenterror'] = 'No s\&#39;han pogut recuperar els exercicis de migració de Turnitin';
$string['checkupdateavailableerror'] = 'No s\&#39;han pogut cercar actualitzacions de la versió de Moodle Direct ';
$string['maxmarkserror'] = 'Les notes màximes han d&#39;estar entre 0 i 100';
$string['nosubmissiondataavailable'] = 'No hi ha altres dades sobre lliuraments disponibles';
$string['nointegration'] = 'Sense integració';
Expand Down
14 changes: 6 additions & 8 deletions lang/cs/turnitintooltwo.php
Original file line number Diff line number Diff line change
Expand Up @@ -210,11 +210,10 @@
$string['turnitintutorsallenrolled'] = 'Všichni školitelé jsou zapsáni v systému Turnitin';
$string['turnitintutors_desc'] = 'Vybraní školitelé níže jsou v tomto Turnitin kurzu zapsáni jako školitelé. Zapsaní školitelé mohou získat přístup do tohoto kurzu, jakmile se přihlásí na webové stránce Turnitin.';
$string['duplicatesfound'] = 'Byly nalezeny duplicitní kopie stejného úkolu Turnitin. Duplikát vzniká, pokud jeden nebo více úkolů Moodle Direct je propojen se stejným úkolem Turnitin prostřednictvím Turnitin API. Taková situace může způsobit problémy. Zejména když se práce odevzdané u jednoho z duplikátů objeví ve schránce pro odevzdané práce u ostatních duplikátů. Chcete-li tento problém odstranit, měli byste buď odstranit duplicitní úkoly, nebo zrušit kurz, kde se duplicitní úkoly nachází.<br /><br />Byly nalezeny následující duplikáty:';
$string['erater'] = 'Povolit kontrolu gramatiky e-rater';
$string['eraternoun'] = 'E-rater';
$string['erater_handbook'] = 'ETS&copy; příručka';
$string['erater_dictionary'] = 'Slovník e-rater';
$string['erater_categories'] = 'Kategorie e-rater';
$string['erater'] = 'Povolit kontrolu gramatiky';
$string['erater_handbook'] = 'Gramatická příručka';
$string['erater_dictionary'] = 'Slovník';
$string['erater_categories'] = 'Kategorie zpětné vazby';
$string['erater_spelling'] = 'Pravopis';
$string['erater_grammar'] = 'Gramatika';
$string['erater_usage'] = 'Použití';
Expand All @@ -228,8 +227,8 @@
$string['erater_dictionary_enus'] = 'Slovník americké angličtiny';
$string['erater_dictionary_engb'] = 'Slovník britské angličtiny';
$string['erater_dictionary_en'] = 'Slovníky americké i britské angličtiny';
$string['turnitinuseerater'] = 'Povolit ETS&copy;';
$string['turnitinuseerater_desc'] = 'Zvolte, zda má být povolena kontrola pravopisu ETS&copy;.<br /><i>(Aktivujte tuto možnost, pouze pokud je ETS&copy; e-rater povolen u vašeho účtu Turnitin)</i>';
$string['turnitinusegrammar'] = 'Povolit gramatickou zpětnou vazbu';
$string['turnitinusegrammar_desc'] = 'Zvolte v případě, že odeslané soubory mohou projít kontrolou gramatiky.<br /><i>(Gramatická zpětná vazba musí také být povolena na vašem účtu Turnitin)</i>';
$string['student_read'] = 'Student si práci prohlédl dne:';
$string['student_notread'] = 'Student si tuto práci neprohlédl.';
$string['relinkusers'] = 'Opětovně propojit uživatele';
Expand Down Expand Up @@ -257,7 +256,6 @@
$string['migrationcoursegeterror'] = 'Nepodařilo se získat žádné kurzy ze systému Turnitin';
$string['migrationassignmentgeterror'] = 'Nepodařilo se získat žádné úkoly ze systému Turnitin';
$string['getassignmenterror'] = 'Nelze načíst přiřazení migrace ze systému Turnitin';
$string['checkupdateavailableerror'] = 'Nelze zkontrolovat možnost aktualizace verze Moodle Direct';
$string['maxmarkserror'] = 'Maximální známky se musí pohybovat mezi 0 a 100';
$string['nosubmissiondataavailable'] = 'Další údaje o odevzdání nejsou dostupné';
$string['nointegration'] = 'Žádná integrace';
Expand Down
Loading

0 comments on commit 6bc4f85

Please sign in to comment.