75 Commits

Author SHA1 Message Date
Eloy Lafuente (stronk7)
1877b7551e Merge branch 'MDL-50894_master' of https://github.com/gedion/moodle 2015-08-11 14:18:34 +02:00
sam marshall
362616ae6c MDL-51007 Availability: Unit test fails with extra plugins 2015-08-05 14:27:40 +01:00
Gedion Woldeselassie
c28eb52862 MDL-50894 lib/conditionlib: Occasional cron error
Inhibit division by zero error warnings when rawgrademax and rawgrademin are
equal. The change does not affect existing functional behavior.
2015-07-24 11:36:26 -05:00
Dan Poltawski
6a51993e9f MDL-49434 availability: more bad whitespace 2015-07-22 23:58:12 +01:00
Dan Poltawski
e870b10343 MDL-49434 availability: fix trailing whitespace 2015-07-22 23:49:52 +01:00
Marina Glancy
57ca231ad9 MDL-49434 availability: unit test adjustments 2015-07-22 12:49:22 +08:00
sam marshall
c7b738546c MDL-49434 availability: Use renderables for multiple messages
Co-Authored-By: Andrew Nicols <andrew@nicols.co.uk>
2015-07-15 11:43:01 +01:00
David Monllao
729a6c5617 MDL-50177 completion: Also accepting cm integer strings 2015-05-12 12:19:43 +08:00
Eloy Lafuente (stronk7)
26ea380d24 MDL-50102 versions: bump all versions and requires near release
version = planned 2015051100 release version
requires= current 2015050500 rc1 version

Note: On purpose, the course format social wrong version (2015102100)
has been kept unmodified. Looking forward a solution right now.
2015-05-05 17:43:19 +02:00
Viduranga Wijesooriya
21e6aabce9 MDL-49477 availability_grade-form: checkbox disable problem fixed
Signed-off-by: Viduranga Wijesooriya <vpowerrc@gmail.com>
2015-04-22 17:33:54 +08:00
Rajesh Taneja
0fe86bbdbb MDL-49799 behat: replaced asd.com with example.com
asd.com is a valid domain, we should use reserved domain names for testing
2015-04-20 11:21:20 +08:00
Simey Lameze
06d631f1c5 MDL-49412 availability: Fix behat failures
Part of MDL-45774
2015-04-10 17:18:22 +08:00
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
Rajesh Taneja
bed97c39eb MDL-49513 behat: Set admin config using php api
Added a new set to set config using set_config() api
to make steps faster and more efficient
2015-04-01 14:25:23 +08:00
Tim Price
e1de40f7f7 MDL-18177 backup: adding PHPdocs blocks 2015-02-20 11:45:23 +11:00
Matt Sammarco
5ef6f97f47 MDL-18177 availability: Excluding group members availability info
If setting was not enabled when backing up, exclude the availability
information of group members.
2015-02-20 11:45:22 +11:00
John Okely
e7bcd2764a MDL-44520 behat: Change behat features to use new section selectors 2015-02-06 10:34:54 +08:00
Eloy Lafuente (stronk7)
8181ab5865 Merge branch 'MDL-48620-master' of git://github.com/andrewnicols/moodle
Conflicts:
	lib/editor/atto/plugins/undo/yui/build/moodle-atto_undo-button/moodle-atto_undo-button-min.js
2015-01-28 01:02:54 +01:00
Eloy Lafuente (stronk7)
7615deba22 Merge branch 'MDL-48660-master' of https://github.com/sammarshallou/moodle 2015-01-27 21:11:27 +01:00
sam marshall
6b40e5b2ec MDL-48660 Availability: filter_user_list() should respect 'view hidden'
Updated filter_user_list and get_user_list_sql to account for
the viewhiddenactivities and viewhiddensections capabilities.
2015-01-27 10:59:05 +00:00
Andrew Nicols
557f44d970 MDL-48620 JavaScript: Updated shifted files to comply with coding style 2015-01-23 14:51:24 +08:00
Eric Merrill
4b4e41342a MDL-35765 availability: Use category total full names 2015-01-20 15:37:13 -05:00
PJ King
c8c746c440 MDL-46671 availability: DEBUG when course_module does not exist.
There was a fatal error when calendar event linked to non-extant activities.

Now, instead of throwing an exception when a course_module does not exist, is_user_visible() will print a debug statement.
2015-01-02 10:34:16 -05:00
Dan Poltawski
3d891e3263 Merge branch 'MDL-47628-master' of https://github.com/sammarshallou/moodle
Conflicts:
	availability/yui/build/moodle-core_availability-form/moodle-core_availability-form-min.js
2014-12-04 12:04:07 +00:00
Andrew Nicols
64e7aa4de1 MDL-28286 JavaScript: Convert all uses of M.str to M.util.get_string 2014-12-01 08:32:04 +13:00
sam marshall
a4c318325c MDL-47628 Availability: Restrict by selected grouping button 2014-11-28 15:55:41 +00:00
Dan Poltawski
5a6c9f1cfb Merge branch 'MDL-48021' of git://github.com/stronk7/moodle
Conflicts:
	admin/tool/monitor/version.php
	mod/lesson/version.php
