Compare commits

..

524 Commits

Author SHA1 Message Date
Eloy Lafuente (stronk7) 06ede85e1f Moodle 2.0.3 release 2011-05-06 15:09:21 +02:00
Tim Hunt 8ad8b7dba8 MDL-27394 Moodle 2.0 backup and restore may randomise the order of multichoice/numerical/shortanswer answers 2011-05-06 00:18:50 +02:00
Sam Hemelryk 36f0835e72 Merge branch 's9_MDL-27382_dropbox_get_file_fix_20' of github.com:dongsheng/moodle into MOODLE_20_STABLE 2011-05-05 13:26:46 +08:00
Sam Hemelryk 259b9d05f3 Merge branch 's9_MDL-27381_overwrite_dialog_safari_20' of github.com:dongsheng/moodle into MOODLE_20_STABLE 2011-05-05 13:23:22 +08:00
Sam Hemelryk da20cd7b43 Merge branch 's9_MDL-26854_spam_comments_20_2' of git://github.com/dongsheng/moodle into MOODLE_20_STABLE 2011-05-05 11:46:05 +08:00
Dongsheng Cai acb4688d29 MDL-26854 Added comments block lib.php, it contains comments callbacks 2011-05-05 11:25:19 +08:00
Jerome Mouneyrac 471952fe82 MDL-26250 Create a web service function that enrols users to a certain course 2011-05-05 11:00:00 +08:00
Dongsheng Cai 0d738689bd MDL-27381 fixed 'overwrite files' dialog zindex in safari 2011-05-05 10:43:17 +08:00
Sam Hemelryk 7390fdde63 Merge branch 's9_MDL-26854_spam_comments_20_2' of git://github.com/dongsheng/moodle into MOODLE_20_STABLE 2011-05-05 10:42:58 +08:00
Sam Hemelryk 1374c61bb4 Merge branch 'MDL-26838_ratings_bad_data3' of git://github.com/andyjdavis/moodle into MOODLE_20_STABLE 2011-05-05 10:19:54 +08:00
Dongsheng Cai 98d9209a34 MDL-27382 repository dropbox plugin, fixed bug of
file downloading path
2011-05-05 09:57:34 +08:00
Eloy Lafuente (stronk7) 8351ce1bd0 weekly release 2.0.2+ 2011-05-05 00:37:10 +02:00
Eloy Lafuente (stronk7) b911ab236c Merge branch 'MDL-25594-20' of git://github.com/srynot4sale/moodle into MOODLE_20_STABLE 2011-05-04 16:09:44 +02:00
Dongsheng Cai b4730465e6 MDL-26854 COMMENT
1. added pluginname_comment_validate callback to comments api
2. change permission callback defaults to false
3. Tidied up serveal areas of comments and implemented callback to
ignore system permissions for view (credits to Sam Hemelryk)

AMOS BEGIN
    MOV [modulerejectcomment,error],[callbackrejectcomment,error]
AMOS END
2011-05-04 17:59:19 +08:00
Eloy Lafuente (stronk7) 78cc7bee62 Merge branch 'MDL-26788_m20' of git://github.com/rwijaya/moodle into MOODLE_20_STABLE 2011-05-04 11:21:02 +02:00
Dongsheng Cai 5d6eafcf10 MDL-26388 Recent repository plugin should return draft url 2011-05-04 17:03:36 +08:00
Dongsheng Cai 090e19328e MDL-26388 Recent repository plugin should return draft url 2011-05-04 15:48:11 +08:00
Andrew Davis (andyjdavis) 34b5e856b0 MDL-26838 rating: multiple fixes after a review of rating validation code 2011-05-04 15:33:35 +08:00
Sam Hemelryk c44a5d5946 Merge branch 's10_MDL-27330_dropbox_authorization_url_20' of github.com:dongsheng/moodle into MOODLE_20_STABLE 2011-05-04 13:56:59 +08:00
Aaron Barnes b7d7679112 MDL-25594 completion: Remove unused column from query
Which is also a reserved word.
2011-05-04 13:01:27 +12:00
Dongsheng Cai 64a17788aa MDL-27330 repository dropbox plugin
Dropbox changed authorization URL, and added a few error check code
2011-05-03 17:42:57 +08:00
Sam Hemelryk 0baa1eee59 Merged MDL-26388 Fixed whitespace 2011-05-03 16:28:38 +08:00
Sam Hemelryk 9f6eeb4abf Merged MDL-25805 Renamed property and function to be a little more descriptive 2011-05-03 15:43:20 +08:00
Sam Hemelryk 6a48b42ae8 Merge branch 'MDL-25805_MOODLE_20_STABLE' of git://github.com/nebgor/moodle into MOODLE_20_STABLE 2011-05-03 15:42:26 +08:00
Sam Hemelryk 2dd90f136c Merge branch 'MDL-26628' of git://github.com/srynot4sale/moodle into MOODLE_20_STABLE 2011-05-03 11:00:15 +08:00
Sam Hemelryk e6647397b9 Merged MDL-27251 Fixed up whitespace, Fixed broken string, reworded new strings 2011-05-03 10:54:44 +08:00
Aparup Banerjee 07fa10d725 MDL-25840 blog - fixed broken image file image attachment display 2011-05-03 01:14:16 +02:00
Eloy Lafuente (stronk7) 98032d512d Merge branch 'MDL-27293-customlang-timeout_20_STABLE' of git://github.com/mudrd8mz/moodle into MOODLE_20_STABLE 2011-05-02 16:19:40 +02:00
Aparup Banerjee 389235fb00 MDL-25805 Roles propagated ugly hack for parent seeing child activities into navigation lib to display nav node. 2011-05-02 20:21:51 +08:00
Eloy Lafuente (stronk7) 656237dd55 Merge branch 'MDL-26714_20' of git://github.com/timhunt/moodle into MOODLE_20_STABLE 2011-05-02 12:26:22 +02:00
Sam Hemelryk e3cc5b1a7f Merged changes and fixed whitespace issues for MDL-23188 2011-05-02 15:00:54 +08:00
Sam Hemelryk 0742ea86b2 Merge branch 'MDL-26955-themedir-plugindirectory_20_STABLE' of git://github.com/mudrd8mz/moodle into MOODLE_20_STABLE 2011-05-02 14:23:06 +08:00
Sam Hemelryk 41f79b5c07 Merge branch 'MDL-27116-themedir-config_20_STABLE' of git://github.com/mudrd8mz/moodle into MOODLE_20_STABLE 2011-05-02 14:12:45 +08:00
Sam Hemelryk ed85c0acd2 Merge branch 'MDL-27155_20' of git://github.com/timhunt/moodle into MOODLE_20_STABLE 2011-05-02 14:09:26 +08:00
Sam Hemelryk 9c39028179 Merge branch 'MDL-27246-cutomlang-version_20_STABLE' of git://github.com/mudrd8mz/moodle into MOODLE_20_STABLE 2011-05-02 12:14:05 +08:00
Dongsheng Cai 9fb4a6300b MDL-26388, pop up a dialog when attaching a file already being used in draft area. 2011-05-02 10:27:50 +08:00
Tim Hunt 44c9dc6e7b MDL-27340 tablelib.php fix a notice when is false. 2011-05-01 17:37:54 +01:00
Andrew Davis (andyjdavis) 4af7c9d188 MDL-26838 rating: remove logged in users ability to sidestep rating validity checks 2011-05-01 18:44:12 +08:00
Tim Hunt 847dee60ce MDL-27155 qtype_numerical problem with GIFT import. 2011-04-29 14:16:10 +01:00
Rossiani Wijaya e0be8fd6a3 MDL-26788 - grading in lesson containing essays 2011-04-29 18:17:36 +08:00
Tim Hunt 55e03d1233 MDL-26714 qtype_multianswer regression from the previous commit for numerical subquestions. 2011-04-28 23:32:14 +01:00
stabijoh e391f907af MDL-23188 implement custom menu where possible in core themes, 20 stable version 2011-04-27 08:44:53 -04:00
David Mudrak bef867a96c MDL-26955 get_plugin_directory() respects $CFG->themedir
If $CFG->themedir is set (it is not usually) and the given theme is not
found in the standard location, then it is expected to be in the custom
$CFG->themedir directory.

Credit goes to Urs Hunkler for the idea of the patch.
2011-04-27 14:03:53 +02:00
David Mudrak 4207d47742 MDL-27116 theme_config::find_theme_location() respects $CFG->themedir
Credit goes to Jai Gupta for the idea of the patch.
2011-04-27 14:03:10 +02:00
David Mudrak bd7193c7ac MDL-27293 report customlang has extra execution time and displays a progress bar during the checkout
Initial checkout of strings into the translator table may take a long time. The
maximum execution time is increased to one hour and a progress bar is
displayed so the user is informed on what is going on.
2011-04-27 14:01:59 +02:00
David Mudrak 77e4a16c4f MDL-27246 customlang report stores the versions in a char field rather than integer 2011-04-27 14:01:38 +02:00
Petr Skoda 7daba2713e weekly release 2.0.2+ 2011-04-27 12:08:04 +02:00
Aaron Barnes 03b1be3005 MDL-26628 completion report: Fix hard coded strings in Completion report 2011-04-27 15:33:45 +12:00
Aparup Banerjee 5c8511ecf7 MDL-27251 Files API - added timeout re-calculation as an optional argument. added setting for minimum Kbps for large files fetched from internet where the passed in timeout maybe too low.
allowed turning off the http HEAD request timeout calculation with zero (or negative) bitrate

	This was added in to allow servers that have a problem with
	HEAD requests to carry on with the given timeout without re-calculations.
	See PULL-651 for the discussion.

	the optional argument to force recalculation of timeout has been forced within scorm/locallib.php

	timeout re-calculation only increments timeout.
