Compare commits

..

1490 Commits

Author SHA1 Message Date
Eloy Lafuente (stronk7) 89e6c5c0e9 Moodle release 2.5.3 2013-11-10 01:58:48 +01:00
Damyon Wiese a7d4d3431d weekly release 2.5.2+ 2013-11-08 12:53:13 +08:00
Damyon Wiese 836ab073a3 Merge branch 'install_25_STABLE' of git://git.moodle.org/moodle-install into MOODLE_25_STABLE 2013-11-08 12:53:09 +08:00
AMOS bot f6b388ebfd Automatically generated installer lang files 2013-11-08 00:43:05 +00:00
Damyon Wiese 5a3a531267 Merge branch 'MDL-42668-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-11-07 16:10:59 +08:00
Dan Poltawski 934c120bf7 Merge branch 'MDL-42666-25-fixup' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-11-07 15:56:31 +08:00
Frederic Massart e4feadd902 MDL-42668 portfolio_boxnet: Do not run upgrade multiple times
Conflicts:

	portfolio/boxnet/db/upgrade.php
	portfolio/boxnet/version.php
2013-11-07 15:37:18 +08:00
Frederic Massart 0fe0fe9ebe MDL-42666 repository_boxnet: Do not run the upgrade multiple times
Conflicts:

	repository/boxnet/db/upgrade.php
	repository/boxnet/version.php
2013-11-07 15:25:33 +08:00
Frederic Massart f15dccae2a MDL-42668 portfolio_boxnet: Disable the portfolio when non-HTTPS 2013-11-07 14:34:18 +08:00
Frederic Massart 01b9b03441 MDL-42668 portfolio_boxnet: Disable the portfolio during upgrade 2013-11-07 14:34:17 +08:00
Frederic Massart c13e763ef1 MDL-42668 portfolio_boxnet: Notify the admins about the upgrade process
Conflicts:

	portfolio/boxnet/version.php
2013-11-07 14:34:12 +08:00
Frederic Massart 0ae0d09eb9 MDL-42668 portfolio_boxnet: Migration to APIv2
Conflicts:

	lib/boxlib.php
2013-11-07 14:31:32 +08:00
Dan Poltawski edb8542bae Merge branch 'MDL-42666-25-fixup' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-11-07 14:19:10 +08:00
Frederic Massart 2c9b25f0cf MDL-42666 tests: Setting new Box.net mandatory arguments 2013-11-07 13:55:07 +08:00
Marina Glancy a41b923702 Merge branch 'MDL-42697-25' of git://github.com/andrewnicols/moodle into MOODLE_25_STABLE 2013-11-07 16:31:22 +11:00
Dan Poltawski 95e92d994a Merge branch 'MDL-42666-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-11-07 11:44:45 +08:00
Frederic Massart c19d952ad2 MDL-42666 repository_boxnet: New lang strings rather than replace 2013-11-07 11:14:12 +08:00
Damyon Wiese 9f4c5ff972 Merge branch 'MDL-42605-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-11-07 11:02:10 +08:00
Frederic Massart f5b8ccf6e4 MDL-42666 repository_boxnet: Improved output during migration 2013-11-07 11:00:33 +08:00
Dan Poltawski dc7910cfb5 Merge branch 'MDL-42728-en_fix_25' of git://github.com/mudrd8mz/moodle into MOODLE_25_STABLE 2013-11-07 09:36:01 +08:00
Frederic Massart 550be25d23 MDL-42666 repository_boxnet: Avoid re-download of sync'd references 2013-11-06 15:04:04 +08:00
Petr Škoda 00163ad105 MDL-38743 add private cache headers 2013-11-06 13:56:22 +08:00
Marina Glancy 36c9dadd67 Merge branch 'MDL-42640-25' of https://github.com/colin-umn/moodle into MOODLE_25_STABLE 2013-11-06 16:31:46 +11:00
Frederic Massart 05c9a3da2a MDL-42666 repository_boxnet: Downloading a file follows locations 2013-11-06 12:46:17 +08:00
Frederic Massart d4617dcbae MDL-42666 repository_boxnet: Fix undefined variable usage 2013-11-06 12:46:17 +08:00
Frederic Massart 78e8d438e1 MDL-42666 repository_boxnet: Using the right reference 2013-11-06 12:45:14 +08:00
Andrew Nicols 0276873e4d MDL-42697 Theme: Fix overflow on docked blocks 2013-11-06 12:01:40 +08:00
Frederic Massart 79277af9cb MDL-42666 repository_boxnet: Convert all the references asap
This has been done in case the script fails during the processing
and needs to be re-run. Now all the references are converted as soon
as we can, where as before they could have ended up being re-downloaded.
2013-11-06 11:24:07 +08:00
Frederic Massart b633be82aa MDL-42666 repository_boxnet: Warn on HTTPS requirement when non HTTPS 2013-11-06 11:24:07 +08:00
Frederic Massart aea6108e05 MDL-42666 repository_boxnet: Alert the admins of the migration process
Conflicts:

	repository/boxnet/version.php
2013-11-06 11:24:05 +08:00
Frederic Massart 4aaab482ff MDL-42666 repository_boxnet: Revoke access token when logging out 2013-11-06 11:22:34 +08:00
Frederic Massart c800a57c7d MDL-42666 oauthlib: Getter methods for accesstoken, client id and secret 2013-11-06 11:22:34 +08:00
Frederic Massart b04cc1f3a7 MDL-42666 repository_boxnet: Remove hardcoded date for APIv1 end of life 2013-11-06 11:22:33 +08:00
Frederic Massart 7ee244b1a4 MDL-42666 repository_boxnet: Disabling file references 2013-11-06 11:22:33 +08:00
Frederic Massart 3fa4ae2a33 MDL-42666 repository_boxnet: Advise the user to run the migration tool 2013-11-06 11:22:33 +08:00
Frederic Massart 738a724ce7 MDL-42666 repository_boxnet: Tool to launch the migration 2013-11-06 11:22:32 +08:00
Frederic Massart 3f944b3350 MDL-42666 repository_boxnet: Function to convert APIv1 references to true copies 2013-11-06 11:22:32 +08:00
Frederic Massart f1b93a70bf MDL-42666 repository_boxnet: Convert repository to APIv2
The support for downloading images when they are references
from Box.net have been dropped in this script as the new
API does not support references. Unfortunately the old
references thumbnails will not be updated any more.

Conflicts:

	lib/upgrade.txt
	repository/boxnet/lib.php
2013-11-06 11:21:16 +08:00
Damyon Wiese 2f78f30342 MDL-39800 tags: Fix tags/upgrade.txt version number in backport 2013-11-06 10:45:42 +08:00
Damyon Wiese bff2785bbb Merge branch 'wip-MDL-41309-25STABLE' of https://github.com/jennymgray/moodle into MOODLE_25_STABLE 2013-11-06 10:37:09 +08:00
Mary Evans 7e7123eb04 MDL-40244 forms: added setType() for groupinfo in forum and wiki 2013-11-06 12:24:55 +11:00
Helen Foster 0282d3ec01 MDL-42728 Merge English strings from the en_fix language pack 2013-11-05 23:49:47 +01:00
Damyon Wiese ef7b0158c9 Merge branch 'wip-MDL-38228-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-11-05 22:39:27 +08:00
Jenny Gray 4aafc00b17 MDL-39800 tags: moved cloud sorting to print function 2013-11-05 10:59:09 +00:00
Jenny Gray bbec0210fa MDL-39800 tags: Applied weight and ordering fix on all more page options
Also:
Fixed weight and ordering on more page show=all
Fixed weight and ordering on more page show=my
rationalised tag_print_cloud lines now identical
2013-11-05 10:58:59 +00:00
Jenny Gray 1ee5db0a96 MDL-39800 tags: resolved weighting in block content 2013-11-05 10:58:48 +00:00
David Monllao b1c08d5b81 MDL-42332 behat: Adding a wait to let AJAX finish the request
The Mark as completed performs an AJAX request,
we need to give time to let it finish.
2013-11-05 17:26:52 +08:00
Dan Poltawski e9c05243e0 Merge branch 'MDL-42613_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-11-05 16:46:34 +08:00
David Monllao 4e6fe1af7a MDL-42363 behat: Avoid random failure because of timing differences 2013-11-05 15:53:34 +08:00
Marina Glancy 5636172729 Merge branch 'MDL-40267-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-11-05 17:45:13 +11:00
Dan Poltawski f6c01ed03d Merge branch 'MDL-42385_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-11-05 12:34:37 +08:00
rwijaya b493d5f228 MDL-42280 Behat: add behat test for block settings.
Test includes: modifying setting to hide and move block appearance
2013-11-05 11:37:56 +08:00
Aaron Barnes 3ddd77dfd7 MDL-42476 report_progress: don't browser sniff for SVG support
Use feature detection, its more robust and better practice.
2013-11-05 11:24:33 +08:00
Colin Campbell 7bdfb60b14 MDL-42640 quiz: Fix restore of backup without overduehandling setting
Use default quiz overduehandling setting when restoring a
backup from older Moodle version that does not have a quiz
overduehandling setting.
2013-11-04 21:12:33 -06:00
Marina Glancy c12f6b3191 MDL-38228 upgrade: Rewrite and re-apply script that fixes corrupt course modules to sequence relation 2013-11-05 14:12:32 +11:00
Ray Morris 3e90b472a0 MDL-42265 make Browse Users list scrollable for smaller screens 2013-11-05 10:50:19 +08:00
Dan Poltawski 60d8c0214b MDL-40267 forms: fix utf8 string length rules 2013-11-05 10:19:41 +08:00
Eloy Lafuente (stronk7) 6cb4f34ebd MDL-40267 forms: added some tests for the range rule 2013-11-05 10:08:11 +08:00
Damyon Wiese 7877f2a10d Merge branch 'wip-MDL-42374-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-11-05 09:27:46 +08:00
Dan Poltawski 9b8d886a7d Merge branch 'MDL-42273-25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-11-04 23:41:08 +08:00
Dan Poltawski 9686f6db9b Merge branch 'MDL-42363_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-11-04 23:34:28 +08:00
Dan Poltawski 742f8adac4 Merge branch 'wip-MDL-42270_M25_2' of git://github.com/gjb2048/moodle into MOODLE_25_STABLE 2013-11-04 22:54:16 +08:00
Dan Poltawski 23e3fe5449 Merge branch 'MDL-42548_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-11-04 22:35:05 +08:00
Dan Poltawski 028528e223 Merge branch 'MDL-42453_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE 2013-11-04 22:17:20 +08:00
Dan Poltawski 2aed63d053 MDL-42533 conditionlib: Add clarifying comments 2013-11-04 22:04:09 +08:00
Dan Poltawski 99870bc223 Merge branch 'MDL-42533-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-11-04 21:55:37 +08:00
Dan Poltawski d06720b0b5 Merge branch 'MDL-42326_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-11-04 21:43:49 +08:00
Dan Poltawski 824105f80f Merge branch '42350-25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-11-04 17:38:01 +08:00
Jerome Mouneyrac c7cc3271c0 MDL-42332 Automate MDLQA-5260 and MDLQA-5261 - A badge can be awarded based on activity and course completion + add i_trigger_cron behat step 2013-11-04 17:18:08 +08:00
Jerome Mouneyrac a10af7329e MDL-42331 Automate MDLQA-5258 - A teacher can add and allocate a course badge 2013-11-04 17:15:05 +08:00
Dan Poltawski 46ee24b31e Merge branch 'MDL-42551_25' of git://github.com/stronk7/moodle into MOODLE_25_STABLE 2013-11-04 16:22:46 +08:00
Jerome Mouneyrac 79a12d2d3f MDL-42330 Automate MDLQA-5257 - An admin can award a site badge 2013-11-04 16:19:42 +08:00
Marina Glancy bdb51186d7 Merge branch 'MDL-42604-25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-11-04 19:16:44 +11:00
Dan Poltawski 162fe6fab2 Merge branch 'w45_MDL-42044_m25_zipaddon' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-11-04 16:14:39 +08:00
Sam Hemelryk 084b8ae091 MDL-42350 mod_assign: fixed display of submission button 2013-11-04 15:58:16 +08:00
Dan Poltawski 43eaae3502 MDL-42111 fix trailing whitespace 2013-11-04 15:36:19 +08:00
Dan Poltawski fde722805f Merge branch 'MDL-42111_m25' of git://github.com/rwijaya/moodle into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-11-04 15:36:08 +08:00
Damyon Wiese f4dfc6aec3 Merge branch 'MDL-34654-m25' of git://github.com/sammarshallou/moodle into MOODLE_25_STABLE 2013-11-04 15:22:58 +08:00
Dan Poltawski 9e947fe303 Merge branch 'MDL-42494-workshop-exception_25' of git://github.com/mudrd8mz/moodle into MOODLE_25_STABLE 2013-11-04 14:51:52 +08:00
Marina Glancy a13c26eca3 Merge branch 'MDL-42429_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-11-04 17:28:15 +11:00
Marina Glancy 7b6142193d Merge branch 'MDL-42566_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-11-04 17:23:12 +11:00
Dan Poltawski 211b771e3b MDL-42286 fix trailing whitespace 2013-11-04 14:15:13 +08:00
Dan Poltawski 8b03e53926 Merge branch 'MDL-42286_behat_25' of https://github.com/andyjdavis/moodle into MOODLE_25_STABLE 2013-11-04 14:13:49 +08:00
Sam Hemelryk 6d50856c1f Merge branch 'MDL-42648_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE 2013-11-04 14:00:19 +08:00
Marina Glancy 01e7a77619 Merge branch 'MDL-42465_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-11-04 16:58:11 +11:00
Frederic Massart 95a7908c29 MDL-41807 repository_filesystem: Prevent access to parent directories 2013-11-04 13:31:11 +08:00
Damyon Wiese 6885480643 Merge branch 'MDL-42489-25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-11-04 13:17:02 +08:00
Marina Glancy c82257cc88 Merge branch 'MDL-42617_25' of git://github.com/jleyva/moodle into MOODLE_25_STABLE 2013-11-04 16:14:57 +11:00
Marina Glancy b981f1b847 Merge branch 'MDL-38664_m25' of git://github.com/rwijaya/moodle into MOODLE_25_STABLE 2013-11-04 15:16:43 +11:00
Dan Poltawski ed4d821352 Merge branch 'MDL-40515_25' of git://github.com/aolley/moodle into MOODLE_25_STABLE 2013-11-04 12:10:56 +08:00
Damyon Wiese 1b6b8865bb Merge branch 'MDL-35146_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-11-04 11:55:44 +08:00
Petr Škoda 80d1934fe3 MDL-41941 clean message text 2013-11-04 11:37:59 +08:00
Tim Hunt 8f39e9f1af MDL-41820 XSS in the quiz responses report.
Thanks to Michael Hess for finding this bug and reporting it to us.
2013-11-04 11:12:04 +08:00
Damyon Wiese 2116cfe31b Merge branch 'MDL-42521_25' of git://github.com/grabs/moodle into MOODLE_25_STABLE 2013-11-04 11:00:55 +08:00
Damyon Wiese 978271ca9b Merge branch 'MDL-42663_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-11-04 10:49:21 +08:00
Marina Glancy b5ba65ebf1 Merge branch 'MDL-42664-performance_measuring_filter_manager_25' of git://github.com/mudrd8mz/moodle into MOODLE_25_STABLE 2013-11-04 13:18:15 +11:00
Damyon Wiese 3e84d1746a Merge branch 'w45_MDL-42496_m25_addonredir' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-11-04 10:00:24 +08:00
Damyon Wiese da9e7233b9 Merge branch 'MDL-38850_m25' of git://github.com/rwijaya/moodle into MOODLE_25_STABLE 2013-11-04 09:41:46 +08:00
Andreas Grabs 3085f3395b MDL-42521 mod_feedback - Feedback does not show line graphs in Clean theme 2013-11-03 19:12:42 +01:00
Mary Evans 8a5c822a99 MDL-42648 lib: Clean theme throws exception if set_pagelayout is called too late. 2013-11-02 00:57:32 +00:00
Damyon Wiese 6c867463ae Merge branch 'wip-MDL-28463-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-11-01 21:50:15 +08:00
Petr Škoda 924a623b74 MDL-42044 standardise list of unzipped files in add-on installer 2013-11-01 10:44:28 +01:00
Petr Škoda f112423e0a MDL-42496 backport MDL-41245 add-on install request redirection fix 2013-11-01 10:40:17 +01:00
Dan Poltawski 7eaaf2dac8 Merge branch 'MDL-42287-25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-11-01 17:38:03 +08:00
David Monllao 8881afbb1a MDL-42663 mod_lesson: Move definitions to show_clock()
Seems that the required data is not always set
before timer.js is included.
2013-11-01 16:38:48 +08:00
Mark Nelson f329d60c38 MDL-42429 mod_lesson: removed unnecessary conditional check 2013-11-01 16:23:40 +08:00
David Mudrák 2c6520c719 MDL-42664 Fix the filter_manager instantiation
For legacy reasons, the $CFG->perfdebug uses values 7 for disabled and 15 for
enabled. Because of this typo, Moodle has always created instance of the slower
performance_measuring_filter_manager instead of the standard filter_manager,
regardless the perfdebug setting.
2013-11-01 09:19:22 +01:00
Dan Poltawski c9ee1a77a5 weekly release 2.5.2+ 2013-11-01 15:47:51 +08:00
Dan Poltawski 3eb7f7103b Merge branch 'install_25_STABLE' of git://git.moodle.org/moodle-install into MOODLE_25_STABLE 2013-11-01 15:47:48 +08:00
Marina Glancy c77dfbdd05 MDL-28463 conditionlib: 10 minutes lifetime of cached grades 2013-11-01 16:53:12 +11:00
Andrew Davis 17988b1854 MDL-42286 questionbank: add behat tests for putting questions in categories MDLQA-95 2013-11-01 10:37:39 +08:00
Sam Hemelryk fe1a264095 MDL-42619 block_community: delete course redirect bug fix 2013-11-01 10:16:26 +08:00
Marina Glancy 27fa761b19 Merge branch 'MDL-41624_25' of git://github.com/jmvedrine/moodle into MOODLE_25_STABLE 2013-10-31 22:17:58 +11:00
Juan Leyva 119faec054 MDL-42617 Add support for frozen fields in searchableselector form elements 2013-10-31 11:48:45 +01:00
Marina Glancy 42863ec241 Merge branch 'MDL-40971_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE 2013-10-31 21:17:08 +11:00
Mark Nelson 38ad8f35da MDL-42566 mod_data: introduced check to ensure the picture supplied is valid 2013-10-31 17:10:59 +08:00
Michael Aherne 04be3fce3e MDL-42517 testing Changed events test to use assertDebuggingCalled() 2013-10-31 13:38:16 +08:00
Marina Glancy 609aa78de1 Merge branch 'MDL-42587_25' of git://github.com/aolley/moodle into MOODLE_25_STABLE 2013-10-31 16:00:16 +11:00
Ankit Agarwal ade7240b9f MDL-42273 behat: Automate groups and groupings import QAs
MDLQA-2420 Importing groups with an ID number with permissions
MDLQA-2421 Importing groups with an ID number without permissions
MDLQA-5266 A teacher can import groupings as well as groups into a course
2013-10-31 10:49:12 +08:00
Frederic Massart a89784e9f3 MDL-42605 portfolio_flickr: Do not auto select a set to export to 2013-10-31 10:32:50 +08:00
Frederic Massart e957693eab MDL-42605 portfolio_flickr: Photos can be added to a set on export 2013-10-31 10:32:49 +08:00
Mary Evans f859cd373b MDL-40971 grade: Importing Outcomes breaks Clean theme. 2013-10-30 23:56:17 +00:00
Jean-Michel Vedrine 4f80368f82 MDL-41624 DragMath crashes Firefox 2013-10-30 18:17:27 +01:00
David Monllao 753c8736f5 MDL-42385 behat: New test to cover MDL-38661
Scenarios to cover the category and combo list
frontpage display modes, checking the AJAX
calls to expand/collapse children nodes. Also refactoring
the site settings step as it has problems to deal
with multiple-field settings.
2013-10-30 18:33:03 +08:00
David Monllao 6887714946 MDL-42363 behat: Covering MDL-41817 testing
Covering backup/restore without blocks
and with a single course section.
2013-10-30 18:28:49 +08:00
Mark Nelson 89f71167f1 MDL-42613 core_group: removed unnecessary table row when there is no group description or picture 2013-10-30 17:59:29 +08:00
Damyon Wiese 1cf4616825 Merge branch 'MDL-38734-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-10-30 17:21:52 +08:00
Damyon Wiese 4323d78919 Merge branch 'MDL-41092-25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-10-30 16:25:08 +08:00
Damyon Wiese c2e79fd044 MDL-41092 Assign: Expose SQL error in cron unit test 2013-10-30 16:24:37 +08:00
Sam Hemelryk 121de7fe9f Merge branch 'wip-MDL-42379-25' of git://github.com/abgreeve/moodle into MOODLE_25_STABLE 2013-10-30 15:08:49 +08:00
Sam Hemelryk 65c6eb8141 Merge branch 'MDL-42284_behat_25' of https://github.com/andyjdavis/moodle into MOODLE_25_STABLE 2013-10-30 14:19:41 +08:00
Sam Hemelryk 4d5be0764a Merge branch 'MDL-42574-25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-10-30 13:44:48 +08:00
Ankit Agarwal 248cd99de6 MDL-42604 scorm: Fix division by zero warnings in error logs 2013-10-30 10:57:27 +08:00
Damyon Wiese 657faa98d8 Merge branch 'wip-MDL-41337-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-10-30 10:53:52 +08:00
Sam Hemelryk 0460b39c13 Merge branch 'MDL-42542-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-10-30 08:39:24 +08:00
Marina Glancy ca50abdd5d MDL-41337 files: Fixed bug with accidental delete of the root directory 2013-10-29 20:30:01 +11:00
Michael de Raadt 23288150aa MDL-41092 assign: Fix duplicate key error in assign cron 2013-10-29 14:41:10 +08:00
John Beedell fb97f9a5cf MDL-41473 book: Book html zip import, incorrect url produced for internal linking to other chapters 2013-10-29 14:28:28 +08:00
Damyon Wiese 56ed66a537 Merge branch 'MDL-40470-25' of git://github.com/andrewnicols/moodle into MOODLE_25_STABLE 2013-10-29 13:56:12 +08:00
Rajesh Taneja 0dc1862e77 MDL-42282 Behat: Max year in date feild is 2020 in 2.5 2013-10-29 13:54:18 +08:00
Damyon Wiese 39ab79ca19 Merge branch 'm25_MDL-39810_IE_Compatibility_View_Does_Not_Recognize_JSON_RFC4627_MIME_Type' of https://github.com/scara/moodle into MOODLE_25_STABLE 2013-10-29 13:42:58 +08:00
Adam Olley 14a99847bc MDL-42587: calendar: Fix regression that stops dates autocorrecting 2013-10-29 14:18:43 +10:30
Dan Poltawski 3dcfa0e6aa Merge branch 'wip-mdl-42282-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-10-29 11:44:36 +08:00
Andrew Nicols 4b98297808 MDL-40470 JavaScript: Correct issue when checking select change in Firefox 2013-10-29 10:43:01 +08:00
Ankit Agarwal d4c3263cea MDL-42287 behat: Add an autoamted test to test MDLQA-82 2013-10-29 10:39:08 +08:00
Dan Poltawski 0da4fd0c21 Merge branch 'wip-mdl-42281-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-10-29 10:33:11 +08:00
Rajesh Taneja ffaa69b81e MDL-42281 Behat: Automated test for MDLQA-510
MDLQA-510: A teacher can set grade conditions to restrict availability
of an activity
2013-10-28 16:49:41 +08:00
Dan Poltawski 796538b786 Merge branch 'MDL-22669-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-10-28 16:31:30 +08:00
Ankit Agarwal 5bcfa0511f MDL-42574 blocks: Fix strict standards warning in community block 2013-10-28 15:41:06 +08:00
Dan Poltawski 321a08bff9 Merge branch 'wip-mdl-42283-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-10-28 14:54:10 +08:00
Dan Poltawski 3c137dafb3 Merge branch 'MDL-42285-25' of git://github.com/phalacee/moodle into MOODLE_25_STABLE 2013-10-28 14:15:40 +08:00
Mark Nielsen 0f0fa7a86c MDL-38419: External tool - when force SSL checked, URLs get corrupted 2013-10-28 12:35:07 +08:00
Mark Nelson 4b83e704b1 MDL-35146 mod_wiki: fixed variable typo and altered code to conform to Moodle guidelines 2013-10-28 12:32:07 +08:00
Anton Fletcher 84c3f002ea MDL-35146 mod_wiki: fixed issue where pages for deleted groups caused an error on restore 2013-10-28 12:32:07 +08:00
Damyon Wiese 59f8555512 Merge branch 'wip-mdl-30812-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-10-28 12:14:52 +08:00
Dan Poltawski 92642bed3c Merge branch 'MDL-42538_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-10-28 11:36:08 +08:00
Dan Poltawski 3fa16c9c7b Merge branch 'wip-mdl-42491-m25' of git://github.com/deraadt/moodle into MOODLE_25_STABLE 2013-10-28 11:33:27 +08:00
David Monllao fb8ea65f94 MDL-42326 behat: New scenario for permission overrides 2013-10-28 11:33:17 +08:00
David Monllao 3b51b66e2b MDL-42326 behat: Data generator for permission overrides 2013-10-28 11:33:17 +08:00
Prateek Sachan b9fdc61f99 MDL-38850: Fixed Horizontal bar issue in lesson 2013-10-28 11:08:26 +08:00
Damyon Wiese b842558dc2 Merge branch 'MDL-36818-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-10-28 10:58:54 +08:00
Adrian Greeve d3da736981 MDL-42379 behat: Automated test for approving glossary entries.
Automate MDLQA-34 - A teacher can set that glossary entries require approval before being viewable be everyone.
2013-10-28 09:31:52 +08:00
AMOS bot a7275914da Automatically generated installer lang files 2013-10-28 00:46:43 +00:00
Matteo Scaramuccia 47e52bfdca MDL-39810 Files: IE doesn't recognize JSON MIME Type (RFC4627).
Affected versions:
- IE 8+, under Compatibility View.
2013-10-27 07:58:51 +01:00
Eloy Lafuente (stronk7) 448589b517 MDL-42551 timezone info: updated to 2013h 2013-10-26 17:14:57 +02:00
Andrew Davis 0a4563b1d4 MDL-42284 core_message: adding behat tests for viewing message history MDLQA-135 2013-10-26 17:51:38 +07:00
Tim Hunt 0bf397b20c MDL-42548 quiz review: don't show grade for non-finished attempts.
Now we show the attempt state separately, so there is no need to show
Grade: Attempt still in progress - especially since we were showing that
for abandoned and overdue attempts which is just wrong.
2013-10-25 20:11:23 +01:00
Gareth J Barnard a22207d167 MDL-42270 course: Section name too big message. 2013-10-25 16:45:55 +01:00
Eloy Lafuente (stronk7) 67d4599aff weekly release 2.5.2+ 2013-10-25 13:03:41 +02:00
Eloy Lafuente (stronk7) a108831497 Merge branch 'install_25_STABLE' of git://git.moodle.org/moodle-install into MOODLE_25_STABLE 2013-10-25 13:03:36 +02:00
Frederic Massart a229f6aeb6 MDL-42542 portfolio: Fix handlerfile in portfolio event handler 2013-10-25 16:02:49 +08:00
Dan Poltawski ac48ed217d Merge branch 'wip-mdl-42536-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-10-25 15:55:36 +08:00
Dan Poltawski 3c78ccf5c4 Merge branch 'MDL-42514-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-10-25 15:28:23 +08:00
Rajesh Taneja 4ccbf72147 MDL-42536 enrol_self: Added behat to test group key self enrolment 2013-10-25 15:17:03 +08:00
Dan Poltawski b629c8b244 Merge branch 'MDL-42272-25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-10-25 12:01:42 +08:00
Ankit Agarwal 12330cda14 MDL-42272 behat: Fix incorrect strings 2013-10-25 11:44:28 +08:00
David Monllao 31b981afa9 MDL-42538 behat: Fixing wrong number of users 2013-10-25 11:37:45 +08:00
Frederic Massart 0a6ebc609d MDL-42533 conditionlib: Field name is translated for students 2013-10-25 09:52:20 +08:00
Michael de Raadt 8fac075a5c MDL-42491 libraries: add exception for IE11 (and hopefully later versions) 2013-10-25 09:01:21 +08:00
Frederic Massart cb8ba87d4e MDL-42514 groups: Importing groups created unnamed groupings 2013-10-25 08:23:11 +08:00
Eloy Lafuente (stronk7) 183058c8b5 Merge branch 'MDL-42377_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-10-25 01:13:46 +02:00
Dan Poltawski 3a32362a30 Merge branch 'MDL-42338_m25' of git://github.com/rwijaya/moodle into MOODLE_25_STABLE 2013-10-24 16:29:11 +08:00
Jason Fowler 13b88e122b MDL-42285 Behat: Automate MDLQA-93 - A teacher can delete questions from the question bank 2013-10-24 13:50:06 +08:00
Dan Poltawski 860553218c Merge branch 'MDL-42272-25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-10-24 13:42:09 +08:00
Dan Poltawski 047f523d91 Merge branch 'MDL-42362_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-10-24 12:39:49 +08:00
Dan Poltawski 7e24c4bbb2 Merge branch 'wip-MDL-42323-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-10-24 12:33:21 +08:00
Marina Glancy a4b421c1fb Merge branch 'MDL-35402_editor_rules_25' of git://github.com/davosmith/moodle into MOODLE_25_STABLE 2013-10-24 15:29:57 +11:00
Marina Glancy b46fc7cefd Merge branch 'MDL-41252-25' of git://github.com/mouneyrac/moodle into MOODLE_25_STABLE 2013-10-24 14:15:39 +11:00
rwijaya 4b178e7ab6 MDL-42338 lti_mod: convert hardcoded string. 2013-10-24 10:35:11 +08:00
Dan Poltawski f9b6e96e59 Merge branch 'MDL-42293-25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-10-24 10:27:45 +08:00
sam marshall fb166770b9 MDL-34654 Glossary: ampersand breaks auto-linking 2013-10-23 16:21:39 +01:00
David Mudrák 30f8726bed MDL-42494 Fix workshop coding exception if all assessments have zero weight
If all assessments for the given submission have zero weight, the grading
evaluation plugin "Comparison with the best assessment" is unable to decide on
the average assessment as it ignores those with zero weight. In such rare case,
it makes sense to set the grading grade to null and prevent the coding
exception.
2013-10-23 11:49:54 +02:00
Dan Poltawski 95fcab4480 Merge branch 'MDL-42324_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-10-23 17:14:37 +08:00
Rajesh Taneja ba9af1f476 MDL-42283 Behat: Automated MDLQA-1777
MDLQA-1777: A teacher can set grade conditions to restrict availability of a section
2013-10-23 15:59:00 +08:00
Jerome Mouneyrac e0b8bc0a08 MDL-41252 Simple changes to main course page to improve accessibility - original patch of Nate Baxley 2013-10-23 15:18:50 +08:00
Dan Poltawski fd60979576 Merge branch 'MDL-42290-25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-10-23 15:05:43 +08:00
Damyon Wiese 6e81b099fb Merge branch 'MDL-42210_25' of git://github.com/grabs/moodle into MOODLE_25_STABLE 2013-10-23 14:19:26 +08:00
Ankit Agarwal acea79f644 MDL-42489 backup: use correct exception class in automated backups 2013-10-23 13:55:47 +08:00
Damyon Wiese 023ab3da11 Merge branch 'w43_MDL-42208_m25_authunmask' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-10-23 13:41:46 +08:00
Dan Poltawski 7eed88eef9 Merge branch 'wip-MDL-42278-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-10-23 13:21:07 +08:00
Dan Poltawski 48c67d9c75 Merge branch 'MDL-40531_25' of https://github.com/stronk7/moodle into MOODLE_25_STABLE 2013-10-23 12:37:52 +08:00
Ankit Agarwal b48366111d MDL-42427 backup: Fix undefined errors during automated backups 2013-10-23 12:11:06 +08:00
Damyon Wiese 75f39a0946 MDL-41339 Tags - use uppercase for SQL keywords (AS) 2013-10-23 11:59:38 +08:00
Damyon Wiese 2840c2ae62 Merge branch '25STABLE-wip-mdl-41339' of https://github.com/jennymgray/moodle into MOODLE_25_STABLE 2013-10-23 11:53:16 +08:00
Marina Glancy 538e06f2b5 Merge branch 'w43_MDL-37813_m25_filterall' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-10-23 10:17:58 +11:00
Dan Poltawski 68c4e246d6 Merge branch 'MDL-42112-25' of git://github.com/damyon/moodle into MOODLE_25_STABLE 2013-10-22 16:40:50 +08:00
Mark Nelson a57462fab5 MDL-42465 mod_chat: instantiated message object before declaring properties 2013-10-22 16:09:14 +08:00
Dan Poltawski c2767fb456 Merge branch 'MDL-29441-25' of git://github.com/andrewnicols/moodle into MOODLE_25_STABLE 2013-10-22 13:21:14 +08:00
Marina Glancy 265b16589d Merge branch 'MDL-26170_rss_25' of https://github.com/andyjdavis/moodle into MOODLE_25_STABLE 2013-10-22 15:04:12 +11:00
Andrew Davis 3234d689b4 MDL-26170 RSS: fixed RSS cache clearing when items are deleted 2013-10-22 10:56:21 +07:00
Dan Poltawski 065e6bf386 Merge branch 'wip-mdl-31405-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-10-22 11:53:17 +08:00
Marina Glancy b2108d9955 Merge branch 'MDL-24380-25' of git://github.com/mouneyrac/moodle into MOODLE_25_STABLE 2013-10-22 14:34:53 +11:00
Rajesh Taneja e2311f397b MDL-31405 Assignment: removed type in time shift reset status
Assignment reset shifts time for all assignments and not specific to
assignment type, hence removed type string from reset status
2013-10-22 11:16:15 +08:00
Marina Glancy 575ec94611 Merge branch 'MDL-42239-m25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-10-22 14:08:45 +11:00
Jerome Mouneyrac a8fe589f4d MDL-24380 Chat: autoscroll help popup incorrect and doesn't display fully (it only concerns the alternative chat methods) 2013-10-22 10:44:47 +08:00
Ankit Agarwal 8be7543205 MDL-42239 calendar: Fix missing ids issue with mouseover panels 2013-10-22 10:43:39 +08:00
Dan Poltawski 9fcd4cc785 Merge branch 'MDL-42201_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-10-22 10:26:41 +08:00
Rajesh Taneja 944c3000bd MDL-34612 Restore: Gracefully handle empty file contenthash while restoring 2013-10-22 09:49:03 +08:00
Rajesh Taneja 89f04265df MDL-34612 Restore: Gracefully handle empty section title while restoring 2013-10-22 09:49:03 +08:00
AMOS bot c303806970 Automatically generated installer lang files 2013-10-22 00:45:41 +00:00
Mary Evans a31108712f MDL-42453 theme_base: Fixed Error in base/style/admin.css that breaks CSS validator. 2013-10-21 15:34:20 +01:00
Jenny Gray acdf10b7f0 MDL-41339 Tags: Added unique tag instance id to tag_get_tags functions
Avoids php warnings on creating new tags
2013-10-21 10:10:01 +01:00
Rajesh Taneja 5c2fa2124e MDL-42282 Behat: Automated test for MDLQA-509
MDLQA-509: A teacher can prevent students from accessing an activity
between specified dates
2013-10-21 14:13:23 +08:00
Dan Poltawski e9f8075b54 Merge branch 'MDL-34209-25' of git://github.com/andrewnicols/moodle into MOODLE_25_STABLE 2013-10-21 13:58:28 +08:00
Jody Steele 94b2dbb9b5 MDL-38628 mod_assign: Allow a user to specify "No Grade" when grading an assignment submission 2013-10-21 16:49:50 +11:00
Marina Glancy 10ae2a6d0e Merge branch 'w43_MDL-42386_m25_etag' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-10-21 16:00:27 +11:00
Dan Poltawski 3a77dc864f MDL-42408 tool_behat: fix version number 2013-10-21 12:29:01 +08:00
Mark Nelson fae00b43fe MDL-42377 backup: fixed incorrect debugging message 2013-10-21 11:55:02 +08:00
Mark Nelson 5f931bb78d MDL-42201 backup: introduced new automatic backup state 2013-10-21 11:46:41 +08:00
Andrew Nicols dc9159d70a MDL-34209 JavaScript: Simplify section drag/drop to fix reordering issues 2013-10-21 11:39:21 +08:00
Dan Poltawski ab2f2f93b1 Merge branch 'MDL-26244_url_25' of https://github.com/andyjdavis/moodle into MOODLE_25_STABLE 2013-10-21 11:25:15 +08:00
David Monllao 857ff6210b MDL-42362 behat: Passing options to modules generators 2013-10-21 11:19:29 +08:00
David Monllao 552af5abdd MDL-42324 behat: New activities data generator 2013-10-21 11:16:23 +08:00
Dan Poltawski 429cc7c8dc Merge branch 'MDL-42408_25' of https://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-10-21 11:15:50 +08:00
rwijaya 7e43cc70d8 MDL-42111 TinyMCE media preview: fix video preview display for TinyMCE media.
Effected themes: boxxie, clean, brick, formal_white and splash.
2013-10-21 11:15:44 +08:00
David Monllao d653929fde MDL-42325 behat: Role assign generator 2013-10-21 11:15:02 +08:00
David Monllao 472b456325 MDL-42408 behat: Setting the site summary 2013-10-21 11:10:41 +08:00
Dan Poltawski bd7a6434be MDL-31405 assign: avoid uncessary get_string call 2013-10-21 11:03:10 +08:00
Dan Poltawski 6b2c8581fa Merge branch 'wip-mdl-31405-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-10-21 10:58:24 +08:00
Andreas Grabs 4d686df651 MDL-42210 mod_feedback - convert tabs to space 2013-10-20 10:06:41 +02:00
Michael Milette 66b193ccb8 MDL-42210-Feedback-Input-Labels
Adds labels to the input fields in the Feedback module including: multichoice, multichoicerated, numeric, textarea and textfield.
2013-10-20 10:06:40 +02:00
AMOS bot 4d11461638 Automatically generated installer lang files 2013-10-20 00:42:08 +00:00
Charles Severance 326dc8f5a8 MDL-40531 mod_lti: Various 1.1/1.1.1 fixes.
Conflicts:
	mod/lti/service.php
2013-10-19 03:03:36 +02:00
Sam Chaffee d565223abd MDL-40531 mod_lti: Changed namespace in XML to IMS LTI compliant 2013-10-19 02:59:32 +02:00
AMOS bot c55cbda0d4 Automatically generated installer lang files 2013-10-19 00:47:34 +00:00
Petr Škoda bfc508c937 MDL-37813 remove missing filters when configuring string filters and fix filter uninstall 2013-10-18 15:58:34 +02:00
Petr Škoda 94d15100cd MDL-42208 prevent autocompletion in auth configs 2013-10-18 15:08:31 +02:00
Petr Škoda 15bf471bb6 MDL-42386 fix invalid etag comparison
Credit goes to Eloy Lafuente, thanks!
2013-10-18 14:49:14 +02:00
Ankit Agarwal 1269807d3c MDL-42290 choice: Add a automated test to verify limiting number of responses works 2013-10-18 17:35:53 +08:00
Dan Poltawski 1115bb3780 weekly release 2.5.2+ 2013-10-18 16:16:57 +08:00
Dan Poltawski ebb6f201ce Merge branch 'install_25_STABLE' of git://git.moodle.org/moodle-install into MOODLE_25_STABLE 2013-10-18 16:16:48 +08:00
Tony Levi cd9c46207d MDL-38734: Automated backup failure causing all course to fail 2013-10-18 15:04:22 +08:00
Damyon Wiese 5964cfdb51 Merge branch 'MDL-41554-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-10-18 13:29:03 +08:00
Dan Poltawski eacd2567db MDL-41554 rss: Move to more robust test url
tinyurl was sometimes failing (was bad to use them anyway)
2013-10-18 12:45:46 +08:00
Dan Poltawski b390cce066 Merge branch 'MDL-42421_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-10-18 12:15:11 +08:00
Damyon Wiese 691a2cc881 MDL-42112 tablelib: Generate the correct number of cols for empty rows
(And a test for it).
2013-10-18 11:53:52 +08:00
Damyon Wiese 690d3ed5fa MDL-42112 Tablelib: Add unit tests (some) 2013-10-18 11:53:51 +08:00
Mark Nelson 3c78a1c381 MDL-42421 auth: removed incorrect statement in upgrade.txt 2013-10-18 11:38:08 +08:00
Ankit Agarwal 68fb639f97 MDL-42272 groups: Add automated tests for MDLQA-145 2013-10-17 11:03:06 +08:00
Marina Glancy b96535cdaa MDL-42323 coursecat: Changed phpdocs in deprecated function get_categories 2013-10-17 09:56:30 +11:00
Damyon Wiese 5cd7d9c9fe Merge branch 'MDL-42065_25' of https://github.com/sam-moodle/moodle into MOODLE_25_STABLE 2013-10-16 15:47:12 +08:00
Rajesh Taneja c7f9332f11 MDL-31405 Assignment: Fixed date in reset to be called once 2013-10-16 12:09:06 +08:00
Marina Glancy 0446e658c2 MDL-42347 course: Added behat test for deleting a course 2013-10-16 15:05:56 +11:00
Jayesh Anandani 090e0ad543 MDL-31405 Assignment reset issue solved 2013-10-16 11:54:14 +08:00
Damyon Wiese 51db769bbd Merge branch 'MDL-37528-25' of git://github.com/andrewnicols/moodle into MOODLE_25_STABLE 2013-10-16 10:42:04 +08:00
Eloy Lafuente (stronk7) 644a0d0023 MDL-37877 backup: fix incorrect backported code. 2013-10-16 00:34:54 +02:00
Davo Smith 5ef9103c67 MDL-35402 forms - prevent crash when multiple rules defined on an editor element 2013-10-15 14:33:38 +01:00
Damyon Wiese 5d56f7d188 Merge branch 'MDL-37877-m25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-10-15 16:57:16 +08:00
Dan Poltawski f12a4819ef Merge branch 'MDL-42209_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-10-15 14:43:12 +08:00
Ankit Agarwal a48e5399a1 MDL-42293 behat: Add suport for custom admin paths to the behat upload repository step 2013-10-15 13:46:03 +08:00
Ankit Agarwal f2793fa225 MDL-37877 backup: Fix issues with zipping of large files
Files bigger than 4GB is not supported at this point. Zip archiver doesn't know about it and always returns true. We need to verify if it is a valid file or not and delete if not
Also delete the backup file immediately if anything goes wrong anywhere in backup. We don't want to use up space
2013-10-15 13:16:49 +08:00
Dan Poltawski 26037c6e3d Merge branch 'wip-MDL-42288-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-10-15 11:53:03 +08:00
Marina Glancy f4c8c454b9 MDL-42278 behat: block context can be returned to original state
Automate MDLQA-1547 - The context of a block can always be returned to it's original state.
2013-10-15 14:43:15 +11:00
Marina Glancy d3cb602c42 MDL-42288 behat: Allowing to change choice response
Automate MDLQA-46 - A teacher can choose whether to allow students to change their choice response
2013-10-15 14:24:37 +11:00
Marina Glancy 071ac9ffdd Merge branch 'wip-MDL-42234-25' of git://github.com/abgreeve/moodle into MOODLE_25_STABLE 2013-10-15 14:11:40 +11:00
Tim Hunt 6efb360102 MDL-42309 typo: fix reponse -> response throughout Moodle. 2013-10-15 13:48:39 +11:00
Adrian Greeve 8f5fea965a MDL-42234 - Repositories: Fix undefined variable notice when no repositories are enabled. 2013-10-15 10:43:14 +08:00
Damyon Wiese c0c2547bf6 Merge branch 'MDL-42198_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-10-14 16:15:10 +08:00
Dan Poltawski 4d2d515c47 Merge branch 'MDL-42151_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-10-14 16:12:05 +08:00
Dan Poltawski 9070663ecd Merge branch 'w42_MDL-42082_m25_authdbpass' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-10-14 14:36:22 +08:00
FilipBenco d35fc13537 MDL-42209 backup: fixed wrong icon being displayed when restoring course 2013-10-14 14:33:18 +08:00
Damyon Wiese 84a185f513 MDL-34586 assignment - fix whitespace 2013-10-14 14:28:24 +08:00
Damyon Wiese f5c356d06c Merge branch 'MDL-34586-25' of https://github.com/mackensen/moodle into MOODLE_25_STABLE 2013-10-14 14:27:48 +08:00
Dan Poltawski 73dc6a5b52 Merge branch 'MDL-42232_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-10-14 14:24:10 +08:00
Damyon Wiese 15ba938554 Merge branch 'MDL-34612-25' of https://github.com/mackensen/moodle into MOODLE_25_STABLE 2013-10-14 14:12:38 +08:00
Ankit Agarwal 053cee9767 MDL-41170 events: Update upgrade.txt to reflect changes made in MDL-41170 2013-10-14 13:19:22 +08:00
Akinsaya Delamarre 74f501e7b5 MDL-41170: Added user updated event triggers to password updating functions. 2013-10-14 13:17:19 +08:00
David Monllao 12539911a2 MDL-42198 tool_generator: Changing test plan default values
To achieve more stability on test results we
switch to less users and more loops.
2013-10-14 12:46:45 +08:00
David Monllao d0df167ba2 MDL-42151 behat: Adding the version to the testplan 2013-10-14 12:44:26 +08:00
Dan Poltawski 85cb1bc059 Merge branch 'MDL-41672-text-mail-links_25' of git://github.com/mudrd8mz/moodle into MOODLE_25_STABLE 2013-10-14 12:11:47 +08:00
Dan Poltawski e13f7b4ed4 Merge branch 'MDL-42167-workshop-update-record_25' of git://github.com/mudrd8mz/moodle into MOODLE_25_STABLE 2013-10-14 12:08:10 +08:00
Thijs Kinkhorst 1e34fbb36d MDL-36818 cas: improve SSL validation 2013-10-14 10:12:22 +08:00
Eloy Lafuente (stronk7) 88401c3494 Merge branch 'wip-mdl-41843-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-10-14 00:14:54 +02:00
Eloy Lafuente (stronk7) 2f334c6464 Merge branch 'MDL-37181_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-10-13 23:32:46 +02:00
Andrew Nicols 85d8381fe7 MDL-29441 Chat: Use a valid name for chat popup actions 2013-10-13 20:05:54 +08:00
Petr Škoda 6cc255a25d MDL-42110 do not show auth_db password in plaintext 2013-10-12 13:52:57 +02:00
AMOS bot 77b1206511 Automatically generated installer lang files 2013-10-12 00:43:48 +00:00
Tim Hunt 2f4fceec28 MDL-42232 Multiple choice question choice alignment issue
The problem was with the alignment of:
* tables inside the choices.
* Lists inside the choices.
* The specific feedback, when it spanned mulitple lines.

The problem was introduced by MDL-39420.
2013-10-11 14:26:24 +01:00
Eloy Lafuente (stronk7) 5c740905f5 weekly release 2.5.2+ 2013-10-11 13:21:02 +02:00
Andrew Davis aba5044091 MDL-26244 mod_date:added some logic show or hide the file picker button based on repository availability 2013-10-11 10:45:46 +07:00
Sam Hemelryk 903cdd6fe8 MDL-42072 badges: fixed cookie use 2013-10-11 09:34:29 +13:00
David Monllao 230c137498 MDL-42013 behat: I should (not)? see checking visibility
Only for non-Javascript tests. If the step
is named I should/should not see whatever
is makes sense that has to be visible.
2013-10-10 18:35:30 +08:00
Andrew Nicols 75da763cd9 MDL-37528 Libraries: Fix gesture + mouse issues with YUI
This addresses issues with devices which support both mouse and gesture
input devices whereby the presence of gesture support on the device causes
mouse interactions to be ignored.

This has the potential to cause issues with multiple events being triggered
for the same action, but we do not have this issue in core, and few
third-party plugins support drag and drop in such a way that this may be an
issue.

This is fixed in the latest version of YUI in a similar way, and the
addition of a new system to only trigger the event from the first action to
be triggered.
2013-10-10 17:02:02 +08:00
Matteo Scaramuccia 22b70ca985 MDL-42167 Update workshop assessment record only when really changed
Under certain conditions there is nothing to actually update here. The
$DB->update_record() would throw an exception here.
2013-10-10 10:12:07 +02:00
Dan Poltawski 5ed1769371 MDL-41379 - fix whitespace 2013-10-10 10:33:14 +08:00
Dan Poltawski 26f1ad0c09 Merge branch 'MDL-41379_outcomes_25' of https://github.com/andyjdavis/moodle into MOODLE_25_STABLE 2013-10-10 10:32:04 +08:00
Andrew Davis 9d7c75bb3a MDL-41379 core_outcome: added some CSS to the course outcome table to make it display nice 2013-10-10 09:27:33 +07:00
Marina Glancy dd70b2b84a Merge branch 'MDL-37153_25' of https://github.com/pauln/moodle into MOODLE_25_STABLE 2013-10-10 12:53:04 +11:00
Sam Hemelryk 9c60ab1513 Merge branch 'wip-mdl-41744-m25' of https://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-10-10 14:39:32 +13:00
Sam Chaffee 5deb021566 MDL-42065 core_grade: Modified some grade_item queries for improved performance
* Modified 2 queries in grade_item::depends_on to improve performance
* Added additional unit tests to cover those queries better
2013-10-09 12:27:18 -06:00
Alain Corbière a182efb289 MDL-41672 Fix html2text processing of multiple occurrences of the same URL 2013-10-09 15:44:18 +02:00
David Mudrák 1ee66b79a9 MDL-41672 Add html2text unit test for multiple occurrences of the same URL 2013-10-09 15:44:07 +02:00
Dan Poltawski 72c707f101 Merge branch 'w41_MDL-42054_m25_phpmailertesting_i' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-10-09 18:19:58 +08:00
Petr Škoda 5c5687765e MDL-42054 fix incorrect email redirection in unit tests 2013-10-09 11:49:27 +02:00
Dan Poltawski 7d3a6249a8 Merge branch 'MDL-39776-25' of git://github.com/phalacee/moodle into MOODLE_25_STABLE 2013-10-09 16:54:17 +08:00
Dan Poltawski 686abf0be9 Merge branch 'm25_MDL-40226_Add_JNLP_MIME_Type_Support' of https://github.com/scara/moodle into MOODLE_25_STABLE 2013-10-09 16:48:11 +08:00
Damyon Wiese 59e180d6d7 Merge branch 'w41_MDL-42047_m25_cohortdel' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-10-09 14:42:42 +08:00
Mark Nelson 8580fba156 MDL-37181 backup: stopped setting the status of unscheduled backups to skipped 2013-10-09 14:16:09 +08:00
Damyon Wiese df253b3030 Merge branch 'MDL-41659_25' of https://github.com/totara/openbadges into MOODLE_25_STABLE 2013-10-09 13:35:43 +08:00
Damyon Wiese 418d50d6a7 Merge branch 'wip-MDL-41967-25' of git://github.com/abgreeve/moodle into MOODLE_25_STABLE 2013-10-09 13:12:14 +08:00
Jason Fowler 30bf77467e MDL-39776 Javascript - enable formautosubmit from a select box on android 2013-10-09 11:37:07 +08:00
Charles Fulton 46575720a1 MDL-34612 forum: convert default format value during restore 2013-10-08 20:04:56 -07:00
Paul Nicholls 7551ada29a MDL-37153 - assign: Obey grade display settings in submission status
The assignment submission status screen was ignoring the grade item's
display setting, showing scores even if it's set to display letters only.
2013-10-09 16:00:13 +13:00
Tim Lock 7258ef74f5 MDL-41908 QuickForm: Fix PEAR Non-static method error 2013-10-09 10:27:20 +08:00
James Henestofel 7822bb9b6d MDL-42068 Filepicker course listing use setting courselistshortname to show shortname and fullname 2013-10-09 01:27:42 +02:00
Eloy Lafuente (stronk7) 5e50cd9355 Merge branch 'MDL-42069_25' of https://github.com/appalachianstate/moodle into MOODLE_25_STABLE 2013-10-08 21:27:18 +02:00
Charles Fulton d5336bd3f4 MDL-34586 assignment: convert default format value during restore 2013-10-08 09:47:57 -07:00
Rajesh Taneja 6b3870a612 MDL-41843 IMS-LTI: Fixed exception namespace 2013-10-08 15:55:30 +08:00
Dongsheng Cai 1027fd95bd MDL-41843 Uses OAuthException in moodle\mod\lti namespace 2013-10-08 15:55:29 +08:00
Damyon Wiese 46b46de84d Merge branch 'MDL-41520-MOODLE_25_STABLE-mod_lti-completion-view' of github.com:Trii/moodle into MOODLE_25_STABLE 2013-10-08 14:34:03 +08:00
Damyon Wiese 43eb9aadcd Merge branch 'MDL-32570-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-10-08 13:47:18 +08:00
Dan Poltawski fa4dda1dcb Merge branch 'MDL-38655_25' of git://github.com/aolley/moodle into MOODLE_25_STABLE 2013-10-08 13:21:37 +08:00
Damyon Wiese a59646ee31 Merge branch 'MDL-42122_25' of git://github.com/aolley/moodle into MOODLE_25_STABLE 2013-10-08 12:49:07 +08:00
Rossiani Wijaya eea9ffd551 MDL-38664 Lesson mod: code improvement for lesson attemps 2013-10-08 10:44:28 +08:00
Joseph Rézeau 21c314df14 MDL-38664 Lesson mod: fixed re-attempt unseen page 2013-10-08 10:44:17 +08:00
Marina Glancy 573ceb9459 Merge branch 'MDL-25176_m25' of https://github.com/merrill-oakland/moodle into MOODLE_25_STABLE 2013-10-08 12:03:48 +11:00
Petr Škoda 896a790f69 MDL-41197 normalize ascii text conversion 2013-10-08 00:00:21 +02:00
Sam Hemelryk 06db3cf3cc Merge branch 'MDL-42188_25' of git://github.com/stronk7/moodle into MOODLE_25_STABLE 2013-10-08 08:52:04 +13:00
Eloy Lafuente (stronk7) 2895da0152 MDL-42188 shifter: delete some orphaned files 2013-10-07 21:45:42 +02:00
Frederic Massart 7776c0d28f MDL-22669 course: Display section number for orphaned activities 2013-10-07 16:54:22 +08:00
Dan Poltawski 5a12c4e258 Merge branch 'MDL-42013_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-10-07 11:33:45 +08:00
Sam Hemelryk 2ec16f735a Merge branch 'MDL-42072_25' of https://github.com/totara/openbadges into MOODLE_25_STABLE 2013-10-07 15:39:42 +13:00
Sam Hemelryk c50daf9ae7 Merge branch 'w41_MDL-41197_m25_convnotices' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-10-07 13:42:47 +13:00
Sam Hemelryk 93bf71cd8e Merge branch 'MDL-41352-25' of git://github.com/phalacee/moodle into MOODLE_25_STABLE 2013-10-07 12:34:07 +13:00
Matteo Scaramuccia e5ae972885 MDL-40226 Files: Added the correct MIME Type for JNLP files.
JNLP stands for Java Network Launch Protocol, used to launch
Java Web Start applications. More details in:
http://docs.oracle.com/javase/tutorial/deployment/webstart/deploying.html
2013-10-06 16:37:51 +02:00
Joshua Johnston 92b226d58d MDL-41520 LTI: Does not track page views for completion 2013-10-04 09:46:07 -04:00
Fred Woolard b8fe053e0d MDL-42069 mod_quiz add lastname sort for manual grading 2013-10-04 09:11:11 -04:00
Petr Škoda 804f44a191 MDL-42047 fix cohort method name error after deleting cohort 2013-10-04 11:32:56 +02:00
Petr Škoda 1e8dcbd251 MDL-41197 ignore all problems when converting texts 2013-10-04 11:10:36 +02:00
David Monllao 29a3e32499 MDL-42013 behat: Fixing related tests
We had no false positives because of this
issue, but some checking have been restricted
to specific DOM parts.
2013-10-04 15:03:25 +08:00
David Monllao 56a0ca595b MDL-42013 behat: Fixing problem with should not see
Using 'should see' outputs rather than an incorrect
xpath query. Also our custom selectors are not properly
used by WebAssert so switching to find xpath.
2013-10-04 15:03:24 +08:00
Sam Hemelryk 22084d5ea2 weekly release 2.5.2+ 2013-10-04 15:43:50 +13:00
Sam Hemelryk af911b089a Merge branch 'install_25_STABLE' of git://git.moodle.org/moodle-install into MOODLE_25_STABLE 2013-10-04 15:43:45 +13:00
Adam Olley 635216b08b MDL-38655: mod_assign: Use correct ordering on cap checks for submission downloads
Conflicts:
	mod/assign/locallib.php
2013-10-04 09:32:52 +09:30
Adam Olley 60da0467ec MDL-42122 block_community: Dont show install option without capability 2013-10-03 14:25:55 +09:30
Rajesh Taneja e35aca3b0b MDL-41744 Users: Convert key to value in bulk upload
Menu profile field expects value, during bulk upload if value is passed by form
then options key is passed. So converting key to value if passed though form
2013-10-03 10:18:00 +08:00
Sam Hemelryk a4aec61855 Revert "MDL-33569 themes: Labels create extra margin below content."
This reverts commits:
* 050e0d8724.
* 055418e963.
2013-10-03 14:43:15 +13:00
Eric Merrill 86eec9b429 MDL-25176 forum Redirects for new discussions shouldn't use SESSION
Unset the session->fromdiscussion var, because we know that the correct
path will be computed later.
2013-10-01 21:18:43 -04:00
Damyon Wiese b085cf96d3 Merge branch 'MDL-41955_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-10-02 08:42:34 +08:00
Yuliya Bozhko 320376f0b7 MDL-41659 badges: Display course/site names through format_string() 2013-10-02 08:45:41 +13:00
Tim Lock 06e8ce4f88 MDL-41996: Don't show the Review Attempt link if no attempts exist. 2013-10-01 20:04:55 +02:00
Eloy Lafuente (stronk7) 46b23b69fa Merge branch 'wip-MDL-41921-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-10-01 19:56:27 +02:00
Eloy Lafuente (stronk7) a348f55e3f Merge branch '41997-25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-10-01 19:53:22 +02:00
Eloy Lafuente (stronk7) 3ee1a66de9 Merge branch 'w40_MDL-41999_m25_userpw' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-10-01 15:59:15 +02:00
Marina Glancy 31f1464297 Merge branch 'MDL-32592-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-10-01 20:49:29 +10:00
Marina Glancy e4f0750a12 Merge branch 'MDL-39653-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-10-01 20:43:25 +10:00
Adrian Greeve 2bb1ee93df MDL-41967 - Gradebook: Fixed an sql syntax error for gradebook custom profile fields. 2013-10-01 17:58:16 +08:00
Damyon Wiese 190cd152a6 Merge branch 'MDL-41913_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-10-01 15:54:27 +08:00
Dan Poltawski b1edf3afac MDL-32570 enrol_imsenterprise: don't hardcode default category id 2013-10-01 15:51:35 +08:00
Damyon Wiese f0233c7acd Merge branch 'MDL-41882_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE
Conflicts:
	admin/tool/generator/version.php
2013-10-01 15:41:33 +08:00
Damyon Wiese a2742ff0de Merge branch 'MDL-41861_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-10-01 15:36:25 +08:00
Damyon Wiese 1702f40046 MDL-41853 tool_generator: Fix version bump for backport 2013-10-01 15:18:48 +08:00
Damyon Wiese df831ae75f Merge branch 'MDL-41853_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-10-01 14:56:53 +08:00
Nadav Kavalerchik fc41842371 MDL-41264 Themes: Right align Tabs on Wiki page, when in RTL mode (theme/clean) 2013-10-01 15:02:26 +10:00
Sam Hemelryk e45ef9ec88 MDL-41398 bootstrap: added a maintenance layout 2013-10-01 14:31:49 +10:00
Yuliya Bozhko 021501f152 MDL-42072 badges: Fix output and headers in badges ajax scripts 2013-10-01 16:48:04 +13:00
Sam Hemelryk 5076c6dd17 MDL-41828 mod: fixed navbar when adding modules to a course 2013-10-01 13:32:59 +10:00
Sam Hemelryk a91af282a3 MDL-41900 events: avoid new debug call within unit tests 2013-10-01 16:21:10 +13:00
Sam Hemelryk 8c90bbcde0 Merge branch 'MDL-41995_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-10-01 14:50:13 +13:00
Sam Hemelryk ae9f3c0671 Merge branch 'MDL-41900-m25' of git://github.com/micaherne/moodle into MOODLE_25_STABLE 2013-10-01 14:35:37 +13:00
Sam Hemelryk 82ce52426e Merge branch 'MDL-41894-m25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-10-01 13:44:54 +13:00
AMOS bot 944cd43d0d Automatically generated installer lang files 2013-10-01 00:41:46 +00:00
Sam Hemelryk b45f2c01c6 Merge branch 'MDL-41228_25' of https://github.com/totara/openbadges into MOODLE_25_STABLE 2013-10-01 13:37:29 +13:00
Sam Hemelryk a45ff7d8a6 Merge branch 'wip-MDL-41676-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-10-01 10:01:16 +13:00
Sam Hemelryk 3f4b04ec3e Merge branch 'MDL-37973_m25' of https://github.com/merrill-oakland/moodle into MOODLE_25_STABLE 2013-10-01 09:53:56 +13:00
Eloy Lafuente (stronk7) 69634029f5 Merge branch 'MDL-26408-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-09-30 16:01:46 +02:00
David Monllao 2980b5cfff MDL-41955 tool_generator: Adding a file size limit 2013-09-30 17:06:02 +08:00
David Monllao 10a020f07f MDL-41955 tool_generator: New unit test checking the generated files size 2013-09-30 17:06:02 +08:00
David Monllao 8c76886dff MDL-41913 tool_generator: Adding a CLI tool to generate the test plan 2013-09-30 17:05:06 +08:00
David Monllao 71f774e5e8 MDL-41913 tool_generator: Adding a test plan generator to feed JMeter
Also changing course_backend.php coding style
according to codechecker.
2013-09-30 17:00:52 +08:00
David Monllao 3320e59e51 MDL-41913 tool_generator: Import .jmx template
Ideally we should generate all the XML based on
modular components so we can also switch templates
between different sizes, this is a first step and
more work should be done in future in this direction.
2013-09-30 17:00:52 +08:00
David Monllao 188fd8006b MDL-41913 tool_generator: Refactoring make_form to make_course_form
Also:
- Added a soft password for the
newly generated users so we can use
them to log in the site when running
performance tests.
- Added a method to see the courses-users
relation from outside course_backend class.
2013-09-30 17:00:52 +08:00
David Monllao c09fed9ee4 MDL-41882 tool_generator: New unit test 2013-09-30 16:58:36 +08:00
David Monllao 028b8dc3e9 MDL-41882 tool_generator: Adding maketestsite script
Uses maketestcourse.php to set up
a test site.
2013-09-30 16:58:34 +08:00
Marina Glancy d23f108197 Merge branch 'MDL-41954-workshop-zero-variance_25' of git://github.com/mudrd8mz/moodle into MOODLE_25_STABLE 2013-09-30 16:10:48 +10:00
Adam Olley 4e87aec553 MDL-40515: report_log: List activities in optgroups
Prevents users from generating reports on invalid values

Change-Id: If358fa06c8dadd33bb2875ea54ab4bce97b16aff
2013-09-30 11:18:03 +09:30
Sam Hemelryk df3108ed21 NOBUG: rebuilt bootstrap CSS 2013-09-30 11:11:03 +13:00
Sam Hemelryk fea809a7b8 Merge branch 'MDL-33569_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE 2013-09-30 10:45:44 +13:00
Sam Hemelryk 96f91e34bf MDL-41997 cache: dummy store now uses static acceleration for session + request 2013-09-30 09:42:39 +13:00
Sam Hemelryk 0055b93959 MDL-41997 cache: added unit tests for disabled stores 2013-09-30 09:42:36 +13:00
Mary Evans 055418e963 MDL-33569 theme_boostrapbase: adding re-compiled style/moodle.css 2013-09-28 16:00:23 +01:00
Mary Evans 050e0d8724 MDL-33569 themes: Labels create extra margin below content. 2013-09-28 15:55:06 +01:00
Petr Škoda e404da07d4 MDL-41999 do not use $USER->password directly 2013-09-27 10:54:43 +02:00
Marina Glancy b81afac481 MDL-41942 course: Allow course listings to work with caches disabled 2013-09-27 18:34:37 +10:00
Marina Glancy b0aea95a96 MDL-41921 mod_url: less restrictions on URL field
Restoring functionality from 2.4 accidentally removed in MDL-34311
2013-09-27 18:33:44 +10:00
Marina Glancy 95d6999f89 MDL-41676 Corrected logic when to dim the activity name and content 2013-09-27 18:31:51 +10:00
Marina Glancy c777836c69 weekly release 2.5.2+ 2013-09-27 14:53:29 +10:00
Marina Glancy 9573950b9d Merge branch 'install_25_STABLE' of git://git.moodle.org/moodle-install into MOODLE_25_STABLE 2013-09-27 14:51:14 +10:00
Dan Poltawski c0a5cd3e33 MDL-39653 enrol_imsenterprise: only mail admins on change
The existing beavhiour was sending useless emails to admins and
generating warnings.

Thanks to Matthew Orlando for the suggested fix.
2013-09-27 12:23:48 +08:00
Mark Nelson e26f1e83a1 MDL-41995 calendar: changed the page layout for the export page 2013-09-26 16:54:20 +08:00
Dan Poltawski 7f5f0ba2d3 MDL-32592 enrol_imsenterprise: fix error when category not defined
thanks to Henrik Thorn for the fix
2013-09-26 14:59:48 +08:00
Dan Poltawski acd6ad0fa1 MDL-26408 enrol_imsenterprise: fix invalid component 2013-09-26 12:22:14 +08:00
AMOS bot f0b5658ee9 Automatically generated installer lang files 2013-09-26 00:44:18 +00:00
David Monllao 456c9d1648 MDL-41882 tool_generator: Refactoring backend class
Moving it to course_backend keeping generic
methods and attributes in backend class.

AMOS BEGIN
 MOV [size_0,tool_generator],[coursesize_0,tool_generator]
 MOV [size_1,tool_generator],[coursesize_1,tool_generator]
 MOV [size_2,tool_generator],[coursesize_2,tool_generator]
 MOV [size_3,tool_generator],[coursesize_3,tool_generator]
 MOV [size_4,tool_generator],[coursesize_4,tool_generator]
 MOV [size_5,tool_generator],[coursesize_5,tool_generator]
AMOS END
2013-09-25 10:13:30 +08:00
David Monllao b0e19c4ca6 MDL-41861 tool_generator: Adding fixeddataset option 2013-09-25 10:12:33 +08:00
David Monllao c65e322ff0 MDL-41861 tool_generator: Unit test for fixeddataset 2013-09-25 10:12:33 +08:00
David Monllao e6f9c31b6e MDL-41853 tool_generator: Adding required files
No autoloader in Moodle 2.5
2013-09-25 10:11:18 +08:00
Dan Poltawski 186a80d203 MDL-41853 tool_generator: fix use of raw LIKE sql 2013-09-25 10:11:18 +08:00
sam marshall e886af6e7e MDL-41853 Script to generate standard-size large course for testing 2013-09-25 10:11:16 +08:00
Eloy Lafuente (stronk7) d5971d75a1 Merge branch 'MDL-41910_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-09-25 03:11:49 +02:00
Petr Škoda 7c97129a9a MDL-41223 do not store any form of login URL in $SESSION->wantsurl
Credit goes to Michael Milette, thanks.
2013-09-25 10:57:54 +10:00
Eloy Lafuente (stronk7) a943166fc1 Merge branch 'MDL-41852_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-09-25 02:49:10 +02:00
Matt Petro 8917283c22 MDL-41660 backup ims-cc: Use correct temp directory 2013-09-25 02:15:47 +02:00
Eloy Lafuente (stronk7) 8ecd67c48e Merge branch 'MDL-41342_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-09-25 02:13:22 +02:00
Eloy Lafuente (stronk7) 1cf52db9b4 Merge branch '40903-25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-09-25 02:00:34 +02:00
David Mudrák b5b58382fb MDL-41954 Fix the grade for assessment calculation in the Workshop module
In a pretty rare case of zero variance of received assessments, the "distance"
of the evaluated assessment from the referential ("best") one was not increased
regardless it's actual value. This led to higher grades for assessments in
certain situations (see the tracker for a particular example).
2013-09-25 01:57:03 +02:00
Sam Hemelryk b8cf62bf04 Merge branch 'MDL-41907_m25' of https://github.com/merrill-oakland/moodle into MOODLE_25_STABLE 2013-09-25 10:18:13 +12:00
Eloy Lafuente (stronk7) 4008db6d6a Merge branch 'wip-MDL-41594-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-09-24 23:21:04 +02:00
Marina Glancy 90336898da Merge branch 'MDL-40550_25' of https://github.com/totara/openbadges into MOODLE_25_STABLE 2013-09-24 21:43:18 +10:00
Marina Glancy 0184a31bad Merge branch 'MDL-41929_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-09-24 21:32:35 +10:00
Sam Hemelryk de760ea9a3 MDL-40903 cached: fixed up versions 2013-09-24 21:13:33 +12:00
Sam Hemelryk cf078f8427 MDL-40903 cache: renamed persistcache to staticacceleration 2013-09-24 21:13:33 +12:00
Sam Hemelryk 6ad2368071 MDL-40903 cache: fixed up event invalidation 2013-09-24 21:13:33 +12:00
Marina Glancy ae3f682a63 MDL-40903 cache: Unittests and small fixes for persistent application cache 2013-09-24 21:13:33 +12:00
Sam Hemelryk b7a3f7457d MDL-40903 cache: coding style tidyup pre-integration 2013-09-24 21:13:32 +12:00
Sam Hemelryk c755b4ef1f MDL-40903 cache: converted persistent into persistentdata
At the same time all cache instances were made persistent
2013-09-24 21:13:32 +12:00
Ankit Agarwal bdd668849b MDL-41894 feedback: Remove unused code, which is generating warnings 2013-09-24 15:01:15 +08:00
AMOS bot bd993fcf5c Automatically generated installer lang files 2013-09-24 00:42:00 +00:00
Sam Hemelryk 72ca4b0acf Merge branch 'MDL-40848_m25' of git://github.com/totara/openbadges into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-09-24 09:17:52 +12:00
Sam Hemelryk 9b70e23754 Merge branch 'MDL-36465-25' of git://github.com/andrewnicols/moodle into MOODLE_25_STABLE 2013-09-24 08:32:57 +12:00
Tim Hunt 4c619d6788 MDL-41929 quiz statistics, overall stats not displayed. 2013-09-23 18:07:47 +01:00
Marina Glancy 1537f8241e Merge branch 'MDL-41833-m25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-09-23 19:17:34 +10:00
David Monllao 0129cc9ec7 MDL-41910 user: Allowing LASTACCESS_UPDATE_SECS overwrite 2013-09-23 16:57:53 +08:00
Andrew Nicols 35c81d2938 MDL-36465 Course JavaScript: Ensure that the zero section is not draggable 2013-09-23 09:19:18 +01:00
Jason Fowler c537b4a9d5 MDL-41352 MyMobile - fixing region/layout/drag-n-drop issues 2013-09-23 14:09:43 +08:00
Marina Glancy 30f43b0e9c Merge branch 'wip-MDL-41772-25' of git://github.com/abgreeve/moodle into MOODLE_25_STABLE 2013-09-23 14:40:35 +10:00
AMOS bot 7ceb85398d Automatically generated installer lang files 2013-09-21 00:42:38 +00:00
Sam Hemelryk ca1c4bacbf weekly release 2.5.2+ 2013-09-20 14:42:03 +12:00
Sam Hemelryk 158785810a Merge branch 'install_25_STABLE' of git://git.moodle.org/moodle-install into MOODLE_25_STABLE 2013-09-20 14:34:46 +12:00
Eric Merrill f9c7450825 MDL-41907 Repositories: Maintain the sortorder of a file when overwriting it. 2013-09-19 18:53:58 -04:00
Eric Merrill c41e70525b MDL-37973 gradebook Return a maxgrade of '-' if grade type is TEXT
Including tests for correct return from
grade_edit_tree_column_range->get_item_cell()
2013-09-19 10:58:05 -04:00
Michael Aherne 98fa01e59f MDL-41900 events Log handler failures 2013-09-19 15:55:50 +01:00
David Monllao c455e8bca5 MDL-41342 admin: Adding warning when upgrading a test site 2013-09-19 15:07:37 +08:00
AMOS bot 9fbe8daafb Automatically generated installer lang files 2013-09-19 00:44:11 +00:00
sam marshall 5b15ad907a MDL-41852 Resource: Does not have generator 2013-09-18 15:44:47 +08:00
Simon Coggins 6880b9f822 MDL-40848 badges: Validate backpack connection via Persona
Instead of trusting that the user owns the email address they
    supply, we now require them to login via Persona before
    connecting them to the backpack
2013-09-18 12:58:42 +12:00
AMOS bot fc246cab3c Automatically generated installer lang files 2013-09-18 00:45:30 +00:00
Eloy Lafuente (stronk7) dd344e3709 Merge branch 'wip-mdl-41717-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-09-17 21:22:42 +02:00
Eloy Lafuente (stronk7) 2307474181 Merge branch 'MDL-41728-m25' of git://github.com/sammarshallou/moodle into MOODLE_25_STABLE 2013-09-17 21:18:34 +02:00
Eloy Lafuente (stronk7) 9336caebaa Merge branch 'wip-mdl-41711-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-09-17 20:29:59 +02:00
Marina Glancy 09b8f892ac MDL-41594 Bug fix for orphaned invisible categories
thanks to L.Sanocki
2013-09-17 20:58:33 +10:00
Ankit Agarwal 81d8cc2765 MDL-41833 feedback: Fix setType() warning when deleting a response in feedback 2013-09-17 15:26:29 +08:00
Eloy Lafuente (stronk7) 69253612e4 Merge branch 'MDL-41595_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE 2013-09-17 02:15:22 +02:00
Sam Hemelryk b27ca3514e Merge branch 'MDL-41667_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-09-17 08:58:33 +12:00
Sam Hemelryk 6d05276c02 Merge branch 'MDL-38317-moodle25' of git://github.com/StudiUM/moodle into MOODLE_25_STABLE 2013-09-17 08:39:02 +12:00
Jean-Philippe Gaudreau b35c36def5 MDL-38317 grade import: Translation support for import mappings form. 2013-09-16 09:20:12 -04:00
Marina Glancy eca39eaeee Merge branch 'MDL-41315-25' of git://github.com/damyon/moodle into MOODLE_25_STABLE 2013-09-16 15:32:45 +10:00
Yuliya Bozhko a2547d7087 MDL-40550 badges: Change wording of badge activation message
Add confirmation check when activating badge from management page
2013-09-16 15:34:33 +12:00
Sam Hemelryk 82dc37c88c Merge branch 'MDL-38194-m25' of git://github.com/sammarshallou/moodle into MOODLE_25_STABLE 2013-09-16 13:55:25 +12:00
Sam Hemelryk c998a75fdb Merge branch 'MDL-41637_25' of https://github.com/totara/openbadges into MOODLE_25_STABLE 2013-09-16 13:50:54 +12:00
AMOS bot d443dd501f Automatically generated installer lang files 2013-09-16 00:40:26 +00:00
Sam Hemelryk f534464a06 Merge branch 'MDL-41662_25' of https://github.com/totara/openbadges into MOODLE_25_STABLE 2013-09-16 10:47:47 +12:00
Sam Hemelryk f8eaa73b41 Merge branch 'm25_MDL-37524' of git://github.com/danmarsden/moodle into MOODLE_25_STABLE 2013-09-16 10:38:34 +12:00
Sam Hemelryk 10c3f9e7e8 Merge branch 'wip-MDL-27684-MOODLE_25_STABLE' of git://github.com/satrun77/moodle into MOODLE_25_STABLE 2013-09-16 10:27:01 +12:00
Dan Marsden 7cf1d8bd60 MDL-37524 SCORM: mode not calculated correctly. 2013-09-16 10:13:18 +12:00
AMOS bot caf0834e40 Merge branch 'MOODLE_25_STABLE' into install_25_STABLE 2013-09-14 00:41:35 +00:00
sam marshall 5912c3e43e MDL-38194 Files: Allow download of large backup files
The PHP readfile function does not work for files more than 2GB.
This commit provides a wrapper that can be used so that files less
than 2GB are sent with readfile, and files larger than 2GB are
sent manually.

The change applies to all uses of pluginfile.php, although in
reality, backup files are probably the only ones likely to be more
than two gigabytes.
2013-09-13 15:01:13 +01:00
Tim Hunt 71eb4e2cda MDL-41667 quiz: Fix CSS rules.
Thanks to Renaat Debleu for spotting this problem.
2013-09-13 11:00:42 +01:00
Henning Bostelmann eb6492e62f MDL-29987 File resource: fix problem with PDF display on mobile devices
Setting the default display option for PDF files from DISPLAY_EMBED to DISPLAY_OPEN
2013-09-13 10:26:57 +01:00
Damyon Wiese 0b213ee795 MDL-41315 assign: Add unit test for groupmembersonly 2013-09-13 16:47:11 +08:00
Damyon Wiese ad02ac1d8c MDL-41315 assign: Dont show users not in the current grouping
This is for separate groups mode. Note - this will be slower - but
this feature is experimental and groupslib does not provide a nicer api.

Conflicts:

	mod/assign/locallib.php
2013-09-13 16:47:08 +08:00
Adrian Greeve 09c5de5075 MDL-41772 - mod_data: Fixed database_module comments not being restored. 2013-09-13 15:33:17 +08:00
Damyon Wiese 444433b575 weekly release 2.5.2+ 2013-09-13 14:08:51 +08:00
Mohamed Alsharaf a12346d527 MDL-27684 repository: make require_login() throws exception instead of redirect 2013-09-13 16:08:36 +12:00
AMOS bot 3eb159ca23 Automatically generated installer lang files 2013-09-13 00:48:40 +00:00
David Monllao ffc377877b MDL-41555 behat: Fixing catch statement location
The exception is thrown when getting the
browser session, not when accessing the first
URL.
2013-09-12 15:53:36 +08:00
Damyon Wiese da09c760a4 MDL-37804 assign: Return proper notice when submissions closed.
MDL-38267 was returning the html page when it should have been adding to the list
of notices and returing false.
2013-09-12 10:37:29 +08:00
sam marshall c4492952bf MDL-41728 Backup: Unnecessary use of in_array in base_plan
Remove unnecessary use of in_array which causes performance problems
when loading the plan for very large courses.
2013-09-11 14:36:08 +01:00
Rajesh Taneja 7671200b0f MDL-28561 blocks_rss_client: Fixed line separator color in bootstrap
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-09-11 17:44:27 +08:00
Rajesh Taneja d1b7e2dfa5 MDL-41717 Theme: Aligned completion checkbox and commands on course page for label 2013-09-11 16:16:36 +08:00
Rajesh Taneja 314285ef10 MDL-41711 Glossary: Fixed seach label alignment 2013-09-11 14:39:01 +08:00
prateeksachan c544b9c601 MDL-38267 assign: No Submit button after cut-off date 2013-09-11 12:18:27 +08:00
Sam Hemelryk 8377c04acf Merge branch 'wip-mdl-41605-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-09-11 10:49:53 +12:00
Sam Hemelryk 884d1b2a41 Merge branch 'MDL-41658_M25' of git://github.com/kordan/moodle into MOODLE_25_STABLE 2013-09-11 09:42:25 +12:00
Matthew Noorenberghe 4342b9320d MDL-41634 - URL Download Repository doesn't warn when asked to download non-image files 2013-09-11 09:37:35 +12:00
Sam Hemelryk 7952a767a3 Merge branch 'MDL-41528_MOODLE_25_STABLE' of https://github.com/nitzo/moodle into MOODLE_25_STABLE 2013-09-11 09:26:21 +12:00
Sam Hemelryk eb398c5ce6 Merge branch 'MDL-41630-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-09-11 09:20:39 +12:00
Sam Hemelryk 89c92427ad Merge branch 'wip-MDL-41578-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-09-11 09:00:23 +12:00
Sam Hemelryk c26684b2be Merge branch 'MDL-41587_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-09-11 08:52:38 +12:00
Sam Hemelryk 492351897d Merge branch 'MDL-41555_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-09-11 08:50:50 +12:00
Rajesh Taneja b7e603a70c MDL-41590 Enrolments: If course is deleted, then use courseid for reference 2013-09-11 08:46:59 +12:00
Yuliya Bozhko 05f840e8a4 MDL-40471 badges: Fixes around badge capabilities and navigation 2013-09-11 08:43:20 +12:00
Dan Poltawski 039b551f68 Merge branch 'MDL-40631-25' of git://github.com/damyon/moodle into MOODLE_25_STABLE 2013-09-10 14:31:51 +08:00
Dan Poltawski e869047273 Merge branch '41189-25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-09-10 14:12:18 +08:00
Damyon Wiese 0e3841a273 Merge branch 'wip-mdl-23335-m25' of https://github.com/deraadt/moodle into MOODLE_25_STABLE 2013-09-10 12:57:11 +08:00
Damyon Wiese 62674fcafc MDL-41497 auth_db: Fix typo in lang string. 2013-09-10 12:25:31 +08:00
Damyon Wiese b0d5d6b0bb Merge branch 'MDL-41497-25' of https://github.com/willylee/moodle into MOODLE_25_STABLE 2013-09-10 12:23:30 +08:00
Dan Poltawski 81a6ccf14a Merge branch 'MDL-28561_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE 2013-09-10 12:05:02 +08:00
Damyon Wiese 3a15ac7c21 Merge branch 'MDL-41451_25' of https://github.com/pauln/moodle into MOODLE_25_STABLE 2013-09-10 11:59:08 +08:00
Damyon Wiese 9c8c97c53e Merge branch 'MDL-41626-moodle25' of github.com:StudiUM/moodle into MOODLE_25_STABLE 2013-09-10 09:16:20 +08:00
Sam Hemelryk 3f6c2f7de8 Merge branch 'MDL-41600_25' of git://github.com/aolley/moodle into MOODLE_25_STABLE 2013-09-10 13:11:54 +12:00
Adam Olley e8c41b0a5f MDL-41600: qformat_blackboard_six Fix test_import_match fail w/ddmatch
With qtype_ddmatch installed, the unit tests for qformat_blackboard_six
fail as they generate ddmatch questions instead of match ones. This
patch checks for ddmatch and changes the test to expect that instead if
its installed.
2013-09-10 09:13:31 +09:30
Sam Hemelryk 0e2b007f33 MDL-32862 backup: fixed missing global 2013-09-10 10:47:25 +12:00
Sam Hemelryk 7eb3ddf9b5 Merge branch 'wip-MDL-32862-25' of git://github.com/abgreeve/moodle into MOODLE_25_STABLE 2013-09-10 09:38:35 +12:00
Sam Hemelryk eb52eb1df0 Merge branch 'MDL-29378-survey-25' of git://github.com/mudrd8mz/moodle into MOODLE_25_STABLE 2013-09-10 09:35:59 +12:00
Dan Poltawski 9778aa2333 Merge branch 'MDL-41254-m25' of git://github.com/micaherne/moodle into MOODLE_25_STABLE 2013-09-09 18:04:39 +08:00
David Mudrák 9cc00ae71e MDL-29378 Fix the recent string modification
But accident, I have modified the string 'collesaintro' in the previous patch.
The correct string to be amended is 'collesapintro'.
2013-09-09 11:21:48 +02:00
William Tam 04928750f0 MDL-37804 mod/assign: Students no longer able to submit files after due date with Prevent late submissions turned on. 2013-09-09 17:13:33 +08:00
Mary Evans 29892d8739 MDL-41595 mod_book: Book mod does not add TOC to default region 2013-09-09 09:48:53 +01:00
Mary Evans 6d44eaad0c MDL-40575 theme_bootstrapbase: Unable to scroll language menu in theme/clean. 2013-09-09 16:10:17 +08:00
Dan Poltawski 4d9ae8de10 Merge branch 'MDL-41163-m25' of git://github.com/sammarshallou/moodle into MOODLE_25_STABLE 2013-09-09 15:39:45 +08:00
Damyon Wiese fa2d417f36 Merge branch 'wip-MDL-41517-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-09-09 12:10:53 +08:00
Damyon Wiese d2b7eee400 Merge branch 'm25_MDL-31232' of git://github.com/danmarsden/moodle into MOODLE_25_STABLE 2013-09-09 11:45:30 +08:00
Rajesh Taneja e232c3b900 MDL-41605 Enrolments: Updated unassign role url to use roleid as param
Filter on enrolled users page use role param to perform filtering by role,
and unassign role also contain role param to remove user role in course
which used to conflict. Looking at assign role, we use roleid param, so
using roleid for unassigning as well
2013-09-09 09:19:00 +08:00
AMOS bot 46658b1dcf Automatically generated installer lang files 2013-09-09 00:44:15 +00:00
Sam Hemelryk 971d920469 MDL-41417 course: fixed idnumbertaken string 2013-09-09 12:16:17 +12:00
Yuliya Bozhko e3fc376a86 MDL-41637 badges: Update modules ids retrieval 2013-09-09 11:56:38 +12:00
Paul Nicholls c50e070d29 MDL-41451 - formslib: use create_function instead of inline function
As per MDL-39432, closure-style inline functions can result in fatal
errors when using eAccelerator and thus should be avoided.
2013-09-09 11:29:59 +12:00
Yuliya Bozhko 37deeaf42e MDL-41662 badges: Fix viewing user profile when not logged in 2013-09-09 11:23:49 +12:00
Sam Hemelryk 119bc4adfc Merge branch 'MDL-38794_25' of https://github.com/prateeksachan/moodle into MOODLE_25_STABLE 2013-09-09 11:12:23 +12:00
Sam Hemelryk 9691b405fc Merge branch 'MDL-41417_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-09-09 10:51:07 +12:00
Sam Hemelryk efe6343ee0 Merge branch 'MDL-29378-survey-25' of git://github.com/mudrd8mz/moodle into MOODLE_25_STABLE 2013-09-09 10:48:37 +12:00
Sam Hemelryk a5f2a9da42 MDL-41189 fixed overflow issue with filepicker thumbnail 2013-09-09 08:24:35 +12:00
kordan 3746d1ae8b MDL-41658 theme_formal_white: text in input select is now never centered (fixed at central level) 2013-09-08 21:03:30 +02:00
AMOS bot 60a9a13c10 Automatically generated installer lang files 2013-09-08 00:43:07 +00:00
Eloy Lafuente (stronk7) 6acbecf531 Moodle release 2.5.2 2013-09-07 14:27:18 +02:00
Eloy Lafuente (stronk7) 93e4ea20f2 Merge branch 'install_25_STABLE' of git://git.moodle.org/moodle-install into MOODLE_25_STABLE 2013-09-07 14:11:59 +02:00
Dan Poltawski 1aecfc42b6 MDL-41623 rss: clean output rss content 2013-09-07 10:41:37 +08:00
Eloy Lafuente (stronk7) 0694d65e7e MDL-41623 ensure all rss links are valid urls. 2013-09-07 04:05:38 +02:00
AMOS bot 60d9fe07a6 Automatically generated installer lang files 2013-09-07 00:43:08 +00:00
Mark Nelson 33a42df4ad MDL-41417 course: allow the use of duplicated idnumbers if they existed before fix 2013-09-06 15:19:01 +08:00
Francis Devine 85251082bf MDL-41417 course: prevent duplicate idnumbers being used when updating a course 2013-09-06 15:17:00 +08:00
Adrian Greeve 769bef0ee0 MDL-32862 - Backup: Rewriting resource_old links on backup. 2013-09-06 14:51:48 +08:00
Frederic Massart 5a45f5fd84 MDL-41630 oauth: Throw exception instead of dying on error 2013-09-06 10:48:15 +08:00
Paul Nicholls 4e93e23bcd MDL-41451 - Large forms are truncated by max_input_vars
By parsing php://input in chunks, we can bypass max_input_vars for
forms which do not use the "multipart/form-data" enctype.  This can
be (and is) safely skipped if there are fewer than max_input_vars
fields submitted as part of $_POST.
2013-09-06 14:37:29 +12:00
Marina Glancy c93c81e263 MDL-41578 Fixed bug in coursecat::has_course_overviewfiles 2013-09-06 10:52:58 +10:00
AMOS bot 4589706812 Automatically generated installer lang files 2013-09-06 00:47:47 +00:00
AMOS bot ce31fccf0e Merge branch 'MOODLE_25_STABLE' into install_25_STABLE 2013-09-06 00:47:47 +00:00
Nitzan Bar b8648c74ed MDL-41528 enrol/ldap course default settings when no course template is selected 2013-09-06 02:13:22 +03:00
Jean-Philippe Gaudreau c729f19add MDL-41626 cas auth: Setting the right url for the multi-authentication page 2013-09-05 16:47:25 -04:00
sam marshall 8f0ce3ca17 MDL-41163 Restore: Large course restore timeout on schema page 2013-09-05 17:14:42 +01:00
Dan Poltawski 2d269d8a4f Merge branch 'install_25_STABLE' of git://git.moodle.org/moodle-install into MOODLE_25_STABLE 2013-09-05 14:43:20 +08:00
Dan Poltawski d8835503a8 weekly release 2.5.1+ 2013-09-05 13:36:12 +08:00
David Monllao 084e8459ef MDL-41587 tool_behat: Adding site name constant 2013-09-05 10:35:13 +08:00
David Monllao 0141968b9e MDL-41555 tool_behat: Improving behat & selenium exceptions messages
Also moving the 'selenium not running'
checking to a proper place as it was
not thrown since the homepage start
visit() was introduced.
2013-09-05 10:34:33 +08:00
Mark Nelson 60abf0f6bd MDL-40924 badges: added a print_error call to prevent PHP notices when no badges are found 2013-09-05 10:05:52 +08:00
David Mudrák f60c7e6851 MDL-29378 Code cleanup in the Survey module
While working on the issue, I spotted these two places that were worth of
fixing. The first one is a trivial reminiscence of a previous refactoring,
after which both branches of the if() statement became equal.

The second one is actually a typo as in theory it could generate unexpected
input fields with the name like qPP1. Luckily this never happened due to the
way how survey questions are hardcoded (there are no questions with the type 2
that would require two answers to their subquestions).
2013-09-05 00:01:42 +02:00
David Mudrák b46b093e5c MDL-29378 Fix the form display in the Survey/COLLES P+A module
In MDL-7501, we stopped using rowspanning cells in the form table due to
accessibility. That had introduced a regression so in the COLLES P+A survey,
all the rows were displayed with the same background colour. This patch returns
the previous behaviour that each couple of items can be distinguished by the
background colour.

Also, there is no need to display "I prefer that" and "I found that" as a small
text any more. It had made sense in rowspanning layout but not after MDL-7501
was fixed.

And finally, as all items are enumerated now sequentially, there are actually
48 lines, each couple covering one question in two variants. I think it's
correct to reflect this in the description of the form so the text was slightly
amended.
2013-09-05 00:01:17 +02:00
David Mudrák 597f4acd89 MDL-29378 Fix regression in the Survey/COLLES P+A module
This basically reverts the commit 5196df589b that
I believe was a result of misunderstanding of how question type field is
(ab)used in the Survey module. As it took significant time to get familiar with
the overall logic of questions and their processing in the module, I left my
findings in added inline comments. The point is that it is $question->type that
matters. Types of questions listed as subquestions in the multi field is
irrelevant in that case (and all have it set to 1 IIRC).

This patch re-enables the "COLLES (Preferred and Actual)" survey type that did
not work at all due to regression.
2013-09-04 23:42:35 +02:00
David Monllao 0c26302299 MDL-41568 lang: Fix behat features after changes 2013-09-04 15:18:43 +08:00
Damyon Wiese 59abd58e9f Merge branch 'MDL-41485-m25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-09-04 12:26:15 +08:00
Jason Fowler e8924ea727 MDL-35925 Behat - Fixing behat test for Create Folder 2013-09-04 11:55:52 +08:00
Damyon Wiese 32c5dad8f0 MDL-41179 assign: Ensure a submission record exists for lock/unlock
Can't change the function params because it is changed in master already.
This will create a draft submission when a student is prevented from submitting
but that is a minor sideeffect and doesn't happen in master.
2013-09-04 11:02:30 +08:00
Dan Poltawski f5fc022310 Merge branch 'wip-mdl-41418-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-09-04 10:38:19 +08:00
Eloy Lafuente (stronk7) f2900567a8 Merge branch 'MDL-40566_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-09-03 22:07:04 +02:00
Eloy Lafuente (stronk7) 247f3e95e7 Merge branch 'MDL-41568-en_fix-25' of git://github.com/mudrd8mz/moodle into MOODLE_25_STABLE 2013-09-03 15:11:41 +02:00
Helen Foster 09fd8327e2 MDL-41568 Merge English strings from the en_fix language pack 2013-09-03 12:50:11 +02:00
Mary Evans e5c7462afa MDL-28561 blocks_rss_client: Fixes lines between RSS feed items are not showing in all themes. 2013-09-03 09:51:55 +01:00
Damyon Wiese cdecb726ec Merge branch 'MDL-41348_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-09-03 16:09:46 +08:00
Tim Lock a5db1b5432 MDL-41304: Hide and handle LDAP error when user not in context being checked 2013-09-03 16:05:49 +08:00
Jason Fowler 3a9a74b259 MDL-35925 filepicker - Fixing behat tests 2013-09-03 15:48:08 +08:00
Aparup Banerjee 75b0c09bd1 MDL-37564 linked dependant plugin component text to plugins DB 2013-09-03 14:56:49 +08:00
Damyon Wiese a36b1f9c65 Merge branch 'MDL-33472-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-09-03 14:38:28 +08:00
Damyon Wiese efb7f5173a Merge branch 'm25_MDL-29218_plugin_init_not_blocking_when_false' of https://github.com/scara/moodle into MOODLE_25_STABLE 2013-09-03 14:28:58 +08:00
Damyon Wiese 6093c3ddf8 Merge branch 'MDL-32690_restoreMissingAssignment_25' of https://github.com/moodlerooms/moodle into MOODLE_25_STABLE 2013-09-03 14:16:10 +08:00
Michael de Raadt 00a3eed306 MDL-23335 mod_forum: allow multi-lang filtering of shortened messages 2013-09-03 13:40:32 +08:00
Yuliya Bozhko 5dffc067da MDL-41228 phpunit: Reset message processors list in unit tests 2013-09-03 17:39:18 +12:00
Dan Poltawski a60215797d Merge branch 'w36_MDL-41255_m25_changepw' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-09-03 12:58:52 +08:00
Dan Poltawski 5202933cdd Merge branch 'MDL-41428-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-09-03 12:28:20 +08:00
Dan Poltawski 3e07519d3f Merge branch 'wip-MDL-41179-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-09-03 11:48:58 +08:00
Marina Glancy ff8018c65c MDL-41517 Do not call fix_course_sortorder unnecessarily
Thanks to Thomas Worthington
2013-09-03 13:45:56 +10:00
David Monllao fe0f9adbe3 MDL-40566 behat: Update features using the new options 2013-09-03 11:15:12 +08:00
David Monllao 9e14d32b12 MDL-40566 behat: Adding info about the deprecated attr. 2013-09-03 11:10:30 +08:00
David Monllao 9ae0496854 MDL-40566 behat: Moving from behat_command to behat_selectors 2013-09-03 11:10:30 +08:00
David Monllao 79b2f3a6f9 MDL-40566 behat: Adding behat_selectors
Class that manages moodle selectors transition
to behat default selectors.
2013-09-03 11:10:30 +08:00
Dan Poltawski fb7bb9af16 Merge branch 'wip-MDL-41317-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-09-03 10:40:34 +08:00
Dan Poltawski 0522e090fb Merge branch 'MDL-40214_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-09-03 10:06:48 +08:00
Matteo Scaramuccia 2fa86e7b56 MDL-29218 Repository: fixed a typo in the PHPDoc 2013-09-02 23:14:37 +02:00
Matteo Scaramuccia 259415dc8d MDL-29218 Repository: $pname, get rid of all the useless code
More details in the Tracker.
2013-09-02 23:14:35 +02:00
Matteo Scaramuccia fd0608a226 MDL-29218 Repository: Hide the repo if repository::plugin_init returns false 2013-09-02 23:14:34 +02:00
Damyon Wiese a4945e23d6 MDL-40631: Prevent students from submitting empty assignments. 2013-09-02 21:59:53 +08:00
Michael Aherne dc4018e5c2 MDL-41254 backup Raise time and memory limit in precheck. 2013-09-02 11:45:25 +01:00
Dan Poltawski 5e86f2ea86 Merge branch 'MDL-41149-25' of git://github.com/damyon/moodle into MOODLE_25_STABLE 2013-09-02 17:25:38 +08:00
Dan Poltawski 37d1f21b36 Merge branch 'MDL-35925-25' of git://github.com/phalacee/moodle into MOODLE_25_STABLE 2013-09-02 15:24:23 +08:00
Nitzan Bar 9dccff7793 MDL-41259 when duplicate course shortname exists an exception is thrown and sync is aborted 2013-09-02 15:08:28 +08:00
Damyon Wiese 18839cbbdc Merge branch 'MDL-41516-m25' of git://github.com/andrewnicols/moodle into MOODLE_25_STABLE 2013-09-02 14:58:21 +08:00
Dan Poltawski 0ab8ba8bf9 Merge branch 'MDL-36093-moodle25' of github.com:StudiUM/moodle into MOODLE_25_STABLE 2013-09-02 14:10:39 +08:00
Dan Poltawski d6edbd9945 MDL-40676 tests: fix null byte test. 2013-09-02 13:59:12 +08:00
Yuliya Bozhko b51c44ac3d MDL-40712 badges: Display recipient information 2013-09-02 13:45:57 +08:00
Yuliya Bozhko 129e7dffeb MDL-40924 badges: Add caching to external badges 2013-09-02 13:45:13 +08:00
Petr Škoda 71b06edf6b MDL-40676 ignore null bytes 2013-09-02 12:27:58 +08:00
Dan Poltawski 5218a6e8fb Merge branch 'MDL-41175_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-09-02 11:52:21 +08:00
Dan Poltawski 581a1695ac Merge branch 'MDL-41328-25' of git://github.com/damyon/moodle into MOODLE_25_STABLE 2013-09-02 11:44:58 +08:00
Andrew Nicols dacc2f8847 MDL-41328 Editor: Work around another iOS issue with TinyMCE
We apply this only on touchend and not touchstart or touchmove. The
location is not guaranteed until the end of the gesture, and there's no
need to keep applying focus on every move.
2013-09-02 09:41:48 +08:00
AMOS bot ce1a153335 Automatically generated installer lang files 2013-09-02 00:47:08 +00:00
Andrew Nicols 7402dcd5fd MDL-41516 Themes: Ensure that blocks are set up early
Blocks can require JavaScript which must be set up early in the page
lifecycle.
In order to do so, we should ensure that content is created in the standard
head setup before any other output is created so that any subsequent use of
block instances are no longer the first such use when they may already be
too late in the lifecycle.
2013-09-02 00:02:07 +01:00
Petr Škoda 24b58fa892 MDL-41255 fix incorrect redirection logic when changing password
Credit goes to Michael Milette.
2013-08-31 11:42:54 +02:00
AMOS bot 2fc1329f44 Merge branch 'MOODLE_25_STABLE' into install_25_STABLE 2013-08-31 00:43:54 +00:00
Willy Lee 42fd2c0b67 MDL-41497 auth_db: Added help text for using odbc dsn names instead 2013-08-30 10:24:50 -05:00
Willy Lee 1d2f1fe762 MDL-41497 enrol_database: Added help text for using odbc dsn names instead 2013-08-30 09:12:07 -05:00
Ankit Agarwal 756a0bc3a1 MDL-41485 calendar: Replace value of action buttons on managesubscription page with int 2013-08-30 17:20:30 +08:00
Dan Marsden 58a6404dbf MDL-31232 SCORM: Wrap suspend_data even when no spaces in value. 2013-08-30 20:34:51 +12:00
Damyon Wiese 0bd9f000b7 weekly release 2.5.1+ 2013-08-30 09:42:53 +08:00
AMOS bot 976d7e3442 Automatically generated installer lang files 2013-08-30 00:41:47 +00:00
Mark Nielsen 65d14146af MDL-32690: Restore 1.9 backup into 2.X fails on missing assignment type
Solution is as follows:
* Allow unsupported subplugins to convert from Moodle1 to Moodle2
* On Moodle2 restore hide unsupported subplugins
* Graceful error message in assignment of unsupported subplugins
2013-08-29 08:50:31 -07:00
Nadav Kavalerchik 3703b1d5de MDL-39682 Forms, File Picker, Themes: Fix alignment of Form's Labels and Input elements in RTL mode (theme/clean)
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-08-29 10:16:51 +08:00
Sam Hemelryk eb0aa3f039 MDL-41213 theme_bootstrapbase: fixed license filemanager overflow
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-08-29 09:12:16 +12:00
Jean-Philippe Gaudreau 13142cece4 MDL-36093 grade export: Fix HTML special characters printed litteraly. 2013-08-28 09:16:00 -04:00
Tim Hunt 69492f8654 MDL-41348 question code depends on filelib.
I think this used to work because mod/forum/lib.php used to be included
everywhere, and in turn included lib/formslib.php. We should declare the
dependencey explicitly.
2013-08-28 11:18:23 +01:00
Damyon Wiese ef8a68a73f MDL-41249 assign: Fix incorrect gradingform restore step
The mapping in the previous patch was wrong - mod assign uses
the area "submissions" but the itemid is the grade->id not the submission->id.
2013-08-28 16:31:32 +08:00
Colin Campbell f931b66a26 MDL-40214 mod_assign: Fixed issue with custom scale being lost during restore. 2013-08-28 10:52:10 +08:00
Marina Glancy 827c357830 MDL-41317 Set correct context to send bulk message page 2013-08-28 11:06:57 +10:00
AMOS bot 90f6e5af5d Automatically generated installer lang files 2013-08-28 00:53:50 +00:00
Eloy Lafuente (stronk7) 14616c145f Merge branch 'MDL-41387_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-08-27 21:00:28 +02:00
Eloy Lafuente (stronk7) 19ed5ae02f Merge branch 'm25_MDL-41410_Move_Comment_To_Appropriate_Place' of https://github.com/scara/moodle into MOODLE_25_STABLE 2013-08-27 19:46:00 +02:00
Dan Poltawski cb096cef51 Merge branch 'MDL-41366_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-08-27 18:09:41 +08:00
Damyon Wiese 01209ab96b Merge branch 'wip-MDL-41127-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-08-27 15:57:28 +08:00
Nadav Kavalerchik 0d376b00be MDL-39682 Forms, File Picker, Themes: Fix alignment of Form's Labels and Input elements in RTL mode (theme/clean)
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-08-27 15:50:10 +08:00
Damyon Wiese fe3ccd7e4d Merge branch 'MDL-41401-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-08-27 15:08:13 +08:00
Dan Poltawski 44e1bb52ec Merge branch 'MDL-41321_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-08-27 14:08:14 +08:00
Dan Poltawski 7f0cbbfea6 MDL-38765 quiz: fix incorrect comment 2013-08-27 14:00:18 +08:00
Dan Poltawski 60426b9a2d Merge branch 'MDL-38765_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-08-27 13:52:22 +08:00
Damyon Wiese 5212cb7d8f Merge branch 'MDL-40877-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-08-27 12:49:36 +08:00
Damyon Wiese 082b0866bc Merge branch 'MDL-40447_M25' of https://github.com/nadavkav/moodle into MOODLE_25_STABLE 2013-08-27 12:29:21 +08:00
Nadav Kavalerchik 1715d58161 MDL-37211 Backup: Migrate hard-coded strings to language string for the table header labels on the restore page 2013-08-27 11:57:53 +08:00
Dan Poltawski abfbffa640 Merge branch 'wip-MDL-41222-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-08-27 11:03:48 +08:00
Damyon Wiese 5b04c580a1 MDL-40321 theme_bootstrapbase: Combine reset into existing overrides file 2013-08-27 10:46:31 +08:00
Frederic Massart 7788b69996 MDL-41428 repository_coursefiles: Missing white space in name 2013-08-27 10:30:20 +08:00
Damyon Wiese ab2a4e3562 Merge branch 'wip-MDL-40321_M25' of git://github.com/gjb2048/moodle into MOODLE_25_STABLE 2013-08-27 10:08:19 +08:00
Marina Glancy 3ab2f6c00a MDL-41179 is_user_access_restricted_by_capability() must look at specified user and not current 2013-08-27 09:49:58 +10:00
Dan Poltawski 0846c3a54a Merge branch 'MDL-41291-25' of git://github.com/mr-russ/moodle into MOODLE_25_STABLE 2013-08-26 18:07:00 +08:00
Damyon Wiese 739ed4ce38 MDL-41213 filepicker: Version bump for css changes 2013-08-26 16:17:17 +08:00
Damyon Wiese 6472bbfbc7 Merge branch '41213-25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-08-26 16:10:02 +08:00
Rajesh Taneja 897995391b MDL-41418 Administration: Page context should be set before setting page title 2013-08-26 15:25:42 +08:00
Dan Poltawski 9a29baa05e Merge branch 'MDL-35930_m25' of git://github.com/rwijaya/moodle into MOODLE_25_STABLE 2013-08-26 14:56:34 +08:00
Dan Poltawski 7f3b8fa7b7 Merge branch 'MDL-36126_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-08-26 14:25:29 +08:00
Mark Nelson 58e8778421 MDL-36126 backup: ensure the backup_logs message does not exceed the maximum allowed length in the DB 2013-08-26 20:41:22 +08:00
Damyon Wiese 879330c428 Merge branch 'mdl25_MDL-29004_wiki-fix-images-in-printer-friendly-view' of https://github.com/brki/moodle into MOODLE_25_STABLE 2013-08-26 13:50:54 +08:00
Marina Glancy b47150934d MDL-41127 Remove the quick category move dropdowns if page is too big 2013-08-26 15:42:27 +10:00
Dan Poltawski c9b822387b Merge branch 'MDL-41249-25' of git://github.com/damyon/moodle into MOODLE_25_STABLE 2013-08-26 13:11:10 +08:00
Damyon Wiese 29b8db0e0b Merge branch 'wip-MDL-41106-m25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-08-26 09:43:58 +08:00
Damyon Wiese fcc147dd2d MDL-36803 tinymce: Version bump for js changes 2013-08-26 09:30:42 +08:00
Damyon Wiese c12ec889fa Merge branch 'MDL-36803-m25' of https://github.com/andrewnicols/moodle into MOODLE_25_STABLE 2013-08-26 09:29:53 +08:00
Russell Smith 1627ea320a MDL-41291 cache: Use fread to avoid race conditions 2013-08-26 10:50:57 +10:00
Sam Hemelryk 63ce1b82c6 MDL-41106 cache: several fixes for the session cache.
This issue makes several fixes for the session loader and the session store.
 * maxsize argument now works for session caches.
 * fixed performance hole when interation occurs frequently.
 * fixed cache purge bug occuring when multiple caches are defined before being used.
 * improved lastaccess handling.

Big thanks to Marina who contributed the following commits:
 * Always make sure the elements in cache are sorted so we need to remove only elements in the beginning of array
 * Remove expired elements from session store to free memory
 * Minor bug fixes
2013-08-26 09:50:16 +12:00
Sam Hemelryk 6cc1668dcd MDL-41213 bootstrap: fixed sizing of filepicker selected file licence selector 2013-08-26 08:39:01 +12:00
Sam Hemelryk 6568daf0db MDL-41213 filepicker: corrected outline of selected file dialogue 2013-08-26 08:38:34 +12:00
Mary Evans 1148cdfd6c MDL-41175 themes: Add/remove group members page broken on small screens. 2013-08-25 17:08:28 +01:00
Damyon Wiese 2f2cae97ad MDL-41149 assign: Group submission updates emailed to wrong person
grade_item_update was altering the userid in the submission record
instead of cloning it. This meant only the last member of a group
recieved all notifications meant for other students in the group.
2013-08-25 22:18:29 +08:00
Damyon Wiese a7effadb53 MDL-41249 assign: Restore step missing gradingform mapping
Thanks to Matthieu Raggett for the report and the solution.
2013-08-25 21:24:09 +08:00
Matteo Scaramuccia 44ac793fcb MDL-41410 Caching: move comment to the appropriate place.
MDL-38162 fixes the issue about testing the connection to the memcached
daemon, which means testing once the connection to the pool of servers
and not to each of the servers while being added to the pool.
It misses to move the comment to that code too.
2013-08-25 14:15:23 +02:00
Gareth J Barnard 70ff400c16 MDL-40321 theme_bootstrapbase: Remove URL's from printed pages. 2013-08-24 13:04:25 +01:00
AMOS bot 441678ecb4 Merge branch 'MOODLE_25_STABLE' into install_25_STABLE 2013-08-24 00:59:02 +00:00
Dan Poltawski eb0f2163dd MDL-41401 backup: fix misnamed test method 2013-08-23 15:10:24 +08:00
Dan Poltawski bda1180dc2 MDL-33472 google plugins: move helper functions to upgradelib.php
upgrade.php is reserved for the upgrade steps only. See also
MDL-34103
2013-08-23 11:34:03 +08:00
Damyon Wiese dd99fdd232 weekly release 2.5.1+ 2013-08-23 10:34:49 +08:00
Mark Nelson 848c33eb87 MDL-41387 tags: changed character case in string used when deleting a course 2013-08-22 17:41:15 +08:00
Dan Poltawski c177228500 Revert "MDL-36044 - Delete Icon ("X") blocks Score numbers, when in RTL mode (mod/assign , Rubrics editor)"
This reverts commit 42fabe1e87.
2013-08-22 17:36:28 +08:00
Damyon Wiese 6bd0ce14ed Merge branch 'wip-MDL-41196-m25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-08-22 11:21:46 +08:00
Dan Poltawski 6c98669c9b Merge branch 'MDL-30839-25' of git://github.com/phalacee/moodle into MOODLE_25_STABLE 2013-08-22 11:18:01 +08:00
Jason Fowler 1dc17ccea2 MDL-30839 Accessibility - Focusing on error on submit 2013-08-22 10:53:56 +08:00
Sam Hemelryk b59bdff58d MDL-41196 phpmailer: fixed unit test detection 2013-08-22 14:46:35 +12:00
Dan Poltawski c36c24ec26 Merge branch 'MDL-30839-25' of git://github.com/phalacee/moodle into MOODLE_25_STABLE 2013-08-22 10:14:40 +08:00
Dan Poltawski 2799d45f08 Merge branch 'MDL-39980_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-08-22 10:05:11 +08:00
Jason Fowler 93e775ab57 MDL-30839 Fixing extra line breaks in error msg 2013-08-22 09:06:01 +08:00
Mary Evans 7d7d4a7c30 MDL-41321 theme_bootstrapbase: Adds styling to groupinfobox. 2013-08-21 17:46:15 +01:00
Tim Hunt 3272a3f771 MDL-41366 qbehaviour_informationitem fix name capitalisation. 2013-08-21 12:29:55 +01:00
Tim Hunt f02a10f38c MDL-39980 essay attempt-on-last. Handle the no-files case.
This slighly changes the format for the way answers are stroed in the DB
in the case where there is some HTML content, but no files. This should
not cause any problems.
2013-08-21 11:57:46 +01:00
Tim Hunt 12ea5b4b00 MDL-38765 quiz view: fix duplicate message.
The "No more attempts are allowed" message was being shown twice. I
checked back, and it has been like that since before the quiz was
converted to use a renderer. Still, it looks horrible, so changing it.
2013-08-21 10:24:28 +01:00
Dan Poltawski 0901b32113 MDL-41191 add more test data to trigger duplicate course records 2013-08-21 15:45:48 +08:00
Dan Poltawski 5db91ce2a4 MDL-41191 mod_forum: avoid DISTINCT on TEXT columns
It is not supported by all db engines
2013-08-21 15:45:42 +08:00
Dan Poltawski 94bcd74360 Merge branch 'MDL-30839-25' of git://github.com/phalacee/moodle into MOODLE_25_STABLE 2013-08-21 15:17:52 +08:00
Jason Fowler 75d2b7da91 MDL-30839 Fixing extra line breaks in error msg 2013-08-21 15:01:07 +08:00
Frederic Massart 1ae04d082d MDL-40877 repository_url: Use textlib functions instead of mb_strlen() 2013-08-21 14:02:13 +08:00
Dan Poltawski e1435f9e6e Merge branch 'wip-MDL-36690-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-08-21 11:35:58 +08:00
Marina Glancy c6af0e03cb MDL-36690 Do not cache objects inside course.modinfo as they may fail to serialize
convert moodle_url (all other fields are numbers or strings) to string before caching and then back to moodle_url when restoring.
Otherwise serialized modinfo can contain \0 byte which cause problems in Postgres DB
2013-08-21 13:09:36 +10:00
Dan Poltawski 69504a7154 Merge branch 'wip-MDL-32191-m25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-08-21 10:44:39 +08:00
Sam Hemelryk 5cdbdc4a71 Merge branch 'wip-MDL-40830-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-08-21 13:13:18 +12:00
AMOS bot d43d1610c6 Automatically generated installer lang files 2013-08-21 00:43:39 +00:00
Sam Hemelryk 34884b3ec8 Merge branch 'MDL-41162_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-08-21 12:13:06 +12:00
Sam Hemelryk aee98acb92 Merge branch 'm25_MDL-41144' of git://github.com/danmarsden/moodle into MOODLE_25_STABLE 2013-08-21 10:59:54 +12:00
Andrew Nicols 37ca398629 MDL-36803 TinyMCE: Fix TinyMCE following touch events on iOS browsers 2013-08-20 23:58:23 +01:00
Sam Hemelryk 8afa842c60 Merge branch 'MDL-41157-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-08-21 10:34:21 +12:00
Sam Hemelryk 6ef239f1c8 Merge branch 'MDL-41196-m25' of git://github.com/andrewnicols/moodle into MOODLE_25_STABLE 2013-08-21 09:30:14 +12:00
Frederic Massart d4f16db9aa MDL-41136 badges: Prevent extra loading due to unnecessary includes 2013-08-20 17:51:32 +08:00
Damyon Wiese fa2a822a17 Merge branch 'MDL-41191-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-08-20 16:15:14 +08:00
Damyon Wiese f669d36b69 Merge branch 'MDL-41071-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-08-20 15:57:59 +08:00
Damyon Wiese 19ad0a3658 Merge branch 'w33_MDL-41112_m25_cachedist' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-08-20 15:15:40 +08:00
Damyon Wiese 1e28defac5 Merge branch 'MDL-40162_25' of https://github.com/totara/openbadges into MOODLE_25_STABLE 2013-08-20 14:49:08 +08:00
Jason Fowler 59d18ddfa7 MDL-35925 - File picker - Adding aria attributes to assist in accessibility 2013-08-20 14:19:06 +08:00
Damyon Wiese fe8c182f0a Merge branch 'MDL-27595-2_25' of https://github.com/bostelm/moodle into MOODLE_25_STABLE 2013-08-20 13:49:04 +08:00
Damyon Wiese 32fc11d77a Merge branch 'MDL-41036_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-08-20 13:00:54 +08:00
Damyon Wiese bf3ed270ec Merge branch 'MDL-41122_2.5' of git://github.com/kastashov/moodle into MOODLE_25_STABLE 2013-08-20 12:30:10 +08:00
Dan Poltawski ba54a0b296 Merge branch 'MDL-38203_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-08-20 11:34:20 +08:00
Nadav Kavalerchik 5d2f59236a MDL-36044 - Delete Icon ("X") blocks Score numbers, when in RTL mode (mod/assign , Rubrics editor) 2013-08-20 11:08:14 +08:00
Nadav Kavalerchik 14d6091f20 MDL-39236 - Right align table cells during install process, when in RTL mode (theme/standard, actually theme/base) 2013-08-20 11:03:15 +08:00
Dan Poltawski 23756ddfea Merge branch 'MDL-39980_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-08-20 10:48:09 +08:00
Marina Glancy 1afdd452aa MDL-41222 Remove unnecessary course cache rebuild 2013-08-20 10:26:34 +10:00
Dan Poltawski 31235acf2b Merge branch 'MDL-30839-25' of git://github.com/phalacee/moodle into MOODLE_25_STABLE 2013-08-19 17:51:11 +08:00
Damyon Wiese c67f7093a4 Merge branch 'm25_MDL-39572' of https://github.com/totara/moodle into MOODLE_25_STABLE 2013-08-19 15:43:59 +08:00
Damyon Wiese 97557f92f3 Merge branch 'MDL-40896_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-08-19 15:38:10 +08:00
Damyon Wiese 01f44f262a Revert "MDL-41106 cache: several fixes for the session cache."
This reverts commit 17aed88ed4.
This reverts commit 4e9ccabd81.
This reverts commit a0933c542e.
2013-08-19 15:32:56 +08:00
Dan Poltawski 2febf20223 Merge branch 'MDL-40893-25' of https://github.com/mr-russ/moodle into MOODLE_25_STABLE 2013-08-19 14:50:10 +08:00
Damyon Wiese 4fea0a3490 Merge branch 'wip-MDL-41106-m25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-08-19 13:51:25 +08:00
Damyon Wiese 07cafa966a Merge branch 'wip-MDL-36789-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-08-19 13:17:03 +08:00
Nadav Kavalerchik c299975400 MDL-39703 Roles, Themes: Fix "Add role" dialog width and position, in RTL mode (theme/clean)
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-08-19 13:13:04 +08:00
Dan Poltawski b31d9b8cbd Merge branch 'm25_MDL-37393' of github.com:danmarsden/moodle into MOODLE_25_STABLE 2013-08-19 12:57:50 +08:00
Jason Fowler 78dd49f5d0 MDL-30839 Accessibility, Forms - Improve accessibility or error messages 2013-08-19 09:55:43 +08:00
AMOS bot 1df739021c Automatically generated installer lang files 2013-08-19 00:42:36 +00:00
Sam Hemelryk 17aed88ed4 MDL-41106 cache: tidied up several elements
Conflicts:
	cache/stores/session/lib.php
2013-08-19 11:30:50 +12:00
Marina Glancy 4e9ccabd81 MDL-41106 Cleaning up expired elements in session cache store
- Always make sure the elements in cache are sorted so we need to remove only elements in the beginning of array
- Remove expired elements from session store to free memory
- Minor bug fixes

Conflicts:
	cache/stores/session/lib.php
	cache/stores/session/tests/session_test.php
2013-08-19 11:01:04 +12:00
Andrew Nicols 6e8edc5af0 MDL-41196 Unit Tests: Add a phpmailer message sink 2013-08-18 16:15:58 +01:00
Nadav Kavalerchik da552f01bb MDL-40447 Administration: Fix translation: "Profile" should be "Profile Fields" on advanced (more...) user filter form 2013-08-17 23:37:12 +03:00
Frederic Massart a0b3ed79e3 MDL-40877 core_text: Added UTF-8 safe strrchr method 2013-08-16 14:17:04 +08:00
Rossiani Wijaya 405ebd52d2 MDL-35930 filepicker filemanaer: make announcement on page change when selecting view files options 2013-08-16 12:09:54 +08:00
AMOS bot e432d94b3b Automatically generated installer lang files 2013-08-16 00:42:55 +00:00
Russell Smith a49e900fda MDL-40893 backup: cache question answers for performance
To constrain memory we only cache a single question's answers.
A quiz must display this many answers, so it will not result
in undue memory pressure.

We now match on the full answer text rather than the first 255
characters.  This removes the risk of matching questions with the
same start.
2013-08-16 10:06:34 +10:00
Sam Hemelryk a0933c542e MDL-41106 cache: several fixes for the session cache.
This issue makes several fixes for the session loader and the session store.
* maxsize argument now works for session caches.
* fixed performance hole when interation occurs frequently.
* fixed cache purge bug occuring when multiple caches are defined before being used.
* improved lastaccess handling.
2013-08-16 11:59:02 +12:00
Simon Coggins d16c91e919 MDL-39572: Fix sql_order_by_text() to use length argument correctly 2013-08-16 11:29:05 +12:00
Simon Coggins b9d40871f0 MDL-39572: Fix existing tests and add more to demonstrate issue with sql_order_by_text() 2013-08-16 11:29:05 +12:00
Yuliya Bozhko 2857077011 MDL-40162 badges: Image url breaks when slashargumets is not supported 2013-08-16 11:13:37 +12:00
Dan Marsden 5883b36a76 MDL-41144 enrol_flatfile: ignore deleted users. 2013-08-16 09:32:52 +12:00
Dan Marsden df47d2c38c MDL-37393 SCORM: Fix existing AICC scoes to use correct parent/child relationships 2013-08-16 09:29:31 +12:00
Matteo Scaramuccia 1ceee0d0d6 MDL-37393 SCORM: Fixed PHP Strict Standards errors with AICC packages 2013-08-16 09:29:31 +12:00
Jonathon Fowler 2cd5d3c03c MDL-32191 navigation: Add keys to module and block settings nav nodes 2013-08-16 09:18:46 +12:00
Tim Hunt 97d8cfa90a MDL-38203 multianswer qtype: feedback pop-up should be constrained.
So that, when there is a lot of feedback, it is all visible.
2013-08-15 14:16:24 +01:00
Tim Hunt a292ada723 MDL-39980 question engine: Attempt on last loses response files
When doing Each attempt builds on last, we need to copy any response
files into a draft file area, and then re-save them.

While writing the unit test for this, I had to deal with a todo in the
question engine so that questions with files in the response could be
unit-tested.

I also found an fixed a bug with qtype_essay_question::is_same_response
and fixed some notices in the existing essay/manual graded unit tests.
2013-08-15 12:56:22 +01:00
Marina Glancy 173839c0a6 MDL-36789 Quick course cache integrity check for deleted modules 2013-08-15 21:46:58 +10:00
Marina Glancy d69129045f MDL-40830 Clear course cache in mod_assign generator 2013-08-15 21:45:03 +10:00
Tim Hunt 3a5f219636 MDL-41162 quiz view page: invalid HTML.
We were sometimes outputting nested p tags. Change the outer one to a
div.
2013-08-15 12:41:27 +01:00
Tim Hunt a369215799 MDL-41093 qtype match: unique index upgrade problem.
Eliminate duplicate rows before we try to add a unique index. We
arbitrarily keep the duplicate row with the lowest id.
2013-08-15 11:58:57 +01:00
Tim Hunt 42f6e9def5 MDL-41036 Question category info should use HTML editor
This is a minimal fix. All this code could do with a clean-up, but at
the moment, it works, so I am not going to touch it.
2013-08-15 11:58:35 +01:00
Tim Hunt e614f12797 MDL-40896 Add missing question edit CSS to bootstrapbase. 2013-08-15 11:58:12 +01:00
Henning Bostelmann a15ad2be17 MDL-27595 backup: allow course import with warnings
Proceed with import if warnings are found, but display the warnings afterwards
2013-08-15 11:20:38 +01:00
Dan Poltawski 661777c503 weekly release 2.5.1+ 2013-08-15 16:42:18 +08:00
Dan Poltawski 2571672496 Merge branch 'install_25_STABLE' of git://git.moodle.org/moodle-install into MOODLE_25_STABLE 2013-08-15 16:41:41 +08:00
Rossiani Wijaya 3d29241619 MDL-41200 filepicker: change header string to select.
limit the length for header, so it fits nicely in mobile devices
2013-08-15 10:58:56 +08:00
AMOS bot f2c29f9b97 Automatically generated installer lang files 2013-08-15 00:54:43 +00:00
Dan Poltawski 0d8d0a34e7 Merge branch 'MDL-39507_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-08-14 21:57:43 +08:00
Dan Poltawski 760cb9ee99 MDL-41191 enrol: unit tests for enrol_get_shared_courses 2013-08-14 21:41:38 +08:00
Dan Poltawski 0f96a45b28 MDL-41191 forum: unit tests for forum_get_courses_user_posted_in 2013-08-14 21:39:13 +08:00
Tim Hunt 766a9a9d8f MDL-39507 Question HTML export: fix image handling.
Some code got committed to stable branches that relied on a new API that
was in master only. This fixes it to use the old API.
2013-08-14 11:02:35 +01:00
Dan Poltawski ad2fc9d060 MDL-41157 calendar: improve calendar_get_course_cached
The function get_course() introduced in 2.5.1 will use $COURSE and
$SITE to avoid an uncessary DB query, simplifying the logic of this
function and improving perf.
2013-08-14 11:06:17 +08:00
Dan Poltawski d0cd4de2dd MDL-41157 calendar: add unit tests for calendar_get_course_cached 2013-08-14 11:06:16 +08:00
Brian King ee5a68022f MDL-29004 Wiki: display images in printer-friendly view 2013-08-13 10:03:02 +02:00
Dan Poltawski a5a39298fa MDL-39507 qtype_essay: hacky fix for unit tests
This is just to get the tests passing for integration purposes. Tim
may want to do a robust fix and revert this.
2013-08-13 10:47:36 +08:00
Dan Poltawski 2d0f489759 Merge branch 'MDL-39507_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-08-13 09:53:09 +08:00
Sam Hemelryk 3f1c01de8d Merge branch 'MDL-41045-m25' of git://github.com/sammarshallou/moodle into MOODLE_25_STABLE 2013-08-13 10:19:16 +12:00
Sam Hemelryk 7ccc8e8b1c Merge branch 'MDL-39691_25' of git://github.com/jmvedrine/moodle into MOODLE_25_STABLE 2013-08-13 09:41:10 +12:00
Sam Hemelryk acea87e9b2 Merge branch 'MDL-41091_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-08-13 09:38:29 +12:00
Sam Hemelryk 05c04ad471 Merge branch 'wip-MDL-41114-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-08-13 09:31:43 +12:00
sam marshall f1cb34a17a MDL-41050 Progress bar: Width parameter does not work 2013-08-13 09:29:22 +12:00
Sam Hemelryk 6ae19630c5 Merge branch 'MDL-41033_m25' of git://github.com/rwijaya/moodle into MOODLE_25_STABLE 2013-08-13 09:22:44 +12:00
Sam Hemelryk 19f92cfd80 Merge branch 'MDL-40852_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-08-13 09:09:59 +12:00
Sam Hemelryk 8e086c697e Merge branch 'MDL-40996_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-08-13 09:08:04 +12:00
Sam Hemelryk 2f1dbeb9ba Merge branch 'MDL-30895-25' of https://github.com/mouneyrac/moodle into MOODLE_25_STABLE 2013-08-13 08:45:25 +12:00
Sam Hemelryk 499637cbc4 NOBUG: fixed whitespace 2013-08-13 08:41:37 +12:00
Sam Hemelryk 5c46191bd0 Merge branch 'MDL-35931-25' of git://github.com/phalacee/moodle into MOODLE_25_STABLE 2013-08-13 08:38:20 +12:00
Sam Hemelryk 55ad6e5841 Merge branch 'MDL-35919-25' of git://github.com/phalacee/moodle into MOODLE_25_STABLE 2013-08-13 08:35:34 +12:00
Sam Hemelryk 2f4aa72775 Merge branch 'MDL-35934_m25' of git://github.com/rwijaya/moodle into MOODLE_25_STABLE 2013-08-13 08:32:43 +12:00
Tim Hunt 1d428a476a MDL-39507 questions: fix pluginfile URLs before format_text.
This commit build's on Jean-Michel's work, tidying up a few lose ends.
2013-08-12 13:13:59 +01:00
Jean-Michel Vedrine 4cb50d230b MDL-39507 questions: fix pluginfile URLs before format_text. 2013-08-12 10:37:11 +01:00
Dan Poltawski c6a8d2c08c Merge branch 'MDL-27655_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-08-12 16:41:59 +08:00
Dan Poltawski 666d9bea6b Merge branch 'MDL-30001_25' of git://github.com/jmvedrine/moodle into MOODLE_25_STABLE 2013-08-12 16:13:20 +08:00
Jason Fowler 6cc0caebb5 MDL-35919 - Activity Chooser - Adding Aria attributes to improve accessibility 2013-08-12 13:23:32 +08:00
Marina Glancy 7e7e871915 MDL-41114 Avoid unnecessary retrieving of coursecat from DB
- course category depth can be estimated in make_categories_options() by the number of separators
2013-08-12 15:11:16 +10:00
Rossiani Wijaya b303f6663a MDL-35934 Filemanager: change the set attribute to use setAttribute() instead of YUI set(). 2013-08-12 12:46:38 +08:00
Kirill Astashov 5ec001f19f MDL-41122: Trim on RSS body to prevent Remote RSS block from failing on valid feeds 2013-08-12 12:41:02 +09:30
Marina Glancy fdec161716 MDL-41114 Speeding up course listings on large sites
- function coursecat::make_categories_list() does not use retrieved contexts and has to query them again.
- /course/manage.php uses field coursecat:: that was not fetched when retrieving the course category children.
2013-08-11 21:48:30 +10:00
Jean-Michel Vedrine 17c77ac500 MDL-39691 Lesson - Email graded essays not working 2013-08-11 08:12:22 +02:00
Jean-Michel Vedrine e87a512c55 MDL-30001 WEBCT Import does not work for 2.0 2013-08-11 07:59:56 +02:00
Petr Škoda 287f2af5a0 MDL-41112 fix theme and js caching info in config-dist.php 2013-08-10 23:46:47 +02:00
Rossiani Wijaya c50d563b63 MDL-41033 Filepicker: add ARIA attributes for selecting file in a modal 2013-08-09 10:55:41 +08:00
Rossiani Wijaya cf4a857e45 MDL-35934 Filemanager: update set focus attribute.
Also limit the display string for the dialog header to fit nicely on mobile devices
2013-08-09 10:53:08 +08:00
Rossiani Wijaya 80f8d50daa MDL-35934 Filemanager: add aria attributes for editing file/folder.
Add unique reference ids
2013-08-09 10:52:54 +08:00
Tim Hunt fa92bc270f MDL-41091 questions: fix get_all_submitted_qt_vars for unit testing. 2013-08-08 14:43:35 +01:00
Jerome Mouneyrac 0b121f1518 MDL-30895 switch from dl tag to table in the accessible chat 2013-08-08 17:48:24 +08:00
Tim Hunt 0d3a5c085f MDL-40996 quiz show user pic should also show name.
This was a regression introduced by MDL-20636 two years ago!
2013-08-08 09:57:58 +01:00
Tim Hunt 60238d1c24 MDL-31487 fix FEATURE_CONTROLS_GRADE_VISIBILITY for quiz.
This is a followup to MDL-18301. That fix missed the following points:

1. On the edit categories and items screens, all items had an eye-con to
control the visibility, even if the visibility was controlled by the
module.

2. Changing the visibility of a grade category change the visibility of
all items within it, even if the visibility was controlled by the
module.

3. The quiz ingored $cm->visible when controlling whether its grade item
was visible.
2013-08-08 09:56:55 +01:00
Tim Hunt e0323c2a2b MDL-27655 improve purge all caches.
If you click the link in the page footer, then it will reliably
redirect you back to the page you were on after purging the caches.

If you go to the purge all caches page in the admin menu, it shows you a
purge button, with no cancel button. Clicking the button purges the
caches and takes you back to the page with the button.
2013-08-08 09:56:33 +01:00
Sam Hemelryk cda44a165a weekly release 2.5.1+ 2013-08-08 16:24:57 +12:00
Sam Hemelryk 7ff9696fcb Merge branch 'install_25_STABLE' of git://git.moodle.org/moodle-install into MOODLE_25_STABLE 2013-08-08 16:19:30 +12:00
Jason Fowler f8243dc071 MDL-35931 Accessibility - adding focus change when repository is selected 2013-08-08 11:30:55 +08:00
sam marshall 99aa447550 MDL-41045 course_add_cm_to_section should not test for sections unless necessary 2013-08-07 17:18:41 +01:00
Frederic Massart e106ecb639 MDL-41071 core: plugininfo_mod caches in plugininfo_mod definition 2013-08-07 20:58:10 +08:00
Mark Nelson 23ad39f773 MDL-40662 block_course_overview: added addinstance capability string 2013-08-07 15:20:02 +12:00
AMOS bot e29655450d Automatically generated installer lang files 2013-08-07 00:43:00 +00:00
Sam Hemelryk 7478d2534b Merge branch 'MDL-40086-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-08-07 10:37:34 +12:00
Frederic Massart 03589368a3 MDL-40086 file: Correct ordering of subdirectories
Thanks to Mohamed Alsharaf for the proposed solution.
2013-08-06 13:55:25 +08:00
Sam Hemelryk 3267d96132 Merge branch 'MDL-34989-25' of git://github.com/damyon/moodle into MOODLE_25_STABLE 2013-08-06 17:51:17 +12:00
David Monllao 87b252defd MDL-40852 behat: Wrong URLs detection 2013-08-06 13:43:37 +08:00
Ruslan Kabalin f327285ab3 MDL-40947: Fix segmentation fault issue in get_fast_modinfo. 2013-08-06 17:42:08 +12:00
Sam Hemelryk aca4d181b9 Merge branch 'wip-mdl-40469-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-08-06 17:36:08 +12:00
Sam Hemelryk 0b1ee3b871 Merge branch 'MDL-40420_25' of https://github.com/prateeksachan/moodle into MOODLE_25_STABLE 2013-08-06 17:01:55 +12:00
Sam Hemelryk ce3fe87f91 Merge branch 'w32_MDL-41002_m25_enroltypo' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-08-06 16:55:31 +12:00
Marina Glancy 71699c5a81 Merge branch 'MDL-31226-MOODLE_25_STABLE' of https://github.com/lucisgit/moodle into MOODLE_25_STABLE 2013-08-06 14:39:26 +10:00
Mark Nelson ea6b3ac108 MDL-27953 auth: documented the newly introduced function can_be_manually_set() in upgrade.txt 2013-08-06 15:47:36 +12:00
Mark Nielsen 01af794851 MDL-40870: Icon alt text in External Tool admin settings all read Accept 2013-08-06 14:48:58 +12:00
Sam Hemelryk d3751ed482 Merge branch 'MDL-40662_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-08-06 14:39:29 +12:00
AMOS bot 866fa55703 Automatically generated installer lang files 2013-08-06 00:42:17 +00:00
Mark Nielsen e1ff960c94 MDL-39090: Duplicate parameters in LTI launches
Removed endpoint query string params from body
to prevent param duplication.
2013-08-06 10:24:44 +12:00
Sam Hemelryk a2f561b6a7 Merge branch 'MDL-27953_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-08-06 10:10:46 +12:00
Sam Hemelryk eeb784d41d Merge branch 'w32_MDL-40889_m25_jsminify' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-08-06 09:55:10 +12:00
Marina Glancy 0b1723fd57 Merge branch 'MDL-36011-25' of git://github.com/damyon/moodle into MOODLE_25_STABLE 2013-08-05 17:16:47 +10:00
Marina Glancy 25dcfa6f54 Merge branch 'MDL-30852-25' of git://github.com/damyon/moodle into MOODLE_25_STABLE 2013-08-05 13:52:38 +10:00
Shane Elliott c794ad68c8 MDL-40684 Fix conditional field name for custom user fields 2013-08-05 15:51:34 +12:00
Sam Hemelryk 85180a0fa9 Merge branch 'MDL-40937_assignment_history_25' of git://github.com/davosmith/moodle into MOODLE_25_STABLE 2013-08-05 15:46:44 +12:00
Sam Hemelryk 737542c674 Merge branch 'MDL-38758_m25' of https://github.com/markn86/moodle into MOODLE_25_STABLE 2013-08-05 15:37:14 +12:00
Sam Hemelryk f16972e717 Merge branch 'MDL-35922-25' of git://github.com/phalacee/moodle into MOODLE_25_STABLE 2013-08-05 15:32:12 +12:00
Damyon Wiese 93d1a6147b MDL-30852 grade report: More coding guideline cleanups. 2013-08-05 11:24:00 +08:00
Damyon Wiese ff8e3b0739 MDL-30852 grade: Coding style fix for user report. 2013-08-05 11:24:00 +08:00
Steve Bader 95ad1cee12 MDL-30852 grade report: Add aria attributes
Converted to git branch by Damyon
2013-08-05 11:24:00 +08:00
Marina Glancy a4bd80565f Merge branch 'MDL-40825_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-08-05 13:16:34 +10:00
Sam Hemelryk 9f15b383d1 Merge branch 'MDL-35927_m25' of git://github.com/rwijaya/moodle into MOODLE_25_STABLE 2013-08-05 14:38:38 +12:00
Marina Glancy 153cb0b4c3 Merge branch 'MDL-40320-m25' of git://github.com/sammarshallou/moodle into MOODLE_25_STABLE 2013-08-05 12:31:53 +10:00
Marina Glancy 2adfb6528e Merge branch 'MDL-35981-25' of git://github.com/damyon/moodle into MOODLE_25_STABLE 2013-08-05 12:20:40 +10:00
Damyon Wiese 36b58250b7 MDL-35981 comments: Fix for keyboard control of "add a comment" 2013-08-05 09:50:44 +08:00
Damyon Wiese 25379e44ad MDL-35981 comments: Remove confirm step from behat delete comments. 2013-08-05 09:50:44 +08:00
Damyon Wiese 38866c905a MDL-35981 comments: Add comment about keycodes for space and enter. 2013-08-05 09:50:44 +08:00
Damyon Wiese 32c72ccb37 MDL-35981 comments: Make delete comment keyboard accessible. 2013-08-05 09:50:43 +08:00
Sam Hemelryk 03c3e7c4e8 Merge branch 'wip-MDL-34785-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-08-05 13:36:43 +12:00
Marina Glancy e8a943e361 Merge branch 'wip-mdl-40933-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-08-05 10:49:32 +10:00
Marina Glancy b4750e06c9 MDL-34785 performance improvement with big list of courses 2013-08-05 10:14:34 +10:00
Petr Škoda 70e746f43e MDL-41002 fix typo causing fatal error on other users page
Credit goes to Bernhard Brandstetter, thanks!
2013-08-04 15:01:43 +02:00
Ruslan Kabalin 6c16201632 MDL-31226: quiz: Fix message for attempts built on previous.
At the moment, when attempt is built on the last one, "not yet answered"
message is shown, which confuses many people. This patch modifies the state to
"complete" for attempt based on previous and modifies the output string.

Many thanks to Tim Hunt for guiding me through quiz infrastructure and some code
suggestions.
2013-08-02 16:55:59 +01:00
Petr Škoda 3dd51921de MDL-40889 prevent 304 when minimising JS 2013-08-02 16:29:12 +02:00
Damyon Wiese b0998d5099 MDL-36011 tablelib: Make column headers expand/collapse links accessible.
Conflicts:

	theme/base/style/core.css
	theme/bootstrapbase/style/moodle.css
2013-08-02 11:29:45 +08:00
AMOS bot df84da67ec Automatically generated installer lang files 2013-08-02 00:38:31 +00:00
Sam Hemelryk a9657adb0f weekly release 2.5.1+ 2013-08-02 08:24:49 +12:00
Sam Hemelryk 1496e4990f Merge branch 'install_25_STABLE' of git://git.moodle.org/moodle-install into MOODLE_25_STABLE 2013-08-02 08:12:26 +12:00
sam marshall c358c8a2c0 MDL-40320 Course page: Text greyed when conditional activity available 2013-08-01 14:13:43 +01:00
Rossiani Wijaya 239fd1544f MDL-35927 filepicker: add aria attribute to display modal error 2013-08-01 15:40:49 +08:00
Mark Nelson 4a546bf04c MDL-40662 block_course_overview: added addinstance capability to remove debugging message due to system context being used on the 'Default My home page' 2013-08-01 12:53:15 +08:00
Rajesh Taneja bbf727c3a8 MDL-40469 Gradebook: Fixed setType warning while exporting gradebook with publishing set 2013-08-01 10:33:51 +08:00
Jason Fowler 219d7ec5c0 MDL-35922 - Adding aria attributes to create-folder modal 2013-07-31 16:42:01 +08:00
Davo Smith 42e54cffad MDL-40937 mod_assign - remove debugging code from 'previous submissions' javascript, that was breaking in IE8/IE9 2013-07-30 11:37:34 +01:00
Rajesh Taneja dcb5678e99 MDL-40933 Administration: Added 'is after' and 'is before' to date filter 2013-07-30 16:15:06 +08:00
Nadav Kavalerchik a36788687a MDL-40902 - Align breadcrumbs to the right in RTL mode (theme/clean, bootstrapbase)
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-07-30 10:36:25 +12:00
Sam Hemelryk cecc076eb7 Merge branch 'MDL-40746_25' of git://github.com/grabs/moodle into MOODLE_25_STABLE 2013-07-30 09:40:28 +12:00
Frederic Massart 2d325dfcf8 MDL-40615 Repository: Updated Amazon S3 library
Fixed insecure use of CURLOPT_SSL_VERIFYHOST
2013-07-30 09:04:58 +12:00
Sam Hemelryk a38830a07b Merge branch 'MDL-39461_25' of https://github.com/totara/openbadges into MOODLE_25_STABLE 2013-07-30 08:59:26 +12:00
Mark Nelson db69373d40 MDL-38758 mod_forum: fixed issue where pass by reference removal caused an undefined variable error 2013-07-29 19:12:38 +08:00
Mark Nelson 8a868abe22 MDL-27953 auth: allowed the LDAP plugin to be manually assigned to uploaded users 2013-07-29 17:11:13 +08:00
Dan Poltawski ff8d9b59ef Merge branch 'MDL-40867_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-29 15:24:54 +08:00
Charles Fulton 9fc858e93e MDL-40323 report_log: fix strict standards error 2013-07-29 14:00:34 +08:00
Dan Poltawski ae19a843bc Merge branch 'MDL-40857_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-29 13:56:46 +08:00
Dan Poltawski 5279ff0725 MDL-40775 feeback: remove uncessary header 2013-07-29 13:31:17 +08:00
Dan Poltawski c79efe260b Merge branch 'MDL-40775_25' of git://github.com/grabs/moodle into MOODLE_25_STABLE 2013-07-29 13:30:35 +08:00
Dan Poltawski 673a456343 Merge branch 'wip-MDL-29731-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-07-29 13:21:12 +08:00
Dan Poltawski 2018e8f12a Merge branch 'MDL-36399_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-29 12:40:12 +08:00
Dan Poltawski 3d4cb04ded Merge branch 'MDL-40863_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-29 10:09:53 +08:00
Damyon Wiese aea34768be MDL-34989 assign: Do not add a param to grading_disabled - cannot be backported.
Conflicts:

	mod/assign/locallib.php
2013-07-29 09:57:18 +08:00
Ashley Holman fae11d2ef1 MDL-34989 assign: Allow students to submit when grade is overriden
Also inform teachers when grading is disabled due to gradebook lock/override.
2013-07-29 09:56:47 +08:00
Sam Hemelryk 5fb1fad943 Merge branch 'MDL-40878_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-29 12:54:16 +12:00
Sam Hemelryk 7b3a806741 Merge branch 'w31_MDL-40891_m25_mkdirrace' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-07-29 11:52:35 +12:00
Sam Hemelryk 8ba4fd3b9a Merge branch 'MDL-40727-25' of git://github.com/damyon/moodle into MOODLE_25_STABLE 2013-07-29 11:49:41 +12:00
Sam Hemelryk fa386d3e36 Merge branch 'MDL-40854_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-29 11:01:45 +12:00
Mark Nielsen 9fe0281217 MDL-40005: LTI module uses Apache specific function for retrieving request headers 2013-07-29 10:54:10 +12:00
AMOS bot f0592ad3a3 Automatically generated installer lang files 2013-07-28 00:42:29 +00:00
AMOS bot 0147686fc7 Merge branch 'MOODLE_25_STABLE' into install_25_STABLE 2013-07-27 00:43:10 +00:00
Petr Škoda f4a4e5e8e6 MDL-40891 prevent exceptions when creating directories in file store
Even if cache creation fails moodle should continue working.
2013-07-26 20:30:41 +02:00
Petr Škoda 7a8ef1453e MDL-40891 work around make_writable_directory() race condition
You will still get a "PHP Warning:  mkdir(): File exists" but that should not cause any problems on production sites.
2013-07-26 20:29:55 +02:00
Andreas Grabs d460eb563e MDL-40775 mod_feedback - Undefined variable in feedback activity 2013-07-26 19:42:28 +02:00
Andreas Grabs 61925ed61c MDL-40746 mod_feedback - Feedback forms display oddly in Clean theme 2013-07-26 19:42:24 +02:00
Tim Hunt 6eb9e11615 MDL-40854 fix mod/...:view capabilities
Prior to the fix, if you did not have a capability like mod/page:view,
then you woulds still see the link to the Page activity in the course
section, but when you clicked on it, you would run into a
require_capability error.

It is a principle that we never show users a link to a page they are not
allowed to access, therefore, when users do not have mod/...:view, they
should not see the link on the course page.

This patch implements this in the cm_info class, in a similar way to how
access restrictions by groups works.

It does not assume that the mod/...:view capability exists. If the
capability does not exist, then users are not prevented from seeing the
link.
2013-07-26 11:51:25 +01:00
Tim Hunt b5d9f07ab5 MDL-40857 External tool: fix incorrect moodle_url usage. 2013-07-26 11:41:36 +01:00
Tim Hunt 5ed6c6a5a1 MDL-40857 External tool (LTI) capabilitiy names confusing.
I have improved the names in the language file so that they actually say
what they do (based on my reading of the code). I have also added
comments to access.php explaining each capability.

I have corrected a few of the RISK in access.php which were wrong.

I have changed a couple of the archetypes so that guests cannot launch
LTI activities, and editing teachers cannot do editing things.
2013-07-26 11:41:34 +01:00
David Monllao f1c1230a77 MDL-40825 behat: Giving time to display the ajax response 2013-07-26 12:38:56 +02:00
Tim Hunt 521932c6d8 MDL-40867 fix misleading PHPdocs for _get_coursemodule_info 2013-07-26 10:17:33 +01:00
Tim Hunt 364b991369 MDL-40867 External tools should launch pop-ups from the course page
Without this fix, if an LTI tool is set to open in a pop-up, then
clicking the link on the course page opens another almost blank page,
which then tries to open the pop-up, which is almost invariably caught
by your pop-up blocker.

With this fix, clicking the link on the course page opens the pop-up
directly, like for pop-up resources.
2013-07-26 10:17:13 +01:00
Tim Hunt 944e90bd6d MDL-40863 feedback and LTI mods need get_extra_capabilities fn
Since moodle/site:accessallgroups is relevant to how them.
2013-07-26 10:16:54 +01:00
Tim Hunt 18dde90e33 MDL-36399 LTI editing tool config breaks on Oracle.
Note that this fix will fail if the tool URL is longer than 1333
characters.
2013-07-26 10:16:11 +01:00
Damyon Wiese f171a8c06e weekly release 2.5.1+ 2013-07-26 11:29:27 +08:00
AMOS bot c0aa2a2c57 Automatically generated installer lang files 2013-07-25 00:40:39 +00:00
Marina Glancy 8127fbe1e1 MDL-29731 Bugs in recent activity when using separate groups 2013-07-24 21:50:02 +10:00
Damyon Wiese 025b889981 MDL-40727 Cache: Fix file cache store on windows. 2013-07-24 17:08:36 +08:00
Jason Fowler 304e27ed5f MDL-39748 - Grading - Fixing the increasing height regression
Conflicts:

	theme/bootstrapbase/style/moodle.css
2013-07-24 15:25:32 +08:00
Sam Hemelryk 7de495d5c6 Merge branch 'wip-MDL-37869-stable25' of git://github.com/phalacee/moodle into MOODLE_25_STABLE 2013-07-24 11:27:58 +12:00
Sam Hemelryk 5590ac2aff Merge branch 'MDL-40315_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-07-24 11:14:01 +12:00
Nadav Kavalerchik cf1e9e9ae3 MDL-39704 - Properly align and widen the chat bubbles in mod/chat, when in RTL mode 2013-07-23 23:23:31 +02:00
Nadav Kavalerchik 614a5201ad MDL-40544 - Right align all tables (system wide) in RTL mode (theme/clean , bootstrapbase)
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-07-23 22:40:26 +02:00
Nadav Kavalerchik e992ee44d4 MDL-40589 - Theme/CLEAN - Flip YUI3 tree item icon in RTL mode in folder resource
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-07-23 22:34:55 +02:00
Nadav Kavalerchik 4e0a41305d MDL-40189 - Theme/Clean - Right align form labels and left align form input elements on admin pages, system wide (when in RTL mode)
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-07-23 22:30:10 +02:00
Nadav Kavalerchik 018904a185 MDL-40071 - Right align category titles and usernames in gradebook (theme/clean, bootstrapbase)
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-07-23 22:15:18 +02:00
Eloy Lafuente (stronk7) 1bb7b65496 Merge branch 'w30_MDL-40679_m25_zlib' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-07-23 18:21:09 +02:00
Eloy Lafuente (stronk7) d03c0ef72d Merge branch 'MDL-40816_m25' of git://github.com/markn86/moodle into MOODLE_25_STABLE 2013-07-23 18:19:32 +02:00
Eloy Lafuente (stronk7) c8dd490281 Merge branch 'MDL-40785_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-23 18:01:19 +02:00
David Monllao 374d9f98d6 MDL-40595 tool_behat: Referencing init.php script
Almost everybody will use init.php instead of
running manually the composer commands and util.php
to install and enable the test environment.
2013-07-23 17:17:36 +02:00
Eloy Lafuente (stronk7) e681d0ed58 MDL-40700 tests: skip if there is not instance
Various reasons can lead to the cache stores not being available
(missing extension, configuration...). Under those situations
the test must be skipped because for sure it will break if
we continue.
2013-07-23 17:02:36 +02:00
Eloy Lafuente (stronk7) 52affa8a9a Merge branch 'wip-MDL-40700-m25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-07-23 13:58:30 +02:00
Eloy Lafuente (stronk7) e988493e68 Merge branch 'wip-MDL-40763-m25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-07-23 13:19:54 +02:00
Nadav Kavalerchik e88a456eb3 MDL-40082 - Several UI fixes for question chooser dialog, when in RTL/LTR modes (theme/clean, bootstrapbase)
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-07-23 12:18:03 +02:00
Dan Poltawski c38a4b6f04 Merge branch 'MDL-20609_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-23 16:45:22 +08:00
Dan Poltawski 4353b3d830 Merge branch 'MDL-40480_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-23 16:38:17 +08:00
Damyon Wiese e2bb8c1bbd Merge branch 'MDL-40295_m25' of git://github.com/rwijaya/moodle into MOODLE_25_STABLE 2013-07-23 15:54:10 +08:00
Jason Fowler bf3371458d MDL-39748 - Grading Methods - Fixing input field widths for Rubrics
Conflicts:

	theme/bootstrapbase/style/moodle.css
2013-07-23 14:32:58 +08:00
Dan Poltawski 36c3919916 MDL-40585 fix trailing whitespace 2013-07-23 13:34:33 +08:00
Dan Poltawski a8369f6a96 Merge branch 'MDL-40585_25' of git://github.com/mr-russ/moodle into MOODLE_25_STABLE 2013-07-23 13:34:29 +08:00
Dan Poltawski fdcad4d5f3 Merge branch 'MDL-40584_25' of https://github.com/mr-russ/moodle into MOODLE_25_STABLE 2013-07-23 12:38:27 +08:00
Dan Poltawski 1f506acf58 Merge branch 'MDL-40793_25' of https://github.com/mr-russ/moodle into MOODLE_25_STABLE 2013-07-23 10:42:07 +08:00
Sam Hemelryk 63ddd040c0 Merge branch 'MDL-40680-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-07-23 14:13:59 +12:00
Eloy Lafuente (stronk7) 932ad50a6e Merge branch 'wip-MDL-38707-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-07-23 03:52:23 +02:00
Jason Fowler f55ac904fa MDL-37869 - Course - Removing the ALT text from activity and resource icons as it duplicated the accesshide text 2013-07-23 08:57:44 +08:00
AMOS bot be2a25c80f Automatically generated installer lang files 2013-07-23 00:39:23 +00:00
Eloy Lafuente (stronk7) 2f956f40b6 Merge branch 'MDL-40123_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-07-23 01:09:20 +02:00
Eloy Lafuente (stronk7) e024b7130a Merge branch 'MDL-39635_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-07-23 00:45:20 +02:00
Eloy Lafuente (stronk7) ed3a28dcec Merge branch 'wip-MDL-33563-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-07-22 22:36:33 +02:00
Yuliya Bozhko aee7b7544c MDL-39461 badges: Fix cURL expectation failed error when trying to connect to backpack 2013-07-23 08:19:17 +12:00
Eloy Lafuente (stronk7) 55be97fba4 Merge branch 'MDL-40626-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-07-22 17:41:01 +02:00
Mark Nelson e94b6c678d MDL-40816 backup: code cleanup on the manage backups form 2013-07-22 18:18:12 +08:00
Mark Nelson ed31b623bc MDL-40816 backup: added missing setType calls to the manage backups form 2013-07-22 18:18:03 +08:00
Dan Poltawski 6ca8973eca Merge branch 'w30_MDL-38867_m25_gspell' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-07-22 17:00:56 +08:00
Damyon Wiese 690b65ca56 MDL-40260 Course overview: code tidy for previous commit
Moving this check inside the following if makes it clear which code
branch it applies to.
2013-07-22 16:15:32 +08:00
Damyon Wiese 1ab82c6775 Merge branch 'm25_MDL-40260' of git://github.com/danmarsden/moodle into MOODLE_25_STABLE 2013-07-22 16:15:05 +08:00
Damyon Wiese d99508f25b Merge branch 'wip-MDL-40174-m25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-07-22 16:02:47 +08:00
Dan Poltawski 114b8bed28 Merge branch 'MDL-38837_25' of https://github.com/totara/openbadges into MOODLE_25_STABLE 2013-07-22 15:02:21 +08:00
Dan Poltawski 4896a0ba25 Merge branch 'MDL-39441_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-07-22 10:46:47 +08:00
Dan Poltawski d46d40d407 Merge branch 'wip-MDL-37333_M25' of git://github.com/gjb2048/moodle into MOODLE_25_STABLE 2013-07-22 10:31:47 +08:00
Russell Smith 874d5a4f85 MDL-40793 profiling: Allow multiple reference runs in display 2013-07-22 12:15:02 +10:00
Sam Hemelryk 5b88c03311 MDL-40174 navigation: don't remove active root nodes without children 2013-07-22 10:49:05 +12:00
Sam Hemelryk 07e26360b8 MDL-40700 cache: memcache and memcached stores now allow alphanumext prefixes 2013-07-22 10:41:42 +12:00
Chris Wharton fe6eeced0b MDL-40700 cache: Validate memcache key prefix field 2013-07-22 10:41:42 +12:00
Sam Hemelryk 497d70c3ec MDL-40700 cache: fixed cache store unit tests 2013-07-22 10:40:56 +12:00
Petr Škoda 5d7faafa0f MDL-40679 mark zlib extension as recommended 2013-07-20 21:20:06 +02:00
AMOS bot dcccd8e2bb Automatically generated installer lang files 2013-07-20 00:44:26 +00:00
Tim Hunt d882d06cea MDL-40785 question instances report: ignore subquestions
We should not count subquestions of cloze questions (parent != 0) but we
do want to count random questions (parent = id).
2013-07-19 15:16:53 +01:00
Tim Hunt 9a62c01edc MDL-40480 tablelib: specify charset in XHMTL downloads.
Thanks to Jürgen Zimmer for the suggestion.
2013-07-19 11:46:35 +01:00
Tim Hunt 58c44e5c20 MDL-20609 quiz tables: improve layout for long cell contents.
By allowing more wrapping.
2013-07-19 11:46:18 +01:00
David Monllao 2ab6b4d43d MDL-40123 behat: Show all of form's elements changes.
* Avoid waiting until Show more... links appears if we
  already waited.
* Use collapse/expand button rather than clicking on
  each of the form's fieldsets.
2013-07-19 10:36:29 +02:00
David Monllao 55e9a99c18 MDL-39635 behat: XPath cleanups
- Escaping steps arguments redirected to other steps
- Adding normalized-space() in all contains() assertions
- General xpaths review
- Convering provided xpath text strings to xpath literals
  to avoid problems with arguments containing both single
  quotes and double quotes
2013-07-19 10:35:54 +02:00
David Monllao 15c461d34d MDL-39635 behat: Replacing hardcoded language strings
Using get_string() instead.
2013-07-19 10:07:31 +02:00
David Monllao a4fad25c53 MDL-39635 behat: Fixing line breaks
Not supported by Windows OSs.
2013-07-19 10:07:31 +02:00
Petr Škoda 6139b462d7 MDL-38867 remove Google spell checking option 2013-07-19 09:32:11 +02:00
Marina Glancy 63e1765c91 MDL-38707 Display module name when the folder is displayed inline 2013-07-19 15:53:13 +10:00
Marina Glancy 16307c1428 MDL-33563 Version bump for grading methods API change 2013-07-19 15:15:21 +10:00
Marina Glancy f2fe655aeb MDL-33563 Grading methods allow decimal grades 2013-07-19 15:13:58 +10:00
Tim Lock 448fc8ab1a MDL-40626 gradebook: Prevent incorrect override with multiline feedback
The quick grading option doesn't allow mutliline editing.
2013-07-19 12:01:37 +08:00
Damyon Wiese 7aed82f15d weekly release 2.5.1+ 2013-07-19 09:51:35 +08:00
Damyon Wiese 4217cea494 Merge branch 'install_25_STABLE' of git://git.moodle.cz/moodle-install into MOODLE_25_STABLE 2013-07-19 09:25:04 +08:00
David Monllao c5a0598bf9 MDL-40315 behat: Performance improvement
We look for exceptions after each step, this patch
includes a pre-checking query to avoid multiple queries
for each step when most of the time they are not necessary.
2013-07-18 11:22:57 +02:00
Damyon Wiese 19f2b2a41f MDL-35851 lesson: Handle importing questions into an empty lesson.
Also - make sure the page we are updating belongs to the lesson.
2013-07-18 16:48:09 +08:00
Rossiani Wijaya 00c9d81bb7 MDL-40295 wiki mod: fix set_url() error for printer friendly page.
Additionally, fix wiki pagelayout for printing
2013-07-18 10:57:11 +08:00
Yuliya Bozhko 2e64d85668 MDL-38837 badges: Check for http or https in badges backpack support 2013-07-18 13:41:33 +12:00
Gareth J Barnard ffadd1242a MDL-37333 theme: Fix 'Clear theme caches' redirect. 2013-07-17 17:39:33 +01:00
Damyon Wiese 2bdf958208 MDL-35851 Lesson: Check/fix the page order every time the pages are loaded 2013-07-17 13:04:32 +08:00
Marina Glancy d11977ebc9 Merge branch 'MDL-40701-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-07-17 12:46:26 +10:00
Dan Poltawski 947933e62b MDL-40701 mod_assignment: fix refresh events
It was getting the cm event with the wrong id and calling
deprecated functions
2013-07-17 10:31:22 +08:00
prateeksachan 7c7563c46a MDL-40420: timemodified field update when lesson_page is updated 2013-07-17 07:24:06 +05:30
AMOS bot d87db3bc5e Automatically generated installer lang files 2013-07-17 00:42:26 +00:00
Eloy Lafuente (stronk7) b5d967cb1d Merge branch 'MDL-40652_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE 2013-07-17 00:41:19 +02:00
Eloy Lafuente (stronk7) c59f83cec2 Merge branch 'w29_MDL-40611_m25_accesslibtest' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-07-17 00:32:37 +02:00
Eloy Lafuente (stronk7) cbd227ffae Merge branch 'MDL-40536-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-07-17 00:26:43 +02:00
Eloy Lafuente (stronk7) bc27ec579e Merge branch 'MDL-40690_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-07-17 00:17:43 +02:00
Eloy Lafuente (stronk7) 980746ce63 Merge branch 'MDL-38857_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-07-16 22:02:23 +02:00
Eloy Lafuente (stronk7) 2ff8b13dee Merge branch 'w29_MDL-40423_m25_localsubdir' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-07-16 21:55:55 +02:00
David Monllao 623544086d MDL-40690 behat: Ignore StaleElementReference exception
Is another of the exceptions thrown by
Selenium when it tries to interact with
an element that disappeared from the DOM,
in happens randomly when redirecting the
user to another page with a wait period to
show him/her a message.
2013-07-16 16:45:59 +02:00
Damyon Wiese 9dafb1ba89 Merge branch 'wip-MDL-40621-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-07-16 21:30:29 +08:00
Damyon Wiese e1982a25cd Merge branch 'wip-MDL-39299-stable25' of git://github.com/phalacee/moodle into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-07-16 21:14:45 +08:00
Jason Fowler 845198b7d7 MDL-39299 - Course - Correcting some rendering problems in bootstrapbase
Conflicts:

	theme/bootstrapbase/style/moodle.css
2013-07-16 15:48:10 +08:00
Eloy Lafuente (stronk7) aeee792c86 Merge branch 'MDL-40555-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE
Conflicts:
	cache/stores/static/lib.php
2013-07-16 09:46:27 +02:00
Marina Glancy 996d775457 Merge branch 'MDL-35851-25' of git://github.com/damyon/moodle into MOODLE_25_STABLE 2013-07-16 16:11:29 +10:00
Damyon Wiese 8fedf20b63 MDL-35851 lesson: removed expensive upgrade step.
Just deal with the bad data when displaying the lesson instead.

Conflicts:

	mod/lesson/db/upgrade.php
2013-07-16 14:07:01 +08:00
Damyon Wiese e811b5fbe1 Merge branch 'MDL-40195_25' of git://github.com/aolley/moodle into MOODLE_25_STABLE 2013-07-16 13:29:38 +08:00
Marina Glancy 3e704e0d7f MDL-39812 recompile less for bootstrapbase 2013-07-16 15:24:55 +10:00
Marina Glancy da4a51d096 Merge branch 'MDL-39812_bootstrapbase_m25' of git://github.com/rwijaya/moodle into MOODLE_25_STABLE 2013-07-16 14:33:24 +10:00
Damyon Wiese f352c87f67 Merge branch 'w29_MDL-40558_m25_guestdelete' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-07-16 11:29:14 +08:00
Matt Debus b66e88a4d1 MDL-40524: mod_wiki: Display comments in order 2013-07-16 11:25:41 +08:00
Damyon Wiese edb2b3c8a0 Merge branch 'MDL-40538_25' of https://github.com/mr-russ/moodle into MOODLE_25_STABLE 2013-07-16 10:25:14 +08:00
Rossiani Wijaya 5247f16b14 MDL-35851 Lesson module: fix page order id for import questions. Add upgrade script to fix lesson pages corrupted links 2013-07-16 10:02:19 +08:00
Dan Poltawski 82b32059b5 MDL-40680 store_memcached: fix serialiser options
* Use correct lang string for SERIALIZER_IGBINARY
* Use PARAM_INT for the parameter
2013-07-16 09:38:59 +08:00
Sam Hemelryk b9082c4b0a MDL-40555 cache: implemented unit tests for default search functionality 2013-07-16 08:33:30 +08:00
Frederic Massart 59ba272aa2 MDL-40555 cache: Static store is searchable 2013-07-16 08:33:30 +08:00
Eloy Lafuente (stronk7) ed405efb4c Merge branch 'w29_MDL-40571_m25_adminblocks' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-07-16 00:26:51 +02:00
Russell Smith d51121efbe MDL-40584 backup: Query db once per category in precheck
The cache is function local and testing against a large database
indicates 10k questions is a large category.  Restore already
uses MEMORY_EXTRA and that will have enough space for the couple
of megabtyes a local sql hash will introduce.
2013-07-16 08:03:59 +10:00
Eloy Lafuente (stronk7) 40aa1f4d88 Merge branch 'MDL-40412_m25' of git://github.com/merrill-oakland/moodle into MOODLE_25_STABLE 2013-07-15 22:08:09 +02:00
Eloy Lafuente (stronk7) ad92b2f1ae Merge branch 'wip-MDL-38747-MOODLE_25_STABLE' of https://github.com/satrun77/moodle into MOODLE_25_STABLE 2013-07-15 17:06:31 +02:00
David Monllao fb50800b16 MDL-39441 behat: Restrict config.php allowed settings 2013-07-15 11:26:12 +02:00
Russell Smith 619fc0cd3c MDL-40585 backup: cache XML parent paths
For $this->groupedpaths, using a key is faster as there is
no need to do in_array searches.

Parent cache allows dirname calls to be substantially reduced.
2048 was chosen as a cache size as this class operates on chunks
of the restore at a time, 8k questions produces a parent cache of
about 500 paths and uses 300K of memory.  Scaling up to 2048 will
use about 1.2M of RAM for really large restores.  This is acceptable
for the 48% function call reduction and the 10% runtime improvement
seen.
2013-07-15 19:23:00 +10:00
Damyon Wiese 4e0dd403e7 MDL-39563: Change to use $CFG consistently 2013-07-15 15:04:58 +08:00
Juan Leyva 2500cd01b1 MDL-39563 Fixing mobilecssurl is not being returned in WebService, phpunit tests
Conflicts:

	webservice/externallib.php
2013-07-15 15:04:24 +08:00
Marina Glancy 2500fc57d0 Merge branch 'MDL-40633_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-15 14:44:22 +10:00
Marina Glancy eccf42d9d9 Merge branch 'wip-MDL-39062-m25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-07-15 12:42:57 +10:00
Daniel Myers c43b7393f8 MDL-40260 block_course_overview: prevent MNET courses from being dimmed 2013-07-15 13:55:28 +12:00
AMOS bot eda6f4d463 Automatically generated installer lang files 2013-07-15 00:44:25 +00:00
Sam Hemelryk 13a363e534 MDL-39062 cache: version bump to update definitions 2013-07-15 12:01:38 +12:00
Sam Hemelryk 72433ecb43 MDL-39062 cache: persist keys now set properly 2013-07-15 12:01:08 +12:00
Mary Evans 7836d4c93e MDL-40652 Calendar: Changed pagelayout from 'standard' to 'base' in calendar/export.php. 2013-07-14 15:15:35 +01:00
Marina Glancy 046804ce55 MDL-40621 fixed small bug in function editor_tinymce_plugin::fix_row() 2013-07-14 15:04:40 +10:00
Petr Škoda 5d43f79358 MDL-40611 fix context cache size expectation 2013-07-13 15:39:49 +02:00
Petr Škoda fe2577d197 MDL-40571 work around block editing hacks on admin page 2013-07-12 14:59:30 +02:00
Petr Škoda 22010649e1 MDL-40423 fix creation of new install.xml in subplugins 2013-07-12 14:56:44 +02:00
Tim Hunt 3a14deef9e MDL-40633 filter_urltolink breaking some image links.
This was a regression caused by MDL-22390. HTML like
<img src="http://www.example.com/logo.gif" />
was being broken.
2013-07-12 11:43:28 +01:00
Petr Škoda bf39b9a42d MDL-40558 skip admins and guest when deleting incomplete users 2013-07-12 12:37:23 +02:00
Petr Škoda 2d35bf9e04 MDL-40569 fix empty CSS files after cache purging 2013-07-12 12:34:40 +02:00
Dan Poltawski ac470250f7 MDL-40536 course/externallib fix incorrect variable
Fixes test_import_course_invalid_deletecontent_option() from the
previous commit.
2013-07-12 16:43:58 +08:00
Dan Poltawski 77e41db50e MDL-40536 course: unit tests for course_external::import_course
Basic import operations and a specific test case which identifies
a bug.
2013-07-12 16:43:57 +08:00
Mohamed Alsharaf 47ef2a432a MDL-38747 blocks: course format options 'numsections' is required to display the block 2013-07-12 20:23:09 +12:00
Damyon Wiese c2ad901002 weekly release 2.5.1+ 2013-07-12 09:52:21 +08:00
Damyon Wiese 3afab77ad6 Merge branch 'install_25_STABLE' of git://git.moodle.cz/moodle-install into MOODLE_25_STABLE 2013-07-12 09:43:13 +08:00
AMOS bot acf6bc9cdc Automatically generated installer lang files 2013-07-12 00:45:57 +00:00
prateeksachan ee36201eee MDL-38794 passed overflowdiv parameter 2013-07-11 07:26:56 +05:30
David Monllao 210290a905 MDL-38857 tool_behat: Adding info about the tool purpose 2013-07-10 12:08:54 +02:00
Marina Glancy 63c8f25b1b Merge branch 'MDL-38366-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-07-10 16:25:38 +10:00
Frederic Massart 21e0b2a025 MDL-38366 repository_filesystem: Prevent use of empty subdir 2013-07-10 13:48:28 +08:00
Marina Glancy 0f2a0a3fb0 Merge branch 'm25_MDL-39832_Fix_Chrome_Issues_ETag_XSendfile_2ndRound' of https://github.com/scara/moodle into MOODLE_25_STABLE 2013-07-10 12:01:29 +10:00
Raymond Wijaya 41e7411b9d MDL-40093_M25: mod/assign: Remove count of drafts in offline assignment's grading summary screen 2013-07-10 11:22:18 +10:00
Marina Glancy 4d8ff7c8e2 Merge branch 'w28_MDL-40488_m25_admin' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-07-10 11:09:44 +10:00
Russell Smith 30967ff481 MDL-40538 caching: Use isset for performance
isset is much faster than array_key_exists. For caches we need to
ensure as much performance as possible. To all null to continue to
be stored and provide correct results, non ttl also now saves in
$this->store[$key][0].  As isset($this->store[$key]) will return
true in all cases.

time() as found in cache::now() can be slow on some platforms and
we shouldn't bother checking it unless needed. It also stops non-ttl
caches paying the ttl price.

Unit tests were adjusted to ensure null is still handled correctly
when we are only using isset.
2013-07-10 10:41:22 +10:00
Sam Hemelryk 70e9700195 Merge branch 'wip-MDL-40593-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-07-10 12:18:36 +12:00
Marina Glancy 512ab8e262 Merge branch 'MDL-40441_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-10 10:02:53 +10:00
Sam Hemelryk c001e046e0 Merge branch 'w28_MDL-40450_m25_tinymcebuttons' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-07-10 11:02:01 +12:00
Sam Hemelryk 7c6e64c36c Merge branch 'MDL-40527_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-10 10:31:25 +12:00
Sam Hemelryk c6b546a1ee Merge branch 'm25_MDL-40512' of git://github.com/danmarsden/moodle into MOODLE_25_STABLE 2013-07-10 10:09:59 +12:00
Damyon Wiese 94fbefa96b Merge branch 'MDL-39420_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-09 22:43:43 +08:00
Damyon Wiese 218f778417 Merge branch 'MDL-36479_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-09 22:30:12 +08:00
Damyon Wiese 641595c1fa Merge branch 'MDL-40392_25' of git://github.com/stronk7/moodle into MOODLE_25_STABLE 2013-07-09 21:52:07 +08:00
Marina Glancy edd3c6961e MDL-40593 fixed SQL query to be postgres-compartible 2013-07-09 22:28:41 +10:00
Marina Glancy 1b0951a26a Merge branch 'MDL-40472-25' of git://github.com/damyon/moodle into MOODLE_25_STABLE 2013-07-09 21:36:12 +10:00
Tim Hunt 5f45c039fd MDL-39420 multichoice: fix layout of multi-line choices. 2013-07-09 11:57:06 +01:00
Tim Hunt b9f1aaa8de MDL-40441 fix obscure notice in the quiz.
This can only happen if you have both a user with both a real attempt
and a preview, and then edit the quiz settings.

Also clean up this code a bit.
2013-07-09 10:44:57 +01:00
Damyon Wiese 234d90b209 Merge branch 'MDL-40443_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-09 15:16:16 +08:00
Jamie Pratt 81e01645d8 MDL-40176 mock_submit method for testing 2013-07-09 15:09:10 +08:00
Marina Glancy 82043201ea Merge branch 'MDL-39020-m25' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-07-09 16:34:28 +10:00
Damyon Wiese 10061c1de7 Merge branch 'MDL-40499_25' of git://github.com/jmvedrine/moodle into MOODLE_25_STABLE 2013-07-09 13:27:28 +08:00
Damyon Wiese a16698d10b Merge branch 'MDL-40386_25' of https://github.com/prateeksachan/moodle into MOODLE_25_STABLE 2013-07-09 12:34:52 +08:00
Jamie Pratt 161d67d8df MDL-40388 Reset globals after each unit test 2013-07-09 11:56:04 +08:00
Tony Levi d4bbe8997f MDL-40035: Avoid rebuild_course_cache always for empty course 2013-07-09 13:54:24 +10:00
Damyon Wiese d5e3d9a06d Merge branch 'MDL-40318_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-09 11:12:19 +08:00
Damyon Wiese 79fd52c6c3 Merge branch 'MDL-40562_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-07-09 11:05:39 +08:00
Marina Glancy 33025649f3 Merge branch 'MDL-40434_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-09 11:31:52 +10:00
Tim Lock 6fe662302c MDL-40436: auth_ldap: Fixed warning when adding new LDAP users 2013-07-08 22:59:11 +08:00
Adam Olley 66a38f083a MDL-40195: mod_assign: Display grades when quickgrading to 2 decimal places 2013-07-08 20:08:01 +09:30
David Monllao c81f3193ce MDL-40562 behat: Catch NoSuchElement exception 2013-07-08 12:08:15 +02:00
Damyon Wiese ca4077c79d Merge branch 'MDL-38314-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE
Conflicts:
	version.php
2013-07-08 15:14:55 +08:00
Petr Škoda 3e17040a6e MDL-40450 update links to TinyMCE 3.x docs 2013-07-07 16:12:04 +02:00
Matteo Scaramuccia a05efa34e2 MDL-39832 Files: Fixed ETag format according with RFC2616.
ETag must be double quoted,
http://tools.ietf.org/html/rfc2616#section-3.11:

      entity-tag = [ weak ] opaque-tag
      weak       = "W/"
      opaque-tag = quoted-string
2013-07-07 09:06:48 +02:00
Matteo Scaramuccia 31afec2312 MDL-39832 Files: Revert MDL-39688 commit, 161be92065
MDL-39688 has been successful in providing a solution for the issue but further
investigations done in MDL-39832 have got the evidence that the given solution
is more likely a workaround.
2013-07-07 09:06:47 +02:00
Eloy Lafuente (stronk7) fb41a38153 Moodle release 2.5.1 2013-07-06 17:59:23 +02:00
Petr Škoda c0c0353438 MDL-40488 improve $CFG->admin docs 2013-07-06 11:47:50 +02:00
Tim Hunt 47c9a54e63 MDL-40527 enrol meta: respect $CFG->courselistshortnames
Thanks to James Henestofel for working this out in MDL-37558. That issue
got complex, so I am just submitting this simple part of it for
integration.
2013-07-05 15:32:26 +01:00
Rossiani Wijaya 54f0dd9492 MDL-39812 clean theme: fixed breadcrumbs layout for narrow screens 2013-07-05 11:09:21 +08:00
Rossiani Wijaya 0a4c3a88db MDL-39812: bootstrapbase theme: Fix breadcrumbs layout for narrow screen 2013-07-05 10:58:15 +08:00
Dan Marsden 353d91fa1d MDL-40512 SCORM: prevent undefined warning 2013-07-05 12:09:21 +12:00
Jean-Michel Vedrine 0c2a1dec76 MDL-40499 Edit question from 1.9 backup breaks if images in subdirs 2013-07-04 15:01:18 +02:00
Eloy Lafuente (stronk7) dc50d26267 MDL-40392 Navigation -> my courses listing tests
This introduces some behat tests to verify that
the display of enrolled courses in the navigation
block works as expected, both when a plain list
or a nested list is configured.

Personally I'm not happy with the way to select
expected text via css element. I'd love to see
something in an higher level like

I should see the text|link "xxxxx" in the "yyyy" "element"

with element being "block, header, footer, main...."

But that's another issue.
2013-07-04 13:51:48 +02:00
Tim Hunt 1cdc4d2556 MDL-40443 setType notice in quiz reports. 2013-07-04 12:37:59 +01:00
Tim Hunt 3feb538a46 MDL-40318 quiz intro comprising just an impage was not shown
Also, ensure that we don't output an empty box if there are no access
messages.
2013-07-04 12:37:19 +01:00
Tim Hunt 48eec6a5bf MDL-36479 quiz regrade: use progress bar to prevent time-outs 2013-07-04 12:36:36 +01:00
Damyon Wiese 4c6f1ec52e weekly release 2.5+ 2013-07-04 15:34:24 +08:00
Damyon Wiese ef572665e9 MDL-40308: Fix javascript for lti mod_form
It was toggling the state of the hidden input - not the checkbox.
2013-07-04 13:47:23 +08:00
Eloy Lafuente (stronk7) 0383404678 MDL-40376 Fix copy/paste typo 2013-07-03 17:54:14 +02:00
Frederic Massart 03ab0ed880 MDL-38314 repository: Improving performance of upgrade script 2013-07-03 16:29:51 +08:00
Frederic Massart f0c176fccc MDL-38314 repository: Remove orphan repository instances 2013-07-03 16:29:48 +08:00
Frederic Massart 6b7b7455d1 MDL-38314 repository: Delete repository instances on context deletion 2013-07-03 16:27:13 +08:00
Frederic Massart 2bc5ceb31c MDL-38314 repository: Unit Tests for delete_all_for_context() 2013-07-03 16:27:13 +08:00
Damyon Wiese 895f8d2b5f MDL-40472: Clean all codechecker warnings on mod_assign 2013-07-03 16:01:52 +08:00
Yuliya Bozhko a7c2742900 MDL-39986 badges: Show badge navigation to users with awardbadge capability
Also fixes an arror when a user with this capability tries to award a badge,
but their role is not among the criteria set up for a badge
2013-07-03 13:05:50 +08:00
Damyon Wiese fc83888891 MDL-39558 badges: Prevent backup of badges without user information 2013-07-03 10:54:31 +08:00
Yuliya Bozhko 18811be378 MDL-39558 badges: Add backup/restore of manually awarded badges 2013-07-03 10:13:05 +08:00
Yuliya Bozhko 56d54e1eed MDL-39558 badges: Add backup/restore to course badges 2013-07-03 10:12:46 +08:00
Michael Aherne 3a4a5356eb MDL-40275 core Improve documentation for block_base::has_config() 2013-07-02 21:52:59 +02:00
Eloy Lafuente (stronk7) 1a5986dab9 Merge branch 'MDL-40376-m25' of git://github.com/andrewnicols/moodle into MOODLE_25_STABLE 2013-07-02 21:12:10 +02:00
Eloy Lafuente (stronk7) c10fc915ad MDL-37516 Translate fieldnames on output only.
This reverts a change performed by the previous commit where user
fieldnames were being translated (and cached) when fetched,
causing the information to remain static later, not responding
to language switches (and perhaps leading to other problems if those
structures are used lated for DB / $USER comparisons.

With the commit, the translation happens on output, so no
potential interferences will happen and, also, the information
changes dynamically on lang switching.
2013-07-02 21:01:56 +02:00
sam marshall a6683d327f MDL-37516 Conditional activities: user field condition display fixes 2013-07-02 20:59:07 +02:00
Eloy Lafuente (stronk7) a9155c2875 Merge branch 'MDL-40246_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-07-02 14:27:24 +02:00
Eloy Lafuente (stronk7) 4d52fbbc14 Merge branch 'MDL-40439-en_fix_25' of git://github.com/mudrd8mz/moodle into MOODLE_25_STABLE 2013-07-02 13:47:37 +02:00
Helen Foster bb07f7ecce MDL-40439 Merge English strings from the en_fix language pack 2013-07-02 11:47:49 +02:00
Dan Poltawski dee6316364 Merge branch 'MDL-40389_25' of git://github.com/stronk7/moodle into MOODLE_25_STABLE 2013-07-02 15:53:06 +08:00
Tim Hunt b465164c24 MDL-40434 calculatedmulti multiple-response questions not randomised 2013-07-02 08:23:56 +01:00
Dan Poltawski f6b1260812 Merge branch 'MDL-40282.25' of github.com:colchambers/moodle into MOODLE_25_STABLE 2013-07-02 15:15:32 +08:00
Damyon Wiese 1e6919f6c8 Merge branch 'wip-MDL-40353-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-07-02 14:29:08 +08:00
Dan Poltawski a852df6f11 Merge branch 'MDL-40297_25' of git://github.com/stronk7/moodle into MOODLE_25_STABLE 2013-07-02 13:43:45 +08:00
Andreas Grabs e235c97f09 MDL-39570 mod_feedback - Missing privilege check 2013-07-02 13:36:51 +08:00
Dan Poltawski d7e626156e Merge branch 'w27_MDL-40399_m25_msarrayshift' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-07-02 13:33:59 +08:00
Dan Marsden 0bde9de161 MDL-39628 Chat: check mod/chat:chat capability when using daemon.
Thanks to Francois Gauthier for report/fix.
2013-07-02 12:18:24 +08:00
Jason Fowler dafe65e438 MDL-37818 - RSS - Prevent access to blocks while RSS context errors are displayed 2013-07-02 10:03:57 +08:00
Dan Poltawski 204383e50d Merge branch 'w27_MDL-40266_m25_arrayshift' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-07-02 09:55:24 +08:00
Eloy Lafuente (stronk7) f1293083a2 Merge branch 'get_users_by_capability_fix_m25' of http://github.com/timgus/moodle into MOODLE_25_STABLE 2013-07-02 00:46:38 +02:00
Sam Hemelryk f0d974fb28 Merge branch 'MDL-39733_25' of git://github.com/stronk7/moodle into MOODLE_25_STABLE 2013-07-02 10:31:28 +12:00
Eloy Lafuente (stronk7) 16a2860ad2 MDL-39733 xhprof: implement import of runs 2013-07-02 00:27:30 +02:00
Rossiani Wijaya bb9024d9d4 MDL-39546 Lesson module: removed duplicate to decode special characters 2013-07-02 09:36:46 +12:00
Rossiani Wijaya a77f19bc47 MDL-39546 Lesson module: fixed matching question issues. 2013-07-02 09:36:32 +12:00
Eloy Lafuente (stronk7) 2bc8f21600 Merge branch 'w27_MDL-39754_m25_evn26' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-07-01 23:14:05 +02:00
Eloy Lafuente (stronk7) 75b8d4a146 Merge branch 'MDL-40370_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-01 18:02:51 +02:00
Eric Merrill 74d5fbac04 MDL-40412 course Expanding the height of module description fields.
Expanding the default height of mod descriptions to 10, which gives
you 3 real lines once TinyMCE Loads.
2013-07-01 10:26:52 -04:00
Tim Hunt 33b4331eaf MDL-40370 qtype_shortanswer: unique index upgrade problem.
Eliminate duplicate rows before we try to add a unique index. We
arbitrarily keep the duplicate row with the lowest id.
2013-07-01 11:23:55 +01:00
prateeksachan ef57de83db MDL-40386: Fix for updating timemodified field in book_chapters 2013-07-01 14:32:34 +05:30
Petr Škoda 00a2921469 MDL-39754 copy 2.5 requirements to Moodle 2.6
Optional features and warnings may be added later,
but we need at least required environment for 2.5.1

This includes database family cleanup and more realistic memory requirement.
2013-07-01 10:03:14 +02:00
Petr Škoda fc4523f8f3 MDL-40266 improve emulate_bound_params() for mssql driver
Looping over large numbers of items with array_shift() is expensive.
Reverse the array and fetch items from the top of the pile.

Credit goes to Martin Langhoff for original mysqli fix.
2013-07-01 08:52:51 +02:00
Petr Škoda 39714cb255 MDL-40266 improve emulate_bound_params() for sqlsrv driver
Looping over large numbers of items with array_shift() is expensive.
Reverse the array and fetch items from the top of the pile.

Credit goes to Martin Langhoff for original mysqli fix.
2013-07-01 08:52:51 +02:00
Mark Nielsen c11621b415 MDL-40308: Privacy settings do not change
Update LTI mod form so checkboxes always submit their value.
2013-07-01 11:27:43 +08:00
Dan Poltawski 7698803c95 Merge branch 'wip-MDL-40344-m25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-07-01 11:22:05 +08:00
Ankit Agarwal 770710e1cd MDL-39020 phpunit: Rename incorrect filename
Rename externallib_tests.php to externallib_test.php
Fix failing unit tests
2013-07-01 10:52:42 +08:00
Sam Hemelryk ebc9b6d158 Merge branch 'MDL-40069_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-07-01 13:47:50 +12:00
Sam Hemelryk ae754bba07 NOBUG: fixed whitespace 2013-07-01 13:24:04 +12:00
Sam Hemelryk d20391916c Merge branch 'wip-MDL-39741-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-07-01 13:17:48 +12:00
Sam Hemelryk 9a561bc5a1 Merge branch 'MDL-35206-email-links_25' of git://github.com/mudrd8mz/moodle into MOODLE_25_STABLE 2013-07-01 13:08:15 +12:00
Eloy Lafuente (stronk7) 7af092c2d6 MDL-39733 profiling: UI for importing runs 2013-07-01 01:39:55 +02:00
Eloy Lafuente (stronk7) 706db16531 MDL-39733 profiling: UI for exporting runs 2013-07-01 01:39:50 +02:00
Eloy Lafuente (stronk7) e3c2cb4656 MDL-39733 xhprof: implement export of runs 2013-07-01 01:39:45 +02:00
Andrew Nicols 2738bb2c2f MDL-40376 Themes: Remove padding from course/manage page 2013-06-30 19:28:41 +01:00
Martin Langhoff c17768973e MDL-40266 improve emulate_bound_params() for mysqli
Looping over large numbers of items with array_shift() is expensive.
Reverse the array and fetch items from the top of the pile.
2013-06-30 18:39:53 +02:00
Eloy Lafuente (stronk7) 11ffc395f4 MDL-40389 Test "parent" course/category generators
Verify that the category->parent switchers for
course & category behat generators are happening
as expected. Use the manage courses page for that.
2013-06-30 18:10:25 +02:00
Eloy Lafuente (stronk7) 1608fbe7c0 MDL-40297 whitespace, comments & var names cleanup 2013-06-30 16:48:44 +02:00
Dmytro Vorona 0927af1e8d MDL-40297 Hide empty categories in my courses
This is a followup of MDL-38631 were was detected that
whith categories being displayed in my courses, some of
them, not having courses for the user, were still shown.

With this patch, any category in the tree, not having courses
is automatically hidden, any depth.
2013-06-30 16:48:39 +02:00
Tim Hunt 77504426de MDL-40069 question/type/upgrade.txt editing changes
Try to more clearly document what question type authors need to do to
upgrade their question types.
2013-06-28 18:21:04 +01:00
Colin Chambers 2fe9be7a9e MDL-40069 Document editing form changes 2013-06-28 18:21:02 +01:00
David Mudrák 52d485c435 MDL-35206 Fix the links list enumeration in the html2text library 2013-06-28 13:13:29 +02:00
Colin Chambers 93a2a0e3d7 MDL-40282 Collapsible editor loses border in IE8-9 2013-06-28 11:23:47 +01:00
Mary Evans dc59a1b1f9 MDL-40131 theme_bootstrapbase: added missing grader table css to less/moodle/grade.less 2013-06-28 02:45:29 +01:00
Sam Hemelryk 21d9cb723b MDL-40344 navigation: expandable branch id is now properly unique 2013-06-28 09:59:09 +12:00
Eloy Lafuente (stronk7) 32e550a6eb weekly release 2.5+ 2013-06-27 20:12:40 +02:00
Eloy Lafuente (stronk7) 97a7b6a7aa Merge branch 'install_25_STABLE' of git://git.moodle.cz/moodle-install into MOODLE_25_STABLE 2013-06-27 20:05:10 +02:00
Marina Glancy 3c4c23876c MDL-39741 removed unused css classes 2013-06-27 22:18:59 +10:00
David Monllao ff46f98998 MDL-40246 mod_forum: Changing scenario to non-JS
Also replacing hardcoded waits for a
wait to be redirected.
2013-06-27 15:13:12 +08:00
Marina Glancy 00b4836197 MDL-40353 fixed wrong redirection on course group page 2013-06-27 13:45:16 +10:00
Marina Glancy 4af378d743 MDL-39741 Use CSS class dimmed_text instead of hidden in grader report 2013-06-27 12:36:11 +10:00
AMOS bot fab0986a5b Automatically generated installer lang files 2013-06-27 00:40:24 +00:00
Eloy Lafuente (stronk7) 866ab6e1ce Merge branch 'w26_MDL-39701_m25_filterupgrade' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-26 12:30:51 +02:00
Petr Škoda 0b675e0ca2 MDL-39701 prevent string filtering before finishing 2.5 upgrade 2013-06-26 09:51:03 +02:00
Eloy Lafuente (stronk7) 3166c21471 Merge branch 'MDL-40033_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-06-25 12:08:25 +02:00
Gareth J Barnard 2ab1b3de30 MDL-40204 theme_bootstrapbase & theme_clean: Fix RTL 3 column lyt with 1 blk. 2013-06-25 11:38:27 +12:00
Sam Hemelryk 6e07abb32d Merge branch 'wip-MDL-40065-m25_4' of git://github.com/gjb2048/moodle into MOODLE_25_STABLE 2013-06-25 09:58:44 +12:00
Sam Hemelryk bc0227d3e5 Merge branch 'w26_MDL-40289_m25_badgescaps' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-25 09:13:05 +12:00
Eloy Lafuente (stronk7) e9d80e664b Merge branch 'w26_MDL-40233_m25_frontset' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-24 21:29:13 +02:00
Eloy Lafuente (stronk7) ffc480afbd Merge branch 'MDL-40264-m25-essay-zero' of git://github.com/ktemkin/moodle into MOODLE_25_STABLE 2013-06-24 21:23:43 +02:00
Eloy Lafuente (stronk7) 3d4a0f2887 Merge branch 'w26_MDL-40254_m25_flatfile' of https://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-24 21:13:06 +02:00
Eloy Lafuente (stronk7) 9067595bf3 Merge branch 'MDL-34610_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-06-24 20:21:30 +02:00
Eloy Lafuente (stronk7) 94a541f7ff Merge branch 'MDL-40255_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE 2013-06-24 19:26:22 +02:00
Eloy Lafuente (stronk7) 3e6f11b240 Merge branch 'm25_MDL-40200_Notices_When_Viewing_Profile_Invalid_UserId' of https://github.com/scara/moodle into MOODLE_25_STABLE 2013-06-24 19:00:43 +02:00
Sam Chaffee 7991637057 MDL-40258: Fixed invalid json string error in file-picker 2013-06-24 18:56:54 +02:00
Ankit Agarwal 4f61afa0b7 MDL-40250 phpunit: Add unit tests for core_files_external::upload() 2013-06-24 18:06:26 +02:00
Gareth J Barnard fb42a8c761 MDL-40065 theme_bootstrapbase theme_clean: Simplify column lyts / fix blocks. 2013-06-24 16:59:11 +01:00
Sam Hemelryk 4418496864 Merge branch 'wip-MDL-39044-stable25' of git://github.com/phalacee/moodle into MOODLE_25_STABLE 2013-06-24 15:41:24 +12:00
Sam Hemelryk 82125f7a78 Merge branch 'w26_MDL-39701_m25_filterupgrade' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-24 15:07:14 +12:00
Sam Hemelryk 9e5adb9305 Merge branch 'MDL-39779_m25' of git://github.com/rwijaya/moodle into MOODLE_25_STABLE 2013-06-24 14:33:04 +12:00
Sam Hemelryk 23dd6b7ebf Merge branch 'MDL-39760-MOODLE_25_STABLE' of https://github.com/lucisgit/moodle into MOODLE_25_STABLE 2013-06-24 14:29:56 +12:00
Frederic Massart af4bdb8c8d MDL-39280 form: Multiple select support disabledIf with multiple values 2013-06-24 14:20:33 +12:00
Sam Hemelryk 12a9b4ec3a Merge branch 'mdl25-MDL-40130-let-course-category-caching-be-used' of git://github.com/brki/moodle into MOODLE_25_STABLE 2013-06-24 11:43:54 +12:00
Sam Hemelryk 084b971bc8 MDL-38347 fixed whitespace 2013-06-24 11:29:26 +12:00
Jason Fowler df7662560b MDL-38347 - Calendar - Fixing arrow output on Android devices 2013-06-24 11:22:51 +12:00
Sam Hemelryk 405a60712b Merge branch 'MDL-28124_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE 2013-06-24 10:30:08 +12:00
Amanda Doughty bce7b6d40e MDL-38376 mod_assign: Feedback displayed when Grade set to hidden 2013-06-24 10:22:34 +12:00
Petr Škoda 55384d2016 MDL-40254 ignore flatfile records with no user idnumber 2013-06-23 21:38:39 +02:00
Petr Škoda f8bb8999e8 MDL-40289 fix block_badges capability defaults 2013-06-23 12:34:02 +02:00
Petr Škoda 2fbf721f27 MDL-40289 fix all badges capabilities
1/ contextlevel must be the lowest level where capability can be overriden
2/ coursecreator is for course creation only!!!
3/ do not mix user with other archetypes
4/ config risk is for admin actions only in standard install

No upgrade cleanup, sorry, blame integrators...
2013-06-23 12:23:50 +02:00
Mary Evans 233edd4dde MDL-40255 theme_boxxie/theme_formfactor: Added block-region class to layout files to enable dnd file uploader to work. 2013-06-22 21:24:23 +01:00
Petr Škoda 75f1afeda0 MDL-39701 prevent filters before finishing 2.5 upgrade
This prevents problems with unsigned integers in MySQL 5.5
2013-06-22 22:23:25 +02:00
Petr Škoda 808043d356 MDL-40233 add proper cache invalidation on frontpage setting save 2013-06-22 22:19:27 +02:00
Matteo Scaramuccia da0c3ea381 MDL-40200 Administration: Return the invalid user message and stop there
To avoid adding duplicate code, 'invalid user' and 'user deleted' checks
have been merged together.
2013-06-22 10:00:59 +02:00
Marina Glancy a028ac4aaf MDL-38631 link categories in My courses only when needed 2013-06-22 16:25:43 +10:00
Dmytro Vorona 02e1c8ad20 MDL-38631 Fixed faulty add_category call, introduced in 758103 2013-06-22 16:25:42 +10:00
Tim Hunt 3174f09839 MDL-34610 remove legacy IE CSS. It breaks form layout 2013-06-21 21:57:37 +01:00
Brian King 1a703d311e MDL-40130 Caching: let make_categories_list use the cache it makes 2013-06-21 11:14:08 +02:00
David Monllao 922a5cf370 MDL-40033 behat: Waiting until file manager is available 2013-06-21 15:36:41 +08:00
Dan Poltawski e978b66009 weekly release 2.5+ 2013-06-21 13:30:52 +08:00
Dan Poltawski 8e29fe2d72 Merge branch 'install_25_STABLE' of git://git.moodle.cz/moodle-install into MOODLE_25_STABLE 2013-06-21 13:29:46 +08:00
Kyle Temkin 11f6680dee MDL-40264 fix essay handling of zero-string response
Fixes an inappropriate behavior of the is_complete_response() function
for the Essay question type, which caused the string "0" to be
inappropriately marked as an incomplete response.

Also adds a set of unit tests for the Essay question type's
is_complete_response.
2013-06-20 19:12:21 -04:00
Tim Gus 0bad576425 MDL-40259 - For SCORM reports limit fields returned from
get_users_by_capability to user ID to decrease memory utilization
2013-06-20 15:56:07 -04:00
Jason Fowler 1620d20165 MDL-39044 - Course Completion - Replaceing strtolower with multibyte safe textlib::strtolower 2013-06-20 08:49:38 +08:00
Ruslan Kabalin e2d5b6cbc8 MDL-39760: mod_assign: Add few more callback methods.
Adds lock, unlock and release_to_draft. All of them accept single parameter -
an assign_submission record.
2013-06-19 15:34:02 +01:00
Yuliya Bozhko e787333622 MDL-40022 badges: Fix missing calls to setType in course criteria settings 2013-06-19 13:41:49 +08:00
David Monllao 4ab623b9b6 MDL-40109 behat: Fixing backup feature 2013-06-19 09:14:05 +08:00
Marina Glancy 8526be5612 Merge branch 'MDL-40207-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-06-18 15:38:20 +10:00
Ruslan Kabalin eede0dbd7b MDL-33546: course: Fix current week hightlighting after dragging the section 2013-06-18 13:02:27 +10:00
Marina Glancy 4d7c173514 Merge branch 'MDL-40165-m25' of git://github.com/andrewnicols/moodle into MOODLE_25_STABLE 2013-06-18 12:57:06 +10:00
Sam Hemelryk 70d4b3182d Merge branch 'MDL-39634_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-06-18 14:50:47 +12:00
Nadav Kavalerchik 32a3dc0ec0 MDL-40180 - RTL/Clean theme: Misalignment of student name and profile image in grader (fixed by Mary Evans)
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-06-18 10:43:48 +08:00
Sam Hemelryk 663c69e974 Merge branch 'MDL-40036-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-06-18 13:59:30 +12:00
Sam Hemelryk eaf4854359 Merge branch 'MDL-39865-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-06-18 13:54:56 +12:00
Marina Glancy 04597742cf Merge branch 'MDL-38079_25' of git://github.com/mr-russ/moodle into MOODLE_25_STABLE 2013-06-18 11:13:26 +10:00
Eloy Lafuente (stronk7) f68a2c50e6 MDL-40137 Whitespace fix 2013-06-18 01:47:44 +02:00
Eloy Lafuente (stronk7) 5e069cbd96 Merge branch 'wip-MDL-40137-m25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-06-18 01:45:27 +02:00
Sam Hemelryk 3d19b183c6 Merge branch 'wip-mdl-39863-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-06-18 11:19:30 +12:00
Sam Hemelryk d81ebc8f0d Merge branch 'MDL-40109_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-06-18 11:07:57 +12:00
Eloy Lafuente (stronk7) 5cc26839e7 Merge branch 'w25_MDL-40210_m25_badgescaps' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-18 00:56:11 +02:00
Eloy Lafuente (stronk7) a831f154ae Merge branch 'MDL-33562-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE
Conflicts:
	lib/db/upgrade.php
	version.php
2013-06-18 00:44:17 +02:00
Sam Hemelryk 54c7d518f3 Merge branch 'MDL-30132_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE 2013-06-18 10:26:53 +12:00
Petr Škoda ec18ffb86c MDL-40210 do not use CAP_PREVENT for role defaults! 2013-06-17 12:13:20 +02:00
Russell Smith 842aac5ecb MDL-38079 mod_feedback - Hide "add question to activity" button 2013-06-17 19:59:37 +10:00
David Monllao dc24efe971 MDL-40110 behat: AM/PM strings are OS-dependant, removing this part from tests 2013-06-17 17:06:38 +08:00
Dan Poltawski 160e432aee Merge branch 'MDL-39825_master' of https://github.com/totara/openbadges into MOODLE_25_STABLE 2013-06-17 16:41:15 +08:00
Dan Poltawski e38c37939a Merge branch 'wip-MDL-40136-m25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-06-17 13:37:23 +08:00
Sam Hemelryk e15bf9b1e5 Merge branch 'm25_MDL-40095_Completion_locked_Error_on_save' of https://github.com/scara/moodle into MOODLE_25_STABLE 2013-06-17 16:10:38 +12:00
Sam Hemelryk 1d1b52eb0c Merge branch 'MDL-21933_25' of https://github.com/mr-russ/moodle into MOODLE_25_STABLE 2013-06-17 15:45:33 +12:00
Sam Hemelryk 209658eab2 Merge branch 'wip-MDL-40091-MOODLE_25_STABLE' of git://github.com/satrun77/moodle into MOODLE_25_STABLE 2013-06-17 15:43:18 +12:00
Rossiani Wijaya 49a60b6c65 MDL-39779 wiki module: fix the alignment for required label to display inline on mobile devices 2013-06-17 11:42:47 +08:00
Sam Hemelryk 8c155823cc Merge branch 'MDL-39369_m25' of git://github.com/rwijaya/moodle into MOODLE_25_STABLE 2013-06-17 15:10:21 +12:00
Dan Poltawski 3c4fcce769 MDL-40207 simplepie: reduce false failures in unit tests
The simplepie tests time out too quickly due to a low connect timeout,
to fix this, I converted the unit tests to use a high timeout value.
2013-06-17 10:46:53 +08:00
Sam Hemelryk 443563a82e Merge branch 'MDL-39761-MOODLE_25_STABLE' of https://github.com/lucisgit/moodle into MOODLE_25_STABLE 2013-06-17 14:26:37 +12:00
David Monllao 346765035a MDL-39634 behat: Adding debugging() messages to deprecated methods 2013-06-17 09:02:39 +08:00
David Monllao 944fd1ca83 MDL-39634 behat: Adding deprecated methods
To keep compatibility if someone is
already using these methods.
2013-06-17 09:01:38 +08:00
David Monllao ded65ca8e0 MDL-39634 behat: Removing unused arguments 2013-06-17 08:59:59 +08:00
AMOS bot 2bf9edf84f Automatically generated installer lang files 2013-06-17 00:43:36 +00:00
Marina Glancy 29a4508930 Merge branch 'wip-MDL-40142-m25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-06-17 10:40:39 +10:00
Sam Hemelryk bda2a7bdf5 MDL-39949 dock: fixed whitespace 2013-06-17 10:24:53 +12:00
Jason Fowler 64ddb28dfd MDL-39949 - Blocks - preventing blocks with empty titles from blocking the execution of javascript 2013-06-17 10:01:44 +12:00
Sam Hemelryk 6fa5e8658a MDL-40137 theme_clean: corrected lib.php function names 2013-06-17 09:39:20 +12:00
Sam Hemelryk 43dc7aa976 MDL-40136 cache: fixed dirroot change bugs with plugin caches 2013-06-17 09:23:47 +12:00
Sam Hemelryk 5d9349b61a MDL-40142 navigation: fixed chainable issue with navigation JS 2013-06-17 09:12:43 +12:00
Mary Evans ff24397ff3 MDL-28124 admin/tool/customlang: Changed page layout from 'standard' to 'report'. 2013-06-14 23:27:34 +01:00
Mohamed Alsharaf de5568b18e MDL-40091 book: revision must be incremented after editing a chapter 2013-06-14 21:28:31 +12:00
Marina Glancy d3cf194050 weekly release 2.5+ 2013-06-14 13:53:28 +10:00
Marina Glancy 37d38a3125 Merge branch 'install_25_STABLE' of git://git.moodle.cz/moodle-install into MOODLE_25_STABLE 2013-06-14 13:50:50 +10:00
Andrew Nicols 2804eb29c6 MDL-40165 Backup: Split out test classes into multiple files 2013-06-13 08:57:24 +01:00
Rossiani Wijaya e85e3bff3e MDL-39369: Lesson module: change settype PARAM_TEXT to PARAM_NOTAGS 2013-06-13 15:37:45 +08:00
Rossiani Wijaya 51c72ecaa5 MDL-39369: Lesson module: fix setType() properly 2013-06-13 15:36:16 +08:00
Dan Poltawski 30703dc8f2 MDL-39824: theme_bootstrap: initalise array before use
This causes warnings when no navigation items are returned.

Also fixed some bad whitespace.
2013-06-13 14:23:55 +08:00
Dan Poltawski 33beb96847 Revert "MDL-39832 Files: Revert MDL-39688 commit, 161be9206571787557eb5c11ee440c9e6ae93ca8"
This reverts commit d618e3c07d.
2013-06-13 13:57:02 +08:00
Dan Poltawski 7f742cece1 Revert "MDL-39832 Files: Fixed ETag format according with RFC2616."
This reverts commit 52286ac358.
2013-06-13 13:57:00 +08:00
Russell Smith ab0e64524d MDL-21933 course: Allow users to search participants course permission
Capability checks are performed at the top of the page and do not need
to be completed again.

Search is an expected feature for users and it was confusion to only
appear after 3 pages.  This has been changed to enable search when
there are more records than are visible on the screen.  If users
are unable to use browser search, they will be able to use Moodle's
search.
2013-06-13 12:43:29 +10:00
AMOS bot 2a93e8d72c Automatically generated installer lang files 2013-06-13 00:41:25 +00:00
Mary Evans 6780a2301e MDL-30312 User: Changed page layout from mydashboard to mypublic in user/profile.php 2013-06-12 21:33:28 +01:00
sam marshall 3a2e904098 MDL-39472 MUC: Optimise cache::get_from_persist_cache 2013-06-12 14:29:48 +08:00
Dan Poltawski 6117c578e4 Merge branch 'MDL-39773_b_m25' of git://github.com/rwijaya/moodle into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-06-12 09:34:04 +08:00
Sam Hemelryk 69303857c7 Merge branch 'MDL-39940-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-06-12 09:06:33 +12:00
Sam Hemelryk a4848b4044 Merge branch 'MDL-39964-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-06-12 09:02:40 +12:00
Sam Hemelryk a6b980d13b Merge branch 'MDL-25901-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-06-12 09:00:11 +12:00
Sam Hemelryk 9e53bbd007 Merge branch 'w24_MDL-38109_m25_pluginlist' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-12 08:53:49 +12:00
Sam Hemelryk e0699a7154 Merge branch 'wip-MDL-39798_M25' of git://github.com/gjb2048/moodle into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-06-12 08:51:21 +12:00
Sam Hemelryk aa41f96d1a Merge branch 'wip-MDL-39820_M25_2' of git://github.com/gjb2048/moodle into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-06-12 08:46:45 +12:00
Petr Škoda e4fcb52f44 MDL-38109 use always get_plugin_list() to get list of plugins
get_list_of_plugins() is NOT intended for real plugins, only plugin like directories.
2013-06-11 10:23:14 +02:00
Dan Poltawski bacf4c5c71 Merge branch 'wip-MDL-40087_M25' of git://github.com/gjb2048/moodle into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-06-11 16:00:51 +08:00
Dan Poltawski 43c5a7d5ad Merge branch 'wip-MDL-40100-m25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-06-11 15:35:31 +08:00
Sam Hemelryk 624f270a26 Merge branch 'MDL-26925-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-06-11 17:31:36 +12:00
Sam Hemelryk 313bcd5268 Merge branch 'MDL-22390_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-06-11 17:07:24 +12:00
Mark Nelson 5a21d336f3 MDL-40010 notes: passing an object rather than an id to avoid debugging message 2013-06-11 13:05:40 +08:00
Dan Poltawski f60ad3fdff Merge branch 'm25_MDL-40002_ETag_value_must_be_a_quoted-string' of https://github.com/scara/moodle into MOODLE_25_STABLE 2013-06-11 12:54:38 +08:00
Jason Fowler 2daa9998ae MDL-39746 - Themes - Hiding the user picture on the forum page when the screensize is too small to allow for it
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-06-11 11:25:04 +08:00
Rajesh Taneja 6079448098 MDL-39863 Administration: Show confirmation/notice and don't redirect automatically 2013-06-11 10:24:51 +08:00
Tim Lock 992c0ec50d MDL-40120: Fix get_course_records() which breaks in PSQL 2013-06-11 13:47:05 +12:00
sam marshall aca67ae8b0 MDL-39454 Accesslib: is_siteadmin is a bit slow 2013-06-11 12:27:09 +12:00
Matteo Scaramuccia 474c13f27f MDL-40095 SCORM: Trivial comments tidy up 2013-06-10 20:52:24 +02:00
Matteo Scaramuccia 7480e99306 MDL-40095 SCORM: Fixed DML error when saving with completion options locked
Regression caused by MDL-38315.
2013-06-10 20:52:14 +02:00
Dan Poltawski 96241e57e9 Merge branch 'MDL-39947_25' of https://github.com/aolley/moodle into MOODLE_25_STABLE 2013-06-10 16:20:30 +08:00
Dan Poltawski ade2afc29f Merge branch 'MDL-39338_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-06-10 16:07:28 +08:00
Dan Poltawski 534f1476f4 Merge branch 'm25_MDL-39832_Fix_Chrome_Issues_ETag_XSendfile' of https://github.com/scara/moodle into MOODLE_25_STABLE 2013-06-10 15:42:53 +08:00
Rajesh Taneja b625e48b87 MDL-39639 Formslib: Hide calendar for datetime element on disable event 2013-06-10 15:29:16 +08:00
Dan Poltawski a327e87866 Merge branch 'MDL-40018_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE 2013-06-10 15:00:20 +08:00
Dan Poltawski 0f74c82897 Merge branch 'MDL-40013_25stable' of git://github.com/oasychev/moodle into MOODLE_25_STABLE 2013-06-10 14:58:12 +08:00
David Mudrák 3ee63c14e0 MDL-40080 Remove unused strings from the core_hub subsystem 2013-06-10 14:41:53 +08:00
Mark Nelson f31670ef40 MDL-40008 forms: fixed ordering of the calendar icon and enable checkbox for the date selector element 2013-06-10 14:25:14 +08:00
David Monllao b1f151c933 MDL-40109 format_weeks: Removing extra space 2013-06-10 13:31:22 +08:00
Dan Poltawski 7f9f03442a Merge branch 'w24_MDL-39096_m25_obfuscate' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-10 13:12:16 +08:00
Dan Poltawski 9d1a909f0e Merge branch 'w24_MDL-28394_m25_enrolrestore' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-10 12:17:04 +08:00
Yuliya Bozhko 8b7c33ae77 MDL-39825 badges: Remove badges from course navigation when course badges are disabled 2013-06-10 16:16:59 +12:00
Dan Poltawski c9d1c4993d Merge branch 'm25_MDL-37968' of git://github.com/danmarsden/moodle into MOODLE_25_STABLE 2013-06-10 12:09:59 +08:00
Mary Evans 7b9caeb92b MDL-39016 theme_bootstrapbase: Added login info and home link to footer in both boostrapbase & clean layout/general.php 2013-06-10 16:04:22 +12:00
Mark Nelson 49acbbad2f MDL-40009 notes: corrected the form element names passed to setType 2013-06-10 15:55:53 +12:00
Sam Hemelryk afe247a0ca Merge branch 'w24_MDL-39549_m25_cohortsearch' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-10 15:48:11 +12:00
Sam Hemelryk f7c2942961 Merge branch 'MDL-39971_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-06-10 15:09:34 +12:00
Dan Poltawski 6f4232974e Merge branch 'wip-MDL-39824-m25' of http://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-06-10 10:54:27 +08:00
Sam Hemelryk f981643f58 Merge branch 'MDL-39978_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-06-10 14:44:40 +12:00
Sam Hemelryk 2f8602990f Merge branch 'w24_MDL-32480_m25_imscp' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-10 14:41:07 +12:00
Sam Hemelryk 7174920aaa MDL-39824 theme: tweaking upgrade note version 2013-06-10 14:34:25 +12:00
Jason Fowler 57ecff6356 MDL-39608 - Bootstrap - Chaning the thresholds and width values for the Form labels
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-06-10 14:28:54 +12:00
AMOS bot 2d69af043d Automatically generated installer lang files 2013-06-10 00:39:09 +00:00
Andrew Davis a1d43d9e4f MDL-36090 core_grade: added logging of overriding of student grades 2013-06-10 12:35:03 +12:00
Sam Hemelryk 08c2a3ca1f Merge branch 'wip-MDL-40088-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-06-10 12:14:04 +12:00
Jason Fowler fbc635e400 MDL-39227 - SCORM - repositioning the navigation panel to be visible in all themes at all resolutions 2013-06-10 11:59:36 +12:00
Sam Hemelryk 00afef17bb Merge branch 'MDL-39979-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-06-10 11:33:59 +12:00
Sam Hemelryk c174a19207 MDL-40100 cache: removed unneeded includes from add instance forms 2013-06-10 10:26:27 +12:00
Sam Hemelryk d89fbe0285 MDL-39871 themes: can now specify regions to swap when using rtl langs
Conflicts:
	lib/pagelib.php
2013-06-10 09:31:05 +12:00
Sam Hemelryk ddf1b0741d MDL-39824 theme: changes recorded in theme/upgrade.txt 2013-06-10 09:29:58 +12:00
Sam Hemelryk dac7c261ca MDL-39824 output: fixed bug when moving blocks with rtl lang 2013-06-10 09:29:58 +12:00
Sam Hemelryk 8504444307 MDL-40089 theme_clean: simplified layouts and converted to new OUTPUT API 2013-06-10 09:29:58 +12:00
Sam Hemelryk 602255df1a MDL-40089 theme_clean: moved general to columns3.php as prep 2013-06-10 09:29:58 +12:00
Sam Hemelryk ee7a52ae91 MDL-39842 js: fixed block drag and drop 2013-06-10 09:29:58 +12:00
Sam Hemelryk 6964e6a580 MDL-39824 theme_bootstrapbase: converted $PAGE use to new $OUTPUT methods. 2013-06-10 09:29:58 +12:00
Sam Hemelryk 5c8c94eabe MDL-40089 theme_bootstrapbase: moved general to columns3.php as prep 2013-06-10 09:29:57 +12:00
Sam Hemelryk 00f906b114 MDL-39824 output: tidied up output before bootstrap cleaning
Conflicts:
	lib/pagelib.php
2013-06-10 09:29:03 +12:00
Sam Hemelryk 2d28b03d90 MDL-39839 renderer: new methods for calls appearing in theme layouts 2013-06-10 09:28:24 +12:00
Sam Hemelryk 03fa7a2ba3 MDL-39838 renderer: new methods for body classes and id 2013-06-10 09:28:24 +12:00
Sam Hemelryk cd79352fbd MDL-39841 renderer: new method to renderer blocks with predictable structure 2013-06-10 09:28:24 +12:00
Matteo Scaramuccia f082c5e390 MDL-40002 Files: ETag value must be a quoted-string.
ETag value must be double quoted, http://tools.ietf.org/html/rfc2616#section-3.11.
More details about potential impacts in MDL-39832: shortly, at least when using
HTTP Partial GET Requests (HTTP Status: 206) plus X-Sendfile HTTP Header.
In this commit, the impact is to be RFC2616 compliant when using the ETag Header.
2013-06-09 10:14:02 +02:00
Tim Hunt 266ceb16a6 MDL-22390 autolink filter: handle URLs in brackets better.
This breaks some legitimate URLs like
http://en.wikipedia.org/wiki/Slash_(punctuation).
This is a necessary trade-off. Many other web systems do not handle that
case correctly either. The work-around it so escape the ) as %29.

This commit also improves the way the unit tests for this work.

It also fixes a couple of other tricky cases that were spotted in
the forums while this was being discussed. See the new test cases.
2013-06-08 17:28:53 +01:00
Gareth J Barnard 35b76a3507 MDL-39798 theme_bootstrapbase: Improve layout for course participation reports. 2013-06-08 13:55:22 +01:00
Petr Škoda 06de509918 MDL-39096 fix obfuscate_text() utf-8 compatibility 2013-06-07 22:43:26 +02:00
Petr Škoda 788e1924a2 MDL-39549 fix cohort search in course categories 2013-06-07 22:07:53 +02:00
Gareth J Barnard 9bc4a4cc79 MDL-40087 theme_bootstrapbase: Turn editing on button misaligned on nav bar. 2013-06-07 18:15:34 +01:00
Petr Škoda d98b9a945e MDL-28394 fix enrolment method restore logic
This patch fixes:
* missing enrolment methods after 1.9 backup restore - defaults are added
* enrolment methods are restored only when users option is enabled
* manual enrolment override option is disabled if users not available
2013-06-07 10:03:25 +02:00
Petr Škoda 4ab6c6fbc0 MDL-32480 allow external https links in IMSCP too 2013-06-07 09:58:54 +02:00
Nicolas Dunand a2ec961309 MDL-32480 fix display of IMS content packages with external links 2013-06-07 09:58:53 +02:00
Marina Glancy 86882b6dfe MDL-40088 fixed bug with not visible course section 2013-06-07 13:58:57 +10:00
Dan Marsden ff3a54a5f7 MDL-37968 course_overview: add dim class to hidden courses for teachers. 2013-06-07 14:39:29 +12:00
Mary Evans 82887b29e8 MDL-39338 core_question: Make history box a .well 2013-06-06 22:57:09 +01:00
Matteo Scaramuccia 52286ac358 MDL-39832 Files: Fixed ETag format according with RFC2616.
ETag must be double quoted,
http://tools.ietf.org/html/rfc2616#section-3.11:

      entity-tag = [ weak ] opaque-tag
      weak       = "W/"
      opaque-tag = quoted-string
2013-06-06 23:11:15 +02:00
Matteo Scaramuccia d618e3c07d MDL-39832 Files: Revert MDL-39688 commit, 161be92065
MDL-39688 has been successful in providing a solution for the issue but further
investigations done in MDL-39832 have got the evidence that the given solution
is more likely a workaround.
2013-06-06 23:11:14 +02:00
Oleg Sychev 14e5c99960 MDL-40013 Easier to override saving question hints
This adds 3 new methods, called from question_type::save_hints,
to make it easier for different question types to overload this
functionality without duplicating code.

Question types that will benefit from this change include
oumultiresponse, ddmarker, preg and correctwriting.
2013-06-06 19:59:33 +03:00
Frederic Massart 333df7d951 MDL-39979 navigation: Remove the use of an undefined variable 2013-06-06 14:53:27 +08:00
Dan Poltawski 6cf8499253 MDL-26925 User selector: Set label when no results
Thanks to Jonathon Fowler for the fix!
2013-06-06 14:09:39 +08:00
Frederic Massart a3fa82636d MDL-40036 user: Respect capability to ignore user quota 2013-06-06 12:43:34 +08:00
Dan Poltawski 1430866232 weekly release 2.5+ 2013-06-06 12:01:38 +08:00
Dan Poltawski 1c437c97f7 Merge branch 'install_25_STABLE' of git://git.moodle.cz/moodle-install into MOODLE_25_STABLE 2013-06-06 11:55:07 +08:00
Dan Poltawski 0fbfae718d MDL-25901 rss: do not copyright html tag
They copyright field does not permit html, it should be plain text
2013-06-06 11:30:27 +08:00
Eloy Lafuente (stronk7) 61899ac202 Merge branch 'wip-MDL-38773-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-06-05 19:32:14 +02:00
Eloy Lafuente (stronk7) 92c46e00eb Merge branch 'w23_MDL-39588_m25_ociinstall' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-05 16:24:22 +02:00
Eloy Lafuente (stronk7) 1127607bce Merge branch 'w23_MDL-39503_m25_signup' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-05 16:18:01 +02:00
Eloy Lafuente (stronk7) ef580461f6 Merge branch 'wip-MDL-21097-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-06-05 10:36:22 +02:00
Dan Poltawski 2d0faffb7f MDL-39940 tags: missing setType call 2013-06-05 16:17:26 +08:00
Marina Glancy f9d68a11da MDL-21097 Correctly check capabilities for frontpage editing mode 2013-06-05 18:09:34 +10:00
Dan Poltawski 0a8985843e MDL-39964 report_progress: don't browser sniff for SVG support
Use feature detection, its more robust and better practice.
2013-06-05 15:42:26 +08:00
Dan Poltawski e0e6015416 Merge branch 'wip-MDL-21097-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-06-05 13:10:18 +08:00
Rossiani Wijaya 9db4dcb68b MDL-39773 bootstrapbase: add style for .centerpadded.
Relocate .centerpadded styling from standard to base themes
2013-06-05 12:50:15 +08:00
Marina Glancy 6b52abc0af MDL-21097 corrected course editing roles 2013-06-05 14:27:50 +10:00
Mary Evans 179fbc7f11 MDL-39977 theme_bootstrapbase: Changes the way Clean theme's login takes its navbar styles from Bootstrapbase.
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-06-05 10:13:39 +08:00
Marina Glancy 28ce5653c0 MDL-38773 Purge coursecat cache on course restore 2013-06-05 12:05:05 +10:00
Brian King c017ccff4c MDL-39409 auth/cas pass web proxy settings along to phpCAS 2013-06-05 02:46:25 +02:00
Eloy Lafuente (stronk7) ea85ee6f63 Merge branch 'w23_MDL-39416_m25_pagelog' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-05 02:43:48 +02:00
AMOS bot 2fb98d4bc0 Automatically generated installer lang files 2013-06-05 00:39:45 +00:00
Dan Poltawski 9a0e9776c0 MDL-39968 bootstrapbase: uses non-standard browser sniffing
Also theme_clean does the same sniffing, but is not necessary as its
included by bootstrapbase
2013-06-05 02:34:13 +02:00
Eloy Lafuente (stronk7) 832aa7eb71 Merge branch 'MDL-38731-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-06-05 02:30:56 +02:00
Eloy Lafuente (stronk7) 0e73df9df6 Merge branch 'MDL-37332-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-06-05 02:27:35 +02:00
Matteo Scaramuccia ab8e75ef40 MDL-38545 Reports: PHP Strict Standards error in graph.php 2013-06-05 02:23:05 +02:00
Eloy Lafuente (stronk7) ef8a1c4908 Merge branch 'MDL-39790_master' of git://github.com/totara/openbadges into MOODLE_25_STABLE 2013-06-05 01:45:28 +02:00
Eloy Lafuente (stronk7) 0f51a82bae Merge branch 'wip-MDL-21097-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-06-05 01:43:11 +02:00
Mary Evans 358544f9b7 MDL-40018 theme_sky_high: Fixed footer in admin pages. 2013-06-05 00:18:33 +01:00
Eloy Lafuente (stronk7) 36e5df06b3 MDL-39723 prevent update_courses() bad habits.
All the external functions end calling require_login() that is
always in charge of setting the $COURSE global. This is not a
problem, but in the case of core_course_external::update_courses()
testing, where we are, in the same "request", both setting and getting
the $COURSE information and it's clearly outdated, so the test fails.

Alternative solution would be to modify the external function to ensure
that, after updating a course, $COURSE is also updated with the changes
but it does not seem to be necessary for "normal" usage (both UI/WS POVs).
2013-06-04 21:49:35 +02:00
Eloy Lafuente (stronk7) 8c8b3eba24 Merge branch 'MDL-39723-m25' of git://github.com/sammarshallou/moodle into MOODLE_25_STABLE 2013-06-04 17:48:57 +02:00
Gareth J Barnard faccb2ba9f MDL-39820 theme_bootstrapbase: Fix form button alignment for badges. 2013-06-04 11:17:23 +01:00
Dan Poltawski bf2360c597 Merge branch 'MDL-39945_25' of git://github.com/timhunt/moodle into MOODLE_25_STABLE 2013-06-04 15:54:01 +08:00
Dan Poltawski e7bb4b1ee7 Merge branch 'MDL-39835_M25' of github.com:lazydaisy/moodle into MOODLE_25_STABLE 2013-06-04 14:43:13 +08:00
Dan Poltawski 2b7e18fded Merge branch 'wip-MDL-39819_M25' of git://github.com/gjb2048/moodle into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-06-04 14:38:36 +08:00
Marina Glancy f85cb076aa MDL-39870 correctly determine whether activity is resource or module 2013-06-04 14:14:39 +08:00
Dan Poltawski 836dab79c0 MDL-39931 less: recompile with whitespace removed 2013-06-04 14:09:28 +08:00
Dan Poltawski 2fdfdd49d4 Merge branch 'MDL-39931-M25' of github.com:lazydaisy/moodle into MOODLE_25_STABLE 2013-06-04 13:32:33 +08:00
Dan Poltawski cb1318754e Merge branch 'MDL-39536-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-06-04 13:19:16 +08:00
Frederic Massart 491e196107 MDL-39536 completion: Unit tests for get_activities and has_activities 2013-06-04 12:58:03 +08:00
Frederic Massart 13f73be25b MDL-39536 completion: Prevent DB call when fetching activities 2013-06-04 12:58:02 +08:00
David Mudrák 21c4402280 MDL-39939 Fix the basic SCORM report plugin name 2013-06-04 12:27:42 +08:00
Dan Poltawski 2140e5afa4 Merge branch 'wip-mdl-39827-m25' of git://github.com/rajeshtaneja/moodle into MOODLE_25_STABLE 2013-06-04 11:29:57 +08:00
Dan Poltawski acae4313c8 Merge branch 'MDL-39317-25' of git://github.com/damyon/moodle into MOODLE_25_STABLE 2013-06-04 11:26:33 +08:00
Frederic Massart 16725a78d0 MDL-39865 navigation: Removed unaccessible repositories node
A user is not allowed to edit another user's repositories, in any
circumstances. The repositories node under 'Profile setting for X'
does not make sense under those conditions.
2013-06-04 11:14:02 +08:00
Frederic Massart 3e17b1c4a7 MDL-39865 navigation: 'Profile settings for ...' always displayed
Before this patch, 'Profile settings for X' would only be displayed
if X can access the course, which means that if the course is hidden
the node would be hidden as well. We changed this so that the user
needs to be enrolled in the course.
2013-06-04 11:14:02 +08:00
Dan Poltawski e19a07bfcb Merge branch 'MDL-39743-25' of git://github.com/damyon/moodle into MOODLE_25_STABLE 2013-06-04 11:03:45 +08:00
Dan Poltawski c687e8d741 Merge branch 'wip_25_mdl-34085' of https://github.com/iarenaza/moodle into MOODLE_25_STABLE 2013-06-04 10:42:55 +08:00
AMOS bot 09c0ea1f39 Automatically generated installer lang files 2013-06-04 00:46:34 +00:00
Eloy Lafuente (stronk7) 1fe7be205c Merge branch 'wip-MDL-39801-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-06-04 01:58:27 +02:00
Eloy Lafuente (stronk7) 6399a82028 MDL-39764 style: phpdoc changed to inline comments 2013-06-04 01:43:35 +02:00
Eloy Lafuente (stronk7) 8a2cee5091 Merge branch 'wip-MDL-39764_M25_3' of git://github.com/gjb2048/moodle into MOODLE_25_STABLE 2013-06-04 01:43:28 +02:00
Eloy Lafuente (stronk7) ca7f399be7 Merge branch 'w23_MDL-39882_m25_behatconfig' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-04 01:32:12 +02:00
Damyon Wiese 6c37003d05 MDL-39821 assign: missing setType with advanced grading 2013-06-04 01:30:20 +02:00
Eloy Lafuente (stronk7) d1963974a9 MDL-39465 Show env. info instead of part twice. 2013-06-04 00:50:55 +02:00
Gareth J Barnard 3b4752e1f2 MDL-39764 course_format: Allow courses to have numsections > maxsections. 2013-06-03 23:43:24 +01:00
Eloy Lafuente (stronk7) 618737d7e9 Merge branch 'MDL-39936-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-06-04 00:05:04 +02:00
Eloy Lafuente (stronk7) 06ab9b8888 Merge branch 'w23_MDL-39465_m25_environment' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-06-04 00:00:44 +02:00
Justin Filip c7abb11786 MDL-39166 auth_ldap Add triggers for user created/updated events. 2013-06-03 23:55:30 +02:00
Eloy Lafuente (stronk7) 73f8ab649f Merge branch 'wip-MDL-39710-m25' of git://github.com/marinaglancy/moodle into MOODLE_25_STABLE 2013-06-03 23:22:17 +02:00
Eloy Lafuente (stronk7) 189590bb37 Merge branch 'MDL-39932_25' of git://github.com/grabs/moodle into MOODLE_25_STABLE 2013-06-03 19:10:39 +02:00
Albert Gasset 827e54dde5 MDL-39487 mod/assign: fixed ID number of grade item changing 2013-06-03 19:05:55 +02:00
Eloy Lafuente (stronk7) 42a9e3efc2 Merge branch 'MDL-39987_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE 2013-06-03 16:07:47 +02:00
Mary Evans f58fadfeba MDL-39987 theme_bootstrapbase: Fixed menunode text in renderers/core_renderer.php. 2013-06-02 23:17:14 +01:00
Petr Škoda f498ae7652 MDL-39416 do not try to get detailed perflog info before PAGE int 2013-06-02 13:35:40 +02:00
Petr Škoda dd85f5aed0 MDL-39588 require MOODLELIB Oracle package
Previously it was kind of optional, but it is now required. We also attempt to install it automatically now.
2013-06-02 11:14:10 +02:00
Mary Evans b91fcb9094 MDL-39835 theme_sky_high: Fix for footer to display correctly in higher resolutions. 2013-06-01 21:53:19 +01:00
Gareth J Barnard dfb83eb132 MDL-39819 theme_bootstrapbase: Fix icon alignment in filepicker. 2013-05-31 22:32:03 +01:00
Petr Škoda 1e558fdf66 MDL-39465 detect environment problems in tests
This should help explain why something else fails.
2013-05-31 22:03:15 +02:00
Tim Hunt 7dad4a5e59 MDL-39978 Essays with files break each attempt builds on last 2013-05-31 20:48:03 +01:00
Tim Hunt 8b2e668a19 MDL-39971 each attempt builds on last broken for previews. 2013-05-31 20:32:52 +01:00
Petr Škoda 65380ecd0a MDL-39503 tell robots to not index login and signup page
This should partially prevent people from googling moodle sites that allow signup. Please note you can not use login block if because it would still disclose the signup link.
2013-05-31 21:26:23 +02:00
Petr Škoda b5ce3bc8f4 MDL-39882 add required behat settings to config-dist 2013-05-31 21:09:05 +02:00
Marina Glancy 51173470b6 MDL-39710 Don't display rubric and guide preview unless option checked 2013-05-31 16:13:18 +10:00
Russell Boyatt 8df87c160f Fixing MDL-39710: setting to limit student access to rubric now checked. 2013-05-31 16:13:13 +10:00
Dan Poltawski e5326193bf MDL-38731 course: split course group settings header
Allow translators to translate the heading differently.

AMOS BEGIN
  CPY [groups,group],[groupsettingsheader,group]
AMOS END
2013-05-31 12:04:51 +08:00
Dan Poltawski e9fd6e5dd6 MDL-37332 portfolio: don't add double slashes
get_filepath() always returns trailing slash.

This breaks windows export - thanks to Jason Platts
2013-05-31 11:52:34 +08:00
Marina Glancy a74edf03ad MDL-39801 navigation_node::remove does not allow to insert nodes afterwards 2013-05-31 13:51:13 +10:00
Marina Glancy bd205fa484 MDL-39801 navigation_node::remove fails if first child does not have a key 2013-05-31 13:51:13 +10:00
Marina Glancy 93ac52a9f3 MDL-21097 Allow user to change current section if he does not have any other manageing capability 2013-05-31 13:20:16 +10:00
Marina Glancy db8d852af9 MDL-21097 Correctly check capabilities for course settings items
- Make sure that items in course settings (and frontpage settings) are shown depending on user capabilities
- Make sure user is able to turn editing on on the page even if he has only limited number of seciton/modules managing capabilities
2013-05-31 13:20:10 +10:00
Dan Poltawski 068373c86a MDL-33562 lib: remove deleted user tokens 2013-05-31 10:23:51 +08:00
Dan Poltawski 4c4c90f4b0 MDL-33562 lib: remove private keys when user deleted 2013-05-31 10:22:02 +08:00
AMOS bot a270a2c129 Automatically generated installer lang files 2013-05-31 00:43:06 +00:00
Adam Olley 096707c01d MDL-39947 mod_forum: Add safety check to variable assignment when counting unread posts 2013-05-31 09:50:05 +09:30
Andreas Grabs b4de832553 MDL-39932 mod_feedback - Mapping Feedback when Course is Deleted - thx to David N. Johnson 2013-05-30 23:11:37 +02:00
Tim Hunt f0dc1a71c1 MDL-39945 qtype multichoice was not comparing blank responses correctly. 2013-05-30 19:22:21 +01:00
Iñaki Arenaza 2f467a82a1 MDL-34085 Fix the backup options names in core_course_duplicate_course
Fix the option names to match those used by the backup subsystem.
2013-05-30 17:45:30 +02:00
Mary Evans 91cf8cc82c MDL-39931 theme_bootstrapbase: ported invisiblefieldset css rules from theme/base/core.css to less/moodle/core.css 2013-05-30 15:51:16 +01:00
Dan Poltawski 2e80405940 MDL-39936 upgrade: 2.5.0 line incorrectly positioned 2013-05-30 13:40:28 +08:00
Damyon Wiese f36066fa9e weekly release 2.5+ 2013-05-30 12:09:08 +08:00
Damyon Wiese a4e0171b2c Merge branch 'install_25_STABLE' of git://git.moodle.cz/moodle-install into MOODLE_25_STABLE 2013-05-30 11:27:46 +08:00
AMOS bot 8352a1b138 Automatically generated installer lang files 2013-05-30 00:38:21 +00:00
Damyon Wiese 028b56f875 MDL-39317 assign: Fix for submitted filter on grading table.
Some old upgraded assignments have no timecreated column so use
a different one to check for a valid submission.
2013-05-29 14:50:42 +08:00
Ashley Holman e9efc2baa2 MDL-39743 assign: Fix missing capability check for "grant extension" 2013-05-29 12:04:22 +08:00
AMOS bot 7e720621ec Automatically generated installer lang files 2013-05-29 00:39:21 +00:00
Yuliya Bozhko 626c84bca9 MDL-39790 Add badges block to the course page 2013-05-29 09:42:11 +12:00
Eloy Lafuente (stronk7) 4bc4844d5b Merge branch 'w22_MDL-39676_m25_whereparam' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-05-28 15:33:33 +02:00
sam marshall 695f6f3c23 MDL-39723 Remove unnecessary queries for COURSE, SITE 2013-05-28 13:16:03 +01:00
Damyon Wiese f4075573b9 MDL-39477: Remove some unused instances of $CFG
Also change @since tags to 2.5.1 because this will be backported.
2013-05-28 11:11:42 +08:00
David Monllao a13cbfb3e7 MDL-39702 generators: Adding MOODLE_INTERNAL
As discussed generators should include MOODLE_INTERNAL
as they make use of CFG and they don't make sense without
requiring config.php.
2013-05-28 11:10:35 +08:00
Frederic Massart 799dbbfbaa MDL-39477 repository: Tests use data generator 2013-05-28 11:08:58 +08:00
Frederic Massart e5c6694de8 MDL-39477 repository: Introducing data generators for repositories 2013-05-28 11:08:54 +08:00
Damyon Wiese d3aeeb93c2 Merge branch 'w22_MDL-39802_m25_deletedusers' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-05-28 09:56:08 +08:00
AMOS bot f5940428a9 Automatically generated installer lang files 2013-05-28 00:38:15 +00:00
Eloy Lafuente (stronk7) e58af1dfcd Merge branch 'wip-MDL-39836_M25' of git://github.com/gjb2048/moodle into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-05-28 01:24:58 +02:00
Eloy Lafuente (stronk7) 4f0d6118ff Merge branch 'wip-MDL-39456-m25' of git://github.com/samhemelryk/moodle into MOODLE_25_STABLE 2013-05-28 01:02:34 +02:00
Eloy Lafuente (stronk7) 8b77e81201 Merge branch 'MDL-39853_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-05-28 00:57:06 +02:00
Eloy Lafuente (stronk7) d6e2b0a03e Merge branch 'MDL-39795_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-05-28 00:45:02 +02:00
Damyon Wiese a665577b37 Merge branch 'MDL-39686_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-05-27 16:28:48 +08:00
Damyon Wiese f32e55c8d7 Merge branch 'MDL-39680-M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-05-27 16:21:44 +08:00
Damyon Wiese 6a3a3bd868 Merge branch 'MDL-39640-master-int' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-05-27 16:14:59 +08:00
Kordan f70d382498 MDL-39194 theme_formal_white: cleaned the category page showing course listing 2013-05-27 15:23:08 +08:00
David Monllao e132b54a6a MDL-39853 behat: Useful info for $CFG->behat_config setting 2013-05-27 15:14:06 +08:00
David Monllao c0b59154ba MDL-39686 behat: Add option to restart the browser 2013-05-27 15:06:15 +08:00
David Monllao 268cb03e2d MDL-39686 behat: Adding into to config-dist.php 2013-05-27 15:06:09 +08:00
Dan Poltawski ad97a56875 MDL-39806 theme_bootstrapbase: run less with --compress 2013-05-27 14:42:44 +08:00
Dan Poltawski 8d94299b02 Merge branch 'MDL-39806_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE 2013-05-27 14:36:55 +08:00
David Monllao 0653761da2 MDL-39795 behat: Adapting features to consider spaces 2013-05-27 14:25:40 +08:00
David Monllao e489df87bf MDL-39795 behat: Improving find-texts-in-page-contents performance 2013-05-27 14:25:34 +08:00
Marina Glancy 87a445ec70 MDL-39785 bug fix: filter_activitynames was not applied correctly 2013-05-27 14:17:15 +08:00
Dan Poltawski 121e2492e8 Merge branch 'MDL-38239-moodle25' of git://github.com/StudiUM/moodle into MOODLE_25_STABLE 2013-05-27 14:13:36 +08:00
Dan Poltawski 6c16494f03 Merge branch 'w22_MDL-39688_m25_etag' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-05-27 13:43:37 +08:00
Dan Poltawski 191e70c2e2 Merge branch 'w22_MDL-38408_m25_paypalcost' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-05-27 13:05:14 +08:00
Yuliya Bozhko 7291b026a0 MDL-39778 badges: Fix missing library error in delete_course() 2013-05-27 12:00:38 +08:00
Rajesh Taneja df4da0fe79 MDL-39827 course: Trigger invalidate cache event while changing sort-order of category 2013-05-27 10:55:48 +08:00
Dan Poltawski ceb4030763 Merge branch 'MDL-39768_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-05-27 10:18:32 +08:00
Gareth J Barnard 69ecf8c0a9 MDL-38856 theme_bootstrapbase: Inverse user name text unreadable on nav bar 2013-05-27 02:09:01 +01:00
Mary Evans 039c78702d MDL-39680 theme_bootstrapbase: Fixed footer alignment in less/moodle/debug.less
Squashed commit of the following:

commit 58f5e063a8b333c184ca83ece7f61ec40d2a5080
Author: Mary Evans <lazydaisy@visible-expression.co.uk>
Date:   Sun May 26 13:45:11 2013 +0100

    MDL-39680 theme_bootstrapbase: Fixed footer alignment in less/moodle/debug.less

commit 575594257a9f4fab75977d2334d07659abea0b65
Author: Mary Evans <lazydaisy@visible-expression.co.uk>
Date:   Sun May 26 02:07:00 2013 +0100

    MDL-39680 theme_bootstrapbase: Centralised text in footer.
2013-05-26 13:55:45 +01:00
Petr Škoda 7fa470de03 MDL-38408 always validate PayPal dates and cost, improve float formatting 2013-05-25 22:48:44 +02:00
Mary Evans 6ceb6eb672 MDL-39806 theme_bootstrapbase: Fix for coursesearchbox label alignment. 2013-05-25 17:16:39 +01:00
Petr Škoda 644b1df502 MDL-39676 improve get_role_users() unit tests 2013-05-25 10:10:17 +02:00
Petr Škoda 161be92065 MDL-39688 do not set Etag when sending http ranges 2013-05-25 09:12:03 +02:00
Petr Škoda 5878ac3957 MDL-39802 ignore deleted users in meta enrolments 2013-05-24 21:28:38 +02:00
Petr Škoda 761227cfc6 MDL-39802 ignore deleted users in cohort enrolments 2013-05-24 21:28:38 +02:00
Petr Škoda 97d68b5652 MDL-39802 ignore deleted users in category enrolments 2013-05-24 21:28:37 +02:00
Petr Škoda 3ecf7ddd15 MDL-39802 fix sloppy user deleting and creating in imsenterprise plugin 2013-05-24 21:28:37 +02:00
Petr Škoda b6ef79950e MDL-39802 add cli script for fixing of all deleted users
Use this script if something just set the user.deleted flag instead of calling the delete_user() method.
2013-05-24 21:28:37 +02:00
Damyon Wiese f65261d096 weekly release 2.5+ 2013-05-24 13:26:46 +08:00
Damyon Wiese 93f645f0ae Merge branch 'install_25_STABLE' of git://git.moodle.cz/moodle-install into MOODLE_25_STABLE 2013-05-24 13:12:11 +08:00
Sam Hemelryk e5184cac0e MDL-39456 cachestore_file: added reference to global $CFG
By holding onto a reference of the global $CFG object we
can be sure that it isn't destroyed before we are done
with it.
This allows for caches to be used within destructors for
purposes such as delayed writes.
2013-05-24 09:54:18 +12:00
Marina Glancy caaad8b08d MDL-39177 make sure we don't remove existing directories when cleaning up unzip 2013-05-23 15:59:53 +02:00
AMOS bot cb033b9fab Automatically generated installer lang files 2013-05-22 08:26:02 +00:00
David Monllao 4f629bc677 MDL-39768 behat: Adding focused panels CSS selector 2013-05-22 15:11:55 +08:00
Eloy Lafuente (stronk7) d917dc9e40 MDL-36482 Fix slipped error, thanks Petr! 2013-05-22 04:14:01 +02:00
Damyon Wiese d74f740722 Merge branch 'MDL-39697-M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE 2013-05-22 09:03:31 +08:00
Marina Glancy 6168502474 MDL-39177 Updating userid when file is overwritten 2013-05-22 02:25:18 +02:00
Marina Glancy 751cebfc3d MDL-39177 More comments about confusing files.source field 2013-05-22 02:25:12 +02:00
Marina Glancy acfd39cbf8 MDL-39177 New function file_storage::get_unused_dirname() 2013-05-22 02:25:07 +02:00
Marina Glancy 2efc8ff39f MDL-39177 Ensure files are overwritten correctly on unzip 2013-05-22 02:25:02 +02:00
Marina Glancy 2a0b243137 MDL-39177 Perform all checks on draftfile area before saving the files 2013-05-22 02:24:56 +02:00
Marina Glancy b8aca19538 MDL-39177 Remove code duplication 2013-05-22 02:24:50 +02:00
Marina Glancy 2fbfedb310 MDL-39177 Update file in filearea only if original is present
Now when file was deleted in filemanager and new file with the same file was uploaded the references will be converted to copies exactly like UI warns in filemanager.
Also do not delete original information from draftfiles.
2013-05-22 02:24:40 +02:00
Marina Glancy 6c43ee510f MDL-39177 Discard file origin when moving/renaming a file in filemanager
Created one function that handles file update to be used from both JS and nonJS filepicker
2013-05-22 02:24:32 +02:00
Marina Glancy d262212a1f MDL-39177 Original info is not preserved when overwriting a file in filemanager
original file location is used by filemanager to indicate that file is a source of reference and file the list of referencing files
2013-05-22 02:24:24 +02:00
Marina Glancy d50f747fd8 MDL-39177 File reference is not updated when overwriting the file 2013-05-22 02:24:13 +02:00
Marina Glancy d95506e05a MDL-33719 When overwriting a file the filemanager is not refreshed 2013-05-22 02:24:08 +02:00
Gilles-Philippe Leblanc f7d180a7fb MDL-38239 gradebook: Importing grades from a .txt file with commas for decimals causes an error 2013-05-21 14:43:07 -04:00
Marina Glancy 91af4fa5bf MDL-39720 added missing setType() in moodleform 2013-05-21 12:30:21 +08:00
Dan Poltawski b051261ecc Merge branch 'MDL-39753_25' of git://github.com/stronk7/moodle into MOODLE_25_STABLE 2013-05-21 11:00:32 +08:00
Dan Poltawski aeaf5c1337 MDL-39323 auth_ldap: fix savepoint version 2013-05-21 10:52:44 +08:00
Iñaki Arenaza 9f13f53393 MDL-39323 Make sure start_tls config value is defined
This has been introduced in 2.5, so when upgrading from previous versions
make sure we set a default value. Otherwise, we get a notice about it
being undefined when we try to use it (and we always try to use it!).
2013-05-21 10:44:11 +08:00
Russell Smith 0bc310eb5a MDL-36482 activities block: Allow mod display without intro's 2013-05-21 02:27:58 +02:00
Eloy Lafuente (stronk7) ab6a0ac4f7 Merge branch 'MDL-39758_M25' of git://github.com/lazydaisy/moodle into MOODLE_25_STABLE 2013-05-21 01:48:38 +02:00
David Monllao 18003f2adb MDL-39638 behat: New step to collapse nodes based on the expand nodes
Also updating steps with a collapse behaviour.
2013-05-21 01:00:36 +02:00
Jayesh Anandani 2ab5928066 MDL-26120 mod_forum: use correct object 2013-05-21 00:55:17 +02:00
Eloy Lafuente (stronk7) e3c1bd2593 Merge branch 'MDL-39717_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-05-21 00:44:22 +02:00
Jerome Mouneyrac 99f5bad554 MDL-31209 web service error message: Indication about the service not containg the web service function is confusing 2013-05-20 19:06:59 +02:00
Ruslan Kabalin 666117e830 MDL-39761: mod_assign: Always check submission plugin status and visibility. 2013-05-20 16:32:04 +01:00
Eloy Lafuente (stronk7) 9b19f3f4fb MDL-39753 Add 2.5.0 upgrade line 2013-05-20 15:34:44 +02:00
Mary Evans b6d07f25a1 MDL-39758 theme_bootatrapbase: Added missing layout/embedded.php. 2013-05-20 13:04:44 +01:00
Dan Poltawski e90eb091c5 Merge branch 'w18_MDL-39374_m25_folderlog' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-05-20 17:58:29 +08:00
Damyon Wiese 5cc84acabe Merge branch 'MDL-38498-25' of git://github.com/FMCorz/moodle into MOODLE_25_STABLE 2013-05-20 16:12:34 +08:00
Frederic Massart 543b5feae0 MDL-39719 course: Pointing to wrong category string in requests 2013-05-20 16:10:07 +08:00
Frederic Massart cdd041e631 MDL-38498 repository: Unit tests for repository::check_capability() 2013-05-20 16:00:11 +08:00
Tim Hunt 6d393bd97c MDL-27748 question: grade options should be localised.
question_bank::fraction_options should use format_float to display
decimal pionts correctly.
2013-05-20 15:47:22 +08:00
Tim Hunt f8aec131e9 MDL-39728 List all the classes in question/type/questionbase.php
This should make it easier for people to understand the type hierarchy.
2013-05-20 15:28:59 +08:00
Troy Lee 62cf9a1d2a MDL-36020 overview/report: fix quiz regrade session lock 2013-05-20 12:42:38 +08:00
Damyon Wiese 76f881c83a Merge branch 'MDL-39363-master' of git://github.com/ankitagarwal/moodle into MOODLE_25_STABLE 2013-05-20 12:13:09 +08:00
Damyon Wiese c4500213d6 Merge branch 'MDL-39528_25' of git://github.com/dmonllao/moodle into MOODLE_25_STABLE 2013-05-20 12:06:51 +08:00
Mary Evans 1cdcb6599a MDL-39630 theme_afterburner: Improving the way course/category listings display. 2013-05-20 12:03:00 +08:00
Kordan ff3f1f3ef3 MDL-39198 theme_formal_white: resized and relocated the "Add..." drop down menu of the "Add a block" pseudo block 2013-05-20 11:48:23 +08:00
Frederic Massart b42e6e1c2e MDL-38369 repository: Remove output before redirect 2013-05-20 10:25:34 +08:00
Damyon Wiese d8581a2367 Merge branch 'MDL-28250-25' of git://github.com/danpoltawski/moodle into MOODLE_25_STABLE 2013-05-17 12:11:31 +08:00
David Monllao 236ebcfe78 MDL-39528 behat: Avoid modal window suite failure
Catching JS alerts/confirms exceptions and
auto-accepting them before each test run to
avoid chained scenarios failures.
2013-05-17 12:09:04 +08:00
David Monllao c340dca9b0 MDL-39717 behat: Removing unstable steps and scenarios 2013-05-17 11:48:29 +08:00
David Monllao a3c292ee64 MDL-39717 behat: Add info to experimental steps definitions
JS modal dialogs and drag & drop should be
considered experimental as the steps are not
working as expected in all OS/browser combinations.
2013-05-17 11:48:20 +08:00
Damyon Wiese b7bbb615d7 Merge branch 'w18_MDL-39678_m25_yui' of git://github.com/skodak/moodle into MOODLE_25_STABLE 2013-05-16 15:55:45 +08:00
Mary Evans 9141e05262 MDL-39697 theme_bootstrapbase: Updated $THEME->layouts in config.php to match those in Base theme. 2013-05-16 00:57:40 +01:00
Petr Škoda e9cfbe4290 MDL-39678 fix YUI 20130515 vulnerability 2013-05-15 22:12:12 +02:00
Petr Škoda 2e297423cd MDL-39374 log only real folder edits
Credit goes to Florian Zillner, thanks.
2013-05-15 21:32:27 +02:00
Eloy Lafuente (stronk7) 8daf98a10f NOBUG: Keep backup YYYYMMDD on sync with 2.5 2013-05-14 12:42:15 +02:00
70301 changed files with 1706914 additions and 8407371 deletions
-185
View File
@@ -1,185 +0,0 @@
// 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/>.
/**
* Generates tsconfig.aliases.json for cross-component TypeScript imports.
*
* Moodle ESM source files can import from other components using the alias
* scheme @moodle/lms/<component>/* (e.g. @moodle/lms/core/SomeUtil). This
* file reads the Moodle component registry (.grunt/components.js), finds every
* component that has a js/esm/src/ directory, and writes the corresponding
* TypeScript path mappings to tsconfig.aliases.json.
*
* tsconfig.json extends tsconfig.aliases.json, so TypeScript picks up the
* mappings automatically. The file is skipped if its content is unchanged, to
* avoid unnecessary rebuilds.
*
* This must run before esbuild compilation. The Grunt `jsconfig` task calls
* generateAliases() so that both jsconfig.json and tsconfig.aliases.json are
* kept in sync. The `react` task depends on `jsconfig`, so aliases are always
* up to date before a React build.
*
* @copyright 2026 Adrian Greeve <adrian@moodle.com>
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
import fs from "fs";
import path from "path";
import { createRequire } from "module";
const rootDir = process.cwd();
const tsconfigOut = path.join(rootDir, "tsconfig.aliases.json");
const TS_ALIASES_WARNING =
"// WARNING: Do not edit this file manually. It is generated by `grunt jsconfig`.\n";
/**
* Load Moodle component paths from `.grunt/components.js`.
*
* @returns {Record<string, string>} Map of component paths to component names.
*/
function loadComponentPathMap() {
const require = createRequire(import.meta.url);
// Load Moodle's components data from .grunt/components.js.
const { fetchComponentData } = require(
path.join(process.cwd(), ".grunt", "components.js")
);
// Format: `{ components: { "public/lib": "core", ... } }`.
const componentsData = fetchComponentData().components;
// Expected:
// `{ "public/lib": "core", "public/ai": "core_ai", ... }`.
return componentsData;
}
/**
* Compare two TypeScript `paths` maps for exact equality.
*
* @param {Record<string, string[]>} a First paths map.
* @param {Record<string, string[]>} b Second paths map.
* @returns {boolean} True when keys and values match in order.
*/
function pathsEqual(a, b) {
const aKeys = Object.keys(a);
const bKeys = Object.keys(b);
if (aKeys.length !== bKeys.length) {
return false;
}
for (const key of aKeys) {
if (!Object.prototype.hasOwnProperty.call(b, key)) {
return false;
}
const aArr = a[key] ?? [];
const bArr = b[key] ?? [];
if (aArr.length !== bArr.length) {
return false;
}
for (let i = 0; i < aArr.length; i++) {
if (aArr[i] !== bArr[i]) {
return false;
}
}
}
return true;
}
/**
* Parse JSON content and tolerate line comments.
*
* @param {string} content Raw JSON/JSONC file content.
* @returns {unknown}
*/
function parseJsonWithComments(content) {
const stripped = content
.replace(/^\uFEFF/, "")
.replace(/^\s*\/\/.*$/gm, "");
return JSON.parse(stripped);
}
/**
* Convert JSON output so single-value arrays are rendered on one line.
*
* @param {unknown} obj Data to stringify.
* @returns {string} JSON string with flattened single-value arrays.
*/
function stringifyFlatArrays(obj) {
const json = JSON.stringify(obj, null, 2);
return TS_ALIASES_WARNING + json.replace(/\[\s+\"(.*?)\"\s+\]/g, '["$1"]') + "\n";
}
/**
* Generate `tsconfig.aliases.json` from Moodle component metadata.
*
* Includes core aliases, discovers plugin React source aliases, and skips
* rewriting when aliases have not changed.
*
* @returns {void}
*/
export function generateAliases() {
const componentPathMap = loadComponentPathMap();
// Build TS paths for tsconfig.aliases.json
/** @type {Record<string, string[]>} */
const tsPaths = {
// Always include core alias.
"@moodle/lms/core/*": ["./public/lib/js/esm/src/*"],
};
for (const [componentPath, componentName] of Object.entries(componentPathMap)) {
const runtimeAliasKey = `@moodle/lms/${componentName}/*`;
const targetPattern = `./${path
.join(componentPath, "js", "esm", "src", "*")
.replace(/\\/g, "/")}`;
tsPaths[runtimeAliasKey] = [targetPattern];
}
const tsconfig = {
compilerOptions: { paths: tsPaths },
};
// If tsconfig paths didn't change, skip regeneration
let previousPaths = null;
let hasWarningHeader = false;
if (fs.existsSync(tsconfigOut)) {
try {
const previousContent = fs.readFileSync(tsconfigOut, "utf8");
hasWarningHeader = previousContent.startsWith(TS_ALIASES_WARNING);
const previousTsconfig = /** @type {{compilerOptions?: {paths?: Record<string, string[]>}}} */ (
parseJsonWithComments(previousContent)
);
previousPaths = previousTsconfig.compilerOptions?.paths ?? {};
} catch {
// ignore parse errors and treat as "no previous cache"
previousPaths = null;
}
}
if (previousPaths && hasWarningHeader && pathsEqual(previousPaths, tsPaths)) {
console.log("✓ Generating tsconfig.aliases.json was skipped. No alias modifications detected.");
return;
}
// Write tsconfig.aliases.json
fs.writeFileSync(tsconfigOut, stringifyFlatArrays(tsconfig));
console.log("✓ Generating tsconfig.aliases.json");
}
-324
View File
@@ -1,324 +0,0 @@
// 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/>.
/**
* Core esbuild library for Moodle ESM components.
*
* This is the single source of all build logic. The Grunt tasks
* (.grunt/tasks/react.js) import from here rather than duplicating
* configuration or build steps.
*
* Source layout convention:
* <component>/js/esm/src/**\/*.{ts,tsx} → <component>/js/esm/build/**\/*.js
*
* Exports:
* createBuildConfig(isDev) esbuild config object; pass isDev=true
* to disable minification / add sourcemaps.
* buildPluginComponents(isDev) Glob for every js/esm/src tree across
* core and plugins, compile all in parallel.
* buildSingleFile(filePath, isDev) Compile one source file; used by the
* Grunt watch task on incremental changes.
* watchComponents(isDev) Start esbuild's native watch mode so the
* compiler rebuilds affected files on save.
* resolveComponentPaths(entry) Map an absolute source path to its
* relative input path and output path.
*
* @copyright 2026 Adrian Greeve <adrian@moodle.com>
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
import esbuild from "esbuild";
import { glob } from "glob";
import chalk from "chalk";
import path from "path";
import fs from "fs";
const projectRoot = process.cwd();
/**
* Resolve a path from the current project root.
*
* @param {...string} segments Path segments to resolve.
* @returns {string} Absolute path from project root.
*/
const fromRoot = (...segments) => path.resolve(projectRoot, ...segments);
/**
* Create an incremental dot progress indicator.
* Prints one dot per completed build and wraps lines for readability.
*
* @param {number} total Total number of items to build.
* @returns {{ start: () => void, tick: () => void, succeed: (msg: string) => void, fail: (msg: string) => void }}
*/
function createDotProgress(total) {
const dotsPerLine = 60;
let printed = 0;
return {
start: () => {
process.stdout.write(`${chalk.cyan("Building")} `);
},
tick: () => {
printed++;
process.stdout.write(chalk.cyan("."));
if (printed % dotsPerLine === 0 && printed < total) {
process.stdout.write(` ${chalk.dim(`[${printed}/${total}]`)}\n`);
}
},
succeed: (msg) => {
process.stdout.write(` ${chalk.dim(`[${printed}/${total}]`)}\n`);
process.stdout.write(`${chalk.green("✓")} ${msg}\n`);
},
fail: (msg) => {
process.stdout.write(` ${chalk.dim(`[${printed}/${total}]`)}\n`);
process.stdout.write(`${chalk.red("✗")} ${msg}\n`);
},
};
}
/**
* Build a single React component entry file.
*
* @param {string} entry Absolute entry file path.
* @param {import('esbuild').BuildOptions} buildConfig Shared esbuild configuration.
* @returns {Promise<{file: string, output?: string, error: Error|null}>}
*/
async function buildComponent(entry, buildConfig) {
const resolved = resolveComponentPaths(entry);
if (!resolved) {
return { file: entry, error: new Error(`Unknown path pattern: ${entry}`) };
}
const { file, output } = resolved;
fs.mkdirSync(path.dirname(output), { recursive: true });
try {
await esbuild.build({
...buildConfig,
entryPoints: [entry],
outfile: output,
});
return { file, output, error: null };
} catch (error) {
return { file, error: error instanceof Error ? error : new Error(String(error)) };
}
}
/**
* Resolve source and output paths for a component entry.
*
* @param {string} entry Absolute component source path.
* @returns {{file: string, output: string} | null} Relative file info and output path, or null for unsupported paths.
*/
export function resolveComponentPaths(entry) {
const rel = path.relative(projectRoot, entry);
if (rel.includes(path.join('esm', 'src'))) {
const [part, rawFile] = rel.split(path.join('esm', 'src'));
const file = rawFile.replace(/^[\/\\]/, '');
return {
file,
output: fromRoot(part, 'esm', 'build', file.replace(/\.(ts|tsx)$/, '.js')),
};
}
return null;
}
/**
* Run all builds in parallel, showing incremental dot progress.
*
* @param {string[]} entryPoints Absolute entry file paths.
* @param {import('esbuild').BuildOptions} buildConfig Shared esbuild configuration.
* @returns {Promise<{errors: {file: string, output?: string, error: Error|null}[]}>}
*/
async function runParallelBuilds(entryPoints, buildConfig) {
const total = entryPoints.length;
/** @type {{file: string, output?: string, error: Error|null}[]} */
const errors = [];
const startTime = Date.now();
const progress = createDotProgress(total);
progress.start();
await Promise.all(entryPoints.map(async (entry) => {
const result = await buildComponent(entry, buildConfig);
if (result.error) {
errors.push(result);
}
progress.tick();
}));
const elapsed = ((Date.now() - startTime) / 1000).toFixed(1);
const succeeded = total - errors.length;
if (errors.length > 0) {
progress.fail(`${succeeded}/${total} built · ${elapsed}s`);
for (const e of errors) {
console.error(chalk.red(`${e.file}: ${e.error?.message ?? ''}`));
}
} else {
progress.succeed(chalk.bold(`${total} components built`) + chalk.dim(` · ${elapsed}s`));
}
return { errors };
}
/**
* Create the shared esbuild build configuration.
*
* @param {boolean} isDev Whether development mode is enabled.
* @returns {import('esbuild').BuildOptions} esbuild configuration object.
*/
export function createBuildConfig(isDev) {
return {
bundle: true,
format: "esm",
external: ["react", "react/*", "react-dom", "react-dom/*", "@moodlehq/design-system", "@moodlehq/design-system/*", "@moodle/lms", "@moodle/lms/*"],
jsx: "automatic",
minify: !isDev,
sourcemap: isDev ? 'inline' : false,
jsxDev: isDev,
keepNames: isDev,
treeShaking: !isDev,
define: { 'process.env.NODE_ENV': isDev ? '"development"' : '"production"' },
};
}
/**
* Build all plugin and core React components.
*
* @param {boolean} isDev Whether development mode is enabled.
* @returns {Promise<void>}
*/
export async function buildPluginComponents(isDev) {
console.log(chalk.green('> Building components...'));
const entryPoints = glob.sync("**/js/esm/src/**/*.{ts,tsx}", {
cwd: projectRoot,
absolute: true,
ignore: [
`${process.cwd()}/node_modules/**`,
`${process.cwd()}/vendor/**`,
],
});
const buildConfig = createBuildConfig(isDev);
const { errors } = await runParallelBuilds(entryPoints, buildConfig);
if (errors.length > 0) {
throw new Error(`React build failed: ${errors.length} component(s) could not be built`);
}
}
/**
* Start esbuild in native watch mode over all React components.
*
* Creates a single incremental build context for all entry points so that
* esbuild can reuse its internal graph between rebuilds instead of starting
* from scratch on every file change.
*
* @param {boolean} isDev Whether to build in development mode.
* @param {((srcFiles: string[]) => void) | undefined} [onRebuild] Called with the rebuilt entry source
* files (relative to project root) after each non-initial successful rebuild. Use this to run
* follow-up tasks such as linting without coupling them to this module.
* @returns {Promise<import('esbuild').BuildContext|null>} The active context, or null if no source files exist.
*/
export async function watchComponents(isDev, onRebuild) {
const entryPoints = glob.sync("**/js/esm/src/**/*.{ts,tsx}", {
cwd: projectRoot,
absolute: true,
ignore: [
`${process.cwd()}/node_modules/**`,
`${process.cwd()}/vendor/**`,
],
});
if (entryPoints.length === 0) {
return null;
}
const buildConfig = createBuildConfig(isDev);
// Map each source file to an {in, out} pair so esbuild can write each
// component to its custom output directory while sharing a single context.
// The 'out' path is relative to outdir (projectRoot) and has no extension —
// esbuild appends the appropriate extension automatically.
// Build entry pairs and ensure output directories exist in a single pass.
const entryPairs = entryPoints.flatMap(entry => {
const resolved = resolveComponentPaths(entry);
if (!resolved) {
return [];
}
fs.mkdirSync(path.dirname(resolved.output), { recursive: true });
return [{ in: entry, out: path.relative(projectRoot, resolved.output).replace(/\.js$/, '') }];
});
// Report build results to the terminal after every build (initial and on each change).
// metafile: true populates result.metafile.outputs so we know which files were written.
// On a rebuild only the affected outputs appear, so it effectively names the changed file.
/** @type {import('esbuild').Plugin} */
const watchReporter = {
name: 'watch-reporter',
setup(build) {
let isInitial = true;
let startTime = 0;
build.onStart(() => {
startTime = Date.now();
});
build.onEnd(result => {
const now = new Date().toLocaleTimeString();
const elapsed = ((Date.now() - startTime) / 1000).toFixed(1);
if (result.errors.length > 0) {
console.error(chalk.red(`[${now}] ✗ Build failed (${result.errors.length} error(s))`) + chalk.dim(` · ${elapsed}s`));
return;
}
const outputs = Object.keys(result.metafile?.outputs ?? {});
console.log(chalk.green(`[${now}] ✓ ${outputs.length} component(s) built`) + chalk.dim(` · ${elapsed}s`));
if (isInitial) {
isInitial = false;
} else if (onRebuild) {
// entryPoint is the source file (relative to projectRoot) that triggered
// this rebuild. Pass it to the caller so they can run follow-up tasks
// (e.g. linting) without this module needing to know about them.
const srcFiles = Object.values(result.metafile?.outputs ?? {})
.map(output => output.entryPoint)
.filter(/** @param {string|undefined} f */ f => !!f);
onRebuild(/** @type {string[]} */ (srcFiles));
}
});
},
};
const ctx = await esbuild.context({
...buildConfig,
entryPoints: entryPairs,
outdir: projectRoot,
metafile: true,
plugins: [watchReporter],
});
await ctx.watch();
return ctx;
}
-266
View File
@@ -1,266 +0,0 @@
{
'plugins': [
'@babel',
'promise',
'jsdoc'
],
'extends': [
'eslint:recommended',
'plugin:promise/recommended'
],
'env': {
'browser': true,
// Enable ES6+ features by default.
// See http://eslint.org/docs/user-guide/configuring#specifying-environments
// Note: The YUI override must exactly match this when disabling the ES6+ version because those features are not supported by Shifter.
'es2020': true,
'amd': true
},
'globals': {
'M': true,
'Y': true
},
// Warn about unused eslint-disable statements.
'reportUnusedDisableDirectives': true,
'rules': {
// See http://eslint.org/docs/rules/ for all rules and explanations of all
// rules.
// === Possible Errors ===
'comma-dangle': 'off',
'no-console': 'error',
'no-empty': 'warn',
'no-extra-parens': 'off',
'no-prototype-builtins': 'off',
'no-unreachable': 'warn',
// === Best Practices ===
// (these mostly match our jshint config)
'array-callback-return': 'warn',
'block-scoped-var': 'warn',
'complexity': 'warn',
'consistent-return': 'warn',
'curly': 'error',
'dot-notation': 'warn',
'no-alert': 'warn',
'no-caller': 'error',
'no-div-regex': 'error',
'no-empty-function': 'warn',
'no-eq-null': 'error',
'no-eval': 'error',
'no-extend-native': 'error',
'no-extra-bind': 'warn',
'no-floating-decimal': 'warn',
'no-global-assign': 'warn',
'no-implied-eval': 'error',
'no-invalid-this': 'error',
'no-iterator': 'error',
'no-labels': 'error',
'no-loop-func': 'error',
'no-multi-spaces': 'warn',
'no-multi-str': 'error',
'no-new-func': 'error',
'no-new-wrappers': 'error',
'no-octal-escape': 'error',
'no-proto': 'error',
'no-redeclare': 'warn',
'no-restricted-globals': ['error', { 'name': 'Notification' }],
'no-return-assign': 'error',
'no-script-url': 'error',
'no-self-compare': 'error',
'no-sequences': 'warn',
'no-throw-literal': 'warn',
'no-unmodified-loop-condition': 'error',
'no-unused-expressions': 'error',
'no-useless-call': 'warn',
'no-useless-escape': 'warn',
'wrap-iife': ['error', 'any'],
// === Variables ===
'no-undef-init': 'error',
'no-unused-vars': ['error', { 'caughtErrors': 'none' }],
// === Stylistic Issues ===
'array-bracket-spacing': 'warn',
'block-spacing': 'warn',
'brace-style': ['warn', '1tbs'],
'camelcase': 'warn',
'capitalized-comments': ['warn', 'always', { 'ignoreConsecutiveComments': true }],
'comma-spacing': ['warn', { 'before': false, 'after': true }],
'comma-style': ['warn', 'last'],
'computed-property-spacing': 'error',
'consistent-this': 'off',
'eol-last': 'off',
'func-call-spacing': ['warn', 'never'],
'func-names': 'off',
'func-style': 'off',
// indent currently not doing well with our wrapping style, so disabled.
'indent': ['off', 4, { 'SwitchCase': 1 }],
'key-spacing': ['warn', { 'beforeColon': false, 'afterColon': true, 'mode': minimum }],
'keyword-spacing': 'warn',
'linebreak-style': ['error', 'unix'],
'lines-around-comment': 'off',
'max-len': ['error', 132],
'max-lines': 'off',
'max-depth': 'warn',
'max-nested-callbacks': ['warn', 5],
'max-params': 'off',
'max-statements': 'off',
'max-statements-per-line': ['warn', { max: 2 }],
'new-cap': ['warn', { 'properties': false }],
'new-parens': 'warn',
'newline-per-chained-call': 'off',
'no-array-constructor': 'off',
'no-bitwise': 'error',
'no-continue': 'off',
'no-inline-comments': 'off',
'no-lonely-if': 'off',
'no-mixed-operators': 'off',
'no-multiple-empty-lines': 'warn',
'no-negated-condition': 'off',
'no-nested-ternary': 'warn',
'no-new-object': 'off',
'no-plusplus': 'off',
'no-tabs': 'error',
'no-ternary': 'off',
'no-trailing-spaces': 'error',
'no-underscore-dangle': 'off',
'no-unneeded-ternary': 'off',
'no-whitespace-before-property': 'warn',
'object-curly-newline': 'off',
'object-curly-spacing': 'warn',
'object-property-newline': 'off',
'one-var': 'off',
'one-var-declaration-per-line': ['warn', 'initializations'],
'operator-assignment': 'off',
'operator-linebreak': 'off',
'padded-blocks': 'off',
'quote-props': ['warn', 'as-needed', {'unnecessary': false, 'keywords': true, 'numbers': true}],
'quotes': 'off',
'semi': 'error',
'semi-spacing': ['warn', {'before': false, 'after': true}],
'sort-vars': 'off',
'space-before-blocks': 'warn',
'space-before-function-paren': ['warn', 'never'],
'space-in-parens': 'warn',
'space-infix-ops': 'warn',
'space-unary-ops': 'warn',
'spaced-comment': 'warn',
'unicode-bom': 'error',
'wrap-regex': 'off',
// === Promises (override plugin:promise/recommended) ===
'promise/always-return': 'warn',
'promise/no-return-wrap': 'warn',
'promise/param-names': 'warn',
'promise/catch-or-return': ['warn', {terminationMethod: ['catch', 'fail', 'always'], allowFinally: true}],
'promise/no-native': 'warn',
'promise/avoid-new': 'warn',
// === Deprecations ===
"no-restricted-properties": ['warn', {
'object': 'M',
'property': 'str',
'message': 'Use "core/str" module or M.util.get_string()'
}],
},
overrides: [
{
files: ["**/yui/src/**/*.js"],
'env': {
// Disable ES6+ for YUI files.
'es2020': false,
},
// Disable some rules which we can't safely define for YUI rollups.
rules: {
'no-undef': 'off',
'no-unused-vars': 'off',
'no-unused-expressions': 'off',
// === JSDocs ===
"jsdoc/check-access": 'off',
"jsdoc/check-alignment": 'off',
"jsdoc/check-param-names": 'off',
"jsdoc/check-property-names": 'off',
"jsdoc/empty-tags": 'off',
"jsdoc/implements-on-classes": 'off',
"jsdoc/multiline-blocks": 'off',
"jsdoc/require-jsdoc": 'off',
"jsdoc/require-param": 'off',
"jsdoc/require-param-name": 'off',
"jsdoc/require-param-type": 'off',
"jsdoc/require-property": 'off',
"jsdoc/require-property-name": 'off',
"jsdoc/require-property-type": 'off',
}
},
{
files: ["**/amd/src/*.js", "**/amd/src/**/*.js", "Gruntfile.js", ".grunt/*.js", ".grunt/tasks/*.js", "jsdoc.conf.js"],
// We're using babel transpiling so use their parser
// for linting.
parser: '@babel/eslint-parser',
// Check AMD with some slightly stricter rules.
rules: {
'no-implicit-globals': 'error',
// Disable all of the rules that have babel versions.
'new-cap': 'off',
// Not using this rule for the time being because it isn't
// compatible with jQuery and ES6.
'no-invalid-this': 'off',
'object-curly-spacing': 'off',
'quotes': 'off',
'semi': 'off',
'no-unused-expressions': 'off',
// Enable all of the babel version of these rules.
'@babel/new-cap': ['warn', { 'properties': false }],
// Not using this rule for the time being because it isn't
// compatible with jQuery and ES6.
'@babel/no-invalid-this': 'off',
'@babel/object-curly-spacing': 'warn',
'@babel/semi': 'error',
'@babel/no-unused-expressions': 'error',
// === Promises ===
// We have Promise now that we're using ES6.
'promise/no-native': 'off',
'promise/avoid-new': 'off',
// === JSDocs ===
'jsdoc/check-access': 'error',
'jsdoc/check-alignment': 1, // Recommended.
'jsdoc/check-param-names': 'error',
'jsdoc/check-property-names': 'error',
'jsdoc/empty-tags': 'error',
'jsdoc/implements-on-classes': 'error',
'jsdoc/multiline-blocks': 'error',
'jsdoc/require-jsdoc': 'error',
'jsdoc/require-param': 'error',
'jsdoc/require-param-name': 'error',
'jsdoc/require-param-type': 'error',
'jsdoc/require-property': 'error',
'jsdoc/require-property-name': 'error',
'jsdoc/require-property-type': 'error'
},
parserOptions: {
'sourceType': 'module',
'requireConfigFile': false
}
},
{
files: ["**/*.ts", "**/*.tsx"],
parser: '@typescript-eslint/parser',
parserOptions: {
sourceType: 'module',
ecmaFeatures: {
jsx: true
},
allowSyntheticDefaultImports: true
},
rules: {
// promise/no-native crashes on TypeScript ASTs (same reason it is
// disabled for AMD files above). Native Promises are standard in TS.
'promise/no-native': 'off',
'promise/avoid-new': 'off',
}
}
]
}
-24
View File
@@ -1,24 +0,0 @@
{
"indentation": ["on",{
"Feature": 0,
"Background": 2,
"Scenario": 2,
"Examples": 4,
"example": 6,
"Step": 4,
"given": 4,
"and": 4
}],
"no-dupe-feature-names": "on",
"no-dupe-scenario-names": "off",
"no-empty-file": "on",
"no-files-without-scenarios": "on",
"no-multiple-empty-lines": "on",
"no-partially-commented-tag-lines": "on",
"no-trailing-spaces": "on",
"no-unnamed-features": "on",
"no-unnamed-scenarios": "on",
"no-scenario-outlines-without-examples": "on",
"no-examples-in-scenarios": "on",
"new-line-at-eof": ["on", "yes"]
}
-9
View File
@@ -1,9 +0,0 @@
**/yui/build/** -diff
**/amd/build/** -diff
**.js.map -diff
**-min.js -diff
**.min.js -diff
# Remove composer lock file changes from standard diff views.
/composer.lock -diff
/lib/js/bundles/*/*.js -diff
-2
View File
@@ -1,2 +0,0 @@
# Primary donations pages.
custom: ["https://moodle.com/donations/"]
-7
View File
@@ -1,7 +0,0 @@
*** PLEASE DO NOT OPEN PULL REQUESTS VIA GITHUB ***
The moodle.git repository at Github is just a mirror of the official repository. We do not accept pull requests at Github.
See CONTRIBUTING.md guidelines for how to contribute patches for Moodle. Thank you.
--
-6
View File
@@ -1,6 +0,0 @@
> [!IMPORTANT]
> PLEASE DO NOT PUBLISH SECURITY FINDINGS PUBLICLY.
If you discover a potential security issue, please report it via our [Security Submission Form](https://moodle.org/security/report).
For more information about our security processes and responsible disclosure policy, see the [Security Procedures documentation](https://moodledev.io/general/development/process/security).
-1
View File
@@ -1 +0,0 @@
<svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1231.24 314.44" preserveAspectRatio="xMinYMid meet"><defs><style>.cls-1{fill:#f48020;}.cls-2,.cls-3{fill:#383738;stroke:#4a4a4c;}.cls-2{stroke-width:2.37px;}.cls-3{stroke-width:2.38px;}.cls-4{fill:#585858;}</style></defs><title>Moodle_Logo_UseonBlack_RGB</title><path class="cls-1" d="M1086.3,235.34a53.42,53.42,0,0,0,16.71,29q13.26,12.27,29.48,12.27,11.29,0,24.56-5.89,16.23-6.88,16.22-16.22l58-.49q-12.29,29-41.76,45.2-27.52,15.23-60.43,15.24-42.25,0-70-26.29t-27.75-68.54q0-43.73,27.75-69.51t72-25.8q48.15,0,75.17,31.94,25.07,29.47,25.06,79.1Zm89.91-33.91q-3.43-17.69-14.73-29-12.8-12.28-29.49-12.29-17.21,0-28.74,11.79t-15.47,29.48Z"/><path class="cls-1" d="M965.45,308.54V0h55V308.54Z"/><path class="cls-1" d="M892.69,308.54V290.36q-7.38,9.83-25.06,15.72a92.31,92.31,0,0,1-30,5.41q-39.31,0-63.13-27T750.7,217.65q0-39.3,23.34-65.84t62.15-26.53q43.71,0,56.5,23.58V0h53.55V308.54Zm0-102.68q0-14.75-14-28.26t-28.74-13.51q-21.12,0-33.41,17.2-10.8,15.24-10.8,37.33,0,21.63,10.8,36.85,12.29,17.71,33.41,17.69,12.78,0,27.76-12t15-24.81Z"/><path class="cls-1" d="M647,313.45q-41.77,0-69-26.53t-27.27-68.3q0-41.73,27.27-68.28t69-26.53q41.75,0,69.27,26.53t27.52,68.28q0,41.79-27.52,68.3T647,313.45ZM647,168q-19.89,0-30.58,15.07t-10.68,35.79q0,20.73,9.94,35.05,11.43,16.31,31.32,16.28t31.32-16.28q10.44-14.31,10.44-35.05t-9.94-35Q667.42,168,647,168Z"/><path class="cls-1" d="M448.07,313.45q-41.76,0-69-26.53t-27.27-68.3q0-41.73,27.27-68.28t69-26.53q41.74,0,69.28,26.53t27.5,68.28q0,41.79-27.5,68.3T448.07,313.45Zm0-145.43q-19.89,0-30.59,15.07t-10.69,35.79q0,20.73,9.94,35.05,11.43,16.31,31.34,16.28t31.32-16.28q10.42-14.31,10.44-35.05t-9.94-35Q468.45,168,448.07,168Z"/><path class="cls-1" d="M288.89,309.11V201q0-33.9-28-33.9t-28,33.9V309.11h-55V201q0-33.9-27.52-33.9-28,0-28,33.9V309.11h-55V194.65q0-35.37,24.56-53.54,21.61-16.22,58.46-16.22,37.35,0,55,19.16,15.23-19.16,55.51-19.16,36.86,0,58.45,16.22,24.57,18.16,24.57,53.54V309.11Z"/><path class="cls-2" d="M.76,145.76"/><path class="cls-3" d="M1.73,145.32"/><path class="cls-4" d="M173.86,116.85l55.08-40.1-.7-2.44C135,83.92,80.42,96.44,0,144.13l.73,2.38,21-.67c15.17.52,30.85,1.26,46,1.32-1,24.09.83,32.65.83,32.65,51.92,17.58,101.22,1.53,127.14-43.9A248.72,248.72,0,0,0,173.86,116.85Z"/><path class="cls-4" d="M113.78,110c-.3-1.08-2.23-1.48-4.28-.9a4.73,4.73,0,0,0-3.14,2.19c-18.53,5-49.16,13.72-70.73,21l-1.33.45c-16.68,5.61-24.73,8.49-25.22,12.55-2.29,18.44-.87,42.18-.86,42.48l.19,6.4c-9.74,27.56.06,49.6,8.38,69.77.06-24.92,1.07-45.22-6-71-.2-3.82-1.49-30.36.61-47.34.34-2.75,11.65-6.56,23.63-10.59l1.33-.44c22-7.42,53.57-16.39,71.9-21.29a6.75,6.75,0,0,0,2.29-.25C112.64,112.43,114.08,111.09,113.78,110Z"/></svg>

Before

Width:  |  Height:  |  Size: 2.7 KiB

-31
View File
@@ -1,31 +0,0 @@
name: 'Close Pull Requests'
on:
pull_request_target:
types: opened
workflow_dispatch:
jobs:
close:
# Avoid forks to run this job
if: github.repository_owner == 'moodle'
name: Close Pull Requests
runs-on: ubuntu-latest
steps:
- uses: dessant/repo-lockdown@v4
with:
process-only: prs
close-pr: true
skip-closed-pr-comment: true
pr-comment: >
**Please, don't open pull requests via GitHub.**
This repository (moodle.git) at GitHub is just a mirror of the official Moodle repository.
For how to contribute patches for Moodle see
[CONTRIBUTING.md](https://github.com/moodle/moodle/blob/main/CONTRIBUTING.md).
Closing this pull request.
-118
View File
@@ -1,118 +0,0 @@
name: Run tests in a Composed Moodle Setup
on:
push:
branches-ignore:
- main
- MOODLE_[0-9]+_STABLE
tags-ignore:
- v[0-9]+.[0-9]+.[0-9]+*
workflow_dispatch:
inputs:
phpunit_extra_options:
description: Additional options to apply to PHPUnit
required: false
default: ''
env:
php: 8.4
jobs:
PHPUnit:
runs-on: ${{ matrix.os }}
services:
exttests:
image: moodlehq/moodle-exttests
ports:
- 8080:80
redis:
image: redis
ports:
- 6379:6379
postgres:
image: ${{ matrix.db == 'pgsql' && 'postgres:16' || '' }}
env:
POSTGRES_DB: test
POSTGRES_USER: test
POSTGRES_PASSWORD: test
ports:
- 5432:5432
strategy:
fail-fast: false
matrix:
include:
# MySQL builds always run with the lowest PHP supported version.
- os: ubuntu-24.04
php: 8.3
extensions:
db: mysqli
# PostgreSQL builds always run with the highest PHP supported version.
- os: ubuntu-24.04
php: 8.4
db: pgsql
steps:
- name: Run MySQL Server
if: ${{ matrix.db == 'mysqli' }}
run: |
docker run --rm \
-e MYSQL_DATABASE=test \
-e MYSQL_USER=test \
-e MYSQL_PASSWORD=test \
-e MYSQL_ROOT_PASSWORD=test \
-p 3306:3306 \
-d \
--tmpfs /var/lib/mysql:rw,noexec,nosuid,size=1024M \
mysql:8.4 \
--skip-log-bin \
--collation-server=utf8mb4_bin
- name: Configuring git vars
uses: rlespinasse/github-slug-action@v5
- name: Setting up PHP ${{ matrix.php }}
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: ${{ matrix.extensions }}
ini-values: max_input_vars=5000
coverage: none
tools: composer
- name: Checking out code from ${{ env.GITHUB_REF_SLUG }}
uses: actions/checkout@v6
with:
path: 'moodle'
- name: 'Preparing the environment'
run: |
echo "pathtophp=$(which php)" >> $GITHUB_ENV # Inject installed pathtophp to env. The template config needs it.
sudo locale-gen en_AU.UTF-8
- name: Create the new Composer Project
run: |
mkdir testsite
cp moodle/.github/workflows/composed/composer.json testsite/composer.json
cp moodle/.github/workflows/composed/config.php testsite/config.php
mkdir -p testsite/data/moodledata
mkdir -p testsite/data/phpunitdata
- name: Install the Moodle test site
working-directory: testsite
run: |
composer install --no-interaction
- name: Setting up PHPUnit
working-directory: testsite
env:
dbtype: ${{ matrix.db }}
run: |
php moodle/public/admin/tool/phpunit/cli/init.php --no-composer-self-update
- name: Running PHPUnit tests
working-directory: testsite
env:
dbtype: ${{ matrix.db }}
phpunit_options: ${{ secrets.phpunit_options }}
run: |
vendor/bin/phpunit $phpunit_options ${{ inputs.phpunit_extra_options }}
-25
View File
@@ -1,25 +0,0 @@
{
"type": "project",
"require": {
"moodle/composer-installer": "^1",
"moodle/moodle-composer-scaffold": "^1",
"moodle/moodle": "@dev",
"moodle/moodle-testing": "^1.0"
},
"repositories": [
{
"name": "moodleundertest",
"type": "path",
"url": "../moodle"
}
],
"config": {
"audit": {
"block-insecure": false
},
"allow-plugins": {
"moodle/composer-installer": true,
"moodle/moodle-composer-scaffold": true
}
}
}
-67
View File
@@ -1,67 +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/>.
/**
* Template configuraton file for GitHub Actions CI/CD using Composer.
*
* @package core
* @copyright 2020 onwards Eloy Lafuente (stronk7) {@link https://stronk7.com}
* @license https://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
// This cannot be used out from a GitHub Actions workflow, so just exit.
getenv('GITHUB_WORKFLOW') || die; // phpcs:ignore moodle.Files.MoodleInternal.MoodleInternalGlobalState
unset($CFG);
global $CFG;
$CFG = new stdClass();
$CFG->dbtype = getenv('dbtype');
$CFG->dblibrary = 'native';
$CFG->dbhost = '127.0.0.1';
$CFG->dbname = 'test';
$CFG->dbuser = 'test';
$CFG->dbpass = 'test';
$CFG->prefix = 'm_';
$CFG->dboptions = ['dbcollation' => 'utf8mb4_bin'];
$host = 'localhost';
$CFG->wwwroot = "http://{$host}";
$CFG->dataroot = __DIR__ . '/data/moodledata';
$CFG->admin = 'admin';
$CFG->directorypermissions = 0777;
// Debug options - possible to be controlled by flag in future.
$CFG->debug = (E_ALL); // DEBUG_DEVELOPER.
$CFG->debugdisplay = 1;
$CFG->debugstringids = 1; // Add strings=1 to url to get string ids.
$CFG->perfdebug = 15;
$CFG->debugpageinfo = 1;
$CFG->allowthemechangeonurl = 1;
$CFG->passwordpolicy = 0;
$CFG->cronclionly = 0;
$CFG->pathtophp = getenv('pathtophp');
$CFG->phpunit_dataroot = __DIR__ . '/data/phpunitdata';
$CFG->phpunit_prefix = 't_';
$CFG->routerconfigured = true;
define('TEST_EXTERNAL_FILES_HTTP_URL', 'http://localhost:8080');
define('TEST_EXTERNAL_FILES_HTTPS_URL', 'http://localhost:8080');
define('TEST_SESSION_REDIS_HOST', 'localhost');
define('TEST_CACHESTORE_REDIS_TESTSERVERS', 'localhost');
-73
View File
@@ -1,73 +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/>.
/**
* Template configuraton file for github actions CI/CD.
*
* @package core
* @copyright 2020 onwards Eloy Lafuente (stronk7) {@link https://stronk7.com}
* @license https://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
// This cannot be used out from a github actions workflow, so just exit.
getenv('GITHUB_WORKFLOW') || die; // phpcs:ignore moodle.Files.MoodleInternal.MoodleInternalGlobalState
unset($CFG);
global $CFG;
$CFG = new stdClass();
$CFG->dbtype = getenv('dbtype');
$CFG->dblibrary = 'native';
$CFG->dbhost = '127.0.0.1';
$CFG->dbname = 'test';
$CFG->dbuser = 'test';
$CFG->dbpass = 'test';
$CFG->prefix = 'm_';
$CFG->dboptions = ['dbcollation' => 'utf8mb4_bin'];
$host = 'localhost';
$CFG->wwwroot = "http://{$host}";
$CFG->dataroot = realpath(dirname(__DIR__)) . '/moodledata';
$CFG->admin = 'admin';
$CFG->directorypermissions = 0777;
// Debug options - possible to be controlled by flag in future.
$CFG->debug = (E_ALL); // DEBUG_DEVELOPER.
$CFG->debugdisplay = 1;
$CFG->debugstringids = 1; // Add strings=1 to url to get string ids.
$CFG->perfdebug = 15;
$CFG->debugpageinfo = 1;
$CFG->allowthemechangeonurl = 1;
$CFG->passwordpolicy = 0;
$CFG->cronclionly = 0;
$CFG->pathtophp = getenv('pathtophp');
$CFG->phpunit_dataroot = realpath(dirname(__DIR__)) . '/phpunitdata';
$CFG->phpunit_prefix = 't_';
$CFG->routerconfigured = true;
define('TEST_EXTERNAL_FILES_HTTP_URL', 'http://localhost:8080');
define('TEST_EXTERNAL_FILES_HTTPS_URL', 'http://localhost:8080');
define('TEST_SESSION_REDIS_HOST', 'localhost');
define('TEST_CACHESTORE_REDIS_TESTSERVERS', 'localhost');
// TODO: add others (solr, mongodb, memcached, ldap...).
// Too much for now: define('PHPUNIT_LONGTEST', true); // Only leaves a few tests out and they are run later by CI.
require_once(__DIR__ . '/lib/setup.php');
-143
View File
@@ -1,143 +0,0 @@
name: One by One Testing
# Run all the individual unit tests one by one, with
# fully independent PHPUnit executions. Useful to
# detect issues with some tests that are using stuff
# that has been made available by others, but is not
# available when running individually.
#
# Note that we aren't using PHPUnit's own isolation
# here but completely separated runs, one for each
# test.
#
# The workflow will fail reporting all the tests
# that have failed (and will pass if no failure is
# detected, of course).
#
# It's only executed via workflow dispatch (automated
# or manual), not by push/tag. And acceptd configuration
# of phpunit, specially useful to run it with PHPUnit's
# own isolation or any other option.
on:
workflow_dispatch:
inputs:
phpunit_extra_options:
description: Additional options to apply to PHPUnit
required: false
default: ''
env:
chunks: 7
jobs:
collect:
name: Collect individual unit tests
runs-on: ubuntu-latest
outputs:
matrix: ${{steps.individual-tests.outputs.matrix }}
steps:
- name: Checking out code
uses: actions/checkout@v4
- name: Looking for all individual tests
id: individual-tests
run: |
count=0 # Number of individual tests found.
while read -r testfile; do # For each test file.
while read -r testname; do # For each unit test in a file.
count=$((count + 1))
# Sent it to the correct chunk file.
chunk=$(((($count % $chunks)) + 1))
echo "$testname $testfile" >> ./chunk_$chunk.txt
done < <(grep "function test_" "${testfile}" | sed -r "s/^.*function (test_[a-zA-Z0-9_]+).*/\1/")
done < <(find . -name "*_test.php" -not -path "*/fixtures/*")
# Generate the matrix to run tests.
echo "matrix=$(ls -1 chunk_*.txt | jq -R -s -c 'split("\n")[:-1]')" >> $GITHUB_OUTPUT
echo "$count individual tests collected in $chunks files"
- name: Upload individual tests files
uses: actions/upload-artifact@v4
with:
name: individual_tests
path: chunk_*.txt
retention-days: 1
test:
name: Run tests
needs: collect
runs-on: ubuntu-latest
services:
exttests:
image: moodlehq/moodle-exttests
ports:
- 8080:80
redis:
image: redis
ports:
- 6379:6379
strategy:
fail-fast: false
matrix:
file: ${{ fromJson(needs.collect.outputs.matrix) }}
steps:
- name: Setting up DB pgsql
uses: m4nu56/postgresql-action@v1
with:
postgresql version: 16
postgresql db: test
postgresql user: test
postgresql password: test
- name: Setting up PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.4
ini-values: max_input_vars=5000
coverage: none
- name: Checking out code
uses: actions/checkout@v4
- name: Download individual test files
uses: actions/download-artifact@v4
with:
name: individual_tests # Make all the chunk files available for the next steps.
- name: Setting up PHPUnit
env:
dbtype: pgsql
run: |
echo "pathtophp=$(which php)" >> $GITHUB_ENV
cp .github/workflows/config-template.php config.php
mkdir ../moodledata
sudo locale-gen en_AU.UTF-8
php public/admin/tool/phpunit/cli/init.php --no-composer-self-update
- name: Run PHPUnit test (one by one)
env:
dbtype: pgsql
run: |
status=0
count=0
while read -r line; do # For each line in the chunk file
count=$((count + 1))
filter="${line% *}"
file="${line#* }"
# Run the individual unit test and report problems if needed to.
if ! php vendor/bin/phpunit \
--fail-on-empty-test-suite \
--fail-on-warning \
--fail-on-risky \
--filter "$filter" ${{ inputs.phpunit_extra_options }} \
"$file" >/dev/null 2>&1; then
if [ $status -eq 0 ]; then
echo "Problems found, list of PHPUnit commands failing:"
fi
echo "vendor/bin/phpunit --filter '${filter}' ${{ inputs.phpunit_extra_options }} $file"
status=$((status + 1))
fi
done < ${{ matrix.file }}
echo "Finished: $count individual tests executed, $status tests failed"
exit $status
-128
View File
@@ -1,128 +0,0 @@
name: Core
on:
push:
branches-ignore:
- main
- MOODLE_[0-9]+_STABLE
tags-ignore:
- v[0-9]+.[0-9]+.[0-9]+*
workflow_dispatch:
inputs:
phpunit_extra_options:
description: Additional options to apply to PHPUnit
required: false
default: ''
env:
php: 8.4
jobs:
Grunt:
runs-on: ubuntu-24.04
steps:
- name: Checking out code
uses: actions/checkout@v4
- name: Configuring node & npm
uses: actions/setup-node@v4
with:
node-version-file: '.nvmrc'
- name: Installing node stuff
run: npm install
- name: Running grunt
run: npx grunt
- name: Looking for uncommitted changes
# Add all files to the git index and then run diff --cached to see all changes.
# This ensures that we get the status of all files, including new files.
# We ignore npm-shrinkwrap.json to make the tasks immune to npm changes.
run: |
git add .
git reset -- npm-shrinkwrap.json
git diff --cached --exit-code
PHPUnit:
runs-on: ${{ matrix.os }}
services:
exttests:
image: moodlehq/moodle-exttests
ports:
- 8080:80
redis:
image: redis
ports:
- 6379:6379
postgres:
image: ${{ matrix.db == 'pgsql' && 'postgres:16' || '' }}
env:
POSTGRES_DB: test
POSTGRES_USER: test
POSTGRES_PASSWORD: test
ports:
- 5432:5432
strategy:
fail-fast: false
matrix:
include:
# MySQL builds always run with the lowest PHP supported version.
- os: ubuntu-24.04
php: 8.3
extensions:
db: mysqli
# PostgreSQL builds always run with the highest PHP supported version.
- os: ubuntu-24.04
php: 8.4
db: pgsql
steps:
- name: Run MySQL Server
if: ${{ matrix.db == 'mysqli' }}
run: |
docker run --rm \
-e MYSQL_DATABASE=test \
-e MYSQL_USER=test \
-e MYSQL_PASSWORD=test \
-e MYSQL_ROOT_PASSWORD=test \
-p 3306:3306 \
-d \
--tmpfs /var/lib/mysql:rw,noexec,nosuid,size=1024M \
mysql:8.4 \
--skip-log-bin \
--collation-server=utf8mb4_bin
- name: Configuring git vars
uses: rlespinasse/github-slug-action@v4
- name: Setting up PHP ${{ matrix.php }}
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: ${{ matrix.extensions }}
ini-values: max_input_vars=5000
coverage: none
- name: Checking out code from ${{ env.GITHUB_REF_SLUG }}
uses: actions/checkout@v4
- name: Setting up PHPUnit
env:
dbtype: ${{ matrix.db }}
run: |
echo "pathtophp=$(which php)" >> $GITHUB_ENV # Inject installed pathtophp to env. The template config needs it.
cp .github/workflows/config-template.php config.php
mkdir ../moodledata
sudo locale-gen en_AU.UTF-8
php public/admin/tool/phpunit/cli/init.php --no-composer-self-update
- name: Running PHPUnit tests
env:
dbtype: ${{ matrix.db }}
phpunit_options: ${{ secrets.phpunit_options }}
run: vendor/bin/phpunit $phpunit_options ${{ inputs.phpunit_extra_options }}
- name: Git status
run: git status
-23
View File
@@ -1,23 +0,0 @@
name: Web Installer Testing
on:
workflow_dispatch:
jobs:
InstallationTest:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
php: [8.3, 8.4]
steps:
- name: Construct repository URL
run: echo "REPOSITORY_URL=${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}" >> $GITHUB_ENV
shell: bash
- uses: moodlehq/moodle-webinstaller-test@main
with:
repository: ${{ env.REPOSITORY_URL }}
branch: ${{ github.ref_name }}
php: ${{ matrix.php }}
-149
View File
@@ -1,149 +0,0 @@
name: Windows Testing
on:
workflow_dispatch:
inputs:
phpunit_extra_options:
description: Additional options to apply to PHPUnit
required: false
default: ''
env:
php: 8.4
jobs:
Grunt:
runs-on: windows-latest
steps:
- name: Set git to use LF
run: |
git config --global core.autocrlf false
git config --global core.eol lf
- name: Checking out code
uses: actions/checkout@v4
- name: Configuring node & npm
uses: actions/setup-node@v4
with:
node-version-file: '.nvmrc'
- name: Installing node stuff
run: npm ci
- name: Running grunt
run: npx grunt
- name: Looking for uncommitted changes
# Add all files to the git index and then run diff --cached to see all changes.
# This ensures that we get the status of all files, including new files.
# We ignore npm-shrinkwrap.json to make the tasks immune to npm changes.
run: |
git add .
git reset -- npm-shrinkwrap.json
git diff --cached --exit-code
PHPUnit:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- os: windows-latest
php: 8.4
# Ideally we should use mysql/mariadb, but they are 4x slower without tweaks and configuration
# so let's run only postgres (1.5h vs 6h) only, If some day we want to improve the mysql runs,
# this is the place to enable them.
# db: mysqli
db: pgsql
extensions: exif, fileinfo, gd, intl, pgsql, mysql, redis, soap, sodium, zip
- os: windows-latest
php: 8.3
db: pgsql
extensions: exif, fileinfo, gd, intl, pgsql, mysql, redis, soap, sodium, zip
steps:
- name: Setting up DB mysql
if: ${{ matrix.db == 'mysqli' }}
uses: shogo82148/actions-setup-mysql@v1
with:
mysql-version: 8.4
user: test
password: test
- name: Creating DB mysql
if: ${{ matrix.db == 'mysqli' }}
run: mysql --host 127.0.0.1 -utest -ptest -e 'CREATE DATABASE IF NOT EXISTS test COLLATE = utf8mb4_bin;';
- name: Setting up DB pgsql
if: ${{ matrix.db == 'pgsql' }}
run: |
# TODO: Remove these conf. modifications when php74 or php80 are lowest.
# Change to old md5 auth, because php73 does not support it.
# #password_encryption = scram-sha-256
(Get-Content "$env:PGDATA\postgresql.conf"). `
replace('#password_encryption = scram-sha-256', 'password_encryption = md5') | `
Set-Content "$env:PGDATA\postgresql.conf"
(Get-Content "$env:PGDATA\pg_hba.conf"). `
replace('scram-sha-256', 'md5') | `
Set-Content "$env:PGDATA\pg_hba.conf"
$pgService = Get-Service -Name postgresql*
Set-Service -InputObject $pgService -Status running -StartupType automatic
Start-Process -FilePath "$env:PGBIN\pg_isready" -Wait -PassThru
& $env:PGBIN\psql --command="CREATE USER test PASSWORD 'test'" --command="\du"
- name: Creating DB pgsql
if: ${{ matrix.db == 'pgsql' }}
run: |
& $env:PGBIN\createdb --owner=test test
$env:PGPASSWORD = 'test'
& $env:PGBIN\psql --username=test --host=localhost --list test
- name: Configuring git vars
uses: rlespinasse/github-slug-action@v4
- name: Setting up PHP ${{ matrix.php }}
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: ${{ matrix.extensions }}
ini-values: max_input_vars=5000
coverage: none
- name: Set git to use LF
run: |
git config --global core.autocrlf false
git config --global core.eol lf
- name: Checking out code from ${{ env.GITHUB_REF_SLUG }}
uses: actions/checkout@v4
# Needs to be done after php is available, git configured and Moodle checkout has happened.
- name: Setting up moodle-exttests service
run: |
git clone https://github.com/moodlehq/moodle-exttests.git
nssm install php-built-in C:\tools\php\php.exe -S localhost:8080 -t D:\a\moodle\moodle\moodle-exttests
nssm start php-built-in
- name: Setting up redis service
run: |
choco install redis --version 5.0.7 --no-progress
nssm install redis redis-server
nssm start redis
- name: Setting up PHPUnit
env:
dbtype: ${{ matrix.db }}
shell: bash
run: |
echo "pathtophp=$(which php)" >> $GITHUB_ENV # Inject installed pathtophp to env. The template config needs it.
cp .github/workflows/config-template.php config.php
mkdir ../moodledata
php public/admin/tool/phpunit/cli/init.php --no-composer-self-update
- name: Running PHPUnit tests
env:
dbtype: ${{ matrix.db }}
phpunit_options: ${{ secrets.phpunit_options }}
run: vendor/bin/phpunit $phpunit_options ${{ inputs.phpunit_extra_options }}
+6 -34
View File
@@ -9,26 +9,15 @@
#
# See gitignore(5) man page for more details
#
# Swap files (vim)
[._]*.s[a-v][a-z]
[._]*.sw[a-p]
[._]s[a-rt-v][a-z]
[._]ss[a-gi-z]
[._]sw[a-p]
# Temporary files including undo
*~
#
/config.php
/lib/editor/tinymce/extra/tools/temp/
*~
*.swp
/tags
/TAGS
/cscope.*
/.patches/
/.idea/
.phpstorm.*
!/.phpstorm.meta.php/
/.phpstorm.meta.php/*
!/.phpstorm.meta.php/di.php
/nbproject/
CVS
.DS_Store
@@ -36,28 +25,11 @@ CVS
/.project
/.buildpath
/.cache
.phpunit.result.cache
phpunit.xml
# Composer support. Do not ignore composer.json, or composer.lock. These should be shipped by us.
# Composer support - only composer.json is to be in git, the rest is installed in each checkout.
composer.phar
composer.lock
/vendor/
/behat.yml
*/yui/build/*/*-coverage.js
/public/lib/yuilib/*/build/*/*-coverage.js
# lib/yuilib/version/module/module-coverage.js
/public/lib/yuilib/*/*/*-coverage.js
atlassian-ide-plugin.xml
/node_modules/
/.vscode/
moodle-plugin-ci.phar
.eslintignore
.stylelintignore
/jsdoc
/public/admin/tool/componentlibrary/docs
/public/admin/tool/componentlibrary/hugo/site/data/my-index.json
.hugo_build.lock
phpcs.xml
jsconfig.json
UPGRADING-CURRENT.md
.phpunit.cache
tsconfig.aliases.json
/lib/yuilib/*/build/*/*-coverage.js
-169
View File
@@ -1,169 +0,0 @@
// 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/>.
/**
* This is a babel plugin to add the Moodle module names to the AMD modules
* as part of the transpiling process.
*
* In addition it will also add a return statement for the default export if the
* module is using default exports. This is a highly specific Moodle thing because
* we're transpiling to AMD and none of the existing Babel 7 plugins work correctly.
*
* This will fix the issue where an ES6 module using "export default Foo" will be
* transpiled into an AMD module that returns {default: Foo}; Instead it will now
* just simply return Foo.
*
* Note: This means all other named exports in that module are ignored and won't be
* exported.
*
* @copyright 2018 Ryan Wyllie <ryan@moodle.com>
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
"use strict";
/* eslint-env node */
module.exports = ({template, types}) => {
const fs = require('fs');
const path = require('path');
const cwd = process.cwd();
const ComponentList = require(path.join(process.cwd(), '.grunt', 'components.js'));
/**
* Search the list of components that match the given file name
* and return the Moodle component for that file, if found.
*
* Throw an exception if no matching component is found.
*
* @throws {Error}
* @param {string} searchFileName The file name to look for.
* @return {string} Moodle component
*/
function getModuleNameFromFileName(searchFileName) {
searchFileName = fs.realpathSync(searchFileName);
const relativeFileName = searchFileName.replace(`${cwd}${path.sep}`, '').replace(/\\/g, '/');
const [componentPath, file] = relativeFileName.split('/amd/src/');
const fileName = file.replace('.js', '');
// Check subsystems first which require an exact match.
const componentName = ComponentList.getComponentFromPath(componentPath);
if (componentName) {
return `${componentName}/${fileName}`;
}
// This matches the previous PHP behaviour that would throw an exception
// if it couldn't parse an AMD file.
throw new Error(`Unable to find module name for ${searchFileName} (${componentPath}::${file}}`);
}
/**
* This is heavily inspired by the babel-plugin-add-module-exports plugin.
* See: https://github.com/59naga/babel-plugin-add-module-exports
*
* This is used when we detect a module using "export default Foo;" to make
* sure the transpiled code just returns Foo directly rather than an object
* with the default property (i.e. {default: Foo}).
*
* Note: This means that we can't support modules that combine named exports
* with a default export.
*
* @param {String} path
* @param {String} exportObjectName
*/
function addModuleExportsDefaults(path, exportObjectName) {
const rootPath = path.findParent(path => {
return path.key === 'body' || !path.parentPath;
});
// HACK: `path.node.body.push` instead of path.pushContainer(due doesn't work in Plugin.post).
// This is hardcoded to work specifically with AMD.
rootPath.node.body.push(template(`return ${exportObjectName}.default`)());
}
return {
pre() {
this.seenDefine = false;
this.addedReturnForDefaultExport = false;
},
visitor: {
// Plugin ordering is only respected if we visit the "Program" node.
// See: https://babeljs.io/docs/en/plugins.html#plugin-preset-ordering
//
// We require this to run after the other AMD module transformation so
// let's visit the "Program" node.
Program: {
exit(path) {
path.traverse({
CallExpression(path) {
// If we find a "define" function call.
if (!this.seenDefine && path.get('callee').isIdentifier({name: 'define'})) {
// We only want to modify the first instance of define that we find.
this.seenDefine = true;
// Get the Moodle component for the file being processed.
var moduleName = getModuleNameFromFileName(this.file.opts.filename);
// The function signature of `define()` is:
// define = function (name, deps, callback) {...}
// Ensure that if the moduel supplied its own name that it is replaced.
if (path.node.arguments.length > 0) {
// Ensure that there is only one name.
if (path.node.arguments[0].type === 'StringLiteral') {
// eslint-disable-next-line
console.log(`Replacing module name '${path.node.arguments[0].extra.rawValue}' with ${moduleName}`);
path.node.arguments.shift();
}
}
// Add the module name as the first argument to the define function.
path.node.arguments.unshift(types.stringLiteral(moduleName));
// Add a space after the define function in the built file so that previous versions
// of Moodle will not try to add the module name to the file when it's being served
// by PHP. This forces the regex in PHP to not match for this file.
path.node.callee.name = 'define ';
}
// Check for any Object.defineProperty('exports', 'default') calls.
if (!this.addedReturnForDefaultExport && path.get('callee').matchesPattern('Object.defineProperty')) {
const [identifier, prop] = path.get('arguments');
const objectName = identifier.get('name').node;
const propertyName = prop.get('value').node;
if ((objectName === 'exports' || objectName === '_exports') && propertyName === 'default') {
addModuleExportsDefaults(path, objectName);
this.addedReturnForDefaultExport = true;
}
}
},
AssignmentExpression(path) {
// Check for an exports.default assignments.
if (
!this.addedReturnForDefaultExport &&
(
path.get('left').matchesPattern('exports.default') ||
path.get('left').matchesPattern('_exports.default')
)
) {
const objectName = path.get('left.object.name').node;
addModuleExportsDefaults(path, objectName);
this.addedReturnForDefaultExport = true;
}
}
}, this);
}
}
}
};
};
-455
View File
@@ -1,455 +0,0 @@
// 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/>.
/**
* Helper functions for working with Moodle component names, directories, and sources.
*
* @copyright 2019 Andrew Nicols <andrew@nicols.co.uk>
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
"use strict";
/* eslint-env node */
/** @var {Object} A list of subsystems in Moodle */
const componentData = {};
/**
* Load details of all moodle modules.
*
* @returns {object}
*/
const fetchComponentData = () => {
const fs = require('fs');
const path = require('path');
const glob = require('glob');
const gruntFilePath = process.cwd();
if (!Object.entries(componentData).length) {
componentData.subsystems = {};
componentData.pathList = [];
componentData.components = {};
componentData.standardComponents = {};
// Fetch the component definiitions from the distributed JSON file.
const components = JSON.parse(fs.readFileSync(`${gruntFilePath}/lib/components.json`));
const pluginData = JSON.parse(fs.readFileSync(`${gruntFilePath}/lib/plugins.json`));
componentData.pluginTypes = components.plugintypes
const standardPlugins = Object.entries(pluginData.standard).map(
([pluginType, pluginNames]) => {
return pluginNames.map(pluginName => `${pluginType}_${pluginName}`);
}
).reduce((acc, val) => acc.concat(val), []);
// Build the list of moodle subsystems.
componentData.subsystems['public/lib'] = 'core';
componentData.pathList.push(`${process.cwd()}/public/lib`);
for (const [component, thisPath] of Object.entries(components.subsystems)) {
if (thisPath) {
// Prefix "core_" to the front of the subsystems.
componentData.subsystems[thisPath] = `core_${component}`;
componentData.pathList.push(`${process.cwd()}/${thisPath}`);
}
}
// The list of components includes the list of subsystems.
componentData.components = Object.fromEntries(
Object.entries(componentData.subsystems)
.map(([path, name]) => ([path, name]))
);
const subpluginAdder = (subpluginType, subpluginTypePath) => {
glob.sync(`${subpluginTypePath}/*/version.php`).forEach(versionPath => {
const componentPath = fs.realpathSync(path.dirname(versionPath));
const componentName = path.basename(componentPath);
const frankenstyleName = `${subpluginType}_${componentName}`;
componentData.components[`${subpluginTypePath}/${componentName}`] = frankenstyleName;
componentData.pathList.push(componentPath);
});
};
// Go through each of the plugintypes.
Object.entries(components.plugintypes).forEach(([pluginType, pluginTypePath]) => {
// We don't allow any code in this place..?
glob.sync(`${pluginTypePath}/*/version.php`).forEach(versionPath => {
const componentPath = fs.realpathSync(path.dirname(versionPath));
const componentName = path.basename(componentPath);
const frankenstyleName = `${pluginType}_${componentName}`;
componentData.components[`${pluginTypePath}/${componentName}`] = frankenstyleName;
componentData.pathList.push(componentPath);
// Look for any subplugins.
const subPluginConfigurationFile = `${componentPath}/db/subplugins.json`;
if (fs.existsSync(subPluginConfigurationFile)) {
const subpluginList = JSON.parse(fs.readFileSync(fs.realpathSync(subPluginConfigurationFile)));
if (subpluginList.subplugintypes) {
Object.entries(subpluginList.subplugintypes).forEach(([subpluginType, subpluginTypePath]) => {
subpluginAdder(
subpluginType,
`${pluginTypePath}/${componentName}/${subpluginTypePath}`
);
});
} else if (subpluginList.plugintypes) {
Object.entries(subpluginList.plugintypes).forEach(([subpluginType, subpluginTypePath]) => {
subpluginAdder(subpluginType, `public/${subpluginTypePath}`);
});
}
}
});
});
// Create a list of the standard subsystem and plugins.
componentData.standardComponents = Object.fromEntries(
Object.entries(componentData.components).filter(([, name]) => {
if (name === 'core' || name.startsWith('core_')) {
return true;
}
return standardPlugins.indexOf(name) !== -1;
})
);
componentData.componentMapping = Object.fromEntries(
Object.entries(componentData.components).map(([path, name]) => [name, path])
);
}
return componentData;
};
/**
* Get the list of component paths.
*
* @param {string} relativeTo
* @returns {array}
*/
const getComponentPaths = (relativeTo = '') => fetchComponentData().pathList.map(componentPath => {
return componentPath.replace(relativeTo, '');
});
/**
* Get the list of paths to build AMD sources.
*
* @returns {Array}
*/
const getAmdSrcGlobList = () => {
const globList = [];
fetchComponentData().pathList.forEach(componentPath => {
globList.push(`${componentPath}/amd/src/*.js`);
globList.push(`${componentPath}/amd/src/**/*.js`);
});
return globList;
};
/**
* Get the list of paths to build YUI sources.
*
* @param {String} relativeTo
* @returns {Array}
*/
const getYuiSrcGlobList = relativeTo => {
const globList = [];
fetchComponentData().pathList.forEach(componentPath => {
const relativeComponentPath = componentPath.replace(relativeTo, '');
globList.push(`${relativeComponentPath}/yui/src/**/*.js`);
});
return globList;
};
/**
* Get the list of paths to thirdpartylibs.xml.
*
* @param {String} relativeTo
* @returns {Array}
*/
const getThirdPartyLibsList = relativeTo => {
const fs = require('fs');
const path = require('path');
const pathList = fetchComponentData().pathList
.map(componentPath => path.relative(relativeTo, componentPath) + '/thirdpartylibs.xml')
.map(componentPath => componentPath.replace(/\\/g, '/'))
.filter(path => fs.existsSync(path));
pathList.push('lib/thirdpartylibs.xml');
return pathList.sort();
};
/**
* Get the list of thirdparty library paths.
*
* @returns {array}
*/
const getThirdPartyPaths = () => {
const DOMParser = require('@xmldom/xmldom').DOMParser;
const fs = require('fs');
const path = require('path');
const xpath = require('xpath');
const thirdpartyfiles = getThirdPartyLibsList(fs.realpathSync('./'));
const libs = ['node_modules/', 'vendor/'];
const addLibToList = lib => {
if (!lib.match('\\*') && fs.statSync(lib).isDirectory()) {
// Ensure trailing slash on dirs.
lib = lib.replace(/\/?$/, '/');
}
// Look for duplicate paths before adding to array.
if (libs.indexOf(lib) === -1) {
libs.push(lib);
}
};
thirdpartyfiles.forEach(function(file) {
const dirname = path.dirname(file);
const xmlContent = fs.readFileSync(file, 'utf8');
const doc = new DOMParser().parseFromString(xmlContent);
const nodes = xpath.select("/libraries/library/location/text()", doc);
nodes.forEach(function(node) {
let lib = path.posix.join(dirname, node.toString());
addLibToList(lib);
});
});
return libs;
};
/**
* Find the name of the component matching the specified path.
*
* @param {String} path
* @returns {String|null} Name of matching component.
*/
const getComponentFromPath = path => {
const componentList = fetchComponentData().components;
if (componentList.hasOwnProperty(path)) {
return componentList[path];
}
return null;
};
/**
* Check whether the supplied path, relative to the Gruntfile.js, is in a known component.
*
* @param {String} checkPath The path to check. This can be with either Windows, or Linux directory separators.
* @returns {String|null}
*/
const getOwningComponentDirectory = checkPath => {
const path = require('path');
// Fetch all components into a reverse sorted array.
// This ensures that components which are within the directory of another component match first.
const pathList = Object.keys(fetchComponentData().components).sort().reverse();
for (const componentPath of pathList) {
// If the componentPath is the directory being checked, it will be empty.
// If the componentPath is a parent of the directory being checked, the relative directory will not start with ..
if (!path.relative(componentPath, checkPath).startsWith('..')) {
return componentPath;
}
}
return null;
};
/**
* Get the latest tag in a remote GitHub repository.
*
* @param {string} url The remote repository.
* @returns {Array}
*/
const getRepositoryTags = async(url) => {
const gtr = require('git-tags-remote');
try {
const tags = await gtr.get(url);
if (tags !== undefined) {
return tags;
}
} catch (error) {
return [];
}
return [];
};
/**
* Get the list of thirdparty libraries that could be upgraded.
*
* @returns {Array}
*/
const getThirdPartyLibsUpgradable = async() => {
const libraries = getThirdPartyLibsData().filter((library) => !!library.repository);
const upgradableLibraries = [];
const versionCompare = (a, b) => {
if (a === b) {
return 0;
}
const aParts = a.split('.');
const bParts = b.split('.');
for (let i = 0; i < Math.min(aParts.length, bParts.length); i++) {
const aPart = parseInt(aParts[i], 10);
const bPart = parseInt(bParts[i], 10);
if (aPart > bPart) {
// 1.1.0 > 1.0.9
return 1;
} else if (aPart < bPart) {
// 1.0.9 < 1.1.0
return -1;
} else {
// Same version.
continue;
}
}
if (aParts.length > bParts.length) {
// 1.0.1 > 1.0
return 1;
}
// 1.0 < 1.0.1
return -1;
};
for (let library of libraries) {
upgradableLibraries.push(
getRepositoryTags(library.repository).then((tagMap) => {
library.version = library.version.replace(/^v/, '');
const currentVersion = library.version.replace(/moodle-/, '');
const currentMajorVersion = library.version.split('.')[0];
const tags = [...tagMap]
.map((tagData) => tagData[0])
.filter((tag) => !tag.match(/(alpha|beta|rc)/))
.map((tag) => tag.replace(/^v/, ''))
.sort((a, b) => versionCompare(b, a));
if (!tags.length) {
library.warning = "Unable to find any comparable tags.";
return library;
}
library.latestVersion = tags[0];
tags.some((tag) => {
if (!tag) {
return false;
}
// See if the version part matches.
const majorVersion = tag.split('.')[0];
if (majorVersion === currentMajorVersion) {
library.latestSameMajorVersion = tag;
return true;
}
return false;
});
if (versionCompare(currentVersion, library.latestVersion) > 0) {
// Moodle somehow has a newer version than the latest version.
library.warning = `Newer version found: ${currentVersion} > ${library.latestVersion} for ${library.name}`;
return library;
}
if (library.version !== library.latestVersion) {
// Delete version and add it again at the end of the array. That way, current and new will stay closer.
delete library.version;
library.version = currentVersion;
return library;
}
return null;
})
);
}
return (await Promise.all(upgradableLibraries)).filter((library) => !!library);
};
/**
* Get the list of paths to build react sources.
*
* @param {string} relativeTo
* @returns {string[]}
*/
const getReactTsSrcGlobList = (relativeTo = '') => {
const globList = [];
fetchComponentData().pathList.forEach(componentPath => {
const relativeComponentPath = componentPath.replace(relativeTo, '');
globList.push(`${relativeComponentPath}/js/esm/src/**/*.ts`);
globList.push(`${relativeComponentPath}/js/esm/src/**/*.tsx`);
});
return globList.map(componentPath => componentPath.replace(/\\/g, '/'));
};
/**
* Get the list of thirdparty libraries.
*
* @returns {Array}
*/
const getThirdPartyLibsData = () => {
const DOMParser = require('@xmldom/xmldom').DOMParser;
const fs = require('fs');
const xpath = require('xpath');
const path = require('path');
const libraryList = [];
const libraryFields = [
'location',
'name',
'version',
'repository',
];
const thirdpartyfiles = getThirdPartyLibsList(fs.realpathSync('./'));
thirdpartyfiles.forEach(function(libraryPath) {
const xmlContent = fs.readFileSync(libraryPath, 'utf8');
const doc = new DOMParser().parseFromString(xmlContent);
const libraries = xpath.select("/libraries/library", doc);
for (const library of libraries) {
const libraryData = [];
for (const field of libraryFields) {
libraryData[field] = xpath.select(`${field}/text()`, library)?.toString();
}
libraryData.location = path.join(path.dirname(libraryPath), libraryData.location);
libraryList.push(libraryData);
}
});
return libraryList.sort((a, b) => a.location.localeCompare(b.location));
};
module.exports = {
fetchComponentData,
getAmdSrcGlobList,
getComponentFromPath,
getComponentPaths,
getOwningComponentDirectory,
getYuiSrcGlobList,
getThirdPartyLibsList,
getThirdPartyPaths,
getThirdPartyLibsUpgradable,
getReactTsSrcGlobList,
};
-19
View File
@@ -1,19 +0,0 @@
# Moodle JavaScript Documentation
```
.-..-.
_____ | || |
/____/-.---_ .---. .---. .-.| || | .---.
| | _ _ |/ _ \/ _ \/ _ || |/ __ \
* | | | | | || |_| || |_| || |_| || || |___/
|_| |_| |_|\_____/\_____/\_____||_|\_____)
Moodle - the world's open source learning platform
```
## About
This generated documentation includes API documentation for JavaScript written in the AMD and ES2015 module formats within Moodle.
## Related information
See [https://moodledev.io](https://moodledev.io) for other related Developer Documentation.
-131
View File
@@ -1,131 +0,0 @@
// 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/>.
/**
* Helper functions for working with Moodle component names, directories, and sources.
*
* @copyright 2019 Andrew Nicols <andrew@nicols.co.uk>
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
"use strict";
/* eslint-env node */
// Do not include any plugins as stanard.
const plugins = [];
plugins.push('plugins/markdown');
/**
* Get the source configuration.
*
* @return {Object}
*/
const getSource = () => {
const glob = require('glob');
const path = require('path');
const ComponentList = require(path.resolve('.grunt/components.js'));
const thirdPartyPaths = ComponentList.getThirdPartyPaths();
const source = {
include: [],
includePattern: ".+\\.js$",
};
let includeList = [];
ComponentList.getAmdSrcGlobList().forEach(async pattern => {
includeList.push(...glob.sync(pattern));
});
const cwdLength = process.cwd().length + 1;
includeList.forEach(path => {
if (source.include.indexOf(path) !== -1) {
// Ensure no duplicates.
return;
}
const relPath = path.substring(cwdLength);
if (thirdPartyPaths.indexOf(relPath) !== -1) {
return;
}
source.include.push(path);
});
source.include.push('.grunt/jsdoc/README.md');
return source;
};
const tags = {
// Allow the use of unknown tags.
// We have a lot of legacy uses of these.
allowUnknownTags: true,
// We make use of jsdoc and closure dictionaries as standard.
dictionaries: [
'jsdoc',
'closure',
],
};
// Template configuraiton.
const templates = {
cleverLinks: false,
monospaceLinks: false,
};
module.exports = {
opts: {
destination: "./public/jsdoc/",
template: "node_modules/docdash",
},
plugins,
recurseDepth: 10,
source: getSource(),
sourceType: 'module',
tags,
templates,
docdash: {
collapse: true,
search: true,
sort: true,
sectionOrder: [
"Namespaces",
"Modules",
"Events",
"Classes",
"Externals",
"Mixins",
"Tutorials",
"Interfaces"
],
"menu": {
"Developer Docs": {
href: "https://moodledev.io",
target: "_blank",
"class": "menu-item",
id: "devdocs"
},
"MDN Docs": {
href: "https://developer.mozilla.org/en-US/docs/Web/JavaScript",
target: "_blank",
"class": "menu-item",
id: "mdndocs",
},
},
typedefs: true,
},
};
-138
View File
@@ -1,138 +0,0 @@
// 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/>.
import * as Components from '../../components.js';
const componentData = Components.fetchComponentData();
/**
* The standard components shipped with core Moodle.
*
* @type {Object}
*/
export const standardComponents = componentData.standardComponents;
/**
* All components of the current Moodle instance.
*
* @type {Object}
*/
export const allComponents = componentData.components;
/**
* Get all components of the current Moodle instance.
*
* @returns {Array}
*/
export const getAllComponents = () => {
let components = new Map(Object.entries(componentData.pluginTypes).map(([value, path]) => ([path,{
path,
value,
name: `${value} (plugin type)`,
}])));
Object
.entries(componentData.components)
.filter(([path, value]) => Object.values(componentData.standardComponents).includes(value))
.forEach(([path, value]) => {
const entry = {
path,
value,
name: value,
};
if (Object.values(componentData.subsystems).includes(value)) {
if (components.has(path)) {
entry.name = `${value} (subsystem / plugintype)`;
} else {
entry.name = `${value} (subsystem)`;
}
}
components.set(path, entry);
});
return Array.from(components.values());
};
/**
* Whether the specified component is a standard component shipped with core Moodle.
*
* @param {string} componentName
* @returns {boolean}
*/
export const isStandardComponent = (componentName) => {
if (Object.values(componentData.standardComponents).includes(componentName)) {
return true;
}
if (Object.keys(componentData.pluginTypes).includes(componentName)) {
return true;
}
return false;
};
export const rewritePlugintypeAsSubsystem = (componentName) => {
if (Object.keys(componentData.pluginTypes).includes(componentName)) {
const pluginTypePath = componentData.pluginTypes[componentName];
if (Object.keys(componentData.subsystems).includes(pluginTypePath)) {
return true;
}
}
return false;
};
/**
* Whether the specified component is a community component.
*
* @param {string} componentName
* @returns {boolean}
*/
export const isCommunityComponent = (componentName) => {
if (isStandardComponent(componentName)) {
return false;
}
return Object.values(componentData.components).indexOf(componentName) !== -1;
};
/**
* Sort method for components.
*
* This method sorts components putting `core` first, followed by core subsystems, then everything else.
*
* @param {String} a
* @param {String} b
* @returns {Number}
*/
export const sortComponents = (a, b) => {
// Always put 'core' first.
if (a === 'core') {
return -1;
} else if (b === 'core') {
return 1;
}
// Put core subsystems next.
if (a.startsWith('core_') && !b.startsWith('core_')) {
return -1;
} else if (b.startsWith('core_') && !a.startsWith('core_')) {
return 1;
}
// Sort alphabetically for everything else.
return a.localeCompare(b);
};
-85
View File
@@ -1,85 +0,0 @@
#!/usr/bin/env node
// 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/>.
import inquirer from 'inquirer';
import chalk from 'chalk';
import { createNote } from './note.mjs';
import { getInitialValues, getIssueNumberFromBranchName } from './helpers.mjs';
import * as Prompts from './prompts.mjs';
import logger from './logger.mjs';
export default async (options) => {
// Processs the initial values.
const initialValues = getInitialValues(options);
// Fetch information.
const messages = [];
const { issueNumber } = await inquirer.prompt([
Prompts.getIssuePrompt(getIssueNumberFromBranchName()),
], initialValues);
let selection = {};
let notePath;
do {
selection = {};
selection = await inquirer.prompt([
Prompts.getComponentsPrompt(),
Prompts.getTypePrompt(),
Prompts.getMessagePromptInput(),
], initialValues);
if (selection.message === '') {
selection = Object.assign(
selection,
await inquirer.prompt([
Prompts.getMessagePromptEditor(),
]),
);
}
logger.info(`
Creating upgrade note with the following options:
- Issue: ${chalk.bold(issueNumber)}
- Component: ${chalk.bold(selection.components)}
- Type: ${chalk.bold(selection.type)}
- Message:
${chalk.bold(selection.message)}
`);
messages.push({
components: [selection.components],
type: selection.type,
message: selection.message,
});
// Save the note so far.
if (notePath) {
await createNote(issueNumber, messages, notePath);
logger.info(`Updated note at: ${chalk.underline(chalk.bold(notePath))}`);
} else {
notePath = await createNote(issueNumber, messages);
logger.info(`Note created at: ${chalk.underline(chalk.bold(notePath))}`);
}
selection = Object.assign(
selection,
await inquirer.prompt([
Prompts.getAddAnotherPrompt(),
], initialValues),
);
} while (selection.addAnother);
};
-357
View File
@@ -1,357 +0,0 @@
#!/usr/bin/env node
// 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/>.
import chalk from 'chalk';
import { getAllComponents } from './components.mjs';
import { getCombinedNotesByComponent, deleteAllNotes } from './note.mjs';
import { getNoteName } from './noteTypes.mjs';
import { writeFile, readFile, unlink } from 'fs/promises';
import { join as joinPath } from 'path';
import logger from './logger.mjs';
import { getCurrentVersion } from './helpers.mjs';
/**
* Helper to fetch the current notes from a file.
*
* @param {string} file
* @returns {Promise<string>}
*/
const getCurrentNotes = async (file) => {
try {
return await readFile(file, 'utf8');
} catch (error) {
return null;
}
}
/**
* Update the UPGRADING.md file.
*
* @param {string} upgradeNotes
* @param {Object} options
* @param {boolean} options.deleteNotes
* @returns {Promise<void>}
*/
const updateUpgradeNotes = async (upgradeNotes, options) => {
const fileName = 'UPGRADING.md';
// Write the notes to a file.
logger.info(`Writing notes to ${chalk.underline(chalk.bold(fileName))}`);
// Prepend to the existing file.
const existingContent = await getCurrentNotes(fileName);
if (existingContent) {
await writeFile(fileName, getUpdatedNotes(existingContent, upgradeNotes));
} else {
// This should not normally happen.
await writeFile(fileName, upgradeNotes);
}
if (options.deleteNotes) {
logger.warn(`>>> Deleting all notes <<<`)
// Delete the notes.
deleteAllNotes();
}
};
/**
* Create the current summary notes.
*
* @param {string} upgradeNotes
* @returns {Promise<void>}
*/
const createCurrentSummary = async (upgradeNotes) => {
const fileName = 'UPGRADING-CURRENT.md';
const notes = `# Moodle upgrade notes\n\n${upgradeNotes}`;
await writeFile(fileName, notes);
logger.info(`Running upgrade notes written to ${chalk.underline(chalk.bold(fileName))}`);
};
/**
* Get the indexes of the lines that contain the version headings.
*
* @param {array<string>} lines
* @returns {array<object>}
*/
const getVersionLineIndexes = (lines) => {
const h2Indexes = [];
lines.forEach((line, index) => {
const matches = line.match(/^##\s(?<version>.*)$/);
if (matches) {
h2Indexes.push({
index,
line,
version: matches.groups.version,
});
}
});
return h2Indexes;
};
/**
* Find the index of the Unreleased heading.
*
* @param {array<object>} versionHeadings
* @returns {number}
*/
const findUnreleasedHeadingIndex = (versionHeadings) => versionHeadings.findIndex((heading) => {
if (heading.version === 'Unreleased') {
// Used if version cannot be guessed.
return true;
}
if (heading.version.endsWith('+')) {
// Weekly release for a stable branch.
return true;
}
if (heading.version.match(/beta|rc\d/)) {
// Beta and RC rolls are treated as weeklies.
return true;
}
if (heading.version.endsWith('dev')) {
// Development version.
return true;
}
return false;
});
/**
* Get the before and after content, to facilitate replacing any existing Unreleased notes.
*
* @param {array<string>} lines
* @returns {Object} {beforeContent: string, afterContent: string}
*/
const getBeforeAndAfterContent = (lines) => {
const existingLines = lines.split('\n');
const versionHeadings = getVersionLineIndexes(existingLines);
if (versionHeadings.length > 0) {
const unreleasedHeadingIndex = findUnreleasedHeadingIndex(versionHeadings);
if (unreleasedHeadingIndex !== -1) {
const beforeContent = existingLines.slice(0, versionHeadings[unreleasedHeadingIndex].index).join('\n');
if (versionHeadings.length > unreleasedHeadingIndex + 1) {
const afterContent = existingLines.slice(versionHeadings[unreleasedHeadingIndex + 1].index).join('\n');
return {
beforeContent,
afterContent,
};
}
return {
beforeContent,
afterContent: '',
};
}
return {
beforeContent: existingLines.slice(0, versionHeadings[0].index).join('\n'),
afterContent: existingLines.slice(versionHeadings[0].index).join('\n'),
};
}
return {
beforeContent: existingLines.join('\n'),
afterContent: '',
}
};
/**
* Get the notes for the component.
*
* @param {string} types
* @param {Number} headingLevel
* @returns {string}
*/
const getNotesForComponent = (types, headingLevel) => {
let upgradeNotes = '';
Object.entries(types).forEach(([type, notes]) => {
upgradeNotes += '#'.repeat(headingLevel);
upgradeNotes += ` ${getNoteName(type)}\n\n`;
notes.forEach(({ message, issueNumber }) => {
// Split the message into lines, removing empty lines.
const messageLines = message
.split('\n')
// Remove empty lines between tables, and list entries, but not after lists.
.filter((line, index, lines) => {
if (line.trim().length === 0) {
// This line is empty.
// If it's the first line in the file, remove it.
if (index === 0) {
return false;
}
// This is the last line in the file, remove it.
if (index === lines.length - 1) {
return false;
}
// If the previous line relates to a table, remove this line.
if (lines[index - 1].match(/^\s*\|/)) {
return false;
}
// If the next line is also empty, do not remove this line.
if (lines[index + 1].trim().length === 0) {
return true;
}
// Do not remove the line if the previous line was a list item.
if (lines[index - 1].match(/^\s*[-*]\s/)) {
return true;
}
if (lines[index - 1].match(/^\s*\d+\.\s/)) {
return true;
}
// Preserve all other empty lines by default.
return true;
}
// Keep any line which has content.
return true;
});
const firstLine = messageLines.shift().trim();
upgradeNotes += `- ${firstLine}\n`;
messageLines
.forEach((line) => {
upgradeNotes += ` ${line}`.trimEnd() + `\n`;
});
upgradeNotes += `\n For more information see [${issueNumber}](https://tracker.moodle.org/browse/${issueNumber})\n`;
});
upgradeNotes += '\n';
});
return upgradeNotes;
};
/**
* Get the updated notes mixed with existing content.
*
* @param {string} existingContent
* @param {string} upgradeNotes
*/
const getUpdatedNotes = (existingContent, upgradeNotes) => {
const { beforeContent, afterContent } = getBeforeAndAfterContent(existingContent);
const newContent = `${beforeContent}\n${upgradeNotes}\n${afterContent}`
.split('\n')
.filter((line, index, lines) => {
if (line === '' && lines[index - 1] === '') {
// Remove multiple consecutive empty lines.
return false;
}
return true;
})
.join('\n');
return newContent;
};
/**
* Update the notes for each component.
*/
const updateComponentNotes = (
notes,
version,
notesFileName = 'UPGRADING.md',
removeEmpty = false,
) => {
return getAllComponents().map(async (component) => {
logger.verbose(`Updating notes for ${component.name} into ${component.path}`);
const fileName = joinPath(component.path, notesFileName);
const existingContent = await getCurrentNotes(fileName);
if (!existingContent) {
if (!notes[component.value]) {
// No existing notes, and no new notes to add.
return;
}
} else {
if (!notes[component.value]) {
// There is existing content, but nothing to add.
if (removeEmpty) {
logger.verbose(`Removing empty notes file ${fileName}`);
await unlink(fileName);
}
return;
}
}
const componentNotes = notes[component.value];
let upgradeNotes = `## ${version}\n\n`;
upgradeNotes += getNotesForComponent(componentNotes, 3);
if (existingContent) {
await writeFile(fileName, getUpdatedNotes(existingContent, upgradeNotes));
} else {
await writeFile(
fileName,
`# ${component.name} Upgrade notes\n\n${upgradeNotes}`,
);
}
});
}
/**
* Generate the upgrade notes for a new release.
*
* @param {string|undefined} version
* @param {Object} options
* @param {boolean} options.generateUpgradeNotes
* @param {boolean} options.deleteNotes
* @returns {Promise<void>}
*/
export default async (version, options = {}) => {
const notes = await getCombinedNotesByComponent();
if (Object.keys(notes).length === 0) {
logger.warn('No notes to generate');
return;
}
if (!version) {
version = await getCurrentVersion();
}
// Generate the upgrade notes for this release.
// We have
// - a title with the release name
// - the change types
// - which contain the components
// - which document each change
let upgradeNotes = `## ${version}\n\n`;
Object.entries(notes).forEach(([component, types]) => {
upgradeNotes += `### ${component}\n\n`;
upgradeNotes += getNotesForComponent(types, 4);
});
await Promise.all([
createCurrentSummary(upgradeNotes),
...updateComponentNotes(notes, version, 'UPGRADING-CURRENT.md', true),
]);
if (options.generateUpgradeNotes) {
await Promise.all(updateComponentNotes(notes, version));
await updateUpgradeNotes(upgradeNotes, options);
}
};
-244
View File
@@ -1,244 +0,0 @@
// 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/>.
import chalk from 'chalk';
import branchName from 'current-git-branch';
import { isStandardComponent, isCommunityComponent, rewritePlugintypeAsSubsystem } from './components.mjs';
import { isValidNoteName } from './noteTypes.mjs';
import logger from './logger.mjs';
import { readFile } from 'fs/promises';
/**
* Validate an issue number input
*
* @param {string} input
* @returns {string|boolean}
*/
export const validateIssueNumber = (input) => {
if (!input) {
return 'You must provide a tracker issue number';
}
if (input.match(/^[a-zA-Z]*-\d+$/)) {
return true;
}
if (input.match(/^\d+$/)) {
return true;
}
return 'The issue number was not recognised as a valid issue number';
};
/**
* Format an issue number input.
*
* @param {string} input
* @returns {string}
*/
export const formatIssueNumber = (input) => {
if (input.match(/^[a-zA-Z]*-\d+$/)) {
return input;
}
if (input.match(/^\d+$/)) {
return `MDL-${input}`;
}
return input;
};
/**
* Get the issue number, based off current git branch name
*
* @returns {string|null}
*/
export const getIssueNumberFromBranchName = () => {
const issueNumber = String(branchName()).match(/^[a-zA-Z]*-\d+/);
if (issueNumber) {
return formatIssueNumber(issueNumber[0]);
}
return null;
};
/**
* Validate a component.
*
* @param {string} input
* @returns {string|boolean}
*/
export const validateComponent = (input) => {
if (isStandardComponent(input)) {
return true;
}
if (isCommunityComponent(input)) {
return 'Currently only core plugins are supported.';
}
return 'The component was not recognised as a standard component';
};
export const formatComponent = (input) => {
if (rewritePlugintypeAsSubsystem(input)) {
return `core_${input}`;
}
return input;
}
/**
* Get the initial values from the options.
*
* @param {object} options
* @returns {object}
*/
export const getInitialValues = (options) => {
const initialValues = {};
const type = getInitialTypeValue(options);
if (type) {
initialValues.type = type;
}
const issueNumber = getInitialIssueValue(options);
if (issueNumber) {
initialValues.issueNumber = issueNumber;
}
const component = getInitialComponentValue(options);
if (component) {
initialValues.components = component;
}
const message = getInitialMessageValue(options);
if (message) {
initialValues.message = message
initialValues.addAnother = false;
}
return initialValues;
};
/**
* Get the initial type value.
*
* @param {Object} options
* @returns {string|undefined}
*/
const getInitialTypeValue = (options) => {
if (!options.type) {
return;
}
options.type = options.type.trim().toLowerCase();
if (isValidNoteName(options.type)) {
return options.type;
}
logger.warn(`Note type "${chalk.underline(chalk.red(options.type))}" is not valid.`);
};
/**
* Get the initial issue number value.
*
* @param {Object} options
* @returns {string|undefined}
*/
const getInitialIssueValue = (options) => {
if (!options.issue) {
return;
}
options.issue = options.issue.trim().toUpperCase();
const issueNumberValidated = validateIssueNumber(options.issue);
if (issueNumberValidated === true) {
const issueNumber = formatIssueNumber(options.issue);
if (issueNumber !== options.issue) {
logger.warn(
`Issue number "${chalk.underline(chalk.red(options.issue))}" was updated to ` +
`"${chalk.underline(chalk.green(issueNumber))}"`
);
}
return issueNumber;
} else {
logger.warn(`Issue number "${chalk.underline(chalk.red(options.issue))}" is not valid: ${issueNumberValidated}`);
}
};
/**
* Get the initial component value.
*
* @param {Object} options
* @returns {string|undefined}
*/
const getInitialComponentValue = (options) => {
if (!options.component) {
return;
}
options.component = options.component.trim().toLowerCase();
const componentValidated = validateComponent(options.component);
if (componentValidated === true) {
const component = formatComponent(options.component);
if (component !== options.component) {
logger.warn(
`Component "${chalk.underline(chalk.red(options.component))}" was updated to ` +
`"${chalk.underline(chalk.green(component))}"`
);
}
return component;
} else {
logger.warn(`Component "${chalk.underline(chalk.red(options.component))}" is not valid: ${componentValidated}`);
}
};
/**
* Get the initial message value.
*
* @param {Object} options
* @returns {string|undefined}
*/
const getInitialMessageValue = (options) => {
if (!options.message) {
return;
}
return options.message.trim();
};
/**
* Get the current version from the project /version.php file.
*
* @returns {Promise<string>}
*/
export const getCurrentVersion = async () => {
const versionRegex = new RegExp(/^ *\$release *= *['\"](?<release>[^ \+]+\+?) *\(Build:.*/m);
try {
const versionFile = await readFile('public/version.php', 'utf8');
const match = versionFile.match(versionRegex);
if (match) {
return match.groups.release;
}
} catch(error) {
logger.error('Unable to read the version file');
}
return "Unreleased";
}
-30
View File
@@ -1,30 +0,0 @@
#!/usr/bin/env node
// 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/>.
import winston from 'winston';
const logger = winston.createLogger({
level: 'info',
format: winston.format.combine(
winston.format.colorize(),
winston.format.simple()
),
transports: [
new winston.transports.Console(),
],
});
export default logger;
-194
View File
@@ -1,194 +0,0 @@
// 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/>.
import yaml from 'js-yaml';
import path from 'path';
import { writeFile, mkdir, readdir, readFile, unlink } from 'fs/promises';
import { isValidNoteName, sortNoteTypes } from './noteTypes.mjs';
import { sortComponents } from './components.mjs';
const unreleasedPath = path.resolve('.upgradenotes');
/**
* Get the filename for the note.
*
* @param {string} issueNumnber The issue number
* @returns {string}
*/
const getFilename = (issueNumber) => {
const dateTimeFormat = new Intl.DateTimeFormat(undefined, {
year: 'numeric',
month: '2-digit',
day: '2-digit',
hour: '2-digit',
minute: '2-digit',
second: '2-digit',
fractionalSecondDigits: 2,
timeZone: 'UTC',
});
const date = Object.fromEntries(
dateTimeFormat.formatToParts(new Date())
.filter((p) => p.type !== 'literal')
.map((p) => ([p.type, p.value]))
);
const dateString = [
date.year,
date.month,
date.day,
date.hour,
date.minute,
date.second,
date.fractionalSecond,
].join('');
return `${issueNumber}-${dateString}.yml`;
};
/**
* Create a new note.
*
* @param {string} issueNumber
* @param {[type: string]: {message: string}} messages
* @returns {string} The path to the note on disk
*/
export const createNote = async (
issueNumber,
messages,
notePath,
) => {
const note = {
issueNumber,
notes: {},
};
messages.forEach(({components, type, message}) => {
note.notes[components] = note.notes[components] || [];
note.notes[components].push({message, type});
});
if (!notePath) {
notePath = path.resolve(unreleasedPath, getFilename(issueNumber));
}
const noteContent = yaml.dump(note);
await mkdir(unreleasedPath, {recursive: true});
await writeFile(notePath, noteContent);
return notePath;
};
/**
* Get all unreleased notes.
*
* @returns {Promise<{issueNumber: string, components: string[], types: {[type: string]: {message: string}[]}}[]>
*/
export const getAllNotes = async () => {
const files = await readdir(unreleasedPath);
const notes = files
.filter((file) => file.endsWith('.yml'))
.map(async (file) => {
const filePath = path.resolve(unreleasedPath, file);
const fileContent = await readFile(filePath, 'utf8');
return {
...yaml.load(fileContent),
filePath,
};
});
return Promise.all(notes);
};
/**
* Get the list of notes, grouped by note type, then component.
*
* @returns {Promise<{[type: string]: {[components: string]: {message: string, issueNumber: string}[]}}>}
*/
export const getCombinedNotes = async () => {
const notes = await getAllNotes();
const combinedNotes = {};
notes.forEach((note) => {
Object.entries(note.notes).forEach(([components, data]) => {
data.forEach((entry) => {
if (!isValidNoteName(entry.type)) {
throw new Error(`Invalid note type: "${entry.type}" in file ${note.filePath}`);
}
combinedNotes[entry.type] = combinedNotes[entry.type] || {};
combinedNotes[entry.type][components] = combinedNotes[entry.type][components] || [];
combinedNotes[entry.type][components].push({message: entry.message, issueNumber: note.issueNumber});
});
});
});
return combinedNotes;
};
/**
* Get the list of notes, grouped by component, then by note type.
*
* @returns {Promise<{[component: string]: {[type: string]: {message: string, issueNumber: string}[]}}>}
*/
export const getCombinedNotesByComponent = async () => {
const notes = await getAllNotes();
const combinedNotes = {};
notes.forEach((note) => {
Object.entries(note.notes).forEach(([component, data]) => {
combinedNotes[component] = combinedNotes[component] || {};
data.forEach((entry) => {
if (!isValidNoteName(entry.type)) {
throw new Error(`Invalid note type: "${entry.type}" in file ${note.filePath}`);
}
combinedNotes[component][entry.type] = combinedNotes[component][entry.type] || [];
combinedNotes[component][entry.type].push({
component,
message: entry.message,
issueNumber: note.issueNumber,
type: entry.type,
});
});
});
});
// Sort notes by note type.
Object.entries(combinedNotes).forEach(([component, types]) => {
combinedNotes[component] = Object.fromEntries(
Object.entries(types).sort(([a], [b]) => sortNoteTypes(a, b))
);
});
// Sort components.
return Object.fromEntries(
Object.entries(combinedNotes).sort(([a], [b]) => sortComponents(a, b))
);
};
/**
* Delete all unreleased notes.
*
* @returns {Promise<void>}
*/
export const deleteAllNotes = async () => {
const files = await readdir(unreleasedPath);
return Promise.all(
files
.filter((item, index) => files.indexOf(item) === index)
.filter((file) => file.endsWith('.yml'))
.map((file) => unlink(`${unreleasedPath}/${file}`))
);
};
-80
View File
@@ -1,80 +0,0 @@
// 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/>.
/**
* The note types.
*
* Matches the suggested order in https://keepachangelog.com/en/1.1.0/.
* @type {Object<string, string>}
*/
const noteTypes = {
'improved': 'Added',
'changed': 'Changed',
'deprecated': 'Deprecated',
'removed': 'Removed',
'fixed': 'Fixed',
};
/**
* The preferred order of note types.
*
* @type {string[]}
*/
const preferredOrder = Object.keys(noteTypes);
/**
* Comparison method to sort note types.
*
* @param {String} a
* @param {String} b
* @returns {Number}
*/
export const sortNoteTypes = (a, b) => {
const aIndex = preferredOrder.indexOf(a);
const bIndex = preferredOrder.indexOf(b);
if (aIndex === -1) {
return 1;
}
if (bIndex === -1) {
return -1;
}
return aIndex - bIndex;
};
/**
* Get the note names.
*
* @returns {string[]}
*/
export const getNoteNames = () => Object.keys(noteTypes);
/**
* Get the human-readable note name.
*
* @param {string} type
* @returns {string}
*/
export const getNoteName = (type) => noteTypes[type];
/**
* Whether the note name is valid.
*
* @param {string} type
* @returns {boolean}
*/
export const isValidNoteName = (type) => noteTypes[type] !== undefined;
-153
View File
@@ -1,153 +0,0 @@
// 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/>.
import inquirer from 'inquirer';
import SearchList from 'inquirer-search-list';
import { getNoteNames } from './noteTypes.mjs';
import { getAllComponents } from './components.mjs';
import {
formatComponent,
formatIssueNumber,
validateComponent,
validateIssueNumber,
} from './helpers.mjs';
/**
* A Search List which accepts an initial value.
*/
class SearchListWithInitialValue extends SearchList {
constructor(options, ...args) {
super(options, ...args);
if (options.default) {
const pointer = this.filterList.findIndex((item) => {
return item.value === options.default;
});
if (pointer > -1) {
this.pointer = pointer;
}
}
}
}
inquirer.registerPrompt('search-list', SearchListWithInitialValue);
/**
* Get the issue type prompt.
*
* @param {string} defaultData The initially selected value
* @returns {Object}
*/
export const getTypePrompt = (defaultData) => ({
default: defaultData,
type: 'search-list',
message: 'Type of change',
name: 'type',
choices: getNoteNames(),
validate: (selection) => {
if (selection.length < 1) {
return 'You must select at least one type of change';
}
return true;
},
});
/**
* Get the component prompt.
*
* @param {string} [defaultValue='core'] The initally selected value.
* @returns
*/
export const getComponentsPrompt = (defaultValue) => {
if (!defaultValue ) {
defaultValue = 'core';
}
return {
choices: getAllComponents(),
default: defaultValue,
type: 'search-list',
message: 'Component',
name: 'components',
validate: validateComponent,
filter: formatComponent,
};
};
/**
* Get the issue number prompt as an inline input.
*
* @param {string} defaultData
* @returns {object}
*/
export const getIssuePrompt = (defaultData) => ({
default: defaultData,
type: 'input',
message: 'Tracker issue number',
name: 'issueNumber',
validate: validateIssueNumber,
filter: formatIssueNumber,
});
/**
* Get a message prompt.
*
* @param {string} defaultData
* @returns
*/
export const getMessagePromptEditor = (defaultData) => ({
default: defaultData,
type: process.stdin.isTTY ? 'editor' : 'input',
postfix: '.md',
message: 'Message',
name: 'message',
waitUserInput: false,
validate: (input) => {
if (!input) {
return 'You must provide a message';
}
return true;
},
// Remove any trailing whitespace.
filter: (input) => input.split('\n').map((line) => line.trimEnd()).join('\n'),
});
/**
* Get a message prompt.
*
* @param {string} defaultData
* @returns
*/
export const getMessagePromptInput = (defaultData) => ({
default: defaultData,
type: 'input',
message: 'Message (leave empty to use editor)',
name: 'message',
filter: (input) => input.trim(),
});
/**
* Get a prompt to ask the user if they wish to add another entry.
*
* @returns {Object}
*/
export const getAddAnotherPrompt = () => ({
type: 'confirm',
message: 'Do you want to add another note?',
default: false,
name: 'addAnother',
});
-58
View File
@@ -1,58 +0,0 @@
#!/usr/bin/env node
// 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/>.
import { getAllComponents } from './components.mjs';
import { getCombinedNotesByComponent } from './note.mjs';
import logger from './logger.mjs';
import { existsSync } from 'fs';
/**
* Generate links to component-specific upgrade notes for each component.
*
* @param {string|undefined} tag The git tag to link to
* @returns {Promise<void>}
*/
export default async (tag) => {
const notes = await getCombinedNotesByComponent();
if (Object.keys(notes).length === 0) {
logger.warn('No notes to generate');
return;
}
if (!tag) {
logger.error('No tag provided');
return;
}
// Generate the links for the components which have upgrade notes in this release.
let upgradeNotes = `### Component API updates\n<!--cspell: disable -->\n\n`;
const componentList = Object.fromEntries(
Object.values(getAllComponents()).map(({path, value}) => [value, path]),
);
Object.entries(notes)
.map(([component]) => ({
component,
componentPath: componentList[component],
}))
.filter(({ componentPath }) => existsSync(`./${componentPath}/UPGRADING.md`))
.forEach(({component, componentPath}) => {
upgradeNotes += `- [${component}](https://github.com/moodle/moodle/blob/${tag}/${componentPath}/UPGRADING.md)\n`;
});
console.log(upgradeNotes);
};
-142
View File
@@ -1,142 +0,0 @@
// 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/>.
/* jshint node: true, browser: false */
/* eslint-env node */
/**
* Component Library build tasks.
*
* @copyright 2021 Andrew Nicols
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
module.exports = grunt => {
/**
* Get a child path of the component library.
*
* @param {string} path
* @returns {string}
*/
const getCLPath = path => `public/admin/tool/componentlibrary/${path}`;
/**
* Get a spawn handler.
*
* This is a generic function to write the spawn output, and then to exit if required and mark the async task as
* complete.
*
* @param {Promise} done
* @returns {function}
*/
const getSpawnHandler = done => (error, result, code) => {
grunt.log.write(result);
if (error) {
grunt.log.error(result.stdout);
process.exit(code);
}
done();
};
/**
* Spawn a function against Node with the provided args.
*
* @param {array} args
* @returns {object}
*/
const spawnNodeCall = (args) => grunt.util.spawn({
cmd: 'node',
args,
}, getSpawnHandler(grunt.task.current.async()));
/**
* Build the docs using Hugo.
*
* @returns {Object} Reference to the spawned task
*/
const docsBuild = () => spawnNodeCall([
'node_modules/hugo-bin/cli.js',
'--config', getCLPath('config.yml'),
'--cleanDestinationDir',
]);
/**
* Build the docs index using the hugo-lunr-indexer.
*
* @returns {Object} Reference to the spawned task
*/
const indexBuild = () => spawnNodeCall([
'node_modules/hugo-lunr-indexer/bin/hli.js',
'-i', getCLPath('content/**'),
'-o', getCLPath('hugo/site/data/my-index.json'),
'-l', 'yaml',
'-d', '---',
]);
/**
* Build the hugo CSS.
*
* @returns {Object} Reference to the spawned task
*/
const cssBuild = () => spawnNodeCall([
'node_modules/sass/sass.js',
'--style', 'expanded',
'--source-map',
'--embed-sources',
'--precision', 6,
'--load-path', `${process.cwd()}/public`,
getCLPath('hugo/scss/docs.scss'),
getCLPath('hugo/dist/css/docs.css'),
]);
// Register the various component library tasks.
grunt.registerTask('componentlibrary:docsBuild', 'Build the component library', docsBuild);
grunt.registerTask('componentlibrary:cssBuild', 'Build the component library', cssBuild);
grunt.registerTask('componentlibrary:indexBuild', 'Build the component library', indexBuild);
grunt.registerTask('componentlibrary', 'Build the component library', [
'componentlibrary:docsBuild',
'componentlibrary:cssBuild',
'componentlibrary:indexBuild',
]);
grunt.config.merge({
watch: {
componentLibraryDocs: {
files: [
getCLPath('content/**/*.md'),
getCLPath('hugo'),
],
tasks: ['componentlibrary:docsBuild', 'componentlibrary:indexBuild'],
},
componentLibraryCSS: {
files: [
getCLPath('hugo/scss/**/*.scss'),
'hugo',
],
tasks: ['componentlibrary:cssBuild'],
},
},
});
// Add the 'componentlibrary' task as a startup task.
grunt.moodleEnv.startupTasks.push('componentlibrary');
return {
docsBuild,
cssBuild,
indexBuild,
};
};
-72
View File
@@ -1,72 +0,0 @@
// 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/>.
/* jshint node: true, browser: false */
/* eslint-env node */
/**
* @copyright 2021 Andrew Nicols
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
module.exports = grunt => {
const files = grunt.moodleEnv.files;
// Project configuration.
grunt.config.merge({
eslint: {
// Even though warnings dont stop the build we don't display warnings by default because
// at this moment we've got too many core warnings.
// To display warnings call: grunt eslint --show-lint-warnings
// To fail on warnings call: grunt eslint --max-lint-warnings=0
// Also --max-lint-warnings=-1 can be used to display warnings but not fail.
options: {
quiet: (!grunt.option('show-lint-warnings')) && (typeof grunt.option('max-lint-warnings') === 'undefined'),
maxWarnings: ((typeof grunt.option('max-lint-warnings') !== 'undefined') ? grunt.option('max-lint-warnings') : -1)
},
// Check AMD src files.
amd: {src: files ? files : grunt.moodleEnv.amdSrc},
// Check YUI module source files.
yui: {src: files ? files : grunt.moodleEnv.yuiSrc},
// Check React source files.
'react': {
options: {
fix: true,
},
src: files ? files : grunt.moodleEnv.reactSrc,
},
},
});
grunt.loadNpmTasks('grunt-eslint');
// On watch, we dynamically modify config to build only affected files. This
// method is slightly complicated to deal with multiple changed files at once (copied
// from the grunt-contrib-watch readme).
let changedFiles = Object.create(null);
const onChange = grunt.util._.debounce(function() {
const files = Object.keys(changedFiles);
grunt.config('eslint.amd.src', files);
grunt.config('eslint.yui.src', files);
changedFiles = Object.create(null);
}, 200);
grunt.event.on('watch', (action, filepath) => {
changedFiles[filepath] = action;
onChange();
});
};
-92
View File
@@ -1,92 +0,0 @@
// 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/>.
/* jshint node: true, browser: false */
/* eslint-env node */
/**
* @copyright 2021 Andrew Nicols
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
module.exports = grunt => {
/**
* Get the list of feature files to pass to the gherkin linter.
*
* @returns {Array}
*/
const getGherkinLintTargets = () => {
if (grunt.moodleEnv.files) {
// Specific files were requested. Only check these.
return grunt.moodleEnv.files;
}
if (grunt.moodleEnv.inComponent) {
return [`${grunt.moodleEnv.runDir}/tests/behat/*.feature`];
}
return ['**/tests/behat/*.feature'];
};
const handler = function() {
const done = this.async();
const options = grunt.config('gherkinlint.options');
// Grab the gherkin-lint linter and required scaffolding.
const linter = require('gherkin-lint/dist/linter.js');
const featureFinder = require('gherkin-lint/dist/feature-finder.js');
const configParser = require('gherkin-lint/dist/config-parser.js');
const formatter = require('gherkin-lint/dist/formatters/stylish.js');
// Run the linter.
return linter.lint(
featureFinder.getFeatureFiles(grunt.file.expand(options.files)),
configParser.getConfiguration(configParser.defaultConfigFileName)
)
.then(results => {
// Print the results out uncondtionally.
formatter.printResults(results);
return results;
})
.then(results => {
// Report on the results.
// The done function takes a bool whereby a falsey statement causes the task to fail.
return results.every(result => result.errors.length === 0);
})
.then(done); // eslint-disable-line promise/no-callback-in-promise
};
grunt.registerTask('gherkinlint', 'Run gherkinlint against the current directory', handler);
grunt.config.set('gherkinlint', {
options: {
files: getGherkinLintTargets(),
}
});
grunt.config.merge({
watch: {
gherkinlint: {
files: [grunt.moodleEnv.inComponent ? 'tests/behat/*.feature' : '**/tests/behat/*.feature'],
tasks: ['gherkinlint'],
},
},
});
// Add the 'gherkinlint' task as a startup task.
grunt.moodleEnv.startupTasks.push('gherkinlint');
return handler;
};
-139
View File
@@ -1,139 +0,0 @@
// 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/>.
/* jshint node: true, browser: false */
/* eslint-env node */
/**
* @copyright 2021 Andrew Nicols
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
module.exports = grunt => {
/**
* Generate the PHPCS configuration.
*
* @param {Object} thirdPartyPaths
*/
const phpcsIgnore = (thirdPartyPaths) => {
const {toXML} = require('jstoxml');
const config = {
_name: 'ruleset',
_attrs: {
name: "MoodleCore",
},
_content: [
{
rule: {
_attrs: {
ref: './phpcs.xml.dist',
},
},
},
],
};
thirdPartyPaths.forEach(library => {
config._content.push({
'exclude-pattern': library,
});
});
grunt.file.write('phpcs.xml', toXML(config, {
header: true,
indent: ' ',
}) + "\n");
};
/**
* Extracts ignore entries from a local ignore file.
*
* @param {string} componentPath the file path to the component, relative to the code base directory
* @param {string} ignoreFilePath the path to the ignore file
* @return {array} array of ignore paths to be included in the global ignore files
*/
const getEntriesFromLocalIgnoreFile = (componentPath, ignoreFilePath) => {
const ignorePaths = [];
if (grunt.file.exists(ignoreFilePath)) {
const ignoreFile = grunt.file.read(ignoreFilePath);
const entries = ignoreFile.split('\n');
entries.forEach(entry => {
entry = entry.trim();
if (entry.length > 0 && !entry.startsWith('#') && !entry.startsWith('!')) {
while (entry.startsWith('/')) {
entry = entry.substring(1);
}
ignorePaths.push(componentPath + '/' + entry);
}
});
}
return ignorePaths;
};
/**
* Generate ignore files (utilising thirdpartylibs.xml data)
*/
const handler = function() {
const path = require('path');
const ComponentList = require(path.join(process.cwd(), '.grunt', 'components.js'));
// An array of paths to third party directories.
const thirdPartyPaths = ComponentList.getThirdPartyPaths();
const localStylelintIgnorePaths = [];
const localEslintIgnorePaths = [];
ComponentList.getComponentPaths(process.cwd() + '/').forEach(componentPath => {
const localEslintIgnorePath = process.cwd() + '/' + componentPath + '/.eslintignore';
const localEslintIgnoreEntries = getEntriesFromLocalIgnoreFile(componentPath, localEslintIgnorePath);
if (localEslintIgnoreEntries.length > 0) {
localEslintIgnorePaths.push(...localEslintIgnoreEntries);
}
const localStylelintIgnorePath = process.cwd() + '/' + componentPath + '/.stylelintignore';
const localStylelintIgnoreEntries = getEntriesFromLocalIgnoreFile(componentPath, localStylelintIgnorePath);
if (localStylelintIgnoreEntries.length > 0) {
localStylelintIgnorePaths.push(...localStylelintIgnoreEntries);
}
});
// Generate .eslintignore.
const eslintIgnores = [
'# Generated by "grunt ignorefiles"',
// Do not ignore the .grunt directory.
'!/.grunt',
// Ignore all yui/src meta directories and build directories.
'*/**/yui/src/*/meta/',
'*/**/build/',
].concat(thirdPartyPaths).concat(localEslintIgnorePaths);
grunt.file.write('.eslintignore', eslintIgnores.join('\n') + '\n');
// Generate .stylelintignore.
const stylelintIgnores = [
'# Generated by "grunt ignorefiles"',
'**/yui/build/*',
'public/theme/boost/style/moodle.css',
'public/theme/classic/style/moodle.css',
'jsdoc/styles/*.css',
'public/admin/tool/componentlibrary/hugo/dist/css/docs.css',
].concat(thirdPartyPaths).concat(localStylelintIgnorePaths);
grunt.file.write('.stylelintignore', stylelintIgnores.join('\n') + '\n');
phpcsIgnore(thirdPartyPaths);
};
grunt.registerTask('ignorefiles', 'Generate ignore files for linters', handler);
return handler;
};
-218
View File
@@ -1,218 +0,0 @@
// 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/>.
/* jshint node: true, browser: false */
/* eslint-env node */
/**
* @copyright 2021 Andrew Nicols
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
/**
* Function to generate the destination for the minification task
* (e.g. build/file.min.js). This function will be passed to
* the rename property of files array when building dynamically:
* http://gruntjs.com/configuring-tasks#building-the-files-object-dynamically
*
* @param {String} destPath the current destination
* @param {String} srcPath the matched src path
* @return {String} The rewritten destination path.
*/
const babelRename = function(destPath, srcPath) {
destPath = srcPath.replace(`amd/src`, `amd/build`);
destPath = destPath.replace(/\.js$/, '.min.js');
return destPath;
};
module.exports = grunt => {
// Load the React build tasks.
require('./react')(grunt);
// Load the Ignorefiles tasks.
require('./ignorefiles')(grunt);
// Load the Shifter tasks.
require('./shifter')(grunt);
// Load ESLint.
require('./eslint')(grunt);
// Load jsconfig.
require('./jsconfig')(grunt);
// Load JSDoc.
require('./jsdoc')(grunt);
const path = require('path');
// Register JS tasks.
grunt.registerTask('yui', ['eslint:yui', 'shifter']);
grunt.registerTask('amd', ['ignorefiles', 'eslint:amd', 'rollup']);
grunt.registerTask('js', ['amd', 'yui', 'react']);
// Register NPM tasks.
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-rollup');
const babelTransform = require('@babel/core').transform;
const babel = (options = {}) => {
return {
name: 'babel',
transform: (code, id) => {
grunt.log.debug(`Transforming ${id}`);
options.filename = id;
const transformed = babelTransform(code, options);
return {
code: transformed.code,
map: transformed.map
};
}
};
};
// Note: We have to use a rate limit plugin here because rollup runs all tasks asynchronously and in parallel.
// When we kick off a full run, if we kick off a rollup of every file this will fork-bomb the machine.
// To work around this we use a concurrent Promise queue based on the number of available processors.
const rateLimit = () => {
const queue = [];
let queueRunner;
const startQueue = () => {
if (queueRunner) {
return;
}
queueRunner = setTimeout(() => {
const limit = Math.max(1, require('os').cpus().length / 2);
grunt.log.debug(`Starting rollup with queue size of ${limit}`);
runQueue(limit);
}, 100);
};
// The queue runner will run the next `size` items in the queue.
const runQueue = (size = 1) => {
queue.splice(0, size).forEach(resolve => {
grunt.log.debug(`Item resolved. Kicking off next one.`);
resolve();
});
};
return {
name: 'ratelimit',
// The options hook is run in parallel.
// We can return an unresolved Promise which is queued for later resolution.
options: async(options) => {
return new Promise(resolve => {
queue.push(resolve);
startQueue();
return options;
});
},
// When an item in the queue completes, start the next item in the queue.
generateBundle: (options, bundle) => {
grunt.log.debug(`Finished output phase for ${Object.keys(bundle).join(', ')}`);
runQueue();
},
};
};
const terser = require('rollup-plugin-terser').terser;
grunt.config.merge({
rollup: {
options: {
format: 'esm',
dir: 'output',
sourcemap: true,
treeshake: false,
context: 'window',
plugins: [
rateLimit(),
babel({
sourceMaps: true,
comments: false,
compact: false,
plugins: [
'transform-es2015-modules-amd-lazy',
'system-import-transformer',
// This plugin modifies the Babel transpiling for "export default"
// so that if it's used then only the exported value is returned
// by the generated AMD module.
//
// It also adds the Moodle plugin name to the AMD module definition
// so that it can be imported as expected in other modules.
path.resolve('.grunt/babel-plugin-add-module-to-define.js')
],
presets: [
['@babel/preset-env', {
modules: false,
useBuiltIns: false
}]
]
}),
terser({
// Do not mangle variables.
// Makes debugging easier.
mangle: false,
}),
],
},
dist: {
files: [{
expand: true,
src: grunt.moodleEnv.files ? grunt.moodleEnv.files : grunt.moodleEnv.amdSrc,
rename: babelRename
}],
},
},
});
grunt.config.merge({
watch: {
amd: {
files: grunt.moodleEnv.inComponent
? ['amd/src/*.js', 'amd/src/**/*.js']
: ['**/amd/src/**/*.js'],
tasks: ['amd']
},
},
});
// Add the 'js' task as a startup task.
grunt.moodleEnv.startupTasks.push('js');
// On watch, we dynamically modify config to build only affected files. This
// method is slightly complicated to deal with multiple changed files at once (copied
// from the grunt-contrib-watch readme).
let changedFiles = Object.create(null);
const onChange = grunt.util._.debounce(function() {
const files = Object.keys(changedFiles);
grunt.config('rollup.dist.files', [{expand: true, src: files, rename: babelRename}]);
changedFiles = Object.create(null);
}, 200);
grunt.event.on('watch', function(action, filepath) {
changedFiles[filepath] = action;
onChange();
});
return {
babelRename,
};
};
-83
View File
@@ -1,83 +0,0 @@
// 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/>.
/* jshint node: true, browser: false */
/* eslint-env node */
// @ts-nocheck
/**
* @copyright 2022 Andrew Lyons <andrew@nicols.co.uk>
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
const configuration = {
compilerOptions: {
baseUrl: ".",
paths: {
},
target: "es2015",
allowSyntheticDefaultImports: false,
},
exclude: [
"node_modules",
],
include: [],
};
/**
* Generate jsconfig.json with AMD module path aliases for all components.
*
* @param {object} grunt The Grunt instance.
*/
const generateJsconfig = (grunt) => {
const jsconfigData = Object.assign({}, configuration);
const path = require('path');
const {fetchComponentData} = require(path.join(process.cwd(), '.grunt', 'components.js'));
const componentData = fetchComponentData().components;
for (const [thisPath, component] of Object.entries(componentData)) {
jsconfigData.compilerOptions.paths[`${component}/*`] = [`${thisPath}/amd/src/*`];
jsconfigData.include.push(`${thisPath}/amd/src/**/*`);
}
grunt.file.write('jsconfig.json', JSON.stringify(jsconfigData, null, " ") + "\n");
grunt.log.write('✓ Generating jsconfig.json\n');
};
/**
* Generate tsconfig.aliases.json with TypeScript path aliases for all ESM components.
*
* @returns {Promise<void>}
*/
const generateTsAliases = async() => {
const {generateAliases} = await import('../../.esbuild/generate-aliases.mjs');
generateAliases();
};
module.exports = (grunt) => {
const handler = async function() {
const done = this.async();
try {
generateJsconfig(grunt);
await generateTsAliases();
done();
} catch (err) {
grunt.log.error(err.message);
done(false);
}
};
grunt.registerTask('jsconfig', 'Generate a jsconfig configuration compatible with the LSP', handler);
};
-52
View File
@@ -1,52 +0,0 @@
// 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/>.
/* jshint node: true, browser: false */
/* eslint-env node */
/**
* @copyright 2021 Andrew Nicols
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
module.exports = (grunt) => {
const path = require('path');
grunt.registerTask('jsdoc', 'Generate JavaScript documentation using jsdoc', function() {
const done = this.async();
const configuration = path.resolve('.grunt/jsdoc/jsdoc.conf.js');
grunt.util.spawn({
cmd: 'jsdoc',
args: [
'--configure',
configuration,
]
}, function(error, result, code) {
if (result.stdout) {
grunt.log.write(result.stdout);
}
if (result.stderr) {
grunt.log.error(result.stderr);
}
if (error) {
grunt.fail.fatal(`JSDoc failed with error code ${code}`);
} else {
grunt.log.write('JSDoc completed successfully'.green);
}
done();
});
});
};
-111
View File
@@ -1,111 +0,0 @@
// 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/>.
/* jshint node: true, browser: false */
/* eslint-env node */
// @ts-nocheck
/**
* Grunt tasks for building React components.
*
* @copyright Meirza <meirza.arson@moodle.com>
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
module.exports = grunt => {
/**
* Register react task — build or watch React components.
*
* Modes:
* grunt react — production build
* grunt react:dev — development build (sourcemaps, no minification)
* grunt react:watch — esbuild native watch (dev mode, incremental context)
*
* Note: react:watch uses esbuild's own context.watch() and is intentionally
* separate from grunt-contrib-watch. This keeps esbuild's incremental build
* graph alive between rebuilds rather than restarting from scratch on each change.
*/
grunt.registerTask('react', 'Build all React components', function(mode) {
const done = this.async();
const isWatch = mode === 'watch';
const isDev = isWatch || mode === 'dev';
if (isWatch) {
const path = require('path');
const {spawn} = require('child_process');
// Run ESLint on the rebuilt source files in check-only mode (no --fix)
// to avoid writing changes that would re-trigger esbuild.
const eslintBin = path.join(grunt.moodleEnv.gruntFilePath, 'node_modules', '.bin', 'eslint');
const onRebuild = (srcFiles) => {
if (srcFiles.length === 0) {
return;
}
const absSrcFiles = srcFiles.map(f => path.join(grunt.moodleEnv.gruntFilePath, f));
spawn(eslintBin, absSrcFiles, {stdio: 'inherit'})
.on('error', err => grunt.log.error(`ESLint: ${err.message}`));
};
(async() => {
try {
const {watchComponents} = await import('../../.esbuild/plugin/plugincomponents.mjs');
const { generateAliases } = await import('../../.esbuild/generate-aliases.mjs');
const { buildPluginComponents } = await import('../../.esbuild/plugin/plugincomponents.mjs');
generateAliases();
await buildPluginComponents(isDev);
const ctx = await watchComponents(true, onRebuild);
if (!ctx) {
grunt.log.warn('No React source files found. Nothing to watch.');
done();
return;
}
grunt.log.ok('esbuild is watching for React changes. Press Ctrl+C to stop.');
// Keep the process alive until the user interrupts. done() is intentionally
// not called here — grunt's async mechanism holds the process open.
process.on('SIGINT', async() => {
await ctx.dispose();
done();
});
} catch (err) {
grunt.log.error(err.message);
done(false);
}
})();
return;
}
grunt.log.writeln(`Building React components in ${isDev ? 'DEVELOPMENT' : 'PRODUCTION'} mode...`);
(async() => {
try {
const {generateAliases} = await import('../../.esbuild/generate-aliases.mjs');
const {buildPluginComponents} = await import('../../.esbuild/plugin/plugincomponents.mjs');
generateAliases();
await buildPluginComponents(isDev);
done();
} catch (err) {
grunt.log.error(err.message);
done(false);
}
})();
});
};
-43
View File
@@ -1,43 +0,0 @@
// 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/>.
/* jshint node: true, browser: false */
/* eslint-env node */
/**
* @copyright 2021 Andrew Nicols
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
module.exports = grunt => {
grunt.loadNpmTasks('grunt-sass');
grunt.config.merge({
sass: {
dist: {
files: {
"public/theme/boost/style/moodle.css": "public/theme/boost/scss/preset/default.scss",
"public/theme/classic/style/moodle.css": "public/theme/classic/scss/classicgrunt.scss"
}
},
options: {
implementation: require('sass'),
includePaths: [
"public/theme/boost/scss/",
"public/theme/classic/scss/",
]
}
},
});
};
-155
View File
@@ -1,155 +0,0 @@
// 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/>.
/* jshint node: true, browser: false */
/* eslint-env node */
/**
* @copyright 2021 Andrew Nicols
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
/* eslint-env node */
module.exports = grunt => {
/**
* Shifter task. Is configured with a path to a specific file or a directory,
* in the case of a specific file it will work out the right module to be built.
*
* Note that this task runs the invidiaul shifter jobs async (becase it spawns
* so be careful to to call done().
*/
const handler = function() {
const done = this.async();
const options = grunt.config('shifter.options');
const async = require('async');
const path = require('path');
// Run the shifter processes one at a time to avoid confusing output.
async.eachSeries(options.paths, function(src, filedone) {
var args = [];
args.push(path.normalize(process.cwd() + '/node_modules/shifter/bin/shifter'));
// Always ignore the node_modules directory.
args.push('--excludes', 'node_modules');
// Determine the most appropriate options to run with based upon the current location.
if (grunt.file.isMatch('**/yui/**/*.js', src)) {
// When passed a JS file, build our containing module (this happen with
// watch).
grunt.log.debug('Shifter passed a specific JS file');
src = path.dirname(path.dirname(src));
options.recursive = false;
} else if (grunt.file.isMatch('**/yui/src', src)) {
// When in a src directory --walk all modules.
grunt.log.debug('In a src directory');
args.push('--walk');
options.recursive = false;
} else if (grunt.file.isMatch('**/yui/src/*', src)) {
// When in module, only build our module.
grunt.log.debug('In a module directory');
options.recursive = false;
} else if (grunt.file.isMatch('**/yui/src/*/js', src)) {
// When in module src, only build our module.
grunt.log.debug('In a source directory');
src = path.dirname(src);
options.recursive = false;
}
if (grunt.option('watch')) {
grunt.fail.fatal('The --watch option has been removed, please use `grunt watch` instead');
}
// Add the stderr option if appropriate
if (grunt.option('verbose')) {
args.push('--lint-stderr');
}
if (grunt.option('no-color')) {
args.push('--color=false');
}
var execShifter = function() {
grunt.log.ok("Running shifter on " + src);
grunt.util.spawn({
cmd: "node",
args: args,
opts: {cwd: src, stdio: 'inherit', env: process.env}
}, function(error, result, code) {
if (code) {
grunt.fail.fatal('Shifter failed with code: ' + code);
} else {
grunt.log.ok('Shifter build complete.');
filedone();
}
});
};
// Actually run shifter.
if (!options.recursive) {
execShifter();
} else {
// Check that there are yui modules otherwise shifter ends with exit code 1.
if (grunt.file.expand({cwd: src}, '**/yui/src/**/*.js').length > 0) {
args.push('--recursive');
execShifter();
} else {
grunt.log.ok('No YUI modules to build.');
filedone();
}
}
}, done);
};
// Register the shifter task.
grunt.registerTask('shifter', 'Run Shifter against the current directory', handler);
// Configure it.
grunt.config.set('shifter', {
options: {
recursive: true,
// Shifter takes a relative path.
paths: grunt.moodleEnv.files ? grunt.moodleEnv.files : [grunt.moodleEnv.runDir]
}
});
grunt.config.merge({
watch: {
yui: {
files: grunt.moodleEnv.inComponent
? ['yui/src/*.json', 'yui/src/**/*.js']
: ['**/yui/src/**/*.js'],
tasks: ['yui']
},
},
});
// On watch, we dynamically modify config to build only affected files. This
// method is slightly complicated to deal with multiple changed files at once (copied
// from the grunt-contrib-watch readme).
let changedFiles = Object.create(null);
const onChange = grunt.util._.debounce(function() {
const files = Object.keys(changedFiles);
grunt.config('shifter.options.paths', files);
changedFiles = Object.create(null);
}, 200);
grunt.event.on('watch', (action, filepath) => {
changedFiles[filepath] = action;
onChange();
});
return handler;
};
-49
View File
@@ -1,49 +0,0 @@
// 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/>.
/* jshint node: true, browser: false */
/* eslint-env node */
/**
* @copyright 2021 Andrew Nicols
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
module.exports = grunt => {
/**
* Generate ignore files (utilising thirdpartylibs.xml data)
*/
const handler = function() {
const path = require('path');
// Are we in a YUI directory?
if (path.basename(path.resolve(grunt.moodleEnv.cwd, '../../')) == 'yui') {
grunt.task.run('yui');
// Are we in an AMD directory?
} else if (grunt.moodleEnv.inAMD) {
grunt.task.run('amd');
// Are we in an ESM source directory?
} else if (grunt.moodleEnv.inEsm) {
grunt.task.run('react');
} else {
// Run all of the requested startup tasks.
grunt.moodleEnv.startupTasks.forEach(taskName => grunt.task.run(taskName));
}
};
// Register the startup task.
grunt.registerTask('startup', 'Run the correct tasks for the current directory', handler);
return handler;
};
-35
View File
@@ -1,35 +0,0 @@
// 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/>.
/* jshint node: true, browser: false */
/* eslint-env node */
/**
* @copyright 2021 Andrew Nicols
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
module.exports = grunt => {
// Load the ignorefiles tasks.
require('./ignorefiles')(grunt);
// Load the Style Lint tasks.
require('./stylelint')(grunt);
// Load the SASS tasks.
require('./sass')(grunt);
// Add the 'css' task as a startup task.
grunt.moodleEnv.startupTasks.push('css');
};
-187
View File
@@ -1,187 +0,0 @@
// 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/>.
/* jshint node: true, browser: false */
/* eslint-env node */
/**
* @copyright 2021 Andrew Nicols
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
module.exports = grunt => {
const getCssConfigForFiles = files => {
return {
stylelint: {
css: {
// Use a fully-qualified path.
src: files,
options: {
quietDeprecationWarnings: true,
configOverrides: {
rules: {
// These rules have to be disabled in .stylelintrc for scss compat.
"at-rule-no-unknown": true,
}
}
}
},
},
};
};
const getScssConfigForFiles = files => {
return {
stylelint: {
scss: {
options: {
quietDeprecationWarnings: true,
customSyntax: 'postcss-scss',
},
src: files,
},
},
};
};
/**
* Register any stylelint tasks.
*
* @param {Object} grunt
* @param {Array} files
* @param {String} fullRunDir
*/
const registerStyleLintTasks = () => {
const glob = require('glob');
// The stylelinters do not handle the case where a configuration was provided but no files were included.
// Keep track of whether any files were found.
let hasCss = false;
let hasScss = false;
// The stylelint processors do not take a path argument. They always check all provided values.
// As a result we must check through each glob and determine if any files match the current directory.
const scssFiles = [];
const cssFiles = [];
const requestedFiles = grunt.moodleEnv.files;
if (requestedFiles) {
// Grunt was called with a files argument.
// Check whether each of the requested files matches either the CSS or SCSS source file list.
requestedFiles.forEach(changedFilePath => {
let matchesGlob;
// Check whether this watched path matches any watched SCSS file.
matchesGlob = grunt.moodleEnv.scssSrc.some(watchedPathGlob => {
return glob.sync(watchedPathGlob).indexOf(changedFilePath) !== -1;
});
if (matchesGlob) {
scssFiles.push(changedFilePath);
hasScss = true;
}
// Check whether this watched path matches any watched CSS file.
matchesGlob = grunt.moodleEnv.cssSrc.some(watchedPathGlob => {
return glob.sync(watchedPathGlob).indexOf(changedFilePath) !== -1;
});
if (matchesGlob) {
cssFiles.push(changedFilePath);
hasCss = true;
}
});
} else {
// Grunt was called without a list of files.
// The start directory (runDir) may be a child dir of the project.
// Check each scssSrc file to see if it's in the start directory.
// This means that we can lint just mod/*/styles.css if started in the mod directory.
grunt.moodleEnv.scssSrc.forEach(path => {
if (path.startsWith(grunt.moodleEnv.runDir)) {
scssFiles.push(path);
hasScss = true;
}
});
grunt.moodleEnv.cssSrc.forEach(path => {
if (path.startsWith(grunt.moodleEnv.runDir)) {
cssFiles.push(path);
hasCss = true;
}
});
}
// Register the tasks.
const scssTasks = ['sass'];
if (hasScss) {
grunt.config.merge(getScssConfigForFiles(scssFiles));
scssTasks.unshift('stylelint:scss');
}
scssTasks.unshift('ignorefiles');
const cssTasks = ['ignorefiles'];
if (hasCss) {
grunt.config.merge(getCssConfigForFiles(cssFiles));
cssTasks.push('stylelint:css');
}
// The tasks must be registered, even if empty to ensure a consistent command list.
// They jsut won't run anything.
grunt.registerTask('scss', scssTasks);
grunt.registerTask('rawcss', cssTasks);
};
// Register CSS tasks.
grunt.loadNpmTasks('grunt-stylelint');
// Register the style lint tasks.
registerStyleLintTasks();
grunt.registerTask('css', ['scss', 'rawcss']);
const getCoreThemeMatches = () => {
const scssMatch = 'scss/**/*.scss';
if (grunt.moodleEnv.inTheme) {
return [scssMatch];
}
if (grunt.moodleEnv.runDir.startsWith('theme')) {
return [`*/${scssMatch}`];
}
return [`theme/*/${scssMatch}`];
};
// Add the watch configuration for rawcss, and scss.
grunt.config.merge({
watch: {
rawcss: {
files: [
'**/*.css',
],
excludes: [
'**/moodle.css',
'**/editor.css',
'jsdoc/styles/*.css',
],
tasks: ['rawcss']
},
scss: {
files: getCoreThemeMatches(),
tasks: ['scss']
},
},
});
};
-42
View File
@@ -1,42 +0,0 @@
// 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/>.
/* jshint node: true, browser: false */
/* eslint-env node */
/**
* @copyright 2023 Sara Arjona <sara@moodle.com>
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
module.exports = grunt => {
/**
* Generate upgradable third-party libraries (utilising thirdpartylibs.xml data)
*/
grunt.registerTask('upgradablelibs', 'Generate upgradable third-party libraries', async function() {
const done = this.async();
const path = require('path');
const ComponentList = require(path.join(process.cwd(), '.grunt', 'components.js'));
// An array of third party libraries that have a newer version in their repositories.
const thirdPartyLibs = await ComponentList.getThirdPartyLibsUpgradable({progress: true});
for (let library of thirdPartyLibs) {
grunt.log.ok(JSON.stringify(Object.assign({}, library), null, 4));
}
done();
});
};
-276
View File
@@ -1,276 +0,0 @@
/**
* This is a wrapper task to handle the grunt watch command. It attempts to use
* Watchman to monitor for file changes, if it's installed, because it's much faster.
*
* If Watchman isn't installed then it falls back to the grunt-contrib-watch file
* watcher for backwards compatibility.
*/
/* eslint-env node */
module.exports = grunt => {
/**
* This is a wrapper task to handle the grunt watch command. It attempts to use
* Watchman to monitor for file changes, if it's installed, because it's much faster.
*
* If Watchman isn't installed then it falls back to the grunt-contrib-watch file
* watcher for backwards compatibility.
*/
const watchHandler = function() {
const async = require('async');
const watchTaskDone = this.async();
let watchInitialised = false;
let watchTaskQueue = {};
let processingQueue = false;
const watchman = require('fb-watchman');
const watchmanClient = new watchman.Client();
// Grab the tasks and files that have been queued up and execute them.
var processWatchTaskQueue = function() {
if (!Object.keys(watchTaskQueue).length || processingQueue) {
// If there is nothing in the queue or we're already processing then wait.
return;
}
processingQueue = true;
// Grab all tasks currently in the queue.
var queueToProcess = watchTaskQueue;
// Reset the queue.
watchTaskQueue = {};
async.forEachSeries(
Object.keys(queueToProcess),
function(task, next) {
var files = queueToProcess[task];
var filesOption = '--files=' + files.join(',');
grunt.log.ok('Running task ' + task + ' for files ' + filesOption);
// Spawn the task in a child process so that it doesn't kill this one
// if it failed.
var args = [task, filesOption];
if (grunt.option('force')) {
args.push('--force');
}
grunt.util.spawn(
{
// Spawn with the grunt bin.
grunt: true,
// Run from current working dir and inherit stdio from process.
opts: {
cwd: grunt.moodleEnv.fullRunDir,
stdio: 'inherit'
},
args: args
},
function(err, res, code) {
if (code !== 0) {
// The grunt task failed.
grunt.log.error(err);
}
// Move on to the next task.
next();
}
);
},
function() {
// No longer processing.
processingQueue = false;
// Once all of the tasks are done then recurse just in case more tasks
// were queued while we were processing.
processWatchTaskQueue();
}
);
};
const originalWatchConfig = grunt.config.get(['watch']);
const watchConfig = Object.keys(originalWatchConfig).reduce(function(carry, key) {
if (key == 'options') {
return carry;
}
const value = originalWatchConfig[key];
const taskNames = value.tasks;
const files = value.files;
let excludes = [];
if (value.excludes) {
excludes = value.excludes;
}
taskNames.forEach(function(taskName) {
carry[taskName] = {
files,
excludes,
};
});
return carry;
}, {});
watchmanClient.on('error', function(error) {
// We have to add an error handler here and parse the error string because the
// example way from the docs to check if Watchman is installed doesn't actually work!!
// See: https://github.com/facebook/watchman/issues/509
if (error.message.match('Watchman was not found')) {
// If watchman isn't installed then we should fallback to the other watch task.
grunt.log.ok('It is recommended that you install Watchman for better performance using the "watch" command.');
// Fallback to the old grunt-contrib-watch task.
grunt.renameTask('watch-grunt', 'watch');
grunt.task.run(['watch']);
// This task is finished.
watchTaskDone(0);
} else {
grunt.log.error(error);
// Fatal error.
watchTaskDone(1);
}
});
watchmanClient.on('subscription', function(resp) {
if (resp.subscription !== 'grunt-watch') {
return;
}
resp.files.forEach(function(file) {
grunt.log.ok('File changed: ' + file.name);
var fullPath = grunt.moodleEnv.fullRunDir + '/' + file.name;
Object.keys(watchConfig).forEach(function(task) {
const fileGlobs = watchConfig[task].files;
var match = fileGlobs.some(function(fileGlob) {
return grunt.file.isMatch(`**/${fileGlob}`, fullPath);
});
if (match) {
// If we are watching a subdirectory then the file.name will be relative
// to that directory. However the grunt tasks expect the file paths to be
// relative to the Gruntfile.js location so let's normalise them before
// adding them to the queue.
var relativePath = fullPath.replace(grunt.moodleEnv.gruntFilePath + '/', '');
if (task in watchTaskQueue) {
if (!watchTaskQueue[task].includes(relativePath)) {
watchTaskQueue[task] = watchTaskQueue[task].concat(relativePath);
}
} else {
watchTaskQueue[task] = [relativePath];
}
}
});
});
processWatchTaskQueue();
});
process.on('SIGINT', function() {
// Let the user know that they may need to manually stop the Watchman daemon if they
// no longer want it running.
if (watchInitialised) {
grunt.log.ok('The Watchman daemon may still be running and may need to be stopped manually.');
}
process.exit();
});
// Initiate the watch on the current directory.
watchmanClient.command(['watch-project', grunt.moodleEnv.fullRunDir], function(watchError, watchResponse) {
if (watchError) {
grunt.log.error('Error initiating watch:', watchError);
watchTaskDone(1);
return;
}
if ('warning' in watchResponse) {
grunt.log.error('warning: ', watchResponse.warning);
}
var watch = watchResponse.watch;
var relativePath = watchResponse.relative_path;
watchInitialised = true;
watchmanClient.command(['clock', watch], function(clockError, clockResponse) {
if (clockError) {
grunt.log.error('Failed to query clock:', clockError);
watchTaskDone(1);
return;
}
// Generate the expression query used by watchman.
// Documentation is limited, but see https://facebook.github.io/watchman/docs/expr/allof.html for examples.
// We generate an expression to match any value in the files list of all of our tasks, but excluding
// all value in the excludes list of that task.
//
// [anyof, [
// [allof, [
// [anyof, [
// ['match', validPath, 'wholename'],
// ['match', validPath, 'wholename'],
// ],
// [not,
// [anyof, [
// ['match', invalidPath, 'wholename'],
// ['match', invalidPath, 'wholename'],
// ],
// ],
// ],
var matchWholeName = fileGlob => ['match', fileGlob, 'wholename'];
var matches = Object.keys(watchConfig).map(function(task) {
const matchAll = [];
matchAll.push(['anyof'].concat(watchConfig[task].files.map(matchWholeName)));
if (watchConfig[task].excludes.length) {
matchAll.push(['not', ['anyof'].concat(watchConfig[task].excludes.map(matchWholeName))]);
}
return ['allof'].concat(matchAll);
});
matches = ['anyof'].concat(matches);
var sub = {
expression: matches,
// Which fields we're interested in.
fields: ["name", "size", "type"],
// Add our time constraint.
since: clockResponse.clock
};
if (relativePath) {
/* eslint-disable camelcase */
sub.relative_root = relativePath;
}
watchmanClient.command(['subscribe', watch, 'grunt-watch', sub], function(subscribeError) {
if (subscribeError) {
// Probably an error in the subscription criteria.
grunt.log.error('failed to subscribe: ', subscribeError);
watchTaskDone(1);
return;
}
grunt.log.ok('Listening for changes to files in ' + grunt.moodleEnv.fullRunDir);
});
});
});
};
// Rename the grunt-contrib-watch "watch" task because we're going to wrap it.
grunt.renameTask('watch', 'watch-grunt');
// Register the new watch handler.
grunt.registerTask('watch', 'Run tasks on file changes', watchHandler);
grunt.config.merge({
watch: {
options: {
nospawn: true // We need not to spawn so config can be changed dynamically.
},
},
});
return watchHandler;
};
-111
View File
@@ -1,111 +0,0 @@
#!/usr/bin/env node
// 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/>.
import { Argument, Option, program } from 'commander';
import chalk from 'chalk';
import { getNoteNames } from './notes/src/noteTypes.mjs';
import createAction from './notes/src/create.mjs';
import generateAction from './notes/src/generate.mjs';
import generateReleaseNotesLinks from './notes/src/releasenotes.mjs';
import logger from './notes/src/logger.mjs';
console.log(`
${chalk.bold(chalk.underline(chalk.green('Moodle Upgrade Notes Generator')))}
This tool is used to generate the upgrade notes for changes you make in Moodle.
Please remember that the intended audience of these changes is
${chalk.italic('plugin developers')} who need to know how to update their plugins
for a new Moodle version.
Upgrade notes should not be used to document changes for site administrators, or
for internal API changes which are not expected to be used outside of the
relevant component.
`)
program.configureHelp({
helpWidth: 100,
});
program.on('option:verbose', () => {
logger.level = 'verbose';
});
program.addOption(
new Option(
'-v, --verbose',
'Output more information during the generation process',
)
.default(false)
);
// Define the command line options.
program
.command('create')
.summary('Generate a new upgrade note')
.addOption(
new Option('-t, --type <type>', `The type of change to document. Valid types are: ${getNoteNames().join(', ')}`)
)
.addOption(new Option('-i, --issue <issue>', 'The tracker issue number'))
.addOption(new Option('-c, --component <component>', 'The component to write a note for'))
.addOption(new Option(
'-m, --message <message>',
'The message to use for the upgrade note',
))
.action((options) => createAction(options));
program
.command('summary')
.summary('Generate a local copy of the upgrade notes summary')
.addArgument(
new Argument('[version]', 'The Moodle version to create the summary notes for')
)
.action((version) => generateAction(version));
program
.command('releasenotes')
.summary('Generate a list of upgrade notes for individual components in markdown format for the release notes')
.addArgument(
new Argument('[tag]', 'The Moodle tag')
)
.action((tag) => generateReleaseNotesLinks(tag));
program
.command('release')
.summary('Generate the markdown copies of the upgrade notes for a Moodle release')
.addArgument(
new Argument('[version]', 'The Moodle version to create the release notes for')
)
.addOption(
new Option(
'--generate-upgrade-notes',
'Generate the UPGRADING.md notes for the release. ' +
'Note: This option is intended for use by the release manager when generating the upgrade notes.',
)
.default(true)
)
.addOption(
new Option(
'-d, --delete-notes',
'Delete the notes after generating the UPGRADING.md notes for the release. ' +
'Note: This option is intended for use by the release manager when generating the upgrade notes.' +
'This option has no effect unless --generate-upgrade-notes is also set.'
)
.default(false)
)
.action((version, options) => generateAction(version, options));
program.parse();
-2
View File
@@ -1,2 +0,0 @@
**/amd/**
/*.js
+22 -32
View File
@@ -1,58 +1,48 @@
// NOTE: We use eslint now. This file is used only by shifter. We keep the configuration
// here because shifter uses jshint after modules have been concating. Eslint can't
// currently do this.
{
"asi": false,
"bitwise": true,
"boss": false,
"browser": true,
"yui": true,
"bitwise": true,
"curly": true,
"eqeqeq": true,
"forin": false,
"immed": true,
"newcap": true,
"noarg": true,
"noempty": true,
"nomen": false,
"onevar": false,
"plusplus": false,
"regexp": false,
"strict": false,
"trailing": true,
"unused": true,
"white": false,
"asi": false,
"boss": false,
"debug": false,
"eqeqeq": false,
"eqnull": false,
"es5": false,
"esnext": false,
"evil": false,
"expr": false,
"forin": false,
"funcscope": false,
"globalstrict": false,
"immed": true,
"indent": 4,
"iterator": false,
"lastsemic": false,
"latedef": true,
"laxbreak": true,
"laxcomma": false,
"loopfunc": false,
"maxerr": 500,
"maxlen": 132,
"multistr": false,
"newcap": true,
"noarg": true,
"noempty": true,
"nomen": false,
"onecase": false,
"onevar": false,
"passfail": false,
"plusplus": false,
"predef": [
"M",
"define",
"require"
],
"proto": false,
"regexdash": false,
"regexp": false,
"scripturl": false,
"shadow": false,
"smarttabs": false,
"strict": false,
"sub": false,
"supernew": false,
"trailing": true,
"undef": true,
"unused": true,
"white": false,
"yui": true
"maxerr": 500,
"maxlen": 150,
"passfail": false,
"latedef": true
}
-1
View File
@@ -1 +0,0 @@
lts/jod
-40
View File
@@ -1,40 +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/>.
/**
* Helper file for PhpStorm, and other IDEs, to provide better code completion.
*
* @package core
* @copyright 2024 Andrew Lyons <andrew@nicols.co.uk>
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
namespace PHPSTORM_META;
// Assume that anything returned by \core\di::get('...') is an instance of the first argument.
override(\core\di::get(0), map([
'' => '@',
]));
// Assume that anything returned by \Psr\Container\ContainerInterface::get('...') is an instance of the first argument.
override(\Psr\Container\ContainerInterface::get(0), map([
'' => '@',
]));
// Assume that anything returned by \DI\Container::get('...') is an instance of the first argument.
override(\DI\Container::get(0), map([
'' => '@',
]));
+1 -2
View File
@@ -1,5 +1,4 @@
{
"coverage": false,
"lint": "config",
"clean": true
"lint": "config"
}
-107
View File
@@ -1,107 +0,0 @@
{
"customSyntax": "postcss-scss",
"plugins": [
"stylelint-csstree-validator"
],
"rules": {
"csstree/validator": {
"syntaxExtensions": [
"sass"
]
},
"at-rule-empty-line-before": [ "always",
{"except": [ "blockless-after-blockless"], ignore: ["after-comment", "inside-block"]}
],
"at-rule-name-case": "lower",
"at-rule-name-space-after": "always-single-line",
"at-rule-no-unknown": null, # Enabled for non-scss in grunt.
"at-rule-semicolon-newline-after": "always",
"at-rule-semicolon-space-before": "never",
"block-closing-brace-newline-after": "always",
"block-closing-brace-newline-before": "always",
"block-closing-brace-space-before": "always-single-line",
"block-no-empty": true,
"block-opening-brace-newline-after": "always",
"block-opening-brace-space-after": "always-single-line",
"block-opening-brace-space-before": "always",
"color-hex-case": ["lower", { "severity": "warning" }],
"color-hex-length": ["short", { "severity": "warning" }],
"color-no-invalid-hex": true,
"declaration-bang-space-after": "never",
"declaration-bang-space-before": "always",
"declaration-block-no-duplicate-properties": true,
"declaration-block-no-shorthand-property-overrides": true,
"declaration-block-semicolon-newline-after": "always-multi-line",
"declaration-block-semicolon-space-after": "always-single-line",
"declaration-block-semicolon-space-before": "never",
"declaration-block-single-line-max-declarations": 1,
"declaration-block-trailing-semicolon": "always",
"declaration-colon-newline-after": "always-multi-line",
"declaration-colon-space-after": "always-single-line",
"declaration-colon-space-before": "never",
"declaration-no-important": true,
"font-family-no-duplicate-names": true,
"function-calc-no-unspaced-operator": true,
"function-comma-newline-after": "always-multi-line",
"function-comma-space-after": "always-single-line",
"function-comma-space-before": "never",
"function-linear-gradient-no-nonstandard-direction": true,
"function-max-empty-lines": 0,
"function-name-case": "lower",
"function-parentheses-newline-inside": "always-multi-line",
"function-parentheses-space-inside": "never-single-line",
"function-url-scheme-disallowed-list": ["data"],
"function-whitespace-after": "always",
"indentation": 4,
"keyframe-declaration-no-important": true,
"length-zero-no-unit": [true, { "severity": "warning" }],
"max-empty-lines": 2,
"max-line-length": [132, { "severity": "warning" }],
"media-feature-colon-space-after": "always",
"media-feature-colon-space-before": "never",
"media-feature-parentheses-space-inside": "never",
"media-feature-range-operator-space-after": "always",
"media-feature-range-operator-space-before": "always",
"media-query-list-comma-newline-after": "always-multi-line",
"media-query-list-comma-space-after": "always-single-line",
"media-query-list-comma-space-before": "never",
"no-empty-source": true,
"no-eol-whitespace": true,
"no-extra-semicolons": [true, { "severity": "warning" }],
"no-invalid-double-slash-comments": true,
"no-unknown-animations": true,
"property-case": "lower",
"property-no-unknown": true,
"selector-attribute-brackets-space-inside": "never",
"selector-attribute-operator-space-after": "never",
"selector-attribute-operator-space-before": "never",
"selector-combinator-space-after": "always",
"selector-combinator-space-before": "always",
"selector-list-comma-newline-after": "always",
"selector-list-comma-space-before": "never",
"selector-max-empty-lines": 0,
"selector-pseudo-class-case": "lower",
"selector-pseudo-class-no-unknown": true,
"selector-pseudo-class-parentheses-space-inside": "never",
"selector-pseudo-element-case": "lower",
"selector-pseudo-element-no-unknown": true,
"selector-type-case": "lower",
"selector-type-no-unknown": true,
"string-no-newline": true,
"time-min-milliseconds": 100,
"unit-disallowed-list": ["pt"],
"unit-case": "lower",
"unit-no-unknown": true,
"value-keyword-case": ["lower", {"ignoreKeywords": ["/(@|$)/"]}],
"value-list-comma-newline-after": "always-multi-line",
"value-list-comma-space-after": "always-single-line",
"value-list-comma-space-before": "never",
},
"overrides": [
{
"files": ["**/yui/**/*.css"],
"rules": {
}
}
]
}
@@ -1,7 +0,0 @@
issueNumber: MDL-51152
notes:
enrol_manual:
- message: >-
The unused parameter 'roleid' has been removed from the external
function `unenrol_users()`
type: removed
@@ -1,22 +0,0 @@
issueNumber: MDL-71368
notes:
core:
- message: >
The `arg_separator.output` has been changed from a default of `amp;` to
a default of `&` in line with PHP defaults.
If you were previously relying on the legacy default when using
`http_build_query()` then you should _actively_ specify the value as the
third
parameter, for example:
```
http_build_query($formdata, '', '&amp;');
```
type: changed
@@ -1,8 +0,0 @@
issueNumber: MDL-73602
notes:
core:
- message: >-
Removed `qtype_random` from core.
`core\component::is_valid_plugin_name` has an additional check to ensure no-one can create a new plugin called qtype_random,
as this would conflict with the support for restoring old backups.
type: removed
@@ -1,8 +0,0 @@
issueNumber: MDL-75067
notes:
tool_behat:
- message: >-
The `behat_session_trait::ensure_element_[does_not_]exists(...)` methods
now accept optional `$container` parameter to define the parent node to
look within
type: improved
@@ -1,5 +0,0 @@
issueNumber: MDL-77894
notes:
core:
- message: Appending an exclamation mark to template names ignores theme overrides
type: improved
@@ -1,10 +0,0 @@
issueNumber: MDL-78325
notes:
core_grades:
- message: >-
In Moodle 4.2, the legacy Gradebook base widget from 4.1 has been removed and
replaced with a simpler class-based system due to a breaking change and
excessive complexity in the old pattern. The files `core/grades/basewidget.js` and
templates in `grade/templates/searchwidget/` have been deleted,
with minimal expected third-party impact.
type: removed
@@ -1,13 +0,0 @@
issueNumber: MDL-79182
notes:
core:
- message: >
The following AMD modules have been removed following the final
deprecation process. It is no longer possible or necessary to manually
register modal types. See MDL-78324 for further details.
- `core/modal_registry`
- `core/modal_factory`
type: removed
@@ -1,7 +0,0 @@
issueNumber: MDL-79574
notes:
core:
- message: >-
The `\core\persistent::get_records(...)` class method now returns
instances keyed by record ID
type: changed
@@ -1,13 +0,0 @@
issueNumber: MDL-81514
notes:
core_group:
- message: >
`groups_print_activity_menu()` and `groups_get_activity_group()` now
include an additional `$participationonly` parameter, which is true by
default. This can be set false when we want the user to be able to
select a non-participation group within an activity, for example if a
teacher wants to filter assignment submissions by non-participation
groups. It should never be used when the menu is displayed to students,
as this may allow them to participate using non-participation groups.
Non-participation groups are labeled as such.
type: improved
@@ -1,8 +0,0 @@
issueNumber: MDL-81608
notes:
mod_quiz:
- message: >-
The language strings `addpagebreak` and `removepagebreak` have been
deprecated and should no longer be used. These have been replaced by
the `addpagebreakafter` and `removepagebreakafter` language strings.
type: deprecated
@@ -1,12 +0,0 @@
issueNumber: MDL-81961
notes:
core_question:
- message: |
core_question:
- message: |
Final deprecation of `moodle-question-chooser` YUI module.
type: removed
- message: |
Final deprecation of `core_question/qbank_chooser` template.
type: removed
type: removed
-13
View File
@@ -1,13 +0,0 @@
issueNumber: MDL-81962
notes:
core:
- message: The `moodle-core-notification-confirm` YUI module has been removed after an extensive deprecation period. Please use the AMD `core/modal` module as a replacement.
type: removed
- message: |
The following feaetures of the `moodle-core-notification` YUI module have been removed after an extensive deprecation process.:
- method: `keyDelegation`
- property: `lightbox`
There is no direct replacement for these features, but they were not widely used and their removal should not cause significant issues. If you were using these features, you will need to implement your own solutions for key delegation and lightbox functionality.
type: removed
@@ -1,7 +0,0 @@
issueNumber: MDL-82284
notes:
core:
- message: >-
Legacy constructors have been removed. These relate to PHP 4 and
earlier.
type: removed
@@ -1,15 +0,0 @@
issueNumber: MDL-83902
notes:
core_badges:
- message: >-
The following classes and functions are now also available in the following new
locations. They will continue to work in their old locations:
| Old classname/function | New classname/function |
| --- | --- |
| `\badge_award_selector_base` | `\core_badges\award_selector_base` |
| `\badge_potential_users_selector` | `\core_badges\potential_award_selector` |
| `\badge_existing_users_selector` | `\core_badges\existing_award_selector` |
| `process_manual_award()` | `\core_badges\award_manager::process_manual_award()` |
| `process_manual_revoke()` | `\core_badges\award_manager::process_manual_revoke()` |
type: improved
@@ -1,7 +0,0 @@
issueNumber: MDL-84082
notes:
core_reportbuilder:
- message: >-
The text filter "Contains" and "Not contains" operators now support `*`
and `?` wildcard characters for better text content filtering
type: improved
@@ -1,30 +0,0 @@
issueNumber: MDL-84960
notes:
core:
- message: >-
Several core web services now include a new initials field in user data
structures. This change is backward-compatible and only adds an optional
field; no existing fields or field semantics have been changed.
Client applications should ensure they can handle the additional initials
field in web service responses, but clients that ignore unknown fields can
continue working without changes. The affected web services are:
- core_enrol_get_enrolled_users
- core_enrol_get_enrolled_users_with_capability
- core_enrol_get_potential_users
- core_enrol_search_users
- core_user_get_users_by_field
- core_user_get_users
- core_user_get_course_user_profiles
- core_grades_get_enrolled_users_for_selector
- core_grades_get_gradable_users
- gradereport_grader_get_users_in_report
- core_message_get_contact_requests
- core_message_get_conversation_members
- core_message_message_search_users
- core_message_get_user_contacts
- core_message_get_member_info
- core_message_get_conversation_messages
- mod_assign_list_participants
- mod_assign_get_participant
- mod_forum_get_forum_discussions
type: improved
@@ -1,9 +0,0 @@
issueNumber: MDL-85233
notes:
core_filters:
- message: >-
MimeTeX support has been removed from both `filter_tex` and
`filter_algebra`. These filters now depend on LaTeX tools (`latex`,
`dvips`, and `convert`/`dvisvgm`), and as a result, the `pathmimetex`
setting has been removed.
type: removed
@@ -1,8 +0,0 @@
issueNumber: MDL-85322
notes:
block_html:
- message: >-
Treat Dashboard (pagetype 'my-index') as trusted in web services so
get_content_for_external preserves embedded HTML (e.g. iframes) on user
Dashboard.
type: changed
@@ -1,8 +0,0 @@
issueNumber: MDL-85336
notes:
core:
- message: >-
Redis connection timeout settings for cachestores and sessions have been
split into connection timeout and read timeout to allow for finer
control. These settings now also accept floats.
type: improved
@@ -1,9 +0,0 @@
issueNumber: MDL-85405
notes:
core_course:
- message: >-
The external function `core_course_get_course_contents` now includes the
`candisplay` property for each returned module. If this is false, the
module should not be displayed on the course page (for example, for
question banks).
type: improved
@@ -1,5 +0,0 @@
issueNumber: MDL-85621
notes:
core_badges:
- message: The create_issued_badge generator now returns the issued badge object.
type: changed
@@ -1,11 +0,0 @@
issueNumber: MDL-85621
notes:
core_badges:
- message: >-
The class core_badges_assertion has been deprecated and replaced by
\core_badges\achievement_credential.
The method badges_get_default_issuer() has also been deprecated because
it is no longer needed.
The file badges/endorsement.php has been removed because it stopped being used
when MDL-84323 was integrated.
type: deprecated
@@ -1,17 +0,0 @@
issueNumber: MDL-85975
notes:
core:
- message: >
`restore_qtype_plugin::unset_excluded_fields` now returns the modified
questiondata structure,
in order to support structures that contain arrays.
If your qtype plugin overrides
`restore_qtype_plugin::remove_excluded_question_data` without
calling the parent method, you may need to modify your overridden method
to use the returned
value.
type: fixed
@@ -1,8 +0,0 @@
issueNumber: MDL-86332
notes:
core_completion:
- message: >-
The `completion_info::clear_criteria` method takes an optional
`$removetypecriteria` to determine whether to remove course type
criteria from other courses that refer to the current course
type: changed
@@ -1,26 +0,0 @@
issueNumber: MDL-86493
notes:
mod_quiz:
- message: >-
The quiz overrides cache implementation has been replaced with a faster alternative with a different API.
This should be a transparent change but any direct references will still need to be updated.
type: deprecated
- message: >
`mod_quiz_cm_info_dynamic()` now uses the new `quiz_overrides` cache via `override_manager`, performing a single cache fetch per quiz/user.
This significantly reduces cache calls on course pages with many quizzes and groups.
The new `mod_quiz:quiz_overrides` cache is keyed by `quizid_userid` using datasource `\mod_quiz\cache\quiz_overrides_cache`.
This cache returns all applicable overrides for a user in a quiz (the user override, if any, plus all group overrides for groups they belong to in the quiz's course).
New class `\mod_quiz\local\quiz_overrides_cache_manager` to interact with the cache:
- `get_overrides(int $quizid, int $userid): array`
- `purge_for_user(int $quizid, int $userid): void`
- `purge_for_users(int $quizid, array $userids): void`
- `purge_for_group(int $quizid, int $groupid): void`
- `purge_for_group_members(int $groupid, array $userids): void`
Hook callbacks in `db/hooks.php` to keep the cache in sync with group
membership changes:
- `\core_group\hook\after_group_membership_added`
- `\core_group\hook\after_group_membership_removed`
type: improved
@@ -1,12 +0,0 @@
issueNumber: MDL-86524
notes:
core_question:
- message: >-
During restore of a question_set_reference, mapping of IDs in the
filtercondition is now delegated to qbank plugins.
If your qbank plugin defines a filter condition that uses database
IDs, add an override of `restore_filtercondition()` to the `condition`
class, which checks the condition's data and replaces the IDs with
mapped values if required. See
`qbank_managecategories\category_condition` for an example.
type: improved
@@ -1,7 +0,0 @@
issueNumber: MDL-86607
notes:
mod_feedback:
- message: >-
The method `feedback_init_feedback_session()` has been deprecated, along
with all other direct access to `$SESSION` from the module
type: deprecated
@@ -1,7 +0,0 @@
issueNumber: MDL-86660
notes:
core_courseformat:
- message: >-
The `$cm` attribute in `activityoverviewbase` has been updated to public
visibility, allowing direct access to the course module instance
type: changed
@@ -1,8 +0,0 @@
issueNumber: MDL-86660
notes:
core_courseformat:
- message: >-
A new `available` attribute has been added to `activityname_exporter`
class. It allows the external API to return the activity's availability
status relative to the current user.
type: changed
@@ -1,9 +0,0 @@
issueNumber: MDL-86660
notes:
core_courseformat:
- message: >-
Two new public static methods have been added to the `overviewtable`
class:
- `is_cm_displayable`: Determines if a course module should be listed in the overview table.
- `is_cm_available`: Checks if a course module is accessible to the user (and should therefore be rendered as a link).
type: changed
@@ -1,19 +0,0 @@
issueNumber: MDL-86678
notes:
core_reportbuilder:
- message: >-
The base entity class now implements a default `initialise` method, that
will automatically call each of the following methods to load entity
report data:
* `get_available_columns()`
* `get_available_filters()`
* `get_available_conditions()`
This change allows for a lot of boilerplate to be removed from report
entity classes
type: improved
@@ -1,12 +0,0 @@
issueNumber: MDL-86699
notes:
core_reportbuilder:
- message: >-
There are two new entities intended for reports specific to course
module data, in order to provide a baseline in terms of module reporting
and API usage:
*
`core_course\reportbuilder\local\entities\{course_module,course_module_base}`
type: improved
@@ -1,7 +0,0 @@
issueNumber: MDL-86699
notes:
mod_forum:
- message: >-
The forum report entity `->get_context_joins()` method is deprecated,
replaced with `->get_course_modules_joins(...)`
type: deprecated
@@ -1,17 +0,0 @@
issueNumber: MDL-86798
notes:
core_question:
- message: >
In order to prevent re-use of question version numbers after a version
is deleted, the `nextversion` column was added to
`question_bank_entries`. This serves as a counter incremented each time
a version is created.
Do not query this field directly. Instead use
`core_question\versions::get_next_version()` to read the value, which
will initialise it based on the existing versions if it is not set yet.
By default, it will increment the version number automatically, unless
you pass `increment: false`. Because of this, it is advisable to call
it inside a transaction, that is only committed after the version number
is used in a `question_versions` record.
type: fixed
@@ -1,7 +0,0 @@
issueNumber: MDL-86798
notes:
core_question:
- message: >-
`get_next_version()` from questionlib.php is now deprecated. Use
`\core_question\versions::get_next_version()` instead.
type: deprecated
@@ -1,5 +0,0 @@
issueNumber: MDL-86832
notes:
core_block:
- message: Removed block_activity_modules from Moodle 5.2.
type: removed
@@ -1,10 +0,0 @@
issueNumber: MDL-86839
notes:
core:
- message: >
"grunt watch" now accepts a force flag. Run "grunt watch -f" or "grunt
watch --force" to prevent grunt from cancelling builds when errors
occur. This is especially useful during development, because js build
files will be built even if, for example, jslint errors are still
present in the files.
type: improved
@@ -1,8 +0,0 @@
issueNumber: MDL-86846
notes:
core:
- message: >-
The `core/drag_handle` template has been modified to use a native HTML
button for a more accessible experience and a consistent look with other
buttons on the page.
type: changed
@@ -1,7 +0,0 @@
issueNumber: MDL-86854
notes:
core_courseformat:
- message: >-
Add core_courseformat\cmactions::move_before that will allow to move a coursemodule to a position before another coursemodule.
Add core_courseformat\cmactions::move_end_section that will allow to move a coursemodule the end of a section.
type: improved
@@ -1,8 +0,0 @@
issueNumber: MDL-86854
notes:
core_course:
- message: >-
Deprecates moveto_module (core_course) in favor of
cmactions::move_before or cmactions::move_end_section
(core_courseformat\local\cmactions).
type: deprecated
@@ -1,11 +0,0 @@
issueNumber: MDL-86855
notes:
qbank_columnsortorder:
- message: >-
The Behat selector `column move handle` for the `qbank_columnsortorder` plugin has been removed.
When interacting with the column's move handle, please use the move handle's accessible name and type.
For example:
- `And I drag "Move Created by" "button" and I drop it in "Move T" "button"`
type: removed
@@ -1,9 +0,0 @@
issueNumber: MDL-86856
notes:
core_course:
- message: >-
The following methods have been deprecated and should no longer be used:
- `course_delete_module`
- `course_module_flag_for_async_deletion`
Please consider using the equivalent methods, delete and delete_async, in `core_courseformat\local\cmactions` instead.
type: deprecated
@@ -1,5 +0,0 @@
issueNumber: MDL-86856
notes:
core_courseformat:
- message: Add delete method to the core_courseformat\cmactions
type: improved
@@ -1,7 +0,0 @@
issueNumber: MDL-86857
notes:
core_courseformat:
- message: >-
Add set_groupmode method to the core_courseformat\cmactions (course
format actions)
type: improved
@@ -1,7 +0,0 @@
issueNumber: MDL-86857
notes:
core_course:
- message: >-
Deprecates set_coursemodule_groupmode in favor of
core_courseformat\cmactions::set_groupmode
type: deprecated
@@ -1,7 +0,0 @@
issueNumber: MDL-86858
notes:
core_courseformat:
- message: >-
Create a new core_courseformat\cmactions::duplicate aiming to replace
the course/lib.php version
type: improved

Some files were not shown because too many files have changed in this diff Show More