350 Commits

Author SHA1 Message Date
Petr Skoda
d6e7a63d9a MDL-49684 timezones: rewrite timezone support
This patch replaces all homegrown timezone
stuff with standard PHP date/time code.

The main change is the introduction of core_date
class that returns normalised user and server
timezones. From now on nobody should be using
$CFG->timezone or $user->timezone directly!

Other new features and fixes:
* admins are prompted for timezone during install
* editing of other users is finally fixed
* timezones are displayed in user profile
* new $this->setTimezone() in phpunit
* time locale is now automatically reset in phpunit
* timezone is now automatically reset in phpunit
* phpunit has Australia/Perth as default timezone
2015-04-06 13:53:51 +12:00
Dave Cooper
3004a92332 MDL-49534 libraries: Removed pear/HTTP/WebDav 2015-04-02 11:05:42 +02:00
Andrew Nicols
b7067f065e MDL-49627 core: Improve thumbnail generation
We now abstract the actual file generation to a new function.
We are then able to call this function from the other image generation
sources. This allows us to generate thumbnails in a more efficient manner.

* Stored files stay as stored files and are not temporarily re-written to
  disk;
* Strings containing an image remain as a variable and are not temporarily
  written to disk; and
* Arbitrary files are not captured to string.
2015-04-01 11:05:19 +08:00
Andrew Nicols
70be2642fc MDL-44874 core: Add per-request directory functions
This adds functionality to create individual request directories which can
be only be used for the current request. They are removed by a shutdown
handler.
2015-03-31 13:58:44 +08:00
Eloy Lafuente (stronk7)
536cf8c298 Merge branch 'MDL-49361-master-stringman' of git://github.com/mudrd8mz/moodle 2015-03-17 12:00:29 +01:00
Damyon Wiese
9bdcf57951 MDL-49152 output: Templates for renderers (JS and PHP)
Mustache support for rendering templates from either php or js.
2015-03-14 22:48:40 +08:00
David Mudrák
9bcb0ba894 MDL-49361 lang: Add support for $CFG->customstringmanager 2015-03-13 10:45:10 +01:00
David Monllao
79565fa55a MDL-49298 admin: Adding upgrade.txt info about enabletgzbackups 2015-03-11 08:41:22 +08:00
Dan Poltawski
9fe26fb874 MDL-48595 upgrade.txt: just add some rationale explaining change 2015-03-10 10:00:40 +00:00
David Monllao
45a1a16bfc MDL-48595 log: Replacing current interfaces
Deprecating sql_internal_reader and sql_select_reader in
favour of the new interfaces including get_events_select_iterator.
2015-03-09 08:25:15 +08:00
Eloy Lafuente (stronk7)
8d9bdd28e0 MDL-49087 mdeploy: now relying on config.php documented 2015-03-03 02:45:44 +01:00
Damyon Wiese
adeb96d28f MDL-49046 javascript: Add support for AMD modules and jquery.
Grunt is the build tool.
2015-02-23 16:23:10 +08:00
Jetha Chan
3451a51cdf MDL-37477 output: Add support for table captions
Conflicts:
	lib/upgrade.txt
	theme/bootstrapbase/style/moodle.css
2015-02-10 16:15:49 +08:00
Juan Leyva
7310dcff41 MDL-30239 webservices: Return additional fields in ws get_files 2015-02-05 14:20:24 +01:00
Dan Poltawski
80f8372926 Revert "Merge branch 'MDL-37477-master' of git://github.com/jethac/moodle"
This reverts commit f13e8ad04168574574d5be2995502d849109d3f9, reversing
changes made to c6bcbad07a7fd437991ee7a2a1a98973949fac43.
2015-02-05 08:07:29 +00:00
Dan Poltawski
cf02542d93 MDL-44071 upgrade.txt: improve notice 2015-02-03 12:20:39 +00:00
Dan Poltawski
1ee0c927b2 Merge branch 'MDL-44071-master' of git://github.com/zbdd/moodle 2015-02-03 12:16:16 +00:00
Jetha Chan
49faeef6bb MDL-37477 output: Add support for table captions 2015-02-03 13:38:24 +08:00
James Henestofel
70f379639a MDL-44071 webservices: Sorting courses post deletion.
Additional warnings added if particular steps fail.