2011-04-27 11:02:21 +08:00
Eloy Lafuente (stronk7) 52435228c5 Merge branch 'w17_MDL-27253_m20_swfsize' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-04-26 11:15:01 +02:00
Eloy Lafuente (stronk7) c9dc3e5564 Merge branch 'w17_MDL-27263_m20_loggedintypo' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-04-26 11:06:31 +02:00
Petr Skoda ffaf18a8c1 MDL-27253 add default swf size and allow #d=100x50 URL resizing in mod/url 2011-04-21 20:36:06 +02:00
Petr Skoda f5fddc6081 MDL-27263 fix already logged in error message typo 2011-04-21 20:35:33 +02:00
stabijoh 9d5a4e2b7c MDL-27252 themes, fix for nonzero current highlight 2011-04-20 13:19:12 -04:00
Eloy Lafuente (stronk7) ba9103b2c6 weekly release 2.0.2+ 2011-04-20 13:36:41 +02:00
Eloy Lafuente (stronk7) 79196c9ed5 Fix permissions 2011-04-20 11:09:11 +02:00
Aparup Banerjee a572cfe5bd MDL-26580 adding precautionary upgrade_set_timeout() calls to some loops which may timeout in very edge cases 2011-04-19 17:58:03 +08:00
Aparup Banerjee 92d7776478 MDL-26580 adding some upgrade_set_timeout() calls to 2010080901 upgrade block, upgrades on questions were timing out 2011-04-19 17:57:56 +08:00
Sam Hemelryk 2715f96932 Merged with small fix branch MDL-26516_m20_calevent_wip4 from git://github.com/rwijaya/moodle.git 2011-04-19 16:29:49 +08:00
John Stabinger 6919d9f790 Fixes for MDL-27138, add correct page headers and footer 2011-04-19 11:03:33 +08:00
Sam Hemelryk 8be0517692 MDL-26835 Fixed up styles being used for suspended users in the grader report. 2011-04-19 10:47:14 +08:00
Sam Hemelryk a4b65c11b9 Merged with conflict resolution branch MDL-26835_MASTER_grader_highlight_suspended_users from git://github.com/andyjdavis/moodle.git 2011-04-19 10:46:54 +08:00
Sam Hemelryk 64e711f04b MDL-25999 Fixed URL bug with admin bookmark changes 2011-04-19 10:26:46 +08:00
Sam Hemelryk e6cf40de78 Merge branch 'MDL-25999_m20' of git://github.com/rwijaya/moodle into MOODLE_20_STABLE 2011-04-19 10:26:30 +08:00
Rossiani Wijaya 174f5a0189 MDL-26516: fix calendar event type (user overides) 2011-04-18 18:12:25 +08:00
Eloy Lafuente (stronk7) dd56fd7c64 MDL-26167 lib/form: minor coding tweaks 2011-04-18 11:45:02 +02:00
Eloy Lafuente (stronk7) 436f83f8ff Merge branch 'MDL-26167-stable' of git://github.com/agwells/moodle into MOODLE_20_STABLE 2011-04-18 11:44:02 +02:00
Rossiani Wijaya d03f904759 MDL-25999: update Admin Bookmarks block to work properly in 2.0 2011-04-18 17:23:36 +08:00
Eloy Lafuente (stronk7) 15a6af91f5 Merge branch 'w16_MDL-17344_m20_uploadprof' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-04-18 11:07:42 +02:00
Andrew Davis (andyjdavis) 0a23dec07a MDL-26835 gradebook: grader report now marks suspended students 2011-04-18 14:25:16 +08:00
Sam Hemelryk 6f8081bef4 MDL-26958 PULL-675 Merged changes and removed border colour style 2011-04-18 10:57:27 +08:00
Andrew Davis (andyjdavis) c643d3ae06 MDL-27153 gradebook - fixed an SQL error in grade export 2011-04-18 02:17:09 +02:00
Eloy Lafuente (stronk7) 507ccf1c4b MDL-27148 whitespace fix 2011-04-18 01:47:11 +02:00
Eloy Lafuente (stronk7) 60bc533ee8 Merge branch 'w16_MDL-27148_m20_stringinc' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-04-18 01:44:10 +02:00
Eloy Lafuente (stronk7) 42f2b8d0dd Merge branch 'w16_MDL-27217_m20_tinyset' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-04-18 01:13:49 +02:00
Eloy Lafuente (stronk7) 84047d1fc9 Merge branch 'w16_MDL-27220_m20_tagprofile' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-04-18 01:08:10 +02:00
Petr Skoda b79ac7e0d6 Merge branch 'm20_MDL-26880_SCORM2004_tracking_fix' of git://github.com/danmarsden/moodle into MOODLE_20_STABLE 2011-04-17 17:16:48 +02:00
Petr Skoda 241ceba38c Merge branch 'm20_MDL-24734_gradefix' of git://github.com/danmarsden/moodle into MOODLE_20_STABLE 2011-04-17 17:09:59 +02:00
Petr Skoda 8e49e0833c Merge branch 'm20_MDL-18392_slash_cleanup' of git://github.com/danmarsden/moodle into MOODLE_20_STABLE 2011-04-17 17:04:09 +02:00
Petr Skoda f6bf9c932d Merge branch 'MDL-27198-m20' of git://github.com/sammarshallou/moodle into MOODLE_20_STABLE 2011-04-17 16:40:10 +02:00
Petr Skoda 1fb2369b09 Merge branch 'wip-MDL-26013-MOODLE_20_STABLE' of git://github.com/samhemelryk/moodle into MOODLE_20_STABLE 2011-04-17 16:22:34 +02:00
Petr Skoda 4de0925820 Merge branch 'wip-MDL-27145-MOODLE_20_STABLE' of git://github.com/samhemelryk/moodle into MOODLE_20_STABLE 2011-04-17 16:13:08 +02:00
Petr Skoda 81f2a1686a MDL-27217 use correct editor name in editor settings page
Credit goes to Franck Bellemain.
2011-04-17 11:18:00 +02:00
Petr Skoda 5f509554a5 MDL-27220 add missing tag lib include 2011-04-17 11:07:57 +02:00
Dan Marsden edd5d0693d SCORM MDL-24734 - fix display of grade information on view.php page - also fixes some XHTML in the same function. 2011-04-16 19:32:11 +12:00
Mary Evans d59a75a841 MDL-26958 Core Themes:adding css patch to base theme so hidden elements are dimmed
This patch also fixes MDL-27160 - the same bug which affects many CORE themes like Binarus and Nonzeo. This patch also a small element of a patch supplied by Thomas Lake in Tracker MDL-26958 (most of which already exists in Base theme).
2011-04-15 00:49:22 +01:00
Aaron Wells 9b482d1cbe MDL-26167 lib/form: Altering Javascript so that "disabledIf" will disable the "Choose" button for a filepicker 2011-04-15 10:02:34 +12:00
sam marshall ca090f3262 MDL-27198 Accessibility: For labels, completion/editing icons must appear after content 2011-04-14 17:28:53 +01:00
Petr Skoda 12db898084 MDL-27148 use new get_in_or_equal() param prefix instead of start 2011-04-14 15:13:28 +02:00
Petr Skoda c79345c0f0 MDL-27148 fix unit tests to accept arbitrary named params format from get_in_or_equal 2011-04-14 15:12:21 +02:00
Petr Skoda d691571218 MDL-27148 use static counter instead of incrementing parameter name 2011-04-14 14:44:50 +02:00
Petr Skoda 4e1bb6e10c MDL-17344 fix case and unicode related profile field issues in user upload
This fixes issue with uppercase and non-ascii profile fields and closes the iterator properly when field not found. Please note that profile fields with upper case letters must be specified exactly in CSV file headers. includes improved docs and parameter typo fix (credit for the parameter typo discovery goes to Aparup Banerjee)
2011-04-14 13:18:42 +02:00
Nadav Kavalerchik a7e920fbfb CSS MDL-26013 Fixed several display bugs when using right to left languages 2011-04-14 15:59:03 +08:00
Matteo Scaramuccia 7a725d6b59 PULL-498 - Fixed potential issues about UTF-8 and multilang filter by adopting pure ASCII chars, the SCO primary key 2011-04-14 10:26:41 +12:00
Matteo Scaramuccia 489c6ef357 MDL-26880 - Fixed missing of activity id
Moved errorCode as global, to allow GetLastError() to work
Applied MDL-17891 mechanism against AJAX failures, "true if true, false otherwise"
Limited what added to log when in debug, to be compliant with mdl_log.action as VARCHAR(40)
2011-04-14 10:26:18 +12:00
Dan Marsden dbb6157aa1 Merge remote branch 'moodle/MOODLE_20_STABLE' into m20_MDL-18392_slash_cleanup 2011-04-14 09:15:17 +12:00
Petr Skoda 50467e50c9 weekly release 2.0.2+ 2011-04-13 22:08:30 +02:00
Petr Skoda 85a91fb98e Merge branch 'MDL-24355_emergency_20' of git://github.com/stronk7/moodle into MOODLE_20_STABLE 2011-04-13 16:49:29 +02:00
Eloy Lafuente (stronk7) 75454e2567 MDL-24355 tags - fix correlation sql to be cross-db 2011-04-13 16:37:37 +02:00
Petr Skoda 06c09f30e3 Revert "MDL-25840 fixed image files link not rendered correctly when attached as file (instead of inline)."
The reason is failed testing. This reverts commit 3d0e3ade75.
2011-04-13 15:07:22 +02:00
Dan Marsden 26daa23d9d SCORM MDL-18392 - remove old call to stripslashes 2011-04-13 20:00:59 +12:00
Matteo Scaramuccia 74a2ee73ed SCORM MDL-18392 MDL-26282 - Fixed calls to add/strip slashes 2011-04-13 19:58:44 +12:00
Petr Skoda fca41d2589 MDL-25718 fix incorrect 'no grade' test and improve coding style 2011-04-12 10:07:05 +02:00
Petr Skoda 6de6a45a10 Merge branch 'MDL-25718_enrol_grades_alternative2' of git://github.com/andyjdavis/moodle into MOODLE_20_STABLE 2011-04-12 09:55:28 +02:00
Sam Hemelryk 0f1fac1f1f form-dateselector MDL-27145 Fixed up error resulting from incorrectly required 'optional' argument on create event 2011-04-12 14:15:51 +08:00
andyjdavis 692134ecd4 enrol MDL-25718 added ability to recover grades when enrolling users 2011-04-12 11:05:02 +08:00
Eloy Lafuente (stronk7) d7706bac2c Merge branch 'MDL-26778-m20' of git://github.com/sammarshallou/moodle into MOODLE_20_STABLE 2011-04-11 17:54:21 +02:00
Eloy Lafuente (stronk7) 391e054c03 Merge branch 'w15_MDL-26577_m20_groupscleanup' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-04-11 16:02:10 +02:00
Eloy Lafuente (stronk7) 71f2316fe6 Merge branch 'w15_MDL-26805_m20_userpol' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-04-11 15:18:31 +02:00
Petr Skoda 16d610019a Merge branch 'wip-MDL-27024-MOODLE_20_STABLE' of git://github.com/samhemelryk/moodle into MOODLE_20_STABLE 2011-04-11 14:13:34 +02:00
Petr Skoda 4f5791da64 Merge branch 'wip-MDL-26599-MOODLE_20_STABLE' of git://github.com/samhemelryk/moodle into MOODLE_20_STABLE 2011-04-11 14:10:38 +02:00
sam marshall c5e3a242b1 MDL-26778 Change to completion should immediately affect nav block
Includes change so that updating completion resets the cache, and a debugging
warning if any module calls the completion viewed thing after it's already
printed navigation (which will mean navigation obviously doesn't update right
away). All existing modules that currently update after printing navigation
were updated.
2011-04-11 12:40:50 +01:00
Petr Skoda 13ad1eaf37 Merge branch 'MDL-25840_m20' of git://github.com/nebgor/moodle into MOODLE_20_STABLE 2011-04-11 13:30:44 +02:00
Petr Skoda 7ca448fa83 MDL-26805 cleanup default role selections
Frontpage role selection now allows only guest and frontpage roles. Default forntpage role is selected duuring install. Unused nodefaultuserrolelists option was removed completely. Coding style improvements.
2011-04-11 13:08:35 +02:00
Eloy Lafuente (stronk7) 37efb4f1ee Merge branch 's9_MDL-27098_filemanager_strings_20' of git://github.com/dongsheng/moodle into MOODLE_20_STABLE 2011-04-11 11:20:31 +02:00
Dongsheng Cai 81bd2292bc MDL-27098
1. Fixed add file language string
2. Fixed hard-coded 'moving' string
3. Fixed hard-coded 'Files' string
2011-04-11 17:10:30 +08:00
Eloy Lafuente (stronk7) 8fa13d155d Merge branch 'w15_MDL-25826_m20_htmlpurifier' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-04-11 11:08:23 +02:00
Sam Hemelryk 465846f082 Merge branch 'MDL-25746_m20' of git://github.com/nebgor/moodle into MOODLE_20_STABLE 2011-04-11 15:38:48 +08:00
Aparup Banerjee f68815ffcf MDL-25746 fixed db tempate page layout to prevent hidden content layers 2011-04-11 15:16:54 +08:00
Sam Hemelryk 67b5d74b2c Merge branch 'MDL-27034_xhprof_table_sql_20' of git://github.com/stronk7/moodle into MOODLE_20_STABLE 2011-04-11 14:34:57 +08:00
Aparup Banerjee 3d0e3ade75 MDL-25840 fixed image files link not rendered correctly when attached as file (instead of inline). 2011-04-11 14:24:22 +08:00
Sam Hemelryk 7d1fb2f6ec Merged branch 'MDL-26185_m20' of git://github.com/andyjdavis/moodle.git and fixed conflicts 2011-04-11 11:54:50 +08:00
Sam Hemelryk 227e54d65a Merge branch 'MDL-27063' of git://github.com/MaryE/moodle into MOODLE_20_STABLE 2011-04-11 11:38:21 +08:00
Sam Hemelryk ee6181b1e7 comment MDL-27024 Removed last check within comment.js for block_comment env 2011-04-11 10:43:25 +08:00
Sam Hemelryk 3962c89bbf comment MDL-27024 Fixed bug that arose when a comment section didnt require pagination but the JS still looked for pageination HTML in the page 2011-04-11 10:43:21 +08:00
Sam Hemelryk 59137c2c5b comment MDL-27024 Removed last reference to the comment block within the comment API and used the options properly 2011-04-11 10:43:17 +08:00
Sam Hemelryk b83e494d6f comment MDL-27024 Fixed up whitespace issues 2011-04-11 10:43:12 +08:00
Sam Hemelryk 3b2164bdca comment MDL-27024 made notoggle and autoload into proper options to remove comment block conditions from comment API 2011-04-11 10:43:06 +08:00
Sam Hemelryk aa54d70440 comment MDL-27024 Cleaned up HTML output in comment class 2011-04-11 10:43:01 +08:00
Sam Hemelryk d2d4bccec1 comment MDL-27024 Cleaned up use of undefined property $this->link 2011-04-11 10:42:56 +08:00
Sam Hemelryk f3a3c59f48 mod-lesson MDL-26599 Fixed echo causing incorrect nesting. 2011-04-11 10:27:58 +08:00
Eloy Lafuente (stronk7) 3d62a46b26 Merge branch 'w15_MDL-27094_m20_assval' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-04-11 01:32:15 +02:00
Eloy Lafuente (stronk7) 9aacfedb22 Merge branch 'w15_MDL-27007_m20_userupload' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-04-11 01:23:04 +02:00
Eloy Lafuente (stronk7) 12b734434b Merge branch 'w15_MDL-26910_m20_httpd' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-04-11 00:17:23 +02:00
Eloy Lafuente (stronk7) f9068e531c Merge branch 'w15_MDL-27121_m20_phpreq' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-04-10 23:55:11 +02:00
Eloy Lafuente (stronk7) 96506c474a Merge branch 'MDL-26319_MOODLE_20_STABLE' of git://github.com/nebgor/moodle into MOODLE_20_STABLE 2011-04-10 23:49:59 +02:00
Tony Levi 0d66e33da5 MDL-27084: mod/feedback fix bad syntax in database query 2011-04-10 23:43:56 +02:00
Petr Skoda 934fa3ed6c MDL-27094 fix incorrect assignment form validation method name
Credit goes to H. Hanna
2011-04-10 21:01:53 +02:00
Petr Skoda 6743d6c520 MDL-26910 add HTTPD server name whitelisting 2011-04-10 13:59:17 +02:00
Petr Skoda cf76e10e4a MDL-26577 fix several groups and groupings issues
The current group in verified on each page which prevents problems when group settings are changed. The default group for course level is now using correct grouping id which solves problems when activity and course are using different grouping. The grouping is now displayed in group selector if user has access to all groups.
2011-04-10 13:28:02 +02:00
Mary Evans c800e31213 MDL-27063 tt styled incorrectly in canvas theme 2011-04-10 00:48:35 +01:00
Petr Skoda 23580ddacb MDL-27121 fix incorrect check_moodle_environment() version parameter
This prevents Moodle 2.0 from using environment info for 2.1 in the installer and CLI upgrade.
2011-04-09 17:42:53 +02:00
Petr Skoda 827fcdb347 MDL-27007 fix incorrectly suspended user enrolment when uploading users
This bug surfaced after the recent change in enrol API, credit goes to Chaim Schendowich and Micky Fokken.
2011-04-09 12:09:53 +02:00
Petr Skoda 60aaf1dc77 MDL-25826 add more HTMLPurifier integration tests 2011-04-09 11:51:55 +02:00
Petr Skoda fd8fa6f9d0 MDL-25826 integrate HTMLPurifier 4.3.0 and improve performance
The new HTMLPurifier finally caches the schema properly eliminating both extra CPU cycles and disk writes. The repeated dir exists tests might cause problems on NFS shares.
2011-04-09 11:51:49 +02:00
Petr Skoda 8adf19eda8 MDL-25826 import HTMLPurifier 4.3.0 2011-04-09 11:51:35 +02:00
Andrew Davis (andyjdavis) a6e29ac6a3 message MDL-26185 fixed the logic around email addy in user profile Vs in messaging preferences 2011-04-07 15:39:03 +08:00
Aparup Banerjee 52e184904f MDL-26319 moved cancel_backup() from backup_ui to cancel_process() in base_ui and renamed callers. fix for method inheritance in restore_ui. 2011-04-07 10:40:45 +08:00
Eloy Lafuente (stronk7) b8d80c062e MDL-27034 profiling - xhprof_table_sql improvement 2011-04-07 00:46:33 +02:00
Petr Skoda eb9d692f8b weekly release 2.0.2+ 2011-04-06 14:55:57 +02:00
Petr Skoda a805d653d1 MDL-26804 fix undefined CFG langcache property during install
Sorry, I have committed fix for this in master incorrectly with MDL-26914.
2011-04-06 10:56:30 +02:00
Sam Hemelryk fe4a0cfe63 PULL-574 MDL-26185 Reverted changes due failed testing + review 2011-04-06 16:35:24 +08:00
Petr Skoda d0e3447e43 revert MDL-26577 added session cleaning to groups_get_activity_group() that fixes an issue with dirty session data. refactored session cleaning into one function, added caching to reduce queries.
(reverse-merged from commit 77335e76e9) This change was causing fatal errors on the course level, I am going to fix it myself.
2011-04-05 18:35:01 +02:00
Sam Hemelryk f046221272 messaging MDL-26185 Last minute fix of bug during integration, empty user preference causing error 2011-04-05 16:53:03 +08:00
Petr Skoda 42a50a0a45 Merge branch 'MDL-26577_groups_api_refactor_take2_m20' of git://github.com/nebgor/moodle into MOODLE_20_STABLE 2011-04-05 10:21:21 +02:00
Aparup Banerjee 77335e76e9 MDL-26577 added session cleaning to groups_get_activity_group() that fixes an issue with dirty session data. refactored session cleaning into one function, added caching to reduce queries. 2011-04-05 12:23:56 +08:00
Eloy Lafuente (stronk7) ddf3e875f3 Merge branch 'wip-MDL-26560-MOODLE_20_STABLE' of git://github.com/samhemelryk/moodle into MOODLE_20_STABLE 2011-04-04 23:16:53 +02:00
Eloy Lafuente (stronk7) 91fa7abf3d Merge branch 'wip-MDL-26858-MOODLE_20_STABLE' of git://github.com/samhemelryk/moodle into MOODLE_20_STABLE 2011-04-04 21:50:22 +02:00
Eloy Lafuente (stronk7) b060e5b0b8 Merge branch 'MDL-26931-blog-post-order_20_STABLE' of git://github.com/mudrd8mz/moodle into MOODLE_20_STABLE 2011-04-04 12:02:17 +02:00
Andrew Davis (andyjdavis) f9c8746704 gradebook MDL-20946 fixed average calculation where users have multiple gradeable roles 2011-04-04 11:27:09 +02:00
Petr Skoda c629aeabe3 MDL-25651 fix incorrect indentation 2011-04-04 10:01:30 +02:00
Petr Skoda 27614a5e5d Merge branch 'wip-MDL-25651_MOODLE_20_STABLE' of git://github.com/jennymgray/moodle into MOODLE_20_STABLE 2011-04-04 09:59:04 +02:00
Sam Hemelryk ba32fc0042 enrolments MDL-26560 Fixed panel.user bug with role assignments dialogue 2011-04-04 14:50:15 +08:00
Sam Hemelryk 87b05ba3e0 enrolments MDL-26858 Added finish user enrolments button to JS dialogue 2011-04-04 14:38:23 +08:00
Sam Hemelryk 728f3c9d08 Merge branch 'MDL-26185_m20' of git://github.com/rwijaya/moodle into MOODLE_20_STABLE 2011-04-04 13:21:24 +08:00
Mary Evans d7dd177eb4 Fix for MDL-27016 added min-width 2011-04-04 13:10:06 +08:00
Rossiani Wijaya 507de745e3 MDL-26185: simplify the logic of email message output and removing email cache 2011-04-01 11:12:54 +08:00
Jenny Gray bf8ff4889b MDL-25651 add capability check to my private files navigation link 2011-03-31 14:54:36 +01:00
Ankit Agarwal f9112bda35 MDL-26931 Order blog entries by the creation date 2011-03-31 11:56:53 +02:00
Tim Hunt ba63612bfa MDL-27035 table_sql forgets to set countparams. 2011-03-30 20:26:34 +01:00
Petr Skoda 408612d111 updating digits to match the .2 release 2011-03-30 18:01:09 +02:00
Petr Skoda 60e837038a weekly release 2011-03-30 14:29:56 +02:00
Petr Skoda 4cb05cea9d Merge branch 'MDL-26964-moodle_url-anchor_20_STABLE' of git://github.com/mudrd8mz/moodle into MOODLE_20_STABLE 2011-03-29 10:00:04 +02:00
Eloy Lafuente (stronk7) 09c1e72a56 Merge branch 'MDL-26744-metasyncstring_20_STABLE' of git://github.com/wildgirl/moodle into MOODLE_20_STABLE 2011-03-28 23:56:08 +02:00
Eloy Lafuente (stronk7) d2455301b7 Merge branch 'w13_MDL-22733_20_youtubeiframe' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-03-28 23:53:40 +02:00
Eloy Lafuente (stronk7) 1be2b904ab Merge branch 'w13_MDL-26909_20_mediatests' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-03-28 23:30:35 +02:00
Eloy Lafuente (stronk7) 337817e669 Merge branch 'w13_MDL-26987_20_sclean' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-03-28 21:59:21 +02:00
Eloy Lafuente (stronk7) b17a3a5591 Merge branch 'w13_MDL-26913_20_sitecreated' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-03-28 20:10:57 +02:00
Eloy Lafuente (stronk7) c44c552efa Merge branch 'w13_MDL-26951_20_archetypes' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-03-28 19:40:35 +02:00
Eloy Lafuente (stronk7) faa297ce6f Merge branch 'w13_MDL-26991_20_legacy' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-03-28 19:26:28 +02:00
Petr Skoda e1ce68c2f9 MDL-26991 use archetypes instead of deprecated 'legacy' when defining roles in enrol plugins 2011-03-28 19:19:54 +02:00
Eloy Lafuente (stronk7) b6225c0f2f Merge branch 'w13_MDL-26966_20_urlparsing' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-03-28 19:07:00 +02:00
Eloy Lafuente (stronk7) 50496af78b Merge branch 'w13_MDL-26985_20_branching' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-03-28 18:41:22 +02:00
Tim Hunt 8fc52ccf46 MDL-26425 tablelib ability for table_sql to add a class to the row based on the data. 2011-03-28 17:12:26 +02:00
Tim Hunt 9f9324f408 MDL-26425 tablelib better validation of the sort code, also some cleanup.
You may think that the extra validation is unnecessary, since the sort fields are already validated when the URL parameters are parsed, however that overlooks an important point. There may be other options that affect which columns are in the SQL, for example the quiz show individual question grades setting. These other options can cause a column that was in the table, and being sorted on, to disappear. Therefore, it is necessary to re-validate the sort columns when they are used, to make sure they are still present, otherwise you can get ORDER BY sql that refers to non-existant columns, which then causes DB errors.
2011-03-28 17:10:53 +02:00
Helen Foster d4dc367a5b MDL-26744 enrol meta lang string improvement thanks to Ray Lawrence 2011-03-28 17:07:55 +02:00
Eloy Lafuente (stronk7) 3ede344b5c Merge branch 'w13_MDL-26990_20_missingrebuild' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-03-28 16:35:18 +02:00
Petr Skoda 5c686792c6 Merge branch 'MDL-26335' of github.com:mouneyrac/moodle into MOODLE_20_STABLE 2011-03-28 15:13:47 +02:00
David Mudrak 91a4b3bd3e MDL-26804 core_string_manager::get_list_of_translations() can use a cache again
This patch reimplements the internal cache that was used to store the
list of available translations in Moodle 1.x. By default, the method
get_list_of_translations() still uses the file
moodledata/cache/languages to store the list of available translations.
The location of that file can be redefined in config.php. The internal
format of the cache file is JSON now (used to be a plain text list).

