Compare commits
302 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 896ce9b4e6 | |||
| c41605e282 | |||
| 70ae23829f | |||
| f29a819640 | |||
| c89d29f8e0 | |||
| dc5cbf1532 | |||
| 08c1b6eff4 | |||
| 02660c64ff | |||
| 787573a007 | |||
| 6585f80f29 | |||
| 7bcc28ac2f | |||
| cc22e91f8f | |||
| 3b2ea17ec4 | |||
| ce37064429 | |||
| 6aa0203deb | |||
| d6d9c4a9c3 | |||
| 993a1ac38f | |||
| e76a83ebf9 | |||
| e6d2eb3792 | |||
| 0f11ec17ca | |||
| c09577b5f3 | |||
| 68124fe0af | |||
| 5611053587 | |||
| c493c6ba2a | |||
| ce589fb4fe | |||
| d8564f56f0 | |||
| e17ee1e9c5 | |||
| 9ddd0bd72a | |||
| fba8a2e290 | |||
| 6f4f3946f6 | |||
| b6098b92b0 | |||
| a42ebf3385 | |||
| 6acdd1f3ab | |||
| 602b3815a0 | |||
| b06b50cf1a | |||
| 9c2f96a13d | |||
| 9214bc50a2 | |||
| 45e0bc6372 | |||
| b1e73801d1 | |||
| 445308fc3b | |||
| 3179ca58b7 | |||
| 86cbb2c450 | |||
| 0c4220fba5 | |||
| 743ad4f126 | |||
| 4a5e209d8c | |||
| 6b50178e4e | |||
| db4031fa52 | |||
| 9a68e396e8 | |||
| b5cc09d20b | |||
| 75528e9305 | |||
| 1082da020e | |||
| 7d085745be | |||
| d46c89d4e7 | |||
| 8817bcf7ba | |||
| 00b7c8a2fd | |||
| c1d089b1be | |||
| 3bbd2e7892 | |||
| c35f42e679 | |||
| 070262c8f9 | |||
| ac3022fb0e | |||
| eed84bfd4b | |||
| 133c06b2e1 | |||
| 6c18a3c802 | |||
| e7c4f87a5d | |||
| 2e95bfa5f2 | |||
| f8ca828c02 | |||
| 22e22a39af | |||
| 6823ac39cc | |||
| 1e5a1eb77b | |||
| 910247b15e | |||
| b94131a90e | |||
| cfe4df185c | |||
| 41c817ef38 | |||
| 32549792c2 | |||
| b6c6b99470 | |||
| 72f7cc6a07 | |||
| a6757673a2 | |||
| e47c42f4a8 | |||
| c51e98722b | |||
| d513f79a24 | |||
| e7048861a6 | |||
| a188724a19 | |||
| d165d2cf24 | |||
| 6db0ef42d4 | |||
| 0e526f9ea6 | |||
| f2520ef454 | |||
| 9fd041ad16 | |||
| 608923c445 | |||
| ec3ade054f | |||
| 0edc92e6bf | |||
| ebdcc591a2 | |||
| 029a29a3cf | |||
| 856dbae2cb | |||
| 729c7f143b | |||
| 5f42866391 | |||
| e0b69258fb | |||
| e684411988 | |||
| 1e15527fa5 | |||
| 0373f42728 | |||
| 864cf11c2f | |||
| ba6e9f22b4 | |||
| 554afbe2cd | |||
| a0f9277b51 | |||
| ebda22d612 | |||
| 0ad03ab13c | |||
| 4dcdab69f6 | |||
| a8321fc3ac | |||
| 167a73cffc | |||
| b19bf809dc | |||
| d2f333357d | |||
| a1d78eac23 | |||
| 937831c736 | |||
| de7951b817 | |||
| 0e1c96a44c | |||
| cdabef710d | |||
| 2a7b253e82 | |||
| b87f4d1ea5 | |||
| c3606bf9ba | |||
| 6806700b01 | |||
| 071633c194 | |||
| ef01fb49a6 | |||
| b9fb0ede39 | |||
| 3567a37302 | |||
| 34770e55b2 | |||
| f7e9dbcbe2 | |||
| e353a80475 | |||
| 8226afc20e | |||
| 535abb009d | |||
| 3125397713 | |||
| 9ce8250f77 | |||
| 1eefc40296 | |||
| a3d444a3af | |||
| 3509e3771a | |||
| d7dd9aa732 | |||
| 2335a0018d | |||
| 6cb68d8d3a | |||
| a3b99f1c03 | |||
| 139c549e3c | |||
| 8336d2be91 | |||
| 46629407c2 | |||
| f1996f596b | |||
| db2718a65d | |||
| 2e26127821 | |||
| ccbc8fadf8 | |||
| 0905763270 | |||
| 558d773213 | |||
| 4288a75a48 | |||
| cdcb157b7e | |||
| 12d454cb4c | |||
| c1d1c098f4 | |||
| 402ce4d5f5 | |||
| f8db8073a2 | |||
| 2eb6dd8cdc | |||
| 32cf700c31 | |||
| c2542c35f6 | |||
| a563739951 | |||
| 04d312fbcc | |||
| e82c98f26d | |||
| f40585c94d | |||
| b91250e430 | |||
| ea3f8fa0cb | |||
| e1f11ce7b1 | |||
| 7c920b5706 | |||
| 3abc7d1c4e | |||
| d2decc7fb0 | |||
| 784e8588ee | |||
| d00a536a0c | |||
| 9a9a841497 | |||
| e319e5a2d0 | |||
| 90574fd1c8 | |||
| 67e8ddc65f | |||
| a41f004fb7 | |||
| 22c756c644 | |||
| b42298d3fa | |||
| e13c169ded | |||
| 766a5891b6 | |||
| 5108b3e7c1 | |||
| 87f417f510 | |||
| 7a75832faa | |||
| 8b2d2a5fc6 | |||
| 5b9dead542 | |||
| 50b024746e | |||
| c0ab266dd0 | |||
| a90270455e | |||
| f0be825426 | |||
| dce24b2a5a | |||
| 985b62f3a9 | |||
| d92499f4c4 | |||
| 6c61222fbb | |||
| 6e19e0c175 | |||
| 92ae0fda60 | |||
| 9702e72bd7 | |||
| 1401dd8f47 | |||
| aae0a865bb | |||
| fed7bdfa96 | |||
| 57a38cf813 | |||
| ed6478fb7e | |||
| 26ce8a1f15 | |||
| f2ceab9582 | |||
| 02151fbe85 | |||
| 6db9bc560d | |||
| 440b00b7d3 | |||
| ba0bd5b9ab | |||
| cf2cda4b31 | |||
| 3cc6435b18 | |||
| e0b383aae0 | |||
| 2121f50755 | |||
| 121c9d3099 | |||
| 32e709a9dc | |||
| 397a8936cb | |||
| 4e3551004e | |||
| e48dd18997 | |||
| 6d36432f2f | |||
| aaf67d012b | |||
| 316706511d | |||
| b407285890 | |||
| 042b90d078 | |||
| c2465fa0e3 | |||
| 4b4f760bfa | |||
| 9ec4ffe9be | |||
| 08e1b1e49e | |||
| 8bf0e602c6 | |||
| 4583242dd6 | |||
| af97a17395 | |||
| 89574179da | |||
| 6ee2dd680e | |||
| 72fce6fc46 | |||
| 3c57ce6e72 | |||
| 79d55f5dee | |||
| d9864df62c | |||
| a04b4d89b2 | |||
| 21735b6075 | |||
| 156371af9c | |||
| a3a8a4a970 | |||
| 3848d57eef | |||
| 4afdece091 | |||
| 649bad89a2 | |||
| 886ce4cfcb | |||
| 8da74658b5 | |||
| 59f2ef03ae | |||
| d1b41e0a34 | |||
| c2e2d38d99 | |||
| 7bde88208c | |||
| 2e2686acf2 | |||
| ed532e8f3b | |||
| 94535cbc8a | |||
| 12d3875811 | |||
| be52d0dace | |||
| e078aa1351 | |||
| 1b13df8f65 | |||
| 3111a4f120 | |||
| aacfdda594 | |||
| 349027033c | |||
| 4ca5db7c0b | |||
| 4c72716d43 | |||
| 733e84fc26 | |||
| 594253c322 | |||
| 1cf3129e86 | |||
| 6178a8c820 | |||
| 4c22adddef | |||
| 91b779aa02 | |||
| 27946d0c65 | |||
| 9ac0280f80 | |||
| b2931bc620 | |||
| 7acd833a3c | |||
| 8f48fbf6f6 | |||
| 81636e4694 | |||
| 91df0eb289 | |||
| 27e0254e8f | |||
| 1929107b8c | |||
| e587b9be09 | |||
| 80ff09db28 | |||
| 61495ffbcb | |||
| 3bc489a0ec | |||
| 6d3a686c2c | |||
| e9fe4cc37c | |||
| 4457c6605b | |||
| d82b0d8ed9 | |||
| f16b97eb8c | |||
| dda3512514 | |||
| f4fe47705e | |||
| 3ec84d746a | |||
| 330f45b6e2 | |||
| cddbbc1752 | |||
| 9407afa0ba | |||
| a62863c658 | |||
| 1164882eff | |||
| 7b0a42b20c | |||
| ff14679150 | |||
| e79a53e370 | |||
| e78f6b391a | |||
| 5a04868aec | |||
| b3a6face59 | |||
| e7714135a4 | |||
| e2b2fad613 | |||
| b85bdc91d4 | |||
| 39f02182de | |||
| fc73f127eb | |||
| e35a24916f | |||
| 36916193d2 | |||
| c85f8d3f93 | |||
| 4bdc05f059 |
@@ -47,6 +47,7 @@ switch ($action) {
|
||||
// remove from enabled list
|
||||
$key = array_search($editor, $active_editors);
|
||||
unset($active_editors[$key]);
|
||||
add_to_config_log('editor_visibility', '1', '0', $editor);
|
||||
break;
|
||||
|
||||
case 'enable':
|
||||
@@ -54,6 +55,7 @@ switch ($action) {
|
||||
if (!in_array($editor, $active_editors)) {
|
||||
$active_editors[] = $editor;
|
||||
$active_editors = array_unique($active_editors);
|
||||
add_to_config_log('editor_visibility', '0', '1', $editor);
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -66,6 +68,7 @@ switch ($action) {
|
||||
$fsave = $active_editors[$key];
|
||||
$active_editors[$key] = $active_editors[$key + 1];
|
||||
$active_editors[$key + 1] = $fsave;
|
||||
add_to_config_log('editor_position', $key, $key + 1, $editor);
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -79,6 +82,7 @@ switch ($action) {
|
||||
$fsave = $active_editors[$key];
|
||||
$active_editors[$key] = $active_editors[$key - 1];
|
||||
$active_editors[$key - 1] = $fsave;
|
||||
add_to_config_log('editor_position', $key, $key - 1, $editor);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -1905,4 +1905,180 @@
|
||||
</CUSTOM_CHECK>
|
||||
</CUSTOM_CHECKS>
|
||||
</MOODLE>
|
||||
<MOODLE version="3.3" requires="2.7">
|
||||
<UNICODE level="required">
|
||||
<FEEDBACK>
|
||||
<ON_ERROR message="unicoderequired" />
|
||||
</FEEDBACK>
|
||||
</UNICODE>
|
||||
<DATABASE level="required">
|
||||
<VENDOR name="mariadb" version="5.5.31" />
|
||||
<VENDOR name="mysql" version="5.5.31" />
|
||||
<VENDOR name="postgres" version="9.3" />
|
||||
<VENDOR name="mssql" version="10.0" />
|
||||
<VENDOR name="oracle" version="10.2" />
|
||||
</DATABASE>
|
||||
<PHP version="5.6.5" level="required">
|
||||
</PHP>
|
||||
<PCREUNICODE level="optional">
|
||||
<FEEDBACK>
|
||||
<ON_CHECK message="pcreunicodewarning" />
|
||||
</FEEDBACK>
|
||||
</PCREUNICODE>
|
||||
<PHP_EXTENSIONS>
|
||||
<PHP_EXTENSION name="iconv" level="required">
|
||||
<FEEDBACK>
|
||||
<ON_ERROR message="iconvrequired" />
|
||||
</FEEDBACK>
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="mbstring" level="optional">
|
||||
<FEEDBACK>
|
||||
<ON_CHECK message="mbstringrecommended" />
|
||||
</FEEDBACK>
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="curl" level="required">
|
||||
<FEEDBACK>
|
||||
<ON_ERROR message="curlrequired" />
|
||||
</FEEDBACK>
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="openssl" level="required">
|
||||
<FEEDBACK>
|
||||
<ON_ERROR message="opensslrequired" />
|
||||
</FEEDBACK>
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="tokenizer" level="optional">
|
||||
<FEEDBACK>
|
||||
<ON_CHECK message="tokenizerrecommended" />
|
||||
</FEEDBACK>
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="xmlrpc" level="optional">
|
||||
<FEEDBACK>
|
||||
<ON_CHECK message="xmlrpcrecommended" />
|
||||
</FEEDBACK>
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="soap" level="optional">
|
||||
<FEEDBACK>
|
||||
<ON_CHECK message="soaprecommended" />
|
||||
</FEEDBACK>
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="ctype" level="required">
|
||||
<FEEDBACK>
|
||||
<ON_ERROR message="ctyperequired" />
|
||||
</FEEDBACK>
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="zip" level="required">
|
||||
<FEEDBACK>
|
||||
<ON_ERROR message="ziprequired" />
|
||||
</FEEDBACK>
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="zlib" level="required">
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="gd" level="required">
|
||||
<FEEDBACK>
|
||||
<ON_ERROR message="gdrequired" />
|
||||
</FEEDBACK>
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="simplexml" level="required">
|
||||
<FEEDBACK>
|
||||
<ON_ERROR message="simplexmlrequired" />
|
||||
</FEEDBACK>
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="spl" level="required">
|
||||
<FEEDBACK>
|
||||
<ON_ERROR message="splrequired" />
|
||||
</FEEDBACK>
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="pcre" level="required">
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="dom" level="required">
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="xml" level="required">
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="xmlreader" level="required">
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="intl" level="optional">
|
||||
<FEEDBACK>
|
||||
<ON_CHECK message="intlrecommended" />
|
||||
</FEEDBACK>
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="json" level="required">
|
||||
</PHP_EXTENSION>
|
||||
<PHP_EXTENSION name="hash" level="required"/>
|
||||
<PHP_EXTENSION name="fileinfo" level="required"/>
|
||||
</PHP_EXTENSIONS>
|
||||
<PHP_SETTINGS>
|
||||
<PHP_SETTING name="memory_limit" value="96M" level="required">
|
||||
<FEEDBACK>
|
||||
<ON_ERROR message="settingmemorylimit" />
|
||||
</FEEDBACK>
|
||||
</PHP_SETTING>
|
||||
<PHP_SETTING name="file_uploads" value="1" level="optional">
|
||||
<FEEDBACK>
|
||||
<ON_CHECK message="settingfileuploads" />
|
||||
</FEEDBACK>
|
||||
</PHP_SETTING>
|
||||
<PHP_SETTING name="opcache.enable" value="1" level="optional">
|
||||
<FEEDBACK>
|
||||
<ON_CHECK message="opcacherecommended" />
|
||||
</FEEDBACK>
|
||||
</PHP_SETTING>
|
||||
</PHP_SETTINGS>
|
||||
<CUSTOM_CHECKS>
|
||||
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_database_storage_engine" level="required">
|
||||
<FEEDBACK>
|
||||
<ON_ERROR message="unsupporteddbstorageengine" />
|
||||
</FEEDBACK>
|
||||
</CUSTOM_CHECK>
|
||||
<CUSTOM_CHECK file="question/engine/upgrade/upgradelib.php" function="quiz_attempts_upgraded" level="required">
|
||||
<FEEDBACK>
|
||||
<ON_ERROR message="quizattemptsupgradedmessage" />
|
||||
</FEEDBACK>
|
||||
</CUSTOM_CHECK>
|
||||
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_slasharguments" level="optional">
|
||||
<FEEDBACK>
|
||||
<ON_CHECK message="slashargumentswarning" />
|
||||
</FEEDBACK>
|
||||
</CUSTOM_CHECK>
|
||||
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_database_tables_row_format" level="optional">
|
||||
<FEEDBACK>
|
||||
<ON_CHECK message="unsupporteddbtablerowformat" />
|
||||
</FEEDBACK>
|
||||
</CUSTOM_CHECK>
|
||||
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_unoconv_version" level="optional">
|
||||
<FEEDBACK>
|
||||
<ON_CHECK message="unoconvwarning" />
|
||||
</FEEDBACK>
|
||||
</CUSTOM_CHECK>
|
||||
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_libcurl_version" level="optional">
|
||||
<FEEDBACK>
|
||||
<ON_CHECK message="libcurlwarning" />
|
||||
</FEEDBACK>
|
||||
</CUSTOM_CHECK>
|
||||
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_mysql_file_format" level="required">
|
||||
<FEEDBACK>
|
||||
<ON_ERROR message="unsupporteddbfileformat" />
|
||||
</FEEDBACK>
|
||||
</CUSTOM_CHECK>
|
||||
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_mysql_file_per_table" level="required">
|
||||
<FEEDBACK>
|
||||
<ON_ERROR message="unsupporteddbfilepertable" />
|
||||
</FEEDBACK>
|
||||
</CUSTOM_CHECK>
|
||||
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_mysql_large_prefix" level="required">
|
||||
<FEEDBACK>
|
||||
<ON_ERROR message="unsupporteddblargeprefix" />
|
||||
</FEEDBACK>
|
||||
</CUSTOM_CHECK>
|
||||
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_is_https" level="optional">
|
||||
<FEEDBACK>
|
||||
<ON_CHECK message="ishttpswarning" />
|
||||
</FEEDBACK>
|
||||
</CUSTOM_CHECK>
|
||||
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_mysql_incomplete_unicode_support" level="optional">
|
||||
<FEEDBACK>
|
||||
<ON_CHECK message="incompleteunicodesupport" />
|
||||
</FEEDBACK>
|
||||
</CUSTOM_CHECK>
|
||||
</CUSTOM_CHECKS>
|
||||
</MOODLE>
|
||||
</COMPATIBILITY_MATRIX>
|
||||
|
||||
@@ -422,12 +422,12 @@ class site_registration_form extends moodleform {
|
||||
$mform->addElement('checkbox', 'badges', '',
|
||||
" " . get_string('badgesnumber', 'hub', $badges));
|
||||
$mform->setDefault('badges', $badgesnumber != -1);
|
||||
$mform->setType('resources', PARAM_INT);
|
||||
$mform->setType('badges', PARAM_INT);
|
||||
|
||||
$mform->addElement('checkbox', 'issuedbadges', '',
|
||||
" " . get_string('issuedbadgesnumber', 'hub', $issuedbadges));
|
||||
$mform->setDefault('issuedbadges', $issuedbadgesnumber != -1);
|
||||
$mform->setType('resources', PARAM_INT);
|
||||
$mform->setType('issuedbadges', PARAM_INT);
|
||||
|
||||
$mform->addElement('checkbox', 'participantnumberaverage', '',
|
||||
" " . get_string('participantnumberaverage', 'hub', $participantnumberaverage));
|
||||
|
||||
+1
-1
@@ -1612,7 +1612,7 @@ class core_admin_renderer extends plugin_renderer_base {
|
||||
$row = new html_table_row();
|
||||
$row->attributes['class'] = 'type-' . $plugin->type . ' name-' . $plugin->type . '_' . $plugin->name;
|
||||
|
||||
if ($this->page->theme->resolve_image_location('icon', $plugin->type . '_' . $plugin->name)) {
|
||||
if ($this->page->theme->resolve_image_location('icon', $plugin->type . '_' . $plugin->name, null)) {
|
||||
$icon = $this->output->pix_icon('icon', '', $plugin->type . '_' . $plugin->name, array('class' => 'icon pluginicon'));
|
||||
} else {
|
||||
$icon = $this->output->pix_icon('spacer', '', 'moodle', array('class' => 'icon pluginicon noicon'));
|
||||
|
||||
@@ -325,6 +325,7 @@ if ($verbose || $status) {
|
||||
}
|
||||
|
||||
// Update status after auto-rerun finished.
|
||||
$status = 0;
|
||||
foreach ($exitcodes as $name => $exitcode) {
|
||||
if ($exitcode) {
|
||||
if (!empty($parallelrun)) {
|
||||
|
||||
@@ -0,0 +1,42 @@
|
||||
@tool @tool_behat
|
||||
Feature: Backported behat step definitions
|
||||
In order to provide feature file compatibility between multiple Moodle versions
|
||||
As a developer
|
||||
I need to be able to use backported steps from newer Moodle versiosn
|
||||
|
||||
Background:
|
||||
Given the following "users" exist:
|
||||
| username | firstname | lastname | email |
|
||||
| student1 | Student | 1 | student1@example.com |
|
||||
| teacher1 | Teacher | 1 | teacher1@example.com |
|
||||
And the following "courses" exist:
|
||||
| fullname | shortname | format |
|
||||
| Course 1 | C101 | topics |
|
||||
And the following "course enrolments" exist:
|
||||
| user | course | role |
|
||||
| student1 | C101 | student |
|
||||
| teacher1 | C101 | editingteacher |
|
||||
|
||||
Scenario: I am on the course homepage
|
||||
When I log in as "student1"
|
||||
And I am on "Course 1" course homepage
|
||||
Then I should see "Topic 1"
|
||||
|
||||
@javascript
|
||||
Scenario: I am on the course homepage with JS
|
||||
When I log in as "teacher1"
|
||||
And I am on "Course 1" course homepage
|
||||
Then I should see "Topic 1"
|
||||
|
||||
Scenario: I am on the course homepage with editing
|
||||
When I log in as "teacher1"
|
||||
And I am on "Course 1" course homepage with editing mode on
|
||||
Then I should see "Topic 1"
|
||||
And I should see "Add an activity or resource"
|
||||
|
||||
@javascript
|
||||
Scenario: I am on the course homepage with editing and JS
|
||||
When I log in as "teacher1"
|
||||
And I am on "Course 1" course homepage with editing mode on
|
||||
Then I should see "Topic 1"
|
||||
And I should see "Add an activity or resource"
|
||||
@@ -1012,7 +1012,7 @@ class manager {
|
||||
$messageparams = new \stdClass();
|
||||
$messageparams->html = $message->html;
|
||||
$messageparams->plain = $message->plain;
|
||||
$messagepreferencesurl = new \moodle_url("/message/edit.php", array('id' => $USER->id));
|
||||
$messagepreferencesurl = new \moodle_url("/message/notificationpreferences.php", array('id' => $USER->id));
|
||||
$messageparams->messagepreferencesurl = $messagepreferencesurl->out();
|
||||
$htmlmessage = get_string('messageprocessingsuccesshtml', 'tool_messageinbound', $messageparams);
|
||||
$plainmessage = get_string('messageprocessingsuccess', 'tool_messageinbound', $messageparams);
|
||||
|
||||
@@ -57,6 +57,13 @@ class api {
|
||||
global $CFG;
|
||||
require_once($CFG->libdir . '/adminlib.php');
|
||||
|
||||
// Check if we can return this from cache.
|
||||
$cache = \cache::make('tool_mobile', 'plugininfo');
|
||||
$pluginsinfo = $cache->get('mobileplugins');
|
||||
if ($pluginsinfo !== false) {
|
||||
return (array)$pluginsinfo;
|
||||
}
|
||||
|
||||
$pluginsinfo = [];
|
||||
$plugintypes = core_component::get_plugin_types();
|
||||
|
||||
@@ -68,7 +75,7 @@ class api {
|
||||
$component = $plugintype . '_' . $plugin;
|
||||
$version = get_component_version($component);
|
||||
|
||||
require_once("$path/db/mobile.php");
|
||||
require("$path/db/mobile.php");
|
||||
foreach ($addons as $addonname => $addoninfo) {
|
||||
$plugininfo = array(
|
||||
'component' => $component,
|
||||
@@ -81,7 +88,7 @@ class api {
|
||||
);
|
||||
|
||||
// All the mobile packages must be under the plugin mobile directory.
|
||||
$package = $path . DIRECTORY_SEPARATOR . 'mobile' . DIRECTORY_SEPARATOR . $addonname . '.zip';
|
||||
$package = $path . '/mobile/' . $addonname . '.zip';
|
||||
if (file_exists($package)) {
|
||||
$plugininfo['fileurl'] = $CFG->wwwroot . '' . str_replace($CFG->dirroot, '', $package);
|
||||
$plugininfo['filehash'] = sha1_file($package);
|
||||
@@ -91,6 +98,9 @@ class api {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$cache->set('mobileplugins', $pluginsinfo);
|
||||
|
||||
return $pluginsinfo;
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
// This file is part of Moodle - http://moodle.org/
|
||||
//
|
||||
// Moodle is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// Moodle is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/**
|
||||
* Mobile cache definitions.
|
||||
*
|
||||
* @package tool_mobile
|
||||
* @copyright 2017 Skylar Kelty <S.Kelty@kent.ac.uk>
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
|
||||
defined('MOODLE_INTERNAL') || die;
|
||||
|
||||
$definitions = array(
|
||||
'plugininfo' => array(
|
||||
'mode' => cache_store::MODE_APPLICATION,
|
||||
'simplekeys' => true,
|
||||
'staticacceleration' => true,
|
||||
'staticaccelerationsize' => 1
|
||||
)
|
||||
);
|
||||
@@ -24,6 +24,7 @@
|
||||
|
||||
$string['autologinkeygenerationlockout'] = 'Auto-login key generation is blocked because of too many requests within an hour.';
|
||||
$string['autologinnotallowedtoadmins'] = 'Auto-login is not allowed for site admins.';
|
||||
$string['cachedef_plugininfo'] = 'This stores the list of plugins with mobile addons';
|
||||
$string['clickheretolaunchtheapp'] = 'Click here if the app does not open automatically.';
|
||||
$string['configmobilecssurl'] = 'A CSS file to customise your mobile app interface.';
|
||||
$string['enablesmartappbanners'] = 'Enable Smart App Banners';
|
||||
|
||||
@@ -49,7 +49,7 @@ It\'s highly recommended to be running the latest (+ version) available of your
|
||||
This functionality doesn\'t perform any action against the DB (just reads from it), so can be safely executed at any moment.';
|
||||
$string['confirmcheckforeignkeys'] = 'This functionality will search for potential violations of the foreign keys defined in the install.xml definitions. (Moodle does not currently generate actual foreign key constraints in the database, which is why invalid data may be present.)
|
||||
|
||||
It\'s highly recommended to be running the latest (+ version) available of your Moodle release before executing the search of missing indexes.
|
||||
It\'s highly recommended to be running the latest (+ version) available of your Moodle release before executing the search for potential violations of the foreign keys.
|
||||
|
||||
This functionality doesn\'t perform any action against the DB (just reads from it), so can be safely executed at any moment.';
|
||||
$string['confirmcheckindexes'] = 'This functionality will search for potential missing indexes in your Moodle server, generating (but not executing!) automatically the needed SQL statements to keep everything updated.
|
||||
|
||||
@@ -26,13 +26,14 @@ if (!is_enabled_auth('shibboleth')) {
|
||||
$inputstream = file_get_contents("php://input");
|
||||
if ($action == 'logout' && !empty($redirect)) {
|
||||
|
||||
if ($USER->auth == 'shibboleth') {
|
||||
// Logout out user from application.
|
||||
if (isloggedin($USER) && $USER->auth == 'shibboleth') {
|
||||
// Logout user from application.
|
||||
require_logout();
|
||||
// Finally, send user to the return URL.
|
||||
redirect($redirect);
|
||||
}
|
||||
|
||||
// Finally, send user to the return URL.
|
||||
redirect($redirect);
|
||||
|
||||
} else if (!empty($inputstream)) {
|
||||
|
||||
// Back channel logout.
|
||||
|
||||
+42
-25
@@ -46,23 +46,6 @@ class edit_backpack_form extends moodleform {
|
||||
$mform->addElement('header', 'backpackheader', get_string('backpackconnection', 'badges'));
|
||||
$mform->addHelpButton('backpackheader', 'backpackconnection', 'badges');
|
||||
$mform->addElement('static', 'url', get_string('url'), BADGE_BACKPACKURL);
|
||||
$status = html_writer::tag('span', get_string('notconnected', 'badges'),
|
||||
array('class' => 'notconnected', 'id' => 'connection-status'));
|
||||
$mform->addElement('static', 'status', get_string('status'), $status);
|
||||
|
||||
$nojs = html_writer::tag('noscript', get_string('error:personaneedsjs', 'badges'),
|
||||
array('class' => 'notconnected'));
|
||||
$personadiv = $OUTPUT->container($nojs, null, 'persona-container');
|
||||
|
||||
$mform->addElement('static', 'persona', '', $personadiv);
|
||||
$mform->addHelpButton('persona', 'personaconnection', 'badges');
|
||||
|
||||
$PAGE->requires->js(new moodle_url('https://login.persona.org/include.js'));
|
||||
$PAGE->requires->js('/badges/backpack.js');
|
||||
$PAGE->requires->js_init_call('badges_init_persona_login_button', null, false);
|
||||
$PAGE->requires->strings_for_js(array('error:backpackloginfailed', 'signinwithyouremail',
|
||||
'error:noassertion', 'error:connectionunknownreason', 'error:badjson', 'connecting',
|
||||
'notconnected'), 'badges');
|
||||
|
||||
$mform->addElement('hidden', 'userid', $USER->id);
|
||||
$mform->setType('userid', PARAM_INT);
|
||||
@@ -70,23 +53,57 @@ class edit_backpack_form extends moodleform {
|
||||
$mform->addElement('hidden', 'backpackurl', BADGE_BACKPACKURL);
|
||||
$mform->setType('backpackurl', PARAM_URL);
|
||||
|
||||
if (isset($this->_customdata['email'])) {
|
||||
// Email will be passed in when we're in the process of verifying the user's email address,
|
||||
// so set the connection status, lock the email field, and provide options to resend the verification
|
||||
// email or cancel the verification process entirely and start over.
|
||||
$status = html_writer::tag('span', get_string('backpackemailverificationpending', 'badges'),
|
||||
array('class' => 'notconnected', 'id' => 'connection-status'));
|
||||
$mform->addElement('static', 'status', get_string('status'), $status);
|
||||
$mform->addElement('hidden', 'email', $this->_customdata['email']);
|
||||
$mform->setType('email', PARAM_RAW_TRIMMED);
|
||||
$mform->hardFreeze(['email']);
|
||||
$status = html_writer::tag('span', $this->_customdata['email'], []);
|
||||
$mform->addElement('static', 'emailverify', get_string('email'), $status);
|
||||
$buttonarray = [];
|
||||
$buttonarray[] = &$mform->createElement('submit', 'submitbutton',
|
||||
get_string('backpackconnectionresendemail', 'badges'));
|
||||
$buttonarray[] = &$mform->createElement('submit', 'revertbutton',
|
||||
get_string('backpackconnectioncancelattempt', 'badges'));
|
||||
$mform->addGroup($buttonarray, 'buttonar', '', [''], false);
|
||||
$mform->closeHeaderBefore('buttonar');
|
||||
} else {
|
||||
// Email isn't present, so provide an input element to get it and a button to start the verification process.
|
||||
$status = html_writer::tag('span', get_string('notconnected', 'badges'),
|
||||
array('class' => 'notconnected', 'id' => 'connection-status'));
|
||||
$mform->addElement('static', 'status', get_string('status'), $status);
|
||||
$mform->addElement('text', 'email', get_string('email'), 'maxlength="100" size="30"');
|
||||
$mform->addHelpButton('email', 'backpackemail', 'badges');
|
||||
$mform->addRule('email', get_string('required'), 'required', null, 'client');
|
||||
$mform->setType('email', PARAM_RAW_TRIMMED);
|
||||
$this->add_action_buttons(false, get_string('backpackconnectionconnect', 'badges'));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Validates form data
|
||||
*/
|
||||
public function validation($data, $files) {
|
||||
global $DB;
|
||||
$errors = parent::validation($data, $files);
|
||||
|
||||
$check = new stdClass();
|
||||
$check->backpackurl = $data['backpackurl'];
|
||||
$check->email = $data['email'];
|
||||
// We don't need to verify the email address if we're clearing a pending email verification attempt.
|
||||
if (!isset($data['revertbutton'])) {
|
||||
$check = new stdClass();
|
||||
$check->backpackurl = $data['backpackurl'];
|
||||
$check->email = $data['email'];
|
||||
|
||||
$bp = new OpenBadgesBackpackHandler($check);
|
||||
$request = $bp->curl_request('user');
|
||||
if (isset($request->status) && $request->status == 'missing') {
|
||||
$errors['email'] = get_string('error:nosuchuser', 'badges');
|
||||
$bp = new OpenBadgesBackpackHandler($check);
|
||||
$request = $bp->curl_request('user');
|
||||
if (isset($request->status) && $request->status == 'missing') {
|
||||
$errors['email'] = get_string('error:nosuchuser', 'badges');
|
||||
} else if (!isset($request->status) || $request->status !== 'okay') {
|
||||
$errors['email'] = get_string('backpackconnectionunexpectedresult', 'badges');
|
||||
}
|
||||
}
|
||||
return $errors;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,78 @@
|
||||
<?php
|
||||
// This file is part of Moodle - http://moodle.org/
|
||||
//
|
||||
// Moodle is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// Moodle is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/**
|
||||
* Endpoint for the verification email link.
|
||||
*
|
||||
* @package core
|
||||
* @subpackage badges
|
||||
* @copyright 2016 Jake Dallimore <jrhdallimore@gmail.com>
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
require_once(__DIR__ . '/../config.php');
|
||||
require_once($CFG->libdir . '/badgeslib.php');
|
||||
require_once(__DIR__ . '/lib/backpacklib.php');
|
||||
|
||||
$data = optional_param('data', '', PARAM_RAW);
|
||||
require_login();
|
||||
$PAGE->set_url('/badges/openbackpackemailverify.php');
|
||||
$PAGE->set_context(context_user::instance($USER->id));
|
||||
$redirect = '/badges/mybackpack.php';
|
||||
|
||||
// Confirm the secret and create the backpack connection.
|
||||
$storedsecret = get_user_preferences('badges_email_verify_secret');
|
||||
if (!is_null($storedsecret)) {
|
||||
if ($data === $storedsecret) {
|
||||
$storedemail = get_user_preferences('badges_email_verify_address');
|
||||
|
||||
$data = new stdClass();
|
||||
$data->backpackurl = BADGE_BACKPACKURL;
|
||||
$data->email = $storedemail;
|
||||
$bp = new OpenBadgesBackpackHandler($data);
|
||||
|
||||
// Make sure we have all the required information before trying to save the connection.
|
||||
$backpackuser = $bp->curl_request('user');
|
||||
if (isset($backpackuser->status) && $backpackuser->status === 'okay' && isset($backpackuser->userId)) {
|
||||
$backpackuid = $backpackuser->userId;
|
||||
} else {
|
||||
redirect(new moodle_url($redirect), get_string('backpackconnectionunexpectedresult', 'badges'),
|
||||
null, \core\output\notification::NOTIFY_ERROR);
|
||||
}
|
||||
|
||||
$obj = new stdClass();
|
||||
$obj->userid = $USER->id;
|
||||
$obj->email = $data->email;
|
||||
$obj->backpackurl = $data->backpackurl;
|
||||
$obj->backpackuid = $backpackuid;
|
||||
$obj->autosync = 0;
|
||||
$obj->password = '';
|
||||
$DB->insert_record('badge_backpack', $obj);
|
||||
|
||||
// Remove the verification vars and redirect to the mypackpack page.
|
||||
unset_user_preference('badges_email_verify_secret');
|
||||
unset_user_preference('badges_email_verify_address');
|
||||
redirect(new moodle_url($redirect), get_string('backpackemailverifysuccess', 'badges'),
|
||||
null, \core\output\notification::NOTIFY_SUCCESS);
|
||||
} else {
|
||||
// Stored secret doesn't match the supplied secret. Take user back to the mybackpack page and present a warning message.
|
||||
redirect(new moodle_url($redirect), get_string('backpackemailverifytokenmismatch', 'badges'),
|
||||
null, \core\output\notification::NOTIFY_ERROR);
|
||||
}
|
||||
} else {
|
||||
// Stored secret is null. Either the email address has already been verified, or there is no record of a verification attempt
|
||||
// for the current user. Either way, just redirect to the mybackpack page.
|
||||
redirect(new moodle_url($redirect));
|
||||
}
|
||||
@@ -117,3 +117,45 @@ class OpenBadgesBackpackHandler {
|
||||
return $this->backpack;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Create and send a verification email to the email address supplied.
|
||||
*
|
||||
* Since we're not sending this email to a user, email_to_user can't be used
|
||||
* but this function borrows largely the code from that process.
|
||||
*
|
||||
* @param string $email the email address to send the verification email to.
|
||||
* @return true if the email was sent successfully, false otherwise.
|
||||
*/
|
||||
function send_verification_email($email) {
|
||||
global $DB, $USER;
|
||||
|
||||
// Store a user secret (badges_email_verify_secret) and the address (badges_email_verify_address) as users prefs.
|
||||
// The address will be used by edit_backpack_form for display during verification and to facilitate the resending
|
||||
// of verification emails to said address.
|
||||
$secret = random_string(15);
|
||||
set_user_preference('badges_email_verify_secret', $secret);
|
||||
set_user_preference('badges_email_verify_address', $email);
|
||||
|
||||
// To, from.
|
||||
$tempuser = $DB->get_record('user', array('id' => $USER->id), '*', MUST_EXIST);
|
||||
$tempuser->email = $email;
|
||||
$noreplyuser = core_user::get_noreply_user();
|
||||
|
||||
// Generate the verification email body.
|
||||
$verificationurl = '/badges/backpackemailverify.php';
|
||||
$verificationurl = new moodle_url($verificationurl);
|
||||
$verificationpath = $verificationurl->out(false);
|
||||
|
||||
$site = get_site();
|
||||
$args = new stdClass();
|
||||
$args->link = $verificationpath . '?data='. $secret;
|
||||
$args->sitename = $site->fullname;
|
||||
$args->admin = generate_email_signoff();
|
||||
|
||||
$messagesubject = get_string('backpackemailverifyemailsubject', 'badges', $site->fullname);
|
||||
$messagetext = get_string('backpackemailverifyemailbody', 'badges', $args);
|
||||
$messagehtml = text_to_html($messagetext, false, false, true);
|
||||
|
||||
return email_to_user($tempuser, $noreplyuser, $messagesubject, $messagetext, $messagehtml);
|
||||
}
|
||||
|
||||
+29
-13
@@ -110,23 +110,39 @@ if ($backpack) {
|
||||
}
|
||||
} else {
|
||||
// If backpack is not connected, need to connect first.
|
||||
$form = new edit_backpack_form();
|
||||
// To create a new connection to the backpack, first we need to verify the user's email address:
|
||||
// 1. User enters email and clicks 'Connect to backpack'.
|
||||
// 2. After cross-checking the email address against the backpack provider, an email is sent to the specified address,
|
||||
// and the email and secret are stored in user preferences. These will be cleared upon successful verification.
|
||||
// 3. User clicks verification link in the email to confirm the backpack connection.
|
||||
// 4. User redirected to the mybackpack page.
|
||||
// While the verification process is pending, the edit_backpack_form form will present the user with options to resend the
|
||||
// verification email, and to cancel the current verification attempt and start over.
|
||||
|
||||
// To pass through the current state of the verification attempt to the form.
|
||||
$params['email'] = get_user_preferences('badges_email_verify_address');
|
||||
|
||||
$form = new edit_backpack_form(new moodle_url('/badges/mybackpack.php'), $params);
|
||||
if ($form->is_cancelled()) {
|
||||
redirect(new moodle_url('/badges/mybadges.php'));
|
||||
} else if ($data = $form->get_data()) {
|
||||
$bp = new OpenBadgesBackpackHandler($data);
|
||||
|
||||
$obj = new stdClass();
|
||||
$obj->userid = $data->userid;
|
||||
$obj->email = $data->email;
|
||||
$obj->backpackurl = $data->backpackurl;
|
||||
$obj->backpackuid = $bp->curl_request('user')->userId;
|
||||
$obj->autosync = 0;
|
||||
$obj->password = '';
|
||||
$DB->insert_record('badge_backpack', $obj);
|
||||
|
||||
redirect(new moodle_url('/badges/mybackpack.php'));
|
||||
// The form may have been submitted under one of the following circumstances:
|
||||
// 1. After clicking 'Connect to backpack'. We'll have $data->email.
|
||||
// 2. After clicking 'Resend verification email'. We'll have $data->email.
|
||||
// 3. After clicking 'Connect using a different email' to cancel the verification process. We'll have $data->revertbutton.
|
||||
if (isset($data->revertbutton)) {
|
||||
unset_user_preference('badges_email_verify_secret');
|
||||
unset_user_preference('badges_email_verify_address');
|
||||
redirect(new moodle_url('/badges/mybackpack.php'));
|
||||
} else if (isset($data->email)) {
|
||||
if (send_verification_email($data->email)) {
|
||||
redirect(new moodle_url('/badges/mybackpack.php'),
|
||||
get_string('backpackemailverifypending', 'badges', $data->email),
|
||||
null, \core\output\notification::NOTIFY_INFO);
|
||||
} else {
|
||||
print_error ('backpackcannotsendverification', 'badges');
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@core @core_badges @_file_upload
|
||||
@core @core_badges
|
||||
Feature: Add badges to the system
|
||||
In order to give badges to users for their achievements
|
||||
As an admin
|
||||
@@ -27,7 +27,7 @@ Feature: Add badges to the system
|
||||
Given I navigate to "Site badges" node in "Site pages"
|
||||
Then I should see "There are no badges available."
|
||||
|
||||
@javascript
|
||||
@javascript @_file_upload
|
||||
Scenario: Add a badge
|
||||
Given I navigate to "Add a new badge" node in "Site administration > Badges"
|
||||
And I set the following fields to these values:
|
||||
|
||||
@@ -682,7 +682,7 @@ class block_activity_results extends block_base {
|
||||
|
||||
$o = html_writer::start_tag('h3');
|
||||
$o .= html_writer::link(new moodle_url('/mod/'.$activity->itemmodule.'/view.php',
|
||||
array('id' => $cm->id)), $activity->itemname);
|
||||
array('id' => $cm->id)), format_string(($activity->itemname), true, ['context' => context_module::instance($cm->id)]));
|
||||
$o .= html_writer::end_tag('h3');
|
||||
return $o;
|
||||
}
|
||||
@@ -699,4 +699,4 @@ class block_activity_results extends block_base {
|
||||
return $scale;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -153,7 +153,8 @@ class block_community_renderer extends plugin_renderer_base {
|
||||
array('class' => 'hubcourseuserinfo'));
|
||||
|
||||
//create course content related information html
|
||||
$course->subject = get_string($course->subject, 'edufields');
|
||||
$course->subject = (get_string_manager()->string_exists($course->subject, 'edufields')) ?
|
||||
get_string($course->subject, 'edufields') : get_string('none');
|
||||
$course->audience = get_string('audience' . $course->audience, 'hub');
|
||||
$course->educationallevel = get_string('edulevel' . $course->educationallevel, 'hub');
|
||||
$coursecontentinfo = '';
|
||||
|
||||
@@ -64,7 +64,7 @@ class block_course_overview extends block_base {
|
||||
$content = array();
|
||||
|
||||
$updatemynumber = optional_param('mynumber', -1, PARAM_INT);
|
||||
if ($updatemynumber >= 0) {
|
||||
if ($updatemynumber >= 0 && optional_param('sesskey', '', PARAM_RAW) && confirm_sesskey()) {
|
||||
block_course_overview_update_mynumber($updatemynumber);
|
||||
}
|
||||
|
||||
|
||||
@@ -213,7 +213,7 @@ class block_course_overview_renderer extends plugin_renderer_base {
|
||||
for ($i = 1; $i <= $max; $i++) {
|
||||
$options[$i] = $i;
|
||||
}
|
||||
$url = new moodle_url('/my/index.php');
|
||||
$url = new moodle_url('/my/index.php', ['sesskey' => sesskey()]);
|
||||
$select = new single_select($url, 'mynumber', $options, block_course_overview_get_max_user_courses(), array());
|
||||
$select->set_label(get_string('numtodisplay', 'block_course_overview'));
|
||||
$output .= $this->output->render($select);
|
||||
|
||||
@@ -52,11 +52,11 @@ $action = (empty($id)) ? 'add' : 'edit';
|
||||
|
||||
$external = new stdClass();
|
||||
|
||||
// Check that this id exists.
|
||||
if (!empty($id) && !$DB->record_exists('blog_external', array('id' => $id))) {
|
||||
print_error('wrongexternalid', 'blog');
|
||||
} else if (!empty($id)) {
|
||||
$external = $DB->get_record('blog_external', array('id' => $id));
|
||||
// Retrieve the external blog record.
|
||||
if (!empty($id)) {
|
||||
if (!$external = $DB->get_record('blog_external', array('id' => $id, 'userid' => $USER->id))) {
|
||||
print_error('wrongexternalid', 'blog');
|
||||
}
|
||||
$external->autotags = core_tag_tag::get_item_tags_array('core', 'blog_external', $id);
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -872,7 +872,7 @@ function blog_get_headers($courseid=null, $groupid=null, $userid=null, $tagid=nu
|
||||
}
|
||||
|
||||
// Append Search info.
|
||||
if (!empty($search)) {
|
||||
if (!empty($search) && has_capability('moodle/blog:search', $sitecontext)) {
|
||||
$headers['filters']['search'] = $search;
|
||||
$blogurl->param('search', $search);
|
||||
$PAGE->navbar->add(get_string('searchterm', 'blog', $search), $blogurl->out());
|
||||
|
||||
Vendored
+54
-2
@@ -229,8 +229,60 @@ class cachestore_memcached extends cache_store implements cache_is_configurable
|
||||
$version = phpversion('memcached');
|
||||
$this->candeletemulti = ($version && version_compare($version, self::REQUIRED_VERSION, '>='));
|
||||
|
||||
// Test the connection to the main connection.
|
||||
$this->isready = @$this->connection->set("ping", 'ping', 1);
|
||||
$this->isready = $this->is_connection_ready();
|
||||
}
|
||||
|
||||
/**
|
||||
* Confirm whether the connection is ready and usable.
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function is_connection_ready() {
|
||||
if (!@$this->connection->set("ping", 'ping', 1)) {
|
||||
// Test the connection to the server.
|
||||
return false;
|
||||
}
|
||||
|
||||
if ($this->isshared) {
|
||||
// There is a bug in libmemcached which means that it is not possible to purge the cache in a shared cache
|
||||
// configuration.
|
||||
// This issue currently affects:
|
||||
// - memcached 1.4.23+ with php-memcached <= 2.2.0
|
||||
// The following combinations are not affected:
|
||||
// - memcached <= 1.4.22 with any version of php-memcached
|
||||
// - any version of memcached with php-memcached >= 3.0.1
|
||||
|
||||
|
||||
// This check is cheapest as it does not involve connecting to the server at all.
|
||||
$safecombination = false;
|
||||
$extension = new ReflectionExtension('memcached');
|
||||
if ((version_compare($extension->getVersion(), '3.0.1') >= 0)) {
|
||||
// This is php-memcached version >= 3.0.1 which is a safe combination.
|
||||
$safecombination = true;
|
||||
}
|
||||
|
||||
if (!$safecombination) {
|
||||
$allsafe = true;
|
||||
foreach ($this->connection->getVersion() as $version) {
|
||||
$allsafe = $allsafe && (version_compare($version, '1.4.22') <= 0);
|
||||
}
|
||||
// All memcached servers connected are version <= 1.4.22 which is a safe combination.
|
||||
$safecombination = $allsafe;
|
||||
}
|
||||
|
||||
if (!$safecombination) {
|
||||
// This is memcached 1.4.23+ and php-memcached < 3.0.1.
|
||||
// The issue may have been resolved in a subsequent update to any of the three libraries.
|
||||
// The only way to safely determine if the combination is safe is to call getAllKeys.
|
||||
// A safe combination will return an array, whilst an affected combination will return false.
|
||||
// This is the most expensive check.
|
||||
if (!is_array($this->connection->getAllKeys())) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -288,6 +288,10 @@ class cachestore_memcached_test extends cachestore_tests {
|
||||
|
||||
$definition = cache_definition::load_adhoc(cache_store::MODE_APPLICATION, 'cachestore_memcached', 'phpunit_test');
|
||||
$cachestore = $this->create_test_cache_with_config($definition, array('isshared' => true));
|
||||
if (!$cachestore->is_connection_ready()) {
|
||||
$this->markTestSkipped('Could not test cachestore_memcached. Connection is not ready.');
|
||||
}
|
||||
|
||||
$connection = new Memcached(crc32(__METHOD__));
|
||||
$connection->addServers($this->get_servers(TEST_CACHESTORE_MEMCACHED_TESTSERVERS));
|
||||
$connection->setOptions(array(
|
||||
|
||||
Vendored
+14
@@ -288,6 +288,20 @@ class cache_config_testing extends cache_config_writer {
|
||||
global $CFG;
|
||||
return $CFG->wwwroot.'phpunit';
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the configuration file exists.
|
||||
*
|
||||
* @return bool True if it exists
|
||||
*/
|
||||
public static function config_file_exists() {
|
||||
// Allow for late static binding by using static.
|
||||
$configfilepath = static::get_config_file_path();
|
||||
|
||||
// Invalidate opcode php cache, so we get correct status of file.
|
||||
core_component::invalidate_opcode_php_cache($configfilepath);
|
||||
return file_exists($configfilepath);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
+1024
-338
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -1,537 +0,0 @@
|
||||
<?php
|
||||
// This file is part of Moodle - http://moodle.org/
|
||||
//
|
||||
// Moodle is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// Moodle is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/**
|
||||
* Defines test class to test manage rrule during ical imports.
|
||||
*
|
||||
* @package core_calendar
|
||||
* @category test
|
||||
* @copyright 2014 onwards Ankit Agarwal <ankit.agrr@gmail.com>
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
class core_calendar_rrule_manager_testcase extends advanced_testcase {
|
||||
|
||||
/** @var stdClass a dummy event */
|
||||
protected $event;
|
||||
|
||||
/**
|
||||
* Set up method.
|
||||
*/
|
||||
protected function setUp() {
|
||||
global $DB, $CFG;
|
||||
$this->resetAfterTest();
|
||||
|
||||
$this->setTimezone('Australia/Perth');
|
||||
|
||||
$user = $this->getDataGenerator()->create_user();
|
||||
$sub = new stdClass();
|
||||
$sub->url = '';
|
||||
$sub->courseid = 0;
|
||||
$sub->groupid = 0;
|
||||
$sub->userid = $user->id;
|
||||
$sub->pollinterval = 0;
|
||||
$subid = $DB->insert_record('event_subscriptions', $sub, true);
|
||||
|
||||
$event = new stdClass();
|
||||
$event->name = 'Event name';
|
||||
$event->description = '';
|
||||
$event->timestart = 1385913700; // A 2013-12-2 Monday event.
|
||||
$event->timeduration = 3600;
|
||||
$event->uuid = 'uuid';
|
||||
$event->subscriptionid = $subid;
|
||||
$event->userid = $user->id;
|
||||
$event->groupid = 0;
|
||||
$event->courseid = 0;
|
||||
$event->eventtype = 'user';
|
||||
$eventobj = calendar_event::create($event, false);
|
||||
$DB->set_field('event', 'repeatid', $eventobj->id, array('id' => $eventobj->id));
|
||||
$eventobj->repeatid = $eventobj->id;
|
||||
$this->event = $eventobj;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test parse_rrule() method.
|
||||
*/
|
||||
public function test_parse_rrule() {
|
||||
|
||||
$rrule = "FREQ=DAILY;COUNT=3;INTERVAL=4;BYSECOND=20,40;BYMINUTE=2,30;BYHOUR=3,4;BYDAY=MO,TH;BYMONTHDAY=20,
|
||||
30;BYYEARDAY=300,-20;BYWEEKNO=22,33;BYMONTH=3,4";
|
||||
$mang = new core_tests_calendar_rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$this->assertEquals(\core_calendar\rrule_manager::FREQ_DAILY, $mang->freq);
|
||||
$this->assertEquals(3, $mang->count);
|
||||
$this->assertEquals(4, $mang->interval);
|
||||
$this->assertEquals(array(20, 40), $mang->bysecond);
|
||||
$this->assertEquals(array(2, 30), $mang->byminute);
|
||||
$this->assertEquals(array(3, 4), $mang->byhour);
|
||||
$this->assertEquals(array('MO', 'TH'), $mang->byday);
|
||||
$this->assertEquals(array(20, 30), $mang->bymonthday);
|
||||
$this->assertEquals(array(300, -20), $mang->byyearday);
|
||||
$this->assertEquals(array(22, 33), $mang->byweekno);
|
||||
$this->assertEquals(array(3, 4), $mang->bymonth);
|
||||
}
|
||||
|
||||
/**
|
||||
* Test exception is thrown for invalid property.
|
||||
*
|
||||
* @expectedException moodle_exception
|
||||
*/
|
||||
public function test_parse_rrule_validation() {
|
||||
|
||||
$rrule = "RANDOM=PROPERTY;";
|
||||
$mang = new core_tests_calendar_rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
}
|
||||
|
||||
/**
|
||||
* Test exception is thrown for invalid frequency.
|
||||
*
|
||||
* @expectedException moodle_exception
|
||||
*/
|
||||
public function test_freq_validation() {
|
||||
|
||||
$rrule = "FREQ=RANDOMLY;";
|
||||
$mang = new core_tests_calendar_rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
}
|
||||
|
||||
/**
|
||||
* Test recurrence rules for daily frequency.
|
||||
*/
|
||||
public function test_daily_events() {
|
||||
global $DB;
|
||||
|
||||
$rrule = 'FREQ=DAILY;COUNT=3'; // This should generate 2 child events + 1 parent.
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(3, $count);
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($this->event->timestart + DAYSECS)));
|
||||
$this->assertTrue($result);
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($this->event->timestart + 2 * DAYSECS)));
|
||||
$this->assertTrue($result);
|
||||
|
||||
$until = $this->event->timestart + DAYSECS * 2;
|
||||
$until = date('Y-m-d', $until);
|
||||
$rrule = "FREQ=DAILY;UNTIL=$until"; // This should generate 1 child event + 1 parent,since by then until bound would be hit.
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(2, $count);
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($this->event->timestart + DAYSECS)));
|
||||
$this->assertTrue($result);
|
||||
|
||||
$rrule = 'FREQ=DAILY;COUNT=3;INTERVAL=3'; // This should generate 2 child events + 1 parent, every 3rd day.
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(3, $count);
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($this->event->timestart + 3 * DAYSECS)));
|
||||
$this->assertTrue($result);
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($this->event->timestart + 6 * DAYSECS)));
|
||||
$this->assertTrue($result);
|
||||
|
||||
// Forever event. This should generate events for time() + 10 year period, every 300th day.
|
||||
$rrule = 'FREQ=DAILY;INTERVAL=300';
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$until = time() + (YEARSECS * $mang::TIME_UNLIMITED_YEARS);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
for ($i = 0, $time = $this->event->timestart; $time < $until; $i++, $time = $this->event->timestart + 300 * DAYSECS * $i) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($time)));
|
||||
$this->assertTrue($result);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Test recurrence rules for weekly frequency.
|
||||
*/
|
||||
public function test_weekly_events() {
|
||||
global $DB;
|
||||
|
||||
$rrule = 'FREQ=WEEKLY;COUNT=1'; // This should generate 7 events in total, one for each day.
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(7, $count);
|
||||
for ($i = 0; $i < 7; $i++) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($this->event->timestart + $i * DAYSECS)));
|
||||
$this->assertTrue($result);
|
||||
}
|
||||
|
||||
// This should generate 4 child event + 1 parent, since by then until bound would be hit.
|
||||
$until = $this->event->timestart + WEEKSECS * 4;
|
||||
$until = date('YmdThis', $until);
|
||||
$rrule = "FREQ=WEEKLY;BYDAY=MO;UNTIL=$until";
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(5, $count);
|
||||
for ($i = 0; $i < 5; $i++) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($this->event->timestart + $i * WEEKSECS)));
|
||||
$this->assertTrue($result);
|
||||
}
|
||||
|
||||
// This should generate 4 events in total every monday and Wednesday of every 3rd week.
|
||||
$rrule = 'FREQ=WEEKLY;INTERVAL=3;BYDAY=MO,WE;COUNT=2';
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(4, $count);
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($this->event->timestart + 3 * WEEKSECS))); // Monday event.
|
||||
$this->assertTrue($result);
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($this->event->timestart + 2 * DAYSECS))); // Wednesday event.
|
||||
$this->assertTrue($result);
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($this->event->timestart + 3 * WEEKSECS + 2 * DAYSECS))); // Wednesday event.
|
||||
$this->assertTrue($result);
|
||||
|
||||
// Forever event. This should generate events over time() + 10 year period, every 50th monday.
|
||||
$rrule = 'FREQ=WEEKLY;BYDAY=MO;INTERVAL=50';
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$until = time() + (YEARSECS * $mang::TIME_UNLIMITED_YEARS);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
for ($i = 0, $time = $this->event->timestart; $time < $until; $i++, $time = $this->event->timestart + 50 * WEEKSECS * $i) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($time)));
|
||||
$this->assertTrue($result);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Test recurrence rules for monthly frequency.
|
||||
*/
|
||||
public function test_monthly_events() {
|
||||
global $DB;
|
||||
$rrule = 'FREQ=MONTHLY;COUNT=3;BYMONTHDAY=2'; // This should generate 3 events in total.
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(3, $count);
|
||||
for ($i = 0; $i < 3; $i++) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => (strtotime("+$i month", $this->event->timestart))));
|
||||
$this->assertTrue($result);
|
||||
}
|
||||
|
||||
// This much seconds after the start of the day.
|
||||
$offset = $this->event->timestart - mktime(0, 0, 0, date("n", $this->event->timestart), date("j", $this->event->timestart),
|
||||
date("Y", $this->event->timestart));
|
||||
$monthstart = mktime(0, 0, 0, date("n", $this->event->timestart), 1, date("Y", $this->event->timestart));
|
||||
|
||||
$rrule = 'FREQ=MONTHLY;COUNT=3;BYDAY=1MO'; // This should generate 3 events in total, first monday of the month.
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(3, $count);
|
||||
$time = strtotime('1 Monday', strtotime("+1 months", $monthstart)) + $offset;
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id, 'timestart' => $time));
|
||||
$this->assertTrue($result);
|
||||
$time = strtotime('1 Monday', strtotime("+2 months", $monthstart)) + $offset;
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id, 'timestart' => $time));
|
||||
$this->assertTrue($result);
|
||||
|
||||
// This should generate 10 child event + 1 parent, since by then until bound would be hit.
|
||||
$until = strtotime('+1 day +10 months', $this->event->timestart);
|
||||
$until = date('YmdThis', $until);
|
||||
$rrule = "FREQ=MONTHLY;BYMONTHDAY=2;UNTIL=$until";
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(11, $count);
|
||||
for ($i = 0; $i < 11; $i++) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => (strtotime("+$i month", $this->event->timestart))));
|
||||
$this->assertTrue($result);
|
||||
}
|
||||
|
||||
// This should generate 10 child event + 1 parent, since by then until bound would be hit.
|
||||
$until = strtotime('+1 day +10 months', $this->event->timestart);
|
||||
$until = date('YmdThis', $until);
|
||||
$rrule = "FREQ=MONTHLY;BYDAY=1MO;UNTIL=$until";
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(10, $count);
|
||||
for ($i = 0; $i < 10; $i++) {
|
||||
$time = strtotime('1 Monday', strtotime("+$i months", $monthstart)) + $offset;
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id, 'timestart' => $time));
|
||||
$this->assertTrue($result);
|
||||
}
|
||||
|
||||
// This should generate 11 child event + 1 parent, since by then until bound would be hit.
|
||||
$until = strtotime('+10 day +10 months', $this->event->timestart); // 12 oct 2014.
|
||||
$until = date('YmdThis', $until);
|
||||
$rrule = "FREQ=MONTHLY;INTERVAL=2;BYMONTHDAY=2,5;UNTIL=$until";
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(12, $count);
|
||||
for ($i = 0; $i < 6; $i++) {
|
||||
$moffset = $i * 2;
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => (strtotime("+$moffset month", $this->event->timestart))));
|
||||
$this->assertTrue($result);
|
||||
// Event on the 5th of a month.
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => (strtotime("+3 days +$moffset month", $this->event->timestart))));
|
||||
$this->assertTrue($result);
|
||||
}
|
||||
|
||||
// This should generate 11 child event + 1 parent, since by then until bound would be hit.
|
||||
$until = strtotime('+20 day +10 months', $this->event->timestart); // 22 oct 2014.
|
||||
$until = date('YmdTHis', $until);
|
||||
$rrule = "FREQ=MONTHLY;INTERVAL=2;BYDAY=1MO,3WE;UNTIL=$until";
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(12, $count);
|
||||
for ($i = 0; $i < 6; $i++) {
|
||||
$moffset = $i * 2;
|
||||
$time = strtotime("+$moffset month", $monthstart);
|
||||
$time2 = strtotime("+1 Monday", $time) + $offset;
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id, 'timestart' => $time2));
|
||||
$this->assertTrue($result);
|
||||
$time2 = strtotime("+3 Wednesday", $time) + $offset;
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => $time2)); // Event on the 5th of a month.
|
||||
$this->assertTrue($result);
|
||||
}
|
||||
|
||||
// Forever event. This should generate events over 10 year period, on 2nd of every 12th month.
|
||||
$rrule = 'FREQ=MONTHLY;INTERVAL=12;BYMONTHDAY=2';
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$until = time() + (YEARSECS * $mang::TIME_UNLIMITED_YEARS);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
for ($i = 0, $time = $this->event->timestart; $time < $until; $i++, $moffset = $i * 12,
|
||||
$time = strtotime("+$moffset month", $this->event->timestart)) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($time)));
|
||||
$this->assertTrue($result);
|
||||
}
|
||||
|
||||
// Forever event. This should generate 10 child events + 1 parent over 10 year period, every 50th Monday.
|
||||
$rrule = 'FREQ=MONTHLY;BYDAY=1MO;INTERVAL=12';
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$until = time() + (YEARSECS * $mang::TIME_UNLIMITED_YEARS);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(11, $count);
|
||||
for ($i = 0, $moffset = 0, $time = $this->event->timestart; $time < $until; $i++, $moffset = $i * 12) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id, 'timestart' => ($time)));
|
||||
$this->assertTrue($result);
|
||||
$time = strtotime("+$moffset month", $monthstart);
|
||||
$time = strtotime("+1 Monday", $time) + $offset;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Test recurrence rules for yearly frequency.
|
||||
*/
|
||||
public function test_yearly_events() {
|
||||
global $DB;
|
||||
|
||||
$rrule = 'FREQ=YEARLY;COUNT=3;BYMONTH=12'; // This should generate 3 events in total.
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(3, $count);
|
||||
for ($i = 0, $time = $this->event->timestart; $i < 3; $i++, $time = strtotime("+$i years", $this->event->timestart)) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id, 'timestart' => $time));
|
||||
$this->assertTrue($result);
|
||||
}
|
||||
|
||||
// Create an event every december, until the time limit is hit.
|
||||
$until = strtotime('+20 day +10 years', $this->event->timestart);
|
||||
$until = date('YmdTHis', $until);
|
||||
$rrule = "FREQ=YEARLY;BYMONTH=12;UNTIL=$until"; // Forever event.
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$until = time() + (YEARSECS * $mang::TIME_UNLIMITED_YEARS);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(11, $count);
|
||||
for ($i = 0, $time = $this->event->timestart; $time < $until; $i++, $yoffset = $i * 2,
|
||||
$time = strtotime("+$yoffset years", $this->event->timestart)) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($time)));
|
||||
$this->assertTrue($result);
|
||||
}
|
||||
|
||||
// This should generate 5 events in total, every second year in the month of december.
|
||||
$rrule = 'FREQ=YEARLY;BYMONTH=12;INTERVAL=2;COUNT=5';
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(5, $count);
|
||||
for ($i = 0, $time = $this->event->timestart; $i < 5; $i++, $yoffset = $i * 2,
|
||||
$time = strtotime("+$yoffset years", $this->event->timestart)) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($time)));
|
||||
$this->assertTrue($result);
|
||||
}
|
||||
|
||||
$rrule = 'FREQ=YEARLY;BYMONTH=12;INTERVAL=2'; // Forever event.
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$until = time() + (YEARSECS * $mang::TIME_UNLIMITED_YEARS);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(6, $count);
|
||||
for ($i = 0, $time = $this->event->timestart; $time < $until; $i++, $yoffset = $i * 2,
|
||||
$time = strtotime("+$yoffset years", $this->event->timestart)) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($time)));
|
||||
$this->assertTrue($result);
|
||||
}
|
||||
|
||||
// This much seconds after the start of the day.
|
||||
$offset = $this->event->timestart - mktime(0, 0, 0, date("n", $this->event->timestart), date("j", $this->event->timestart),
|
||||
date("Y", $this->event->timestart));
|
||||
$yearstart = mktime(0, 0, 0, 1, 1, date("Y", $this->event->timestart));
|
||||
|
||||
$rrule = 'FREQ=YEARLY;COUNT=3;BYMONTH=12;BYDAY=1MO'; // This should generate 3 events in total.
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(3, $count);
|
||||
for ($i = 0; $i < 3; $i++) {
|
||||
$time = strtotime("+11 months +$i years", $yearstart);
|
||||
$time = strtotime("+1 Monday", $time) + $offset;
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id, 'timestart' => $time));
|
||||
$this->assertTrue($result);
|
||||
}
|
||||
|
||||
// Create an event every december, until the time limit is hit.
|
||||
$until = strtotime('+20 day +10 years', $this->event->timestart);
|
||||
$until = date('YmdTHis', $until);
|
||||
$rrule = "FREQ=YEARLY;BYMONTH=12;UNTIL=$until;BYDAY=1MO";
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$until = time() + (YEARSECS * $mang::TIME_UNLIMITED_YEARS);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(11, $count);
|
||||
for ($i = 0, $time = $this->event->timestart; $time < $until; $i++) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($time)));
|
||||
$this->assertTrue($result);
|
||||
$time = strtotime("+11 months +$i years", $yearstart);
|
||||
$time = strtotime("+1 Monday", $time) + $offset;
|
||||
}
|
||||
|
||||
// This should generate 5 events in total, every second year in the month of december.
|
||||
$rrule = 'FREQ=YEARLY;BYMONTH=12;INTERVAL=2;COUNT=5;BYDAY=1MO';
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(5, $count);
|
||||
for ($i = $yoffset = 0, $time = $this->event->timestart; $i < 5; $i++, $yoffset = $i * 2) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($time)));
|
||||
$this->assertTrue($result);
|
||||
$time = strtotime("+11 months +$yoffset years", $yearstart);
|
||||
$time = strtotime("+1 Monday", $time) + $offset;
|
||||
}
|
||||
|
||||
$rrule = 'FREQ=YEARLY;BYMONTH=12;INTERVAL=2;BYDAY=1MO'; // Forever event.
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$until = time() + (YEARSECS * $mang::TIME_UNLIMITED_YEARS);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(6, $count);
|
||||
for ($i = 0, $time = $this->event->timestart; $time < $until; $i++, $yoffset = $i * 2) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($time)));
|
||||
$this->assertTrue($result);
|
||||
$time = strtotime("+11 months +$yoffset years", $yearstart);
|
||||
$time = strtotime("+1 Monday", $time) + $offset;
|
||||
}
|
||||
|
||||
$rrule = 'FREQ=YEARLY;INTERVAL=2'; // Forever event.
|
||||
$mang = new \core_calendar\rrule_manager($rrule);
|
||||
$until = time() + (YEARSECS * $mang::TIME_UNLIMITED_YEARS);
|
||||
$mang->parse_rrule();
|
||||
$mang->create_events($this->event);
|
||||
$count = $DB->count_records('event', array('repeatid' => $this->event->id));
|
||||
$this->assertEquals(6, $count);
|
||||
for ($i = 0, $time = $this->event->timestart; $time < $until; $i++, $yoffset = $i * 2) {
|
||||
$result = $DB->record_exists('event', array('repeatid' => $this->event->id,
|
||||
'timestart' => ($time)));
|
||||
$this->assertTrue($result);
|
||||
$time = strtotime("+11 months +$yoffset years", $yearstart);
|
||||
$time = strtotime("+1 Monday", $time) + $offset;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Class core_calendar_test_rrule_manager
|
||||
*
|
||||
* Wrapper to access protected vars for testing.
|
||||
*
|
||||
* @package core_calendar
|
||||
* @category test
|
||||
* @copyright 2014 onwards Ankit Agarwal <ankit.agrr@gmail.com>
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
class core_tests_calendar_rrule_manager extends \core_calendar\rrule_manager{
|
||||
|
||||
/**
|
||||
* Magic method to get properties.
|
||||
*
|
||||
* @param $prop string property
|
||||
*
|
||||
* @return mixed
|
||||
* @throws coding_exception
|
||||
*/
|
||||
public function __get($prop) {
|
||||
if (property_exists($this, $prop)) {
|
||||
return $this->$prop;
|
||||
}
|
||||
throw new coding_exception('invalidproperty');
|
||||
}
|
||||
}
|
||||
@@ -676,7 +676,8 @@ class competency extends persistent {
|
||||
public static function share_same_framework(array $ids) {
|
||||
global $DB;
|
||||
list($insql, $params) = $DB->get_in_or_equal($ids);
|
||||
return $DB->count_records_select(self::TABLE, "id $insql", $params, "COUNT(DISTINCT(competencyframeworkid))") == 1;
|
||||
$sql = "SELECT COUNT('x') FROM (SELECT DISTINCT(competencyframeworkid) FROM {" . self::TABLE . "} WHERE id {$insql}) f";
|
||||
return $DB->count_records_sql($sql, $params) == 1;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -84,13 +84,17 @@ class completion_criteria_activity extends completion_criteria {
|
||||
|
||||
$this->course = $data->id;
|
||||
|
||||
foreach (array_keys($data->criteria_activity) as $activity) {
|
||||
|
||||
$module = $DB->get_record('course_modules', array('id' => $activity));
|
||||
$this->module = self::get_mod_name($module->module);
|
||||
$this->moduleinstance = $activity;
|
||||
$this->id = NULL;
|
||||
$this->insert();
|
||||
// Data comes from advcheckbox, so contains keys for all activities.
|
||||
// A value of 0 is 'not checked' whereas 1 is 'checked'.
|
||||
foreach ($data->criteria_activity as $activity => $val) {
|
||||
// Only update those which are checked.
|
||||
if (!empty($val)) {
|
||||
$module = $DB->get_record('course_modules', array('id' => $activity));
|
||||
$this->module = self::get_mod_name($module->module);
|
||||
$this->moduleinstance = $activity;
|
||||
$this->id = null;
|
||||
$this->insert();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+9
-13
@@ -217,6 +217,12 @@ class course_edit_form extends moodleform {
|
||||
$mform->addElement('select', 'calendartype', get_string('forcecalendartype', 'calendar'), $calendars);
|
||||
}
|
||||
|
||||
$options = range(0, 10);
|
||||
$mform->addElement('select', 'newsitems', get_string('newsitemsnumber'), $options);
|
||||
$courseconfig = get_config('moodlecourse');
|
||||
$mform->setDefault('newsitems', $courseconfig->newsitems);
|
||||
$mform->addHelpButton('newsitems', 'newsitemsnumber');
|
||||
|
||||
$mform->addElement('selectyesno', 'showgrades', get_string('showgrades'));
|
||||
$mform->addHelpButton('showgrades', 'showgrades');
|
||||
$mform->setDefault('showgrades', $courseconfig->showgrades);
|
||||
@@ -368,19 +374,9 @@ class course_edit_form extends moodleform {
|
||||
'addcourseformatoptionshere');
|
||||
}
|
||||
|
||||
if ($courseformat->supports_news()) {
|
||||
// Show the news items select field if the course format supports news.
|
||||
$options = range(0, 10);
|
||||
$newsitems = $mform->createElement('select', 'newsitems', get_string('newsitemsnumber'), $options);
|
||||
$mform->insertElementBefore($newsitems, 'showgrades');
|
||||
$courseconfig = get_config('moodlecourse');
|
||||
$mform->setDefault('newsitems', $courseconfig->newsitems);
|
||||
$mform->addHelpButton('newsitems', 'newsitemsnumber');
|
||||
} else {
|
||||
// Otherwise, create a hidden newsitems element and set its value to 0.
|
||||
$newsitems = $mform->addElement('hidden', 'newsitems', 0);
|
||||
$mform->setType('newsitems', PARAM_INT);
|
||||
$newsitems->setValue(0);
|
||||
// Remove newsitems element if format does not support news.
|
||||
if (!$courseformat->supports_news()) {
|
||||
$mform->removeElement('newsitems');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -433,7 +433,9 @@ class core_course_external extends external_api {
|
||||
$exceptionparam->courseid = $course->id;
|
||||
throw new moodle_exception('errorcoursecontextnotvalid', 'webservice', '', $exceptionparam);
|
||||
}
|
||||
require_capability('moodle/course:view', $context);
|
||||
if ($course->id != SITEID) {
|
||||
require_capability('moodle/course:view', $context);
|
||||
}
|
||||
|
||||
$courseinfo = array();
|
||||
$courseinfo['id'] = $course->id;
|
||||
|
||||
@@ -678,7 +678,9 @@ abstract class format_base {
|
||||
if (isset($option['type'])) {
|
||||
$mform->setType($optionname, $option['type']);
|
||||
}
|
||||
if (is_null($mform->getElementValue($optionname)) && isset($option['default'])) {
|
||||
if (isset($option['default']) && !array_key_exists($optionname, $mform->_defaultValues)) {
|
||||
// Set defaults for the elements in the form.
|
||||
// Since we call this method after set_data() make sure that we don't override what was already set.
|
||||
$mform->setDefault($optionname, $option['default']);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2433,6 +2433,14 @@ function update_course($data, $editoroptions = NULL) {
|
||||
}
|
||||
}
|
||||
|
||||
// Set newsitems to 0 if format does not support announcements.
|
||||
if (isset($data->format)) {
|
||||
$newcourseformat = course_get_format((object)['format' => $data->format]);
|
||||
if (!$newcourseformat->supports_news()) {
|
||||
$data->newsitems = 0;
|
||||
}
|
||||
}
|
||||
|
||||
// Update with the new data
|
||||
$DB->update_record('course', $data);
|
||||
// make sure the modinfo cache is reset
|
||||
|
||||
@@ -483,7 +483,7 @@ class core_course_externallib_testcase extends externallib_advanced_testcase {
|
||||
$this->assertEquals($courseinfo->numsections, $course3options['numsections']);
|
||||
$this->assertEquals($courseinfo->coursedisplay, $course3options['coursedisplay']);
|
||||
} else {
|
||||
throw moodle_exception('Unexpected shortname');
|
||||
throw new moodle_exception('Unexpected shortname');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -642,6 +642,32 @@ class core_course_externallib_testcase extends externallib_advanced_testcase {
|
||||
$this->assertEquals($DB->count_records('course'), count($courses));
|
||||
}
|
||||
|
||||
/**
|
||||
* Test get_courses without capability
|
||||
*/
|
||||
public function test_get_courses_without_capability() {
|
||||
$this->resetAfterTest(true);
|
||||
|
||||
$course1 = $this->getDataGenerator()->create_course();
|
||||
$this->setUser($this->getDataGenerator()->create_user());
|
||||
|
||||
// No permissions are required to get the site course.
|
||||
$courses = core_course_external::get_courses(array('ids' => [SITEID]));
|
||||
$courses = external_api::clean_returnvalue(core_course_external::get_courses_returns(), $courses);
|
||||
|
||||
$this->assertEquals(1, count($courses));
|
||||
$this->assertEquals('PHPUnit test site', $courses[0]['fullname']);
|
||||
$this->assertEquals('site', $courses[0]['format']);
|
||||
|
||||
// Requesting course without being enrolled or capability to view it will throw an exception.
|
||||
try {
|
||||
core_course_external::get_courses(array('ids' => [$course1->id]));
|
||||
$this->fail('Exception expected');
|
||||
} catch (moodle_exception $e) {
|
||||
$this->assertEquals(1, preg_match('/Course or activity not accessible. \(Not enrolled\)/', $e->getMessage()));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Test search_courses
|
||||
*/
|
||||
@@ -1137,7 +1163,7 @@ class core_course_externallib_testcase extends externallib_advanced_testcase {
|
||||
$this->assertEquals(0, $courseinfo->newsitems);
|
||||
$this->assertEquals(FORMAT_MOODLE, $courseinfo->summaryformat);
|
||||
} else {
|
||||
throw moodle_exception('Unexpected shortname');
|
||||
throw new moodle_exception('Unexpected shortname');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -661,6 +661,10 @@ DragDrop.prototype = {
|
||||
return false;
|
||||
}
|
||||
|
||||
while (contstraint.get('scrollHeight') === 0 && !contstraint.compareTo(window.document.body)) {
|
||||
contstraint = contstraint.get('parentNode');
|
||||
}
|
||||
|
||||
courseul.all('> li').each(function(li) {
|
||||
this.initCourseListing(li, contstraint);
|
||||
}, this);
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -654,6 +654,10 @@ DragDrop.prototype = {
|
||||
return false;
|
||||
}
|
||||
|
||||
while (contstraint.get('scrollHeight') === 0 && !contstraint.compareTo(window.document.body)) {
|
||||
contstraint = contstraint.get('parentNode');
|
||||
}
|
||||
|
||||
courseul.all('> li').each(function(li) {
|
||||
this.initCourseListing(li, contstraint);
|
||||
}, this);
|
||||
|
||||
Vendored
+4
@@ -69,6 +69,10 @@ DragDrop.prototype = {
|
||||
return false;
|
||||
}
|
||||
|
||||
while (contstraint.get('scrollHeight') === 0 && !contstraint.compareTo(window.document.body)) {
|
||||
contstraint = contstraint.get('parentNode');
|
||||
}
|
||||
|
||||
courseul.all('> li').each(function(li) {
|
||||
this.initCourseListing(li, contstraint);
|
||||
}, this);
|
||||
|
||||
@@ -62,8 +62,8 @@ $string['course_summary'] = 'Optional: LDAP attribute to get the summary from';
|
||||
$string['course_summary_key'] = 'Summary';
|
||||
$string['course_summary_updateonsync'] = 'Update summary during synchronisation script';
|
||||
$string['course_summary_updateonsync_key'] = 'Update summary';
|
||||
$string['createcourseextid'] = 'CREATE User enrolled to a nonexistant course \'{$a->courseextid}\'';
|
||||
$string['createnotcourseextid'] = 'User enrolled to a nonexistant course \'{$a->courseextid}\'';
|
||||
$string['createcourseextid'] = 'CREATE User enrolled to a non-existing course \'{$a->courseextid}\'';
|
||||
$string['createnotcourseextid'] = 'User enrolled to a non-existing course \'{$a->courseextid}\'';
|
||||
$string['creatingcourse'] = 'Creating course \'{$a}\'...';
|
||||
$string['duplicateshortname'] = "Course creation failed. Duplicate short name. Skipping course with idnumber '{\$a->idnumber}'...";
|
||||
$string['editlock'] = 'Lock value';
|
||||
|
||||
+1
-1
@@ -132,7 +132,7 @@ class enrol_ldap_plugin extends enrol_plugin {
|
||||
*/
|
||||
public function can_hide_show_instance($instance) {
|
||||
$context = context_course::instance($instance->courseid);
|
||||
return has_capability('enrol/ldap:config', $context);
|
||||
return has_capability('enrol/ldap:manage', $context);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -280,6 +280,62 @@ class core_enrollib_testcase extends advanced_testcase {
|
||||
$this->assertEquals($sharedcourse->id, $course1->id);
|
||||
}
|
||||
|
||||
public function test_enrol_get_shared_courses_different_methods() {
|
||||
global $DB, $CFG;
|
||||
|
||||
require_once($CFG->dirroot . '/enrol/self/externallib.php');
|
||||
|
||||
$this->resetAfterTest();
|
||||
|
||||
$user1 = $this->getDataGenerator()->create_user();
|
||||
$user2 = $this->getDataGenerator()->create_user();
|
||||
$user3 = $this->getDataGenerator()->create_user();
|
||||
|
||||
$course1 = $this->getDataGenerator()->create_course();
|
||||
|
||||
// Enrol user1 and user2 in course1 with a different enrolment methode.
|
||||
// Add self enrolment method for course1.
|
||||
$selfplugin = enrol_get_plugin('self');
|
||||
$this->assertNotEmpty($selfplugin);
|
||||
|
||||
$studentrole = $DB->get_record('role', array('shortname' => 'student'));
|
||||
$this->assertNotEmpty($studentrole);
|
||||
|
||||
$instance1id = $selfplugin->add_instance($course1, array('status' => ENROL_INSTANCE_ENABLED,
|
||||
'name' => 'Test instance 1',
|
||||
'customint6' => 1,
|
||||
'roleid' => $studentrole->id));
|
||||
|
||||
$instance1 = $DB->get_record('enrol', array('id' => $instance1id), '*', MUST_EXIST);
|
||||
|
||||
self::setUser($user2);
|
||||
// Self enrol me (user2).
|
||||
$result = enrol_self_external::enrol_user($course1->id);
|
||||
|
||||
// Enrol user1 manually.
|
||||
$this->getDataGenerator()->enrol_user($user1->id, $course1->id, null, 'manual');
|
||||
|
||||
$course2 = $this->getDataGenerator()->create_course();
|
||||
$this->getDataGenerator()->enrol_user($user1->id, $course2->id);
|
||||
|
||||
$course3 = $this->getDataGenerator()->create_course();
|
||||
$this->getDataGenerator()->enrol_user($user2->id, $course3->id);
|
||||
|
||||
// Test that user1 and user2 have courses in common.
|
||||
$this->assertTrue(enrol_get_shared_courses($user1, $user2, false, true));
|
||||
// Test that user1 and user3 have no courses in common.
|
||||
$this->assertFalse(enrol_get_shared_courses($user1, $user3, false, true));
|
||||
|
||||
// Test retrieving the courses in common.
|
||||
$sharedcourses = enrol_get_shared_courses($user1, $user2, true);
|
||||
|
||||
// Only should be one shared course.
|
||||
$this->assertCount(1, $sharedcourses);
|
||||
$sharedcourse = array_shift($sharedcourses);
|
||||
// It should be course 1.
|
||||
$this->assertEquals($sharedcourse->id, $course1->id);
|
||||
}
|
||||
|
||||
/**
|
||||
* Test user enrolment created event.
|
||||
*/
|
||||
@@ -422,4 +478,58 @@ class core_enrollib_testcase extends advanced_testcase {
|
||||
$this->assertEquals('self', $event->other['enrol']);
|
||||
$this->assertEventContextNotUsed($event);
|
||||
}
|
||||
|
||||
/**
|
||||
* Confirms that timemodified field was updated after modification of user enrollment
|
||||
*/
|
||||
public function test_enrollment_update_timemodified() {
|
||||
global $DB;
|
||||
|
||||
$this->resetAfterTest(true);
|
||||
$datagen = $this->getDataGenerator();
|
||||
|
||||
/** @var enrol_manual_plugin $manualplugin */
|
||||
$manualplugin = enrol_get_plugin('manual');
|
||||
$this->assertNotNull($manualplugin);
|
||||
|
||||
$studentroleid = $DB->get_field('role', 'id', ['shortname' => 'student'], MUST_EXIST);
|
||||
$course = $datagen->create_course();
|
||||
$user = $datagen->create_user();
|
||||
|
||||
$instanceid = null;
|
||||
$instances = enrol_get_instances($course->id, true);
|
||||
foreach ($instances as $inst) {
|
||||
if ($inst->enrol == 'manual') {
|
||||
$instanceid = (int)$inst->id;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (empty($instanceid)) {
|
||||
$instanceid = $manualplugin->add_default_instance($course);
|
||||
if (empty($instanceid)) {
|
||||
$instanceid = $manualplugin->add_instance($course);
|
||||
}
|
||||
}
|
||||
$this->assertNotNull($instanceid);
|
||||
|
||||
$instance = $DB->get_record('enrol', ['id' => $instanceid], '*', MUST_EXIST);
|
||||
$manualplugin->enrol_user($instance, $user->id, $studentroleid, 0, 0, ENROL_USER_ACTIVE);
|
||||
$userenrolorig = (int)$DB->get_field(
|
||||
'user_enrolments',
|
||||
'timemodified',
|
||||
['enrolid' => $instance->id, 'userid' => $user->id],
|
||||
MUST_EXIST
|
||||
);
|
||||
$this->waitForSecond();
|
||||
$this->waitForSecond();
|
||||
$manualplugin->update_user_enrol($instance, $user->id, ENROL_USER_SUSPENDED);
|
||||
$userenrolpost = (int)$DB->get_field(
|
||||
'user_enrolments',
|
||||
'timemodified',
|
||||
['enrolid' => $instance->id, 'userid' => $user->id],
|
||||
MUST_EXIST
|
||||
);
|
||||
|
||||
$this->assertGreaterThan($userenrolorig, $userenrolpost);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -33,6 +33,8 @@ function xmldb_filter_mathjaxloader_upgrade($oldversion) {
|
||||
|
||||
$dbman = $DB->get_manager();
|
||||
|
||||
require_once($CFG->dirroot . '/filter/mathjaxloader/db/upgradelib.php');
|
||||
|
||||
if ($oldversion < 2014081100) {
|
||||
|
||||
$sslcdnurl = get_config('filter_mathjaxloader', 'httpsurl');
|
||||
@@ -157,6 +159,42 @@ MathJax.Hub.Config({
|
||||
}
|
||||
// Automatically generated Moodle v3.2.0 release upgrade line.
|
||||
// Put any upgrade step following this.
|
||||
if ($oldversion < 2016120501) {
|
||||
$httpsurl = get_config('filter_mathjaxloader', 'httpsurl');
|
||||
$newcdnurl = filter_mathjaxloader_upgrade_cdn_cloudflare($httpsurl, false);
|
||||
|
||||
set_config('httpsurl', $newcdnurl, 'filter_mathjaxloader');
|
||||
|
||||
$mathjaxconfig = get_config('filter_mathjaxloader', 'mathjaxconfig');
|
||||
if (strpos($mathjaxconfig, 'MathJax.Ajax.config.path') === false) {
|
||||
$newconfig = 'MathJax.Ajax.config.path["Contrib"] = "{wwwroot}/filter/mathjaxloader/contrib";' . "\n";
|
||||
$newconfig .= $mathjaxconfig;
|
||||
|
||||
set_config('mathjaxconfig', $newconfig, 'filter_mathjaxloader');
|
||||
}
|
||||
|
||||
upgrade_plugin_savepoint(true, 2016120501, 'filter', 'mathjaxloader');
|
||||
}
|
||||
if ($oldversion < 2016120502) {
|
||||
|
||||
$httpsurl = get_config('filter_mathjaxloader', 'httpsurl');
|
||||
if ($httpsurl === "https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js") {
|
||||
set_config('httpsurl', 'https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js', 'filter_mathjaxloader');
|
||||
}
|
||||
|
||||
$mathjaxconfig = get_config('filter_mathjaxloader', 'mathjaxconfig');
|
||||
|
||||
if (strpos($mathjaxconfig, 'MathJax.Ajax.config.path') !== false) {
|
||||
// Now we need to remove this config again because mathjax 2.7.1 supports the extensions on the CDN.
|
||||
$configtoremove = 'MathJax.Ajax.config.path["Contrib"] = "{wwwroot}/filter/mathjaxloader/contrib";';
|
||||
|
||||
$mathjaxconfig = str_replace($configtoremove, '', $mathjaxconfig);
|
||||
|
||||
set_config('mathjaxconfig', $mathjaxconfig, 'filter_mathjaxloader');
|
||||
}
|
||||
|
||||
upgrade_plugin_savepoint(true, 2016120502, 'filter', 'mathjaxloader');
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,66 @@
|
||||
<?php
|
||||
// This file is part of Moodle - http://moodle.org/
|
||||
//
|
||||
// Moodle is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// Moodle is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/**
|
||||
* Random functions for mathjax upgrades.
|
||||
*
|
||||
* @package filter_mathjaxloader
|
||||
* @copyright 2017 Damyon Wiese (damyon@moodle.com)
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
/**
|
||||
* This function takes an existing mathjax url and, if it was using the standard mathjax cdn,
|
||||
* upgrades it to use the cloudflare matchjax cdn (because the standard one is shutting down).
|
||||
* @param string $mathjaxurl - The current url.
|
||||
* @param boolean $httponly - Use http instead of https - really only for 3.1 upgrades.
|
||||
* @return string The new url.
|
||||
*/
|
||||
function filter_mathjaxloader_upgrade_cdn_cloudflare($mathjaxurl, $httponly = false) {
|
||||
$newcdnurl = $mathjaxurl;
|
||||
$cdnroot = 'https://cdn.mathjax.org/mathjax/';
|
||||
if ($httponly) {
|
||||
$cdnroot = 'http://cdn.mathjax.org/mathjax/';
|
||||
}
|
||||
$usingcdn = strpos($mathjaxurl, $cdnroot) === 0;
|
||||
if ($usingcdn) {
|
||||
$majorversion = substr($mathjaxurl, strlen($cdnroot), 3);
|
||||
$latestversion = '2.7.0';
|
||||
if ($majorversion == '2.6') {
|
||||
$latestversion = '2.6.1';
|
||||
} else if ($majorversion == '2.5') {
|
||||
$latestversion = '2.5.3';
|
||||
}
|
||||
|
||||
$offset = strpos($mathjaxurl, '/', strlen($cdnroot));
|
||||
if ($offset === false) {
|
||||
return $newcdnurl;
|
||||
}
|
||||
|
||||
$endofurl = substr($mathjaxurl, $offset + 1);
|
||||
|
||||
$newcdnbase = 'https://cdnjs.cloudflare.com/ajax/libs/mathjax/';
|
||||
if ($httponly) {
|
||||
$newcdnbase = 'http://cdnjs.cloudflare.com/ajax/libs/mathjax/';
|
||||
}
|
||||
|
||||
$newcdnurl = $newcdnbase . $latestversion . '/' . $endofurl;
|
||||
}
|
||||
|
||||
return $newcdnurl;
|
||||
}
|
||||
@@ -111,6 +111,9 @@ class filter_mathjaxloader extends moodle_text_filter {
|
||||
$page->requires->js_module($moduleconfig);
|
||||
|
||||
$config = get_config('filter_mathjaxloader', 'mathjaxconfig');
|
||||
$wwwroot = new moodle_url('/');
|
||||
|
||||
$config = str_replace('{wwwroot}', $wwwroot->out(true), $config);
|
||||
|
||||
$params = array('mathjaxconfig' => $config, 'lang' => $lang);
|
||||
|
||||
|
||||
@@ -33,7 +33,7 @@ if ($ADMIN->fulltree) {
|
||||
$item = new admin_setting_configtext('filter_mathjaxloader/httpsurl',
|
||||
new lang_string('httpsurl', 'filter_mathjaxloader'),
|
||||
new lang_string('httpsurl_help', 'filter_mathjaxloader'),
|
||||
'https://cdn.mathjax.org/mathjax/2.7-latest/MathJax.js',
|
||||
'https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js',
|
||||
PARAM_RAW);
|
||||
$settings->add($item);
|
||||
|
||||
|
||||
@@ -0,0 +1,91 @@
|
||||
<?php
|
||||
// This file is part of Moodle - http://moodle.org/
|
||||
//
|
||||
// Moodle is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// Moodle is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/**
|
||||
* Unit test for the upgrade MathJax code.
|
||||
*
|
||||
* @package filter_mathjaxloader
|
||||
* @copyright 2017 Damyon Wiese
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
global $CFG;
|
||||
require_once($CFG->dirroot . '/filter/mathjaxloader/db/upgradelib.php');
|
||||
|
||||
/**
|
||||
* Unit test for the upgrade MathJax code.
|
||||
*
|
||||
* Test the functions in upgradelib.php
|
||||
*
|
||||
* @copyright 2017 Damyon Wiese
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
class filter_mathjax_upgradelib_testcase extends advanced_testcase {
|
||||
|
||||
public function test_upgradelib() {
|
||||
$current = 'https://cdn.mathjax.org/mathjax/2.7-latest/MathJax.js?...';
|
||||
$expected = 'https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js?...';
|
||||
$this->assertEquals($expected, filter_mathjaxloader_upgrade_cdn_cloudflare($current));
|
||||
|
||||
$current = 'http://cdn.mathjax.org/mathjax/2.7-latest/MathJax.js?...';
|
||||
$expected = 'http://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js?...';
|
||||
$this->assertEquals($expected, filter_mathjaxloader_upgrade_cdn_cloudflare($current, true));
|
||||
|
||||
$current = 'http://cdn.mathjax.org/mathjax/2.7-latest/MathJax.js?...';
|
||||
$expected = 'http://cdn.mathjax.org/mathjax/2.7-latest/MathJax.js?...';
|
||||
$this->assertEquals($expected, filter_mathjaxloader_upgrade_cdn_cloudflare($current, false));
|
||||
|
||||
$current = 'https://cdn.mathjax.org/mathjax/2.7-latest/MathJax.js?...';
|
||||
$expected = 'https://cdn.mathjax.org/mathjax/2.7-latest/MathJax.js?...';
|
||||
$this->assertEquals($expected, filter_mathjaxloader_upgrade_cdn_cloudflare($current, true));
|
||||
|
||||
$current = 'https://cdn.mathjax.org/mathjax/2.6-latest/MathJax.js?...';
|
||||
$expected = 'https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.6.1/MathJax.js?...';
|
||||
$this->assertEquals($expected, filter_mathjaxloader_upgrade_cdn_cloudflare($current));
|
||||
|
||||
$current = 'https://cdn.mathjax.org/mathjax/2.5-latest/MathJax.js?...';
|
||||
$expected = 'https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.5.3/MathJax.js?...';
|
||||
$this->assertEquals($expected, filter_mathjaxloader_upgrade_cdn_cloudflare($current));
|
||||
|
||||
// Dont touch non https links.
|
||||
$current = 'http://cdn.mathjax.org/mathjax/2.5-latest/MathJax.js?...';
|
||||
$expected = 'http://cdn.mathjax.org/mathjax/2.5-latest/MathJax.js?...';
|
||||
$this->assertEquals($expected, filter_mathjaxloader_upgrade_cdn_cloudflare($current));
|
||||
|
||||
// Dont touch non local links.
|
||||
$current = 'https://mylocalmirror/mathjax/2.7-latest/MathJax.js?...';
|
||||
$expected = 'https://mylocalmirror/mathjax/2.7-latest/MathJax.js?...';
|
||||
$this->assertEquals($expected, filter_mathjaxloader_upgrade_cdn_cloudflare($current));
|
||||
|
||||
// Try some unexpected things.
|
||||
$current = '';
|
||||
$expected = '';
|
||||
$this->assertEquals($expected, filter_mathjaxloader_upgrade_cdn_cloudflare($current));
|
||||
|
||||
// Try some unexpected things.
|
||||
$current = 'https://cdn.mathjax.org/mathjax/2.7-latest/MathJax.js';
|
||||
$expected = 'https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js';
|
||||
$this->assertEquals($expected, filter_mathjaxloader_upgrade_cdn_cloudflare($current));
|
||||
|
||||
// Try some unexpected things.
|
||||
$current = 'https://cdn.mathjax.org/mathjax/2.7-latest';
|
||||
$expected = 'https://cdn.mathjax.org/mathjax/2.7-latest';
|
||||
$this->assertEquals($expected, filter_mathjaxloader_upgrade_cdn_cloudflare($current));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
<?xml version="1.0"?>
|
||||
<libraries>
|
||||
<!-- Accessibility extensions for mathjax were briefly included - and then removed again -->
|
||||
</libraries>
|
||||
@@ -24,6 +24,6 @@
|
||||
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
$plugin->version = 2016120500;
|
||||
$plugin->version = 2016120502;
|
||||
$plugin->requires = 2016112900; // Requires this Moodle version.
|
||||
$plugin->component= 'filter_mathjaxloader';
|
||||
|
||||
@@ -249,7 +249,7 @@ class gradingform_guide_renderer extends plugin_renderer_base {
|
||||
foreach ($comments as $id => $comment) {
|
||||
$commentoption = new stdClass();
|
||||
$commentoption->id = $id;
|
||||
$commentoption->description = s($comment['description']);
|
||||
$commentoption->description = $comment['description'];
|
||||
$commentoptions[] = $commentoption;
|
||||
}
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@ Feature: Marking guides can be created and edited
|
||||
| Comment 1 |
|
||||
| Comment 2 |
|
||||
| Comment 3 |
|
||||
| Comment 4 |
|
||||
| Comment "4" |
|
||||
And I press "Save marking guide and make it ready"
|
||||
Then I should see "Ready for use"
|
||||
And I should see "Guide criterion A"
|
||||
@@ -46,7 +46,7 @@ Feature: Marking guides can be created and edited
|
||||
And I should see "Comment 1"
|
||||
And I should see "Comment 2"
|
||||
And I should see "Comment 3"
|
||||
And I should see "Comment 4"
|
||||
And I should see "Comment \"4\""
|
||||
|
||||
@javascript
|
||||
Scenario: Deleting criterion and comment
|
||||
@@ -66,7 +66,7 @@ Feature: Marking guides can be created and edited
|
||||
And I press "Save"
|
||||
Then I should see "Comment 1"
|
||||
And I should see "Comment 2"
|
||||
And I should see "Comment 4"
|
||||
And I should see "Comment \"4\""
|
||||
But I should not see "Comment 3"
|
||||
|
||||
@javascript
|
||||
@@ -80,9 +80,9 @@ Feature: Marking guides can be created and edited
|
||||
# Inserting frequently used comment.
|
||||
And I click on "Insert frequently used comment" "button" in the "Guide criterion B" "table_row"
|
||||
And I wait "1" seconds
|
||||
And I press "Comment 4"
|
||||
And I press "Comment \"4\""
|
||||
And I wait "1" seconds
|
||||
Then the field "Guide criterion B criterion remark" matches value "Comment 4"
|
||||
Then the field "Guide criterion B criterion remark" matches value "Comment \"4\""
|
||||
When I press "Save changes"
|
||||
And I press "Ok"
|
||||
And I follow "Edit settings"
|
||||
@@ -98,7 +98,7 @@ Feature: Marking guides can be created and edited
|
||||
And I should see "80" in the ".feedback" "css_element"
|
||||
And I should see "Marking guide test description" in the ".feedback" "css_element"
|
||||
And I should see "Very good"
|
||||
And I should see "Comment 4"
|
||||
And I should see "Comment \"4\""
|
||||
And I should see "Nice!"
|
||||
|
||||
Scenario: I can use marking guides to grade and edit them later updating students grades with Javascript disabled
|
||||
|
||||
@@ -39,6 +39,7 @@ if (!empty($CFG->defaulthomepage) && ($CFG->defaulthomepage == HOMEPAGE_MY) && o
|
||||
}
|
||||
$PAGE->set_url('/', $urlparams);
|
||||
$PAGE->set_course($SITE);
|
||||
$PAGE->set_pagelayout('frontpage');
|
||||
$PAGE->set_other_editing_capability('moodle/course:update');
|
||||
$PAGE->set_other_editing_capability('moodle/course:manageactivities');
|
||||
$PAGE->set_other_editing_capability('moodle/course:activityvisibility');
|
||||
@@ -106,7 +107,6 @@ if (file_exists($CFG->dirroot.'/local/hub/lib.php') and get_config('local_hub',
|
||||
|
||||
$PAGE->set_pagetype('site-index');
|
||||
$PAGE->set_docs_path('');
|
||||
$PAGE->set_pagelayout('frontpage');
|
||||
$editing = $PAGE->user_is_editing();
|
||||
$PAGE->set_title($SITE->fullname);
|
||||
$PAGE->set_heading($SITE->fullname);
|
||||
|
||||
@@ -30,7 +30,7 @@
|
||||
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
$string['cannotcreatedboninstall'] = '<p>No és pot crear la base de dades.</p> <p>La base de dades especificada no existeix i l\'usuari que heu proporcionat no té permís per a crear-la.</p>
|
||||
$string['cannotcreatedboninstall'] = '<p>No es pot crear la base de dades.</p> <p>La base de dades especificada no existeix i l\'usuari que heu proporcionat no té permís per a crear-la.</p>
|
||||
<p>L\'administrador del lloc hauria de verificar la configuració de la base de dades.</p>';
|
||||
$string['cannotcreatelangdir'] = 'No s\'ha pogut crear el directori d\'idiomes';
|
||||
$string['cannotcreatetempdir'] = 'No s\'ha pogut crear el directori temporal';
|
||||
|
||||
@@ -82,10 +82,9 @@ $string['pathsunsecuredataroot'] = 'Umístění datového adresáře není bezpe
|
||||
$string['pathswrongadmindir'] = 'Adresář pro správu serveru (admin) neexistuje';
|
||||
$string['phpextension'] = '{$a} PHP rozšíření';
|
||||
$string['phpversion'] = 'Verze PHP';
|
||||
$string['phpversionhelp'] = '<p>Moodle vyžaduje PHP alespoň verze 4.3.0 nebo 5.1.0 (PHP 5.0.x obsahuje množství chyb).</p>
|
||||
$string['phpversionhelp'] = '<p>Moodle vyžaduje PHP alespoň verze 5.6.5 PHP (7.x má určitá omezení jádra).</p>
|
||||
<p>Nyní používáte PHP verze {$a}.</p>
|
||||
<p>Musíte PHP upgradovat, nebo přejít k hostiteli s vyšší verzí!<br />
|
||||
(U PHP 5.0.x můžete také přejít na nižší verzi 4.4.x )</p>';
|
||||
<p>Musíte PHP upgradovat, nebo přejít k hostiteli s vyšší verzí!</p>';
|
||||
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
|
||||
$string['welcomep20'] = 'Podařilo se vám úspěšně nainstalovat a spustit balíček <strong>{$a->packname} {$a->packversion}</strong>. Gratulujeme!';
|
||||
$string['welcomep30'] = 'Tato verze <strong>{$a->installername}</strong> obsahuje aplikace k vytvoření prostředí, ve kterém bude provozován váš <strong>Moodle</strong>. Jmenovitě se jedná o:';
|
||||
|
||||
@@ -73,10 +73,9 @@ $string['pathsunsecuredataroot'] = 'Der Speicherort des Verzeichnisses \'dataroo
|
||||
$string['pathswrongadmindir'] = 'Das Admin-Verzeichnis existiert nicht';
|
||||
$string['phpextension'] = 'PHP-Extension {$a}';
|
||||
$string['phpversion'] = 'PHP-Version';
|
||||
$string['phpversionhelp'] = '<p>Moodle erwartet als PHP-Version mindestens 4.3.0/4.4.0 oder 5.1.0 (5.0.x weist eine Reihe bekannter Fehler auf).</p>
|
||||
<p>Sie nutzen momentan die Version {$a}.</p>
|
||||
<p>Sie müssen Ihre PHP-Version aktualisieren oder auf einen Rechner wechseln, der eine neuere Version von PHP nutzt.<br />
|
||||
(Im Falle von 5.0.x könnten Sie auch zu einer Version 4.3.x/4.4.x downgraden)</p>';
|
||||
$string['phpversionhelp'] = '<p>Moodle benötigt mindestens die PHP-Version 5.6.5. (7.x weist einige EInschränkungen auf).</p>
|
||||
<p>Sie nutzen im Moment die Version {$a}.</p>
|
||||
<p>Sie müssen die PHP-Version aktualisieren oder auf einen Server wechseln, der eine aktuellere Version von PHP nutzt.</p>';
|
||||
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
|
||||
$string['welcomep20'] = 'Sie haben das Paket <strong>{$a->packname} {$a->packversion}</strong> erfolgreich auf Ihrem Computer installiert.';
|
||||
$string['welcomep30'] = 'Diese Version von <strong>{$a->installername}</strong> enthält folgende Anwendungen, mit denen Sie <strong>Moodle</strong> ausführen können:';
|
||||
|
||||
@@ -31,18 +31,19 @@
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
$string['cannotcreatelangdir'] = 'Δε δημιουργήθηκε φάκελος γλώσσας.';
|
||||
$string['cannotcreatetempdir'] = 'Δε δημιουργήθηκε φάκελος temp.';
|
||||
$string['cannotdownloadcomponents'] = 'Δεν κατέβηκαν τα τμήματα.';
|
||||
$string['cannotdownloadzipfile'] = 'Δεν κατέβηκε το αρχείο ZIP.';
|
||||
$string['cannotfindcomponent'] = 'Δεν βρέθηκε το τμήμα.';
|
||||
$string['cannotsavemd5file'] = 'Δεν αποθηκεύτηκε το αρχείο md5.';
|
||||
$string['cannotsavezipfile'] = 'Δεν αποθηκεύτηκε το αρχείο ZIP.';
|
||||
$string['cannotunzipfile'] = 'Δεν έγινε αποσυμπίεση του αρχείου.';
|
||||
$string['componentisuptodate'] = 'Το τμήμα είναι ενημερωμένο.';
|
||||
$string['cannotcreatetempdir'] = 'Αδυναμία δημιουργίας προσωρινού φακέλου';
|
||||
$string['cannotdownloadcomponents'] = 'Αδυναμία λήψης συστατικών.';
|
||||
$string['cannotdownloadzipfile'] = 'Αδυναμία λήψης συμπιεσμένου αρχείου';
|
||||
$string['cannotfindcomponent'] = 'Αδυναμία εύρεσης συστατικού.';
|
||||
$string['cannotsavemd5file'] = 'Αδυναμία αποθήκευσης αρχείου md5.';
|
||||
$string['cannotsavezipfile'] = 'Αδυναμία αποθήκευσης συμπιεσμένου αρχείου';
|
||||
$string['cannotunzipfile'] = 'Αδυναμία αποσυμπίεσης αρχείου';
|
||||
$string['componentisuptodate'] = 'Το συστατικό είναι ενημερωμένο.';
|
||||
$string['downloadedfilecheckfailed'] = 'Το κατέβασμα ελέγχου αρχείου απέτυχε.';
|
||||
$string['invalidmd5'] = 'Μη έγκυρο md5';
|
||||
$string['missingrequiredfield'] = 'Κάποιο απαιτούμενο πεδίο λείπει';
|
||||
$string['remotedownloaderror'] = 'Απέτυχε η λήψη του τμήματος στο διακομιστή σας, παρακαλώ επιβεβαιώστε τις ρυθμίσεις του διακομιστή proxy, η επέκταση PHP cURL συνιστάται θερμά.<br /><br />Πρέπει να κατεβάσετε το <a href="{$a->url}">{$a->url}</a> χειροκίνητα, να το αντιγράψετε στο "{$a->dest}" στο διακομιστή σας και να το αποσυμπιέσετε εκεί.';
|
||||
$string['remotedownloaderror'] = '<p>Απέτυχε η λήψη του συστατικού στο διακομιστή σας. Παρακαλώ επιβεβαιώστε τις ρυθμίσεις του διακομιστή proxy, η επέκταση PHP cURL συνιστάται ιδιαίτερα.</p>
|
||||
<p>Πρέπει να κατεβάσετε το αρχείο <a href="{$a->url}">{$a->url}</a> χειροκίνητα, να το αντιγράψετε στο "{$a->dest}" στο διακομιστή σας και να το αποσυμπιέσετε εκεί.</p>';
|
||||
$string['wrongdestpath'] = 'Λανθασμένη διαδρομή προορισμού.';
|
||||
$string['wrongsourcebase'] = 'Λανθασμένη βάση πηγής URL.';
|
||||
$string['wrongzipfilename'] = 'Λανθασμένo όνομα αρχείου ZIP.';
|
||||
|
||||
@@ -90,7 +90,7 @@ $string['pathsunsecuredataroot'] = 'Dataroot location is not secure';
|
||||
$string['pathswrongadmindir'] = 'Admin directory does not exist';
|
||||
$string['phpextension'] = '{$a} PHP extension';
|
||||
$string['phpversion'] = 'PHP version';
|
||||
$string['phpversionhelp'] = '<p>Moodle requires a PHP version of at least 5.6.5 (7.x has some engine limitations).</p>
|
||||
$string['phpversionhelp'] = '<p>Moodle requires a PHP version of at least 5.6.5 or 7.1 (7.0.x has some engine limitations).</p>
|
||||
<p>You are currently running version {$a}.</p>
|
||||
<p>You must upgrade PHP or move to a host with a newer version of PHP.</p>';
|
||||
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
|
||||
|
||||
@@ -0,0 +1,70 @@
|
||||
<?php
|
||||
|
||||
// This file is part of Moodle - http://moodle.org/
|
||||
//
|
||||
// Moodle is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// Moodle is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/**
|
||||
* Automatically generated strings for Moodle installer
|
||||
*
|
||||
* Do not edit this file manually! It contains just a subset of strings
|
||||
* needed during the very first steps of installation. This file was
|
||||
* generated automatically by export-installer.php (which is part of AMOS
|
||||
* {@link http://docs.moodle.org/dev/Languages/AMOS}) using the
|
||||
* list of strings defined in /install/stringnames.txt.
|
||||
*
|
||||
* @package installer
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
$string['admindirname'] = 'Directorio Admin';
|
||||
$string['availablelangs'] = 'Paquetes de idiomas disponibles';
|
||||
$string['chooselanguagehead'] = 'Seleccionar el idioma';
|
||||
$string['chooselanguagesub'] = 'Selecciona un idioma para el proceso de instalación. Este idioma se usará también como el idioma por defecto del sitio, aunque se puede cambiar más adelante.';
|
||||
$string['clialreadyconfigured'] = 'Ya existe el archivo de configuración: config.php. Emplea admin/cli/install_database.php para instalar moodle en este sitio.';
|
||||
$string['clialreadyinstalled'] = 'Ya existe el archivo de configuración: config.php. Emplea admin/cli/install_database.php para actualizar el moodle de este sitio.';
|
||||
$string['cliinstallheader'] = 'Programa de instalación desde la linea de comandos de Moodle {$a}';
|
||||
$string['databasehost'] = 'Servidor';
|
||||
$string['databasename'] = 'Base de datos';
|
||||
$string['databasetypehead'] = 'Controlador';
|
||||
$string['dataroot'] = 'Directorio de Datos';
|
||||
$string['datarootpermission'] = 'Permiso par EL directorios de datos';
|
||||
$string['dbprefix'] = 'Prefijo para Tablas';
|
||||
$string['dirroot'] = 'Directorio Moodle';
|
||||
$string['environmenthead'] = 'Verificando tu entorno...';
|
||||
$string['environmentsub2'] = 'Cada versión de Moodle tiene algunos requerimientos mínimos de la versión de PHP y un número de extensiones obligatorias de PHP.
|
||||
La verificación completa del entorno se realiza antes de cada instalación y actualización. Ponte en contacto con el administrador del servidor si no sabes cómo instalar una nueva versión o habilitar las extensiones de PHP.';
|
||||
$string['errorsinenvironment'] = '¡Falló la verificación del entrono!';
|
||||
$string['installation'] = 'Instalación';
|
||||
$string['langdownloaderror'] = 'Desafortunadamente el idioma "{$ a}" no pudo ser descargado. El proceso de instalación continuará en inglés.';
|
||||
$string['paths'] = 'Rutas';
|
||||
$string['pathserrcreatedataroot'] = 'El directorio de datos ({$a->dataroot}) no puede ser creado por el instalador.';
|
||||
$string['pathshead'] = 'Confirma las rutas';
|
||||
$string['pathsrodataroot'] = 'No se puede escribir en el directorio raíz';
|
||||
$string['pathsroparentdataroot'] = 'No se puede escribir en el directorio base ({$a->parent}). El directorio de datos ({$a->dataroot}) no puede ser creado por el instalador.';
|
||||
$string['pathssubdataroot'] = '<p>El directorio donde Moodle guardará los documentos subidos por los usuarios.</p>
|
||||
<p>El directorio debe permitir LEER y ESCRIBIR al usuario del servidor web (<i>usualmente \'www-data\', \'nobody\' o \'apache\'</i>).</p>
|
||||
<p>No debe ser accesible directamente desde la web.</p>
|
||||
<p>Si el directorio no existe, el proceso de instalación tratará de crearlo.</p>';
|
||||
$string['pathssubdirroot'] = '<p>La ruta completa del directorio que contiene el código de Moodle.</p>';
|
||||
$string['pathssubwwwroot'] = '<p>La dirección web completa para acceder a Moodle (<i>la dirección que los usuarios escribirán en el navegador para acceder a Moodle</i>)</p>
|
||||
<p>No es posible acceder a Moodle utilizando múltiples direcciones. Si tu sitio es accesible desde múltiples direcciones debes seleccionar la mas conveniente y redireccionar permanentemente a está las demás direcciones.</p>
|
||||
<p>Si tu sitio web es accesible tanto desde internet como desde una red interna (<i>algunas veces llamada Intranet</i>), escribe aquí la dirección pública.</p>
|
||||
<p>Si la dirección actual no es correcta, cambia la URL en el navegador y reinicia la instalación.</p>';
|
||||
$string['pathsunsecuredataroot'] = 'La ubicación del directorio raíz no es segura';
|
||||
$string['pathswrongadmindir'] = 'El directorio admin no existe';
|
||||
$string['phpextension'] = '{$a} extensión PHP';
|
||||
$string['phpversion'] = 'Versión PHP';
|
||||
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
|
||||
// This file is part of Moodle - http://moodle.org/
|
||||
//
|
||||
// Moodle is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// Moodle is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/**
|
||||
* Automatically generated strings for Moodle installer
|
||||
*
|
||||
* Do not edit this file manually! It contains just a subset of strings
|
||||
* needed during the very first steps of installation. This file was
|
||||
* generated automatically by export-installer.php (which is part of AMOS
|
||||
* {@link http://docs.moodle.org/dev/Languages/AMOS}) using the
|
||||
* list of strings defined in /install/stringnames.txt.
|
||||
*
|
||||
* @package installer
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
$string['parentlanguage'] = 'es';
|
||||
$string['thislanguage'] = 'Español Colombiano';
|
||||
@@ -85,9 +85,9 @@ $string['pathsunsecuredataroot'] = 'La ubicación de dataroot no es segura';
|
||||
$string['pathswrongadmindir'] = 'El directorio admin no existe';
|
||||
$string['phpextension'] = 'Extensión PHP {$a}';
|
||||
$string['phpversion'] = 'Versión PHP';
|
||||
$string['phpversionhelp'] = '<p>Moodle requiere una versión de PHP de al menos 5.6.5 (7.x tiene algunas limitaciones del motor).</p>
|
||||
$string['phpversionhelp'] = '<p>Moodle requiere una versión de PHP de al menos 5.6.5 o 7.1 (7.0.x tiene algunas limitaciones del motor).</p>
|
||||
<p>En este momento está ejecutando la versión {$a}</p>
|
||||
<p>Usted debe actualizar PHP o trasladarse a otro servidor con una versión más reciente de PHP!<br />';
|
||||
<p>Usted debe actualizar PHP o trasladarse a otro servidor con una versión más reciente de PHP<br />';
|
||||
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
|
||||
$string['welcomep20'] = 'Si está viendo esta página es porque ha podido instalar y ejecutar exitosamente el paquete <strong>{$a->packname} {$a->packversion}</strong> en su computadora. !Enhorabuena!';
|
||||
$string['welcomep30'] = 'Esta versión de <strong>{$a->installername}</strong> incluye las aplicaciones necesarias para que <strong>Moodle</strong> funcione en su computadora, principalmente:';
|
||||
|
||||
@@ -37,8 +37,9 @@ $string['cliincorrectvalueretry'] = 'Vale väärtus(value), palun proovige uuest
|
||||
$string['clitypevalue'] = 'tüübi väärtus';
|
||||
$string['clitypevaluedefault'] = 'sisesta väärtus, vajuta Enter kasutamaks vaikeväärtust ({$a})';
|
||||
$string['cliunknowoption'] = 'Tundmatud valikud:
|
||||
{$a}
|
||||
Palun kasuta --help valikut.';
|
||||
{$a}
|
||||
Kasutage spikrivalikut.';
|
||||
$string['cliyesnoprompt'] = 'kirjuta y (tähendab jah) või n (tähendab ei)';
|
||||
$string['environmentrequireinstall'] = 'on nõutud, et oleks installeeritud ja võimaldatud';
|
||||
$string['environmentrequireversion'] = 'versioon {$a->needed} on nõutud, Sinul on jooksmas versioon {$a->current}';
|
||||
$string['upgradekeyset'] = 'Versioonitäienduse võti (jätke tühjaks, kui te ei soovi seda määrata)';
|
||||
|
||||
+17
-12
@@ -30,19 +30,24 @@
|
||||
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
$string['cannotcreatelangdir'] = 'Ei saa luua lang kataloogi';
|
||||
$string['cannotcreatetempdir'] = 'Ei saa luua temp kataloogi';
|
||||
$string['cannotdownloadcomponents'] = 'Ei saa alla tõmmata komponente.';
|
||||
$string['cannotdownloadzipfile'] = 'Ei saa alla tõmmata ZIP faili.';
|
||||
$string['cannotfindcomponent'] = 'Ei leia komponenti.';
|
||||
$string['cannotsavemd5file'] = 'Ei saa salvestada md5 faili.';
|
||||
$string['cannotsavezipfile'] = 'Ei saa salvestada ZIP faili.';
|
||||
$string['cannotunzipfile'] = 'Ei saa lahti pakkida faili.';
|
||||
$string['cannotcreatedboninstall'] = '<p>Andmebaasi ei saa luua.</p>
|
||||
<p>Määratud andmebaasi pole ja antud kasutajal puudub õigus andmebaasi loomiseks.</p>
|
||||
<p>Õpikeskkonna administraator peab kontrollima andmebaasi konfiguratsiooni</p>';
|
||||
$string['cannotcreatelangdir'] = 'Keelekataloogi ei saa luua';
|
||||
$string['cannotcreatetempdir'] = 'Ajutist kataloogi ei saa luua';
|
||||
$string['cannotdownloadcomponents'] = 'Komponente ei saa alla laadida';
|
||||
$string['cannotdownloadzipfile'] = 'ZIP-faili ei saa alla laadida';
|
||||
$string['cannotfindcomponent'] = 'Ei leia komponenti';
|
||||
$string['cannotsavemd5file'] = 'MD5-faili ei saa salvestada';
|
||||
$string['cannotsavezipfile'] = 'ZIP-faili ei saa salvestada';
|
||||
$string['cannotunzipfile'] = 'Faili ei saa lahti pakkida.';
|
||||
$string['componentisuptodate'] = 'Komponent on ajakohane';
|
||||
$string['downloadedfilecheckfailed'] = 'Alla laetud faili kontroll ebaõnnestus.';
|
||||
$string['invalidmd5'] = 'Vigane md5';
|
||||
$string['dmlexceptiononinstall'] = '<p>Ilmnes andmebaasitõrge [{$a->errorcode}].<br />{$a->debuginfo}</p>';
|
||||
$string['downloadedfilecheckfailed'] = 'Allalaaditud faili kontroll nurjus';
|
||||
$string['invalidmd5'] = 'Kontrolli muutuja oli vale – proovige uuesti';
|
||||
$string['missingrequiredfield'] = 'Mõni nõutav väli on puudu';
|
||||
$string['remotedownloaderror'] = 'Komponendi alla tõmbamine serverisse ebaõnnestus, palun kontrolli proksi seadeid, PHP cURL laiendus on tungivalt soovitatav.<br /><br />Sa pead tõmbama <a href="{$a->url}">{$a->url}</a> faili käsitsi, kopeerima selle "{$a->dest}" oma serveris ja pakkima lahti sinna.';
|
||||
$string['remotedownloaderror'] = '<p>Komponendi teie serverisse allalaadimine nurjus. Kontrollige puhvri sätteid; PHP laiend cURL on tungivalt soovitatav.</p>
|
||||
<p>Peate faili <a href="{$a->url}">{$a->url}</a> käsitsi alla laadima, kopeerima selle oma serveris asukohta „{$a->dest}“ ja seal lahti pakkima.</p>';
|
||||
$string['wrongdestpath'] = 'Vale sihtkohatee';
|
||||
$string['wrongsourcebase'] = 'Vale allika URL\'i baas.';
|
||||
$string['wrongsourcebase'] = 'Vale allika URL-i baas';
|
||||
$string['wrongzipfilename'] = 'Vale ZIP-faili nimi';
|
||||
|
||||
+49
-31
@@ -30,49 +30,60 @@
|
||||
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
$string['admindirname'] = 'Administreerimiskataloog';
|
||||
$string['availablelangs'] = 'Saadaval keelte nimekiri';
|
||||
$string['admindirname'] = 'Halduskataloog';
|
||||
$string['availablelangs'] = 'Saadaolevad keelepaketid';
|
||||
$string['chooselanguagehead'] = 'Valige keel';
|
||||
$string['chooselanguagesub'] = 'Palun vali keel, mida kasutatakse AINULT installeerimise käigus. Hiljem saab valida õpikeskkonna ja kasutajate keelt.';
|
||||
$string['clialreadyinstalled'] = 'Fail config.php juba eksisteerib, palun kasuta admin/cli/upgrade.php kui soovid uuendada oma saiti.';
|
||||
$string['chooselanguagesub'] = 'Valige Moodle’i keel. Valitud keelt kasutatakse õpikeskkonna vaikekeelena ja seda saab hiljem muuta.';
|
||||
$string['clialreadyconfigured'] = 'Fail „config.php“ on juba olemas. Kasutage sellele saidile Moodle’i installimiseks faili „admin/cli/install_database.php“.';
|
||||
$string['clialreadyinstalled'] = 'Konfiguratsioonifail config.php on juba olemas. Palun kasutage Moodle’i selles õpikeskkonnas uuendamiseks faili admin/cli/install_database.php.';
|
||||
$string['cliinstallheader'] = 'Moodle’i {$a} käsureapõhine installiprogramm';
|
||||
$string['databasehost'] = 'Andmebaasi host';
|
||||
$string['databasename'] = 'Andmebaasi nimi';
|
||||
$string['databasetypehead'] = 'Valige andmebaasi draiver';
|
||||
$string['dataroot'] = 'Andmete kataloog';
|
||||
$string['dataroot'] = 'Andmekataloog';
|
||||
$string['datarootpermission'] = 'Andmekataloogide õigus';
|
||||
$string['dbprefix'] = 'Tabeli eesliide';
|
||||
$string['dirroot'] = 'Moodle kataloog';
|
||||
$string['dirroot'] = 'Moodle’i kataloog';
|
||||
$string['environmenthead'] = 'Keskkonna kontrollimine...';
|
||||
$string['environmentsub2'] = 'Iga Moodle väljalaskel on oma minimaalne PHP versiooni nõue ja kohustuslikud PHP laiendused.
|
||||
Täielik keskkonna kontroll tehakse enne iga installeerimist ja uuendamist. Palun võta ühendust serveri administraatoriga, kui sa ei sa kuidas installeerida või võimaldada PHP laiendusi.';
|
||||
$string['environmentsub2'] = 'Igal Moodle’i väljaandel on oma minimaalne PHP versiooni nõue ja kohustuslikud PHP- laiendused.
|
||||
Täielik keskkonnakontroll tehakse enne iga installi ja versiooniuuendust. Kui te ei tea, kuidas installida uus versioon või lubada PHP-laiendused, pöörduge administraatori poole.';
|
||||
$string['errorsinenvironment'] = 'Keskkonna sobivuse kontroll nurjus.';
|
||||
$string['installation'] = 'Installimine';
|
||||
$string['langdownloaderror'] = 'Keelt "{$a}" ei saanud alla laadida. Installimine jätkub inglise keeles.';
|
||||
$string['memorylimithelp'] = '<p>PHP mälu limiit sinu serveri jaoks on hetkel {$a}.</p>
|
||||
<p>See võib hiljem tekitada Moodle\'il mäluprobleeme, eriti kui sul on palju mooduleid ja/või kasutajaid.
|
||||
</p>
|
||||
<p>Me soovitame, et sa konfigureeriksid PHP kõrgema limiidi peale, näiteks 16M. Selle tostamiseks on mitu viisi:</p>
|
||||
$string['memorylimithelp'] = '<p>Teie serveri PHP mälulimiit on praegu {$a}.</p>
|
||||
|
||||
<p>See võib hiljem tekitada Moodle’il mäluprobleeme,
|
||||
eriti kui teil on palju kasutajaid ja/või lubatud palju mooduleid.</p>
|
||||
|
||||
<p>Soovitatav on võimaluse korral konfigureerida suurem PHP limiit, näiteks 16M.
|
||||
Selle tegemiseks on mitu viisi.</p>
|
||||
<ol>
|
||||
<li>Kui võimalik, siis kompileeri PHP uuesti parameetriga <i>--enable-memory-limit</i>.
|
||||
See lubab Moodle\'il ise mälu limiiti määrata.</li>
|
||||
<li>Kui sul on juurdepääs oma php.ini failile, siis saad muuta seal <b>memory_limit</b> väärtuseks midagi 16M lähedast. Kui sul ei ole juurdepääsu, siis võiksid paluda administraatoril seda teha.</li>
|
||||
<li>Mõnedes PHP serverites saad luua Moodle kataloogi .htaccess faili, mis sisaldab seda rida:<p><blockquote>php_value memory_limit 16M</blockquote></p>
|
||||
<p>Kuigi mõnedes serverites tõkestab see <b>kõigi</b> PHP lehekülgede tööd (sa näed veateateid, kui vaatad lehti), nii et pead eemaldama .htaccess faili.</p></li>
|
||||
<li>Kui võimalik, siis kompileerige PHP uuesti parameetriga <i>--enable-memory-limit</i>.
|
||||
See lubab Moodle’il ise mälulimiidi määrata.</li>
|
||||
<li>Kui teil on juurdepääs teie php.ini failile, saate seal muuta sätte <b>memory_limit</b>
|
||||
väärtuse näiteks väärtuseks 40M. Kui teil pole juurdepääsu,
|
||||
saate paluda administraatoril seda teha.</li>
|
||||
<li>Mõnes PHP-serveris saab luua Moodle’i kataloogi faili .htaccess,
|
||||
mis sisaldab seda rida:
|
||||
<blockquote><div>php_value memory_limit 40M</div></blockquote>
|
||||
<p>Kuigi mõnes serveris tõkestab see <b>kõigi</b> PHP-lehtede tööd
|
||||
(kui vaatate lehti, näete tõrketeateid), nii et peate faili .htaccess eemaldama.</p></li>
|
||||
</ol>';
|
||||
$string['paths'] = 'Teed';
|
||||
$string['pathserrcreatedataroot'] = 'Andmete kataloogi ({$a->dataroot}) ei saa installeerija luua.';
|
||||
$string['pathserrcreatedataroot'] = 'Installiprogramm ei saanud andmete kataloogi ({$a->dataroot}) luua.';
|
||||
$string['pathshead'] = 'Kinnita teed';
|
||||
$string['pathsrodataroot'] = 'Andmete juurkataloog ei võimalda kirjutust.';
|
||||
$string['pathsroparentdataroot'] = 'Ülemkataloog ({$a->parent}) ei võimalda kirjutust. Installiprogramm ei saanud andmete kataloogi ({$a->dataroot}) luua.';
|
||||
$string['pathssubadmindir'] = 'Väga vähesed veebihostid kasutavad /admin spetsiaalse URL-na, et pääseda ligi kontrollpaneelile või millegile sarnasele. Kahjuks on see konfliktis Moodle administreerimislehtedega. Sa saad olukorda parandada, kui nimetad kataloogi admin ümber oma üaigalduses ning kirjutad selle uue nime siia. Näiteks: <em>moodleadmin</em>. See parandab administreerimisliidese lingid Moodle\'s.';
|
||||
$string['pathssubdataroot'] = 'Sa pead näitama koha, kuhu Moodle saaks salvestada üles laetud failid. See kataloog peab olema loetav JA KIRJUTATAV veebiserveri kasutaja poolt (tavaliselt \'nobody\' or \'apache\'), samas see kataloog ei tohiks olla ligipääsetav otse veebi kaudu. Kui kataloogi ei eksisteeri, siis installeerija püüab selle ise luua.';
|
||||
$string['pathssubdirroot'] = 'Täistee Moodle paigalduse kataloogile.';
|
||||
$string['pathssubwwwroot'] = 'Täielik veebiaadress, kust kaudu Moodle\'le ligi pääsetakse.
|
||||
Ei ole võimalik kasutada mitmest kohast kohast ligipääsu.
|
||||
Kui Su sait omab mitut avalikku aadress, siis pead seadistama ümbersuunamised kõikidelt teistest aadressidelt.
|
||||
Kui Su sait on ligipääsetav nii Internetist kui intranetist (sisevõrgust), siis kasuta Interneti ehk avalikku aadressi ja seadista DNS sellisellt, et intraneti kasutajad kasutaksid ka avalikku aadressi.
|
||||
Kui aadress pole korrektne, siis palun muuda URL oma brauseris, et taasalustada installeerimist erineva väärtusega.';
|
||||
$string['pathssubadmindir'] = 'Väga vähestes veebihostides on juhtpaneelile vm juurdepääsuks spetsiaalse URL-ina kasutusel „/admin“. Kahjuks ei vasta see Moodle’i administreerimislehtede tavaasukohale. Saate olukorda parandada, kui nimetate kataloogi admin oma installis ümber ja sisestate uue nime siin. Näiteks: <em>moodleadmin</em>. See parandab Moodle’is olevad administreerimisliidese lingid.';
|
||||
$string['pathssubdataroot'] = '<p>Kataloog, kuhu Moodle salvestab kõigi kasutajate üleslaaditud failide sisu.</p>
|
||||
<p>See kataloog peab olema veebiserveri kasutaja poolt (tavaliselt \'www-data\', \'nobody\' või \'apache\') nii loetav kui ka kirjutatav.</p>
|
||||
<p>See ei tohi olla otse veebist juurdepääsetav.</p>
|
||||
<p>Kui kataloogi pole praegu olemas, püüab installimisprotsess selle ise luua.</p>';
|
||||
$string['pathssubdirroot'] = '<p>Moodle’i koodi sisaldava kataloogi täielik tee.</p>';
|
||||
$string['pathssubwwwroot'] = '<p>Täielik veebiaadress, kustkaudu Moodle’ile juurde pääsetakse, s.t see aadress, mille kasutajad Moodle’ile juurdepääsemiseks oma brauseri aadressiribale sisestavad.</p>
|
||||
<p>Moodle’ile poole võimalik juurde pääseda mitme aadressi kaudu. Kui teie õpikeskkond on juurdepääsetav mitme aadressi kaudu, valige neist lihtsaim ja määrake kõigilt teistelt aadressidelt püsiv ümbersuunamine.</p>
|
||||
<p>Kui teie õpikeskkond on juurdepääsetav nii Internetist kui ka sisevõrgust, kasutage siin avalikku aadressi.</p>
|
||||
<p>Kui praegune aadress pole õige, siis muutke oma brauseri aadressiribal URL ja alustage installi uuesti.</p>';
|
||||
$string['pathsunsecuredataroot'] = 'Andmete juurkataloogi asukoht pole turvaline';
|
||||
$string['pathswrongadmindir'] = 'Halduskataloogi pole olemas';
|
||||
$string['phpextension'] = '{$a} PHP-laiendus';
|
||||
@@ -81,10 +92,17 @@ $string['phpversionhelp'] = '<p>Moodle vajab vähemalt PHP versiooni 4.1.0</p>
|
||||
<p>Sinu jooksev versioon on {$a}</p>
|
||||
<p>Sa pead oma PHP-d uuendama või kolima hosti, kus on uuem PHP versioon!</p>';
|
||||
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
|
||||
$string['welcomep20'] = 'Sa näed seda lehte, sest oled edukalt installeerinud ja käivitanud <strong>{$a->packname} {$a->packversion}</strong> paketi Sinu arvutis. Õnnitleme!';
|
||||
$string['welcomep30'] = 'See <strong>{$a->installername}</strong> väljalase rakendusi loomaks keskkonda, millel <strong>Moodle</strong> hakkab will operate, namely:';
|
||||
$string['welcomep20'] = 'Teile kuvatakse see leht, kuna olete edukalt oma arvutisse installinud ja
|
||||
käivitanud paketi <strong>{$a->packname} {$a->packversion}</strong>. Õnnitleme!';
|
||||
$string['welcomep30'] = 'See <strong>{$a->installername}</strong> väljaanne hõlmab rakendusi, mille abil
|
||||
saab luua <strong>Moodle’i</strong> toimimiseks vajaliku keskkonna, nt:';
|
||||
$string['welcomep40'] = 'Pakett sisaldab ka järgmist: <strong>Moodle {$a->moodlerelease} ({$a->moodleversion})</strong>.';
|
||||
$string['welcomep50'] = 'Kasutamaks kõiki selle rakendusi selles paketis on kaetud nende vastavad litsentsid. Täielik <strong>{$a->installername}</strong> pakett on <a href="http://www.opensource.org/docs/definition_plain.html">avatud lähtekoodil</a> ja jaotatud <a href="http://www.gnu.org/copyleft/gpl.html">GPL</a> litsentsi alusel.';
|
||||
$string['welcomep60'] = 'Järgnevatel lehtedel juhitakse sind läbi mõnede lihtsate sammude seadistamaks ja seadmaks üles <strong>Moodle</strong> oma arvutis. Sa võid nõustuda vaikeväärtustega või fakultatiivselt täiendada vastavalt oma vajadustele.';
|
||||
$string['welcomep70'] = '<strong>Moodle\\’i</strong> installi jätkamiseks klõpsake nuppu Edasi.';
|
||||
$string['welcomep50'] = 'Kõigi selle paketi rakenduste kasutamise kohta kehtivad nende vastavad
|
||||
litsentsid. Täielik <strong>{$a->installername}</strong> pakett on
|
||||
<a href="http://www.opensource.org/docs/definition_plain.html">avatud lähtekoodiga</a> ja seda levitatakse
|
||||
<a href="http://www.gnu.org/copyleft/gpl.html">GPL</a> litsentsi alusel.';
|
||||
$string['welcomep60'] = 'Järgmistel lehtedel toodud lihtsate juhiste abil saate konfigureerida ja
|
||||
häälestada <strong>Moodle</strong>’i oma arvutis. Võite nõustuda
|
||||
vaikesätetega või muuta sätteid oma vajaduste järgi.';
|
||||
$string['welcomep70'] = '<strong>Moodle’i</strong> installi jätkamiseks klõpsake nuppu Edasi.';
|
||||
$string['wwwroot'] = 'Veebiaadress';
|
||||
|
||||
@@ -32,4 +32,4 @@ defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
$string['parentlanguage'] = '';
|
||||
$string['thisdirection'] = 'ltr';
|
||||
$string['thislanguage'] = 'inglise';
|
||||
$string['thislanguage'] = 'eesti';
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
$string['language'] = 'Keel';
|
||||
$string['next'] = 'Järgmine';
|
||||
$string['moodlelogo'] = 'Moodle’i logo';
|
||||
$string['next'] = 'Edasi';
|
||||
$string['previous'] = 'Eelmine';
|
||||
$string['reload'] = 'Laadi uuesti';
|
||||
|
||||
@@ -30,6 +30,9 @@
|
||||
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
$string['cannotcreatedboninstall'] = '<p>Ezin da datu-basea sortu.<p>
|
||||
<p>Zehaztutako datu-basea ez da existitzen eta adierazitako erabiltzaileak ez du baimenik datu-basea sortzeko.<p>
|
||||
<p>Guneko kudeatzaileak datu-basearen konfigurazioa egiaztatu behar du.</p>';
|
||||
$string['cannotcreatelangdir'] = 'Ezin da hizkuntza-direktorioa sortu';
|
||||
$string['cannotcreatetempdir'] = 'Ezin da temp direktorioa sortu';
|
||||
$string['cannotdownloadcomponents'] = 'Ezin dira osagaiak jaitsi';
|
||||
|
||||
@@ -85,10 +85,9 @@ $string['pathsunsecuredataroot'] = 'Dataroot-en kokapena ez da segurua';
|
||||
$string['pathswrongadmindir'] = 'Admin direktorioa ez da existitzen';
|
||||
$string['phpextension'] = '{$a} PHP luzapena';
|
||||
$string['phpversion'] = 'PHP bertsioa';
|
||||
$string['phpversionhelp'] = '<p>Moodle-k gutxienez PHP 4.3.0 edo 5.1.0 (5.0.x errore batzuk ditu). </p>
|
||||
$string['phpversionhelp'] = '<p>Moodle-k gutxienez PHP 5.6.5 bertsioa behar du (7.x bertsioak muga batzuk ditu). </p>
|
||||
<p>Zure bertsioa: {$a}</p>
|
||||
<p>PHP eguneratu edo PHP bertsio berriagoa duen zerbitzari batera jo</p>
|
||||
<p>5.0.x baduzu, nahi izanez gero, 4.4.x. bertsiora jaitsi dezakezu</p>';
|
||||
<p>PHP eguneratu edo PHP bertsio berriagoa duen zerbitzari batera jo</p>';
|
||||
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
|
||||
$string['welcomep20'] = 'Orri hau ikusten baduzu <strong>{$a->packname} {$a->packversion}</strong> paketea zure ordenagailuan instalatu ahal izan duzu. Zorionak!';
|
||||
$string['welcomep30'] = '<strong>{$a->installername}</strong>ren bertsio honek <strong>Moodle</strong>k
|
||||
|
||||
@@ -42,3 +42,4 @@ $string['cliunknowoption'] = 'گزینههای شناخته نشده:
|
||||
$string['cliyesnoprompt'] = 'یکی از گزینههای ب (به معنای بلی) یا خ (به نشانه خیر) را تایپ کنید';
|
||||
$string['environmentrequireinstall'] = 'باید نصب و فعال باشد';
|
||||
$string['environmentrequireversion'] = 'نسخهٔ {$a->needed} لازم است و شما نسخهٔ {$a->current} را دارید';
|
||||
$string['upgradekeyset'] = 'کلید ارتقا (برای تعیین نکردن خالی بگذارید)';
|
||||
|
||||
@@ -34,13 +34,24 @@ $string['admindirname'] = 'دایرکتوری مدیر';
|
||||
$string['availablelangs'] = 'بستههای زبانی موجود';
|
||||
$string['chooselanguagehead'] = 'انتخاب زبان';
|
||||
$string['chooselanguagesub'] = 'لطفاً زبانی را به جهت استفاده در حین نصب انتخاب نمایید. زبانی که در این صفحه انتخاب میکنید به عنوان زبان پیشفرض سایت نیز مورد استفاده قرار خواهد گرفت. البته میتوانید بعداً آن را تغییر دهید.<br />ترجمهٔ فارسی این نسخه با همکاری <a href="http://foodle.org" target="_blank">گروه فودل</a> آماده شده است.';
|
||||
$string['clialreadyconfigured'] = '.ﺩﺭﺍﺩ ﺩﻮﺟﻭ config.php ﯼﺪﻨﺑﺮﮑﯿﭘ ﻞﯾﺎﻓ
|
||||
ﺯﺍ ﺖﯾﺎﺳ ﻦﯾﺍ ﺭﺩ ﻝﺩﻮﻣ ﺐﺼﻧ ﯼﺍﺮﺑ ﺎﻔﻄﻟ
|
||||
.ﺪﯿﻨﮐ ﻩﺩﺎﻔﺘﺳﺍ admin/cli/database_install.php';
|
||||
$string['clialreadyinstalled'] = '.ﺩﺭﺍﺩ ﺩﻮﺟﻭ config.php ﯼﺪﻨﺑﺮﮑﯿﭘ ﻞﯾﺎﻓ
|
||||
ﺯﺍ ﺖﯾﺎﺳ ﻦﯾﺍ ﺭﺩ ﻝﺩﻮﻣ ﯼﺎﻘﺗﺭﺍ ﯼﺍﺮﺑ ﺎﻔﻄﻟ
|
||||
.ﺪﯿﻨﮐ ﻩﺩﺎﻔﺘﺳﺍ admin/cli/database_install.php';
|
||||
$string['cliinstallheader'] = 'ﻥﺎﻣﺮﻓ ﻂﺧ ﻖﯾﺮﻃ ﺯﺍ {$a} ﻝﺩﻮﻣ ﺐﺼﻧ ﻪﻣﺎﻧﺮﺑ';
|
||||
$string['databasehost'] = 'میزبان پایگاه داده';
|
||||
$string['databasename'] = 'نام پایگاه داده';
|
||||
$string['databasetypehead'] = 'راهانداز پایگاه داده را انتخاب کنید';
|
||||
$string['dataroot'] = 'دایرکتوری داده';
|
||||
$string['datarootpermission'] = 'ﺎﻫﻩﺩﺍﺩ ِﯼﺭﻮﺘﮐﺮﯾﺍﺩ ﺯﻮﺠﻣ';
|
||||
$string['dbprefix'] = 'پیشوند جدولها';
|
||||
$string['dirroot'] = 'دایرکتوری مودل';
|
||||
$string['environmenthead'] = 'بررسی محیط شما ...';
|
||||
$string['environmentsub2'] = 'هر کدام از انتشارهای مودل حداقل نیازمندی مخصوص به خود را در مورد نسخهٔ PHP و وجود داشتن برخی از افزونههای PHP دارد.
|
||||
پیش از هر نصب و ارتقا، بررسی کامل محیط انجام میشود. اگر نمیدانید چطور نسخهٔ جدید PHP را نصب کنید یا افزونههای PHP را فعال کنید، لطفا با مسئول کارگزار خود تماس بگیرید.';
|
||||
$string['errorsinenvironment'] = 'بررسی محیط ناموفق بود!';
|
||||
$string['installation'] = 'در حال نصب';
|
||||
$string['langdownloaderror'] = 'متأسفانه زبان «{$a}» نصب نشد. فرآیند نصب به زبان انگلیسی ادامه خواهد یافت.';
|
||||
$string['memorylimithelp'] = '<p>حد حافظهٔ PHP کارگزار شما هماکنون {$a} است.</p>
|
||||
@@ -62,6 +73,28 @@ $string['memorylimithelp'] = '<p>حد حافظهٔ PHP کارگزار شما ه
|
||||
<p>اگرچه، در برخی از کارگزارها انجام این کار موجب جلوگیری از کارکردن <b>همهٔ</b> صفحههای PHP خواهد شد
|
||||
(هنگام مشاهدهٔ صفحهها خطاهایی خواهید دید) و مجبور خواهید بود که فایل <span dir="ltr">.htaccess</span> را پاک کنید.</p></li>
|
||||
</ol>';
|
||||
$string['paths'] = 'مسیرها';
|
||||
$string['pathserrcreatedataroot'] = 'دایرکتوری داده (<string dir="ltr" style="direction:ltr;display:inline-block;">{$a->dataroot}</span>) نمیتواند توسط برنامهٔ نصب ایجاد شود.';
|
||||
$string['pathshead'] = 'تایید مسیرها';
|
||||
$string['pathsrodataroot'] = 'دایرکتوری داده قابل نوشتن نیست.';
|
||||
$string['pathsroparentdataroot'] = 'دایرکتوری مادر (<string dir="ltr" style="direction:ltr;display:inline-block;">{$a->parent}</span>) قابل نوشتن نیست. دایرکتوری داده (<string dir="ltr" style="direction:ltr;display:inline-block;">{$a->dataroot}</span>) نمیتواند توسط برنامهٔ نصب ایجاد شود.';
|
||||
$string['pathssubadmindir'] = 'وبسایتهای خیلی کمی از <span dir="ltr" style="display:inline-block;direction:ltr">/admin</span> بهعنوان پیوند ویژهای برای دستیابی به یک
|
||||
control panel یا چیز دیگری استفاده میکنند. متأسفانه این مسئله با
|
||||
محل استاندارد صفحههای مدیر در مودل تداخل دارد. این مشکل را میتوانید
|
||||
با تغییر نام دایرکتوری admin در فایلهای نصب و قرار دادن
|
||||
نام جدید در این قسمت برطرف نمائید. بهعنوان مثال: <em>moodleadmin</em>. این کار پیوندهای مدیر در مودل را اصلاح خواهد کرد.';
|
||||
$string['pathssubdataroot'] = '<p>دایرکتوریای مودل تمام فایلهایی که توسط کاربران ارسال میشود را نگهداری میکند.</p>
|
||||
<p>این دایرکتوری باید توسط کاربر کارگزار وب (معمولا www-data یا nobody یا apache) هم قابل خواندن و هم قابل نوشتن باشد.</p>
|
||||
<p>این دایرکتوری نباید مستقیما بر روی وب قابل دسترسی باشد.</p>
|
||||
<p>اگر دایرکتوری در حال حاضر وجود نداشته باشد، فرایند نصب سعی میکند که آن را بسازد.</p>';
|
||||
$string['pathssubdirroot'] = '<p>مسیر کامل دایرکتوریای که محتوی کد مودل است.</p>';
|
||||
$string['pathssubwwwroot'] = '<p>آدرس کامل دسترسی به مودل؛ یعنی آدرسی که کاربران برای دسترسی به مودل در نوار آدرس مرورگرشان وارد میکنند.</p>
|
||||
<p>دسترسی به مودل از طریق چند آدرس امکانپذیر نیست. اگر سایت شما توسط آدرسهای مختلفی قابل دسترسی است آنگاه سادهترین آنها را انتخاب کنید و تمام آدرسهای دیگر را روی آن ریدایرکت کنید (permanent redirect).</p>
|
||||
<p>اگر سایت شما هم از طریق اینترنت و هم از طریق شبکهٔ محلی (که گاهی به آن اینترانت هم میگویند) قابل دسترسی است، آنگاه آدرس عمومی را در این قسمت استفاده کنید.</p>
|
||||
<p>اگر آدرس فعلی درست نیست، لطفا آدرس را در نوار آدرس مرورگر خود تغییر دهید و فرایند نصب را از اول شروع کنید.</p>';
|
||||
$string['pathsunsecuredataroot'] = 'محل دایرکتوری داده امن نیست';
|
||||
$string['pathswrongadmindir'] = 'دایرکتوری مدیر وجود ندارد';
|
||||
$string['phpextension'] = 'افزونهٔ {$a} در PHP';
|
||||
$string['phpversion'] = 'نسخهٔ PHP';
|
||||
$string['phpversionhelp'] = '<p>مودل نیاز به PHP نسخهٔ حداقل 5.6.5 دارد (<span dir="ltr" style="direction: ltr; display: inline-block">7.x</span> محدودیتهایی در engine اش دارد).</p>
|
||||
<p>شما در حال حاضر از نسخهٔ {$a} استفاده میکنید</p>
|
||||
|
||||
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
|
||||
// This file is part of Moodle - http://moodle.org/
|
||||
//
|
||||
// Moodle is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// Moodle is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/**
|
||||
* Automatically generated strings for Moodle installer
|
||||
*
|
||||
* Do not edit this file manually! It contains just a subset of strings
|
||||
* needed during the very first steps of installation. This file was
|
||||
* generated automatically by export-installer.php (which is part of AMOS
|
||||
* {@link http://docs.moodle.org/dev/Languages/AMOS}) using the
|
||||
* list of strings defined in /install/stringnames.txt.
|
||||
*
|
||||
* @package installer
|
||||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
||||
*/
|
||||
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
$string['clianswerno'] = '';
|
||||
$string['cliansweryes'] = '';
|
||||
@@ -31,3 +31,4 @@
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
$string['language'] = 'Tungumál';
|
||||
$string['next'] = 'Næsta';
|
||||
|
||||
@@ -68,10 +68,12 @@ $string['pathsunsecuredataroot'] = 'Az adatok gyökérkönyvtára nem biztonság
|
||||
$string['pathswrongadmindir'] = 'Nem létezik az admin könyvtár.';
|
||||
$string['phpextension'] = '{$a} PHP-bővítmény';
|
||||
$string['phpversion'] = 'PHP-verzió';
|
||||
$string['phpversionhelp'] = 'A Moodle használatához legalább a PHP 4.3.0 vagy 5.1.0 verziója szükséges
|
||||
(az 5.0.x több ismert gond miatt nem ajánlott). Az Ön által használt
|
||||
verzió {$a}. Frissítse a PHP-verziót, vagy térjen át újabb PHP-verziót
|
||||
működtető gazdagépre! (5.0.x esetén visszatérhet a 4.4.x verzióhoz is)';
|
||||
$string['phpversionhelp'] = 'A Moodle használatához legalább a PHP 5.6.5 verziója szükséges
|
||||
(a 7.x bizonyos korlátokkal rendelkezik).</p>
|
||||
<p> Az Ön által használt
|
||||
verzió {$a}. </p>
|
||||
<p>Frissítse a PHP-verziót, vagy térjen át újabb PHP-verziót
|
||||
működtető gazdagépre!</p>';
|
||||
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
|
||||
$string['welcomep20'] = 'Azért látja ezt az oldalt, mert sikeresen telepítette és futtatja az {$a->packname} {$a->packversion} csomagot számítógépén. Gratulálunk!';
|
||||
$string['welcomep30'] = 'A {$a->installername} tartalmazza azokat az alkalmazásokat, amelyekkel a Moodle számára kialakítható a működési környezet, azaz:';
|
||||
|
||||
@@ -83,10 +83,9 @@ $string['pathsunsecuredataroot'] = 'La posizione della Cartella dati non è sicu
|
||||
$string['pathswrongadmindir'] = 'La cartella Admin non esiste';
|
||||
$string['phpextension'] = '{$a} estensioni PHP';
|
||||
$string['phpversion'] = 'Versione PHP';
|
||||
$string['phpversionhelp'] = '<p>Moodle necessita come minimo della versione 4.3.0 o 5.1.0 del PHP. (La versione 5.0.x soffre di problemi noti)</p>
|
||||
$string['phpversionhelp'] = '<p>Moodle necessita come minimo della versione 5.6.5 del PHP. (La versione 7.x ha alcuni limiti nell\'engine)</p>
|
||||
<p>La versione installata nel sistema è la {$a}</p>
|
||||
<p>E\' necessario aggiornare la versione del PHP oppure spostarsi su un host che abbia una versione più aggiornata del PHP!<br>
|
||||
(Dalla 5.0.x, è possibile eseguire il downgrade alla versione 4.4.x)</p>';
|
||||
<p>E\' necessario aggiornare la versione del PHP oppure spostarsi su un host che abbia una versione più aggiornata del PHP.<br>';
|
||||
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
|
||||
$string['welcomep20'] = 'Se vedi questa pagina hai installato correttamente e lanciato il pacchetto <strong>{$a->packname} {$a->packversion}</strong>. Complimenti!';
|
||||
$string['welcomep30'] = 'La release di <strong>{$a->installername}</strong> include l\'applicazione per creare l\'ambiente necessario a far girare <strong>Moodle</strong>:';
|
||||
|
||||
@@ -46,7 +46,7 @@ $string['dmlexceptiononinstall'] = '<p>データベースエラーが発生し
|
||||
$string['downloadedfilecheckfailed'] = 'ダウンロードファイルのチェックに失敗しました。';
|
||||
$string['invalidmd5'] = 'チェック変数が正しくありません - 再度お試しください。';
|
||||
$string['missingrequiredfield'] = 'いくつかの必須入力フィールドが入力されていません。';
|
||||
$string['remotedownloaderror'] = '<p>あなたのサーバへのコンポーネントのダウンロードに失敗しました。プロクシ設定を確認してください。PHP cURL拡張モジュールの使用を強くお勧めします。</p>
|
||||
$string['remotedownloaderror'] = '<p>あなたのサーバへのコンポーネントのダウンロードに失敗しました。プロキシ設定を確認してください。PHP cURL拡張モジュールの使用を強くお勧めします。</p>
|
||||
<p><a href="{$a->url}">{$a->url}</a>ファイルを手動でダウンロードした後、あなたのサーバの「{$a->dest}」にコピーおよび展開してください。</p>';
|
||||
$string['wrongdestpath'] = '宛先パスが正しくありません。';
|
||||
$string['wrongsourcebase'] = 'ソースURLベースが正しくありません。';
|
||||
|
||||
@@ -84,11 +84,9 @@ $string['pathsunsecuredataroot'] = 'dataroot ロケーションが安全では
|
||||
$string['pathswrongadmindir'] = 'adminディレクトリがありません。';
|
||||
$string['phpextension'] = '{$a} PHP拡張モジュール';
|
||||
$string['phpversion'] = 'PHPバージョン';
|
||||
$string['phpversionhelp'] = '<p>Moodleには少なくとも4.3.0または5.1.0のPHPバージョンが必要です (5.0.x には既知の多数の問題があります)。</p>
|
||||
<p>現在、バージョン {$a} が動作しています。</p>
|
||||
<p>PHPをアップグレードするか、新しいバージョンがインストールされているホストに移動してください!<br />
|
||||
(5.0.x の場合、anataha
|
||||
バージョン 4.4.x にダウングレードすることもできます。)</p>';
|
||||
$string['phpversionhelp'] = '<p>Moodleには少なくとも5.6.5または7.1のPHPバージョンが必要です (7.0.x にはエンジンの制限があります)。</p>
|
||||
<p>現在、あなたはバージョン {$a} を動作させています。</p>
|
||||
<p>PHPをアップグレードするか新しいバージョンのPHPがインストールされているホストに移動する必要があります。</p>';
|
||||
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
|
||||
$string['welcomep20'] = 'インストールが正常に完了して、あなたのコンピュータで <strong>{$a->packname} {$a->packversion}</strong> パッケージが起動されたため、このページが表示されています。おめでとうございます!';
|
||||
$string['welcomep30'] = 'このリリース <strong>{$a->installername}</strong> には<strong>Moodle</strong>で環境を作成するアプリケーションが含まれています。すなわち:';
|
||||
|
||||
@@ -80,8 +80,9 @@ $string['pathsunsecuredataroot'] = 'De plaats van de datamap is niet veilig.';
|
||||
$string['pathswrongadmindir'] = 'De adminmap bestaat niet';
|
||||
$string['phpextension'] = '{$a} PHP-extentie';
|
||||
$string['phpversion'] = 'PHP-versie';
|
||||
$string['phpversionhelp'] = '<p>Moodle heeft minstens PHP-versie 4.3.0 of 5.1.0 nodig (5.0.x heeft veel bekende problemen).</p> <p>De huidige versie op je server is {$a}</p>
|
||||
<p>Je moet PHP upgraden of verhuizen naar een host met een nieuwere versie van PHP!<br />(Als je 5.0.x draait, kun je ook downgraden naar versie 4.4.x)</p>';
|
||||
$string['phpversionhelp'] = '<p>Moodle vereist minstens PHP-versie 5.6.5 (7.x kent enige beperkingen).</p>
|
||||
<p>De huidige versie op je server is {$a}.</p>
|
||||
<p>Je moet PHP upgraden of verhuizen naar een host met een nieuwere versie van PHP.</p>';
|
||||
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
|
||||
$string['welcomep20'] = 'Je krijgt deze pagina te zien omdat je met succes het <strong>{$a->packname} {$a->packversion}</strong> packet op je computer gezet en gestart hebt. Proficiat!';
|
||||
$string['welcomep30'] = 'Deze uitgave van <strong>{$a->installername}</strong> bevat de software die nodig is om een omgeving te creëren waarin <strong>Moodle</strong> zal werken, namelijk:';
|
||||
|
||||
@@ -36,7 +36,7 @@ $string['cliincorrectvalueerror'] = 'Erro: o valor "{$a->value}" não é permiti
|
||||
$string['cliincorrectvalueretry'] = 'Valor incorreto, por favor tente novamente';
|
||||
$string['clitypevalue'] = 'introduza valor';
|
||||
$string['clitypevaluedefault'] = 'introduza valor, pressione a tecla Enter para usar o valor predefinido ({$a})';
|
||||
$string['cliunknowoption'] = 'Opções desconhecidas: {$a} Por favor use a opção --help';
|
||||
$string['cliunknowoption'] = 'Opções desconhecidas: {$a}. Por favor use a opção --help';
|
||||
$string['cliyesnoprompt'] = 'digite s (para sim) ou n (para não)';
|
||||
$string['environmentrequireinstall'] = 'deve estar instalada e ativa';
|
||||
$string['environmentrequireversion'] = 'é requerida a versão {$a->needed} e está a correr a versão {$a->current}';
|
||||
|
||||
@@ -66,7 +66,9 @@ $string['pathsunsecuredataroot'] = 'A localização da pasta de dados não é se
|
||||
$string['pathswrongadmindir'] = 'A pasta <b>admin</b> não existe';
|
||||
$string['phpextension'] = 'Extensão <b>{$a}</b> do PHP';
|
||||
$string['phpversion'] = 'Versão do PHP';
|
||||
$string['phpversionhelp'] = '<p>A instalação do Moodle só é possível se o servidor tiver instalada a versão 4.3.0 ou 5.1.0 ( a versão 5.0.x apresenta vários problemas) ou superiores.</p><p>A versão atualmente instalada é <b>{$a}</b></p><p>É necessário atualizar esta versão do PHP ou mudar para um novo servidor que possua as referidas versões!<br />(Se a versão instalada for a 5.0.x é possível regredir para a versão 4.4.x)</p>';
|
||||
$string['phpversionhelp'] = '<p>A instalação do Moodle só é possível se no servidor estiver instalada, pelo menos, a versão 5.6.5 do PHP (a versão 7.x tem algumas limitações).</p>
|
||||
<p>A versão atualmente instalada é <b>{$a}</b>.</p>
|
||||
<p>É necessário atualizar a versão do PHP ou mudar para um novo servidor que possua a referida versão!</p>';
|
||||
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
|
||||
$string['welcomep20'] = 'A apresentação desta página confirma a correta instalação e ativação do pacote <strong>{$a->packname} {$a->packversion}</strong> no servidor.';
|
||||
$string['welcomep30'] = 'Esta versão do pacote <strong>{$a->installername}</strong> inclui as aplicações necessárias para o correto funcionamento do <strong>Moodle</strong>, nomeadamente:';
|
||||
|
||||
@@ -82,10 +82,9 @@ $string['pathsunsecuredataroot'] = 'A localização da pasta de dados não é se
|
||||
$string['pathswrongadmindir'] = 'Diretório Admin não existe';
|
||||
$string['phpextension'] = 'Extensão PHP {$a}';
|
||||
$string['phpversion'] = 'Versão do PHP';
|
||||
$string['phpversionhelp'] = '<p>Moodle requer a versão 4.3.0 de PHP ou posterior.</p>
|
||||
<p>A sua versão é a {$a}</p>
|
||||
<p>Atualize a versão do PHP!</p>
|
||||
(atenção, a versão 5.0.x tem muitos problemas - use a versão 5.1.0 ou a 4.4)';
|
||||
$string['phpversionhelp'] = '<p>O Moodle requer uma versão PHP de pelo menos 5.6.5 (o 7.x tem algumas limitações do motor). </p>
|
||||
<p>Atualmente, você está executando a versão {$ a}. </p>
|
||||
<p>Você deve atualizar o PHP ou migrar para um host com uma versão mais recente do PHP. </p>';
|
||||
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
|
||||
$string['welcomep20'] = 'Você está vendo esa página pois instalou com sucesso o pacote<strong>{$a->packname} {$a->packversion}</strong>. Parabéns!';
|
||||
$string['welcomep30'] = 'Esta versão do <strong>{$a->installername}</strong> inclui as aplicações para a criação de um ambiente em que <strong>Moodle</strong> possa operar:';
|
||||
|
||||
@@ -80,10 +80,9 @@ $string['pathsunsecuredataroot'] = 'Dataroot локација није безб
|
||||
$string['pathswrongadmindir'] = 'Админ директоријум не постоји';
|
||||
$string['phpextension'] = '{$a} PHP екстензија';
|
||||
$string['phpversion'] = 'PHP верзија';
|
||||
$string['phpversionhelp'] = '<p>Moodle захтева најмање PHP верзију 4.3.0 или 5.1.0 (5.0.x има бројне уочене проблеме).</p>
|
||||
$string['phpversionhelp'] = '<p>Moodle захтева најмање PHP верзију 5.6.7 (7.0.x има нека ограничења).</p>
|
||||
<p>Тренутно користите верзију {$a}</p>
|
||||
<p>Морате надоградити PHP или преместити Moodle на веб сервер са новијом верзијом PHP-a!</br>
|
||||
(У случају верзије 5.0.x можете, такође, да се вратите на 4.4.x верзију)</p>';
|
||||
<p>Морате да надоградите PHP или да преместити Moodle на веб сервер са новијом верзијом PHP-a.</p>';
|
||||
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
|
||||
$string['welcomep20'] = 'Ову страницу видите зато што сте успешно инсталирали и покренули <strong>{$a->packname} {$a->packversion}</strong> пакет на свом серверу. Честитамо!';
|
||||
$string['welcomep30'] = 'Ово издање <strong>{$a->installername}</strong> укључује апликације за креирање окружења у којем ће <strong>Moodle</strong> успешно функционисати, конкретно:';
|
||||
|
||||
@@ -80,10 +80,9 @@ $string['pathsunsecuredataroot'] = 'Dataroot lokacija nije bezbedna';
|
||||
$string['pathswrongadmindir'] = 'Admin direktorijum ne postoji';
|
||||
$string['phpextension'] = '{$a} PHP ekstenѕija';
|
||||
$string['phpversion'] = 'PHP verzija';
|
||||
$string['phpversionhelp'] = '<p>Moodle zahteva najmanje PHP verziju 4.3.0 ili 5.1.0 (5.0.x ima brojne uočene probleme).</p>
|
||||
$string['phpversionhelp'] = '<p>Moodle zahteva najmanje PHP verziju 5.6.7 (7.0.x ima neka ograničenja).</p>
|
||||
<p>Trenutno koristite verziju {$a}</p>
|
||||
<p>Morate nadograditi PHP ili premestiti Moodle na veb server sa novijom verzijom PHP-a!</br>
|
||||
(U slučaju verzije 5.0.x možete, takođe, da se vratite na 4.4.x verziju)</p>';
|
||||
<p>Morate da nadogradite PHP ili da premestiti Moodle na veb server sa novijom verzijom PHP-a.</p>';
|
||||
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
|
||||
$string['welcomep20'] = 'Ovu stranicu vidite zato što ste uspešno instalirali i pokrenuli <strong>{$a->packname} {$a->packversion}</strong> paket na svom serveru. Čestitamo!';
|
||||
$string['welcomep30'] = 'Ovo izdanje <strong>{$a->installername}</strong> uključuje aplikacije za kreiranje okruženja u kojem će <strong>Moodle</strong> uspešno funkcionisati, konkretno:';
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
$string['language'] = 'Dil';
|
||||
$string['moodlelogo'] = 'Moodle logo';
|
||||
$string['moodlelogo'] = 'Moodle logosu';
|
||||
$string['next'] = 'Sonraki';
|
||||
$string['previous'] = 'Önceki';
|
||||
$string['reload'] = 'Tekrar yükle';
|
||||
|
||||
+3
-1
@@ -383,7 +383,7 @@ $string['courseswithsummarieslimit'] = 'Courses with summaries limit';
|
||||
$string['creatornewroleid'] = 'Creators\' role in new courses';
|
||||
$string['creatornewroleid_help'] = 'If the user does not already have the permission to manage the new course, the user is automatically enrolled using this role.';
|
||||
$string['cron'] = 'Cron';
|
||||
$string['cron_help'] = 'The cron.php maintenance script assists some of Moodle\'s modules to perform tasks on a scheduled basis, such as mailing out copies of new forum posts. A mechanism is required to run the script regularly e.g. every 5 minutes.';
|
||||
$string['cron_help'] = 'The cron.php script runs a number of tasks at different scheduled intervals, such as sending forum post notification emails. The script should be run regularly - ideally every minute.';
|
||||
$string['cron_link'] = 'admin/cron';
|
||||
$string['cronclionly'] = 'Cron execution via command line only';
|
||||
$string['cronerrorclionly'] = 'Sorry, internet access to this page has been disabled by the administrator.';
|
||||
@@ -621,6 +621,7 @@ $string['iplookupinfo'] = 'By default Moodle uses the free online NetGeo (The In
|
||||
It is recommended to install local copy of free GeoLite2 City database from MaxMind.<br />
|
||||
IP address location is displayed on simple map or using Google Maps. Please note that you need to have a Google account and apply for free Google Maps API key to enable interactive maps.';
|
||||
$string['iplookupmaxmindnote'] = 'This product includes GeoLite2 data created by MaxMind, available from <a href="http://www.maxmind.com">http://www.maxmind.com</a>.';
|
||||
$string['ishttpswarning'] = 'It has been detected that your site is not secured using HTTPS. It is strongly recommended to migrate your site to HTTPS for increased security and improved integration with other systems.';
|
||||
$string['keeptagnamecase'] = 'Keep tag name casing';
|
||||
$string['lang'] = 'Default language';
|
||||
$string['langcache'] = 'Cache language menu';
|
||||
@@ -799,6 +800,7 @@ $string['numberofstrings'] = 'Total number of strings: {$a->strings}<br />Missin
|
||||
$string['onlynoreply'] = 'Only when from a no-reply address';
|
||||
$string['opcacherecommended'] = 'PHP opcode caching improves performance and lowers memory requirements, OPcache extension is recommended and fully supported.';
|
||||
$string['opensslrecommended'] = 'Installing the optional OpenSSL library is highly recommended -- it enables Moodle Networking functionality.';
|
||||
$string['opensslrequired'] = 'The OpenSSL PHP extension is now required by Moodle to provide stronger cryptographic services.';
|
||||
$string['opentogoogle'] = 'Open to Google';
|
||||
$string['optionalmaintenancemessage'] = 'Optional maintenance message';
|
||||
$string['order1'] = 'First';
|
||||
|
||||
@@ -79,6 +79,7 @@ You should fix this issue on any production site where you are planning to issue
|
||||
|
||||
The only URL required for verification is [your-site-url]/badges/assertion.php so if you are able to modify your firewall to allow external access to that file, badge verification will still work.';
|
||||
$string['backpackbadges'] = 'You have {$a->totalbadges} badge(s) displayed from {$a->totalcollections} collection(s). <a href="mybackpack.php">Change backpack settings</a>.';
|
||||
$string['backpackcannotsendverification'] = 'Cannot send verification email';
|
||||
$string['backpackconnection'] = 'Backpack connection';
|
||||
$string['backpackconnection_help'] = 'This page allows you to set up connection to an external backpack provider. Connecting to a backpack lets you display external badges within this site and push badges earned here to your backpack.
|
||||
|
||||
@@ -90,6 +91,27 @@ $string['personaconnection'] = 'Sign in with your email';
|
||||
$string['personaconnection_help'] = 'Persona is a system for identifying yourself across the web, using an email address that you own. The Open Badges backpack uses Persona as a login system, so to be able to connect to a backpack you will need a Persona account.
|
||||
|
||||
For more information about Persona visit <a href="https://login.persona.org/about">https://login.persona.org/about</a>.';
|
||||
$string['backpackconnectioncancelattempt'] = 'Connect using a different email address';
|
||||
$string['backpackconnectionconnect'] = 'Connect to backpack';
|
||||
$string['backpackconnectionresendemail'] = 'Resend verification email';
|
||||
$string['backpackconnectionunexpectedresult'] = 'There was a problem connecting to your backpack. Please try again.<br><br>If the problem persists, contact your administrator.';
|
||||
$string['backpackemailverificationpending'] = 'Verification pending';
|
||||
$string['backpackemailverifyemailbody'] = 'Hi,
|
||||
|
||||
A new connection to your OpenBadges backpack has been requested from \'{$a->sitename}\' using your email address.
|
||||
|
||||
To confirm and activate the connection to your backpack, please go to
|
||||
|
||||
{$a->link}
|
||||
|
||||
In most mail programs, this should appear as a blue link which you can just click on. If that doesn\'t work, then cut and paste the address into the address line at the top of your web browser.
|
||||
|
||||
If you need help, please contact the site administrator,
|
||||
{$a->admin}';
|
||||
$string['backpackemailverifyemailsubject'] = '{$a}: OpenBadges Backpack email verification';
|
||||
$string['backpackemailverifypending'] = 'A verification email has been sent to <strong>{$a}</strong>. Click on the verification link in the email to activate your Backpack connection.';
|
||||
$string['backpackemailverifysuccess'] = 'Thanks for verifying your email address. You are now connected to your backpack.';
|
||||
$string['backpackemailverifytokenmismatch'] = 'The token in the link you clicked does not match the stored token. Make sure you clicked the link in most recent email you received.';
|
||||
$string['backpackimport'] = 'Badge import settings';
|
||||
$string['backpackimport_help'] = 'After the backpack connection is successfully established, badges from your backpack can be displayed on your badges page and your profile page.
|
||||
|
||||
|
||||
@@ -185,6 +185,7 @@ $string['viewmyentriesaboutcourse'] = 'View my entries about this course';
|
||||
$string['viewsiteentries'] = 'View all entries';
|
||||
$string['viewuserentries'] = 'View all entries by {$a}';
|
||||
$string['worldblogs'] = 'The world can read entries set to be world-accessible';
|
||||
$string['wrongexternalid'] = 'Wrong external blog id';
|
||||
$string['wrongpostid'] = 'Wrong blog post id';
|
||||
$string['page-blog-edit'] = 'Blog editing pages';
|
||||
$string['page-blog-index'] = 'Blog listing pages';
|
||||
|
||||
@@ -61,12 +61,26 @@ $string['erroraddingevent'] = 'Failed to add event';
|
||||
$string['errorbadsubscription'] = 'Calendar subscription not found.';
|
||||
$string['errorbeforecoursestart'] = 'Cannot set event before course start date';
|
||||
$string['errorcannotimport'] = 'You cannot set up a calendar subscription at this time.';
|
||||
$string['errorhasuntilandcount'] = 'Either UNTIL or COUNT may appear in a recurrence rule, but UNTIL and COUNT MUST NOT occur in the same recurrence rule.';
|
||||
$string['errorinvalidbydaysuffix'] = 'Valid values for the day of the week parts of the BYDAY rule are MO, TU, WE, TH, FR, SA and SU';
|
||||
$string['errorinvalidbydayprefix'] = 'Integer values preceding BYDAY rules can only be present for MONTHLY or YEARLY RRULE.';
|
||||
$string['errorinvalidbyhour'] = 'Valid values for the BYHOUR rule are 0 to 23.';
|
||||
$string['errorinvalidinterval'] = 'The value for the INTERVAL rule must be a positive integer.';
|
||||
$string['errorinvalidbyminute'] = 'Valid values for the BYMINUTE rule are 0 to 59.';
|
||||
$string['errorinvalidbymonth'] = 'Valid values for the BYMONTH rule are 1 to 12.';
|
||||
$string['errorinvalidbymonthday'] = 'Valid values for the BYMONTHDAY rule are 1 to 31 or -31 to -1.';
|
||||
$string['errorinvalidbysetpos'] = 'Valid values for the BYSETPOS rule are 1 to 366 or -366 to -1.';
|
||||
$string['errorinvalidbyweekno'] = 'Valid values for the BYWEEKNO rule are 1 to 53 or -53 to -1.';
|
||||
$string['errorinvalidbyyearday'] = 'Valid values for the BYYEARDAY rule are 1 to 366 or -366 to -1.';
|
||||
$string['errorinvalidbysecond'] = 'Valid values for the BYSECOND rule are 0 to 59.';
|
||||
$string['errorinvaliddate'] = 'Invalid date';
|
||||
$string['errorinvalidminutes'] = 'Specify duration in minutes by giving a number between 1 and 999.';
|
||||
$string['errorinvalidrepeats'] = 'Specify the number of events by giving a number between 1 and 99.';
|
||||
$string['errorinvalidicalurl'] = 'The given iCal URL is invalid.';
|
||||
$string['errormustbeusedwithotherbyrule'] = 'The BYSETPOS rule must only be used in conjunction with another BYxxx rule part.';
|
||||
$string['errornodescription'] = 'Description is required';
|
||||
$string['errornoeventname'] = 'Name is required';
|
||||
$string['errornonyearlyfreqwithbyweekno'] = 'The BYWEEKNO rule is only valid for YEARLY rules.';
|
||||
$string['errorrequiredurlorfile'] = 'Either a URL or a file is required to import a calendar.';
|
||||
$string['errorrrule'] = 'The passed rrule seems incorrect';
|
||||
$string['errorrrulefreq'] = 'The rrule has an invalid frequency parameter';
|
||||
|
||||
+1
-1
@@ -393,7 +393,7 @@ $string['moduledisable'] = 'This module ({$a}) has been disabled for this partic
|
||||
$string['moduledoesnotexist'] = 'This module does not exist';
|
||||
$string['moduleinstancedoesnotexist'] = 'The instance of this module does not exist';
|
||||
$string['modulemissingcode'] = 'Module {$a} is missing the code needed to perform this function';
|
||||
$string['movecatcontentstoroot'] = 'Moving the category content to root is not allowed. You must move the contents to an existant category!';
|
||||
$string['movecatcontentstoroot'] = 'Moving the category content to root is not allowed. You must move the contents to an existing category!';
|
||||
$string['movecategorynotpossible'] = 'You cannot move category \'{$a}\' into the selected category.';
|
||||
$string['movecategoryownparent'] = 'You cannot make category \'{$a}\' a parent of itself.';
|
||||
$string['movecategoryparentconflict'] = 'You cannot make category \'{$a}\' a subcategory of one of its own subcategories.';
|
||||
|
||||
+1
-1
@@ -219,7 +219,7 @@ $string['pathswrongadmindir'] = 'Admin directory does not exist';
|
||||
$string['pgsqlextensionisnotpresentinphp'] = 'PHP has not been properly configured with the PGSQL extension so that it can communicate with PostgreSQL. Please check your php.ini file or recompile PHP.';
|
||||
$string['phpextension'] = '{$a} PHP extension';
|
||||
$string['phpversion'] = 'PHP version';
|
||||
$string['phpversionhelp'] = '<p>Moodle requires a PHP version of at least 5.6.5 (7.x has some engine limitations).</p>
|
||||
$string['phpversionhelp'] = '<p>Moodle requires a PHP version of at least 5.6.5 or 7.1 (7.0.x has some engine limitations).</p>
|
||||
<p>You are currently running version {$a}.</p>
|
||||
<p>You must upgrade PHP or move to a host with a newer version of PHP.</p>';
|
||||
$string['releasenoteslink'] = 'For information about this version of Moodle, please see the release notes at {$a}';
|
||||
|
||||
+36
-5
@@ -40,17 +40,48 @@ $string['application/msword'] = 'Word document';
|
||||
$string['application/pdf'] = 'PDF document';
|
||||
$string['application/vnd.moodle.backup'] = 'Moodle backup';
|
||||
$string['application/vnd.ms-excel'] = 'Excel spreadsheet';
|
||||
$string['application/vnd.ms-excel.sheet.macroEnabled.12'] = 'Excel 2007 macro-enabled workbook';
|
||||
$string['application/vnd.ms-powerpoint'] = 'Powerpoint presentation';
|
||||
$string['application/vnd.openxmlformats-officedocument.presentationml.presentation'] = 'Powerpoint presentation';
|
||||
$string['application/vnd.openxmlformats-officedocument.presentationml.slideshow'] = 'Powerpoint slideshow';
|
||||
$string['application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'] = 'Excel spreadsheet';
|
||||
$string['application/vnd.openxmlformats-officedocument.spreadsheetml.template'] = 'Excel template';
|
||||
$string['application/vnd.openxmlformats-officedocument.wordprocessingml.document'] = 'Word document';
|
||||
$string['application/vnd.oasis.opendocument.spreadsheet'] = 'OpenDocument Spreadsheet';
|
||||
$string['application/vnd.oasis.opendocument.spreadsheet-template'] = 'OpenDocument Spreadsheet template';
|
||||
$string['application/vnd.oasis.opendocument.text'] = 'OpenDocument Text document';
|
||||
$string['application/vnd.oasis.opendocument.text-template'] = 'OpenDocument Text template';
|
||||
$string['application/vnd.oasis.opendocument.text-web'] = 'OpenDocument Web page template';
|
||||
$string['application/vnd.openxmlformats-officedocument.presentationml.presentation'] = 'Powerpoint 2007 presentation';
|
||||
$string['application/vnd.openxmlformats-officedocument.presentationml.slideshow'] = 'Powerpoint 2007 slideshow';
|
||||
$string['application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'] = 'Excel 2007 spreadsheet';
|
||||
$string['application/vnd.openxmlformats-officedocument.spreadsheetml.template'] = 'Excel 2007 template';
|
||||
$string['application/vnd.openxmlformats-officedocument.wordprocessingml.document'] = 'Word 2007 document';
|
||||
$string['application/x-iwork-keynote-sffkey'] = 'iWork Keynote presentation';
|
||||
$string['application/x-iwork-numbers-sffnumbers'] = 'iWork Numbers spreadsheet';
|
||||
$string['application/x-iwork-pages-sffpages'] = 'iWork Pages document';
|
||||
$string['application/x-javascript'] = 'JavaScript source';
|
||||
$string['application/x-mspublisher'] = 'Publisher document';
|
||||
$string['application/x-shockwave-flash'] = 'Flash animation';
|
||||
$string['application/xhtml_xml'] = 'XHTML document';
|
||||
$string['archive'] = 'Archive ({$a->EXT})';
|
||||
$string['audio'] = 'Audio file ({$a->EXT})';
|
||||
$string['default'] = '{$a->mimetype}';
|
||||
$string['document/unknown'] = 'File';
|
||||
$string['group:archive'] = 'Archive files';
|
||||
$string['group:audio'] = 'Audio files';
|
||||
$string['group:document'] = 'Document files';
|
||||
$string['group:html_audio'] = 'Audio files natively supported by browsers';
|
||||
$string['group:html_track'] = 'HTML track files';
|
||||
$string['group:html_video'] = 'Video files natively supported by browsers';
|
||||
$string['group:image'] = 'Image files';
|
||||
$string['group:presentation'] = 'Presentation files';
|
||||
$string['group:sourcecode'] = 'Source code';
|
||||
$string['group:spreadsheet'] = 'Spreadsheet files';
|
||||
$string['group:video'] = 'Video files';
|
||||
$string['group:web_audio'] = 'Audio files used on the web';
|
||||
$string['group:web_file'] = 'Web files';
|
||||
$string['group:web_image'] = 'Image files used on the web';
|
||||
$string['group:web_video'] = 'Video files used on the web';
|
||||
$string['image'] = 'Image ({$a->MIMETYPE2})';
|
||||
$string['image/vnd.microsoft.icon'] = 'Windows icon';
|
||||
$string['text/css'] = 'Cascading Style-Sheet';
|
||||
$string['text/csv'] = 'Comma-separated values';
|
||||
$string['text/html'] = 'HTML document';
|
||||
$string['text/plain'] = 'Text file';
|
||||
$string['text/rtf'] = 'RTF document';
|
||||
|
||||
Vendored
+1
-1
@@ -1 +1 @@
|
||||
define(["jquery","core/config"],function(a,b){var c=function(a){var b,c,d=this,e=null,f=0;for(f=0;f<d.length;f++){if(b=d[f],c=a[f],"undefined"==typeof c){e=new Error("missing response");break}if(c.error!==!1){e=c.exception;break}b.deferred.resolve(c.data)}if(null!==e)for(;f<d.length;f++)b=d[f],b.deferred.reject(e)},d=function(a,b){var c=this,d=0;for(d=0;d<c.length;d++){var e=c[d];e.deferred.reject(b)}};return{call:function(e,f,g){var h,i=[],j=[];for("undefined"==typeof g&&(g=!0),"undefined"==typeof f&&(f=!0),h=0;h<e.length;h++){var k=e[h];i.push({index:h,methodname:k.methodname,args:k.args}),k.deferred=a.Deferred(),j.push(k.deferred.promise()),"undefined"!=typeof k.done&&k.deferred.done(k.done),"undefined"!=typeof k.fail&&k.deferred.fail(k.fail),k.index=h}i=JSON.stringify(i);var l={type:"POST",data:i,context:e,dataType:"json",processData:!1,async:f,contentType:"application/json"},m=b.wwwroot+"/lib/ajax/service.php?sesskey="+b.sesskey;return g||(m=b.wwwroot+"/lib/ajax/service-nologin.php?sesskey="+b.sesskey),f?a.ajax(m,l).done(c).fail(d):(l.success=c,l.error=d,a.ajax(m,l)),j}}});
|
||||
define(["jquery","core/config"],function(a,b){var c=function(a){var b,c,d=this,e=null,f=0;for(f=0;f<d.length;f++){if(b=d[f],c=a[f],"undefined"==typeof c){e=new Error("missing response");break}if(c.error!==!1){e=c.exception;break}b.deferred.resolve(c.data)}if(null!==e)for(;f<d.length;f++)b=d[f],b.deferred.reject(e)},d=function(a,b){var c=this,d=0;for(d=0;d<c.length;d++){var e=c[d];e.deferred.reject(b)}};return{call:function(e,f,g){var h,i=[],j=[],k=[],l="";for("undefined"==typeof g&&(g=!0),"undefined"==typeof f&&(f=!0),h=0;h<e.length;h++){var m=e[h];i.push({index:h,methodname:m.methodname,args:m.args}),m.deferred=a.Deferred(),j.push(m.deferred.promise()),"undefined"!=typeof m.done&&m.deferred.done(m.done),"undefined"!=typeof m.fail&&m.deferred.fail(m.fail),m.index=h,k.push(m.methodname)}l=k.length<=5?k.sort().join():k.length+"-method-calls",i=JSON.stringify(i);var n={type:"POST",data:i,context:e,dataType:"json",processData:!1,async:f,contentType:"application/json"},o="service.php";g||(o="service-nologin.php");var p=b.wwwroot+"/lib/ajax/"+o+"?sesskey="+b.sesskey+"&info="+l;return f?a.ajax(p,n).done(c).fail(d):(n.success=c,n.error=d,a.ajax(p,n)),j}}});
|
||||
Vendored
+1
-1
@@ -1 +1 @@
|
||||
define(["jquery","core/ajax","core/localstorage"],function(a,b,c){var d=[];return{get_string:function(a,b,c,d){var e=this.get_strings([{key:a,component:b,param:c,lang:d}]);return e.then(function(a){return a[0]})},get_strings:function(e){var f,g=a.Deferred(),h=[],i=0,j=!1;for(i=0;i<e.length;i++)if(f=e[i],"undefined"==typeof f.lang&&(f.lang=a("html").attr("lang").replace("-","_")),f.cacheKey="core_str/"+f.key+"/"+f.component+"/"+f.lang,"undefined"==typeof M.str[f.component]||"undefined"==typeof M.str[f.component][f.key]){var k=c.get(f.cacheKey);k?("undefined"==typeof M.str[f.component]&&(M.str[f.component]=[]),M.str[f.component][f.key]=k):j=!0}if(j){var l=[],m=[],n=function(a){this.resolve(a)},o=function(a){this.reject(a)};for(i=0;i<e.length;i++)if(f=e[i],"undefined"!=typeof d[f.cacheKey])m.push(d[f.cacheKey]);else{var p=a.Deferred();l.push({methodname:"core_get_string",args:{stringid:f.key,component:f.component,lang:f.lang,stringparams:[]},done:n.bind(p),fail:o.bind(p)}),d[f.cacheKey]=p.promise(),m.push(d[f.cacheKey])}l.length>0&&b.call(l,!0,!1),a.when.apply(null,m).done(function(){var a=0;for(a=0;a<arguments.length;a++)f=e[a],"undefined"==typeof M.str[f.component]&&(M.str[f.component]=[]),M.str[f.component][f.key]=arguments[a],c.set("core_str/"+f.key+"/"+f.component+"/"+f.lang,arguments[a]),h[a]=M.util.get_string(f.key,f.component,f.param).trim();g.resolve(h)}).fail(function(a){g.reject(a)})}else{for(i=0;i<e.length;i++)f=e[i],h[i]=M.util.get_string(f.key,f.component,f.param);g.resolve(h)}return g.promise()}}});
|
||||
define(["jquery","core/ajax","core/localstorage"],function(a,b,c){var d=[];return{get_string:function(a,b,c,d){var e=this.get_strings([{key:a,component:b,param:c,lang:d}]);return e.then(function(a){return a[0]})},get_strings:function(e){var f,g=a.Deferred(),h=[],i=0,j=!1;for(i=0;i<e.length;i++)if(f=e[i],"undefined"==typeof f.lang&&(f.lang=a("html").attr("lang").replace(/-/g,"_")),f.cacheKey="core_str/"+f.key+"/"+f.component+"/"+f.lang,"undefined"==typeof M.str[f.component]||"undefined"==typeof M.str[f.component][f.key]){var k=c.get(f.cacheKey);k?("undefined"==typeof M.str[f.component]&&(M.str[f.component]=[]),M.str[f.component][f.key]=k):j=!0}if(j){var l=[],m=[],n=function(a){this.resolve(a)},o=function(a){this.reject(a)};for(i=0;i<e.length;i++)if(f=e[i],"undefined"!=typeof d[f.cacheKey])m.push(d[f.cacheKey]);else{var p=a.Deferred();l.push({methodname:"core_get_string",args:{stringid:f.key,component:f.component,lang:f.lang,stringparams:[]},done:n.bind(p),fail:o.bind(p)}),d[f.cacheKey]=p.promise(),m.push(d[f.cacheKey])}l.length>0&&b.call(l,!0,!1),a.when.apply(null,m).done(function(){var a=0;for(a=0;a<arguments.length;a++)f=e[a],"undefined"==typeof M.str[f.component]&&(M.str[f.component]=[]),M.str[f.component][f.key]=arguments[a],c.set("core_str/"+f.key+"/"+f.component+"/"+f.lang,arguments[a]),h[a]=M.util.get_string(f.key,f.component,f.param).trim();g.resolve(h)}).fail(function(a){g.reject(a)})}else{for(i=0;i<e.length;i++)f=e[i],h[i]=M.util.get_string(f.key,f.component,f.param);g.resolve(h)}return g.promise()}}});
|
||||
Vendored
+1
-1
@@ -1 +1 @@
|
||||
define(["core/mustache","jquery","core/ajax","core/str","core/notification","core/url","core/log","core/config","core/localstorage","core/event","core/yui","core/log"],function(a,b,c,d,e,f,g,h,i,j,k,l){var m=0,n={},o={},p=function(){this.requiredStrings=[],this.requiredJS=[],this.currentThemeName=""};p.prototype.requiredStrings=null,p.prototype.requiredJS=null,p.prototype.currentThemeName="",p.prototype.getTemplate=function(a){var d=a.split("/"),e=d.shift(),f=d.shift(),g=this.currentThemeName+"/"+a;if(g in o)return o[g];var h=i.get("core_template/"+g);if(h)return n[g]=h,o[g]=b.Deferred().resolve(h).promise(),o[g];var j=c.call([{methodname:"core_output_load_template",args:{component:e,template:f,themename:this.currentThemeName}}],!0,!1);return o[g]=j[0].then(function(a){return n[g]=a,i.set("core_template/"+g,a),a}),o[g]},p.prototype.partialHelper=function(a){var b=this.currentThemeName+"/"+a;return b in n||e.exception(new Error("Failed to pre-fetch the template: "+a)),n[b]},p.prototype.pixHelper=function(b,c,d){var e,g=c.split(","),h="",i="",j="";g.length>0&&(h=g.shift().trim()),g.length>0&&(i=g.shift().trim()),g.length>0&&(j=g.join(",").trim());var k=f.imageUrl(h,i),l={attributes:[{name:"src",value:k},{name:"alt",value:d(j)},{name:"title",value:d(j)},{name:"class",value:"smallicon"}]},m=this.currentThemeName+"/core/pix_icon",o=n[m];return e=a.render(o,l,this.partialHelper.bind(this)),e.trim()},p.prototype.jsHelper=function(a,b,c){return this.requiredJS.push(c(b,a)),""},p.prototype.stringHelper=function(a,b,c){var d=b.split(","),e="",f="",g="";d.length>0&&(e=d.shift().trim()),d.length>0&&(f=d.shift().trim()),d.length>0&&(g=d.join(",").trim()),""!==g&&(g=c(g,a)),0===g.indexOf("{")&&0!==g.indexOf("{{")&&(g=JSON.parse(g));var h=this.requiredStrings.length;return this.requiredStrings.push({key:e,component:f,param:g}),"[[_s"+h+"]]"},p.prototype.quoteHelper=function(a,b,c){var d=c(b.trim(),a);return d=d.replace('"','\\"').replace(/([\{\}]{2,3})/g,"{{=<% %>=}}$1<%={{ }}=%>"),'"'+d+'"'},p.prototype.addHelpers=function(a,b){this.currentThemeName=b,this.requiredStrings=[],this.requiredJS=[],a.uniqid=m++,a.str=function(){return this.stringHelper.bind(this,a)}.bind(this),a.pix=function(){return this.pixHelper.bind(this,a)}.bind(this),a.js=function(){return this.jsHelper.bind(this,a)}.bind(this),a.quote=function(){return this.quoteHelper.bind(this,a)}.bind(this),a.globals={config:h},a.currentTheme=b},p.prototype.getJS=function(a){var b="";return this.requiredJS.length>0&&(b=this.requiredJS.join(";\n")),this.treatStringsInContent(b,a)},p.prototype.treatStringsInContent=function(a,b){var c,d,e,f,g,h,i=/\[\[_s\d+\]\]/;do{for(c="",d=a.search(i);d>-1;){c+=a.substring(0,d),a=a.substr(d),e="",f=4,g=a.substr(f,1);do e+=g,f++,g=a.substr(f,1);while("]"!=g);h=b[parseInt(e,10)],"undefined"==typeof h&&(l.debug("Could not find string for pattern [[_s"+e+"]]."),h=""),c+=h,a=a.substr(6+e.length),d=a.search(i)}a=c+a,d=a.search(i)}while(d>-1);return a},p.prototype.doRender=function(c,e,f){return this.currentThemeName=f,this.getTemplate("core/pix_icon").then(function(){this.addHelpers(e,f);var g=a.render(c,e,this.partialHelper.bind(this));return this.requiredStrings.length>0?d.get_strings(this.requiredStrings).then(function(a){return g=this.treatStringsInContent(g,a),b.Deferred().resolve(g,this.getJS(a)).promise()}.bind(this)):b.Deferred().resolve(g.trim(),this.getJS([])).promise()}.bind(this))};var q=function(a){if(""!==a.trim()){var c=b("<script>").attr("type","text/javascript").html(a);b("head").append(c)}},r=function(a,c,d,e){var f=b(a);if(f.length){var g=b(c),h=null;e?(h=new k.NodeList(f.children().get()),h.destroy(!0),f.empty(),f.append(g)):(h=new k.NodeList(f.get()),h.destroy(!0),f.replaceWith(g)),q(d),j.notifyFilterContentUpdated(g)}};p.prototype.scanForPartials=function(b){var c=a.parse(b),d=[],e=function(a,b){var c,d;for(c=0;c<a.length;c++)d=a[c],">"!=d[0]&&"<"!=d[0]||b.push(d[1]),d.length>4&&e(d[4],b)};return e(c,d),d},p.prototype.cachePartials=function(a){return this.getTemplate(a).then(function(a){var c,d=this.scanForPartials(a),e=[];for(c=0;c<d.length;c++){var f=this.currentThemeName+"/"+d[c];f in o||e.push(this.cachePartials(d[c]))}return b.when.apply(b,e).then(function(){return a})}.bind(this))},p.prototype.render=function(a,b,c){return"undefined"==typeof c&&(c=h.theme),this.currentThemeName=c,this.cachePartials(a).then(function(a){return this.doRender(a,b,c)}.bind(this))};var s=function(a,c,d){var e=b(a);e.length&&(e.prepend(c),q(d),j.notifyFilterContentUpdated(e))},t=function(a,c,d){var e=b(a);e.length&&(e.append(c),q(d),j.notifyFilterContentUpdated(e))};return{render:function(a,b,c){var d=new p;return d.render(a,b,c)},runTemplateJS:q,replaceNodeContents:function(a,b,c){r(a,b,c,!0)},replaceNode:function(a,b,c){r(a,b,c,!1)},prependNodeContents:function(a,b,c){s(a,b,c)},appendNodeContents:function(a,b,c){t(a,b,c)}}});
|
||||
define(["core/mustache","jquery","core/ajax","core/str","core/notification","core/url","core/log","core/config","core/localstorage","core/event","core/yui","core/log"],function(a,b,c,d,e,f,g,h,i,j,k,l){var m=0,n={},o={},p=function(){this.requiredStrings=[],this.requiredJS=[],this.currentThemeName=""};p.prototype.requiredStrings=null,p.prototype.requiredJS=null,p.prototype.currentThemeName="",p.prototype.getTemplate=function(a){var d=a.split("/"),e=d.shift(),f=d.shift(),g=this.currentThemeName+"/"+a;if(g in o)return o[g];var h=i.get("core_template/"+g);if(h)return n[g]=h,o[g]=b.Deferred().resolve(h).promise(),o[g];var j=c.call([{methodname:"core_output_load_template",args:{component:e,template:f,themename:this.currentThemeName}}],!0,!1);return o[g]=j[0].then(function(a){return n[g]=a,i.set("core_template/"+g,a),a}),o[g]},p.prototype.partialHelper=function(a){var b=this.currentThemeName+"/"+a;return b in n||e.exception(new Error("Failed to pre-fetch the template: "+a)),n[b]},p.prototype.pixHelper=function(b,c,d){var e,g=c.split(","),h="",i="",j="";g.length>0&&(h=g.shift().trim()),g.length>0&&(i=g.shift().trim()),g.length>0&&(j=g.join(",").trim());var k=f.imageUrl(h,i),l={attributes:[{name:"src",value:k},{name:"alt",value:d(j)},{name:"title",value:d(j)},{name:"class",value:"smallicon"}]},m=this.currentThemeName+"/core/pix_icon",o=n[m];return e=a.render(o,l,this.partialHelper.bind(this)),e.trim()},p.prototype.jsHelper=function(a,b,c){return this.requiredJS.push(c(b,a)),""},p.prototype.stringHelper=function(a,b,c){var d=b.split(","),e="",f="",g="";d.length>0&&(e=d.shift().trim()),d.length>0&&(f=d.shift().trim()),d.length>0&&(g=d.join(",").trim()),""!==g&&(g=c(g,a)),0===g.indexOf("{")&&0!==g.indexOf("{{")&&(g=JSON.parse(g));var h=this.requiredStrings.length;return this.requiredStrings.push({key:e,component:f,param:g}),"[[_s"+h+"]]"},p.prototype.quoteHelper=function(a,b,c){var d=c(b.trim(),a);return d=d.replace('"','\\"').replace(/([\{\}]{2,3})/g,"{{=<% %>=}}$1<%={{ }}=%>"),'"'+d+'"'},p.prototype.addHelpers=function(a,b){this.currentThemeName=b,this.requiredStrings=[],this.requiredJS=[],a.uniqid=m++,a.str=function(){return this.stringHelper.bind(this,a)}.bind(this),a.pix=function(){return this.pixHelper.bind(this,a)}.bind(this),a.js=function(){return this.jsHelper.bind(this,a)}.bind(this),a.quote=function(){return this.quoteHelper.bind(this,a)}.bind(this),a.globals={config:h},a.currentTheme=b},p.prototype.getJS=function(a){var b="";return this.requiredJS.length>0&&(b=this.requiredJS.join(";\n")),this.treatStringsInContent(b,a)},p.prototype.treatStringsInContent=function(a,b){var c,d,e,f,g,h,i=/\[\[_s\d+\]\]/;do{for(c="",d=a.search(i);d>-1;){c+=a.substring(0,d),a=a.substr(d),e="",f=4,g=a.substr(f,1);do e+=g,f++,g=a.substr(f,1);while("]"!=g);h=b[parseInt(e,10)],"undefined"==typeof h&&(l.debug("Could not find string for pattern [[_s"+e+"]]."),h=""),c+=h,a=a.substr(6+e.length),d=a.search(i)}a=c+a,d=a.search(i)}while(d>-1);return a},p.prototype.doRender=function(c,e,f){return this.currentThemeName=f,this.getTemplate("core/pix_icon").then(function(){this.addHelpers(e,f);var g=a.render(c,e,this.partialHelper.bind(this));return this.requiredStrings.length>0?d.get_strings(this.requiredStrings).then(function(a){return g=this.treatStringsInContent(g,a),b.Deferred().resolve(g,this.getJS(a)).promise()}.bind(this)):b.Deferred().resolve(g.trim(),this.getJS([])).promise()}.bind(this))};var q=function(a){if(""!==a.trim()){var c=b("<script>").attr("type","text/javascript").html(a);b("head").append(c)}},r=function(a,c,d,e){var f=b(a);if(f.length){var g=b(c),h=null;e?(h=new k.NodeList(f.children().get()),h.destroy(!0),f.empty(),f.append(g)):(h=new k.NodeList(f.get()),h.destroy(!0),f.replaceWith(g)),q(d),j.notifyFilterContentUpdated(g)}};p.prototype.scanForPartials=function(b){var c=a.parse(b),d=[],e=function(a,b){var c,d;for(c=0;c<a.length;c++)d=a[c],">"!=d[0]&&"<"!=d[0]||b.push(d[1]),d.length>4&&e(d[4],b)};return e(c,d),d},p.prototype.cachePartials=function(a){return this.getTemplate(a).then(function(a){var c,d=this.scanForPartials(a),e=[];for(c=0;c<d.length;c++){var f=this.currentThemeName+"/"+d[c];f in o?e.push(o[f]):e.push(this.cachePartials(d[c]))}return b.when.apply(b,e).then(function(){return a})}.bind(this))},p.prototype.render=function(a,b,c){return"undefined"==typeof c&&(c=h.theme),this.currentThemeName=c,this.cachePartials(a).then(function(a){return this.doRender(a,b,c)}.bind(this))};var s=function(a,c,d){var e=b(a);e.length&&(e.prepend(c),q(d),j.notifyFilterContentUpdated(e))},t=function(a,c,d){var e=b(a);e.length&&(e.append(c),q(d),j.notifyFilterContentUpdated(e))};return{render:function(a,b,c){var d=new p;return d.render(a,b,c)},runTemplateJS:q,replaceNodeContents:function(a,b,c){r(a,b,c,!0)},replaceNode:function(a,b,c){r(a,b,c,!1)},prependNodeContents:function(a,b,c){s(a,b,c)},appendNodeContents:function(a,b,c){t(a,b,c)}}});
|
||||
+16
-5
@@ -111,7 +111,9 @@ define(['jquery', 'core/config'], function($, config) {
|
||||
call: function(requests, async, loginrequired) {
|
||||
var ajaxRequestData = [],
|
||||
i,
|
||||
promises = [];
|
||||
promises = [],
|
||||
methodInfo = [],
|
||||
requestInfo = '';
|
||||
|
||||
if (typeof loginrequired === "undefined") {
|
||||
loginrequired = true;
|
||||
@@ -137,6 +139,13 @@ define(['jquery', 'core/config'], function($, config) {
|
||||
request.deferred.fail(request.fail);
|
||||
}
|
||||
request.index = i;
|
||||
methodInfo.push(request.methodname);
|
||||
}
|
||||
|
||||
if (methodInfo.length <= 5) {
|
||||
requestInfo = methodInfo.sort().join();
|
||||
} else {
|
||||
requestInfo = methodInfo.length + '-method-calls';
|
||||
}
|
||||
|
||||
ajaxRequestData = JSON.stringify(ajaxRequestData);
|
||||
@@ -150,20 +159,22 @@ define(['jquery', 'core/config'], function($, config) {
|
||||
contentType: "application/json"
|
||||
};
|
||||
|
||||
var script = config.wwwroot + '/lib/ajax/service.php?sesskey=' + config.sesskey;
|
||||
var script = 'service.php';
|
||||
if (!loginrequired) {
|
||||
script = config.wwwroot + '/lib/ajax/service-nologin.php?sesskey=' + config.sesskey;
|
||||
script = 'service-nologin.php';
|
||||
}
|
||||
var url = config.wwwroot + '/lib/ajax/' + script +
|
||||
'?sesskey=' + config.sesskey + '&info=' + requestInfo;
|
||||
|
||||
// Jquery deprecated done and fail with async=false so we need to do this 2 ways.
|
||||
if (async) {
|
||||
$.ajax(script, settings)
|
||||
$.ajax(url, settings)
|
||||
.done(requestSuccess)
|
||||
.fail(requestFail);
|
||||
} else {
|
||||
settings.success = requestSuccess;
|
||||
settings.error = requestFail;
|
||||
$.ajax(script, settings);
|
||||
$.ajax(url, settings);
|
||||
}
|
||||
|
||||
return promises;
|
||||
|
||||
+1
-1
@@ -78,7 +78,7 @@ define(['jquery', 'core/ajax', 'core/localstorage'], function($, ajax, storage)
|
||||
for (i = 0; i < requests.length; i++) {
|
||||
request = requests[i];
|
||||
if (typeof request.lang === "undefined") {
|
||||
request.lang = $('html').attr('lang').replace('-', '_');
|
||||
request.lang = $('html').attr('lang').replace(/-/g, '_');
|
||||
}
|
||||
request.cacheKey = 'core_str/' + request.key + '/' + request.component + '/' + request.lang;
|
||||
if (typeof M.str[request.component] === "undefined" ||
|
||||
|
||||
@@ -517,9 +517,10 @@ define(['core/mustache',
|
||||
for (i = 0; i < partials.length; i++) {
|
||||
var searchKey = this.currentThemeName + '/' + partials[i];
|
||||
if (searchKey in templatePromises) {
|
||||
continue;
|
||||
fetchThemAll.push(templatePromises[searchKey]);
|
||||
} else {
|
||||
fetchThemAll.push(this.cachePartials(partials[i]));
|
||||
}
|
||||
fetchThemAll.push(this.cachePartials(partials[i]));
|
||||
}
|
||||
|
||||
return $.when.apply($, fetchThemAll).then(function() {
|
||||
|
||||
@@ -944,4 +944,22 @@ class behat_base extends Behat\MinkExtension\Context\RawMinkContext {
|
||||
}
|
||||
return $DB->get_record('user', ['id' => $userid]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Trigger click on node via javascript instead of actually clicking on it via pointer.
|
||||
*
|
||||
* This function resolves the issue of nested elements with click listeners or links - in these cases clicking via
|
||||
* the pointer may accidentally cause a click on the wrong element.
|
||||
* Example of issue: clicking to expand navigation nodes when the config value linkadmincategories is enabled.
|
||||
* @param NodeElement $node
|
||||
*/
|
||||
protected function js_trigger_click($node) {
|
||||
if (!$this->running_javascript()) {
|
||||
$node->click();
|
||||
}
|
||||
$this->ensure_node_is_visible($node); // Ensures hidden elements can't be clicked.
|
||||
$xpath = $node->getXpath();
|
||||
$script = "Syn.click({{ELEMENT}})";
|
||||
$this->getSession()->getDriver()->triggerSynScript($xpath, $script);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -90,7 +90,7 @@ abstract class core_filetypes {
|
||||
'dxr' => array('type' => 'application/x-director', 'icon' => 'flash'),
|
||||
'eps' => array('type' => 'application/postscript', 'icon' => 'eps'),
|
||||
'epub' => array('type' => 'application/epub+zip', 'icon' => 'epub', 'groups' => array('document')),
|
||||
'fdf' => array('type' => 'application/pdf', 'icon' => 'pdf'),
|
||||
'fdf' => array('type' => 'application/vnd.fdf', 'icon' => 'pdf'),
|
||||
'flac' => array('type' => 'audio/flac', 'icon' => 'audio', 'groups' => array('audio', 'html_audio', 'web_audio'),
|
||||
'string' => 'audio'),
|
||||
'flv' => array('type' => 'video/x-flv', 'icon' => 'flash',
|
||||
@@ -189,7 +189,7 @@ abstract class core_filetypes {
|
||||
'string' => 'video'),
|
||||
|
||||
'pct' => array('type' => 'image/pict', 'icon' => 'image', 'groups' => array('image'), 'string' => 'image'),
|
||||
'pdf' => array('type' => 'application/pdf', 'icon' => 'pdf'),
|
||||
'pdf' => array('type' => 'application/pdf', 'icon' => 'pdf', 'groups' => array('document')),
|
||||
'php' => array('type' => 'text/plain', 'icon' => 'sourcecode'),
|
||||
'pic' => array('type' => 'image/pict', 'icon' => 'image', 'groups' => array('image'), 'string' => 'image'),
|
||||
'pict' => array('type' => 'image/pict', 'icon' => 'image', 'groups' => array('image'), 'string' => 'image'),
|
||||
@@ -270,12 +270,13 @@ abstract class core_filetypes {
|
||||
'wma' => array('type' => 'audio/x-ms-wma', 'icon' => 'audio', 'groups' => array('audio'), 'string' => 'audio'),
|
||||
|
||||
'xbk' => array('type' => 'application/x-smarttech-notebook', 'icon' => 'archive'),
|
||||
'xdp' => array('type' => 'application/pdf', 'icon' => 'pdf'),
|
||||
'xfd' => array('type' => 'application/pdf', 'icon' => 'pdf'),
|
||||
'xfdf' => array('type' => 'application/pdf', 'icon' => 'pdf'),
|
||||
'xdp' => array('type' => 'application/vnd.adobe.xdp+xml', 'icon' => 'pdf'),
|
||||
'xfd' => array('type' => 'application/vnd.xfdl', 'icon' => 'pdf'),
|
||||
'xfdf' => array('type' => 'application/vnd.adobe.xfdf', 'icon' => 'pdf'),
|
||||
|
||||
'xls' => array('type' => 'application/vnd.ms-excel', 'icon' => 'spreadsheet', 'groups' => array('spreadsheet')),
|
||||
'xlsx' => array('type' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', 'icon' => 'spreadsheet'),
|
||||
'xlsx' => array('type' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', 'icon' => 'spreadsheet',
|
||||
'groups' => array('spreadsheet')),
|
||||
'xlsm' => array('type' => 'application/vnd.ms-excel.sheet.macroEnabled.12',
|
||||
'icon' => 'spreadsheet', 'groups' => array('spreadsheet')),
|
||||
'xltx' => array('type' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.template',
|
||||
|
||||
@@ -133,13 +133,14 @@ class manager {
|
||||
return $savemessage->id;
|
||||
}
|
||||
|
||||
$processors = get_message_processors(true);
|
||||
|
||||
$failed = false;
|
||||
foreach ($processorlist as $procname) {
|
||||
// Let new messaging class add custom content based on the processor.
|
||||
$proceventdata = ($eventdata instanceof message) ? $eventdata->get_eventobject_for_processor($procname) : $eventdata;
|
||||
if (!$processors[$procname]->object->send_message($proceventdata)) {
|
||||
$stdproc = new \stdClass();
|
||||
$stdproc->name = $procname;
|
||||
$processor = \core_message\api::get_processed_processor_object($stdproc);
|
||||
if (!$processor->object->send_message($proceventdata)) {
|
||||
debugging('Error calling message processor ' . $procname);
|
||||
$failed = true;
|
||||
// Previously the $messageid = false here was overridden
|
||||
|
||||
@@ -1955,7 +1955,7 @@ class core_plugin_manager {
|
||||
|
||||
if (!$this->is_plugin_folder_removable($plugin->component)) {
|
||||
throw new moodle_exception('err_removing_unremovable_folder', 'core_plugin', '',
|
||||
array('plugin' => $pluginfo->component, 'rootdir' => $pluginfo->rootdir),
|
||||
array('plugin' => $plugin->component, 'rootdir' => $plugin->rootdir),
|
||||
'plugin root folder is not removable as expected');
|
||||
}
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user