Signed-off-by: Zachary Durber <zdurber@gmail.com>
2015-02-02 16:37:12 +08:00
Neill Magill
8072628a67 MDL-48177 core: Plugin environment checks with no version of Moodle
The environment.xml files in plugins force you to define the versions of Moodle that the checks should be carried out against.
For community plugins the environment requirements of the plugin seem unlikely to be dependant on the version of Moodle.

This patch will allow the environment.xml files to use a new <PLUGIN> tag in place of the <MOODLE version="> tag.

This solution has the following properties:

* The Environment file will not break versions of Moodle that do not support the PLUGIN syntax.
* Specific versioned MOODLE tags can still be defined for versions of Moodle that do not have this patch.
* If both MOODLE and PLUGIN tags exist the PLUGIN tag will be used in preference.
* The PLUGIN tag will not function in the main Moodle environment.xml file.
* The PLUGIN tag has a mandatory name attribute that must match the frankenstyle name of the plugin being tested.
2015-01-27 13:08:47 +01:00
Eloy Lafuente (stronk7)
2e02eab234 Merge branch 'MDL-43242-master' of git://github.com/andrewnicols/moodle
Conflicts:
	lib/upgrade.txt
2015-01-08 01:30:53 +01:00
Andrew Nicols
7d0d3b369d MDL-43242 ajax: Final deprecation of core JS functions 2015-01-08 08:28:37 +08:00
David Monllao
fcec67db13 Merge branch 'MDL-48697-master' of git://github.com/ankitagarwal/moodle 2015-01-07 09:05:51 +08:00
Ankit Agarwal
9802bd616e MDL-48697 libraries: Use proper path for core_completion 2014-12-23 13:29:58 +05:30
Dan Poltawski
c67c00a6fe Merge branch 'MDL-42616-master' of https://github.com/sammarshallou/moodle 2014-12-22 12:13:31 +00:00
sam marshall
91fed57a4e MDL-42616 filelib: Use config value for custom MIME types (1/2)
Uses a new optional config variable to define custom MIME types
in JSON format. Includes new API for accessing and modifying
this data.
2014-12-19 14:48:59 +00:00
Frederic Massart
c9bd4e41eb MDL-46122 libraries: Final deprecation of file lib/pluginlib.php 2014-12-17 09:37:11 +08:00
Andrew Nicols
556e3a9e8a MDL-48197 testing: Always set up a mail sink for mail redirection
Rather than setting noemailever in the bootstrap, this sets up a default
phpmailer message sink which will catch all messages.

Tests which require the phpmailer sink will continue to work as before
without change, though the noemailever config setting no longer needs to
be altered.

For tests wanting to test with noemailever set with the previous behaviour,
they will need to load the message sink and then close it.
2014-11-19 09:09:49 +08:00
Sam Hemelryk
a74d4743e1 MDL-33606 event: moved upgrade notice 2014-11-19 09:38:55 +13:00
David Monllao
d931574ff9 MDL-33606 course: Adding section info to course_viewed log
Also changing references to section id to
section number, that it is what it really is.
2014-11-17 15:18:18 +08:00
Damyon Wiese
53f26095c6 Merge branch 'MDL-46527-master' of git://github.com/jleyva/moodle 2014-10-22 10:45:57 +08:00
Juan Leyva
a7888487f0 MDL-46527 grades: grade_get_grades external function rewritten 2014-10-21 12:10:01 +02:00
Damyon Wiese
47d6e6a7d3 MDL-47503 Grades: Completely remove aggregationsubcats
This setting is not compatible with combinations of aggregation methods
and the ways in which it does and does not work are not documented. It
was voted to remove it completely by the gradebook workshop, so I have
completely removed it and added a warning for all affected courses + restored
backups.
2014-10-20 12:03:18 +08:00
Ankit Agarwal
b9ba26b222 MDL-45758 tool_monitor: Update navigation to add callbacks
User settings node now checks for callbacks in various admin tools
2014-10-15 07:41:06 +05:30
Mark Nelson
27b6839fe2 MDL-45758 core: edited get_formatted_help_string
Edited the api to accept string parameters