The patch also fixes a usage of the global $CFG in translation_exists()
methods where the internal property should be used instead.
2011-03-28 14:49:17 +02:00
Dongsheng Cai 1a6a1487f4 MOD-WIKI MDL-26213
1. Rewrite the image urls in diff.php and viewdiff.php
2. Fxied image urls in search.php
3. Add modcontext variable to avoid using duplicated
get_context_instance calls
2011-03-28 11:50:37 +02:00
Jenny Gray a5286ae4cc MDL-26932 full url path for toggle completion form POST 2011-03-28 11:04:39 +02:00
Dan Marsden 5b97bff526 Plagiarism MDL-26939 - missing return 2011-03-28 10:53:13 +02:00
Dongsheng Cai 1c4873ba1b MDL-26916, MDL-26917
1. Fix filepicker paging issue MDL-26916
2. Highlight view as icon button by default MDL-26917
2011-03-28 16:13:27 +08:00
Dan Marsden 9a8f8cea49 Forum Overview MDL-26957 add classes to allow better control by theme 2011-03-28 16:11:30 +08:00
stabijoh c37f03543b Revised fix for MDL-26906, magazine and formal white secure browser quiz window 2011-03-28 16:04:21 +08:00
Andrew Davis (andyjdavis) cd4ca97611 message MDL-26077 fixed up a problem with html tags being stripped out 2011-03-28 16:00:36 +08:00
Myles Carrick 77bfc4ce0f MDL-26798 encode file path in dropbox repository plugin, credits to Myles Carrick 2011-03-28 15:57:38 +08:00
Sam Hemelryk 13c53a4a2e Merge branch 'w13_MDL-26992_20_uploadtemplates' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-03-28 14:33:27 +08:00
Sam Hemelryk d3796a2c61 Merge branch 'w13_MDL-26989_20_enrolroles' of git://github.com/skodak/moodle into MOODLE_20_STABLE 2011-03-28 14:17:08 +08:00
Petr Skoda 43070e6193 MDL-26992 fix broken upload users templates 2011-03-27 23:48:41 +02:00
Nikhil Gupta d099348e32 MDL-26989 fix incorrect disabling of assignable roles 2011-03-27 20:34:15 +02:00
Petr Skoda c4dd3bb86f MDL-26913 set timecreated in fortpage of a newly installed site 2011-03-27 18:22:11 +02:00
Petr Skoda ce8b66c67f MDL-26881 work around the block context setting problems 2011-03-27 16:39:27 +02:00
Petr Skoda d38f419d5c MDL-26987 fix invalid DML syntax in spam cleaner tool 2011-03-27 16:14:22 +02:00
Petr Skoda c102060deb MDL-26951 fix removing of archetype from role 2011-03-27 16:04:33 +02:00
Petr Skoda 0ae36f6638 MDL-26966 improve self URL validation 2011-03-27 12:29:36 +02:00
Petr Skoda 3c3d544700 MDL-26909 fix outdated mediaplugin filter unittests 2011-03-26 23:54:45 +01:00
Petr Skoda c4b491a417 MDL-22733 enable youtube iframe embedding 2011-03-26 23:38:40 +01:00
Petr Skoda 112d3b4962 MDL-26990 fix undefined rebuild_course_cache() regression 2011-03-26 22:49:04 +01:00
Petr Skoda 7bb8ae5911 MDL-26985 new Moodle 2.1 requirements
For now only extra PHP 5.3.2 requirement compared to 2.0.
2011-03-26 22:03:00 +01:00
David Mudrak dbe6d9f821 MDL-26964 URL anchor support for single_button and single_select
If the single_button or single_select use HTTP method 'get' then the
eventual anchor part of the URL is used.
2011-03-24 22:15:47 +01:00
David Mudrak 4927443761 MDL-26964 URL returned by moodle_url::out_omit_querystring() may contain the anchor part 2011-03-24 22:15:47 +01:00
Petr Skoda 92a387b467 weekly release 2011-03-23 11:33:20 +01:00
Jerome Mouneyrac ac3e0b3c8c MDL-26335 fix capability name typo in the description of the web service function moodle_user_get_users_by_id 2011-03-23 11:35:46 +08:00
Eloy Lafuente (stronk7) 34c0b5bd86 MDL-26848 I left one remaining "xxx" there, grrr 2011-03-22 12:28:57 +01:00
Petr Skoda a93bd90b97 bump version to detect integration reset problems 2011-03-22 11:16:16 +01:00
Eloy Lafuente (stronk7) 18e3cba749 MDL-26848 fixing some "stupid" comments and specs of 1 field 2011-03-21 22:20:17 +01:00
Eloy Lafuente (stronk7) c6f7c3e7f3 Merge branch 'MDL-26848' of git://github.com/timhunt/moodle 2011-03-21 21:56:46 +01:00
Eloy Lafuente (stronk7) bc35885cb4 Merge branch 'MDL-25834' of git://github.com/samhemelryk/moodle 2011-03-21 21:54:57 +01:00
Eloy Lafuente (stronk7) b9c6ce2d19 Merge branch 'm20_MDL-26905_AICC_API_missing_currentorg_init' of git://github.com/scara/moodle 2011-03-21 21:38:23 +01:00
Eloy Lafuente (stronk7) bf1a4d75e0 Merge branch 'MDL-26570' of git://github.com/samhemelryk/moodle 2011-03-21 21:34:17 +01:00
Eloy Lafuente (stronk7) 8c2e4c90d7 Merge branch 'MDL-25621' of git://github.com/samhemelryk/moodle 2011-03-21 21:32:50 +01:00
Eloy Lafuente (stronk7) be5eb0013e Merge branch 'MDL-26863_wrong_appendtolog_statement' of git://github.com/scara/moodle 2011-03-21 21:15:54 +01:00
Eloy Lafuente (stronk7) c031f2c1e7 Merge branch 'MDL-26875' of git://github.com/samhemelryk/moodle 2011-03-21 21:10:55 +01:00
Eloy Lafuente (stronk7) 63187a6887 Merge branch 'm20_MDL-26894_SCORM13_PHP_notice_undefined_prop_id' of git://github.com/scara/moodle 2011-03-21 21:03:15 +01:00
Eloy Lafuente (stronk7) 1595b8120f Merge branch 'MDL-26861' of git://github.com/timhunt/moodle 2011-03-21 20:59:32 +01:00
Eloy Lafuente (stronk7) 4c2ce98b42 Merge branch 'master' of git.moodle.org:/git/integration 2011-03-21 20:55:20 +01:00
Petr Skoda c20d07074c Merge branch 'MDL-23022' of git://github.com/samhemelryk/moodle 2011-03-21 19:16:37 +01:00
Petr Skoda 3bfb75a9ed Merge branch 'wip-MDL-26781' of git://github.com/sammarshallou/moodle 2011-03-21 19:10:15 +01:00
Eloy Lafuente (stronk7) 83ee4693c5 Merge branch 'MDL-26908' of git://github.com/samhemelryk/moodle 2011-03-21 19:08:46 +01:00
Petr Skoda 7b2dde5a80 Merge branch 'wip-MDL-26747' of git://github.com/sammarshallou/moodle 2011-03-21 19:06:28 +01:00
Petr Skoda 94ff0f08f3 Merge branch 'MDL-26922' of git://github.com/stronk7/moodle 2011-03-21 19:02:16 +01:00
Eloy Lafuente (stronk7) f80de2f25c MDL-26922 dml - avoid PHP_INT_MAX overflow on limit queries 2011-03-21 18:49:08 +01:00
Petr Skoda 25bd4d9a37 Merge branch 'MDL-26847_amended' of git://github.com/timhunt/moodle 2011-03-21 18:10:35 +01:00
Eloy Lafuente (stronk7) 4386e0d101 Merge branch 'master' of git.moodle.org:/git/integration 2011-03-21 18:04:25 +01:00
Petr Skoda 2c23734a7f Merge branch 'MDL-25975' of git://github.com/samhemelryk/moodle 2011-03-21 18:02:46 +01:00
Petr Skoda 61baea5d22 Merge branch 'MDL-26903' of git://github.com/samhemelryk/moodle 2011-03-21 18:00:07 +01:00
Eloy Lafuente (stronk7) 1f95c9a4af Merge branch 'w12_MDL-26842_20_ociparams' of git://github.com/skodak/moodle 2011-03-21 17:55:40 +01:00
Petr Skoda cd278cd454 MDL-26842 fix invalid parameter mix discovered by the new test 2011-03-21 17:19:36 +01:00
Eloy Lafuente (stronk7) 1997d9dc1d Merge branch 'w12_MDL-26842_20_ociparams' of git://github.com/skodak/moodle 2011-03-21 16:38:19 +01:00
Petr Skoda 4c1638c10f MDL-26842 fix o_ prefix regression 2011-03-21 16:32:09 +01:00
Eloy Lafuente (stronk7) c0c232ab63 Merge branch 'master' of git.moodle.org:/git/integration 2011-03-21 16:31:27 +01:00
Tim Hunt af7b3673d7 MDL-26847 new method file_storage::delete_area_files_select for efficient bulk file deletion. 2011-03-21 15:21:02 +00:00
Petr Skoda 10464ffb33 Merge branch 'MDL-26887' of git://github.com/timhunt/moodle 2011-03-21 15:39:31 +01:00
Eloy Lafuente (stronk7) 7a5852c857 Merge branch 'w12_MDL-26844_20_limittests' of git://github.com/skodak/moodle 2011-03-21 15:35:17 +01:00
Eloy Lafuente (stronk7) 9c3865c81c MDL-25565 - fix borked merge. The power of one curly bracket! 2011-03-21 15:32:24 +01:00
Petr Skoda dca072aedc Merge branch 'MDL-26571_lesson_scale' of git://github.com/andyjdavis/moodle 2011-03-21 14:52:11 +01:00
Petr Skoda e5be555c27 Merge branch 'MDL-26768_0_grade' of git://github.com/andyjdavis/moodle 2011-03-21 14:49:18 +01:00
Petr Skoda 949fe7154c Merge branch 's8_MDL-26919_search_dialog_event' of git://github.com/dongsheng/moodle 2011-03-21 14:46:59 +01:00
Petr Skoda d96b0a969b Merge branch 'wip-MDL-26822' 2011-03-21 14:03:33 +01:00
Petr Skoda ae8c1f3d06 MDL-26822 fix whitespace 2011-03-21 14:02:50 +01:00
Dongsheng Cai e4e9e853d2 Fix three minor filepicker bugs: 1. use language string in search dialog instead of hard code filepicker MDL-26915 2. search dialog now response to enter key MDL-26919 3. search dialog should be modal mode MDL-26918 2011-03-21 20:56:36 +08:00
Sam Hemelryk 8196e3c08d Merge branch 'MDL-26557' of git://git.luns.net.uk/moodle 2011-03-21 17:32:06 +08:00
Sam Hemelryk 587a4ee42c Merge branch 'MDL-26827' of git://git.luns.net.uk/moodle 2011-03-21 17:23:13 +08:00
Sam Hemelryk c889fb8372 Merge branch 'w12_MDL-26904_20_PHPLOL' of git://github.com/skodak/moodle 2011-03-21 17:19:06 +08:00
Sam Hemelryk beb81f4947 Merged PULL-496/MDL-26859 and fixed incorrect defines 2011-03-21 17:13:20 +08:00
Sam Hemelryk ee780aeeaf Merge branch 'w12_MDL-26876_20_blogformat' of git://github.com/skodak/moodle 2011-03-21 16:50:07 +08:00
Sam Hemelryk d9738e84d6 Merged PULL-480/MDL-24877 and bumped version number to fix conflict 2011-03-21 15:58:19 +08:00
Sam Hemelryk 161ba40d03 Merge branch 'w12_MDL-26808_20_enrolpageurl' of git://github.com/skodak/moodle 2011-03-21 15:47:36 +08:00
Sam Hemelryk ca3fce634f Merge branch 'w12_MDL-26826_20_youtubedim' of git://github.com/skodak/moodle 2011-03-21 14:27:45 +08:00
Sam Hemelryk 909fc3ff2e Merge branch 'w12_MDL-26726_20_typocat' of git://github.com/skodak/moodle 2011-03-21 14:16:51 +08:00
Sam Hemelryk e460480080 Merge branch 'w12_MDL-26825_20_cancelform' of git://github.com/skodak/moodle 2011-03-21 14:10:44 +08:00
Sam Hemelryk d1f5425171 Merge branch 'w12_MDL-26837_20_algebra' of git://github.com/skodak/moodle 2011-03-21 13:37:36 +08:00
Sam Hemelryk 1698268db1 Merge branch 'w12_MDL-26834_20_inactiveparticipants' of git://github.com/skodak/moodle 2011-03-21 13:30:59 +08:00
Sam Hemelryk 885e86b108 Merge branch 'w12_MDL-26833_20_inactiveforum' of git://github.com/skodak/moodle 2011-03-21 12:36:47 +08:00
Sam Hemelryk 37fff87398 Merge branch 'w12_MDL-26803_20_userupload' of git://github.com/skodak/moodle 2011-03-21 12:28:45 +08:00
Sam Hemelryk b89d39bfcb Merge branch 'w12_MDL-26842_20_ociparams' of git://github.com/skodak/moodle 2011-03-21 12:22:23 +08:00
Sam Hemelryk 9d61397181 Merge branch 'MDL-26607_search_error' of git://github.com/andyjdavis/moodle 2011-03-21 11:54:20 +08:00
Sam Hemelryk 0235bd8706 Merged MDL-25565 PULL-451 and fixed conflicts 2011-03-21 11:16:50 +08:00
Sam Hemelryk 553669ae17 navigation MDL-26908 Fixed up positioning of icons for items that are both expandable and have an icon 2011-03-21 10:45:23 +08:00
Sam Hemelryk c78262b542 navigation MDL-26903 Fixed regression to navigation ajax after CM changes 2011-03-21 10:22:28 +08:00
Matteo Scaramuccia c6e46d37bc MDL-26905 - Fixed missing of currentorg initialization in AICC API 2011-03-20 23:54:39 +01:00
Petr Skoda 7119e1a0a7 MDL-26904 fix funny constant typo 2011-03-20 19:25:47 +01:00
Petr Skoda 8f6c1f3488 MDL-26859 improve blog access control and prevent unnecessary blog includes 2011-03-20 13:34:51 +01:00
Petr Skoda 5b183f51a8 MDL-26859 do not show "my blog" link to guests and not-logged-in users 2011-03-20 12:34:41 +01:00
Petr Skoda fd85ceac57 MDL-26859 improve coding style in blog related blocks 2011-03-20 12:29:22 +01:00
Petr Skoda d9e0b80ffb MDL-26859 automatically enable and disable blog related blocks when bloglevel changed 2011-03-20 12:28:34 +01:00
Petr Skoda 61c32b7b27 MDL-26808 solve chicken-egg problem with moodle url on the user enrolments page 2011-03-20 11:03:16 +01:00
Petr Skoda d6614d667d MDL-26876 use correct blog post format when migrating to forum posts 2011-03-20 08:28:46 +01:00
Matteo Scaramuccia 36c0108a2f MDL-26894: merged from SCORM 1.2 (scorm_12lib.php) after an XDebug audit session 2011-03-19 11:15:10 +01:00
Tim Hunt 8c448e1c83 MDL-26861 quiz view align Summary of your previous attempts table consistenty
Fix thanks to Joseph Rézeau.
2011-03-19 09:31:27 +00:00
Tim Hunt c08643da97 MDL-26887 Refactor file_save_draft_area_files to separate out the file_rewrite_urls_to_pluginfile bit. 2011-03-18 16:41:29 +00:00
Eloy Lafuente (stronk7) 00570de599 MDL-26883 ddl - fix some function declarations 2011-03-18 14:40:20 +01:00
Sam Hemelryk ced9fc4453 theme-anomaly MDL-25621 Added support for the langmenu to the config.php file 2011-03-18 16:53:03 +08:00
Sam Hemelryk 34b9d4d4a5 portfolio MDL-23022 Fixed navigation when cancelling a portfolio export 2011-03-18 16:19:59 +08:00
Adam Olley 9bf6815753 user-selector MDL-25975 Fixed timeout bug in user selector that was affecting IE8 2011-03-18 15:02:55 +08:00
Sam Hemelryk 4c2820fbd8 navigation MDL-26875 Moved course type check into object check and moved JS string call to navigation block where the navigation JS is initialised. 2011-03-18 14:45:10 +08:00
Sam Hemelryk dd18964703 navigation MDL-26570 Removed test from navigation simpletests which is no longer possible due to new cm_info object implementation 2011-03-18 13:51:35 +08:00
Sam Hemelryk c755c87437 navigation MDL-26570 branchid was renamed to key in previous fixes, unit tests updated to reflect this 2011-03-18 13:35:46 +08:00
Jonathon Fowler c683165a4a insert a 'View all courses' link when loading category navigation entries from AJAX 2011-03-18 15:00:14 +10:00
Sam Hemelryk d30d67aad5 theme-overlay MDL-25834 Added images to replace the standard dropdown arrows (new images are white) 2011-03-18 11:26:33 +08:00
Sam Hemelryk 53b1445eeb theme-overlay MDL-25834 Added CSS to better display the custom menu in the overlay theme 2011-03-18 11:23:58 +08:00
Petr Skoda a3516c4908 MDL-26826 add resizing of youtube and vimeo and remove non-functional % embedding sizes, only pixel sizes work in object tags 2011-03-17 22:13:07 +01:00
Petr Skoda 3e7069e70b MDL-26726 fix whitespace and a few debug and comment typos 2011-03-17 21:34:34 +01:00
Petr Skoda d2b322ae3c MDL-26825 do not return any form data if form cancelled 2011-03-17 20:43:35 +01:00
Matteo Scaramuccia 77e889a0ef MDL-26863: fixed regression by an appropriate Merging From Branch using 1.9 2011-03-17 18:15:42 +01:00
Petr Skoda 10793e570c MDL-26837 remove blacklisted markup from algebra conversion 2011-03-17 15:36:21 +01:00
Tim Hunt ea003cd59a MDL-26848 get rid of stupid unsigned columns in the quiz statistics report. 2011-03-17 12:48:01 +00:00
Petr Skoda 72650054f4 MDL-26833 send forum notifications to active enrolled users only 2011-03-16 23:26:00 +01:00
Petr Skoda 505c641a52 MDL-26834 remove suspended users from the participants list 2011-03-16 22:10:12 +01:00
Petr Skoda 22a7796343 MDL-26803 fix switched values of autosubscribe defaults in user upload 2011-03-16 20:00:06 +01:00
Petr Skoda bc61aa4085 MDL-26803 add missing forcing of password reset when new password created in cron 2011-03-16 19:59:33 +01:00
Petr Skoda 4335aa296e MDL-26844 ugly workaround for PHP int size limitation in query limits
It looks like the pg driver or database is internally overflowing at least on my 64bit test setup, I think we can safely return all results when from + num is over our max PHP integer.
2011-03-16 16:15:43 +01:00
Petr Skoda 3d24c50144 MDL-26844 fix use of invalid integers in dml tests 2011-03-16 16:08:55 +01:00
sam marshall adaeccb66d MDL-26781 Ensure get_fast_modinfo $cm is compatible with get_record $cm 2011-03-16 15:03:01 +00:00
Tim Hunt b6eb984a45 MDL-26747 Allow course reports to have settings.php 2011-03-16 14:45:02 +00:00
Petr Skoda 200b4556d7 MDL-26842 make sure query parameter names are not reserved words in oracle driver 2011-03-16 15:20:32 +01:00
Andrew Robert Nicols d8e7d1a085 formslib: MDL-26557 Use correct variable name and specify defaults in function declaration
Signed-off-by: Andrew Robert Nicols <andrew.nicols@luns.net.uk>
2011-03-16 10:50:07 +00:00
Andrew Davis (andyjdavis) f51cda3d09 lesson MDL-26571 made lesson accept a custom scale 2011-03-16 17:27:59 +08:00
Dan Poltawski f723bd3df5 blocks admin MDL-26827- allow blocks settings to be an admin externalpage
This borrows from Tim's technique for qtypes in 1650a33cb
2011-03-16 09:12:22 +00:00
Petr Skoda 56babbcb76 weekly release 2011-03-16 09:35:33 +01:00
Andrew Davis (andyjdavis) b6e526585a message MDL-26607 fixed sql error when searching for users and limiting search to your courses 2011-03-16 10:58:07 +08:00
Andrew Davis (andyjdavis) 76027a9f65 lesson MDL-26768 lesson was inserting a grade of 0 when a user id and a null raw grade were supplied 2011-03-16 10:26:12 +08:00
Eloy Lafuente (stronk7) 93d8fdc201 MDL-26697 take out unused vars from formal white 2011-03-15 15:33:36 +01:00
Eloy Lafuente (stronk7) e5e64a4886 Merge branch 'w11_MDL-26697_20_media' of git://github.com/skodak/moodle
Conflicts:
	theme/formal_white/config.php
2011-03-15 15:21:02 +01:00
Jerome Mouneyrac d587f077ef MDL-26822 enrol_user now save the status + trivial typo change in a (bit) related file 2011-03-15 17:27:27 +08:00
Mary Evans 1bb4846249 Fix for MDL-25565 2011-03-15 01:34:40 +00:00
Petr Skoda b0b4ab1aff Merge branch 'MDL-26464_m20_v2' of github.com:skodak/moodle 2011-03-14 20:55:04 +01:00
Petr Skoda 0393a8b706 MDL-26464 improve coding style and fix phpdocs 2011-03-14 20:54:00 +01:00
Petr Skoda cd3d2823af Merge branch 'MDL-26228_grade_full_view2' of git://github.com/andyjdavis/moodle 2011-03-14 18:21:33 +01:00
Petr Skoda 65361ab836 Merge branch 'MDL-24724_course_profile' of git://github.com/andyjdavis/moodle 2011-03-14 18:18:24 +01:00
Petr Skoda e7104d2dba PULL-400 fix incorrect format_white theme file permissions from recent commits 2011-03-14 18:11:09 +01:00
Petr Skoda 3908f7ca1a Merge branch 'MDL-4633_m20' of git://github.com/rwijaya/moodle 2011-03-14 18:01:19 +01:00
Eloy Lafuente (stronk7) 6326817e0f Merge branch 'MDL-26767' of git://github.com/timhunt/moodle 2011-03-14 12:07:41 +01:00
Eloy Lafuente (stronk7) 3d63eb08f6 Merge branch 'MDL-22478-alternative-langcacheroot' of git://github.com/mudrd8mz/moodle 2011-03-14 12:03:36 +01:00
Dan Marsden 571ae25286 MDL-21432 backup - add plagiarism plugin hooks for course and module 2011-03-14 11:44:14 +01:00
Sam Hemelryk f786f01115 Merge rebased branch 'formal_white_2011030507' of git://github.com/kordan/moodle.git 2011-03-14 18:02:18 +08:00
Sam Hemelryk e1f517fcc7 theme-formal_white MDL-26300, MDL-25628 , MDL-25520 Fixed whitespace and nesting issues 2011-03-14 17:59:57 +08:00
kordan 8b759a9a48 theme-formal_white MDL-26789 Fixed up vertical centering in navbar 2011-03-14 17:33:58 +08:00
kordan 5e911b2ea5 theme-formal_white MDL-26300, MDL-25628 , MDL-25520 fixed problems in admin report section pages 2011-03-14 17:33:38 +08:00
kordan 0e412e87a4 theme-formal_white MDL-26300, MDL-25628 , MDL-25520 one more setting and logos with transparent background to allow custom header background color 2011-03-14 17:33:03 +08:00
kordan 4afb01dbb4 formal white from scratch fixing MDL-26300, MDL-25628 , MDL-25520 2011-03-14 17:33:02 +08:00
Kordan 3718dfc771 theme-formal_white MDL-26300, MDL-25628 , MDL-25520 FW last version 2011-03-14 17:32:14 +08:00
Dongsheng Cai 2848b97948 MDL-24877, do not display all courses in course category tree if there are too many courses in moodle 2011-03-14 17:04:06 +08:00
Sam Hemelryk e96aa1a669 Merge branch 's7_MDL-26583_filepicker_lang' of git://github.com/dongsheng/moodle 2011-03-14 16:05:37 +08:00
Sam Hemelryk 4bbe460316 Merge branch 'w11_MDL-26480_20_redirect' of git://github.com/skodak/moodle 2011-03-14 15:41:51 +08:00
Sam Hemelryk 85f1abe304 Merge branch 'MDL-13983' of git://github.com/timhunt/moodle 2011-03-14 15:33:49 +08:00
Sam Hemelryk 9fed82de9c Merge branch 'MDL-26785' of git://github.com/stronk7/moodle 2011-03-14 11:22:05 +08:00
Sam Hemelryk 2012d82a96 Fixed merge conflicts in nonzero theme 2011-03-14 10:59:58 +08:00
Sam Hemelryk 66c6e870ef Merge branch 'MDL-25304' of git://github.com/epsd/moodle 2011-03-14 10:54:24 +08:00
Sam Hemelryk b146486613 Merge branch 'MDL-25786-2' of git://github.com/epsd/moodle 2011-03-14 10:43:42 +08:00
Sam Hemelryk e9fda1c945 Merge branch 'MDL-25212' of git://github.com/epsd/moodle 2011-03-14 10:36:17 +08:00
Sam Hemelryk af99e7286b Merge branch 'MDL-25939-3' of git://github.com/epsd/moodle 2011-03-14 10:33:17 +08:00
Sam Hemelryk 77a5af1f12 Merge branch 'MDL-26084' of git://github.com/epsd/moodle 2011-03-14 10:19:52 +08:00
Sam Hemelryk df94dbd825 Merge branch 'MDL-24743' of git://github.com/epsd/moodle 2011-03-14 09:57:55 +08:00
Sam Hemelryk e2d50a6a00 Merge branch 'MDL-26711' of git://github.com/epsd/moodle 2011-03-14 09:51:27 +08:00
Eloy Lafuente (stronk7) 64f3208b7c Merge branch 'w11_MDL-26698_20_helphttps' of git://github.com/skodak/moodle 2011-03-14 02:12:46 +01:00
Eloy Lafuente (stronk7) 3c38ad5d79 Merge branch 'MDL-26643' of git://github.com/nebgor/moodle 2011-03-14 01:57:08 +01:00
Eloy Lafuente (stronk7) 98fd7dcb72 Merge branch 'w11_MDL-24071_20_tex' of git://github.com/skodak/moodle 2011-03-14 01:53:29 +01:00
Eloy Lafuente (stronk7) b8f249b43a Merge branch 'w11_MDL-26634_20_ldapsep' of git://github.com/skodak/moodle 2011-03-14 01:26:22 +01:00
Eloy Lafuente (stronk7) 9f091bcd45 Merge branch 's7_MDL-9376_qaforum' of git://github.com/dongsheng/moodle 2011-03-14 01:22:10 +01:00
Eloy Lafuente (stronk7) 008011875c MDL-25352 fix tiny typo 2011-03-14 01:12:38 +01:00
Eloy Lafuente (stronk7) 5869d05bb7 Merge branch 'w11_MDL-25352_20_replace' of git://github.com/skodak/moodle 2011-03-14 01:10:35 +01:00
Eloy Lafuente (stronk7) 2b1a23a6aa Merge branch 'MDL-26594' of git://github.com/nebgor/moodle 2011-03-14 00:54:36 +01:00
Eloy Lafuente (stronk7) d47070248f Merge branch 'MDL-26748' of git://github.com/timhunt/moodle 2011-03-14 00:53:28 +01:00
Petr Skoda c3b5e8290b MDL-25352 fix multiple issues in admin/replace.php
Make sure admins know things can go wrong, MSSQL and Oracle were never working, fix block_html config saving issue, skip a lot more tables because the data there is serialised() or can not be changed in case of config tables, more warnings and checkbox confirmation.
2011-03-14 00:51:42 +01:00
Eloy Lafuente (stronk7) 6bfddc2e38 Merge branch 'MDL-26773' of git://github.com/timhunt/moodle 2011-03-14 00:49:11 +01:00
Eloy Lafuente (stronk7) 7e0579cb8c Merge branch 'MDL-26714' of git://github.com/timhunt/moodle 2011-03-14 00:43:58 +01:00
Eloy Lafuente (stronk7) 9929445926 Merge branch 'MDL-19555_m20' of git://github.com/rwijaya/moodle 2011-03-14 00:35:03 +01:00
Eloy Lafuente (stronk7) f934143c6c Merge branch 'AMOS-install-strings' of git://github.com/mudrd8mz/moodle 2011-03-14 00:32:01 +01:00
Eloy Lafuente (stronk7) e9579e548d Merge branch 'w11_MDL-26621_20_profilemail' of git://github.com/skodak/moodle 2011-03-14 00:25:04 +01:00
Eloy Lafuente (stronk7) 5cd0d27089 Merge branch 'MDL-26730' of git://github.com/timhunt/moodle 2011-03-13 23:50:20 +01:00
Eloy Lafuente (stronk7) b5686d021b Merge branch 'MDL-26735' of git://github.com/timhunt/moodle 2011-03-13 23:41:48 +01:00
Eloy Lafuente (stronk7) d93c27ec95 Merge branch 'MDL-26734' of git://github.com/timhunt/moodle 2011-03-13 23:33:09 +01:00
Eloy Lafuente (stronk7) 908b892d9c Merge branch 'MDL-21446' of git://github.com/timhunt/moodle 2011-03-13 23:31:05 +01:00
Eloy Lafuente (stronk7) 22acfde076 Merge branch 'MDL-26733' of git://github.com/timhunt/moodle 2011-03-13 23:28:07 +01:00
Eloy Lafuente (stronk7) 40b204b863 Merge branch 'wip-MDL-26606' of git://github.com/sammarshallou/moodle 2011-03-13 23:22:04 +01:00
Eloy Lafuente (stronk7) 4f7fd61a7a Merge branch 'MDL-26724' of git://github.com/timhunt/moodle 2011-03-13 22:57:06 +01:00
AMOS bot 8dc0b786d0 Automatic installer lang files (20110313) 2011-03-13 19:45:51 +01:00
Petr Skoda 69542fb3af MDL-26698 use https for help ajax loginhttps pages 2011-03-13 17:08:50 +01:00
Petr Skoda f7f0909ce5 PULL-442 multiple TeX related fixes
Prevent moodle_url error, cleanup entity encoding and decoding, disable tex source view when TeX and Algebra plugins disabled, localise TeX source popup and prevent phishing attempts, fix executable permission of Algebra pearl script, prevent image error in tex debug when Tex/Ghostscript not configured properly, fix copyright blocks and phpdocs, improve coding style, fix wrong source display link in Algebra filter.
2011-03-13 15:18:07 +01:00
Petr Skoda b399e43592 MDL-26480 IIS redirect bug workaround
Credit goes to Zenger Sergey
2011-03-13 10:47:47 +01:00
Petr Skoda ee69d85a1f MDL-26634 LDAP NTLM SSO Multiple subnet separator is not specified and people use a wrong one
Credit goes to Inaki Arenaza.
2011-03-13 10:14:20 +01:00
Petr Skoda 181991e791 MDL-26621 respect email privacy settings on the main user profile and fix missing context 2011-03-12 19:04:26 +01:00
Petr Skoda fcd2cbaf1f MDL-26697 multiple media filtering fixes and improvements
Bug fixes:
    * fixed broken flash resizing via URL
    * upgraded Flowplayer
    * fixed invalid context in format_text()
    * all media related CSS moved from themes to filter and resources
    * fixed automatic pdf resizing in resources