2014-11-05 12:11:16 +00:00
Eloy Lafuente (stronk7)
de881693f7 MDL-48021 bump: Bump all versions to planned release
This bumps all versions to planned 2.8 release
(2014111000) version and all the dependencies to
current 2.8rc1 (2014110400)
2014-11-04 17:52:35 +01:00
Marina Glancy
41107173e4 MDL-46262 availability: validation of fields without value
Thanks to Tomasz Pawlik | CKO USl for the patch
2014-11-01 16:58:14 +08:00
Tim Hunt
a3d5068083 MDL-47726 availability: fix tests when there is a text custom field
This unit tests assumed that on a fresh install, there were no custom
user-profile fields. Given some third-party plugins, that assumption is
false.
2014-10-20 16:15:34 +01:00
Dan Poltawski
01c3b4c50b Merge branch 'MDL-47564-master' of https://github.com/sammarshallou/moodle 2014-10-16 11:50:38 +01:00
Dan Poltawski
0993f24df0 Merge branch 'MDL-47509' of https://github.com/stronk7/moodle 2014-10-09 07:13:18 +01:00
Eloy Lafuente (stronk7)
278432258f MDL-47509 Profile restriction: More oracle/text fixes
1) Get rid of "uid" that is a reserved word.
2) Add cross-db support for text columns in the get_condition_sql() method
   by adding a new, defaulting to false for BC param and intensively using
   the sql_compare_text() helper to build the correct sql fragments.
2014-10-08 01:45:29 +02:00
sam marshall
9634c60e7b MDL-47509 Profile restriction: Broken Oracle causes problem 2014-10-08 01:45:28 +02:00
Sam Hemelryk
28fffe1f9b Merge branch 'MDL-47481-master' of https://github.com/sammarshallou/moodle 2014-10-08 11:51:32 +13:00
sam marshall
c0d92241f1 MDL-47564 Availability: incorrect use of defined('PHP_UNIT') 2014-10-07 14:47:29 +01:00
sam marshall
80ee9add2d MDL-47481 Availability: Profile condition error if no users 2014-10-02 10:39:20 +01:00
Dan Poltawski
2633f23627 Merge branch 'MDL-47322-master' of https://github.com/sammarshallou/moodle 2014-09-29 11:12:29 +01:00
sam marshall
38584d1167 MDL-47380 Availability: Editing interface broken in IE8 2014-09-26 15:47:00 +01:00
sam marshall
06c0603825 MDL-47322 Availability: empty availability should be saved as null
As part of the unit test modifications for this change, I added the get_json
function to the availability conditions that didn't have it. (This is a function
for use in unit tests.)
2014-09-26 15:42:37 +01:00
sam marshall
5176504d3f MDL-46991 Availability: Conditional dates not updated on restore 2014-09-18 16:37:53 +01:00
Adam Olley
0151ca2b91 MDL-47208 core_availability: Return false when cm isnt in modinfo list
If a cm isn't in modinfo's cm list, then the user shouldn't be able to see that cm.
This fixes an issue where hidden activities would cause users to be unable to use moodle.
2014-09-12 09:14:56 +09:30
sam marshall
28f31f7d2d MDL-44725 Availability: Unit test for tree::get_user_list_sql 2014-09-04 10:25:01 +08:00
Marina Glancy
3b4db5bdf5 MDL-44725 dml: added sql_intersect() 2014-09-03 13:33:58 +08:00
sam marshall
1a7049af22 MDL-44725 Availability: Add SQL feature for user lists (11)
The previous API included a facility to filter a list of users
to include only those who are allowed to access an activity, i.e.
only people who belong to the required groups etc.

This change adds a new API function to return SQL that obtains
this list of users, so that it can be combined with other
queries.
2014-09-02 13:03:29 +01:00
sam marshall
f9103882dc MDL-44725 Availability: Add utility API to make unit testing easier (7)
Previously there was no way in PHP to create the JSON values used for
availability, except by manually hard-coding them (the main code to
do this normally is in JavaScript).

This makes unit tests hard to read, so I have implemented static
functions tree::get_root_json and tree::get_nested_json which allow
for easier-to-read unit tests.
2014-09-02 13:03:19 +01:00
sam marshall
3d962d49cb MDL-44725 Availability: Replace groupmembersonly - core_availability (2)
Remove groupmembersonly usage in the core_availability API, and change
the update code (used in backup) so that it considers groupmembersonly
when restoring old backups.
2014-09-02 13:03:09 +01:00
Nadav Kavalerchik
51f2398ce7 MDL-46450 availability/info: Add links to module names inside restrict access availabilityinfo box 2014-08-24 23:39:20 +03:00
sam marshall
61f5302b85 MDL-46414 Conditional availability: Dropdowns not set correctly when editing in IE
In IE, you cannot set the value of a dropdown to an integer; it has to be a string.
This caused a bug in several parts of the conditional availability editing
interface.
2014-07-29 18:33:03 +01:00
Rajesh Taneja
a9e2d4c03a MDL-45698 behat: Added extra setting, to avoid timout issue 2014-05-29 09:44:03 +08:00