Original issue - MDL-47152
2014-10-15 07:41:05 +05:30
Marina Glancy
885b889dc0 MDL-47297 libraries: upgrade note about Google API update 2014-10-08 19:22:14 +08:00
Dan Poltawski
08abbd61c2 Merge branch 'wip-MDL-35618-master' of git://github.com/marinaglancy/moodle
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-10-07 09:24:39 +01:00
Damyon Wiese
4a813f3959 Merge branch 'wip-MDL-36014-master' of git://github.com/marinaglancy/moodle
Conflicts:
	lib/db/install.xml
	lib/db/upgrade.php
	version.php
2014-10-07 12:34:34 +08:00
Dan Poltawski
f5bacd6539 Merge branch 'wip-MDL-46576-master' of git://github.com/abgreeve/moodle
Conflicts:
	lib/upgrade.txt
    lib/db/upgrade.php
	version.php
2014-10-06 18:06:13 +01:00
Dan Poltawski
16078807f8 MDL-47221 task: allow 'random' time definitions
When working against external services it can be advantageous to not
have automated tasks all hit the service at the exact same time from
many different installations.

This change allows the use of 'R' in hour/minute fields of the scheduled
task definition so a task will be installed with a 'random' hour/minute
value for these sort of occasions.

Note that the task will be installed in the database with a defined
time, this simply randomises the time chosen when loading from the
definiton.
2014-10-05 14:27:04 +01:00
Marina Glancy
58b5b04d4b MDL-35618 enrol_cohort: remove enrolment button 2014-10-03 18:28:48 +08:00
Marina Glancy
80f98467f8 MDL-36014 cohorts: Allow teachers to view cohorts
Added property 'visible' for cohorts. Unsetting it hides the cohort from users in the course.

AMOS BEGIN
 CPY [visible,core_moodle],[visible,core_cohort]
AMOS END
2014-10-03 18:26:34 +08:00
Marina Glancy
b79bf7a234 MDL-47146 core_grades: Removed unused setup columns
Part of: MDL-46576
2014-10-03 13:54:39 +08:00
sam marshall
061e6b2864 MDL-44725 Availability: Replace groupmembersonly - upgrade, core (1)
* Upgrades existing data so that the groupmembersonly option is
  replaced with equivalent data for the new availability API.
* Removes the database field and admin setting used for
  groupmembersonly.
* Changes core modinfo library to remove/deprecate groupmembersonly
  data and functions.
* Changes other core library files to remove groupmembersonly
  references.

Includes deprecation of several functions, listed in lib/upgrade.txt.
2014-09-02 13:03:07 +01:00
Damyon Wiese
52ed065131 Merge branch 'MDL-46706-master' of https://github.com/sammarshallou/moodle
Conflicts:
	lib/tests/modinfolib_test.php
2014-08-19 17:13:05 +08:00
sam marshall
d25c41fbc5 MDL-46706 Library: API to get cm_info more easily
Creates two new functions that make it easier to get cm_info
objects (both in modinfolib.php):

get_course_and_cm($cmid) - intended for use e.g. in modules;
efficiently loads $course and $cm (normally saves 1 query).

cm_info::from_mixed($cm) - for use in back-end API where we
are not sure whether a $cm is a real cm_info or a stdClass.
2014-08-15 18:24:11 +01:00
Damyon Wiese
d6caf63789 MDL-35984 Grades: Fix deprecation of grade_category::aggregate_values 2014-08-11 15:53:47 +08:00
Eloy Lafuente (stronk7)
83988eb1f7 MDL-46290 Completion: document the deprecation 2014-07-16 01:06:23 +02:00
Sam Hemelryk
ebdcb2924c MDL-41663 output: fix for methods with _renderable suffix 2014-07-02 14:59:31 +12:00
Rajesh Taneja
2b55cb1b18 MDL-45641 event: Option to trigger user event manually
On some pages full user data is not stored before user_created/
user_updated event is triggred. So giving option to trigger that
manually, so it can be triggred after all data is saved
2014-06-27 15:44:56 +08:00