Changes:
    * reworked filter_mediaplugin system settings - grouped by player type instead of individual extensions, added more information
    * improved regex url matching
    * removed old unused players, Eolas fix and UFO embedding
    * image embedding moved to filter_urltolink
    * new Flowplayer embedding API
    * accessibility and compatibility tweaks in Flowplayer
    * SWF embedding now works only in trusted texts, it is now enabled by default (works everywhere if "Allow EMBED and OBJECT tags" enabled)
    * new default video width and height

New features:
    * automatic Flash video resizing using information from video metadata
    * Flash HD video support (*.f4v)
    * Flash video embedding with HTML5 fallback - compatible with iOS and other mobile devices
    * Vimeo embedding
    * no-cookie YouTube site supported
    * HTML 5 audio and video with multiple source URLs and QuickTime fallback
    * more video and audio extensions in filelib.php
    * MP3 player colours customisable via CSS in themes
    * nomediaplugin class in a tag prevents media embedding
2011-03-12 17:42:52 +01:00
Eloy Lafuente (stronk7) e140197481 MDL-26785 module edit - icon in heading missing sometimes 2011-03-12 01:39:58 +01:00
stabijoh fab058e5d5 Added custom menu to nonzero theme, MDL-26711 2011-03-11 07:22:56 -05:00
David Mudrak c198593b0e MDL-22478 Allow alternative location of strings disk cache
Administrators can now specify $CFG->langcacheroot in their config.php for
alternative location of strings disk cache. If the alternative location is
not set, Moodle uses default $CFG->dataroot/cache/lang
2011-03-11 12:34:52 +01:00
Tim Hunt 74a43c7487 MDL-26773 PHP error notice when editing multianswer question
$course was removed from the save question methods in 2.0, but this occurrence was missed.
Thanks to Joseph Rezeau for the fix
2011-03-11 08:51:47 +00:00
Tim Hunt c159b07046 MDL-26767 responses report has the same unsigned subtract issue as overview (MDL-26416) 2011-03-11 07:37:29 +00:00
Aparup Banerjee 2a5302b62d MDL-26643 added missing message property to discussion object used to upgrade blog 2011-03-11 14:28:45 +08:00
Dongsheng Cai 67fc4f0025 MDL-9376, disallow student to see the other users posts in max editing time, credits to Vlas Voloshin and Charles Fulton 2011-03-11 11:22:13 +08:00
Rossiani Wijaya 6e571603c0 MDL-19555: add NULL string test to format_test(). Credit goes to Matej Vela. Thanks 2011-03-11 11:16:18 +08:00
Rossiani Wijaya e4e9611570 MDL-26464: remove 'add entry' link on setting block when it reachs the max number of records. Link removal does not apply to user who has data:manageentries capability (eg: teacher). 2011-03-11 10:03:14 +08:00
Tim Hunt c5169f4e78 MDL-26748 file links in qtype essay feedback broken.
Fix thanks to Respondus Inc.
2011-03-10 21:40:00 +00:00
stabijoh 66e937a44b MDL-25304 minor fix to Fusion theme forum post style 2011-03-10 13:52:26 -05:00
stabijoh d60cc8dbec Added custom menu support to Leatherbound theme, MDL-25212 2011-03-10 09:54:59 -05:00
sam marshall 69ae86ea5f MDL-26606 Theme backup: Minor improvement to make it more consistent with other backup 2011-03-10 12:57:27 +00:00
stabijoh ec5ced0d9d Additional work for MDL-25939, fix splash orange blog titles 2011-03-10 07:33:55 -05:00
stabijoh 2ef9c4eb67 MDL-26084 fix in Canvas theme for hide section icon 2011-03-10 07:15:03 -05:00
Rossiani Wijaya 91c2b0f068 MDL-4633: remove 'required' rule for user's profile description 2011-03-10 15:45:49 +08:00
Tim Hunt 9316d66121 MDL-26714 qtype_multianswer needs an implementation of compare_responses.
The main problem lack of this was causing is if you click through a quiz without answering any questions, mulitanswer questions would get marked as answered.
2011-03-09 18:08:18 +00:00
Rod Norfor 1e668c4d85 MDL-13983 show frozen radio buttons in a more accessible way. 2011-03-09 16:26:37 +00:00
Tim Hunt b053dcab0f MDL-26730 when going back from modedit.php to the course, go to the right section. 2011-03-09 15:51:15 +00:00
Tim Hunt f11672d84a MDL-26735 Questions file links broken when quiz_attempts.id and .uniqueid differ. 2011-03-09 15:46:59 +00:00
Tim Hunt 5f36713765 MDL-26734 fatal error on the quiz review page when reviews are not allowed.
Sorry silly error by me, merging code from my 2.1 work.
2011-03-09 15:22:15 +00:00
Tim Hunt 0484f1ef01 MDL-21446 truncate >31 char worksheet names that otherwise break Excel export. 2011-03-09 14:43:44 +00:00
stabijoh cea5d97b4c Additional fix for MDL-25786, use of #header in theme Magazine 2011-03-09 09:35:42 -05:00
stabijoh ca8f828cb5 MDL-24743 fix for Magazine theme forced font size 2011-03-09 08:01:27 -05:00
Aparup Banerjee c4a88609fe MDL-26594 renamed named param causing oracle reserved word error. - thanks to Luca Mazzola 2011-03-09 17:04:09 +08:00
Dongsheng Cai a6b53a7cbe FILEPICKER MDL-26583 filepicker should use core language string not string from modules 2011-03-09 17:00:01 +08:00
Petr Skoda c09604234a weekly release 2011-03-09 09:07:01 +01:00
Andrew Davis (andyjdavis) 48c235941f gradebook MDL-26228 moved scrollbar css from standard theme into base 2011-03-09 15:55:25 +08:00
Andrew Davis (andyjdavis) 8d22e342a9 user MDL-24724 added email to user course profile 2011-03-09 13:29:55 +08:00
Tim Hunt d93cafeaa1 MDL-26733 avoid possible notice in admin/user.php. 2011-03-08 17:48:05 +00:00
Tim Hunt 7e0218e79f MDL-26724 notice from numerical qtype when no answer is given. 2011-03-08 10:43:48 +00:00
Petr Skoda ed66022935 MDL-26625 do not look for session size if session not started 2011-03-08 10:31:16 +01:00
Petr Skoda 23c799459d Revert "MDL-26392, nwiki and creole format wiki pages should support file attachments"
This reverts commit 0c5e812ba7  because UI is going to be reimplemented.
2011-03-08 10:11:07 +01:00
Mary Evans 2150d1580f Added Custom CSS Settings - Fix for MDL-26700 2011-03-07 15:01:21 -08:00
Mary Evans 2fb0b3bd3b Edited theme/nonzero/style/core.css via GitHub 2011-03-07 09:27:30 -08:00
Eloy Lafuente (stronk7) 97b4297e13 Merge branch 'MDL-26517' of git://github.com/timhunt/moodle 2011-03-07 14:49:17 +01:00
Tim Hunt 71575a152c MDL-26517 display responses in reports by converting to plain text.
Following Eloy's testing, that seems to be the only safe way. It is also consistent with what has been done in Moodle 2.1.
2011-03-07 11:57:38 +00:00
Petr Skoda 4eca364392 Merge branch 'MDL-26458_PULL' of git://github.com/nebgor/moodle 2011-03-07 12:52:51 +01:00
Petr Skoda 8eade3d773 Merge branch 'MDL-26392_wiki_images' of git://github.com/dongsheng/moodle 2011-03-07 12:40:04 +01:00
Petr Skoda 25ca24d59f Merge branch 'MDL-25388_restore_activities_target' of git://github.com/stronk7/moodle 2011-03-07 12:32:46 +01:00
Petr Skoda 2c10c5f4e5 Merge branch 'wip-MDL-26423' of git://github.com/sammarshallou/moodle 2011-03-07 12:28:27 +01:00
Eloy Lafuente (stronk7) 5f9f0717fe Merge branch 'MDL-26609-version-maturity' of git://github.com/mudrd8mz/moodle 2011-03-07 11:49:28 +01:00
Petr Skoda 29c852088a Merge branch 'wip-MDL-26625' of git://github.com/sammarshallou/moodle 2011-03-07 10:25:28 +01:00
Petr Skoda 7a2f4c12b6 Merge branch 'MDL-26433_message_constants' of git://github.com/andyjdavis/moodle 2011-03-07 10:18:31 +01:00
Eloy Lafuente (stronk7) 9f3813016c Merge branch 'MDL-26190' of git://github.com/srynot4sale/moodle 2011-03-07 02:58:09 +01:00
Eloy Lafuente (stronk7) 34700d60f2 Merge branch 'MDL-20562-report-link-string' of git://github.com/mudrd8mz/moodle 2011-03-07 02:48:42 +01:00
Eloy Lafuente (stronk7) 51ecc3255b Merge branch 'm20_MDL-26672_aiccfix' of git://github.com/danmarsden/moodle 2011-03-07 02:37:28 +01:00
Eloy Lafuente (stronk7) 500422e6d0 Merge branch 'workshop-submissions-anonymity-and-availability' of git://github.com/mudrd8mz/moodle 2011-03-07 01:56:28 +01:00
Eloy Lafuente (stronk7) 5ff33ba14b Merge branch 'MDL-26324' of git://github.com/timhunt/moodle 2011-03-07 01:22:43 +01:00
Eloy Lafuente (stronk7) 34e30d9bce Merge branch 'MDL-26445' of git://github.com/timhunt/moodle 2011-03-07 01:12:55 +01:00
Eloy Lafuente (stronk7) 7d754148c4 Merge branch 'MDL-26685' of git://github.com/timhunt/moodle 2011-03-07 01:06:51 +01:00
Eloy Lafuente (stronk7) 2875c1507f Merge branch 'MDL-26520' of git://github.com/timhunt/moodle 2011-03-07 00:29:14 +01:00
Eloy Lafuente (stronk7) 5878504958 Merge branch 'MDL-26636' of git://github.com/timhunt/moodle 2011-03-07 00:25:54 +01:00
Eloy Lafuente (stronk7) 4b43b1074f backup MDL-26572 add new param to plugin and subplugin functions 2011-03-07 00:16:25 +01:00
Eloy Lafuente (stronk7) 07a36633f9 Merge branch 'MDL-26572_backup_sum' of git://github.com/andyjdavis/moodle 2011-03-07 00:10:16 +01:00
David Mudrak d67c20b873 MDL-26535 workshop: fixed availability of published and assessed submissions
While working on the new capability to view authors of published
submissions, I realized that published submissions are correctly listed
(implemented in 00bc77ee) but they can't be viewed by submission.php.
This patch fixes submission.php so that it allows to view published
submissions.

Also, I noticed that when the workshop is closed, the submissions that
were assessed by the user are not listed (as they were in the previous
phases) but submission.php provides access to them correctly. So I added
a code that lists assessed submissions in the closed phase.
2011-03-06 23:49:49 +01:00
Dan Marsden 69c3d39a9c AICC MDL-26672 fix for handling of value = 0 2011-03-07 09:54:33 +13:00
andyjdavis 25bd5c75ab message MDL-26433 refactored the constants in messaging 2011-03-06 22:03:49 +08:00
ppichet 8f63ab1f44 MDL-26445 question -fix numerical unit grade
fix unit penalty grading and display


Signed-off-by: ppichet <pichet.pierre@uqam.ca>
2011-03-05 20:13:50 +00:00
Tim Hunt 209442ce24 MDL-26517 HTML tags visible in the response history table and quiz reports. 2011-03-05 19:51:38 +00:00
Tim Hunt 4a6f461830 MDL-26685 each attempt builds on last did not work when quiz_attemts.id and question_attempts.id were not equal. 2011-03-05 19:27:32 +00:00
Tim Hunt 231ec77323 MDL-26520 random tf questions that had not been answered were shown as answered on the summary page.
This was a regression from MDL-26236 thanks to some brain-dead PHP behaviour.
2011-03-05 16:33:42 +00:00
Tim Hunt b302591de8 MDL-26636 fix typo in language string.
Thanks to Luis de Vasconcelos.
2011-03-05 15:19:49 +00:00
Eloy Lafuente (stronk7) 165b7bd987 MDL-25388 restore - confusing options restoring 1-activity 2011-03-04 19:45:43 +01:00
Tim Hunt 0357171e68 MDL-26324 overall feedback problem when quiz changed to being graded out of 0 2011-03-04 17:20:12 +00:00
Aparup Banerjee 7fedc2c25e lib MDL-26458 adding unit tests to test cursors.
-added test with limits and order by with table aliases to test_get_records_sql()
 -added test_recordset_locks_delete() and test_recordset_locks_update()
 - added out of range limits test to test_get_records_sql()
2011-03-05 01:18:36 +08:00
sam marshall 89213d0041 backup MDL-26606 Backup should allow themes to have course data; also fix course theme restore 2011-03-04 15:53:48 +00:00
sam marshall b031caf858 lib MDL-26423 Added support for ->allowid option in format_text 2011-03-04 15:53:10 +00:00
sam marshall f07704d2a2 lib MDL-26625 Add session size info to perfdebug block 2011-03-04 15:52:19 +00:00
David Mudrak e13d02f544 MDL-26535 workshop: new capability to control the anonymity of published submissions
Re-using 'mod/workshop:viewauthornames' would not be a happy option here
because teacher would have to change local overrides every time when
they were closing or re-opening the workshop (if they wanted anonymous
assessment but non-anonymous hall of fame).
2011-03-04 14:08:00 +01:00
David Mudrak 757bade1f6 MDL-26684 workshop: fixed missing href attribute in the link to the own submission
This was caused by incorrect construction of workshop_submission_summary.
Instead of direct initiation, the helper method should be used. The
helper adds a property 'url' needed to render 'href' later.
2011-03-04 14:07:50 +01:00
David Mudrak de6aaa7295 MDL-26683 workshop: fixed typos in code comments 2011-03-04 13:03:49 +01:00
Eloy Lafuente (stronk7) 3479ba4d48 MDL-26458 sqlsrv - limit impl using scrollable sets 2011-03-04 16:12:37 +08:00
Dongsheng Cai 0c5e812ba7 MDL-26392, nwiki and creole format wiki pages should support file attachments 2011-03-04 15:44:20 +08:00
David Mudrak ea118bed0c MDL-20562 Do not use a capability name as a navigation node title
Ideally all reports should use their pluginname in the navigation tree.
In this particular case, the patch fixes two issues: using the
capability name as the report title in the navigation and incorrect
pluginname defined for coursereport_log.
2011-03-04 06:03:39 +01:00
David Mudrak 1a4d6a5b60 MDL-26609 Display information about the current version during the upgrade
As Eloy Lafuente noticed in the tracker discussion, we display the
information about the current version in the browser window title but
not at the screen itself. The patch fixes that by displaying the
information in the page heading instead of the page title.

Eloy's original idea to put the information into the grey message box
would require a change of [upgradesure,core_admin] string because
unfortunately it does not expect $a as an object but as a plain string.
2011-03-04 05:59:08 +01:00
David Mudrak dc41abd808 MDL-26609 Provide a link to a docs page for more help with Moodle versions and their maturity
Thanks Martin Dougiamas for this suggestion.
2011-03-04 05:59:08 +01:00
David Mudrak 3d673fc474 MDL-26609 Admins are warned if they try to install or upgrade to unstable version
The commit introduces four new constants that can be used to declare a
maturity level of Moodle core and, in the future, of extension plugins.
If the administrator is about to install or upgrade Moodle to a version
that is not considered as production-ready yet, a warning is displayed
before any change in the database.
2011-03-04 05:59:08 +01:00
Andrew Davis (andyjdavis) 98529b009b backup MDL-26572 made restore store null instead of 0 2011-03-04 12:14:00 +08:00
Petr Skoda 48fe5c6cf9 weekly release 2011-03-03 18:26:24 +01:00
Petr Skoda 84fed015d8 Revert "gradebook MDL-26228 moved scroll bar css from standard theme into base"
This reverts commit 54c3b90ec6.
2011-03-02 09:09:06 +01:00
Aaron Barnes 0b15b43b3e MDL-26190 completion blocks: Show messages rather than hiding the block 2011-03-02 16:34:19 +13:00
Eloy Lafuente (stronk7) 5eb1e14aa4 Merge branch 'w09_MDL-26564_20_uploadusers' of git://github.com/skodak/moodle 2011-03-01 19:02:04 +01:00
Petr Skoda 2197b642b3 MDL-26564 print password when changed 2011-03-01 17:29:52 +01:00
Petr Skoda faceca9176 MDL-26564 fix reversed password policy check 2011-03-01 17:22:00 +01:00
Petr Skoda 431ac39634 MDL-26623 fix file permissions
The permissions are now going to be verified as part of the weekly release process.
2011-03-01 12:26:49 +01:00
Petr Skoda 2a921ee985 MDL-26047 fix string letter case and whitespace 2011-03-01 12:11:31 +01:00
Eloy Lafuente (stronk7) 8cf42d248e Merge branch 'w09_MDL-26564_20_uploadusers' of git://github.com/skodak/moodle 2011-03-01 12:05:52 +01:00
Eloy Lafuente (stronk7) 847753d497 Merge branch 'w09_MDL-26616_20_resourcelinks' of git://github.com/skodak/moodle 2011-02-28 18:41:03 +01:00
Eloy Lafuente (stronk7) 8ef8ec689e MDL-26047 nimble theme - changing 2 "fusion" ocurrences 2011-02-28 12:28:44 +01:00
Eloy Lafuente (stronk7) c2a975e68d Merge branch 'MDL-26047' of git://github.com/ptrkmkl/moodle 2011-02-28 12:27:46 +01:00
Eloy Lafuente (stronk7) a8ccca5325 MDL-26404 messages - move textlib instance out from loop 2011-02-28 10:35:21 +01:00
Eloy Lafuente (stronk7) 77e4bb774b Merge branch 'MDL-26404_nav_too_wide' of git://github.com/andyjdavis/moodle 2011-02-28 10:17:51 +01:00
Petr Skoda 70e6628ea3 Merge branch 'MDL-26576' of git://github.com/timhunt/moodle 2011-02-28 10:06:03 +01:00
Petr Skoda 589028b203 Merge branch 'MDL-25760' of git://github.com/ptrkmkl/moodle 2011-02-28 10:03:57 +01:00
Petr Skoda bca4fa81a8 Merge branch 'MDL-26451_alfresco_repo' of git://github.com/dongsheng/moodle 2011-02-28 10:01:03 +01:00
Petr Skoda ed9fd13fd6 Merge branch 'MDL-26228_grade_full_view' of git://github.com/andyjdavis/moodle 2011-02-28 09:59:13 +01:00
Petr Skoda 7c4c754a89 Merge branch 'MDL-26442_qtype_match' of git://github.com/stronk7/moodle 2011-02-28 09:56:36 +01:00
Petr Skoda 16fd74a3a5 Merge branch 'm20_MDL-26545_userpicfix' of git://github.com/danmarsden/moodle 2011-02-28 09:48:38 +01:00
David Mudrak 29cbe43189 MDL-13481 Strings fullname and shortname are now deprecated
This is a final cleanup commit of fullname and shortname issue. All
places where these strings were detected yet have been replaced with
proper fullnamecourse or fullnameuser or some other context specific
string.

AMOS BEGIN
 CPY [fullname,core],[outcomefullname,core_grades]
 CPY [shortname,core],[outcomeshortname,core_grades]
 CPY [name,core],[rolefullname,core_role]
 CPY [shortname,core],[roleshortname,core_role]
AMOS END
2011-02-28 09:42:50 +01:00
Petr Skoda 8bdb31ed54 MDL-26564 fix regressions and other problems in csv user upload
This patch fixes incorrect password creating, updating and resetting, updating of user fields, unsupported auth plugins are correctly identified, modification of mnethostid is prevented, fixed problem with email duplicates, new password is generated for users without email, etc. It also includes coding style improvements, more inline docs, future TODOs and license information.
2011-02-28 08:27:31 +01:00
Dan Marsden 629f5021b3 SCORM MDL-26545 - fix user object passed to user_picture renderer 2011-02-28 12:33:29 +13:00
Petr Skoda 3d8f1d3abc MDL-26616 fix broken resource modinfo caused by invalid sortorder upgrade 2011-02-27 22:54:41 +01:00
Andrew 54c3b90ec6 gradebook MDL-26228 moved scroll bar css from standard theme into base 2011-02-27 21:49:00 +08:00
Dongsheng Cai b9825e8e29 REPOSITORY MDL-23951 alfresco repository plugin supports returning external links 2011-02-24 10:56:30 +08:00
Eloy Lafuente (stronk7) 303c04f7d0 MDL-26442 restore - missing new in qtype match exception 2011-02-24 02:24:18 +01:00
Eloy Lafuente (stronk7) 2b37004c28 weekly release 2011-02-23 20:03:30 +01:00
Tim Hunt 92c4354ff9 MDL-26576 avoid notices one quizzes with no overall feedback. 2011-02-23 11:42:37 +00:00
Andrew b2bce32ff0 message MDL-26404 trimming course short to prevent long names messing up the UI 2011-02-23 11:00:41 +08:00
Eloy Lafuente (stronk7) fa188aa0a2 Merge branch 'MDL-26546-workshop-restore' of git://github.com/mudrd8mz/moodle 2011-02-22 23:00:46 +01:00
David Mudrak 1dade8b185 MDL-26546 Workshop: fixed embedded images in Number of errors grading form
Because of this typo, embedded images were not loaded when the
assessment form was re-edited. Thanks Helen Foster for spotting this.
2011-02-22 22:19:16 +01:00
Eloy Lafuente (stronk7) d6211dce9a Merge branch 'MDL-25816_jabber_preference' of git://github.com/andyjdavis/moodle 2011-02-22 16:51:49 +01:00
Eloy Lafuente (stronk7) ec58c9ddf0 Merge branch 'MDL-26537-flickr-callback-url' of git://github.com/mudrd8mz/moodle 2011-02-22 16:23:08 +01:00
Eloy Lafuente (stronk7) 5df4d6ccab Merge branch 'MDL-26513_restrict_modules' of git://github.com/stronk7/moodle 2011-02-22 16:12:43 +01:00
Eloy Lafuente (stronk7) 9da0fc11ac Merge branch 'MDL-26532' of git://github.com/nebgor/moodle 2011-02-22 15:40:30 +01:00
Eloy Lafuente (stronk7) 0783533066 Merge branch 'AMOS-install-strings' of git://github.com/mudrd8mz/moodle 2011-02-22 15:37:24 +01:00
Eloy Lafuente (stronk7) a8f690e4e6 Merge branch 'MDL-21250-capitalized-strings' of git://github.com/mudrd8mz/moodle 2011-02-22 15:35:50 +01:00
Helen Foster 6cb66ae00e MDL-21250 Get rid of capitalized words in titles 2011-02-22 14:15:58 +01:00
Eloy Lafuente (stronk7) 908053e21d Merge branch 'MDL-25122' of git://github.com/timhunt/moodle 2011-02-22 12:41:28 +01:00
Eloy Lafuente (stronk7) 915a20f5a5 Merge branch 'MDL-26546-workshop-restore' of git://github.com/mudrd8mz/moodle 2011-02-22 12:24:48 +01:00
Eloy Lafuente (stronk7) 0797530336 Merge branch 'MDL-26416' of git://github.com/timhunt/moodle 2011-02-22 12:18:52 +01:00
Eloy Lafuente (stronk7) c5530f4151 Merge branch 'fix-symbian' of git://github.com/darenc/moodle 2011-02-22 11:45:57 +01:00
Eloy Lafuente (stronk7) f7edca80b0 Merge branch 'MDL-26524' of git://github.com/grabs/moodle 2011-02-22 11:35:29 +01:00
Eloy Lafuente (stronk7) 3521e87f06 Merge branch 'MDL-26060' of git://github.com/grabs/moodle 2011-02-22 11:30:33 +01:00
Eloy Lafuente (stronk7) f44872427f Merge branch 'MDL-26435_rem_commented_out_code' of git://github.com/andyjdavis/moodle 2011-02-22 11:26:56 +01:00
Eloy Lafuente (stronk7) d33d813d91 Merge branch 'lesson-rendering' of git://github.com/mudrd8mz/moodle 2011-02-22 11:25:03 +01:00
Eloy Lafuente (stronk7) e49c60345e Merge branch 'wip-MDL-26507' of git://github.com/sammarshallou/moodle 2011-02-22 11:17:16 +01:00
Eloy Lafuente (stronk7) 29336fb13c Merge branch 'MDL-26461_change_rating_scale' of git://github.com/andyjdavis/moodle 2011-02-22 11:06:23 +01:00
Eloy Lafuente (stronk7) cc31313c4b Merge branch 'MDL-26440_uid' of git://github.com/andyjdavis/moodle 2011-02-22 10:27:38 +01:00
Andrew Davis (andyjdavis) 6c0f13a5bc message MDL-25816 added safety checks in form processing 2011-02-22 16:05:01 +08:00
David Mudrak 7c26c3f875 MDL-26546 Workshop: fixed incorrect mapping name in the restore of assessment forms
There was a regression of 8fa86f and ac0f8f where I changed the mapping
names but did not use the new names in add_related_files() call.

All credit goes to Eloy Lafuente for spotting the problem and giving me
a hint on how to fix it.
2011-02-22 00:54:13 +01:00
AMOS bot d5a1cca1af Automatic installer lang files (20110222) 2011-02-22 00:27:05 +01:00
David Mudrak dd2645d304 MDL-26537 Portfolio: Flickr setup instruction contains correct callback URL
There was a bug due to the code copied from portfolio_boxnet plugin.
2011-02-21 16:00:12 +01:00
Eloy Lafuente (stronk7) e4f72d1428 MDL-26513 restore - observe target site restrictmodulesfor setting 2011-02-21 15:58:20 +01:00
Charles Fulton fdef13e692 MDL-26507: improper use of assignment operater causes grade checks to fail 2011-02-21 12:54:37 +00:00
Aparup Banerjee d042ff06b3 assignment MDL-26532 fixed regression in assignment_cron() while processing messaging. 2011-02-21 15:43:30 +08:00
Andrew Davis (andyjdavis) aafa4f324a rating MDL-26461 fixed an off by 1 bug that made the safeguard against too high ratings not work 2011-02-21 10:48:38 +08:00
Andreas Grabs 5cf4fa4684 MDL-26524 - Group Filtering Errors 2011-02-20 18:18:44 +01:00
Andreas Grabs 7cc5cec6e1 MDL-26060 - Sorting by date on user list for responses list throws an error 2011-02-20 17:45:10 +01:00
Tim Hunt 79c6e3a096 MDL-25122 Quiz review page does not check and enforce separate groups mode. 2011-02-18 18:53:37 +00:00
Tim Hunt 19a9f1124d MDL-26416 avoid subtracting two unsigned ints, which breaks MySQL since 5.5.5. 2011-02-18 14:10:06 +00:00
Tim Hunt bbc2d0ba31 MDL-26416 quiz overview report, clean up the code before making the real bug fix.
Cleaning up the code like this will make the real bug-fix easier to understand.
2011-02-18 14:10:04 +00:00
Daren Chandisingh cb6b733232 Change 'Simbian' to 'Symbian' 2011-02-18 12:28:26 +00:00
David Mudrak ffdf7f8a24 MDL-25899 Lesson: fixed page content rendering
Form element 'header' used to be used for rendering the page contents.
This led to layout problems in non-gecko browsers. This patch fixes the
issue by using raw 'html' element to render the page contents.
2011-02-18 11:43:24 +01:00
Joseph Rezeau c76cd2ede1 MDL-26113 Lesson: temporary fix of page content alignment
That rendering method should not use cell style attribute at all.
Instead, the alignment should be controlled by CSS. However, this will
require more massive changes in the Lesson code to be done by the module
maintainer. As a temporary fix, left alignment is set as it usually
matches the layout that students see.
2011-02-18 10:43:25 +01:00
andyjdavis 7bbe971548 general MDL-26440 removed references to uid in SQL queries as its a reserved word in Oracle 2011-02-18 15:51:50 +08:00
andyjdavis 731f8516bc message MDL-26435 removed commented out code 2011-02-17 11:03:18 +08:00
ptrkmkl ee3b46d8bf MDL-26047 - added new theme called Nimble 2011-01-18 08:42:48 -05:00
ptrkmkl 6f2257ae0d Removed white color from course section content and added white color to section content left side for topic number styling 2011-01-08 12:39:05 -05:00
1188 changed files with 16440 additions and 6973 deletions
+5 -1
View File
@@ -147,7 +147,11 @@
$settings = ''; // By default, no configuration
if ($blockobject and $blockobject->has_config()) {
if (file_exists($CFG->dirroot.'/blocks/'.$block->name.'/settings.php')) {
$blocksettings = admin_get_root()->locate('blocksetting' . $block->name);
if ($blocksettings instanceof admin_externalpage) {
$settings = '<a href="' . $blocksettings->url . '">' . get_string('settings') . '</a>';
} else if ($blocksettings instanceof admin_settingpage) {
$settings = '<a href="'.$CFG->wwwroot.'/'.$CFG->admin.'/settings.php?section=blocksetting'.$block->name.'">'.$strsettings.'</a>';
} else {
$settings = '<a href="block.php?block='.$blockid.'">'.$strsettings.'</a>';
+2 -2
View File
@@ -88,9 +88,9 @@ function bloglevelupgrade_entries($blogentries, $forum, $cm, $groupid=-1) {
$discussion->course = $forum->course;
$discussion->forum = $forum->id;
$discussion->name = $blogentry->subject;
$discussion->intro = $blogentry->summary;
$discussion->assessed = $forum->assessed;
$discussion->messageformat = $forum->introformat;
$discussion->message = $blogentry->summary;
$discussion->messageformat = $blogentry->summaryformat;
$discussion->messagetrust = 0;
$discussion->attachments = 0;
$discussion->mailnow = false;
+28 -3
View File
@@ -70,6 +70,8 @@ Options:
problem encountered.
--agree-license Indicates agreement with software license,
required in non-interactive mode.
--allow-unstable Install even if the version is not marked as stable yet,
required in non-interactive mode.
-h, --help Print out this help
Example:
@@ -136,9 +138,6 @@ $CFG->early_install_lang = true;
$parts = explode('/', str_replace('\\', '/', dirname(dirname(__FILE__))));
$CFG->admin = array_pop($parts);
require($CFG->dirroot.'/version.php');
$CFG->target_release = $release;
//point pear include path to moodles lib/pear so that includes and requires will search there for files before anywhere else
//the problem is that we need specific version of quickforms and hacked excel files :-(
ini_set('include_path', $CFG->libdir.'/pear' . PATH_SEPARATOR . ini_get('include_path'));
@@ -154,6 +153,9 @@ require_once($CFG->libdir.'/deprecatedlib.php');
require_once($CFG->libdir.'/adminlib.php');
require_once($CFG->libdir.'/componentlib.class.php');
require($CFG->dirroot.'/version.php');
$CFG->target_release = $release;
//Database types
$databases = array('mysqli' => moodle_database::get_driver_instance('mysqli', 'native'),
'pgsql' => moodle_database::get_driver_instance('pgsql', 'native'),
@@ -193,6 +195,7 @@ list($options, $unrecognized) = cli_get_params(
'adminpass' => '',
'non-interactive' => false,
'agree-license' => false,
'allow-unstable' => false,
'help' => false
),
array(
@@ -402,6 +405,28 @@ $CFG->langotherroot = $CFG->dataroot.'/lang';
$CFG->langlocalroot = $CFG->dataroot.'/lang';
get_string_manager(true);
// make sure we are installing stable release or require a confirmation
if (isset($maturity)) {
if (($maturity < MATURITY_STABLE) and !$options['allow-unstable']) {
$maturitylevel = get_string('maturity'.$maturity, 'admin');
if ($interactive) {
cli_separator();
cli_heading(get_string('notice'));
echo get_string('maturitycorewarning', 'admin', $maturitylevel) . PHP_EOL;
echo get_string('morehelp') . ': ' . get_docs_url('admin/versions') . PHP_EOL;
echo get_string('continue') . PHP_EOL;
$prompt = get_string('cliyesnoprompt', 'admin');
$input = cli_input($prompt, '', array(get_string('clianswerno', 'admin'), get_string('cliansweryes', 'admin')));
if ($input == get_string('clianswerno', 'admin')) {
exit(1);
}
} else {
cli_error(get_string('maturitycorewarning', 'admin'));
}
}
}
// ask for db type - show only drivers available
if ($interactive) {
$options['dbtype'] = strtolower($options['dbtype']);
+39 -4
View File
@@ -40,8 +40,16 @@ require_once($CFG->libdir.'/environmentlib.php');
// now get cli options
list($options, $unrecognized) = cli_get_params(array('non-interactive'=>false, 'help'=>false),
array('h'=>'help'));
list($options, $unrecognized) = cli_get_params(
array(
'non-interactive' => false,
'allow-unstable' => false,
'help' => false
),
array(
'h' => 'help'
)
);
$interactive = empty($options['non-interactive']);
@@ -59,6 +67,8 @@ Site defaults may be changed via local/defaults.php.
Options:
--non-interactive No interactive questions or confirmations
--allow-unstable Upgrade even if the version is not marked as stable yet,
required in non-interactive mode.
-h, --help Print out this help
Example:
@@ -73,17 +83,18 @@ if (empty($CFG->version)) {
cli_error(get_string('missingconfigversion', 'debug'));
}
require("$CFG->dirroot/version.php"); // defines $version and $release
require("$CFG->dirroot/version.php"); // defines $version, $release and $maturity
$CFG->target_release = $release; // used during installation and upgrades
if ($version < $CFG->version) {
cli_error(get_string('downgradedcore', 'error'));
}
$oldversion = "$CFG->release ($CFG->version)";
$newversion = "$release ($version)";
// test environment first
if (!check_moodle_environment($version, $environment_results, false, ENV_SELECT_RELEASE)) {
if (!check_moodle_environment(normalize_version($release), $environment_results, false, ENV_SELECT_RELEASE)) {
$errors = environment_get_errors($environment_results);
cli_heading(get_string('environment', 'admin'));
foreach ($errors as $error) {
@@ -93,6 +104,30 @@ if (!check_moodle_environment($version, $environment_results, false, ENV_SELECT_
exit(1);
}
if ($interactive) {
$a = new stdClass();
$a->oldversion = $oldversion;
$a->newversion = $newversion;
echo cli_heading(get_string('databasechecking', '', $a)) . PHP_EOL;
}
// make sure we are upgrading to a stable release or display a warning
if (isset($maturity)) {
if (($maturity < MATURITY_STABLE) and !$options['allow-unstable']) {
$maturitylevel = get_string('maturity'.$maturity, 'admin');
if ($interactive) {
cli_separator();
cli_heading(get_string('notice'));
echo get_string('maturitycorewarning', 'admin', $maturitylevel) . PHP_EOL;
echo get_string('morehelp') . ': ' . get_docs_url('admin/versions') . PHP_EOL;
cli_separator();
} else {
cli_error(get_string('maturitycorewarning', 'admin', $maturitylevel));
}
}
}
if ($interactive) {
echo html_to_text(get_string('upgradesure', 'admin', $newversion))."\n";
$prompt = get_string('cliyesnoprompt', 'admin');
+114
View File
@@ -328,4 +328,118 @@
</CUSTOM_CHECK>
</CUSTOM_CHECKS>
</MOODLE>
<MOODLE version="2.1" requires="1.9">
<UNICODE level="required">
<FEEDBACK>
<ON_ERROR message="unicoderequired" />
</FEEDBACK>
</UNICODE>
<DATABASE level="required">
<VENDOR name="mysql" version="5.0.25">
<FEEDBACK>
<ON_ERROR message="mysql416required" />
</FEEDBACK>
</VENDOR>
<VENDOR name="postgres" version="8.3" />
<VENDOR name="mssql" version="9.0" />
<VENDOR name="odbc_mssql" version="9.0" />
<VENDOR name="mssql_n" version="9.0" />
<VENDOR name="oracle" version="10.2" />
<VENDOR name="sqlite" version="2.0" />
</DATABASE>
<PHP version="5.3.2" level="required">
</PHP>
<PHP_EXTENSIONS>
<PHP_EXTENSION name="iconv" level="required">
<FEEDBACK>
<ON_CHECK message="iconvrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="mbstring" level="optional">
<FEEDBACK>
<ON_CHECK message="mbstringrecommended" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="curl" level="required">
<FEEDBACK>
<ON_CHECK message="curlrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="openssl" level="optional">
<FEEDBACK>
<ON_CHECK message="opensslrecommended" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="tokenizer" level="optional">
<FEEDBACK>
<ON_CHECK message="tokenizerrecommended" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="xmlrpc" level="optional">
<FEEDBACK>
<ON_CHECK message="xmlrpcrecommended" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="soap" level="optional">
<FEEDBACK>
<ON_CHECK message="soaprecommended" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="ctype" level="required">
<FEEDBACK>
<ON_ERROR message="ctyperequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="zip" level="required">
<FEEDBACK>
<ON_ERROR message="ziprequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="gd" level="optional">
<FEEDBACK>
<ON_CHECK message="gdrecommended" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="simplexml" level="required">
<FEEDBACK>
<ON_CHECK message="simplexmlrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="spl" level="required">
<FEEDBACK>
<ON_CHECK message="splrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="pcre" level="required">
</PHP_EXTENSION>
<PHP_EXTENSION name="dom" level="required">
</PHP_EXTENSION>
<PHP_EXTENSION name="xml" level="required">
</PHP_EXTENSION>
<PHP_EXTENSION name="intl" level="optional">
<FEEDBACK>
<ON_CHECK message="intlrecommended" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="json" level="required">
</PHP_EXTENSION>
</PHP_EXTENSIONS>
<PHP_SETTINGS>
<PHP_SETTING name="memory_limit" value="40M" level="required">
<FEEDBACK>
<ON_ERROR message="settingmemorylimit" />
</FEEDBACK>
</PHP_SETTING>
<PHP_SETTING name="safe_mode" value="0" level="optional">
<FEEDBACK>
<ON_CHECK message="settingsafemode" />
</FEEDBACK>
</PHP_SETTING>
<PHP_SETTING name="file_uploads" value="1" level="optional">
<FEEDBACK>
<ON_CHECK message="settingfileuploads" />
</FEEDBACK>
</PHP_SETTING>
</PHP_SETTINGS>
</MOODLE>
</COMPATIBILITY_MATRIX>
Executable → Regular
+2 -2
View File
@@ -387,10 +387,10 @@ class generator {
.$this->get('number_of_modules')." modules in each section, for each course...");
list($modules_list_sql, $modules_params) =
$DB->get_in_or_equal($this->get('modules_list'), SQL_PARAMS_NAMED, 'param0000', true);
$DB->get_in_or_equal($this->get('modules_list'), SQL_PARAMS_NAMED, 'mod', true);
list($modules_ignored_sql, $ignore_params) =
$DB->get_in_or_equal($this->modules_to_ignore, SQL_PARAMS_NAMED, 'param2000', false);
$DB->get_in_or_equal($this->modules_to_ignore, SQL_PARAMS_NAMED, 'ignore', false);
$wheresql = "name $modules_list_sql AND name $modules_ignored_sql";
$modules = $DB->get_records_select('modules', $wheresql, array_merge($modules_params, $ignore_params));
+29 -8
View File
@@ -86,7 +86,7 @@ if (!isset($CFG->version)) {
$version = null;
$release = null;
require("$CFG->dirroot/version.php"); // defines $version and $release
require("$CFG->dirroot/version.php"); // defines $version, $release and $maturity
$CFG->target_release = $release; // used during installation and upgrades
if (!$version or !$release) {
@@ -130,17 +130,29 @@ if (!core_tables_exist()) {
if (empty($confirmrelease)) {
$strcurrentrelease = get_string('currentrelease');
$PAGE->navbar->add($strcurrentrelease);
$PAGE->set_title($strinstallation.' - Moodle '.$CFG->target_release);
$PAGE->set_heading($strinstallation);
$PAGE->set_title($strinstallation);
$PAGE->set_heading($strinstallation . ' - Moodle ' . $CFG->target_release);
$PAGE->set_cacheable(false);
echo $OUTPUT->header();
echo $OUTPUT->heading("Moodle $release");
if (isset($maturity)) {
// main version.php declares moodle code maturity
if ($maturity < MATURITY_STABLE) {
$maturitylevel = get_string('maturity'.$maturity, 'admin');
echo $OUTPUT->box(
$OUTPUT->container(get_string('maturitycorewarning', 'admin', $maturitylevel)) .
$OUTPUT->container($OUTPUT->doc_link('admin/versions', get_string('morehelp'))),
'generalbox maturitywarning');
}
}
$releasenoteslink = get_string('releasenoteslink', 'admin', 'http://docs.moodle.org/en/Release_Notes');
$releasenoteslink = str_replace('target="_blank"', 'onclick="this.target=\'_blank\'"', $releasenoteslink); // extremely ugly validation hack
echo $OUTPUT->box($releasenoteslink, 'generalbox boxaligncenter boxwidthwide');
echo $OUTPUT->box($releasenoteslink, 'generalbox releasenoteslink');
require_once($CFG->libdir.'/environmentlib.php');
if (!check_moodle_environment($release, $environment_results, true, ENV_SELECT_RELEASE)) {
if (!check_moodle_environment(normalize_version($release), $environment_results, true, ENV_SELECT_RELEASE)) {
print_upgrade_reload("index.php?agreelicense=1&amp;lang=$CFG->lang");
} else {
echo $OUTPUT->notification(get_string('environmentok', 'admin'), 'notifysuccess');
@@ -189,11 +201,20 @@ if ($version > $CFG->version) { // upgrade
$strdatabasechecking = get_string('databasechecking', '', $a);
if (empty($confirmupgrade)) {
$PAGE->navbar->add($strdatabasechecking);
$PAGE->set_title($strdatabasechecking);
$PAGE->set_heading($stradministration);
$PAGE->set_title($stradministration);
$PAGE->set_heading($strdatabasechecking);
$PAGE->set_cacheable(false);
echo $OUTPUT->header();
if (isset($maturity)) {
// main version.php declares moodle code maturity
if ($maturity < MATURITY_STABLE) {
$maturitylevel = get_string('maturity'.$maturity, 'admin');
echo $OUTPUT->box(
$OUTPUT->container(get_string('maturitycorewarning', 'admin', $maturitylevel)) .
$OUTPUT->container($OUTPUT->doc_link('admin/versions', get_string('morehelp'))),
'generalbox maturitywarning');
}
}
$continueurl = new moodle_url('index.php', array('confirmupgrade' => 1));
$cancelurl = new moodle_url('index.php');
echo $OUTPUT->confirm(get_string('upgradesure', 'admin', $a->newversion), $continueurl, $cancelurl);
Executable → Regular
-5
View File
@@ -53,11 +53,6 @@ define('INSTALLATION_OF_SELECTED_LANG', 2);
define('DELETION_OF_SELECTED_LANG', 4);
define('UPDATE_ALL_LANG', 5);
//reset and diagnose lang cache permissions
remove_dir($CFG->dataroot.'/cache/languages');
if (file_exists($CFG->dataroot.'/cache/languages')) {
print_error('cannotdeletelangcache', 'error');
}
get_string_manager()->reset_caches();
$notice_ok = array();
Executable → Regular
View File
+16 -21
View File
@@ -11,23 +11,32 @@ admin_externalpage_setup('replace');
$search = optional_param('search', '', PARAM_RAW);
$replace = optional_param('replace', '', PARAM_RAW);
$sure = optional_param('sure', 0, PARAM_BOOL);
###################################################################
echo $OUTPUT->header();
echo $OUTPUT->heading('Search and replace text throughout the whole database');
if ($DB->get_dbfamily() !== 'mysql' and $DB->get_dbfamily() !== 'postgres') {
//TODO: add $DB->text_replace() to DML drivers
echo $OUTPUT->notification('Sorry, this feature is implemented only for MySQL and PostgreSQL databases.');
echo $OUTPUT->footer();
die;
}
if (!data_submitted() or !$search or !$replace or !confirm_sesskey()) { /// Print a form
if (!data_submitted() or !$search or !$replace or !confirm_sesskey() or !$sure) { /// Print a form
echo $OUTPUT->notification('This script is not supported, always make complete backup before proceeding!<br />This operation can not be reverted!');
echo $OUTPUT->box_start();
echo '<div class="mdl-align">';
echo '<form action="replace.php" method="post">';
echo '<form action="replace.php" method="post"><div>';
echo '<input type="hidden" name="sesskey" value="'.sesskey().'" />';
echo 'Search whole database for: <input type="text" name="search" /><br />';
echo 'Replace with this string: <input type="text" name="replace" /><br />';
echo '<input type="submit" value="Yes, do it now" /><br />';
echo '</form>';
echo '<div><label for="search">Search whole database for: </label><input id="search" type="text" name="search" size="40" /> (usually previous server URL)</div>';
echo '<div><label for="replace">Replace with this string: </label><input type="text" id="replace" name="replace" size="40" /> (usually new server URL)</div>';
echo '<div><label for="sure">I understand the risks of this operation: </label><input type="checkbox" id="sure" name="sure" value="1" /></div>';
echo '<div class="buttons"><input type="submit" class="singlebutton" value="Yes, do it now" /></div>';
echo '</div></form>';
echo '</div>';
echo $OUTPUT->box_end();
echo $OUTPUT->footer();
@@ -35,23 +44,9 @@ if (!data_submitted() or !$search or !$replace or !confirm_sesskey()) { /// Pr
}
echo $OUTPUT->box_start();
if (!db_replace($search, $replace)) {
print_error('erroroccur', debug);
}
db_replace($search, $replace);
echo $OUTPUT->box_end();
/// Try to replace some well-known serialised contents (html blocks)
echo $OUTPUT->notification('Replacing in html blocks...');
$instances = $DB->get_recordset('block_instances', array('blockname' => 'html'));
foreach ($instances as $instance) {
$blockobject = block_instance('html', $instance);
$blockobject->config->text = str_replace($search, $replace, $blockobject->config->text);
$blockobject->instance_config_commit();
}
$instances->close();
/// Rebuild course cache which might be incorrect now
echo $OUTPUT->notification('Rebuilding course cache...', 'notifysuccess');
rebuild_course_cache();
+3 -3
View File
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
<XMLDB PATH="admin/report/customlang/db" VERSION="20101115" COMMENT="XMLDB file for Moodle admin/report/customlang"
<XMLDB PATH="admin/report/customlang/db" VERSION="20110419" COMMENT="XMLDB file for Moodle admin/report/customlang"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../lib/xmldb/xmldb.xsd"
>
@@ -30,11 +30,11 @@
<FIELDS>
<FIELD NAME="id" TYPE="int" LENGTH="10" NOTNULL="true" UNSIGNED="true" SEQUENCE="true" NEXT="name"/>
<FIELD NAME="name" TYPE="char" LENGTH="255" NOTNULL="true" SEQUENCE="false" COMMENT="The normalized name of the plugin" PREVIOUS="id" NEXT="version"/>
<FIELD NAME="version" TYPE="int" LENGTH="10" NOTNULL="false" UNSIGNED="true" SEQUENCE="false" COMMENT="The checked out version of the plugin, null of the version is unknown" PREVIOUS="name"/>
<FIELD NAME="version" TYPE="char" LENGTH="255" NOTNULL="false" SEQUENCE="false" COMMENT="The checked out version of the plugin, null if the version is unknown" PREVIOUS="name"/>
</FIELDS>
<KEYS>
<KEY NAME="primary" TYPE="primary" FIELDS="id"/>
</KEYS>
</TABLE>
</TABLES>
</XMLDB>
</XMLDB>
+13
View File
@@ -57,5 +57,18 @@ function xmldb_report_customlang_upgrade($oldversion) {
upgrade_plugin_savepoint(true, 2010111500, 'report', 'customlang');
}
/**
* Change the version field from integer to varchar
*/
if ($oldversion < 2011041900) {
$table = new xmldb_table('report_customlang_components');
$field = new xmldb_field('version', XMLDB_TYPE_CHAR, '255', null, null, null, null, 'name');
$dbman->change_field_type($table, $field);
upgrade_plugin_savepoint(true, 2011041900, 'report', 'customlang');
}
return $result;
}
+18 -2
View File
@@ -24,6 +24,8 @@
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
define('NO_OUTPUT_BUFFERING', true); // progress bar is used here
require(dirname(dirname(dirname(dirname(__FILE__)))).'/config.php');
require_once($CFG->dirroot.'/'.$CFG->admin.'/report/customlang/locallib.php');
require_once($CFG->libdir.'/adminlib.php');
@@ -45,8 +47,22 @@ if ($action === 'checkout') {
if (empty($lng)) {
print_error('missingparameter');
}
report_customlang_utils::checkout($lng);
redirect(new moodle_url('/admin/report/customlang/edit.php', array('lng' => $lng)));
$PAGE->set_cacheable(false); // progress bar is used here
$output = $PAGE->get_renderer('report_customlang');
echo $output->header();
echo $output->heading(get_string('pluginname', 'report_customlang'));
$progressbar = new progress_bar();
$progressbar->create(); // prints the HTML code of the progress bar
// we may need a bit of extra execution time and memory here
@set_time_limit(HOURSECS);
raise_memory_limit(MEMORY_EXTRA);
report_customlang_utils::checkout($lng, $progressbar);
echo $output->continue_button(new moodle_url('/admin/report/customlang/edit.php', array('lng' => $lng)), 'get');
echo $output->footer();
exit;
}
if ($action === 'checkin') {
@@ -27,7 +27,9 @@
defined('MOODLE_INTERNAL') || die();
$string['checkin'] = 'Check in strings into disk';
$string['checkout'] = 'Check out strings into translator';
$string['checkout'] = 'Check out strings into the translator';
$string['checkoutdone'] = 'Strings checked out successfully into the translator';
$string['checkoutinprogress'] = 'Checking out strings into the translator';
$string['confirmcheckin'] = 'You are about to check in modified strings into your local language pack. This will export the customized strings from the translator into the data directory and Moodle will start using the modified strings. Press \'Continue\' button to proceed check in.';
$string['customlang:edit'] = 'Edit local translation';
$string['customlang:view'] = 'View local translation';
+23 -2
View File
@@ -16,7 +16,7 @@
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
/**
* Definition of classes used by Langugae customization admin report
* Definition of classes used by language customization admin report
*
* @package report
* @subpackage customlang
@@ -33,6 +33,12 @@ defined('MOODLE_INTERNAL') || die();
*/
class report_customlang_utils {
/**
* Rough number of strings that are being processed during a full checkout.
* This is used to estimate the progress of the checkout.
*/
const ROUGH_NUMBER_OF_STRINGS = 16500;
/** @var array cache of {@link self::list_components()} results */
protected static $components = null;
@@ -83,8 +89,9 @@ class report_customlang_utils {
* This should be executed each time before going to the translation page
*
* @param string $lang language code to checkout
* @param progress_bar $progressbar optionally, the given progress bar can be updated
*/
public static function checkout($lang) {
public static function checkout($lang, progress_bar $progressbar = null) {
global $DB;
// make sure that all components are registered
@@ -107,6 +114,10 @@ class report_customlang_utils {
}
unset($current);
// initialize the progress counter - stores the number of processed strings
$done = 0;
$strinprogress = get_string('checkoutinprogress', 'report_customlang');
// reload components and fetch their strings
$stringman = get_string_manager();
$components = $DB->get_records('report_customlang_components');
@@ -129,6 +140,12 @@ class report_customlang_utils {
$stringlocal = isset($local[$stringid]) ? $local[$stringid] : null;
$now = time();
if (!is_null($progressbar)) {
$done++;
$donepercent = floor(min($done, self::ROUGH_NUMBER_OF_STRINGS) / self::ROUGH_NUMBER_OF_STRINGS * 100);
$progressbar->update_full($donepercent, $strinprogress);
}
if (isset($current[$stringid])) {
$needsupdate = false;
$currentoriginal = $current[$stringid]->original;
@@ -175,6 +192,10 @@ class report_customlang_utils {
}
}
}
if (!is_null($progressbar)) {
$progressbar->update_full(100, get_string('checkoutdone', 'report_customlang'));
}
}
/**
+4
View File
@@ -63,3 +63,7 @@
background-color: #f6f6f6;
margin-top: 0.5em;
}
#page-admin-report-customlang-index .continuebutton {
margin-top: 1em;
}
+1 -1
View File
@@ -24,5 +24,5 @@
defined('MOODLE_INTERNAL') || die();
$plugin->version = 2010120900;
$plugin->version = 2011041900;
$plugin->requires = 2010120700;
+8 -6
View File
@@ -151,19 +151,21 @@ function search_spammers($keywords) {
$params = array('userid'=>$USER->id);
$keywordfull = array();
$i = 0;
foreach ($keywords as $keyword) {
$keywordfull[] = $DB->sql_like('description', ':descpat', false);
$params['descpat'] = "%$keyword%";
$keywordfull2[] = $DB->sql_like('p.summary', ':sumpat', false);
$params['sumpat'] = "%$keyword%";
$keywordfull[] = $DB->sql_like('description', ':descpat'.$i, false);
$params['descpat'.$i] = "%$keyword%";
$keywordfull2[] = $DB->sql_like('p.summary', ':sumpat'.$i, false);
$params['sumpat'.$i] = "%$keyword%";
$i++;
}
$conditions = '( '.implode(' OR ', $keywordfull).' )';
$conditions2 = '( '.implode(' OR ', $keywordfull2).' )';
$sql = "SELECT * FROM {user} WHERE deleted = 0 AND id <> :userid AND $conditions"; // Exclude oneself
$sql2 = "SELECT u.*, p.summary FROM {user} AS u, {post} AS p WHERE $conditions2 AND u.deleted = 0 AND u.id=p.userid AND u.id <> :userid";
$spamusers_desc = $DB->get_recordset_sql($sql);
$spamusers_blog = $DB->get_recordset_sql($sql2);
$spamusers_desc = $DB->get_recordset_sql($sql, $params);
$spamusers_blog = $DB->get_recordset_sql($sql2, $params);
$keywordlist = implode(', ', $keywords);
echo $OUTPUT->box(get_string('spamresult', 'report_spamcleaner').s($keywordlist)).' ...';
View File
Executable → Regular
View File
Executable → Regular
View File
Executable → Regular
View File
Executable → Regular
View File
+4 -5
View File
@@ -628,7 +628,7 @@ class define_role_table_advanced extends capability_table_with_risks {
// Legacy type.
$archetype = optional_param('archetype', null, PARAM_RAW);
if ($archetype) {
if (isset($archetype)) {
$archetypes = get_role_archetypes();
if (isset($archetypes[$archetype])){
$this->role->archetype = $archetype;
@@ -716,7 +716,6 @@ class define_role_table_advanced extends capability_table_with_risks {
}
protected function get_archetype_field($id) {
global $OUTPUT;
$options = array();
$options[''] = get_string('none');
foreach(get_role_archetypes() as $type) {
@@ -780,8 +779,8 @@ class define_role_table_advanced extends capability_table_with_risks {
global $OUTPUT;
// Extra fields at the top of the page.
echo '<div class="topfields clearfix">';
$this->print_field('name', get_string('name'), $this->get_name_field('name'));
$this->print_field('shortname', get_string('shortname'), $this->get_shortname_field('shortname'));
$this->print_field('name', get_string('rolefullname', 'role'), $this->get_name_field('name'));
$this->print_field('shortname', get_string('roleshortname', 'role'), $this->get_shortname_field('shortname'));
$this->print_field('edit-description', get_string('description'), $this->get_description_field('description'));
$this->print_field('menuarchetype', get_string('archetype', 'role').'&nbsp;'.$OUTPUT->help_icon('archetype', 'role'), $this->get_archetype_field('archetype'));
$this->print_field('', get_string('maybeassignedin', 'role'), $this->get_assignable_levels_control());
@@ -1143,7 +1142,7 @@ class existing_role_holders extends role_assign_user_selector_base {
global $DB;
list($wherecondition, $params) = $this->search_sql($search, 'u');
list($ctxcondition, $ctxparams) = $DB->get_in_or_equal(get_parent_contexts($this->context, true), SQL_PARAMS_NAMED, 'ctx00');
list($ctxcondition, $ctxparams) = $DB->get_in_or_equal(get_parent_contexts($this->context, true), SQL_PARAMS_NAMED, 'ctx');
$params = array_merge($params, $ctxparams);
$params['roleid'] = $this->roleid;
Executable → Regular
+1 -1
View File
@@ -194,7 +194,7 @@
$table->head = array(
get_string('role') . ' ' . $OUTPUT->help_icon('roles', 'role'),
get_string('description'),
get_string('shortname'),
get_string('roleshortname', 'role'),
get_string('edit')
);
Executable → Regular
View File
Executable → Regular
View File
+5 -5
View File
@@ -63,10 +63,10 @@ if ($hassiteconfig) { // speedup for non-admins, add all caps used on this page
// blog
$temp = new admin_settingpage('blog', get_string('blog','blog'));
$temp->add(new admin_setting_configcheckbox('useblogassociations', get_string('useblogassociations', 'blog'), get_string('configuseblogassociations','blog'), 1));
$temp->add(new admin_setting_bloglevel('bloglevel', get_string('bloglevel', 'admin'), get_string('configbloglevel', 'admin'), 4, array(5 => get_string('worldblogs','blog'),
4 => get_string('siteblogs','blog'),
1 => get_string('personalblogs','blog'),
0 => get_string('disableblogs','blog'))));
$temp->add(new admin_setting_bloglevel('bloglevel', get_string('bloglevel', 'admin'), get_string('configbloglevel', 'admin'), 4, array(BLOG_GLOBAL_LEVEL => get_string('worldblogs','blog'),
BLOG_SITE_LEVEL => get_string('siteblogs','blog'),
BLOG_USER_LEVEL => get_string('personalblogs','blog'),
0 => get_string('disableblogs','blog'))));
$temp->add(new admin_setting_configcheckbox('useexternalblogs', get_string('useexternalblogs', 'blog'), get_string('configuseexternalblogs','blog'), 1));
$temp->add(new admin_setting_configselect('externalblogcrontime', get_string('externalblogcrontime', 'blog'), get_string('configexternalblogcrontime', 'blog'), 86400,
array(43200 => get_string('numhours', '', 12),
@@ -130,7 +130,7 @@ if ($hassiteconfig) { // speedup for non-admins, add all caps used on this page
// link to tag management interface
$ADMIN->add('appearance', new admin_externalpage('managetags', get_string('managetags', 'tag'), "$CFG->wwwroot/tag/manage.php"));
$temp = new admin_settingpage('additionalhtml', get_string('additionalhtml', 'admin'));
$temp->add(new admin_setting_heading('additionalhtml_heading', get_string('additionalhtml_heading', 'admin'), get_string('additionalhtml_desc', 'admin')));
$temp->add(new admin_setting_configtextarea('additionalhtmlhead', get_string('additionalhtmlhead', 'admin'), get_string('additionalhtmlhead_desc', 'admin'), '', PARAM_RAW));
+14 -5
View File
@@ -52,13 +52,22 @@ if (!during_initial_install()) { //do not use during installation
$temp->add(new admin_setting_configtext('coursesperpage', get_string('coursesperpage', 'admin'), get_string('configcoursesperpage', 'admin'), 20, PARAM_INT));
// front page default role
$roleoptions = array(0=>get_string('none')); // roles to choose from
if ($roles = get_all_roles()) {
foreach ($roles as $role) {
$roleoptions[$role->id] = strip_tags(format_string($role->name, true));
$options = array(0=>get_string('none')); // roles to choose from
$defaultfrontpageroleid = 0;
foreach (get_all_roles() as $role) {
if (empty($role->archetype) or $role->archetype === 'guest' or $role->archetype === 'frontpage' or $role->archetype === 'student') {
$options[$role->id] = strip_tags(format_string($role->name)) . ' ('. $role->shortname . ')';
if ($role->archetype === 'frontpage') {
$defaultfrontpageroleid = $role->id;
}
}
}
$temp->add(new admin_setting_configselect('defaultfrontpageroleid', get_string('frontpagedefaultrole', 'admin'), '', 0, $roleoptions));
if ($defaultfrontpageroleid and (!isset($CFG->defaultfrontpageroleid) or $CFG->defaultfrontpageroleid)) {
//frotpage role may not exist in old upgraded sites
unset($options[0]);
}
$temp->add(new admin_setting_configselect('defaultfrontpageroleid', get_string('frontpagedefaultrole', 'admin'), '', $defaultfrontpageroleid, $options));
$ADMIN->add('frontpage', $temp);
+1 -1
View File
@@ -10,7 +10,7 @@ if ($hassiteconfig) {
$temp->add(new admin_setting_configselect('lang', get_string('lang', 'admin'), get_string('configlang', 'admin'), current_language(), get_string_manager()->get_list_of_translations())); // $CFG->lang might be set in installer already, default en is in setup.php
$temp->add(new admin_setting_configcheckbox('langmenu', get_string('langmenu', 'admin'), get_string('configlangmenu', 'admin'), 1));
$temp->add(new admin_setting_langlist());
$temp->add(new admin_setting_configcheckbox('langcache', get_string('langcache', 'admin'), get_string('configlangcache', 'admin'), 1));
$temp->add(new admin_setting_configcheckbox('langcache', get_string('langcache', 'admin'), get_string('langcache_desc', 'admin'), 1));
$temp->add(new admin_setting_configcheckbox('langstringcache', get_string('langstringcache', 'admin'), get_string('configlangstringcache', 'admin'), 1));
$temp->add(new admin_setting_configtext('locale', get_string('localetext', 'admin'), get_string('configlocale', 'admin'), '', PARAM_FILE));
$temp->add(new admin_setting_configselect('latinexcelexport', get_string('latinexcelexport', 'admin'), get_string('configlatinexcelexport', 'admin'), '0', array('0'=>'Unicode','1'=>'Latin')));
+27 -2
View File
@@ -367,7 +367,7 @@ if ($hassiteconfig) {
}
$ADMIN->add('webservicesettings', $temp);
// Question type settings
if ($hassiteconfig || has_capability('moodle/question:config', $systemcontext)) {
// Question type settings.
$ADMIN->add('modules', new admin_category('qtypesettings', get_string('questiontypes', 'admin')));
@@ -385,6 +385,8 @@ if ($hassiteconfig || has_capability('moodle/question:config', $systemcontext))
}
}
}
// Plagiarism plugin settings
if ($hassiteconfig && !empty($CFG->enableplagiarism)) {
$ADMIN->add('modules', new admin_category('plagiarism', get_string('plagiarism', 'plagiarism')));
$temp = new admin_settingpage('plagiarismsettings', get_string('plagiarismsettings', 'plagiarism'));
@@ -397,8 +399,31 @@ if ($hassiteconfig && !empty($CFG->enableplagiarism)) {
}
}
$ADMIN->add('reports', new admin_externalpage('comments', get_string('comments'), $CFG->wwwroot.'/comment/', 'moodle/site:viewreports'));
/// Now add reports
// Course reports settings
if ($hassiteconfig) {
$pages = array();
foreach (get_plugin_list('coursereport') as $report => $path) {
$file = $CFG->dirroot . '/course/report/' . $report . '/settings.php';
if (file_exists($file)) {
$settings = new admin_settingpage('coursereport' . $report,
get_string('pluginname', 'coursereport_' . $report), 'moodle/site:config');
// settings.php may create a subcategory or unset the settings completely
include($file);
if ($settings) {
$pages[] = $settings;
}
}
}
if (!empty($pages)) {
$ADMIN->add('modules', new admin_category('coursereports', get_string('coursereports')));
foreach ($pages as $page) {
$ADMIN->add('coursereports', $page);
}
}
}
// Now add reports
foreach (get_plugin_list('report') as $plugin => $plugindir) {
$settings_path = "$plugindir/settings.php";
if (file_exists($settings_path)) {
+4
View File
@@ -227,6 +227,8 @@ $ADMIN->add('server', new admin_externalpage('phpinfo', get_string('phpinfo'), "
// "performance" settingpage
$temp = new admin_settingpage('performance', get_string('performance', 'admin'));
$temp->add(new admin_setting_configtext('numcoursesincombo', get_string('numcoursesincombo', 'admin'), get_string('numcoursesincombo_help', 'admin'), 500));
$temp->add(new admin_setting_configselect('extramemorylimit', get_string('extramemorylimit', 'admin'),
get_string('configextramemorylimit', 'admin'), '512M',
// if this option is set to 0, default 128M will be used
@@ -239,6 +241,8 @@ $temp->add(new admin_setting_configselect('extramemorylimit', get_string('extram
$temp->add(new admin_setting_configtext('curlcache', get_string('curlcache', 'admin'),
get_string('configcurlcache', 'admin'), 120, PARAM_INT));
$temp->add(new admin_setting_configtext('curltimeoutkbitrate', get_string('curltimeoutkbitrate', 'admin'),
get_string('curltimeoutkbitrate_help', 'admin'), 56, PARAM_INT));
/* //TODO: we need to fix code instead of relying on slow rcache, enable this once we have some code that is actually using it
$temp->add(new admin_setting_special_selectsetup('cachetype', get_string('cachetype', 'admin'),
get_string('configcachetype', 'admin'), '',
+2 -1
View File
@@ -37,9 +37,10 @@ if ($hassiteconfig) { // speedup for non-admins, add all caps used on this page
$optionalsubsystems->add(new admin_setting_configcheckbox('enablecompletion',
get_string('enablecompletion','completion'),
get_string('configenablecompletion','completion'), 0));
$optionalsubsystems->add(new admin_setting_configcheckbox('enableavailability',
$optionalsubsystems->add($checkbox = new admin_setting_configcheckbox('enableavailability',
get_string('enableavailability','condition'),
get_string('configenableavailability','condition'), 0));
$checkbox->set_affects_modinfo(true);
$optionalsubsystems->add(new admin_setting_configcheckbox('enableplagiarism', get_string('enableplagiarism','plagiarism'), get_string('configenableplagiarism','plagiarism'), 0));
}
+25 -27
View File
@@ -38,17 +38,18 @@ if ($hassiteconfig
if ($ADMIN->fulltree) {
if (!during_initial_install()) {
$context = get_context_instance(CONTEXT_SYSTEM);
$allroles = array();
$generalroles = array();
$otherroles = array();
$guestroles = array();
$userroles = array();
$studentroles = array();
$teacherroles = array();
$creatornewroles = array();
$defaultteacherid = null;
$defaultuserid = null;
$defaultguestid = null;
foreach (get_all_roles() as $role) {
$rolename = strip_tags(format_string($role->name)) . ' ('. $role->shortname . ')';
$allroles[$role->id] = $rolename;
switch ($role->archetype) {
case 'manager':
$creatornewroles[$role->id] = $rolename;
@@ -56,58 +57,55 @@ if ($hassiteconfig
case 'coursecreator':
break;
case 'editingteacher':
$teacherroles[$role->id] = $rolename;
$defaultteacherid = isset($defaultteacherid) ? $defaultteacherid : $role->id;
$creatornewroles[$role->id] = $rolename;
break;
case 'teacher':
$creatornewroles[$role->id] = $rolename;
break;
case 'student':
$studentroles[$role->id] = $rolename;
break;
case 'guest':
$defaultguestid = isset($defaultguestid) ? $defaultguestid : $role->id;
$guestroles[$role->id] = $rolename;
break;
case 'user':
$defaultuserid = isset($defaultuserid) ? $defaultuserid : $role->id;
$userroles[$role->id] = $rolename;
break;
case 'frontpage':
break;
default:
$creatornewroles[$role->id] = $rolename;
$generalroles[$role->id] = $rolename;
$otherroles[$role->id] = $rolename;
break;
}
}
reset($guestroles);
$defaultguestid = key($guestroles);
reset($studentroles);
$defaultstudentid = key($studentroles);
reset($teacherroles);
$defaultteacherid = key($teacherroles);
if (empty($guestroles)) {
$guestroles[0] = get_string('none');
$defaultguestid = 0;
}
if ($userroles) {
reset($userroles);
$defaultuserid = key($userroles);
} else {
$userroles = array('0'=>get_string('none'));
if (empty($userroles)) {
$userroles[0] = get_string('none');
$defaultuserid = 0;
}
$temp->add(new admin_setting_configselect('notloggedinroleid', get_string('notloggedinroleid', 'admin'),
get_string('confignotloggedinroleid', 'admin'), $defaultguestid, ($guestroles + $generalroles)));
get_string('confignotloggedinroleid', 'admin'), $defaultguestid, ($guestroles + $otherroles)));
$temp->add(new admin_setting_configselect('guestroleid', get_string('guestroleid', 'admin'),
get_string('guestroleid_help', 'admin'), $defaultguestid, ($guestroles + $generalroles)));
get_string('guestroleid_help', 'admin'), $defaultguestid, ($guestroles + $otherroles)));
$temp->add(new admin_setting_configselect('defaultuserroleid', get_string('defaultuserroleid', 'admin'),
get_string('configdefaultuserroleid', 'admin'), $defaultuserid, ($userroles + $generalroles)));
}
$temp->add(new admin_setting_configcheckbox('nodefaultuserrolelists', get_string('nodefaultuserrolelists', 'admin'), get_string('confignodefaultuserrolelists', 'admin'), 0));
if (!during_initial_install()) {
get_string('configdefaultuserroleid', 'admin'), $defaultuserid, ($userroles + $otherroles)));
$temp->add(new admin_setting_configselect('creatornewroleid', get_string('creatornewroleid', 'admin'),
get_string('creatornewroleid_help', 'admin'), $defaultteacherid, $creatornewroles));
// release memory
unset($otherroles);
unset($guestroles);
unset($userroles);
unset($creatornewroles);
}
$temp->add(new admin_setting_configcheckbox('autologinguests', get_string('autologinguests', 'admin'), get_string('configautologinguests', 'admin'), 0));
Executable → Regular
+396 -728
View File
File diff suppressed because it is too large Load Diff
+111 -63
View File
@@ -1,16 +1,44 @@
<?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/>.
if (!defined('MOODLE_INTERNAL')) {
die('Direct access to this script is forbidden.'); /// It must be included from a Moodle page
}
/**
* Bulk user upload forms
*
* @package core
* @subpackage admin
* @copyright 2007 Dan Poltawski
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
defined('MOODLE_INTERNAL') || die();
require_once $CFG->libdir.'/formslib.php';
class admin_uploaduser_form1 extends moodleform {
function definition (){
global $CFG, $USER;
$mform =& $this->_form;
/**
* Upload a file CVS file with user information.
*
* @package core
* @subpackage admin
* @copyright 2007 Petr Skoda {@link http://skodak.org}
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
class admin_uploaduser_form1 extends moodleform {
function definition () {
$mform = $this->_form;
$mform->addElement('header', 'settingsheader', get_string('upload'));
@@ -36,69 +64,90 @@ class admin_uploaduser_form1 extends moodleform {
$mform->addElement('select', 'previewrows', get_string('rowpreviewnum', 'admin'), $choices);
$mform->setType('previewrows', PARAM_INT);
$choices = array(UU_ADDNEW => get_string('uuoptype_addnew', 'admin'),
UU_ADDINC => get_string('uuoptype_addinc', 'admin'),
UU_ADD_UPDATE => get_string('uuoptype_addupdate', 'admin'),
UU_UPDATE => get_string('uuoptype_update', 'admin'));
$mform->addElement('select', 'uutype', get_string('uuoptype', 'admin'), $choices);
$this->add_action_buttons(false, get_string('uploadusers', 'admin'));
}
}
/**
* Specify user upload details
*
* @package core
* @subpackage admin
* @copyright 2007 Petr Skoda {@link http://skodak.org}
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
class admin_uploaduser_form2 extends moodleform {
function definition (){
function definition () {
global $CFG, $USER;
$mform =& $this->_form;
$columns =& $this->_customdata;
$mform = $this->_form;
$columns = $this->_customdata['columns'];
$data = $this->_customdata['data'];
// I am the template user, why should it be the administrator? we have roles now, other ppl may use this script ;-)
$templateuser = $USER;
// upload settings and file
$mform->addElement('header', 'settingsheader', get_string('settings'));
$mform->addElement('static', 'uutypelabel', get_string('uuoptype', 'admin') );
$choices = array(UU_USER_ADDNEW => get_string('uuoptype_addnew', 'admin'),
UU_USER_ADDINC => get_string('uuoptype_addinc', 'admin'),
UU_USER_ADD_UPDATE => get_string('uuoptype_addupdate', 'admin'),
UU_USER_UPDATE => get_string('uuoptype_update', 'admin'));
$mform->addElement('select', 'uutype', get_string('uuoptype', 'admin'), $choices);
$choices = array(0 => get_string('infilefield', 'auth'), 1 => get_string('createpasswordifneeded', 'auth'));
$mform->addElement('select', 'uupasswordnew', get_string('uupasswordnew', 'admin'), $choices);
$mform->setDefault('uupasswordnew', 1);
$mform->disabledIf('uupasswordnew', 'uutype', 'eq', UU_UPDATE);
$mform->disabledIf('uupasswordnew', 'uutype', 'eq', UU_USER_UPDATE);
$choices = array(0 => get_string('nochanges', 'admin'),
1 => get_string('uuupdatefromfile', 'admin'),
2 => get_string('uuupdateall', 'admin'),
3 => get_string('uuupdatemissing', 'admin'));
$choices = array(UU_UPDATE_NOCHANGES => get_string('nochanges', 'admin'),
UU_UPDATE_FILEOVERRIDE => get_string('uuupdatefromfile', 'admin'),
UU_UPDATE_ALLOVERRIDE => get_string('uuupdateall', 'admin'),
UU_UPDATE_MISSING => get_string('uuupdatemissing', 'admin'));
$mform->addElement('select', 'uuupdatetype', get_string('uuupdatetype', 'admin'), $choices);
$mform->setDefault('uuupdatetype', 0);
$mform->disabledIf('uuupdatetype', 'uutype', 'eq', UU_ADDNEW);
$mform->disabledIf('uuupdatetype', 'uutype', 'eq', UU_ADDINC);
$mform->setDefault('uuupdatetype', UU_UPDATE_NOCHANGES);
$mform->disabledIf('uuupdatetype', 'uutype', 'eq', UU_USER_ADDNEW);
$mform->disabledIf('uuupdatetype', 'uutype', 'eq', UU_USER_ADDINC);
$choices = array(0 => get_string('nochanges', 'admin'), 1 => get_string('update'));
$mform->addElement('select', 'uupasswordold', get_string('uupasswordold', 'admin'), $choices);
$mform->setDefault('uupasswordold', 0);
$mform->disabledIf('uupasswordold', 'uutype', 'eq', UU_ADDNEW);
$mform->disabledIf('uupasswordold', 'uutype', 'eq', UU_ADDINC);
$mform->disabledIf('uupasswordold', 'uutype', 'eq', UU_USER_ADDNEW);
$mform->disabledIf('uupasswordold', 'uutype', 'eq', UU_USER_ADDINC);
$mform->disabledIf('uupasswordold', 'uuupdatetype', 'eq', 0);
$mform->disabledIf('uupasswordold', 'uuupdatetype', 'eq', 3);
$choices = array(UU_PWRESET_WEAK => get_string('usersweakpassword', 'admin'),
UU_PWRESET_NONE => get_string('none'),
UU_PWRESET_ALL => get_string('all'));
if (empty($CFG->passwordpolicy)) {
unset($choices[UU_PWRESET_WEAK]);
}
$mform->addElement('select', 'uuforcepasswordchange', get_string('forcepasswordchange', 'core'), $choices);
$mform->addElement('selectyesno', 'uuallowrenames', get_string('allowrenames', 'admin'));
$mform->setDefault('uuallowrenames', 0);
$mform->disabledIf('uuallowrenames', 'uutype', 'eq', UU_ADDNEW);
$mform->disabledIf('uuallowrenames', 'uutype', 'eq', UU_ADDINC);
$mform->disabledIf('uuallowrenames', 'uutype', 'eq', UU_USER_ADDNEW);
$mform->disabledIf('uuallowrenames', 'uutype', 'eq', UU_USER_ADDINC);
$mform->addElement('selectyesno', 'uuallowdeletes', get_string('allowdeletes', 'admin'));
$mform->setDefault('uuallowdeletes', 0);
$mform->disabledIf('uuallowdeletes', 'uutype', 'eq', UU_ADDNEW);
$mform->disabledIf('uuallowdeletes', 'uutype', 'eq', UU_ADDINC);
$mform->disabledIf('uuallowdeletes', 'uutype', 'eq', UU_USER_ADDNEW);
$mform->disabledIf('uuallowdeletes', 'uutype', 'eq', UU_USER_ADDINC);
$mform->addElement('selectyesno', 'uunoemailduplicates', get_string('uunoemailduplicates', 'admin'));
$mform->setDefault('uunoemailduplicates', 1);
$choices = array(0 => get_string('no'),
1 => get_string('uubulknew', 'admin'),
2 => get_string('uubulkupdated', 'admin'),
3 => get_string('uubulkall', 'admin'));
$mform->addElement('selectyesno', 'uustandardusernames', get_string('uustandardusernames', 'admin'));
$mform->setDefault('uustandardusernames', 1);
$choices = array(UU_BULK_NONE => get_string('no'),
UU_BULK_NEW => get_string('uubulknew', 'admin'),
UU_BULK_UPDATED => get_string('uubulkupdated', 'admin'),
UU_BULK_ALL => get_string('uubulkall', 'admin'));
$mform->addElement('select', 'uubulk', get_string('uubulk', 'admin'), $choices);
$mform->setDefault('uubulk', 0);
@@ -152,18 +201,22 @@ class admin_uploaduser_form2 extends moodleform {
// default values
$mform->addElement('header', 'defaultheader', get_string('defaultvalues', 'admin'));
$mform->addElement('text', 'username', get_string('username'), 'size="20"');
$mform->addElement('text', 'username', get_string('uuusernametemplate', 'admin'), 'size="20"');
$mform->addRule('username', get_string('requiredtemplate', 'admin'), 'required', null, 'client');
$mform->disabledIf('username', 'uutype', 'eq', UU_USER_ADD_UPDATE);
$mform->disabledIf('username', 'uutype', 'eq', UU_USER_UPDATE);
$mform->addElement('text', 'email', get_string('email'), 'maxlength="100" size="30"');
$mform->disabledIf('email', 'uutype', 'eq', UU_USER_ADD_UPDATE);
$mform->disabledIf('email', 'uutype', 'eq', UU_USER_UPDATE);
// only enabled and known to work plugins
$choices = uu_allowed_auths();
$choices = uu_supported_auths();
$mform->addElement('select', 'auth', get_string('chooseauthmethod','auth'), $choices);
$mform->setDefault('auth', 'manual'); // manual is a sensible backwards compatible default
$mform->addHelpButton('auth', 'chooseauthmethod', 'auth');
$mform->setAdvanced('auth');
$mform->addElement('text', 'email', get_string('email'), 'maxlength="100" size="30"');
$choices = array(0 => get_string('emaildisplayno'), 1 => get_string('emaildisplayyes'), 2 => get_string('emaildisplaycourse'));
$mform->addElement('select', 'maildisplay', get_string('emaildisplay'), $choices);
$mform->setDefault('maildisplay', 2);
@@ -178,7 +231,7 @@ class admin_uploaduser_form2 extends moodleform {
$mform->setDefault('maildigest', 0);
$mform->setAdvanced('maildigest');
$choices = array(0 => get_string('autosubscribeyes'), 1 => get_string('autosubscribeno'));
$choices = array(1 => get_string('autosubscribeyes'), 0 => get_string('autosubscribeno'));
$mform->addElement('select', 'autosubscribe', get_string('autosubscribe'), $choices);
$mform->setDefault('autosubscribe', 1);
@@ -272,27 +325,30 @@ class admin_uploaduser_form2 extends moodleform {
$mform->addElement('hidden', 'previewrows');
$mform->setType('previewrows', PARAM_INT);
$mform->addElement('hidden', 'readcount');
$mform->setType('readcount', PARAM_INT);
$mform->addElement('hidden', 'uutype');
$mform->setType('uutype', PARAM_INT);
$this->add_action_buttons(true, get_string('uploadusers', 'admin'));
$this->set_data($data);
}
/**
* Form tweaks that depend on current data.
*/
function definition_after_data() {
$mform =& $this->_form;
$columns =& $this->_customdata;
$mform = $this->_form;
$columns = $this->_customdata['columns'];
foreach ($columns as $column) {
if ($mform->elementExists($column)) {
$mform->removeElement($column);
}
}
if (!in_array('password', $columns)) {
// password resetting makes sense only if password specified in csv file
if ($mform->elementExists('uuforcepasswordchange')) {
$mform->removeElement('uuforcepasswordchange');
}
}
}
/**
@@ -300,19 +356,19 @@ class admin_uploaduser_form2 extends moodleform {
*/
function validation($data, $files) {
$errors = parent::validation($data, $files);
$columns =& $this->_customdata;
$columns = $this->_customdata['columns'];
$optype = $data['uutype'];
// detect if password column needed in file
if (!in_array('password', $columns)) {
switch ($optype) {
case UU_UPDATE:
case UU_USER_UPDATE:
if (!empty($data['uupasswordold'])) {
$errors['uupasswordold'] = get_string('missingfield', 'error', 'password');
}
break;
case UU_ADD_UPDATE:
case UU_USER_ADD_UPDATE:
if (empty($data['uupasswordnew'])) {
$errors['uupasswordnew'] = get_string('missingfield', 'error', 'password');
}
@@ -321,12 +377,12 @@ class admin_uploaduser_form2 extends moodleform {
}
break;
case UU_ADDNEW:
case UU_USER_ADDNEW:
if (empty($data['uupasswordnew'])) {
$errors['uupasswordnew'] = get_string('missingfield', 'error', 'password');
}
break;
case UU_ADDINC:
case UU_USER_ADDINC:
if (empty($data['uupasswordnew'])) {
$errors['uupasswordnew'] = get_string('missingfield', 'error', 'password');
}
@@ -335,7 +391,7 @@ class admin_uploaduser_form2 extends moodleform {
}
// look for other required data
if ($optype != UU_UPDATE) {
if ($optype != UU_USER_UPDATE) {
if (!in_array('firstname', $columns)) {
$errors['uutype'] = get_string('missingfield', 'error', 'firstname');
}
@@ -369,7 +425,7 @@ class admin_uploaduser_form2 extends moodleform {
function get_data() {
$data = parent::get_data();
if ($data !== null) {
if ($data !== null and isset($data->description)) {
$data->descriptionformat = $data->description['format'];
$data->description = $data->description['text'];
}
@@ -377,11 +433,3 @@ class admin_uploaduser_form2 extends moodleform {
return $data;
}
}
class admin_uploaduser_form3 extends moodleform {
function definition (){
global $CFG, $USER;
$mform =& $this->_form;
$this->add_action_buttons(false, get_string('uploadnewfile'));
}
}
+368
View File
@@ -0,0 +1,368 @@
<?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/>.
/**
* Bulk user registration functions
*
* @package core
* @subpackage admin
* @copyright 2004 onwards Martin Dougiamas (http://dougiamas.com)
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
defined('MOODLE_INTERNAL') || die();
define('UU_USER_ADDNEW', 0);
define('UU_USER_ADDINC', 1);
define('UU_USER_ADD_UPDATE', 2);
define('UU_USER_UPDATE', 3);
define('UU_UPDATE_NOCHANGES', 0);
define('UU_UPDATE_FILEOVERRIDE', 1);
define('UU_UPDATE_ALLOVERRIDE', 2);
define('UU_UPDATE_MISSING', 3);
define('UU_BULK_NONE', 0);
define('UU_BULK_NEW', 1);
define('UU_BULK_UPDATED', 2);
define('UU_BULK_ALL', 3);
define('UU_PWRESET_NONE', 0);
define('UU_PWRESET_WEAK', 1);
define('UU_PWRESET_ALL', 2);
/**
* Tracking of processed users.
*
* This class prints user information into a html table.
*
* @package core
* @subpackage admin
* @copyright 2007 Petr Skoda {@link http://skodak.org}
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
class uu_progress_tracker {
private $_row;
public $columns = array('status', 'line', 'id', 'username', 'firstname', 'lastname', 'email', 'password', 'auth', 'enrolments', 'deleted');
/**
* Print table header.
* @return void
*/
public function start() {
$ci = 0;
echo '<table id="uuresults" class="generaltable boxaligncenter flexible-wrap" summary="'.get_string('uploadusersresult', 'admin').'">';
echo '<tr class="heading r0">';
echo '<th class="header c'.$ci++.'" scope="col">'.get_string('status').'</th>';
echo '<th class="header c'.$ci++.'" scope="col">'.get_string('uucsvline', 'admin').'</th>';
echo '<th class="header c'.$ci++.'" scope="col">ID</th>';
echo '<th class="header c'.$ci++.'" scope="col">'.get_string('username').'</th>';
echo '<th class="header c'.$ci++.'" scope="col">'.get_string('firstname').'</th>';
echo '<th class="header c'.$ci++.'" scope="col">'.get_string('lastname').'</th>';
echo '<th class="header c'.$ci++.'" scope="col">'.get_string('email').'</th>';
echo '<th class="header c'.$ci++.'" scope="col">'.get_string('password').'</th>';
echo '<th class="header c'.$ci++.'" scope="col">'.get_string('authentication').'</th>';
echo '<th class="header c'.$ci++.'" scope="col">'.get_string('enrolments', 'enrol').'</th>';
echo '<th class="header c'.$ci++.'" scope="col">'.get_string('delete').'</th>';
echo '</tr>';
$this->_row = null;
}
/**
* Flush previous line and start a new one.
* @return void
*/
public function flush() {
if (empty($this->_row) or empty($this->_row['line']['normal'])) {
// Nothing to print - each line has to have at least number
$this->_row = array();
foreach ($this->columns as $col) {
$this->_row[$col] = array('normal'=>'', 'info'=>'', 'warning'=>'', 'error'=>'');
}
return;
}
$ci = 0;
$ri = 1;
echo '<tr class="r'.$ri.'">';
foreach ($this->_row as $key=>$field) {
foreach ($field as $type=>$content) {
if ($field[$type] !== '') {
$field[$type] = '<span class="uu'.$type.'">'.$field[$type].'</span>';
} else {
unset($field[$type]);
}
}
echo '<td class="cell c'.$ci++.'">';
if (!empty($field)) {
echo implode('<br />', $field);
} else {
echo '&nbsp;';
}
echo '</td>';
}
echo '</tr>';
foreach ($this->columns as $col) {
$this->_row[$col] = array('normal'=>'', 'info'=>'', 'warning'=>'', 'error'=>'');
}
}
/**
* Add tracking info
* @param string $col name of column
* @param string $msg message
* @param string $level 'normal', 'warning' or 'error'
* @param bool $merge true means add as new line, false means override all previous text of the same type
* @return void
*/
public function track($col, $msg, $level = 'normal', $merge = true) {
if (empty($this->_row)) {
$this->flush(); //init arrays
}
if (!in_array($col, $this->columns)) {
debugging('Incorrect column:'.$col);
return;
}
if ($merge) {
if ($this->_row[$col][$level] != '') {
$this->_row[$col][$level] .='<br />';
}
$this->_row[$col][$level] .= $msg;
} else {
$this->_row[$col][$level] = $msg;
}
}
/**
* Print the table end
* @return void
*/
public function close() {
$this->flush();
echo '</table>';
}
}
/**
* Validation callback function - verified the column line of csv file.
* Converts standard column names to lowercase.
* @param csv_import_reader $cir
* @param array $stdfields standard user fields
* @param array $profilefields custom profile fields
* @param moodle_url $returnurl return url in case of any error
* @return array list of fields
*/
function uu_validate_user_upload_columns(csv_import_reader $cir, $stdfields, $profilefields, moodle_url $returnurl) {
$columns = $cir->get_columns();
if (empty($columns)) {
$cir->close();
$cir->cleanup();
print_error('cannotreadtmpfile', 'error', $returnurl);
}
if (count($columns) < 2) {
$cir->close();
$cir->cleanup();
print_error('csvfewcolumns', 'error', $returnurl);
}
$textlib = textlib_get_instance(); // profile fields may contain unicode chars
// test columns
$processed = array();
foreach ($columns as $key=>$unused) {
$field = $columns[$key];
$lcfield = $textlib->strtolower($field);
if (in_array($field, $stdfields) or in_array($lcfield, $stdfields)) {
// standard fields are only lowercase
$newfield = $lcfield;
} else if (in_array($field, $profilefields)) {
// exact profile field name match - these are case sensitive
$newfield = $field;
} else if (in_array($lcfield, $profilefields)) {
// hack: somebody wrote uppercase in csv file, but the system knows only lowercase profile field
$newfield = $lcfield;
} else if (preg_match('/^(course|group|type|role|enrolperiod)\d+$/', $lcfield)) {
// special fields for enrolments
$newfield = $lcfield;
} else {
$cir->close();
$cir->cleanup();
print_error('invalidfieldname', 'error', $returnurl, $field);
}
if (in_array($newfield, $processed)) {
$cir->close();
$cir->cleanup();
print_error('duplicatefieldname', 'error', $returnurl, $newfield);
}
$processed[$key] = $newfield;
}
return $processed;
}
/**
* Increments username - increments trailing number or adds it if not present.
* Varifies that the new username does not exist yet
* @param string $username
* @return incremented username which does not exist yet
*/
function uu_increment_username($username) {
global $DB, $CFG;
if (!preg_match_all('/(.*?)([0-9]+)$/', $username, $matches)) {
$username = $username.'2';
} else {
$username = $matches[1][0].($matches[2][0]+1);
}
if ($DB->record_exists('user', array('username'=>$username, 'mnethostid'=>$CFG->mnet_localhost_id))) {
return uu_increment_username($username);
} else {
return $username;
}
}
/**
* Check if default field contains templates and apply them.
* @param string template - potential tempalte string
* @param object user object- we need username, firstname and lastname
* @return string field value
*/
function uu_process_template($template, $user) {
if (is_array($template)) {
// hack for for support of text editors with format
$t = $template['text'];
} else {
$t = $template;
}
if (strpos($t, '%') === false) {
return $template;
}
$username = isset($user->username) ? $user->username : '';
$firstname = isset($user->firstname) ? $user->firstname : '';
$lastname = isset($user->lastname) ? $user->lastname : '';
$callback = partial('uu_process_template_callback', $username, $firstname, $lastname);
$result = preg_replace_callback('/(?<!%)%([+-~])?(\d)*([flu])/', $callback, $t);
if (is_null($result)) {
return $template; //error during regex processing??
}
if (is_array($template)) {
$template['text'] = $result;
return $t;
} else {
return $result;
}
}
/**
* Internal callback function.
*/
function uu_process_template_callback($username, $firstname, $lastname, $block) {
$textlib = textlib_get_instance();
switch ($block[3]) {
case 'u':
$repl = $username;
break;
case 'f':
$repl = $firstname;
break;
case 'l':
$repl = $lastname;
break;
default:
return $block[0];
}
switch ($block[1]) {
case '+':
$repl = $textlib->strtoupper($repl);
break;
case '-':
$repl = $textlib->strtolower($repl);
break;
case '~':
$repl = $textlib->strtotitle($repl);
break;
}
if (!empty($block[2])) {
$repl = $textlib->substr($repl, 0 , $block[2]);
}
return $repl;
}
/**
* Returns list of auth plugins that are enabled and known to work.
*
* If ppl want to use some other auth type they have to include it
* in the CSV file next on each line.
*
* @return array type=>name
*/
function uu_supported_auths() {
// only following plugins are guaranteed to work properly
$whitelist = array('manual', 'nologin', 'none', 'email');
$plugins = get_enabled_auth_plugins();
$choices = array();
foreach ($plugins as $plugin) {
if (!in_array($plugin, $whitelist)) {
continue;
}
$choices[$plugin] = get_string('pluginname', "auth_{$plugin}");
}
return $choices;
}
/**
* Returns list of roles that are assignable in courses
* @return array
*/
function uu_allowed_roles() {
// let's cheat a bit, frontpage is guaranteed to exist and has the same list of roles ;-)
$roles = get_assignable_roles(get_context_instance(CONTEXT_COURSE, SITEID), ROLENAME_ORIGINALANDSHORT);
return array_reverse($roles, true);
}
/**
* Returns mapping of all roles using short role name as index.
* @return array
*/
function uu_allowed_roles_cache() {
$allowedroles = get_assignable_roles(get_context_instance(CONTEXT_COURSE, SITEID), ROLENAME_SHORT);
foreach ($allowedroles as $rid=>$rname) {
$rolecache[$rid] = new stdClass();
$rolecache[$rid]->id = $rid;
$rolecache[$rid]->name = $rname;
if (!is_numeric($rname)) { // only non-numeric shortnames are supported!!!
$rolecache[$rname] = new stdClass();
$rolecache[$rname]->id = $rid;
$rolecache[$rname]->name = $rname;
}
}
return $rolecache;
}
+1 -1
View File
@@ -180,7 +180,7 @@
}
foreach ($users as $key => $user) {
if (!empty($user->country)) {
if (isset($countries[$user->country])) {
$users[$key]->country = $countries[$user->country];
}
}
Executable → Regular
View File
Executable → Regular
View File
Executable → Regular
View File
Executable → Regular
View File
View File
Executable → Regular
View File
+5 -5
View File
@@ -228,9 +228,9 @@ class auth_plugin_db extends auth_plugin_base {
// find obsolete users
if (count($userlist)) {
list($notin_sql, $params) = $DB->get_in_or_equal($userlist, SQL_PARAMS_NAMED, 'u0000', false);
$params['authtype'] = $this->authtype;
$sql = "SELECT u.id, u.username, u.email, u.auth
list($notin_sql, $params) = $DB->get_in_or_equal($userlist, SQL_PARAMS_NAMED, 'u', false);
$params['authtype'] = $this->authtype;
$sql = "SELECT u.id, u.username, u.email, u.auth
FROM {user} u
WHERE u.auth=:authtype AND u.deleted=0 AND u.username $notin_sql";
} else {
@@ -238,7 +238,7 @@ class auth_plugin_db extends auth_plugin_base {
FROM {user} u
WHERE u.auth=:authtype AND u.deleted=0";
$params = array();
$params['authtype'] = $this->authtype;
$params['authtype'] = $this->authtype;
}
$remove_users = $DB->get_records_sql($sql, $params);
@@ -290,7 +290,7 @@ class auth_plugin_db extends auth_plugin_base {
// only go ahead if we actually
// have fields to update locally
if (!empty($updatekeys)) {
list($in_sql, $params) = $DB->get_in_or_equal($userlist, SQL_PARAMS_NAMED, 'u0000', true);
list($in_sql, $params) = $DB->get_in_or_equal($userlist, SQL_PARAMS_NAMED, 'u', true);
$params['authtype'] = $this->authtype;
$sql = "SELECT u.id, u.username
FROM {user} u
Executable → Regular
View File
+1 -1
View File
@@ -101,7 +101,7 @@ $string['auth_ntlmsso_enabled'] = 'Set to yes to attempt Single Sign On with the
$string['auth_ntlmsso_enabled_key'] = 'Enable';
$string['auth_ntlmsso_ie_fastpath'] = 'Set to yes to enable the NTLM SSO fast path (bypasses certain steps and only works if the client\'s browser is MS Internet Explorer).';
$string['auth_ntlmsso_ie_fastpath_key'] = 'MS IE fast path?';
$string['auth_ntlmsso_subnet'] = 'If set, it will only attempt SSO with clients in this subnet. Format: xxx.xxx.xxx.xxx/bitmask';
$string['auth_ntlmsso_subnet'] = 'If set, it will only attempt SSO with clients in this subnet. Format: xxx.xxx.xxx.xxx/bitmask. Separate multiple subnets with \',\' (comma).';
$string['auth_ntlmsso_subnet_key'] = 'Subnet';
$string['auth_ntlmsso_type_key'] = 'Authentication type';
$string['auth_ntlmsso_type'] = 'The authentication method configured in the web server to authenticate the users (if in doubt, choose NTLM)';
+49
View File
@@ -0,0 +1,49 @@
<?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/>.
/**
* Manual authentication plugin upgrade code
*
* @package auth
* @subpackage manual
* @copyright 2011 Petr Skoda (http://skodak.org)
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
/**
* @param int $oldversion the version we are upgrading from
* @return bool result
*/
function xmldb_auth_manual_upgrade($oldversion) {
global $CFG, $DB, $OUTPUT;
if ($oldversion < 2011022700) {
// force creation of missing passwords
$createpassword = hash_internal_user_password('');
$rs = $DB->get_recordset('user', array('password'=>$createpassword, 'auth'=>'manual'));
foreach ($rs as $user) {
if (validate_email($user->email)) {
$DB->set_field('user', 'password', 'to be created', array('id'=>$user->id));
unset_user_preference('auth_forcepasswordchange', $user);
set_user_preference('create_password', 1, $user);
}
}
$rs->close();
upgrade_plugin_savepoint(true, 2011022700, 'auth', 'manual');
}
return true;
}
+29
View File
@@ -0,0 +1,29 @@
<?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/>.
/**
* Manual authentication plugin version information
*
* @package auth
* @subpackage manual
* @copyright 2011 Petr Skoda (http://skodak.org)
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
defined('MOODLE_INTERNAL') || die();
$plugin->version = 2011022700;
$plugin->component = 'auth_manual';
Executable → Regular
View File
Executable → Regular
View File
Executable → Regular
View File
Executable → Regular
View File
Executable → Regular
View File
Executable → Regular
View File
Executable → Regular
View File
View File
Executable → Regular
View File
Executable → Regular
View File
View File
Executable → Regular
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File

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