Compare commits

...

901 Commits

Author SHA1 Message Date
Eloy Lafuente (stronk7) ef0ee34df0 Moodle release 2.6.2 2014-03-07 18:51:51 +01:00
Eloy Lafuente (stronk7) 7330bdebff weekly release 2.6.1+ 2014-03-06 22:17:22 +01:00
Eloy Lafuente (stronk7) 3fb5bd96e8 Merge branch 'install_26_STABLE' of git://git.moodle.org/moodle-install into MOODLE_26_STABLE 2014-03-06 22:17:16 +01:00
Yuliya Bozhko 28c8ac2c4a MDL-44140 badges: Prevent non-owners to change visibility of issued badges
Signed-off-by: Yuliya Bozhko <yuliya.bozhko@totaralms.com>
2014-03-06 14:37:03 +08:00
Damyon Wiese b9d8d54be2 Merge branch 'wip-MDL-44403-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2014-03-06 09:22:13 +08:00
Dan Poltawski e5636247a1 Revert "MDL-43852 Filters Fixed naked-OR conditions."
While the patch worked as intended, we discovered some other concerns
about use of this setting in testing.

This reverts commit edf55404ff.
2014-03-06 09:05:27 +08:00
Eloy Lafuente (stronk7) 728ece64e4 Merge branch 'MDL-44425-en_fix_26' of git://github.com/mudrd8mz/moodle into MOODLE_26_STABLE 2014-03-06 00:36:27 +01:00
Helen Foster eecdbbf315 MDL-44425 Merge English strings from the en_fix language pack 2014-03-05 13:35:06 +01:00
Damyon Wiese 6b1e9b0cd4 Merge branch 'MDL-43635-m26' of https://github.com/brentboghosian/moodle2 into MOODLE_26_STABLE 2014-03-05 14:51:18 +08:00
Dan Poltawski 864ea90d6d Merge branch 'wip-MDL-44287-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2014-03-05 14:18:22 +08:00
Dan Poltawski 7442e32e87 Merge branch 'MDL-43930-26-fix1' of git://github.com/damyon/moodle into MOODLE_26_STABLE 2014-03-05 14:13:35 +08:00
Damyon Wiese abfc156859 Merge branch 'MDL-44370-26' of git://github.com/ankitagarwal/moodle into MOODLE_26_STABLE 2014-03-05 14:00:57 +08:00
Yuliya Bozhko 857f80ef77 MDL-41585 badges: Add a note that badge recipient is a deleted user
Signed-off-by: Yuliya Bozhko <yuliya.bozhko@totaralms.com>
2014-03-05 13:18:21 +08:00
Damyon Wiese 3efe930987 MDL-43930 Assign: Fix unit tests.
The tests were expecting exact log data to match, I changed the data
but missed updating the test.
2014-03-05 12:51:15 +08:00
Dan Poltawski a77f82dacf Merge branch 'MDL-41248_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-03-05 12:39:56 +08:00
Dan Poltawski ed9e1428d1 Merge branch 'MDL-43930-26' of git://github.com/damyon/moodle into MOODLE_26_STABLE 2014-03-05 11:22:37 +08:00
Dan Poltawski 730440dcf4 Merge branch 'MDL-44065-m26' of https://github.com/sammarshallou/moodle into MOODLE_26_STABLE 2014-03-05 10:52:50 +08:00
Damyon Wiese c6465439d0 Merge branch 'wip-MDL-44074-M26_4' of git://github.com/gjb2048/moodle into MOODLE_26_STABLE 2014-03-05 09:58:54 +08:00
AMOS bot 25488a1120 Automatically generated installer lang files 2014-03-05 00:54:43 +00:00
Dan Poltawski 602a3bd3de Merge branch 'wip-MDL-44258-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2014-03-04 17:50:07 +08:00
Ankit Agarwal d57ce0312a MDL-44370 calendar: Add support for restoring calendar log rules 2014-03-04 16:13:59 +08:00
Ankit Agarwal bdff56f737 MDL-44370 calendar: Fix calendar url in reports 2014-03-04 16:13:59 +08:00
Dan Poltawski 5b2f2af6cd Merge branch 'MDL-44272-26' of git://github.com/ankitagarwal/moodle into MOODLE_26_STABLE 2014-03-04 16:00:01 +08:00
Dan Poltawski 6a37f9898e Merge branch 'MDL-44278_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-03-04 15:43:26 +08:00
Marina Glancy 76f9954066 MDL-44403 events: bug fix in legacy event data for unknown_service_api_called 2014-03-04 15:26:17 +08:00
Marina Glancy ce3b9d2f59 MDL-44403 events: added public methods to get eventdata 2014-03-04 15:26:14 +08:00
Frederic Massart f96b8a1c67 MDL-43468 mod_assign: Webservice parameters were not safely cleaned 2014-03-04 14:49:28 +08:00
Dan Poltawski 5d4abb97b2 Merge branch 'MDL-44436-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-03-04 14:41:32 +08:00
Frederic Massart 7ffe38cebf MDL-44436 context: Context IDs are forced to be int
The method context::insert_context_record() sets the context::$id to
an int, while when we create an instance, the $id is often read from
a DB $record object, and is a string. The ID should always be an int.
2014-03-04 14:25:37 +08:00
Damyon Wiese 0fc189a4b4 Merge branch 'MDL-43738_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-03-04 13:28:18 +08:00
Dan Poltawski 013de6d5d4 Merge branch 'm26_MDL-43852_SWF_Not_Embedded_By_Mediaplugin_Filter' of https://github.com/scara/moodle into MOODLE_26_STABLE 2014-03-04 12:56:13 +08:00
Dan Poltawski 41a19bffee MDL-43146 enrol_imsenterprise: missing sesskey protection 2014-03-04 12:26:02 +08:00
Frederic Massart ee8f17db89 MDL-29409 repository_alfresco: Drop support for URL/link
The current solution has two major issues. Firstly, it is using the
session key in the file URL, allowing anyone with the link to steal
the identify of the poster. Secondly, the links are not presistent
and become broken as soon as the server is restarted. Let's not
support this any more until a proper solution is found in MDL-26454.
2014-03-04 11:34:58 +08:00
Brent Boghosian e7fa4cde7b MDL-43635: Further support custom contexts: reading from config DB table and reset method for after plugin install
Add PHPUnit test for custom context changes
2014-03-03 12:03:09 -05:00
Dan Poltawski 51214dd2d1 Merge branch 'MDL-44377_26' of https://github.com/stronk7/moodle into MOODLE_26_STABLE 2014-03-03 15:15:20 +08:00
Marina Glancy e6499fb8a4 MDL-39990 wiki: more detailed validation of view/edit access 2014-03-03 14:45:40 +08:00
Dan Poltawski d5c7462a6a Merge branch 'wip-MDL-44362-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2014-03-03 13:34:35 +08:00
Andrew Davis 4d4867503c MDL-44082 mod_chat: added a security check for users already in the chat activity 2014-03-03 12:16:48 +08:00
Tomasz Muras 71037bf26c MDL-43656 mod_feedback: availablity date logic incorrect 2014-03-03 11:24:23 +08:00
Maria Torres db4e2c4cd4 MDL-43916 - Email addresses incorrectly displayed
When capabilities and settings do not allow it.
2014-03-03 10:37:22 +08:00
Dan Poltawski 6b25f55ec9 Merge branch 'w06_MDL-43344_m26_flow' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2014-03-03 10:07:15 +08:00
Gareth J Barnard 0bd4dca7be MDL-44074 theme_bootstrapbase: No 768px-979px & 1200px+ empty blk span calcs. 2014-03-01 09:18:34 +00:00
AMOS bot 9b1cc0bb86 Automatically generated installer lang files 2014-03-01 00:56:04 +00:00
Gordon Bateson edf55404ff MDL-43852 Filters Fixed naked-OR conditions. 2014-02-28 23:56:35 +01:00
Eloy Lafuente (stronk7) 36f74f56d8 MDL-44377 dml: enforce non-empty prefix for sqlsrv
Only MySQL is allowed to run Moodle instances without
(with an empty) database prefix. The rationale is that
"user" is a reserved word in every RDBMS but MySQL.

Before this patch, installation was breaking badly, when
the "user" CREATE TABLE statement was issued. With this
patch the error is shown earlier (on connection) preventing
any advance/use of the database.

This check is present in all the drivers, just sqlsrv was missing it.
2014-02-28 10:12:27 +01:00
Marina Glancy 51294319af MDL-44362 recentactivity: fix regressions from MDL-44055 2014-02-28 16:33:54 +08:00
Marina Glancy c89fa51c0e MDL-44258 Behat test for workshop, automate MDLQA-99 2014-02-28 16:33:32 +08:00
Marina Glancy e7198624aa MDL-44287 glossary: fixing warnings when importing as new module 2014-02-28 16:33:21 +08:00
Marina Glancy 971b916b44 MDL-44287 glossary: do not output before redirecting 2014-02-28 16:33:21 +08:00
Tim Hunt 65a90d2d9b MDL-44278 Quiz time overrides: use the same step everywhere.
On the main form, you could select to the nearest minute. On
the override form you could only select to the nearest 5 minutes.
2014-02-28 09:00:54 +01:00
Tim Hunt 379a3fcee3 MDL-41248 completion: fix non-translatable text.
There were two hard-coded strings. Thanks to Guido Hornig for the suggested fix.
2014-02-28 08:10:26 +01:00
Damyon Wiese ed0a48b2c1 weekly release 2.6.1+ 2014-02-28 10:02:43 +08:00
Damyon Wiese a97718eaed Merge branch 'install_26_STABLE' of git://git.moodle.org/moodle-install into MOODLE_26_STABLE 2014-02-28 10:02:41 +08:00
David Monllao 5ee96bbcf1 MDL-43738 behat: Refactoring the field type guesser
The previous behaviour delegates the responsability
of overwriting the 3 public methods to the child
classes, now the field type or moodleform field is
guessed earlier in the execution flow.

Other changes introduced here:
- Fix wrong moodleform detection when there is a form
  in the page but the field we are dealing with is
  not inside it.
- Some coding style changes
2014-02-27 18:47:03 +08:00
David Monllao 158eb2af96 MDL-43738 behat: Backporting new 2.7 methods to 2.6
We encourage backporting new feature files, adding
here also these Moodle 2.7 new step definitions so
future features will be easier to backport as we
would be able to directly cherry-pick them.
2014-02-27 18:06:31 +08:00
David Monllao 42e5f933b6 MDL-43738 behat: New step to adapt to radio buttons behaviour
Now we interact with radio fields through it's value
or text.
2014-02-27 18:06:31 +08:00
David Monllao 08066a2ab2 MDL-43738 behat: Normalization and major refactoring of getters and setters
Every single step that sets or gets a value from a field
has been updated to follow the same behaviour both when
using it through a single step or through generic steps
like "I fill the moodle form with:", to resume all the
changes:
- Created a behat_form_group to re-guess the field type
  and act appropriately setting and getting it's value
- Normalize all getters and setters to use behat_form_field
  children
- Complete behat_form_checkbox to trigger the appropiate JS
  event needed to perform some JS scripts that are listening
- Refactor MDL-43713 multi-select changes and remove
  the two new steps introduced there as that behaviour can
  be managed from the generic getter
2014-02-27 18:06:29 +08:00
David Monllao 8ee37654e5 MDL-43738 behat: Functional tests for fields management
We are cheating with this .feature file as this
is not a behaviour and we are just testing the
framework, but in this case I think that everybody
will agree on the need of doing it, as every browser
behaves differently and minor changes in the getters
and setters can easily end up breaking the behaviours.

All credit goes to Eloy Lafuente (stronk7).
2014-02-27 18:05:51 +08:00
Eloy Lafuente (stronk7) 5fbf4638ab MDL-43713 behat: improve multi-select support
This patch implements:

1) Normalization of options. Before the patch options
in a select were being returned as "op1 op2 op3" by selenium
and "op1 op2 op3" by goutte. With the patch, those lists
are always returned like "op1, op2, op3". If real commas are
needed when handling multiple selects they should
be escaped with backslash in feature files.

2) Support for selecting multiple options. Before the patch
only one option was selected and a new selection was cleaning the
previous one. With the patch it's possible to pass "op1, op2" in
these steps:
  - I fill the moodle form with (table)
  - I select "OPTION_STRING" from "SELECT_STRING"

3) Ability to match multiple options in this steps. Before the
patch matching of multiple was really random, now every every
passed option ("opt1, opt2") is individually verified. It applies
to these 2 steps:
  - the "ELEMENT" select box should contain "OPTIONS"
  - the "ELEMENT" select box should not contain "OPTIONS"

4) Two new steps able to verify if a form have some options selected or no:
  - the "ELEMENT" select box should contain "OPTIONS" selected
  - the "ELEMENT" select box should contain "OPTIONS" not selected

5) Change get_value from xpath search to Mink's getValue() that is immediate
(does not need form submission) and works for all browsers but Safari, that
fails because of the extra ->click() issued.

Note all the changes 1-4 only affect to multi-select fields. Single
selects should continue working 100% the same.

The change 5) causes Safari to fail. The problem has been traced down to
the extra ->click() present there. Anyway there are not test cases
requiring that "immediate" evaluation right now. Only the special feature
file attached verifies it.
2014-02-27 18:05:51 +08:00
David Monllao c7db26dab9 MDL-44286 behat: Fixing JS code error
PhantomJS console shows a JS error regarding
an undefined Syn var; as explained by Andrew
Nicols this is caused by Syn supported features
checker, the change in moodle-behat-extension
solves this problem.
2014-02-27 11:54:54 +08:00
Damyon Wiese 0f73fa60b9 MDL-43723 Blocks drag and drop: Javascript cleanup
Declare the selector instead of repeating it several times.
2014-02-25 17:05:45 +08:00
Damyon Wiese b174b543d8 Merge branch 'MDL-43723-26' of git://github.com/mouneyrac/moodle into MOODLE_26_STABLE
Conflicts:
	lib/yui/build/moodle-core-blocks/moodle-core-blocks-min.js
2014-02-25 16:44:48 +08:00
Dan Poltawski 233f8b265a Merge branch 'MDL-43882_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-02-25 15:34:00 +08:00
David Monllao aa5916d94c MDL-43882 lib: Adding info about the change in upgrade.txt 2014-02-25 11:24:00 +08:00
Damyon Wiese 2db5aef32e MDL-40619 mod_quiz: Remove commented non-js behat scenario 2014-02-25 11:05:08 +08:00
Damyon Wiese 0e0bbd9922 Merge branch 'wip-MDL-40619-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2014-02-25 11:04:40 +08:00
Dan Poltawski e274eece15 Merge branch 'MDL-43405_m26' of https://github.com/markn86/moodle into MOODLE_26_STABLE 2014-02-25 10:30:36 +08:00
Ankit Agarwal 0483a5ad93 MDL-44272 events: Fix incorrect urls in course module events 2014-02-24 17:05:02 +08:00
Damyon Wiese 7c9f70acd4 Merge branch 'MDL-43837_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-02-24 16:56:21 +08:00
Damyon Wiese 5f98c897b4 Merge branch 'MDL-44111_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-02-24 15:40:28 +08:00
Damyon Wiese 9334d95009 Merge branch 'wip-MDL-44168_26' of git://github.com/ds125v/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-02-24 15:22:42 +08:00
Damyon Wiese ede0d15765 Merge branch 'MDL-44247-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-02-24 14:30:08 +08:00
Damyon Wiese ff7b9d9d8f Merge branch '44279-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE 2014-02-24 13:38:33 +08:00
Damyon Wiese 1998e85cf1 Merge branch 'MDL-44286_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-02-24 13:33:42 +08:00
Damyon Wiese e2f19c6b33 Merge branch 'MDL-44288_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-02-24 13:27:45 +08:00
Michael Aherne 96942337fb MDL-44066 caching Don't advertise session mode for MongoDB and memcached 2014-02-24 12:49:51 +08:00
Damyon Wiese ebe9c36cb5 Merge branch '44217-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE 2014-02-24 11:14:05 +08:00
Damyon Wiese 24d6ab75fc Merge branch 'MDL-34319_m26' of https://github.com/markn86/moodle into MOODLE_26_STABLE 2014-02-24 11:09:57 +08:00
Sam Hemelryk 82403a6f38 MDL-44217 theme_bootstrapbase: darkend link colour by 5% for accessibility 2014-02-24 16:07:23 +13:00
Damyon Wiese 41a10883b6 Merge branch 'MDL-41767-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-02-24 10:41:25 +08:00
David Monllao 235847ecd5 MDL-43837 behat: Adding reduced timeouts
There are steps where we want to check that
"something" does not appear in the page
or does not exist. We still have to spin
but we don't need to spin for 6 seconds.
2014-02-24 09:43:58 +08:00
David Monllao 8102409895 MDL-44111 behat: Limiting dump files filename size 2014-02-21 13:25:11 +08:00
David Monllao 0710e4944f MDL-43882 dml: New test for perf_get_xxxx() methods 2014-02-21 13:20:51 +08:00
David Monllao 1b6b3b66df MDL-43882 performance: New metric, time spent by the database
This patch adds a new performance metric to the performance
info shown by MDL_PERF* vars, the time spent by the database,
it was one of the wonderful @poltawski ideas. To be more specific
the value displayed is the sum of the time elapsed between query_start()
and query_end().
2014-02-21 13:20:51 +08:00
David Monllao aafe8337df MDL-44286 behat: Updating to our custom Syn library 2014-02-21 10:18:23 +08:00
AMOS bot e3caf032d7 Automatically generated installer lang files 2014-02-21 00:45:30 +00:00
Sam Hemelryk 25c950b63b MDL-42279 user: fixed typo in user_get_user_details_courses 2014-02-21 08:34:42 +13:00
Sam Hemelryk d1ac630093 MDL-44279 user: added unit test to trigger known bug 2014-02-21 08:34:42 +13:00
Tim Hunt 193cb51042 MDL-44288 qtype_calculatedsimple fix validation notice.
The notice happend if you clicked Save changes before Find the wild
cards {x..} present in the correct answer formulas.
2014-02-20 12:59:50 +00:00
Eloy Lafuente (stronk7) 05636776e3 weekly release 2.6.1+ 2014-02-20 12:43:31 +01:00
Eloy Lafuente (stronk7) 3bcd0f23ff Merge branch 'install_26_STABLE' of git://git.moodle.org/moodle-install into MOODLE_26_STABLE 2014-02-20 12:43:25 +01:00
Damyon Wiese 15378769f2 MDL-43930 assign: Do not log when user is logged in as someone else.
I do not agree with this behaviour - but this makes it consistent with other modules.
2014-02-20 12:32:05 +08:00
Damyon Wiese 5e9d6beaa3 Merge branch 'MDL-44118_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-02-19 09:20:07 +08:00
Dan Poltawski a43aa9fbf1 Merge branch 'MDL-43182_26' of git://github.com/mr-russ/moodle into MOODLE_26_STABLE 2014-02-19 09:16:49 +08:00
Eloy Lafuente (stronk7) 3f4a9df9f7 MDL-43265 question: incorrect closing parenthesis 2014-02-19 00:11:35 +01:00
Eloy Lafuente (stronk7) 9f5ac013a3 Merge branch 'MDL-43265_26' of https://github.com/jacks92/moodle into MOODLE_26_STABLE 2014-02-18 23:56:12 +01:00
Eloy Lafuente (stronk7) 77da718f1b Merge branch 'MDL-43337-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-02-18 23:25:30 +01:00
Tim Hunt 652413ce70 MDL-44118 new environment check are all quiz attempts upgraded.
In Moodle 2.1, there was a major DB upgrade relating to questions, and
it was possible to delay some of that upgrade. Now, those DB tables are
changing again, and the time has come to insist that all the updata has
been upgraded (or deleted).
2014-02-18 12:01:38 +00:00
Dan Poltawski 29b3c5dfc6 Merge branch 'm26_MDL-43541' of git://github.com/danmarsden/moodle into MOODLE_26_STABLE 2014-02-18 14:14:00 +08:00
Damyon Wiese 28ac492db3 Merge branch 'MDL-43802_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-02-18 14:05:32 +08:00
Damyon Wiese fa0016a8a2 Merge branch 'MDL-41646_26' of git://github.com/apsdehal/moodle into MOODLE_26_STABLE 2014-02-18 12:41:42 +08:00
Eloy Lafuente (stronk7) 0f678757a4 Merge branch '43822-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE 2014-02-18 02:06:19 +01:00
David Scotson 8895425e41 MDL-44168 html: border=1 on regexdetect table 2014-02-17 11:47:18 +00:00
sam marshall f76c4edf01 MDL-44065 Course: _add_instance exception leads to inconsistent db
If an exception occurs during a module's _add_instance function, this
results in a course_modules entry with instance=0. The system already
handled returning false to this function, but did not handle
exceptions.
2014-02-17 10:52:10 +00:00
Frederic Massart 6e1688f7ba MDL-44247 mod_scorm: Reference to SYSTEM_CONTEXT instead of real context 2014-02-17 15:59:26 +08:00
Dan Marsden 9f3a4cbbcf MDL-43541 SCORM: set first launchable sco correctly. 2014-02-17 19:57:37 +13:00
Damyon Wiese 590a9dc30a Merge branch 'MDL-43169_m26' of https://github.com/markn86/moodle into MOODLE_26_STABLE 2014-02-17 14:35:36 +08:00
Damyon Wiese 31ab685057 Merge branch 'MDL-43504-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-02-17 14:23:40 +08:00
Marina Glancy 2dfed6304e MDL-40619 behat: test for creating a one-question quiz 2014-02-17 14:20:00 +08:00
Matt Switlik 823640c16d MDL-42618 fix grade importing of whitespace idnumbers 2014-02-17 12:14:23 +08:00
Dan Poltawski 06a8eb06f3 Merge branch 'MDL-27414_26' of git://github.com/jmvedrine/moodle into MOODLE_26_STABLE 2014-02-17 12:06:46 +08:00
Andrew Nicols 4f88b83de9 MDL-43504 Course: Include the course/category collapse JS correctly
This was previously only included when there were hidden categories to show
which were not yet visible. As a result, if all categories were visible,
then the JS was not included.
2014-02-17 11:40:09 +08:00
David Monllao 6fcf292760 MDL-43802 behat: Testing deleted activity with JS enabled 2014-02-17 11:02:36 +08:00
Dan Poltawski f23808515b Merge branch 'MDL-42033_26' of git://github.com/jmvedrine/moodle into MOODLE_26_STABLE 2014-02-17 10:32:38 +08:00
Jerome Mouneyrac fd9233c1b9 MDL-43723 restrict the drag and drop to the move icon instead of dragging the entire block header
Conflicts:
	lib/yui/build/moodle-core-blocks/moodle-core-blocks-min.js
2014-02-17 09:21:58 +08:00
Damyon Wiese 759e616eb6 Merge branch 'MDL-44018_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-02-17 09:21:46 +08:00
fabmen a0815efa5d MDL-43405 auth_ldap: Fixed issue with undefined variable: ldap_cookie 2014-02-16 14:23:17 -08:00
fabmen 25d981659b MDL-34319 auth_cas: Fixed issue with undefined variable: ldapconnection 2014-02-16 14:20:41 -08:00
Mark Nelson ce7c5de2e9 MDL-43169 core_calendar: introduced calendar type system setting (Backport of MDL-42932) 2014-02-16 13:52:57 -08:00
Sam Hemelryk bfb99b7e1d Merge branch 'MDL-44037_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-02-17 10:16:39 +13:00
Sam Hemelryk 90e7406e29 Merge branch 'MDL-42404_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-02-17 10:15:41 +13:00
Sam Hemelryk 2f31445ff8 Merge branch 'MDL-44142-26' of git://github.com/mrverrall/moodle into MOODLE_26_STABLE 2014-02-17 09:16:41 +13:00
Sam Hemelryk 0b420fab17 Merge branch 'MDL-44042-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-02-17 09:07:02 +13:00
Sam Hemelryk a413d15875 Merge branch 'MDL-44055-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-02-17 09:04:51 +13:00
Sam Hemelryk ba0f2d978b Merge branch 'MDL-44079-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE
Conflicts:
	lib/yui/build/moodle-core-notification-dialogue/moodle-core-notification-dialogue-min.js
2014-02-17 08:49:12 +13:00
Sam Hemelryk 3c60db1a84 Merge branch 'MDL-43979-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE
Conflicts:
	lib/yui/build/moodle-core-notification-dialogue/moodle-core-notification-dialogue-min.js
2014-02-17 08:28:06 +13:00
Jean-Michel Vedrine a00bff10e5 MDL-42033 Files in subdirs not exported correctly by question XML format 2014-02-16 19:46:10 +01:00
Simon Coggins a837a7c721 MDL-43049 accesslib: Fix typo in memory optimization code 2014-02-16 20:14:04 +11:00
Sam Hemelryk 19cb367592 MDL-43822 theme_bootstrapbase: blocks less tidied and reorganised
Thanks Gareth for the peer-review.
2014-02-16 14:26:11 +13:00
AMOS bot dfbde06b40 Automatically generated installer lang files 2014-02-15 00:43:51 +00:00
Jean-Michel Vedrine a1b2b00736 MDL-27414 Upgrade the randomsamatch qtype to the new question engine
Added XML import/export
Different randomsamatch questions in the same quiz can now pick the same
shortanswer question.
Images are not preserved if shortanswer question is deleted after being
used in a randomsamatch attempt.
2014-02-14 16:59:32 +01:00
Paul Verrall 0ec77cdea6 MDL-44142 Cohorts: Use maxusersperpage for list of current users. 2014-02-13 16:18:04 +00:00
Eloy Lafuente (stronk7) acbd69f7ee weekly release 2.6.1+ 2014-02-13 15:30:08 +01:00
Eloy Lafuente (stronk7) 47e4397538 Merge branch 'install_26_STABLE' of git://git.moodle.org/moodle-install into MOODLE_26_STABLE 2014-02-13 15:30:03 +01:00
Jayesh Anandani 08e9a32e5f MDL-43265 Fix question name text to 255 chars 2014-02-13 17:06:10 +05:30
David Monllao 9a8544daf6 MDL-44037 behat: New feature -> publishing rubric templates
This patch automates MDLQA-1186; rubrics can be
shared as templates.
2014-02-13 16:50:53 +08:00
David Monllao 0a1c3118ba MDL-42404 behat: Covering MDL-39710 with behat features
I've contributed to a large an ugly scenario
in favour of performance as separating it in another
scenario or feature would add 3 or 4 minutes to the suite.
2014-02-13 16:49:45 +08:00
David Monllao 782e32e3e4 MDL-42404 behat: Adding feature to test reusing user's rubrics
Automates MDLQA-1187, teachers can reuse their
rubrics in other activity.
2014-02-13 16:49:45 +08:00
David Monllao 577efa89cd MDL-42404 behat: Adding rubrics step definitions 2014-02-13 16:49:45 +08:00
David Monllao c644877218 MDL-42404 behat: Adding edit rubrics feature
Automates the following MDLQA-1185, MDLQA-1188
and MDLQA-1427. All of them related with the
expected outcomes after editing rubrics definitions
that were already used to grade students.
2014-02-13 16:49:45 +08:00
David Monllao a63fd3a6a8 MDL-42404 behat: Adding yui-dialog to dialogue selector 2014-02-13 16:49:45 +08:00
Frederic Massart 53a09b3886 MDL-43337 enrol: More tests for get_enrolled_users_with_capability 2014-02-13 12:07:06 +08:00
Frederic Massart 07b9d5e9df MDL-43337 enrol: Missing break in get_enrolled_users WS 2014-02-13 12:07:06 +08:00
apsdehal c9c9a4a76b MDL-43337 WebService: Missing break statement added
In function get_enrolled_users_with_capability
2014-02-13 12:07:06 +08:00
Andrew Nicols a5be87d234 MDL-44042 Javascript: Handle moving to the top of the current section with keyboard 2014-02-13 10:13:38 +08:00
Sam Hemelryk a70818530e Merge branch 'int26_MDL-43200' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2014-02-13 08:25:32 +13:00
Petr Škoda 6279184e14 MDL-43200 fix enrol_manual externallib tests 2014-02-12 16:03:01 +08:00
Andrew Nicols 11a788e420 MDL-43941 Behat: Section visibility tests should not check if activities are visible
It should be possible for activities to be visible even when the section
they are in is hidden.

However, when a section is hidden, all activities in that section are also
then initially hidden. Therefore, this commit splits out the hidden test to
a new test so that the initial state of activities after hiding can still
be tested.
2014-02-12 11:55:15 +08:00
AMOS bot c0aac4e36f Automatically generated installer lang files 2014-02-12 00:42:50 +00:00
Sam Hemelryk 7a27c83bc0 Merge branch 'MDL-41644_26' of git://github.com/apsdehal/moodle into MOODLE_26_STABLE 2014-02-12 09:24:11 +13:00
Marina Glancy efdbd1bd1d Merge branch '28567-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE 2014-02-11 14:42:59 +08:00
Marina Glancy 28e5849960 MDL-42505 whitespace correction 2014-02-11 14:36:52 +08:00
Michael Milette 761a10f8d5 MDL-42505 - Feedback plugin: Inappropriate use of fieldset tags around form and cancel button
Changes:
* Removed the fieldset HTML tags around the Cancel button at the bottom of the form.
* Removed the fieldset HTML tags around the whole form.
* Added missing fieldset tags around groups of radio buttons and checkboxes.
* Removed unordered list wrapping dropdown lists.
* Removed duplicate label for dropdown lists.

Modified Files:
* mod/feedback/complete.php
* mod/feedback/complete_guest.php
* mod/feedback/item/multichoice/lib.php
* mod/feedback/item/multichoicerated/lib.php

Signed-off-by: Michael Milette <michael.milette@instruxmedia.com>
2014-02-11 14:15:00 +08:00
Andrew Nicols aebc072dd4 MDL-44079 Javascript: EditPDF editor should be modal 2014-02-11 12:25:34 +08:00
Andrew Nicols 3c78500c9f MDL-44079 Javascript: Closing a tooltip should pass event details 2014-02-11 12:25:15 +08:00
Andrew Nicols 624feb24f2 MDL-44079 Javascript: Check whether a dialogue is focused before closing 2014-02-11 12:25:00 +08:00
Andrew Nicols a1f3fe6617 MDL-44055 mod_glossary: Add missing alternate name fields 2014-02-11 10:02:08 +08:00
Andrew Nicols 4ba46b8618 MDL-44055 mod_quiz: Add missing alternate name fields 2014-02-11 10:02:07 +08:00
Sam Hemelryk 58ce5122b2 Merge branch 'MDL-43941-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-02-11 14:10:58 +13:00
AMOS bot 38a69deafa Automatically generated installer lang files 2014-02-11 00:42:11 +00:00
Andrew Nicols f47b4fec8f MDL-43994 Blocks: Hide the move icon when blocks are docked on Afterburner too 2014-02-11 00:08:55 +01:00
Sam Hemelryk ec5dc1fab7 Merge branch 'MDL-43929_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-02-11 08:27:44 +13:00
Andrew Nicols 5ce1ff33ce MDL-43979 Javascript: Correct checking of attributes during dialogue init
Various dialogue attributes are optional and are provided by the parent and
not provided as attributes to the dialogue being initted.

As a result, if the setting is not provided during init, we were assuming
that the value would be false rather than checking the real attribute.
2014-02-10 22:00:44 +08:00
Marina Glancy 98c5ac4358 Merge branch '43977-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-02-10 18:16:42 +08:00
Andrew Nicols c1e725bbd1 MDL-43504 Javascript: Frontpage collapsing should not depend on enableajax
This is an oversight, but we should not depend on the enableajax setting
which we're trying to deprecate.
2014-02-10 15:45:51 +08:00
Tim Hunt f10763ebc0 MDL-43929 question manual grading: keep comment when validation fails.
If the validation failed, so the manual grading page was re-displayed
with a validation error, then any comment that had just been typed in
was getting lost. This fixes that.
2014-02-10 07:34:21 +00:00
Sam Hemelryk 5eb9a4f631 Merge branch 'wip_26_mdl-32724' of https://github.com/iarenaza/moodle into MOODLE_26_STABLE 2014-02-10 15:26:24 +13:00
Sam Hemelryk e2b27417dc Merge branch 'MDL-43774_26' of https://github.com/totara/openbadges into MOODLE_26_STABLE 2014-02-10 15:20:25 +13:00
Sam Hemelryk 8ebaf4bd74 Merge branch 'MDL-43267-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-02-10 14:53:55 +13:00
Sam Hemelryk 7aaf82deb6 Merge branch 'MDL-40938-26' of git://github.com/lazydaisy/moodle into MOODLE_26_STABLE 2014-02-10 14:16:22 +13:00
Sam Hemelryk 83fffcb97a Merge branch 'MDL-43200_26' of git://github.com/apsdehal/moodle into MOODLE_26_STABLE 2014-02-10 14:11:36 +13:00
Sam Hemelryk a5a7dd624f Merge branch 'MDL-42882-26' of git://github.com/danpoltawski/moodle into MOODLE_26_STABLE 2014-02-10 13:13:03 +13:00
Sam Hemelryk b41b2b2e18 MDL-44056 question: added new default property to unit tests 2014-02-10 12:56:48 +13:00
Sam Hemelryk 4acc62f2c4 Merge branch 'MDL-43641-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-02-10 11:50:34 +13:00
Sam Hemelryk e32b3de09e Merge branch 'MDL-44056_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-02-10 11:30:20 +13:00
Sam Hemelryk 7082e945b2 Merge branch 'MDL-43838_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-02-10 11:27:12 +13:00
Sam Hemelryk ab4ec7a21c Merge branch 'MDL-43969-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-02-10 09:48:22 +13:00
Sam Hemelryk 4e4fabd197 Merge branch 'MDL-43992-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-02-10 09:40:21 +13:00
Sam Hemelryk 7ca837ef2c MDL-44020 core: version bump for service change 2014-02-10 09:37:52 +13:00
Sam Hemelryk 8ef741eeca Merge branch 'MDL-44020-STABLE-26' of git://github.com/jleyva/moodle into MOODLE_26_STABLE 2014-02-10 09:31:04 +13:00
Sam Hemelryk 764d330c3e Merge branch 'MDL-44046_m26' of https://github.com/merrill-oakland/moodle into MOODLE_26_STABLE 2014-02-10 09:28:19 +13:00
Sam Hemelryk a95a356322 Merge branch 'MDL-43978_26' of https://github.com/totara/openbadges into MOODLE_26_STABLE 2014-02-10 09:24:01 +13:00
Sam Hemelryk dfc8d1d7f5 Merge branch 'MDL-43994-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-02-10 09:06:40 +13:00
Sam Hemelryk fdf33244b5 Merge branch 'MDL-44029-quiz-group-delete-handler-bug_26_STABLE' of https://github.com/mpetrowi/moodle into MOODLE_26_STABLE 2014-02-10 08:44:56 +13:00
Sam Hemelryk 3b6aa4f70c Merge branch 'MDL-43946_m26' of https://github.com/merrill-oakland/moodle into MOODLE_26_STABLE 2014-02-10 08:43:05 +13:00
Sam Hemelryk a7695377d7 MDL-43977 theme_bootstrapbase: small fix to make custom menu work with JS disabled 2014-02-10 08:37:00 +13:00
Sam Hemelryk dc606a57a7 MLD-28567 calendar: improved course filter process 2014-02-10 08:31:43 +13:00
Tim Hunt a82e15de84 MDL-44056 questions: restore essay attempts from 2.0 notice. 2014-02-09 17:50:59 +00:00
AMOS bot 80e5c694d3 Automatically generated installer lang files 2014-02-09 00:42:13 +00:00
Mary Evans 39790f906c MDL-40938 theme_bootstrapbase: Fix for text fields in login block. 2014-02-08 15:09:52 +00:00
Tim Hunt aa083d663b MDL-44018 quesiton variant was not backed up or restored. 2014-02-07 21:55:57 +00:00
Eric Merrill 2a2176186d MDL-44046 gradebook Reduce duplicates returned during sortorder fixing. 2014-02-07 09:30:08 -05:00
Juan Leyva ae4ce123e5 MDL-44020 Add core_calendar_get_calendar_events function to the Moodle Mobile service 2014-02-07 11:22:10 +01:00
Andrew Nicols 8f71903132 MDL-43994 Blocks: Hide the move icon when blocks are docked 2014-02-07 17:42:23 +08:00
Andrew Nicols b269650d8a MDL-43992 Javascript: Remove <return> key listener for confirmation
The listener was previously confirming, even when the cancel or 'No'
buttons were selected. However, having the default action as 'Confirm'
seems dangerous in this situation, so removing this option entirely.
2014-02-07 16:32:59 +08:00
Andrew Nicols 684424a6e6 MDL-43969 Forms: Adjust ARIA attributes for short forms
The aria-live="polite" attribute is incorrectly added to the fieldset,
causing the entire fieldset to be read out on change in some browsers. This
is unnecessary.
It also does not announce the current state of the fieldset (collaped or
open) and should.
2014-02-07 16:20:21 +08:00
Andrew Nicols 4974d22b8d MDL-43267 Javascript: Improve focus before and after drag/drop 2014-02-07 15:12:18 +08:00
Andrew Nicols 472b07b8e7 MDL-43267 Javascript: Remove aria drag/drop related attributes for drag/drop
Since we provide an alternative interface rather than describing the
locations for each drop, we should not add aria-grabbed, or
aria-dropeffect.
2014-02-07 14:17:27 +08:00
Andrew Nicols de5c64fa7c MDL-43267 Javascript: Improve accessibility of keyboard move
Change the keyboard move descriptions to allow for more detailed
descriptions such as:
* "After 'X'"; or
* "To top of section 'Y'"
2014-02-07 14:12:45 +08:00
Petr Skoda 98d135fea3 MDL-43344 upgrade to latest Flowplayer 2014-02-07 13:12:00 +08:00
Sam Hemelryk 27ebbdd703 weekly release 2.6.1+ 2014-02-07 11:46:12 +13:00
Yuliya Bozhko 79405669f9 MDL-43978 badges: Fix lang string 2014-02-07 09:10:47 +13:00
Matt Petro 82d0300757 MDL-44029 mod_quiz: Fixing group deleted handler so it does not remove user overrides. 2014-02-06 14:14:21 -05:00
Russell Smith 905b88c69c MDL-43926 files: Unit tests cannot assume id values. 2014-02-06 09:49:44 +08:00
Sam Hemelryk 155771cb4b Merge branch 'MDL-43936_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-02-06 10:04:06 +13:00
apsdehal a1b52cb282 MDL-43200 WebServices: Reset Instance variable 2014-02-06 01:05:29 +05:30
Eric Merrill e29585b206 MDL-43946 gradebook upgrade Improve SQL to find duplicate sortorders. 2014-02-05 09:57:30 -05:00
Tim Hunt 7e00410338 MDL-43936 questions: fix my lame spelling in upgrade.txt.
Thanks to Mark Nelson for the suggested improvements.
2014-02-05 11:59:53 +00:00
Marina Glancy 270cd52103 Merge branch 'MDL-42339_m26' of git://github.com/rwijaya/moodle into MOODLE_26_STABLE 2014-02-05 15:57:21 +08:00
Rossiani Wijaya a3b0030e04 MDL-42339 - removed double formatting for set_title() and set_heading() 2014-02-05 15:40:25 +08:00
Dan Poltawski 824fef6892 MDL-42882 upgrade: Improvements to upgrade code
Suggested by Petr:
* Don't rely on single user for upgrade
* Make the pathnamehash generation a bit clearer (and add
  a test to verify its correctly formed).
2014-02-05 14:40:32 +08:00
Yuliya Bozhko b70d618c04 MDL-43774 badges: Stop overriding default course navigation 2014-02-05 10:47:57 +13:00
Yuliya Bozhko 256731fd39 MDL-43978 badges: Display error message to guest users viewing "My Badges" page 2014-02-05 09:57:52 +13:00
Iñaki Arenaza b1f5a038f3 MDL-32724: LDAP Auth function user_update() returns true even if update has failed 2014-02-04 19:28:06 +01:00
Eloy Lafuente (stronk7) d088fbebac Merge branch 'MDL-43911-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-02-04 10:53:28 +01:00
Eloy Lafuente (stronk7) 4947703a0b Merge branch 'wip-MDL-41384-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2014-02-04 10:40:57 +01:00
Andrew Nicols 066bfe30b0 MDL-43641 Javascript: Correct default dialogue centering 2014-02-04 15:40:42 +08:00
Damyon Wiese ce296e211f MDL-43805 assign: Prevent behat fail on ci - editpdf is not available there
Ghostscript is not setup on the ci servers, so the editpdf feature will be automatically
disabled. This means that I cannot click on "Hide Annotate PDF".
2014-02-04 13:44:07 +08:00
Andrew Nicols e719c59c0e MDL-43941 Course: Allow AJAX show/hide of activities in hidden and orphaned sections 2014-02-04 10:57:46 +08:00
Sam Hemelryk 82bef99867 Merge branch 'MDL-43369-26' of git://github.com/jamiepratt/moodle into MOODLE_26_STABLE 2014-02-04 15:24:02 +13:00
Andrew Nicols b954cb004c MDL-43911 Behat: Save dumps of the page content to disk on scenario failure 2014-02-04 08:53:19 +08:00
Oleg Sychev c5a229c2f1 MDL-42456: add Mercurial vcs support to plugin_external_source 2014-02-04 13:10:57 +13:00
Sam Hemelryk 93289de65e Merge branch 'MDL-43885-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-02-04 12:38:28 +13:00
Marina Glancy b207d05e48 MDL-43821 completion: fix bug in section completion progress
Thanks to Shane Dye for the provided patch
2014-02-04 00:11:52 +01:00
Eloy Lafuente (stronk7) e28eb21659 Merge branch 'wip-MDL-43828-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2014-02-03 23:58:14 +01:00
Sam Hemelryk 5dce0f2a1a Merge branch 'MDL-43892_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-02-04 10:57:37 +13:00
Sam Hemelryk 90c15466d8 Merge branch 'wip-MDL-33920-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2014-02-04 10:47:09 +13:00
Sam Hemelryk c78f073a41 Merge branch 'MDL-43936_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-02-04 10:11:47 +13:00
Gordon Bateson cb5639ca1c MDL-40410 remove ampersands required for PHP strict standards lib/tablelib.php 2014-02-04 10:05:53 +13:00
Sam Hemelryk 2ad02f9c91 Merge branch 'MDL-43884-26' of git://github.com/ankitagarwal/moodle into MOODLE_26_STABLE 2014-02-04 09:11:41 +13:00
Sam Hemelryk fa0b936d59 Merge branch 'wip-MDL-39942-MOODLE_26_STABLE' of https://github.com/kwiliarty/moodle into MOODLE_26_STABLE 2014-02-04 08:29:17 +13:00
Eloy Lafuente (stronk7) fa10d60b15 Merge branch 'm26_MDL-37714' of git://github.com/greg-or/moodle into MOODLE_26_STABLE 2014-02-03 17:58:38 +01:00
Marina Glancy 8ded044775 Merge branch 'MDL-41647_26' of git://github.com/apsdehal/moodle into MOODLE_26_STABLE 2014-02-03 17:34:57 +08:00
Dan Poltawski b7f4097043 MDL-42882 upgrade: improved SQL query
Kudos to Tim Hunt who came up with this, on mysql with 4 milion
records (and a fast SSD) the performance difference is:

Original: 36.83 sec
New query: 8.63 sec
2014-02-03 17:30:21 +08:00
Dan Poltawski 5f38edeefd MDL-42882 upgrade: unit tests for root folders upgrade
Just verifying the original behaviour
2014-02-03 17:30:20 +08:00
David Monllao 74d357b1c2 MDL-43838 behat: Clean theme compatibility with small and medium screen sizes 2014-02-03 17:01:48 +08:00
Marina Glancy 839b58679d Merge branch 'MDL-43805-26' of git://github.com/damyon/moodle into MOODLE_26_STABLE 2014-02-03 16:09:37 +08:00
Marina Glancy 79efe4f22b Merge branch 'w05_MDL-43905_m26_loginevents' of git://github.com/skodak/moodle into MOODLE_26_STABLE 2014-02-03 15:34:32 +08:00
Marina Glancy 18a28dde45 Merge branch 'MDL-43593-26' of git://github.com/damyon/moodle into MOODLE_26_STABLE 2014-02-03 15:07:53 +08:00
Marina Glancy 94776f1bfa Merge branch 'MDL-43951_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-02-03 14:54:11 +08:00
David Monllao 9a13b1108f MDL-43951 behat: Fixing random failure
NodeElement->hasAttribute() (JS enabled) queries selenium
about whether it has any attribute or not, if due to an
AJAX request the field node changed selenium can not access
that node and throws an exception.
2014-02-03 13:59:32 +08:00
Marina Glancy 52b3120916 Merge branch 'MDL-43440-26' of git://github.com/mr-russ/moodle into MOODLE_26_STABLE 2014-02-03 13:43:50 +08:00
apsdehal 3a1ade2544 MDL-41646 Wiki: Removed unnecessary wiki_info class 2014-02-02 15:51:30 +05:30
apsdehal 1ab256742d MDL-41647 WebServices: Changed notification CSS class 2014-02-02 15:24:40 +05:30
apsdehal 3a98e73a54 MDL-41644 Backup: Update CSS class .notifywarning with .notifyproblem 2014-02-02 03:31:37 +05:30
Tim Hunt bdeb5d0bf1 MDL-43936 questions: document renderer API change. 2014-01-31 14:12:35 +00:00
Tim Hunt 9b62fec54a MDL-43926 Unit tests shouldn't assume only one category on install 2014-01-31 10:46:35 +00:00
Marina Glancy cfd46e76c6 MDL-43828 forum: allow to select single available group when posting 2014-01-31 17:00:19 +08:00
Marina Glancy 1c4b2c0b8d MDL-41384 course: do not show debugging message if $COURSE contains format options
before showing debugging message make sure that field exists in database and not only in the object
2014-01-31 16:59:54 +08:00
Marina Glancy e262d58d6c MDL-41384 upgrade: make sure to re-read $SITE from DB when course table is altered 2014-01-31 16:59:54 +08:00
Marina Glancy 97eb0e4473 MDL-33920 filepicker: hide 'save as' field when not applicable 2014-01-31 16:48:16 +08:00
Marina Glancy 4f6e4f8d86 weekly release 2.6.1+ 2014-01-31 14:11:19 +08:00
Marina Glancy 814a6297ec Merge branch 'install_26_STABLE' of git://git.moodle.org/moodle-install into MOODLE_26_STABLE 2014-01-31 14:11:18 +08:00
Petr Škoda 4d7f209923 MDL-43905 fix update of user login times
There needs to be only one event during user login.
The timemodified field is not supposed to be updated during login.
2014-01-31 10:07:20 +08:00
Gregory Faller 1d8d52cdd9 MDL-37714: Correctly identify frequently used comments during restore 2014-01-31 10:24:59 +10:30
Andrew Nicols c5609f6dc5 MDL-42928 Filepicker: Disable behat tests run by phantom
There seems to be a bug relating to overflow: hidden on the body tag in
some cases which is only showing for dialogues which belong to the
filepicker.

Disabling these for the moment as this issue may be related to MDL-43712
which is a work in progress.
2014-01-30 17:13:56 +08:00
Damyon Wiese e008e04db1 MDL-43805 assign: Behat test for quickgrading bug 2014-01-29 20:42:41 +08:00
Damyon Wiese 6b23bd16da MDL-43805 assign: Quickgrading wipes out grades for hidden columns.
Grr.. quickgrading will always be a hack.
2014-01-29 20:42:38 +08:00
Andrew Nicols 20a93a61db MDL-43885 Javascript: Make the [X] button work like 'No' in relevant dialogues
The [X] button on the dialogue is another form of the 'No' button and
should behave as such. In some dialogues this matters more than others
because the dialogue is destroyed.
2014-01-29 11:17:03 +08:00
Tim Hunt e82aee6895 MDL-43892 dbtransfer: Fix missing string. 2014-01-28 15:56:28 +00:00
Eloy Lafuente (stronk7) 04224a6dc7 Merge branch 'MDL-42928-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-01-28 12:22:56 +01:00
Ankit Agarwal 90ace35a9d MDL-43884 database: Fix get_tables() api for external stores 2014-01-28 16:54:35 +08:00
Kevin Wiliarty 414fcf2584 MDL-39942: invite only users who can post to discuss 2014-01-27 22:35:17 -05:00
Andrew Nicols c81672b56d MDL-42928 JavaScript: Disable lockScroll for small chooserdialogues 2014-01-28 09:50:45 +08:00
Andrew Nicols eb97871058 MDL-42928 JavaScript: Add LockScroll to all modal dialogues 2014-01-28 09:50:27 +08:00
Andrew Nicols d07b03422d MDL-42928 JavaScript: Create a module to handle page scroll locking 2014-01-28 09:50:11 +08:00
Eloy Lafuente (stronk7) 960dfcae59 Merge branch 'm26_MDL-43797' of https://github.com/totara/moodle into MOODLE_26_STABLE 2014-01-28 00:44:24 +01:00
David Curry 9eb88a59dd MDL-43797 lib/db/upgrade.php: Optimise sql for my_pages deletion
Change-Id: Ibf8da394e3357fdde351eac49627539eb412e247
2014-01-28 12:34:11 +13:00
Sam Hemelryk 9681639337 Merge branch 'MDL-43246_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-01-28 12:16:26 +13:00
Eloy Lafuente (stronk7) 115707c2b5 Merge branch '43688-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-01-28 00:00:16 +01:00
Eloy Lafuente (stronk7) d9613f122f Merge branch 'MDL-43874_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-01-27 23:53:33 +01:00
David Curry ade2c99109 MDL-43797 lib/db/upgrade.php: Remove custom pages for deleted users
Change-Id: Ief5ec1dd0930e55b6f0bf2e0d2caa3febec07b18
2014-01-28 11:30:00 +13:00
David Curry ee7d0bbfcf MDL-43797 lib/moodlelib.php: Remove custom homepages on user deletion
Change-Id: I43359a630c0b668ed3312828c15acc9cc220e49b
2014-01-28 11:27:40 +13:00
Eloy Lafuente (stronk7) 646f774a0f Merge branch 'MDL-43757_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-01-27 21:20:37 +01:00
Sam Hemelryk 83bfad45a5 Merge branch 'wip-MDL-43643-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2014-01-28 08:40:48 +13:00
Eloy Lafuente (stronk7) 408b3ee93f Merge branch 'wip-mdl-43765-m26' of https://github.com/rajeshtaneja/moodle into MOODLE_26_STABLE 2014-01-27 19:23:35 +01:00
Eloy Lafuente (stronk7) 06b2987aad Merge branch 'wip-mdl-43766-m26' of https://github.com/rajeshtaneja/moodle into MOODLE_26_STABLE 2014-01-27 19:20:02 +01:00
Eloy Lafuente (stronk7) 227164c9b6 Merge branch 'MDL-43773-MOODLE_26_STABLE' of https://github.com/lucisgit/moodle into MOODLE_26_STABLE 2014-01-27 17:22:49 +01:00
Eloy Lafuente (stronk7) ff04a96ba2 Merge branch 'MDL-43581_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-01-27 17:04:11 +01:00
Tim Hunt b006c3f9ff MDL-43874 quiz, teacher comments should respect display options.
Whether the comments on manually graded questions were visible to
students should have been controlled by the 'Specific feedback' Review
option in the quiz settings. However, the quiz was not setting
$displayoptions->manualcomment, so it did not work.
2014-01-27 12:26:59 +00:00
Eloy Lafuente (stronk7) 866bbb05f7 Merge branch 'wip-MDL-43800-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2014-01-27 12:02:36 +01:00
James Pratt b98bc5cb98 MDL-43369 : quiz statistics - average across attempts where item seen
and not across all attempts for subqs.
2014-01-27 17:37:39 +07:00
Tim Hunt b8e91060b1 MDL-43581 additionalhtmlfooter should be added to every page
Not just pages with a visible footer.
2014-01-27 10:26:02 +00:00
Eloy Lafuente (stronk7) 7a6ad10586 Merge branch 'MDL-43809_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-01-27 11:00:32 +01:00
AMOS bot e73eb478c4 Automatically generated installer lang files 2014-01-27 00:42:36 +00:00
Mark Nielsen 91e6e56014 MDL-43734: Prevent purging of all user session cache 2014-01-27 00:28:53 +01:00
Sam Hemelryk 250611b579 Merge branch 'w04_MDL-43746_m26_courselogin' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2014-01-27 11:32:25 +13:00
Sam Hemelryk 5ccfa40292 Merge branch 'MDL-43794_m26' of https://github.com/merrill-oakland/moodle into MOODLE_26_STABLE 2014-01-27 11:16:15 +13:00
Tony Butler bd538db810 MDL-43773 mod_choice: Swap order of name column headings in text export 2014-01-24 11:22:39 +00:00
Damyon Wiese e205c062b1 MDL-43593 Assign editpdf: More robust handling of errors from TCPDF.
This includes a check to see if there are 0 pages in the combined pdf,
catching exceptions and suppressing php warnings and errors from bad pdf files.

Also - Use TCPDF directly to check if pdfs are compatible. The previous check was
letting dodgy PDFs through which then failed at generation time. This way dodgy
pdfs will get run through ghostscript early and cleaned up.
2014-01-24 16:17:29 +08:00
David Monllao 9cb75a10bf MDL-43757 behat: Allowing the form field guesser to detect TinyMCE
It includes 2 more minor fixes:
- Escapes values sent to TinyMCE as it was breaking
  when values contained double quotes.
- Adding seconds to the screenshots directory to
  avoid using the same folder for multiple runs.
2014-01-24 15:12:18 +08:00
David Monllao c18481fab8 MDL-43757 messaging: Behat feature to test participants messaging
The new test checks that messages can be sent from
the participants block and they can be read when
accesing user's recent conversations.
2014-01-24 15:12:12 +08:00
Petr Skoda c22d036916 MDL-43746 fix require_course_login regression caused by MDL-25981 2014-01-24 13:51:54 +08:00
Russell Smith cac73cf1ec MDL-43440 unit testing: Use cmid in unit tests when it should be used.
instance is has been used instead of cmid.  This works as all id's are 1
in most cases, but not always.

accesslib_clear_all_caches_for_unit_testing was updated to clear the
$USER->access cache which would fail test when the wrong user's data was used.

Conflicts from extra tests in master:
	blocks/comments/tests/events_test.php
	mod/assign/submission/comments/tests/events_test.php
	mod/data/tests/lib_test.php
	mod/glossary/tests/events_test.php
2014-01-24 14:56:53 +11:00
AMOS bot d4f1027e54 Automatically generated installer lang files 2014-01-24 00:42:09 +00:00
Jason Fowler a4ea4e2b1a MDL-40786 User profile: Fixing narrow screen RTL collapse 2014-01-24 08:38:27 +08:00
Nadav Kavalerchik d86801bed7 MDL-40786 User Profile: Right align profile fields in RTL mode (theme/bootstrapbase, theme/clean) 2014-01-24 08:38:23 +08:00
Sam Hemelryk a3e2211c5f MDL-43688 dndupload: fixed positioning across themes 2014-01-24 09:52:40 +13:00
Tim Hunt 8b080d52ff MDL-43809 qformat_xml messes up $s in multianswer questions. 2014-01-23 15:19:13 +00:00
Tim Hunt 68575baff3 MDL-43246 question engine: avoid order-by id.
This was breaking with oracle master/master replication. Fortunately all
the places that needed to be changed were private to datalib.php. There
is still some ordering by id there, but only places where we want a
consitent, rather than meaningful, order, so that is OK.

The queries changed by this patch all have subqueries in aggregate
queries that pull out the latest step for a question_attempt. Those
queries used to look for MAX(id) but now they look for
MAX(sequencenumber). This is equivalent (for databases where ids always
increase with time, except for auto-saved steps. In the past,  an
auto-saved step might have been considered latest. Now the latest step
will always be one that has been properly processed. You can aruge that
this change is an improvement. Anyway, it is a moot point. All these
queries are only used in reports which are run on completed attempts,
where there will not be any autosaved data.
2014-01-23 15:18:56 +00:00
Tim Hunt 7e71efabf9 MDL-43246 some question data mapper unit tests
With fixes for the issues unearthed by these tests.
2014-01-23 15:18:55 +00:00
Tim Hunt 4caa3de6db MDL-43246 give unit tests class a better name. 2014-01-23 15:18:55 +00:00
Eloy Lafuente (stronk7) b88bb98ab7 weekly release 2.6.1+ 2014-01-23 12:38:43 +01:00
Eloy Lafuente (stronk7) fc27206268 Merge branch 'install_26_STABLE' of git://git.moodle.org/moodle-install into MOODLE_26_STABLE 2014-01-23 12:38:39 +01:00
Marina Glancy 929b5b3210 MDL-43643 chat: do not assign to nonexisting cm_info properties 2014-01-23 11:00:33 +08:00
Marina Glancy 9b4e4b7f64 MDL-43800 course: groupings are sorted alphabetically 2014-01-23 09:07:54 +08:00
Eric Merrill ff71f55265 MDL-43794 Files API Set the mtime of files to extraction time.
The restore cleanup code expects the mtime to be the time of extraction
not the mtime before archiving. If set to the old mtime, the restore
files may be cleaned up before the restore is complete.

This behaviour also matches the behaviour of the zip unpacker.
2014-01-22 11:07:07 -05:00
Dan Poltawski 8f89ca5780 Merge branch 'MDL-41506-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-01-21 23:29:25 +08:00
Dan Poltawski 32418eeee0 Merge branch 'mdl34020-moodle26' of https://github.com/tlock/moodle into MOODLE_26_STABLE 2014-01-21 15:21:20 +08:00
Dan Poltawski 0469922b5f Merge branch '43714-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE 2014-01-21 14:49:27 +08:00
Dan Poltawski 1cbda6fabd Merge branch 'MDL-43760-26' of git://github.com/damyon/moodle into MOODLE_26_STABLE 2014-01-21 14:28:52 +08:00
Damyon Wiese eef0d3043c Merge branch 'MDL-43725-26' of git://github.com/ankitagarwal/moodle into MOODLE_26_STABLE 2014-01-21 13:55:49 +08:00
Dan Poltawski 1f77f14fb9 Merge branch 'wip-MDL-43700-26' of git://github.com/abgreeve/moodle into MOODLE_26_STABLE 2014-01-21 12:24:41 +08:00
Dan Poltawski 574111a94e Merge branch 'MDL-43717_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-01-21 12:19:36 +08:00
Dan Poltawski 66b74e5aa5 Merge branch 'MDL-43693-MOODLE_26_STABLE' of https://github.com/lucisgit/moodle into MOODLE_26_STABLE 2014-01-21 11:21:54 +08:00
Rajesh Taneja 81efab0cbb MDL-43765 reports: Fixed addtional name warning
Fix the alternate name warning which is generated when course participation report
is viewed
2014-01-21 11:00:45 +08:00
Damyon Wiese 9717c4b19c Merge branch 'MDL-41688-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-01-21 09:37:04 +08:00
Damyon Wiese d6d18a2b7b Merge branch 'MDL-43732_m26' of github.com:merrill-oakland/moodle into MOODLE_26_STABLE 2014-01-21 09:29:40 +08:00
Eloy Lafuente (stronk7) 8d8e51b073 Merge branch 'wip-MDL-43333-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2014-01-21 02:01:35 +01:00
Eric Merrill 2d73ec85ea MDL-43732 quiz Fix styles so that question div doesn't overlap controls. 2014-01-20 19:57:10 -05:00
Eloy Lafuente (stronk7) b61b21d7ee Merge branch 'wip-MDL-43211-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2014-01-21 01:54:09 +01:00
Eloy Lafuente (stronk7) a45dbb214b Merge branch 'MDL-43401-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-01-21 01:46:54 +01:00
Eloy Lafuente (stronk7) f973e5f968 Merge branch 'MDL-43480_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-01-21 01:44:45 +01:00
Eloy Lafuente (stronk7) 3e1eb36d77 Merge branch 'MDL-41693-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-01-21 01:13:54 +01:00
Eloy Lafuente (stronk7) 3677e0c1aa Merge branch 'MDL-39684-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-01-21 00:20:51 +01:00
Eloy Lafuente (stronk7) 133e38fdbb Merge branch 'MDL-40533-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-01-21 00:17:39 +01:00
Eloy Lafuente (stronk7) 7c5074ce82 Merge branch 'MDL-43743_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-01-21 00:05:11 +01:00
Eloy Lafuente (stronk7) a7029b542e Merge branch 'MDL-41362-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-01-21 00:02:11 +01:00
Frederic Massart ff66e9daa8 MDL-41767 themes: Support for parent-specific sheets in plugins 2014-01-20 13:31:58 +01:00
Frederic Massart b12cc0679f MDL-41688 gradebook: Improved grading layout on bootstrapbase themes 2014-01-20 10:43:10 +01:00
Tony Butler cfd4b8a3f5 MDL-43632 mod_feedback: Use SSL for reCAPTCHA API request if Moodle is using it 2014-01-20 17:14:38 +08:00
Rajesh Taneja ee7bb53ccd MDL-43766 reports: Fixed wrong string variable 2014-01-20 16:47:01 +08:00
Dan Poltawski 5f074a6bb0 Merge branch 'wip-MDL-41062-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2014-01-20 15:29:21 +08:00
Dan Poltawski 4f02d0074a Merge branch '42682-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE 2014-01-20 15:25:49 +08:00
Dan Poltawski 1605660ad2 Merge branch 'MDL-43690_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-01-20 14:24:44 +08:00
Damyon Wiese 62415470ae MDL-43760 Potential fix for fletcher scott issues with fullname. 2014-01-20 13:39:19 +08:00
Damyon Wiese e35e70f83d Merge branch 'MDL-42495-m26' of git://github.com/micaherne/moodle into MOODLE_26_STABLE 2014-01-20 13:21:34 +08:00
Dan Poltawski 8a073e4364 Merge branch 'MDL-42980_m26' of git://github.com/rwijaya/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-01-20 12:56:20 +08:00
Marina Glancy 8de9100136 MDL-41062 gradebook: corrections to grade_item upgrade script, more tests 2014-01-20 12:25:56 +08:00
Damyon Wiese b53af0f2a6 Merge branch 'MDL-39683-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-01-20 11:29:21 +08:00
Damyon Wiese 5b860c69a2 Merge branch '43675-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE 2014-01-20 10:56:34 +08:00
Dan Poltawski 37b0d3adad Merge branch 'MDL-43671_message_26' of https://github.com/andyjdavis/moodle into MOODLE_26_STABLE 2014-01-20 10:53:53 +08:00
Dan Poltawski da2e9d519b Merge branch 'MDL-40139-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-01-20 10:33:38 +08:00
Ankit Agarwal 6cfed595c9 MDL-43725 report_loglive: Fixing undefined variable error
AMOS BEGIN
 CPY [page,report_log],[page,report_loglive]
AMOS END
2014-01-20 10:23:55 +08:00
Damyon Wiese df25d33379 Merge branch 'MDL-43733_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-01-20 10:13:54 +08:00
Andrew Davis 9fade08632 MDL-43671 message: removed an overly cautious check 2014-01-20 10:06:27 +08:00
Dan Poltawski e53eb2a208 Merge branch 'wip-mdl-43306-m26' of git://github.com/rajeshtaneja/moodle into MOODLE_26_STABLE 2014-01-20 09:45:44 +08:00
David Monllao 2998a4cb30 MDL-43743 mod_scorm: Adding package disclaimer
As the package is licensed under CC 3.0 we should
be compliant with attribution.
2014-01-20 09:32:17 +08:00
Dan Poltawski 0b8749c892 Merge branch 'MDL-40752-26' of git://github.com/phalacee/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-01-20 09:26:12 +08:00
AMOS bot e1882ddaef Automatically generated installer lang files 2014-01-20 00:41:22 +00:00
AMOS bot bb2e1de1c2 Automatically generated installer lang files 2014-01-19 00:41:56 +00:00
Tim Hunt 4c4fc6d629 MDL-43733 use any auto-saved responses when questions are finished.
Before this, autosave was only working to save data when a student went
back in to continue an attempt. If the student, having crashed out,
never went back in and continued the attempt, their auto-saved responses
were not used when the attempt was automatically finished. That was a
rather bad oversight, which should now be fixed.
2014-01-17 17:17:49 +00:00
Tim Hunt 217d839ded MDL-43690 quiz_question_tostring missing s().
This meant that the edit quiz page sometimes had invalid HTML.
2014-01-17 10:47:00 +00:00
David Monllao cd554c4287 MDL-43743 behat: Lightweight scorm package
The previous used package were adding a second iframe
inside the scorm iframe and was slow loading it;
this patch replaces it for a simple one without any
extra iframe.
2014-01-17 17:43:25 +08:00
Dan Poltawski 15fac63956 MDL-41062 gradebook: remove sortorder duplicates
* Upgrade function to remove duplicates from the grade item duplicates
  column. Duplicates were causing sorting to fail in some cases.
* Add some unit tests which simulate sort order duplicate data and
  verify that they have been removed.
2014-01-17 17:36:37 +08:00
rwijaya dc842aaa36 MDL-42980 clean theme: fixed add/cancel buttons position for safari on iPhone with ios7. 2014-01-17 16:14:14 +08:00
David Monllao ef967ae424 MDL-43480 behat: Adding @_file_upload and @_alert tags
Keeping the previous @_only_local and @_alerts as
this is a stable branch.
2014-01-17 10:42:22 +08:00
David Monllao 8279060aca MDL-43480 behat: Removing @_only_local tags from steps where it is not necessary 2014-01-17 10:42:22 +08:00
David Monllao 2ab17fbdeb MDL-43717 behat: Replacing 2050 for a date eariler than the max timestamp 32bit limit
All credit goes to Michael de Raadt.
2014-01-17 10:37:27 +08:00
AMOS bot 4a45541511 Automatically generated installer lang files 2014-01-17 00:48:06 +00:00
Sam Hemelryk 9b93e7b472 MDL-43714 blocks: fixed notice when moving to an empty region 2014-01-17 10:47:23 +13:00
Sam Hemelryk aafc6872e4 MDL-43675 navigation: courses branch is now recognised as expandable 2014-01-17 10:27:05 +13:00
Sam Hemelryk d073c81248 MDL-42682 theme_bootstrapbase: fixed styling of discussion selector
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-01-17 10:25:26 +13:00
Sam Hemelryk 74aa973e8e MDL-42682 theme_bootstrapbase: fixed forum search alignment
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-01-17 10:25:24 +13:00
Eloy Lafuente (stronk7) 9c1c9d8954 weekly release 2.6.1+ 2014-01-16 18:51:19 +01:00
Eloy Lafuente (stronk7) 40e8488c8d Merge branch 'install_26_STABLE' of git://git.moodle.org/moodle-install into MOODLE_26_STABLE 2014-01-16 18:51:14 +01:00
AMOS bot 9a57b4bc0b Automatically generated installer lang files 2014-01-16 00:43:16 +00:00
Eloy Lafuente (stronk7) ba541f01b6 Merge branch 'm26_MDL-43222' of git://github.com/danmarsden/moodle into MOODLE_26_STABLE 2014-01-15 22:02:29 +01:00
Dan Marsden 64156342ad MDL-43222 SCORM: Fix invalid sql 2014-01-16 09:49:36 +13:00
Rajesh Taneja ebc09cc3ad MDL-43306 restore: Fix grade_item sortorder after restoring course
While restoring course/activity, restore will blindly insert grade_item
sortorder. Which cause dulicate sortorder and lead to unpredicatble sorting
results.

Now we will call grade_item::fix_duplicate_sortorder() after restore is finished
to fix duplicate sortorder and order grade items to the closest order possible
2014-01-15 13:31:57 +08:00
Damyon Wiese 5af6a32866 Merge branch 'MDL-43621_26' of https://github.com/totara/openbadges into MOODLE_26_STABLE 2014-01-15 13:30:58 +08:00
Adrian Greeve cbfbe43604 MDL-43700 reports: Update to the sql in the comment locallib to include additional name fields. 2014-01-15 12:05:40 +08:00
Yuliya Bozhko f0040e7daf MDL-43621 badges: Fix has_awards() result when deleted users are the only recipients of a badge 2014-01-15 16:25:48 +13:00
Eloy Lafuente (stronk7) 893139fd12 Merge branch 'MDL-43439_26-dateformat' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-01-15 04:01:11 +01:00
Damyon Wiese f5d810b4f3 Merge branch 'MDL-43461_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-01-15 09:38:46 +08:00
David Monllao e5ee31453a MDL-43439 behat: Dir date without - separators 2014-01-15 09:18:55 +08:00
Dan Poltawski 05297cc0a8 Merge branch 'MDL-43619-m26' of git://github.com/sammarshallou/moodle into MOODLE_26_STABLE 2014-01-15 08:20:39 +08:00
Eloy Lafuente (stronk7) 66e46b4859 Merge branch 'MDL-43439_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-01-15 00:11:18 +01:00
Yuliya Bozhko 4768a4768b MDL-43621 badges: Don't count deleted users as badge recipients 2014-01-15 09:57:26 +13:00
Yuliya Bozhko b4918e7d8a MDL-43621 badges: Don't display deleted users in badge recipients list 2014-01-15 09:54:19 +13:00
Eloy Lafuente (stronk7) 65e9de16c2 Merge branch 'wip-MDL-31597-26' of git://github.com/abgreeve/moodle into MOODLE_26_STABLE 2014-01-14 21:49:37 +01:00
Frederic Massart 1e8b6e0087 MDL-40533 block_html: Remove styles specific to the block 2014-01-14 19:07:22 +01:00
Ruslan Kabalin 9d649ad7a3 MDL-43693: assignment: Fix JS error on grading page. 2014-01-14 16:14:41 +00:00
Eloy Lafuente (stronk7) ff48f6f0e7 Merge branch 'MDL-43332_m26' of https://github.com/markn86/moodle into MOODLE_26_STABLE 2014-01-14 16:53:40 +01:00
Eloy Lafuente (stronk7) f5191afd30 Merge branch 'm26_MDL-43222' of git://github.com/danmarsden/moodle into MOODLE_26_STABLE 2014-01-14 16:45:38 +01:00
sam marshall a6a14f2155 MDL-43619 Roles: reset_role_capabilities unit test, cache fix 2014-01-14 13:47:38 +00:00
sam marshall bf2c42e8ee MDL-43619 Roles: reset_role_capabilities function destroys overrides 2014-01-14 13:47:37 +00:00
Frederic Massart b31c53a372 MDL-41506 theme_bootstrapbase: Implement highlight class 2014-01-14 11:24:10 +01:00
Dan Poltawski f9d14c4cd7 Merge branch 'MDL-43664-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-01-14 16:50:09 +08:00
Dan Poltawski 79c8b9fcae Merge branch 'm26_MDL-43577_Incorrect_Variable_Expansion' of https://github.com/scara/moodle into MOODLE_26_STABLE 2014-01-14 15:58:12 +08:00
Dan Poltawski 33d83d755a Merge branch 'MDL-43642_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-01-14 15:48:52 +08:00
Dan Poltawski 4a2ac9676a Merge branch 'm26_MDL-43575_Typo_In_The_Overridden_setOption' of https://github.com/scara/moodle into MOODLE_26_STABLE 2014-01-14 15:37:04 +08:00
Dan Poltawski 30354dc0d2 Merge branch 'MDL-43178_forum_26' of https://github.com/andyjdavis/moodle into MOODLE_26_STABLE 2014-01-14 15:26:52 +08:00
David Monllao e906a85cc3 MDL-43439 behat: Save the screenshots to the specified location 2014-01-14 15:24:09 +08:00
Damyon Wiese 7b0e78bf83 Merge branch 'w02_MDL-43511_m26_bankcache' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2014-01-14 14:29:34 +08:00
Damyon Wiese 24607ba326 Merge branch 'MDL-43371-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-01-14 14:05:27 +08:00
Damyon Wiese eb8f1fef79 Merge branch 'MDL-43460-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-01-14 13:33:30 +08:00
Damyon Wiese 5a0cf2cda0 Merge branch 'w02_MDL-43488_m26_signreq' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2014-01-14 13:18:35 +08:00
David Monllao 58dd0d506e MDL-43461 testing: Avoid switching to .bat files when running MinGW
MinGW can not execute .bat files (http://sourceforge.net/p/mingw/bugs/1902)
so we should not switch to .bat files when running MinGW.
2014-01-14 13:14:40 +08:00
David Monllao 22a09b7d40 MDL-43461 behat: Using linux-style directory separators when using cygwin 2014-01-14 13:14:14 +08:00
Damyon Wiese 020705cca0 Merge branch 'MDL-43610-m26' of git://github.com/micaherne/moodle into MOODLE_26_STABLE 2014-01-14 12:37:17 +08:00
Adrian Greeve e5eddec0b7 MDL-31597 gradebook: Update to gradebook behat tests to include testing grade weightings. 2014-01-14 11:48:36 +08:00
Adrian Greeve 7269154b44 MDL-31597 gradebook: Removed the percentage symbol from weights in the gradebook. 2014-01-14 11:48:12 +08:00
Dan Poltawski 1e65c37e97 Merge branch 'm26_MDL-42792' of git://github.com/danmarsden/moodle into MOODLE_26_STABLE 2014-01-14 11:28:44 +08:00
Dan Poltawski b3eacbd5da Merge branch 'MDL-43412_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-01-14 10:46:34 +08:00
Andrew Nicols 56f0dc64ed MDL-43664 Javascript: Use YUI indexOf for pending_js tracking
Some old browsers do not support indexOf and so cannot determine whether JS
script is in progress. The YUI Y.Array module polyfills the indexOf
functionality when it does not exist.
2014-01-14 10:40:39 +08:00
Nadav Kavalerchik f4075b7127 MDL-40752 Login RTL: Swapping the panels on two-panel login pages for RTL
Additions to the patch made by Jason Fowler <phalacee@gmail.com>
2014-01-14 09:23:46 +08:00
AMOS bot 1b696dcde0 Automatically generated installer lang files 2014-01-14 00:45:37 +00:00
Mark Nelson 0deddeed2f MDL-43332 core_grades: automated basic grade viewing functionality performed in MDLQA-317 2014-01-13 15:48:12 -08:00
Eloy Lafuente (stronk7) 8c75f05721 Merge branch 'MDL-43109_26' of https://github.com/mdikih/moodle into MOODLE_26_STABLE 2014-01-13 21:51:54 +01:00
Matteo Scaramuccia fc33a35857 MDL-43575 Libraries Google_CurlIO ext, typo in the overridden setOption(). 2014-01-13 21:34:48 +01:00
Matteo Scaramuccia 5725c1850f MDL-43577 Messages Incorrect variable expansion in the message template. 2014-01-13 21:11:09 +01:00
Frederic Massart c7d4465070 MDL-41362 theme_bootstrapbase: Alignment of User Selector controls 2014-01-13 18:41:32 +01:00
Frederic Massart b4eed40953 MDL-39684 theme: RTL align of restrictions label in file manager 2014-01-13 16:27:52 +01:00
Frederic Massart 08a491e16d MDL-39683 message: RTL alignment of messages in theme_base 2014-01-13 15:41:30 +01:00
Nadav Kavalerchik 53a26c87d6 MDL-39683 Messages, Themes: Fix "my" and "other person" message alignment in RTL mode (theme/clean) 2014-01-13 15:29:53 +01:00
Dan Poltawski a377868a50 Merge branch 'MDL-40849-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-01-13 15:50:34 +08:00
Frederic Massart 7e343b7304 MDL-40849 gradingform_guide: Fixed CSS issues with Bootstrapbase 2014-01-13 08:12:18 +01:00
Dan Poltawski 4d2984c136 Merge branch '43598-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE 2014-01-13 12:37:26 +08:00
Dan Poltawski 6719aa5ec5 Merge branch 'MDL-39603-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-01-13 12:34:58 +08:00
Dan Poltawski d9dcb97bbe Merge branch '41226-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE 2014-01-13 11:11:12 +08:00
Dan Poltawski 51bced46a7 Merge branch '40821-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE 2014-01-13 11:03:37 +08:00
Dan Poltawski a893680091 Merge branch '40693-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE 2014-01-13 10:07:54 +08:00
Dan Poltawski 67a75acaff Merge branch 'MDL-41152-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-01-13 10:03:47 +08:00
Sam Hemelryk 6060234de5 MDL-40205 theme: fixed overflow of block headers
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-01-13 09:41:25 +08:00
Dan Poltawski 892173b3f3 Merge branch 'MDL-40705-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-01-13 09:36:12 +08:00
Dan Poltawski bc7a77f14d Merge branch 'MDL-39661-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-01-13 08:54:23 +08:00
Sam Hemelryk a2fb18da50 MDL-43598 dialogue: fixed bug with render procedure
Conflicts:
	lib/yui/build/moodle-core-chooserdialogue/moodle-core-chooserdialogue-min.js
	lib/yui/build/moodle-core-notification-dialogue/moodle-core-notification-dialogue-min.js
2014-01-13 08:25:42 +13:00
Sam Hemelryk cdd7fe6a48 MDL-40821 theme_bootstrapbase: fixed positioning of profile controls
Conflicts:
	theme/bootstrapbase/style/moodle.css

Conflicts:
	theme/bootstrapbase/style/moodle.css
2014-01-13 08:17:12 +13:00
Sam Hemelryk fe7bf6425a MDL-40821 theme_bootstrapbase: show the current lang in the menu 2014-01-13 08:16:04 +13:00
Sam Hemelryk 495a02bb5a MDL-40693 theme_bootstrapbase: changed navbar separator to official separator 2014-01-13 08:15:39 +13:00
Petr Škoda a27c1faa9f MDL-43488 remoe city and country requirement from signup
This was supposed to be part of MDL-28558.
2014-01-12 18:23:56 +08:00
Petr Škoda 6b4ae63ac8 MDL-43511 do not cache the MUC cache in question code 2014-01-12 18:21:29 +08:00
Eloy Lafuente (stronk7) 0e088aec08 Moodle release 2.6.1 2014-01-11 15:57:34 +01:00
Eloy Lafuente (stronk7) 378240d57d MDL-43646 "disapprove" changed to "undo approval" 2014-01-10 19:55:23 +01:00
Eloy Lafuente (stronk7) d339d41274 MDL-43590 move unapprove to undo approval 2014-01-10 18:55:17 +01:00
Michael Aherne 4b6c90cb17 MDL-46310 assign Prevent blind marking submission notification email being sent to noreplyemail address 2014-01-10 16:03:17 +00:00
Frederic Massart 543397a50d MDL-40139 block_privatefiles: Prevent usage of unmaintained edit page 2014-01-10 13:01:56 +01:00
Frederic Massart 0047b06264 MDL-41693 group: Use standard layout for group related pages 2014-01-10 12:29:56 +01:00
Damyon Wiese 134462ae28 MDL-43439: Behat - new $CFG param - behat_screenshot_after_failure 2014-01-10 17:56:04 +08:00
David Monllao 52a027398e MDL-43642 behat: Setting the correct files @package 2014-01-10 17:47:49 +08:00
Eloy Lafuente (stronk7) 02b5deb65a Merge branch 'MDL-43590-en_fix_26' of git://github.com/mudrd8mz/moodle into MOODLE_26_STABLE 2014-01-10 10:10:27 +01:00
Dan Marsden e71ac727e3 MDL-43222 SCORM: correct check for list of attempts and make correct check for current attempt in scorm_get_toc 2014-01-10 22:04:54 +13:00
Dan Marsden 8c5dd5e5eb MDL-42792 SCORM: Prevent JS error when network connection fails. - return false to SCORM package so that issue can be detected and reported. 2014-01-10 21:06:39 +13:00
Damyon Wiese 704ecfea00 weekly release 2.6+ 2014-01-10 14:20:58 +08:00
Damyon Wiese 8aaad0d2b6 Merge branch 'install_26_STABLE' of git://git.moodle.org/moodle-install into MOODLE_26_STABLE 2014-01-10 14:20:52 +08:00
Marina Glancy 0078652172 MDL-43333 blocks: move activity icon in social and main menu 2014-01-10 12:09:09 +08:00
Eloy Lafuente (stronk7) 8d5b7ed598 MDL-36721 make upgrade queries cross-db 2014-01-10 11:20:52 +08:00
Andrew Davis b4de89cc95 MDL-43178 mod_forum: fixed the digest setting confirmation message 2014-01-10 08:42:21 +08:00
Eloy Lafuente (stronk7) d9aa7cbb6f Merge branch 'wip-MDL-43283-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2014-01-09 23:07:52 +01:00
Frederic Massart 750f660990 MDL-43401 mod_lesson: Fix serving of the pluginfile mediafile 2014-01-09 16:56:06 +01:00
Frederic Massart 7e3c5c34d6 MDL-43371 mod_lesson: Remove files upon page or module deletion 2014-01-09 16:23:17 +01:00
Frederic Massart 9a093f57a1 MDL-41152 theme_bootstrapbase: Optimise width for gradebook tree view 2014-01-09 10:44:40 +01:00
Marina Glancy 69d44a56fe MDL-43211 blocks: style edit icons in main menu and social activities 2014-01-09 17:29:30 +08:00
Marina Glancy 41391dfd9d MDL-43211 course: do not return indent icon if not needed 2014-01-09 17:29:25 +08:00
Marina Glancy 61d35d7b9d MDL-43283 mod_chat: corrected SQL query to follow strict groupping rules 2014-01-09 15:38:29 +08:00
AMOS bot 963e29f6b2 Automatically generated installer lang files 2014-01-09 00:42:12 +00:00
Helen Foster 8772689453 MDL-43590 Merge English strings from the en_fix language pack 2014-01-09 01:11:59 +01:00
Tim Hunt 4cbc5af3a6 MDL-43412 quiz with grade period and password did not work.
Once the attempt became overdue, it was impossible to get in to submit
it because of a redirect loop. This fix resovles that loop, so the
student can enter their password and get in.
2014-01-08 18:00:56 +00:00
Andrew Nicols 5cf42ac843 MDL-40119 Forms: Remove cursor style override for calendar button 2014-01-08 11:14:37 +01:00
Frederic Massart bc936e8ac8 MDL-39603 theme_bootstrapbase: Alignment of filter form elements on enrol page 2014-01-08 10:45:13 +01:00
David Monllao 5bb7f7e0dc MDL-43423 behat: Increasing the timeout to 6 seconds 2014-01-08 09:56:10 +01:00
Dan Poltawski 135634fbd3 Merge branch 'wip-MDL-43606-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2014-01-08 14:33:11 +08:00
Marina Glancy 6f70004a0d MDL-43606 tinymce_managefiles: bump version
to allow smooth upgrade from contributed plugin in 2.5
2014-01-08 13:57:54 +08:00
Dan Poltawski d99f765ee6 Merge branch 'MDL-43595-26' of git://github.com/damyon/moodle into MOODLE_26_STABLE 2014-01-08 11:34:48 +08:00
Damyon Wiese 87f4750d75 MDL-43595: The dropdowns for editpdf stopped working due to a recent change. 2014-01-08 09:20:04 +08:00
Eloy Lafuente (stronk7) a3fa0ca96f Merge branch 'MDL-40119-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-01-08 02:17:42 +01:00
Eloy Lafuente (stronk7) 895e16ff28 Merge branch 'w01_MDL-42797_m26_admin' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2014-01-08 02:10:36 +01:00
Eloy Lafuente (stronk7) 93073173ce Merge branch 'MDL-43423_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-01-08 02:02:56 +01:00
Eloy Lafuente (stronk7) 5c283bb713 Merge branch 'wip-MDL-42310-26' of git://github.com/abgreeve/moodle into MOODLE_26_STABLE 2014-01-08 01:52:12 +01:00
Dan Poltawski e86b3c7335 Merge branch 'MDL-43173_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2014-01-08 08:21:09 +08:00
Eloy Lafuente (stronk7) 52d8541b5b Merge branch 'm26_MDL-43508_Invalid_String_Identifier' of https://github.com/scara/moodle into MOODLE_26_STABLE 2014-01-08 00:46:13 +01:00
Eloy Lafuente (stronk7) 99a57908f5 Merge branch 'MDL-42607_rss_26' of https://github.com/andyjdavis/moodle into MOODLE_26_STABLE 2014-01-08 00:42:45 +01:00
Eloy Lafuente (stronk7) ebe415f889 Merge branch 'MDL-42392-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-01-08 00:33:48 +01:00
Eloy Lafuente (stronk7) f0d61c012d Merge branch 'MDL-43451-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-01-07 23:38:28 +01:00
Dan Poltawski d829440fed Merge branch 'w01_MDL-43510_m26_test404' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2014-01-07 17:26:01 +08:00
Dan Poltawski e57bc1637c Merge branch 'm26_MDL-43482_Lot_Of_Passed_By_Reference_Messages' of https://github.com/scara/moodle into MOODLE_26_STABLE 2014-01-07 17:20:49 +08:00
Damyon Wiese 708e0804b8 Merge branch 'w01_MDL-43585_m26_userlib' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2014-01-07 13:33:53 +08:00
Damyon Wiese 3a8e16ecab Merge branch 'MDL-43411-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-01-07 12:52:49 +08:00
Dan Poltawski 9fe6a6f42b Merge branch 'm26_MDL-40379_Prevent_Some_Mobile_Network_Providers_From_Modifying_Content' of https://github.com/scara/moodle into MOODLE_26_STABLE 2014-01-07 12:43:29 +08:00
Petr Škoda 7f5a384c99 MDL-43585 remove incorrect user/lib.php include 2014-01-07 12:16:34 +08:00
Dan Poltawski 836399115b Merge branch 'MDL-42995-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-01-07 11:51:18 +08:00
Dan Poltawski adb28ab708 Merge branch 'wip-mdl-43521-m26' of https://github.com/rajeshtaneja/moodle into MOODLE_26_STABLE 2014-01-07 11:08:28 +08:00
Rajesh Taneja c783a874f0 MDL-42643 course: Member in same group should only loginas
If course groupmode is set to SEPARATEGROUPS, and user doesn't have
site:accessallgroups capability than only allow user to loginas if
current user is in same group as loginas user
2014-01-07 11:05:27 +08:00
Dan Poltawski 883ea035af Merge branch 'MDL-43394a-26' of https://github.com/srynot4sale/moodle into MOODLE_26_STABLE 2014-01-07 11:00:12 +08:00
Tony Butler c56a930df8 MDL-43373 core_enrol: Display enrolments dimmed if outside of start or end times 2014-01-07 10:44:29 +08:00
Damyon Wiese 28abbabae5 Merge branch 'MDL-43448_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2014-01-07 09:22:15 +08:00
AMOS bot 2010db2cd4 Automatically generated installer lang files 2014-01-07 00:41:52 +00:00
Frederic Massart bf6527407d MDL-40705 theme_bootstrapbase: Handling of long words in block content 2014-01-06 15:45:19 +01:00
Frederic Massart 2424069da2 MDL-39661 blocks: Removed notice when moving a block 2014-01-06 12:44:23 +01:00
Frederic Massart 8d1293da86 MDL-43460 calendar: Decode event description links on restore 2014-01-06 11:46:56 +01:00
Frederic Massart 396b5cc75b MDL-42995 mod_assign: Extended tests for update_calendar method 2014-01-06 10:32:06 +01:00
Frederic Massart 49a9cc9bd1 MDL-42995 mod_assign: Remove files from calendar event description 2014-01-06 10:32:00 +01:00
Frederic Massart 5bf8b2e969 MDL-42995 libraries: Global function to strip pluginfile content 2014-01-06 10:31:48 +01:00
Damyon Wiese 9ce83d0908 Merge branch 'MDL-43399-26' of git://github.com/mouneyrac/moodle into MOODLE_26_STABLE 2014-01-06 16:14:02 +08:00
Damyon Wiese 0f399f7f74 Merge branch 'MDL-43454-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-01-06 15:52:17 +08:00
Damyon Wiese 5726fe6263 Merge branch 'w01_MDL-36721_m26_passlog' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2014-01-06 14:51:16 +08:00
Dan Poltawski e3e938b861 Merge branch '43349-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE 2014-01-06 14:21:45 +08:00
Rajesh Taneja 3dd7b4f805 MDL-42883 Administration: Check sessionkey before taking action on user profile fields 2014-01-06 13:58:59 +08:00
Tony Butler cf3f46344e MDL-43408 gradereport_grader: Display users with expired enrolments as inactive in grader report 2014-01-06 10:38:13 +08:00
Sam Hemelryk 0cb1903bfd Merge branch 'MDL-35973_redirect_26' of https://github.com/andyjdavis/moodle into MOODLE_26_STABLE 2014-01-06 11:28:25 +13:00
Sam Hemelryk 8571b889f3 Merge branch 'MDL-43281-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-01-06 11:22:09 +13:00
Sam Hemelryk ec9f2a7d3f Merge branch 'MDL-42212-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2014-01-06 10:30:13 +13:00
Sam Hemelryk 97e9098927 Merge branch 'MDL-42801-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2014-01-06 10:20:39 +13:00
Andrew Davis 44b74479cb MDL-35973 lib: added a page title to redirect() and added 2 seconds to the page redirection when posting in a forum 2014-01-05 20:08:05 +08:00
AMOS bot 6a4e20e239 Automatically generated installer lang files 2014-01-04 00:51:51 +00:00
David Monllao adf125a30b MDL-43173 behat: Thowing an exception if the JS is not ready 2014-01-03 11:29:56 +08:00
Rajesh Taneja 3db84ae082 MDL-43521 block_admin_bookmarks: Site admin node is of type TYPE_SITE_ADMIN
Since 2.6 Site admin node is of type TYPE_SITE_ADMIN, previously it was TYPE_SETTING
2014-01-03 10:47:39 +08:00
Michael Milette 025000a221 MDL-42310 feedback mod - Enable filtering of multichoice and multichoice rated controls
Conflicts:
	mod/feedback/item/multichoice/lib.php
	mod/feedback/item/multichoicerated/lib.php

Signed-off-by: Michael Milette <michael.milette@instruxmedia.com>
2014-01-03 10:30:11 +08:00
Andrew Davis a90069245d MDL-42607 mod_forum:fixed some inefficiencies in forum RSS generation 2014-01-02 10:50:54 +08:00
Petr Škoda ddc72f06ef MDL-42797 require real user login on upgrade settings page 2014-01-02 09:17:38 +08:00
Sam Hemelryk 55f4cb7299 MDL-43349 cache: init now checks store requirements are met 2014-01-02 09:22:42 +13:00
Petr Škoda 9d904936c8 MDL-42797 require real user login on admin page 2014-01-01 15:19:34 +08:00
Andrew Nicols 560672aaa1 MDL-43451 Cron: Retrieve additional name fields when creating passwords 2014-01-01 02:25:42 +08:00
Andrew Nicols 5aee2507d4 MDL-43281 Blocks: Retrieve a newly created block after creating it
Although we were previously creating the DOM markup for a block region if
it did not exist, we were not making use of it.

This change ensures that we make use of that block region as part of the
blocks code.
2014-01-01 02:20:15 +08:00
Andrew Nicols 1f5b61e1db MDL-40119 Forms: Date selector should use images for the calendar popup toggle
The calendar popup toggle must use an image, rather than an input with type
of image as the latter is actually a form of submit button, and hence it
steals the focus away from the real submit button.
2013-12-30 15:54:42 +08:00
AMOS bot c15270df73 Automatically generated installer lang files 2013-12-30 00:43:23 +00:00
Petr Škoda 5e10746ae7 MDL-43510 fix 404 unit test server incompatibility 2013-12-29 15:29:30 +08:00
AMOS bot 84510e3b82 Automatically generated installer lang files 2013-12-29 00:43:25 +00:00
Matteo Scaramuccia a9df6656b8 MDL-40379 Files Prevent mobile network providers from modifying content. 2013-12-28 14:02:18 +01:00
Matteo Scaramuccia b33cc5d748 MDL-43508 Quiz Invalid get_string() identifier. 2013-12-28 11:21:36 +01:00
Andrew Nicols 74b0aca7eb MDL-42801 JavaScript: Fix dndupload to match actual style 2013-12-28 09:15:27 +08:00
Andrew Nicols e9ca5e144c MDL-42392 Blocks: Do not hide blocks if JS is disabled
With JS disabled, it is not possible to change the block visibility
user preference and therefore not possible to show content which was
hidden.

Since the block hiding functionality is a nicety, and we have no controls
to show and hide the blocks when JS is disabled, we should instead show the
block content regardless of the user preference.
2013-12-28 08:42:02 +08:00
Petr Škoda be6128fcd5 MDL-36721 do not store passwords in config logs 2013-12-27 11:18:50 +08:00
Petr Škoda 424c3248c7 MDL-43196 do not load file management for guests and when not managing files 2013-12-27 11:12:33 +08:00
AMOS bot 81de3795fa Automatically generated installer lang files 2013-12-25 00:42:49 +00:00
Matteo Scaramuccia f29b93ad61 MDL-43482 Chat Lot of "Only variables should be passed by reference". 2013-12-24 11:06:22 +01:00
Sam Hemelryk e71a5333a3 weekly release 2.6+ 2013-12-24 17:17:49 +13:00
Sam Hemelryk 910dc3393c Merge branch 'install_26_STABLE' of git://git.moodle.org/moodle-install into MOODLE_26_STABLE 2013-12-24 17:17:46 +13:00
Sam Hemelryk 5ac473e356 Merge branch 'wip-MDL-41788_M26_3' of git://github.com/gjb2048/moodle into MOODLE_26_STABLE 2013-12-24 12:52:02 +13:00
Eloy Lafuente (stronk7) 93b6f3c79e Merge branch 'w52_MDL-43314_m26_floats' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2013-12-24 00:46:12 +01:00
Sam Hemelryk 10beedc18f Merge branch 'MDL-41246-moodle26' of git://github.com/StudiUM/moodle into MOODLE_26_STABLE 2013-12-24 11:41:32 +13:00
Sam Hemelryk 83797afa91 Merge branch 'MDL-43438-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2013-12-24 11:23:06 +13:00
Sam Hemelryk d3220e229e Merge branch 'MDL-43250-26' of git://github.com/damyon/moodle into MOODLE_26_STABLE 2013-12-24 10:44:04 +13:00
Sam Hemelryk f2b1768da6 Merge branch 'MDL-43410-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2013-12-24 09:12:47 +13:00
AMOS bot e200f7a382 Automatically generated installer lang files 2013-12-23 12:40:11 +00:00
AMOS bot 2d92ee0ad5 Automatically generated installer lang files 2013-12-23 12:26:27 +00:00
Aaron Barnes a6cf46f473 MDL-43394 behat: Fix checkbox action 2013-12-23 16:00:06 +13:00
Sam Hemelryk 1c5052e29f Merge branch 'MDL-35032-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2013-12-23 15:57:49 +13:00
Andrew Nicols 5c7d7dec73 MDL-43411 JavaScript: Correct checks for section support to use helper function 2013-12-23 09:45:24 +08:00
Sam Hemelryk 61dde025a1 Merge branch 'MDL-30195-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2013-12-23 14:35:07 +13:00
Sam Hemelryk b10fec1750 Merge branch 'w52_MDL-43367_m26_contextpath' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2013-12-23 14:31:50 +13:00
Eloy Lafuente (stronk7) a4c14b94ca Merge branch 'MDL-43318-26' of git://github.com/damyon/moodle into MOODLE_26_STABLE 2013-12-23 00:39:48 +01:00
Sam Hemelryk 072ce9a5e7 MDL-34182 js: fixed typo in ajaxException use 2013-12-23 09:43:16 +13:00
Sam Hemelryk 2347fe5450 Merge branch 'MDL-43325-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE
Conflicts:
	lib/yui/build/moodle-core-notification-dialogue/moodle-core-notification-dialogue-min.js
2013-12-23 08:50:48 +13:00
Sam Hemelryk 43d6e05c24 Merge branch 'MDL-34182-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2013-12-23 08:16:23 +13:00
Petr Škoda b3e24b7f60 MDL-43314 make float serialize consistent on all systems
This should resolve problems with plugin version change detection.
2013-12-22 16:06:52 +08:00
Petr Škoda 2a8d78c00f MDL-43367 stop returning of bogus context children when path unknown
This also prevents deletion of system context.
2013-12-22 16:00:09 +08:00
Tim Hunt 69be43879e MDL-43448 Links to the gradebook not fixed on restore.
Note we can only fix certain generic links, we can't handle ones like
/grade/report/{reportname}/index.php, but fortunately, we were only
using the generic ones.

I added a couple of other likely things too (badges and participants
list).
2013-12-20 12:27:42 +00:00
Damyon Wiese 5d2169e053 weekly release 2.6+ 2013-12-20 11:58:11 +08:00
Damyon Wiese 996c1d5b15 Merge branch 'install_26_STABLE' of git://git.moodle.org/moodle-install into MOODLE_26_STABLE 2013-12-20 11:58:07 +08:00
Damyon Wiese 206b1f6d6d MDL-43318 Assign: Fix bug when editing previous attempt feedback 2013-12-20 11:15:00 +08:00
Gareth J Barnard 997731210c MDL-41788 theme_bootstrapbase: Custom menus - sub-menus breaking. 2013-12-19 12:11:15 +00:00
David Monllao 83e305fa8c MDL-43404 behat: Avoid failures at framework level as much as possible
- Move them to i_look_for_exceptions() so they will be
  thrown at a step (scenario) level.
- Accept alerts only when they are detected to avoid
  all the following scenarios to be failing; they would
  continue executing, but they will all fail if the alert
  is still there
- Add a step to avoid add_scorm.feature to fail
- Refine the UnknownError catch
2013-12-19 16:03:40 +08:00
Frederic Massart 50809576b5 MDL-43454 mod_assignment: Use of undefined constants FILE_* 2013-12-19 07:22:06 +01:00
Eloy Lafuente (stronk7) 2d2faf8087 Revert "MDL-43306 restore: fix grade item sortorder restoration"
This reverts commit 6afd79df8d.
2013-12-19 02:14:03 +01:00
AMOS bot 5f41d7ce6b Automatically generated installer lang files 2013-12-19 00:44:14 +00:00
Jean-Philippe Gaudreau adcddcf776 MDL-41246 cache: Fix PHP notice of non well formed numeric values for the memcache store 2013-12-18 08:52:59 -05:00
Frederic Massart 15d16015b7 MDL-43438 mod_assignment: Prevent double inclusion of plugin files 2013-12-18 09:18:07 +01:00
David Monllao 6acf61d35e MDL-43235 behat: Remove notice about undeclared var 2013-12-18 16:03:29 +08:00
Dan Poltawski 8d7c3b0d50 Merge branch 'MDL-41198-26' of https://github.com/mr-russ/moodle into MOODLE_26_STABLE 2013-12-18 14:59:59 +08:00
Russell Smith 4902bfaf3e MDL-41198 lib: Add comment about the changes to srand on adodb 2013-12-18 16:53:17 +11:00
Russell Smith 9c5c2dbf5a MDL-41198 lib: Allow PHP to generate random seed on script start
Most srand instances are removed to allow PHP to do the work.

srand was left for group randomization due to the method used.
2013-12-18 16:53:10 +11:00
Russell Smith dd7e948dba MDL-41198 lib: Allow PHP to generate random seed on script start
All mt_srand instances are removed to allow PHP to do the work.
2013-12-18 16:53:04 +11:00
Eloy Lafuente (stronk7) ae20e634d7 Merge branch 'MDL-43404_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2013-12-18 02:24:19 +01:00
Russell Smith c25dbc446a MDL-41292 cache: only update identifiers if they change 2013-12-18 02:23:36 +01:00
Sam Hemelryk 12c847fed9 Merge branch 'MDL-43235_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2013-12-18 11:19:26 +13:00
Eloy Lafuente (stronk7) 04b53e0e0c Merge branch 'MDL-43025-26' of git://github.com/damyon/moodle into MOODLE_26_STABLE 2013-12-17 22:59:14 +01:00
Sam Hemelryk 6a8e8ac25e Merge branch 'MDL-43355_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2013-12-18 10:45:02 +13:00
Sam Hemelryk f01cac675a Merge branch 'MDL-43074-26' of git://github.com/damyon/moodle into MOODLE_26_STABLE 2013-12-18 09:58:51 +13:00
Andrew Nicols 6d69cf1045 MDL-43234 JavaScript: Clone dialogue configuration before initialising
Since we modify the config object when instantiating a new Dialogue, we
need to clone the configuration to prevent those changes from being
reflected back in the caller.
2013-12-18 09:53:35 +13:00
Sam Hemelryk 3aa576a8ef Merge branch 'MDL-38698-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2013-12-18 09:21:31 +13:00
David Monllao cc8ba5f12a MDL-43404 behat: Form change checker disabled when running behat 2013-12-17 18:40:13 +08:00
David Monllao 303ea5f34e MDL-43404 behat: Removing auto accept_alert 2013-12-17 18:40:06 +08:00
David Monllao 63e764faba MDL-43423 behat: Running hooks before and after each step of a chained step 2013-12-17 18:14:48 +08:00
Eloy Lafuente (stronk7) e74f735a99 Merge branch 'MDL-43306-26' of git://github.com/danpoltawski/moodle into MOODLE_26_STABLE 2013-12-17 10:29:34 +01:00
Frederic Massart ae5884f8e6 MDL-38698 filter_urltolink: Remove performance test in Unit Test 2013-12-17 07:06:01 +01:00
Frederic Massart 2490febd82 MDL-38698 filter_urltolink: Do not link the URL property of CSS 2013-12-17 07:06:01 +01:00
Marina Glancy df1914d111 Merge branch 'MDL-37679-26' of git://github.com/phalacee/moodle into MOODLE_26_STABLE 2013-12-17 16:37:42 +11:00
Marina Glancy 6e39ee0c82 Merge branch 'wip-MDL-43295-26' of git://github.com/abgreeve/moodle into MOODLE_26_STABLE 2013-12-17 16:36:00 +11:00
Mark Nielsen 13e8736049 MDL-37679 Course: Adding section to page title on section only pages 2013-12-17 11:42:38 +08:00
Adrian Greeve d868e5331c MDL-43295 mod_assign: Removed wrongly used format_text call in online text submission. 2013-12-17 10:44:36 +08:00
Andrew Nicols 829897be3e MDL-43410 JavaScript: Stop event propagation when opening the action menu
In certain situations, the click event is propagated through to the
hideIfOutside and immediately closes the menu.

This happens when blocks are dock for example.
2013-12-17 09:57:58 +08:00
Marina Glancy 20b9e53010 Merge branch 'MDL-41075-26' of git://github.com/mouneyrac/moodle into MOODLE_26_STABLE 2013-12-17 11:24:08 +11:00
Russell Smith 5470f3859f MDL-39725 database: Apply database statistics update to daily stats 2013-12-17 10:26:49 +13:00
Russell Smith 9cd60b20d0 MDL-39725 database: Include stats collections in unit tests 2013-12-17 10:26:48 +13:00
Russell Smith bd8dbfdbc3 MDL-39725 database: Add statistics collection functions
Conflicts:
	lib/dml/moodle_database.php
2013-12-17 10:26:46 +13:00
Sam Hemelryk 21bb4f142c Merge branch 'MDL-25473-26' of git://github.com/phalacee/moodle into MOODLE_26_STABLE 2013-12-17 08:54:22 +13:00
Sam Hemelryk 7809633d79 Merge branch 'MDL-34321-26' of git://github.com/phalacee/moodle into MOODLE_26_STABLE 2013-12-17 08:47:51 +13:00
Sam Hemelryk 7f574aadff Merge branch 'MDL-36984-26' of git://github.com/phalacee/moodle into MOODLE_26_STABLE 2013-12-17 08:44:52 +13:00
Sam Hemelryk 9c099d21eb Merge branch 'w51_MDL-43268_m26_filternotice' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2013-12-17 08:24:52 +13:00
Frederic Massart 8ee06a7b17 MDL-30195 portfolio_googledocs: Allow export of rich HTML 2013-12-16 11:06:57 +01:00
Jerome Mouneyrac 22c5c2f04c MDL-43399 Badge: the Choose... option can still be selected once a role is choosen. 2013-12-16 14:33:45 +08:00
Frederic Massart 83818b0452 MDL-42212 mod_lesson: Use autoloading for mod_lesson_file_info 2013-12-16 07:26:13 +01:00
Frederic Massart e81efe7691 MDL-42212 mod_lesson: Localise area names 2013-12-16 07:26:13 +01:00
Frederic Massart a256d06cfd MDL-42212 mod_lesson: Fix callbacks retrieving activity files 2013-12-16 07:26:13 +01:00
Jerome Mouneyrac ef483684d3 MDL-41075 Remove "Choose..." option from participants page. 2013-12-16 12:08:36 +08:00
Damyon Wiese 147c966a46 MDL-43250 Assign: separate groups mode fix
When in separate groups mode, only get graders in a group that is in the course module grouping.
2013-12-16 10:50:23 +08:00
Sam Hemelryk a3a8490d3a Merge branch 'wip-mdl-21180-m26' of https://github.com/rajeshtaneja/moodle into MOODLE_26_STABLE 2013-12-16 15:43:47 +13:00
Sam Hemelryk e9623e55e3 Merge branch 'MDL-43062-26' of git://github.com/mouneyrac/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-12-16 15:40:25 +13:00
Rajesh Taneja ae1baf9042 MDL-21180 Gradebook: Consistent handling of change in aggregation
Change from/to GRADE_AGGREGATE_WEIGHTED_MEAN and GRADE_AGGREGATE_EXTRACREDIT_MEAN was only
handled prior to this patch. GRADE_AGGREGATE_SUM and GRADE_AGGREGATE_WEIGHTED_MEAN2 also
behave similar and should be handled same way
2013-12-16 09:58:26 +08:00
Marina Glancy be7a37d442 Merge branch 'MDL-37972-26' of git://github.com/phalacee/moodle into MOODLE_26_STABLE 2013-12-16 12:27:59 +11:00
Sam Hemelryk e646b89f8b Merge branch 'wip-MDL-43348_M26' of git://github.com/gjb2048/moodle into MOODLE_26_STABLE 2013-12-16 14:09:52 +13:00
Sam Hemelryk a0f5d96f1e Merge branch 'MDL-40096-26' of git://github.com/damyon/moodle into MOODLE_26_STABLE 2013-12-16 13:52:03 +13:00
Sam Hemelryk 45c0583312 Merge branch 'MDL-40436-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2013-12-16 11:31:13 +13:00
Sam Hemelryk 05a423d850 Merge branch 'w51_MDL-42931_m26_env27' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2013-12-16 11:17:46 +13:00
Sam Hemelryk 12869bfdb1 Merge branch 'MDL-42085-26' of git://github.com/mouneyrac/moodle into MOODLE_26_STABLE 2013-12-16 11:11:26 +13:00
Sam Hemelryk 909f01f17e Merge branch 'MDL-43326-26' of git://github.com/damyon/moodle into MOODLE_26_STABLE 2013-12-16 09:46:32 +13:00
Frederic Massart d8a4219d47 MDL-35032 mod_book: 1.9 backup restore convertis files to book area 2013-12-13 10:26:58 +01:00
David Monllao c56dbe9c28 MDL-43235 behat: Ensure that behat_config_manager::get_config_file_contents() has always a behat_wwwroot 2013-12-13 14:33:52 +08:00
Andrew Nicols d0e04db7fb MDL-34182 Repositories: Check for and warn on invalid output in the file picker 2013-12-13 14:15:10 +08:00
Andrew Nicols 2e96609a93 MDL-34182 AJAX: Change to use shared method when checking the siteadminbranch for invalid output 2013-12-13 14:15:10 +08:00
Andrew Nicols 207f2c8880 MDL-34182: Add functions to warn of output in AJAX scripts
We need to be able to capture output when including contributed code as it
may add additional content which makes makes the json we output invalid.

We only warn of these errors if the site is in debugdeveloper, otherwise
we silently drop them.
2013-12-13 14:15:09 +08:00
Petr Škoda 2f7a48c0a9 MDL-42931 set new requirements for 2.7 2013-12-13 14:06:20 +08:00
Petr Škoda ad2d2f19a3 MDL-43268 fix filter notice when not in debug mode 2013-12-13 13:59:31 +08:00
Jerome Mouneyrac 834f172c77 MDL-43062 course: Content of label is left-aligned, regardless of alignment chosen
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-12-13 13:55:51 +08:00
Sam Hemelryk 8703e6530c weekly release 2.6+ 2013-12-13 16:59:33 +13:00
Sam Hemelryk 40d3bc442f Merge branch 'install_26_STABLE' of git://git.moodle.org/moodle-install into MOODLE_26_STABLE 2013-12-13 16:59:31 +13:00
AMOS bot 3c790ba117 Automatically generated installer lang files 2013-12-13 00:42:12 +00:00
Gareth J Barnard f10d0d2745 MDL-43348 theme: html <nav> element on the wrong content. 2013-12-12 16:14:50 +00:00
David Monllao 668505a9e4 MDL-42625 behat: Wrapping select an option extra actions in a try & catch
To select an option is specially painful, every browser
behaves differently and phantomjs just joined the party
throwing "Element does not exist in cache" random
exceptions that we need to catch.
2013-12-12 12:20:34 +01:00
David Monllao b1915ed987 MDL-43355 testing: Return the hash when HEAD points to a hash 2013-12-12 17:39:37 +08:00
Andrew Nicols bccff20039 MDL-43325 JavaScript: Set a default visibility for most Moodle dialogues
We used to ignore the 'visible' field in the initializer, but now we hide
dialogues if visible is false. This was an unintentional change from the
stable API and means that confirmation boxes, alerts, and exceptions are no
longer shown by default.
2013-12-12 16:21:30 +08:00
Frederic Massart 736ce96319 MDL-40436 block_course_list: Fix bad context resolution
We were trying to get the course context of a remote course
from a completely unrelated ID. It would sometimes work if the
ID was matching the one of a local course. In other places
we are not trying to find a context for the remote course, we
simply use the $PAGE context in format_string. So the usage
of the context has been removed here too.
2013-12-12 09:10:45 +01:00
Jerome Mouneyrac 4a6fb4a2ca MDL-42085 Enrol: Always apply enrolment duration.
Before the fix, the startdates and duration fields were integrated to HTML code only
when the user clicked on the collapsible region to see them.
It was wrong because their values were not sent by the form
if ever the user didn't expand this Enrolment options region.
2013-12-12 16:07:33 +08:00
Jason Fowler d06e9d3bef MDL-36984 Assign: Add redirect after saving grades 2013-12-12 14:19:51 +08:00
Marina Glancy 06805cb54f Merge branch 'MDL-42625_26-failures-fix' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2013-12-12 16:51:05 +11:00
David Monllao fff8b97ebc MDL-42625 behat: Fixing failures
* Expanding fieldsets before setting the course format
* Ensure editors are loaded moved to expand_all_fieldsets
* Return true rather than false when JS is disabled and
  non-allowed steps should continue without throwing an
  exception.
2013-12-12 13:42:56 +08:00
Marina Glancy 26023575ba Merge branch 'mucupdates26' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2013-12-12 15:39:51 +11:00
Petr Škoda 1a815ef7d4 MDL-42973 fix MUC caching issue when fetching available updates 2013-12-12 11:36:36 +08:00
Jason Fowler 9fc09121a8 MDL-34321 Assignment2.2 - Fixing submission count 2013-12-12 10:36:08 +08:00
Eloy Lafuente (stronk7) 26f9407892 MDL-31410 paypal: fix problem on notifications
This commit fixes a PHP warning about using a
unititialised variable and also the problems when
notifications are enabled and there is not yet a
teacher in the course, defaulting to admin for student
notifications and preventing teacher notifications to happen.
2013-12-12 02:22:23 +01:00
Eloy Lafuente (stronk7) 4701b68a51 Merge branch 'w50_MDL-31410_m26_paypalipn' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2013-12-12 01:16:38 +01:00
David Monllao a80eba9500 MDL-42625 behat: Fixing ExpectationException::__construct() call
Also adding an extra checking to the selector to
ensure it is no updating the list of files.
2013-12-11 10:26:58 +01:00
Damyon Wiese 1ac6fd0322 MDL-43326 Assign: Start new attempt from previous missing sesskey 2013-12-11 13:11:26 +08:00
Marina Glancy 1562e8d3eb MDL-43218 blog: prepare the blog navigation only when needed 2013-12-11 15:37:36 +13:00
Simon Coggins 139a8556e8 MDL-43218 navigation: Remove link to blogs when they are disabled 2013-12-11 15:37:36 +13:00
Marina Glancy 856be66774 Merge branch 'MDL-43071-MOODLE_26_STABLE' of https://github.com/lucisgit/moodle into MOODLE_26_STABLE 2013-12-11 12:47:00 +11:00
Eloy Lafuente (stronk7) 3675c98506 Merge branch 'MDL-42625_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2013-12-10 23:31:51 +01:00
sam marshall 43ed2ccbf2 MDL-42815 Backup/restore: Error saving files - log messages unhelpful
This commit contains three changes in the three files:
1. A bug in the backup process meant that anything logged after a
   certain point did not appear in the on-screen display of the
   backup log, because the logger was serialised and deserialised
   but display code referred to the old version. Changed so that
   code retrieves new object.
2. Add more information to backup log when there is a missing file.
3. Add more information to restore log when there is a missing file
   (and remove existing code duplication of the current message).

The 'missing file' situation is one that generally shouldn't occur in
normal usage, but when it does happen, it is useful to have full
information about the file.
2013-12-10 23:25:19 +01:00
Sam Hemelryk 5fbc32ebdb Merge branch 'MDL-42796-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2013-12-11 11:12:55 +13:00
Sam Hemelryk 9f00dabf86 Merge branch 'MDL-43252-m26' of git://github.com/sammarshallou/moodle into MOODLE_26_STABLE 2013-12-11 11:03:23 +13:00
Sam Hemelryk 51d311f703 Merge branch 'wip-MDL-43279-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2013-12-11 10:58:49 +13:00
Sam Hemelryk 3ef86b3909 Merge branch 'w50_MDL-31625_m26_replace' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2013-12-11 10:51:21 +13:00
Eloy Lafuente (stronk7) 6085ca703d Merge branch 'wip-MDL-43150-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2013-12-10 22:47:29 +01:00
Sam Hemelryk bdb2677b79 Merge branch 'MDL-42959-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2013-12-11 10:34:04 +13:00
Eloy Lafuente (stronk7) 8a630a771c Merge branch 'wip-MDL-42174-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2013-12-10 22:13:17 +01:00
Eloy Lafuente (stronk7) 409e4794d7 Merge branch '26STABLE-wip-MDL-43135' of https://github.com/jennymgray/moodle into MOODLE_26_STABLE 2013-12-10 19:46:31 +01:00
Jenny Gray 30ce0cd396 MDL-43135 Guest Enrol: new language string for with key icon
AMOS BEGIN
CPY [pluginname,enrol_guest], [guestaccess_withpassword,enrol_guest]
CPY [pluginname,enrol_guest], [guestaccess_withoutpassword,enrol_guest]
AMOS END
2013-12-10 11:19:50 +00:00
Sam Chaffee e5a0c16bd3 MDL-37972 Assignment: fixing settings link for upload single submissions 2013-12-10 14:09:16 +08:00
Dan Poltawski 6afd79df8d MDL-43306 restore: fix grade item sortorder restoration
Previously, restore was blindly inserting the old sort order into the
database, causing duplicate sortorders which lead to unpredicatble
sorting results.

Now we will use the api function to add it after the original sortorder,
this means if a duplicate exists in the original location, this item
will appear after it.
2013-12-10 12:34:08 +08:00
Marina Glancy 9f2e956580 Merge branch 'MDL-43199-26' of git://github.com/damyon/moodle into MOODLE_26_STABLE 2013-12-10 15:16:08 +11:00
Marina Glancy 4bc1b2151e Merge branch 'm26_MDL-43082_IE9_Compat_View_SVG_Say_No' of https://github.com/scara/moodle into MOODLE_26_STABLE 2013-12-10 14:47:52 +11:00
Michael Dikih 79f0a612c4 MDL-43109: mod/wiki - When editing pages populate the default value for the tags input. 2013-12-10 14:17:17 +10:30
Marina Glancy 66a437aca8 Merge branch 'MDL-43215_m26' of https://github.com/markn86/moodle into MOODLE_26_STABLE 2013-12-10 14:26:14 +11:00
Marina Glancy 3b70fdaaf3 Merge branch 'MDL-43131_26' of git://github.com/timhunt/moodle into MOODLE_26_STABLE 2013-12-10 14:10:29 +11:00
Marina Glancy 08f6d5de07 Merge branch 'mdl42487-moodle26' of https://github.com/tlock/moodle into MOODLE_26_STABLE 2013-12-10 13:57:20 +11:00
Jason Fowler 39d505664e MDL-25473 mediaplayer - prevent embedded videos from looping 2013-12-10 10:47:47 +08:00
Marina Glancy 286348d97f MDL-43279 block_blog_recent: fixed undefined property notice 2013-12-10 09:28:40 +11:00
Sam Hemelryk e5bb9741b6 Merge branch 'MDL-43164-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2013-12-10 09:50:27 +13:00
Sam Hemelryk c7f545bbb0 Merge branch 'm26_MDL-43159_Wrong_Naming_Convention_For_Variable' of https://github.com/scara/moodle into MOODLE_26_STABLE 2013-12-10 09:20:33 +13:00
Sam Hemelryk b2a803d5d1 Merge branch 'MDL-43194-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2013-12-10 08:48:04 +13:00
Sam Hemelryk 8eb717f993 Merge branch 'MDL-43152-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2013-12-10 08:43:36 +13:00
Eloy Lafuente (stronk7) f37e3f357d Merge branch 'MDL-40003-26' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2013-12-09 16:24:35 +01:00
sam marshall b1b09903b0 MDL-43252 Group menu in wrong order when groupings used 2013-12-09 13:02:43 +00:00
Sam Chaffee 2470b6ea89 MDL-40003 mod_assign: Fixed submission comments not being restored 2013-12-09 11:04:39 +01:00
Marina Glancy cc2aca7c23 Merge branch 'wip-MDL-43175-26' of git://github.com/abgreeve/moodle into MOODLE_26_STABLE 2013-12-09 18:56:15 +11:00
Marina Glancy d66fe9c1aa Merge branch 'wip-mdl-43224-m26' of https://github.com/rajeshtaneja/moodle into MOODLE_26_STABLE 2013-12-09 18:46:36 +11:00
Marina Glancy 6203fc19f2 Merge branch 'w50_MDL-42973_m26_addonupd' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2013-12-09 18:28:35 +11:00
Marina Glancy 64c03072a9 Merge branch 'MDL-43092_M26' of git://github.com/lazydaisy/moodle into MOODLE_26_STABLE 2013-12-09 17:50:53 +11:00
Marina Glancy 780dc00ce5 Merge branch 'w50_MDL-43137_m26_openbasedir' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2013-12-09 16:15:59 +11:00
Damyon Wiese 75ceca0bf5 MDL-43025 EditPDF: Increase memory limit when reading source pdfs. 2013-12-09 12:53:29 +08:00
David Monllao db13e21956 MDL-42625 behat: Make behat pacient
* When looking for texts inside the page or inside
  other containers we should wait until the elements
  are visible.
* Same when expanding tree nodes.
* Normalizing loops to spin() function using
  behat_base::TIMEOUT and behat_base::EXTENDED_TIMEOUT,
  leaving TIMEOUT for DOM load processes and
  EXTENDED_TIMEOUT for long processes that involves JS
  too.
* Add page load waits between actions that involves
  reloading the page.
2013-12-09 11:11:48 +08:00
Damyon Wiese 42515a2e58 MDL-43074 assignfeedback_editpdf: Use escapeshellarg for all args in exec command.
This is to fix a reported problem with windows compatibility (e.g. when ghostscript is installed in
a folder with spaces in the name).
2013-12-09 11:00:13 +08:00
Damyon Wiese ced275af37 MDL-40096 assign: Prevent js error because uniqid() is not unique.
Use html_writer::random_id instead because it incorporates a static counter.
2013-12-09 10:26:05 +08:00
Andrew Nicols 6eb703ad69 MDL-42959 JavaScript: Backport fix from https://github.com/yui/yui3/pull/1465 2013-12-09 10:25:33 +08:00
Marina Glancy c4bc562172 Merge branch 'm26_MDL-43192' of https://github.com/danmarsden/moodle into MOODLE_26_STABLE 2013-12-09 11:28:32 +11:00
Gareth J Barnard 45d1c530d2 MDL-40213 theme_clean: Layout "secure.php" missing settings. 2013-12-09 11:14:07 +11:00
Andrew Nicols e6caeefe0c MDL-42796 ActionMenu: Add additional keyboard event handling
Add additional handling for up/down/escape key presses and consolidate them
with the existing tab/shift+tab handling.
2013-12-06 16:21:13 +08:00
Andrew Nicols b8351f4c24 MDL-42796 ActionMenu: Move event handlers to showMenu 2013-12-06 16:20:49 +08:00
Damyon Wiese fb64bae5e2 MDL-42625 TinyMCE: Hook into API to track the progress of the init script 2013-12-06 15:53:58 +08:00
David Monllao 9f8ef4294a MDL-42625 behat: Step definitions + related changes in features
In general aiming for compatibility with multiple browsers,
firefox, chrome and phantomjs to be more specific.

* Removing hardcoded waits
* Adding @_alert, @_switch_window and @_switch_frame tags,
  to label actions that different drivers have problems with.
* Adding missing @_files_upload and @_only_local tags to features that
  uploads files.
* Fixing a few wait for page ready what specified miliseconds.
* New methods to ensure elements (usual selectors), sections and editors
  are ready to interact with
* Changing the select an option implementation to deal with the different
  drivers implementations when listening to JS events.
2013-12-06 15:53:55 +08:00
David Monllao 503c8dddcc MDL-42625 behat: Editing .feature files 2013-12-06 15:53:50 +08:00
Andrew Nicols 40daab14a4 MDL-41030 JavaScript: Convert remaining YUI2 IO calls to YUI3 2013-12-06 15:53:47 +08:00
Damyon Wiese 01426638cb MDL-41030 Behat: Add support for waiting for javascript
This is so that phantomjs (which runs faster than selenium) can pass the tests.
2013-12-06 15:53:40 +08:00
David Monllao f5940bfb5f MDL-41030 behat: Dock blocks compatible with both selenium and phantomjs 2013-12-06 15:53:38 +08:00
Marina Glancy ae3dd7efdb MDL-42174 behat: change word filepicker to filemanager in step definitions 2013-12-06 17:31:58 +11:00
Marina Glancy 35c2c697ce MDL-42174 behat: replace word filepicker with filemanager in file upload step 2013-12-06 17:31:58 +11:00
Marina Glancy 4ec1b7b094 MDL-42174 More behat tests for filepicker 2013-12-06 17:31:55 +11:00
Pavel Sokolov a2afdf4691 MDL-43199 assign: fix js error when expanding comments for non editing teachers in assign grading table 2013-12-06 12:58:18 +08:00
Rajesh Taneja 738e1d3556 MDL-43224 navigation: Load local plugin navigation in site admin via ajax
Local plugin can add navigation nodes to site admin and while loading
site admin via ajax this should be considered.
2013-12-06 10:28:42 +08:00
Petr Škoda c673cdfee7 MDL-31410 always send 200 in PayPal IPN response and hide all errors 2013-12-06 10:02:43 +08:00
Petr Škoda b4d2e7f267 MDL-31625 fix multiple global search-replace issues
Includes following fixes:
* support for MS SQL Server
* optional trimming of of oversized VARCHAR fields
* conversion to forms library
* full localisation
* other cleanup
2013-12-06 09:52:47 +08:00
Petr Škoda 4bc526cc8a MDL-42973 fix multiple addon update issues 2013-12-06 09:37:28 +08:00
Petr Škoda 7ed7cabf5f MDL-43137 fix open_basedir regression in classloader 2013-12-06 09:30:08 +08:00
Andrew Nicols d33dffe53a MDL-43152 JavaScript: Add update instructions for gallery-bootstrap 2013-12-06 09:20:05 +08:00
Andrew Nicols 19b1ff816f MDL-43152 JavaScript: Fix linting issues with moodle-theme_bootstrapbase 2013-12-06 09:20:02 +08:00
Andrew Nicols 40f2d64856 MDL-43152 JavaScript: Fix linting issues with moodle-core-blocks 2013-12-06 09:19:58 +08:00
Andrew Nicols d6c8107249 MDL-43152 JavaScript: Fix linting issue with navigation JS 2013-12-06 09:09:01 +08:00
Matteo Scaramuccia fcf15debfc MDL-43159 Libraries Wrong naming convention in $compat_view. 2013-12-05 16:08:14 +01:00
Matteo Scaramuccia eadcc99eea MDL-43082 Themes IE 9 Compatibility View doesn't support SVG. 2013-12-05 15:57:00 +01:00
Tim Hunt 102fe39706 MDL-43131 qbank: Fix show question text when first viewing.
When you followed the link to the question bank, the checkbox for the
"Show question text in the question list" option correctly reflected the
user's preference, but what was actually shown in the question bank did
not.
2013-12-05 11:06:46 +00:00
Dan Poltawski 3e6e38b2e3 weekly release 2.6+ 2013-12-05 15:10:16 +08:00
Dan Poltawski d04814641b Merge branch 'install_26_STABLE' of git://git.moodle.org/moodle-install into MOODLE_26_STABLE 2013-12-05 15:10:13 +08:00
Mark Nelson b4d09c2db0 MDL-43215 core_webservice: retrieve all user name fields when adding a token 2013-12-04 20:57:24 -08:00
David Monllao 2fc28aa794 MDL-41592 behat: Setting a default value for CFG->behat_wwwroot in case it is empty 2013-12-05 17:06:18 +13:00
Adrian Greeve c5f2967a64 MDL-43175 events: Base event unit tests for JSON encoding / decoding comparison. 2013-12-05 10:03:51 +08:00
Adrian Greeve 9a7713304c MDL-43175 events: Changed JSON encoding decoding comparison to be less strict.
Debugging messages would be sent when other contained a float that is a whole number.
When encoding and decoding using JSON the number is changed to an integer and the
comparison fails.
2013-12-05 10:03:37 +08:00
Frederic Massart 85c39e437b MDL-43185 behat: Use realpath on existing paths 2013-12-05 08:18:05 +13:00
Andrew Nicols e37014fafb MDL-43194 JavaScript: Correct maxlen jshint configuration 2013-12-04 16:40:21 +08:00
Dan Marsden 77492a3e62 MDL-43192 Repository: param doesn't exist - should use function 2013-12-04 20:57:32 +13:00
Dan Poltawski b01548ecba Merge branch 'wip-MDL-40191-2-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2013-12-04 15:44:08 +08:00
Marina Glancy dd75bf89ff MDL-40191 folder: Do not check capability in renderer
Capability to access the module is already checked before calling the renderer. Extra check works bad together with switching roles
2013-12-04 18:30:09 +11:00
Dan Poltawski 307d961277 Merge branch 'wip-mdl-43028-m26' of https://github.com/rajeshtaneja/moodle into MOODLE_26_STABLE 2013-12-04 15:06:30 +08:00
Rajesh Taneja bc7ac30669 MDL-43028 navigation: fixed section for profilepage
section for profile page is profilepage and not mypage
2013-12-04 14:50:35 +08:00
Tim Lock 56dc43f3d2 MDL-34020: Further work on IMS package importing when using Blackboard packages 2013-12-04 15:18:13 +10:30
Tomasz Muras fa4e8ee5c9 MDL-42563 Correct version of GPL license to GPL 2+ for AlgParser.pm 2013-12-04 11:30:57 +08:00
Tomasz Muras efdb216ca9 MDL-42563 Add thirdpartylibs.xml for AlgParser.pm. 2013-12-04 11:30:43 +08:00
Jason Fowler 62f68371df MDL-43084 Themes: fixing dialog header in standard theme 2013-12-04 15:32:31 +13:00
Jason Fowler 3690a9db9f MDL-43083 Course: Swapping the edit/cog for the right size icon 2013-12-04 09:53:42 +08:00
AMOS bot 952292945c Automatically generated installer lang files 2013-12-04 00:43:13 +00:00
Eloy Lafuente (stronk7) ac184c9db2 Merge branch 'MDL-41446-master' of git://github.com/sammarshallou/moodle into MOODLE_26_STABLE 2013-12-03 23:55:49 +01:00
Sam Hemelryk 8e60097af8 Merge branch 'MDL-41592_26' of https://github.com/dmonllao/moodle into MOODLE_26_STABLE 2013-12-04 11:52:18 +13:00
Eloy Lafuente (stronk7) 786f04f485 Merge branch 'MDL-43142_m26' of https://github.com/markn86/moodle into MOODLE_26_STABLE 2013-12-03 23:41:24 +01:00
Eloy Lafuente (stronk7) 310cf52b37 Merge branch 'MDL-43140_m26' of https://github.com/markn86/moodle into MOODLE_26_STABLE 2013-12-03 23:25:33 +01:00
Tim Hunt 3893b5fa32 MDL-43093 update repeat_elements PHPdoc. 2013-12-04 10:12:25 +13:00
Sam Hemelryk f5a134213d Merge branch 'MDL-43065-26' of git://github.com/damyon/moodle into MOODLE_26_STABLE
Conflicts:
	backup/util/ui/base_moodleform.class.php
2013-12-04 09:43:24 +13:00
Sam Hemelryk 7ac9576825 Merge branch 'MDL-42919-26' of git://github.com/damyon/moodle into MOODLE_26_STABLE 2013-12-04 09:42:34 +13:00
Eloy Lafuente (stronk7) b5036ee20c Merge branch 'wip-MDL-43058-26' of git://github.com/abgreeve/moodle into MOODLE_26_STABLE 2013-12-03 19:33:30 +01:00
Eloy Lafuente (stronk7) 1abaa0c22e Merge branch 'MDL-43105-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2013-12-03 19:16:08 +01:00
Eloy Lafuente (stronk7) 9a734d1862 Merge branch 'moodle26-mdl33971' of https://github.com/tlock/moodle into MOODLE_26_STABLE 2013-12-03 17:18:02 +01:00
Mary Evans a108795999 MDL-43092 theme_afterburner: Activity or Resource dialog greyed-out for non-empty courses 2013-12-03 15:04:02 +00:00
James Pratt 7ef639c709 MDL-43079 quiz statistics : fix stats graph when all grades zero 2013-12-03 15:39:09 +01:00
Damyon Wiese cb891e57f0 Merge branch 'wip-MDL-42731-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2013-12-03 17:29:57 +08:00
Eloy Lafuente (stronk7) b470112643 Merge branch 'MDL-42885_m26' of https://github.com/markn86/moodle into MOODLE_26_STABLE 2013-12-03 10:01:43 +01:00
Damyon Wiese 4e14b95f0e Merge branch 'MDL-42627_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2013-12-03 16:29:39 +08:00
Damyon Wiese 4d32c0c6d0 Merge branch 'wip-MDL-43026-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2013-12-03 16:12:08 +08:00
Dan Poltawski 0e44ba37cf Merge branch 'moodle26-mdl43020' of https://github.com/tlock/moodle into MOODLE_26_STABLE 2013-12-03 16:08:22 +08:00
Andrew Nicols 5259c6b402 MDL-42989 JavaScript: Check result of navigation IO requests before reporting errors
When making a request which fails, we need to ensure that the AJAX query
was not aborted before displaying the error.

This ensures that if the navigation tree is being requested at the same
time as a page load is being processed, the abortion of the AJAX request is
not displayed before the page reloads.
2013-12-03 16:05:18 +08:00
Andrew Nicols ed52eb4c88 MDL-42989 JavaScript: Do not attempt to expand navigation when opening link
When clicking on a link which is also expandable, we should not attempt to
expand it.
2013-12-03 16:05:09 +08:00
Dan Poltawski 77325154af Merge branch 'wip-mdl-43028-m26' of https://github.com/rajeshtaneja/moodle into MOODLE_26_STABLE 2013-12-03 13:46:26 +08:00
Jason Fowler b136969308 MDL-43076 Activity Chooser: Fixing the white bar at the bottom of the dialogue
Conflicts:

	theme/bootstrapbase/style/moodle.css
2013-12-03 13:30:15 +08:00
Dan Poltawski 47d9d4cd00 MDL-43081 upgrade.txt: note generator change
Conflicts:

	lib/upgrade.txt
2013-12-03 13:04:26 +08:00
Dan Poltawski 61ae30255c Merge branch 'MDL-43066_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2013-12-03 12:36:52 +08:00
Damyon Wiese e2a2209ed6 Merge branch 'wip-mdl-43048-m26' of https://github.com/rajeshtaneja/moodle into MOODLE_26_STABLE 2013-12-03 11:43:53 +08:00
Damyon Wiese 1cf504414d Merge branch 'wip-mdl-42904-m26' of https://github.com/rajeshtaneja/moodle into MOODLE_26_STABLE
Conflicts:
	enrol/self/db/upgrade.php
2013-12-03 11:25:36 +08:00
Andrew Nicols 2d6dfcde3e MDL-43164 JavaScript: Use the up/down move icon for non-AJAX courses
When a course format does not support AJAX, or AJAX is disabled at the site
level, we should revert back to the old-style move icon.

This helps to clarify that you cannot drag/drop the icon, but must click
instead.
2013-12-03 10:49:42 +08:00
Sam Hemelryk 1cb0536bcb Merge branch 'w48_MDL-41819_m26_maxinputvars' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2013-12-03 09:58:10 +13:00
Michael Aherne 217c5d8208 MDL-42495 lesson Prevent coding error for invalid user 2013-12-02 10:53:20 +00:00
Dan Poltawski d8be1d9ac5 Merge branch 'MDL-42989-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2013-12-02 14:53:37 +08:00
Damyon Wiese 88c5d93aa1 Merge branch 'm26_MDL-43039_SessionDiskFull_False_Positive' of https://github.com/scara/moodle into MOODLE_26_STABLE 2013-12-02 14:37:03 +08:00
Andrew Nicols cbb87c9568 MDL-42989 Admin: Clean output when building site administration tree for JS
Previously, any inappropriate whitespace found whilst building the admin
tree caused a JSON error and for the site administration tree retrieval to
fail.

This change ensures that access to the site administration tree is unbroken
for non-developers, whilst still alerting developers that there is an
issue.
2013-12-02 14:34:11 +08:00
Jerome Mouneyrac 7d2f938cf0 MDL-42969 Main Menu Block loses ability to move resource or activity up or down (add back exact same behavior than in 2.5) 2013-12-02 14:24:16 +08:00
David Monllao eb1931ccd1 MDL-41592 general: Also checking the site path 2013-12-02 14:19:25 +08:00
David Monllao 5f717f7aac MDL-41592 behat: Config settings more flexible
Adding the option to just set ->behat_wwwroot to
allow switching to the behat test site.
2013-12-02 14:19:25 +08:00
Aaron Barnes 64c5119637 MDL-41592 behat: Allow alt wwwroot to be set for acceptance testing
To set add $CFG->behat_wwwroot = 'http://alturl'; in your config.php
2013-12-02 14:19:25 +08:00
David Monllao dad1bc64c5 MDL-42627 behat: Replacing calls to deprecated step
Switching to the selector-based ..in the "LOCATOR" "table_row"
2013-12-02 14:13:49 +08:00
David Monllao 812fa23e82 MDL-43066 behat: Checking that the site is not already installed 2013-12-02 14:11:33 +08:00
Damyon Wiese fe0d1d488b MDL-43018 Fix unit tests for minify changes. 2013-12-02 12:52:43 +08:00
Dan Poltawski d76bc30606 Merge branch 'w49_MDL-43106_m26_doublecookie' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2013-12-02 11:58:23 +08:00
Damyon Wiese 39177fd3a7 Merge branch 'MDL-43018-26' of git://github.com/andrewnicols/moodle into MOODLE_26_STABLE 2013-12-02 11:23:23 +08:00
Dan Poltawski 0c94afe7af Merge branch 'wip-MDL-40191-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2013-12-02 11:19:45 +08:00
Tim Hunt b14196043d MDL-43068 course&gradebook: show/hide cm & CONTROLS_GRADE_VISIBILITY
Making a quiz visible on the course page, of via the settings form,
could cause the grade item to become visible in the gradebook, even
though the quiz supports FEATURE_CONTROLS_GRADE_VISIBILITY to ensure
that when the grades are hidden in the quiz settings, they do not appear
in the gradebook.

Now, if a module supports FEATURE_CONTROLS_GRADE_VISIBILITY, then
set_coursemodule_visible calls the _grade_item_update callback to update
the grade item(s).

In addition, there was a bug when saving the quiz form, where it used
the value of $cm->visible from the database, which was wrong if the
value of cm->visible had just been changed on the setting form.
2013-12-02 11:12:53 +08:00
Damyon Wiese 2f6a01e094 Merge branch '43033-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE 2013-12-02 09:51:08 +08:00
Jerome Mouneyrac c68fa5fcbb MDL-42876 Screen reader does not trigger the keyboard move 2013-12-02 14:07:28 +13:00
Marina Glancy 4f7ec48046 MDL-43150 tinymce_managefiles: fixed unattractive background 2013-12-02 12:02:04 +11:00
AMOS bot fe0f1f5c19 Automatically generated installer lang files 2013-12-02 00:42:53 +00:00
Sam Hemelryk f098ca6d97 Merge branch 'MDL-42918_m26' of git://github.com/rwijaya/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-12-02 13:39:51 +13:00
Petr Škoda 8aac99eb3d MDL-41819 try to work around max_input_vars restriction 2013-12-02 08:29:41 +08:00
Marina Glancy 1affdad829 MDL-40191 navigation: do not throw an error if activity is not visible
navigationlib is not the place to check it, let the page itself decide what to do in this case
2013-12-02 10:48:38 +11:00
Marina Glancy f497fd1de8 MDL-43026 behat: add tests for all available module generators 2013-12-02 10:38:29 +11:00
Marina Glancy 0a44a45fea MDL-42731 block_activity_modules: added behat tests 2013-12-02 10:15:52 +11:00
Marina Glancy fdc93e4092 MDL-42731 behat: load 'Site administration' when expanding node in non-javascript mode 2013-12-02 10:15:33 +11:00
Frederic Massart add7675e51 MDL-42951 curl: Re-organise Unit Tests in smaller chunks 2013-12-02 10:55:57 +13:00
Frederic Massart 20f8cd8551 MDL-42951 curl: Always keep the last headers of a request 2013-12-02 10:55:57 +13:00
Sam Hemelryk 7ac884d457 MDL-43033 cache: added stats logging to set_many methods 2013-12-02 09:29:44 +13:00
Sam Hemelryk 4bbbd50202 MDL-43033 cache: fixed display of definition stores in admin interface 2013-12-02 09:29:44 +13:00
Sam Hemelryk e6175024e6 MDL-43033 cache: added a warning icon for mappings
We now show a warning icon with an explanatory alt if the user
has mapped a store as a mode default that doesn't not fulfill the
requirements of every known definition.
2013-12-02 09:29:44 +13:00
Sam Hemelryk c21a04f63e MDL-43033 cache: fixed mode map event invalidation scenario 2013-12-02 09:29:44 +13:00
Sam Hemelryk ad3bbeb5c0 MDL-43033 cache: added stats logging to get_many methods 2013-12-02 09:29:44 +13:00
Matteo Scaramuccia 18d2aac902 MDL-43039 Libraries "The session partition is full." false positive. 2013-11-30 14:35:31 +01:00
Mark Nelson 5546df9078 MDL-43140 mnet: display header after redirects to avoid warning 2013-11-29 14:26:08 -08:00
Mark Nelson d0e29366de MDL-43142 mnet: fixed typo in variable passed to get_string 2013-11-29 14:15:24 -08:00
Petr Škoda 78da7d9529 MDL-43106 fix double cookies on first access 2013-11-29 15:47:52 +08:00
Dan Poltawski ea04def291 weekly release 2.6+ 2013-11-29 12:52:56 +08:00
Dan Poltawski 6ba3f5d72a Merge branch 'install_26_STABLE' of git://git.moodle.org/moodle-install into MOODLE_26_STABLE 2013-11-29 12:52:52 +08:00
Tim Lock 2153633aac MDL-42487: Forced userprofile dl style to be displayed: inline-block. 2013-11-29 09:26:52 +10:30
Eloy Lafuente (stronk7) d6ece9f7f0 Merge branch 'MDL-42957-26' of https://github.com/jamiepratt/moodle into MOODLE_26_STABLE 2013-11-28 12:44:13 +01:00
James Pratt a69c78724e MDL-42957 (3) quiz statistics : removing assertEquals(time(), ..) tests 2013-11-28 17:59:05 +07:00
James Pratt 7968f77edb MDL-42957 (2) quiz statistics : Hardcoded sql LIMIT clause
Fixing some typos and adding some tests.
2013-11-28 17:35:39 +07:00
AMOS bot 6d7583c9b2 Automatically generated installer lang files 2013-11-28 09:12:40 +00:00
Andrew Nicols 6dae822543 MDL-43105 JavaScript: Use the correct versions of our rollups 2013-11-28 12:32:18 +08:00
Andrew Nicols 451044df4e MDL-43018 JavaScript: Correct joining of multiple minified JS
When minifiying JS, unnecessary semi-colons are removed - this includes the
trailing semi-colon.

Since we join multiple files together after minification, we need to add an
additional semi-colon in this situation to produce valid JavaScript.
2013-11-28 11:54:53 +08:00
Adrian Greeve 9daaa37aac MDL-43058 reports: updated sql to return fullnames in security check reports. 2013-11-27 14:57:11 +08:00
Rajesh Taneja 1880d3684c MDL-43048 block_tags: Initalised content->text for tags block 2013-11-27 14:37:07 +08:00
Mark Nelson dcef51b614 MDL-42885 tool_uploaduser: removed misleading debugging message 2013-11-26 21:26:23 -08:00
Dan Poltawski 66d40a5dae MDL-42942 behat: increment version 2013-11-27 11:37:32 +08:00
Dan Poltawski 9e56dabab6 Merge branch 'MDL-42942_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2013-11-27 11:37:25 +08:00
Marina Glancy 168e14feee MDL-42508 folder: add module generator 2013-11-27 12:36:12 +13:00
Marina Glancy 137778af00 MDL-42508 imspcp: add module generator 2013-11-27 12:36:11 +13:00
Marina Glancy d4d848343b MDL-42508 scorm: add module generator 2013-11-27 12:36:11 +13:00
Tim Lock 7f3fca8ff1 MDL-33971: When viewing course log entries for Quiz View Summary a number is displayed not the quiz name 2013-11-27 08:14:04 +10:30
Eloy Lafuente (stronk7) a01d727a31 Merge branch 'm26_MDL-43045' of git://github.com/totara/moodle into MOODLE_26_STABLE 2013-11-26 21:28:25 +01:00
Ruslan Kabalin d149d894a0 MDL-43071 assign: Fix offline grades import for scale grading. 2013-11-26 16:44:41 +00:00
rwijaya 4c1ac80799 MDL-42918: fixed fullscreen width for multichoice answers editor 2013-11-26 18:34:55 +08:00
Damyon Wiese 1e9c117f50 Merge branch 'wip-MDL-43008-26' of git://github.com/abgreeve/moodle into MOODLE_26_STABLE 2013-11-26 16:59:04 +08:00
Adrian Greeve 55b02e02e6 MDL-43008 calendar: Allow calendar plugins to display setting pages. 2013-11-26 15:50:31 +08:00
Tim Hunt cead41882b MDL-43000 shortanswer qtype: handle patterns with many *s
Teachers were typing patterns like
********************************<em>****************************</em>
which translates into a pattern like .*.*.*.*, which is very inefficient
to try to match, althought it is equivalent ot a single .*. At a certain
point preg was just giving up.

Since people actually do this, we should simplify the regex by treating
runs of * like a single *.
2013-11-26 15:06:15 +08:00
Dan Poltawski 44e5ac93bc Merge branch 'MDL-40741_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2013-11-26 14:57:15 +08:00
Damyon Wiese b451ddf416 MDL-43065 Backup: Prevent any responsiveness in backup/restore forms
Adding 'unresponsive' class to any moodle form will prevent the default
collapsing on screens < 1200px.
2013-11-26 14:50:21 +08:00
Dan Poltawski 46d1d519f8 Merge branch 'MDL-42851_m26' of git://github.com/rwijaya/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-11-26 14:48:38 +08:00
Damyon Wiese c18fe9ec19 MDL-42919 Question: Remove &#160; from empty labels
This allows the form elements with empty labels to "fold" properly.
2013-11-26 13:32:46 +08:00
Damyon Wiese f5af9b62e8 MDL-41919 Forms: Add a class to form elements with an empty label
This means they can be styled properly when the form is folded with
the labels above the form fields.
2013-11-26 13:32:11 +08:00
Dan Poltawski ace15cee6d Merge branch 'wip-MDL-43006-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2013-11-26 13:24:41 +08:00
David Monllao addedcb142 MDL-40741 behat: Changing xpaths for clean theme
Keeps compatibility with standard theme.
2013-11-26 13:00:24 +08:00
Dan Poltawski e55207d9d7 Merge branch 'MDL-42733_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2013-11-26 12:09:47 +08:00
Tim Lock 4743fdf290 MDL-42998: Fix user selection search options autoselectunique. 2013-11-26 10:50:17 +08:00
Dan Poltawski 5ffad8a406 Merge branch 'MDL-43050_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE 2013-11-26 10:42:08 +08:00
Dan Poltawski 00b965f609 Merge branch 'wip-mdl-41635-m26' of git://github.com/rajeshtaneja/moodle into MOODLE_26_STABLE 2013-11-26 10:25:01 +08:00
Damyon Wiese 5f9aa41321 Merge branch 'wip-MDL-40850-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2013-11-26 09:33:36 +08:00
Ankit Agarwal 5c1adaddba MDL-43005 blogs: Fix issues with blog tags 2013-11-26 08:43:39 +13:00
Sam Hemelryk 390896d3d9 Merge branch 'MDL-43037_m26' of https://github.com/markn86/moodle into MOODLE_26_STABLE 2013-11-26 08:36:09 +13:00
Simon Coggins eab8b262be MDL-43045 report: Fix missing role name in security overview report 2013-11-26 08:22:37 +13:00
David Monllao 5464179b31 MDL-42842 behat: Adding a new formatter
Based on ProgressFormatter, the site info
will be displayed when the suite begins.
2013-11-25 16:01:52 +08:00
David Monllao 99a4c833b6 MDL-42842 testing: Generalization of the site info 2013-11-25 16:00:43 +08:00
David Monllao da920040ad MDL-43050 behat: Fixing moodlehq/behat-extension version 2013-11-25 15:48:04 +08:00
Marina Glancy fdbd1d7a9d MDL-42925 course: Changed help string for course format selection 2013-11-25 15:44:06 +08:00
rwijaya bb68dfc002 MDL-42858 Course Management: Update phpunit test for core_course_management_helper_test 2013-11-25 15:40:07 +08:00
Frederic Massart 72cf8c6ca3 MDL-42985 curl: Correctly apply rule proxybypass 2013-11-25 14:51:18 +08:00
Damyon Wiese a1554ea241 Merge branch 'wip-MDL-41257-26' of git://github.com/abgreeve/moodle into MOODLE_26_STABLE 2013-11-25 14:02:30 +08:00
Dan Poltawski 749db57b4c Merge branch 'w48_MDL-37016_m26_sloppymysql' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2013-11-25 13:40:56 +08:00
Marina Glancy 3b62f94787 MDL-43028 navigation: correct capability check 2013-11-25 13:29:11 +08:00
Rajesh Taneja 13d5afea34 MDL-43028 Navigation: Setting proper page properties on admin pages 2013-11-25 13:29:02 +08:00
Damyon Wiese 025bd122a6 Merge branch 'wip-mdl-42924-m26' of https://github.com/rajeshtaneja/moodle into MOODLE_26_STABLE 2013-11-25 13:16:37 +08:00
Tim Lock 7ce782e654 MDL-43020: Fix lesson scale warnings when deleting user attempts 2013-11-25 15:10:05 +10:30
Damyon Wiese c3208c17d1 Merge branch 'MDL-42913a-26' of https://github.com/srynot4sale/moodle into MOODLE_26_STABLE 2013-11-25 12:30:23 +08:00
Dan Poltawski 0f4ea5911c Merge branch '43016-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE 2013-11-25 12:22:56 +08:00
Marina Glancy b955d07c33 MDL-43006 behat: adding javascript tag because of behat bug
behat without JS does not submit the empty textarea field causing notice in the form processing
2013-11-25 15:00:28 +11:00
Dan Marsden 60ee7cebc7 MDL-42992 SCORM: Always allow IE to resize window 2013-11-25 11:18:18 +08:00
Dan Poltawski 6508a3c68e Merge branch 'wip-MDL-43024-m26' of git://github.com/marinaglancy/moodle into MOODLE_26_STABLE 2013-11-25 11:06:41 +08:00
Dan Poltawski 9e2bc0490f Merge branch 'MDL-42858_m26' of git://github.com/rwijaya/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-11-25 10:49:02 +08:00
Dan Poltawski a2aceccdbe Merge branch 'MDL-42957-26' of git://github.com/jamiepratt/moodle into MOODLE_26_STABLE 2013-11-25 10:43:31 +08:00
Dan Poltawski d3ec6a9dcf Merge branch 'MDL-42547_m26' of https://github.com/markn86/moodle into MOODLE_26_STABLE 2013-11-25 10:37:36 +08:00
Rajesh Taneja 80140c4592 MDL-42904 self_enrol: Set customint1 if it's null 2013-11-25 10:02:01 +08:00
Tim Lock 7a2b15647e MDL-43020: Fix calculation of lesson scale value warning 2013-11-25 09:33:14 +10:30
Petr Škoda bf5a6920bc MDL-37016 fix sloppy mysql nulls in event.uuid 2013-11-24 15:11:33 +08:00
Mark Nelson 295b622b0b MDL-43037 mod_quiz: retrieve all name fields for the user override pages 2013-11-23 16:18:12 -08:00
rwijaya aa5b71c005 MDL-42851 frontpage: fix rtl in clean theme for course listings 2013-11-22 15:49:06 +08:00
Marina Glancy 5ad8fa096d MDL-43024 course: fixed bug for accessing section options 2013-11-22 12:39:55 +11:00
Tim Lock ab077b368c MDL-43020: Lesson using a scale always gives the minimum scale value 2013-11-22 07:20:24 +10:30
Sam Hemelryk 5e946b2ceb MDL-43016 block_navigation: fixed category link display 2013-11-22 09:00:09 +13:00
Eloy Lafuente (stronk7) ca3b210680 weekly release 2.6+ 2013-11-21 19:33:44 +01:00
rwijaya 2834f79e73 MDL-42858 Course Management: fix regression for subcategories visibility 2013-11-21 15:34:40 +08:00
David Monllao bf752eb38b MDL-42733 behat: Removing the restriction of an started output to handle the PHP errors 2013-11-21 14:35:43 +08:00
Marina Glancy 5018c28e43 MDL-40850 editor: Manage files popup correctly sets the course/cm context 2013-11-21 11:56:36 +11:00
Mark Nelson 2f874214ba MDL-42547 tool_uploaduser: trim values before uploading users 2013-11-20 00:32:15 -08:00
Damyon Wiese 981e960d34 MDL-42930 Release upgrade line: Fix ordering for tinymce 2013-11-20 11:50:38 +08:00
FilipBenco 7843fb7e14 MDL-41635 Reports: Added missing string in loglive reports
Under course administration navigation log live doesn't appear
or appear with empty string (in some themes), this is happening
because text passed is empty.
2013-11-20 11:26:15 +08:00
Ankit Agarwal dbc251e25c MDL-42767 events: Remove ob_clean from tests 2013-11-20 13:22:27 +11:00
Ankit Agarwal bdfb46a2d0 MDL-42767 notes: Delete notes on a course delete 2013-11-20 13:22:07 +11:00
Michael Milette 9da8b39169 MDL-41257 calendar: Day and Upcoming-Events view not processed through text_filters() function
This fix adds text filtering to the Calendar Day view and Upcoming Events view, specifically the event name and event description.

Signed-off-by: Michael Milette <michael.milette@instruxmedia.com>
2013-11-20 09:59:39 +08:00
Aaron Barnes b642702aa2 MDL-42913 lib/grouplib.php: Avoid cache sometimes for groups_get_all_groups
The new groups cache returns unexpected results when you pass
in a field parameter than would normally change the result array index
2013-11-20 12:02:15 +13:00
Rajesh Taneja 740d260ce7 MDL-42924 Administration: use normalize_component to extract plugin name and type 2013-11-19 11:56:04 +08:00
Rajesh Taneja ffe199b1fa MDL-42403 course: Added behat to check visibility of bluk move action 2013-11-19 11:44:48 +08:00
Rajesh Taneja d583059471 MDL-42403 course: Show bluk move to category only when something selected 2013-11-19 11:44:43 +08:00
Dan Poltawski 5af5a205a3 Merge branch '42060-26' of git://github.com/samhemelryk/moodle into MOODLE_26_STABLE 2013-11-19 10:39:33 +08:00
Tim Hunt 6c816ca22c MDL-42504 quiz autosave: alert users if connection lost.
When the auto-save fails, we alert the user that they may have lost their
internet connection so that they don't do more work that they might just
lose.
2013-11-19 10:31:37 +08:00
M Kassaei f6240d9eea MDL-42181 quiz nav: highight all buttons when all Qs on one page 2013-11-19 10:08:22 +08:00
Damyon Wiese 49d367d47e Merge branch 'm26_MDL-40223' of git://github.com/danmarsden/moodle into MOODLE_26_STABLE 2013-11-19 09:50:49 +08:00
sam marshall f068ae74db MDL-42905 Backup progress: Pointless line of code should be deleted 2013-11-19 14:39:56 +13:00
Mark Nelson dd7b9d1dce MDL-42553 core_calendar: third party calendar types can now be uninstalled 2013-11-19 14:32:25 +13:00
Adrian Greeve c7232a325a MDL-42850 administration: Updated bulk user upload errors to be more descriptive. 2013-11-19 14:20:32 +13:00
Dan Marsden be335eb8db MDL-40223 SCORM: pass limit into function instead of hardcoding to allow cross-db 2013-11-19 13:24:25 +13:00
Ankit Agarwal ff8cadd271 MDL-41316 tool_spamcleaner: Fix sql queries
AS keyword is not allowed in sql qeries for table alias as Oracle doesn't support it
Thanks to Sara Cenni for suggesting the patch
2013-11-19 12:28:37 +13:00
Sam Hemelryk a34073eeb8 Merge branch 'w47_MDL-42612_m26_paypalruble' of https://github.com/skodak/moodle into MOODLE_26_STABLE 2013-11-19 12:24:41 +13:00
Andrew Nicols 223f133f88 MDL-42774 JavaScript: Ensure that shifter cleans build directories before running 2013-11-19 12:06:59 +13:00
Tim Hunt a47b6805be MDL-42863 make capabilities overview more fault-tolerant. 2013-11-19 12:03:55 +13:00
Tim Hunt 99b936835d MDL-42865 Make XMLDB foreign key check more robust.
Otherwise, installing one bad add-on can completely break this report.
2013-11-19 11:51:06 +13:00
Sam Hemelryk 8bd0487a4b MDL-42852 theme_bootstrapbase: fixed whitespace 2013-11-19 11:44:50 +13:00
Gareth J Barnard 600ad57d35 MDL-42852 lib: Blocks disappear in Clean in RTL.
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-11-19 11:42:56 +13:00
Jerome Mouneyrac 7628ac73f4 MDL-42184 bootstrapbase: popup should have no header 2013-11-19 10:16:35 +13:00
Sam Hemelryk 64b4fbebd8 Merge branch 'MDL-42853-master' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE
Conflicts:
	theme/bootstrapbase/style/moodle.css
2013-11-19 10:09:18 +13:00
Damyon Wiese 52454bedee Merge branch 'MDL-42100_master' of https://github.com/markn86/moodle into MOODLE_26_STABLE 2013-11-18 16:08:31 +08:00
Tim Hunt 8f74fa4366 MDL-42880 quiz settings: remove unnecessary disabledif rules.
These rules were causing problems in the case where the form was
sumitted with validation errors. In that case, the During the attempt ->
The attempt checkbox was becoming unset, and hence the other During the
attmept checkboxes became disabled, and the values were not saved.

Thanks to Sam Marshall for suggesting this fix.
2013-11-18 15:37:15 +08:00
Damyon Wiese 02e45bf269 Merge branch 'MDL-42808-master' of git://github.com/FMCorz/moodle into MOODLE_26_STABLE 2013-11-18 15:27:22 +08:00
Damyon Wiese 28fccc09ce Merge branch 'm26_MDL-41695' of git://github.com/danmarsden/moodle into MOODLE_26_STABLE 2013-11-18 15:21:01 +08:00
sam marshall 7ed24ca351 MDL-42582 Availability: Restriction display incorrect for multi-para Labels
When a label has multiple paragraphs, its name (converted to plain text)
contains a line feed. Due to an error in regular expressions that don't
accept the line feed, this caused incorrect display on the course page
when that label is shown as a requirement for accessing another activity.
2013-11-18 14:54:55 +08:00
Mark Nelson e98f145ccc MDL-42884 core_user: fixed issue when deleting users with invalid emails throws invalidusername exception 2013-11-18 14:48:36 +08:00
Dan Poltawski 904f5815c7 Merge branch 'MDL-42930-26' of git://github.com/damyon/moodle into MOODLE_26_STABLE
Conflicts:
	mod/scorm/db/upgrade.php
2013-11-18 14:30:50 +08:00
Damyon Wiese d29a7827c4 Merge branch 'm26_MDL-40223' of git://github.com/danmarsden/moodle into MOODLE_26_STABLE 2013-11-18 14:04:23 +08:00
Petr Škoda 5cd5271673 MDL-42612 add support for Russian Ruble in PayPal 2013-11-18 11:47:18 +08:00
Damyon Wiese 005e784e22 MDL-42930 Add 2.6.0 upgrade line 2013-11-18 11:41:59 +08:00
Sam Hemelryk c20f615105 MDL-42060 block_course_list: fixed sorting of mycourses 2013-11-18 11:15:35 +13:00
Dan Marsden 685badbb2b MDL-41695 SCORM: allow unlimited decimal places in CMIDecimal 2013-11-18 10:27:59 +13:00
Dan Marsden eef55a6333 MDL-40223 SCORM: update scorm->launch param after restore - also check that scorm->launch is valid. 2013-11-18 09:48:02 +13:00
Eloy Lafuente (stronk7) fa28975f25 MDL-42929 backup: keep own version & release updated. 2013-11-17 02:34:50 +01:00
Frederic Massart 7d31a2999b MDL-42853 course: Fix edit title icon margin on RTL 2013-11-14 10:59:35 +08:00
Frederic Massart e161a5a319 MDL-42853 frontpage: RTL alignment to match LTR 2013-11-14 10:59:23 +08:00
Mark Nelson 8eb2ea83d2 MDL-42100 tool_capability: fixed incorrect links 2013-11-13 00:20:28 -08:00
Frederic Massart 7c9753a713 MDL-42808 library: Google API was resetting the timezone 2013-11-11 15:25:00 +08:00
sam marshall 1f8662f6fb MDL-41446 Completion: Incorrectly marks complete when grade data present with no actual grade 2013-09-06 13:01:50 +01:00
858 changed files with 18336 additions and 3924 deletions
+1 -1
View File
@@ -42,7 +42,7 @@
"sub": false,
"supernew": false,
"maxerr": 500,
"maxlen": 150,
"maxlen": 180,
"passfail": false,
"latedef": true
}
+2 -1
View File
@@ -1,4 +1,5 @@
{
"coverage": false,
"lint": "config"
"lint": "config",
"clean": true
}
+123
View File
@@ -1013,4 +1013,127 @@
</PHP_SETTING>
</PHP_SETTINGS>
</MOODLE>
<MOODLE version="2.7" requires="2.2">
<UNICODE level="required">
<FEEDBACK>
<ON_ERROR message="unicoderequired" />
</FEEDBACK>
</UNICODE>
<DATABASE level="required">
<VENDOR name="mariadb" version="5.5.31" />
<VENDOR name="mysql" version="5.5.31" />
<VENDOR name="postgres" version="9.1" />
<VENDOR name="mssql" version="10.0" />
<VENDOR name="oracle" version="10.2" />
</DATABASE>
<PHP version="5.4.4" level="required">
</PHP>
<PCREUNICODE level="optional">
<FEEDBACK>
<ON_CHECK message="pcreunicodewarning" />
</FEEDBACK>
</PCREUNICODE>
<PHP_EXTENSIONS>
<PHP_EXTENSION name="iconv" level="required">
<FEEDBACK>
<ON_ERROR message="iconvrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="mbstring" level="optional">
<FEEDBACK>
<ON_CHECK message="mbstringrecommended" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="curl" level="required">
<FEEDBACK>
<ON_ERROR message="curlrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="openssl" level="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="zlib" level="required">
</PHP_EXTENSION>
<PHP_EXTENSION name="gd" level="required">
<FEEDBACK>
<ON_ERROR message="gdrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="simplexml" level="required">
<FEEDBACK>
<ON_ERROR message="simplexmlrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="spl" level="required">
<FEEDBACK>
<ON_ERROR message="splrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="pcre" level="required">
</PHP_EXTENSION>
<PHP_EXTENSION name="dom" level="required">
</PHP_EXTENSION>
<PHP_EXTENSION name="xml" level="required">
</PHP_EXTENSION>
<PHP_EXTENSION name="intl" level="optional">
<FEEDBACK>
<ON_CHECK message="intlrecommended" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="json" level="required">
</PHP_EXTENSION>
<PHP_EXTENSION name="hash" level="required"/>
</PHP_EXTENSIONS>
<PHP_SETTINGS>
<PHP_SETTING name="memory_limit" value="96M" level="required">
<FEEDBACK>
<ON_ERROR message="settingmemorylimit" />
</FEEDBACK>
</PHP_SETTING>
<PHP_SETTING name="file_uploads" value="1" level="optional">
<FEEDBACK>
<ON_CHECK message="settingfileuploads" />
</FEEDBACK>
</PHP_SETTING>
<PHP_SETTING name="opcache.enable" value="1" level="optional">
<FEEDBACK>
<ON_CHECK message="opcacherecommended" />
</FEEDBACK>
</PHP_SETTING>
</PHP_SETTINGS>
<CUSTOM_CHECKS>
<CUSTOM_CHECK file="question/engine/upgrade/upgradelib.php" function="quiz_attempts_upgraded" level="required">
<FEEDBACK>
<ON_ERROR message="quizattemptsupgradedmessage" />
</FEEDBACK>
</CUSTOM_CHECK>
</CUSTOM_CHECKS>
</MOODLE>
</COMPATIBILITY_MATRIX>
+66 -47
View File
@@ -47,7 +47,9 @@ if (!function_exists('iconv')) {
define('NO_OUTPUT_BUFFERING', true);
if (empty($_GET['cache']) and empty($_POST['cache']) and empty($_GET['sesskey']) and empty($_POST['sesskey'])) {
if ((isset($_GET['cache']) and $_GET['cache'] === '0')
or (isset($_POST['cache']) and $_POST['cache'] === '0')
or (!isset($_POST['cache']) and !isset($_GET['cache']) and empty($_GET['sesskey']) and empty($_POST['sesskey']))) {
// Prevent caching at all cost when visiting this page directly,
// we redirect to self once we known no upgrades are necessary.
// Note: $_GET and $_POST are used here intentionally because our param cleaning is not loaded yet.
@@ -90,9 +92,7 @@ $newaddonreq = optional_param('installaddonrequest', null, PARAM_RAW);
// Set up PAGE.
$url = new moodle_url('/admin/index.php');
if ($cache) {
$url->param('cache', 1);
}
$url->param('cache', $cache);
$PAGE->set_url($url);
unset($url);
@@ -267,12 +267,13 @@ if (!$cache and $version > $CFG->version) { // upgrade
$PAGE->set_pagelayout('maintenance');
$PAGE->set_popup_notification_allowed(false);
/** @var core_admin_renderer $output */
$output = $PAGE->get_renderer('core', 'admin');
if (upgrade_stale_php_files_present()) {
$PAGE->set_title($stradministration);
$PAGE->set_cacheable(false);
/** @var core_admin_renderer $output */
$output = $PAGE->get_renderer('core', 'admin');
echo $output->upgrade_stale_php_files_page();
die();
}
@@ -287,8 +288,6 @@ if (!$cache and $version > $CFG->version) { // upgrade
$PAGE->set_heading($strdatabasechecking);
$PAGE->set_cacheable(false);
/** @var core_admin_renderer $output */
$output = $PAGE->get_renderer('core', 'admin');
echo $output->upgrade_confirm_page($a->newversion, $maturity, $testsite);
die();
@@ -302,8 +301,6 @@ if (!$cache and $version > $CFG->version) { // upgrade
$PAGE->set_heading($strcurrentrelease);
$PAGE->set_cacheable(false);
/** @var core_admin_renderer $output */
$output = $PAGE->get_renderer('core', 'admin');
echo $output->upgrade_environment_page($release, $envstatus, $environment_results);
die();
@@ -315,23 +312,13 @@ if (!$cache and $version > $CFG->version) { // upgrade
$PAGE->set_heading($strplugincheck);
$PAGE->set_cacheable(false);
$reloadurl = new moodle_url('/admin/index.php', array('confirmupgrade' => 1, 'confirmrelease' => 1));
/** @var core_admin_renderer $output */
$output = $PAGE->get_renderer('core', 'admin');
// check plugin dependencies first
$failed = array();
if (!core_plugin_manager::instance()->all_plugins_ok($version, $failed)) {
echo $output->unsatisfied_dependencies_page($version, $failed, $reloadurl);
die();
}
unset($failed);
$reloadurl = new moodle_url('/admin/index.php', array('confirmupgrade' => 1, 'confirmrelease' => 1, 'cache' => 0));
if ($fetchupdates) {
// no sesskey support guaranteed here
if (empty($CFG->disableupdatenotifications)) {
\core\update\checker::instance()->fetch();
// No sesskey support guaranteed here, because sessions might not work yet.
$updateschecker = \core\update\checker::instance();
if ($updateschecker->enabled()) {
$updateschecker->fetch();
}
redirect($reloadurl);
}
@@ -342,6 +329,7 @@ if (!$cache and $version > $CFG->version) { // upgrade
$deploydata = $deployer->submitted_data();
if (!empty($deploydata)) {
// No sesskey support guaranteed here, because sessions might not work yet.
echo $output->upgrade_plugin_confirm_deploy_page($deployer, $deploydata);
die();
}
@@ -349,11 +337,22 @@ if (!$cache and $version > $CFG->version) { // upgrade
echo $output->upgrade_plugin_check_page(core_plugin_manager::instance(), \core\update\checker::instance(),
$version, $showallplugins, $reloadurl,
new moodle_url('/admin/index.php', array('confirmupgrade'=>1, 'confirmrelease'=>1, 'confirmplugincheck'=>1)));
new moodle_url('/admin/index.php', array('confirmupgrade'=>1, 'confirmrelease'=>1, 'confirmplugincheck'=>1, 'cache'=>0)));
die();
} else {
// Launch main upgrade
// Always verify plugin dependencies!
$failed = array();
if (!core_plugin_manager::instance()->all_plugins_ok($version, $failed)) {
$PAGE->set_pagelayout('maintenance');
$PAGE->set_popup_notification_allowed(false);
$reloadurl = new moodle_url('/admin/index.php', array('confirmupgrade' => 1, 'confirmrelease' => 1, 'cache' => 0));
echo $output->unsatisfied_dependencies_page($version, $failed, $reloadurl);
die();
}
unset($failed);
// Launch main upgrade.
upgrade_core($version, true);
}
} else if ($version < $CFG->version) {
@@ -373,6 +372,10 @@ if (!$cache and $branch <> $CFG->branch) { // Update the branch
if (!$cache and moodle_needs_upgrading()) {
if (!$PAGE->headerprinted) {
// means core upgrade or installation was not already done
/** @var core_admin_renderer $output */
$output = $PAGE->get_renderer('core', 'admin');
if (!$confirmplugins) {
$strplugincheck = get_string('plugincheck');
@@ -384,40 +387,46 @@ if (!$cache and moodle_needs_upgrading()) {
$PAGE->set_cacheable(false);
if ($fetchupdates) {
// no sesskey support guaranteed here
\core\update\checker::instance()->fetch();
require_sesskey();
$updateschecker = \core\update\checker::instance();
if ($updateschecker->enabled()) {
$updateschecker->fetch();
}
redirect($PAGE->url);
}
$output = $PAGE->get_renderer('core', 'admin');
$deployer = \core\update\deployer::instance();
if ($deployer->enabled()) {
$deployer->initialize($PAGE->url, $PAGE->url);
$deploydata = $deployer->submitted_data();
if (!empty($deploydata)) {
require_sesskey();
echo $output->upgrade_plugin_confirm_deploy_page($deployer, $deploydata);
die();
}
}
// check plugin dependencies first
$failed = array();
if (!core_plugin_manager::instance()->all_plugins_ok($version, $failed)) {
echo $output->unsatisfied_dependencies_page($version, $failed, $PAGE->url);
die();
}
unset($failed);
// dependencies check passed, let's rock!
// Show plugins info.
echo $output->upgrade_plugin_check_page(core_plugin_manager::instance(), \core\update\checker::instance(),
$version, $showallplugins,
new moodle_url($PAGE->url),
new moodle_url('/admin/index.php', array('confirmplugincheck'=>1)));
new moodle_url('/admin/index.php', array('confirmplugincheck'=>1, 'cache'=>0)));
die();
}
// Make sure plugin dependencies are always checked.
$failed = array();
if (!core_plugin_manager::instance()->all_plugins_ok($version, $failed)) {
$PAGE->set_pagelayout('maintenance');
$PAGE->set_popup_notification_allowed(false);
$reloadurl = new moodle_url('/admin/index.php', array('cache' => 0));
echo $output->unsatisfied_dependencies_page($version, $failed, $reloadurl);
die();
}
unset($failed);
}
// install/upgrade all plugins and other parts
upgrade_noncore(true);
}
@@ -477,6 +486,17 @@ if (during_initial_install()) {
upgrade_finished('upgradesettings.php');
}
if (has_capability('moodle/site:config', context_system::instance())) {
if ($fetchupdates) {
require_sesskey();
$updateschecker = \core\update\checker::instance();
if ($updateschecker->enabled()) {
$updateschecker->fetch();
}
redirect(new moodle_url('/admin/index.php', array('cache' => 0)));
}
}
// Now we can be sure everything was upgraded and caches work fine,
// redirect if necessary to make sure caching is enabled.
if (!$cache) {
@@ -485,6 +505,11 @@ if (!$cache) {
// Check for valid admin user - no guest autologin
require_login(0, false);
if (isguestuser()) {
// Login as real user!
$SESSION->wantsurl = (string)new moodle_url('/admin/index.php');
redirect(get_login_url());
}
$context = context_system::instance();
require_capability('moodle/site:config', $context);
@@ -564,12 +589,6 @@ $registered = $DB->count_records('registration_hubs', array('huburl' => HUB_MOOD
admin_externalpage_setup('adminnotifications');
if ($fetchupdates) {
require_sesskey();
$updateschecker->fetch();
redirect(new moodle_url('/admin/index.php'));
}
$output = $PAGE->get_renderer('core', 'admin');
echo $output->admin_notifications_page($maturity, $insecuredataroot, $errorsdisplayed,
$cronoverdue, $dbproblems, $maintenancemode, $availableupdates, $availableupdatesfetch, $buggyiconvnomb,
+7 -5
View File
@@ -16,8 +16,6 @@ require_login();
admin_externalpage_setup('ssoaccesscontrol');
echo $OUTPUT->header();
if (!extension_loaded('openssl')) {
print_error('requiresopenssl', 'mnet');
}
@@ -65,9 +63,11 @@ if (!empty($action) and confirm_sesskey()) {
if (mnet_update_sso_access_control($idrec->username, $idrec->mnet_host_id, $accessctrl)) {
if ($accessctrl == 'allow') {
redirect('access_control.php', get_string('ssl_acl_allow','mnet', array('uset'=>$idrec->username, 'host'=>$mnethosts[$idrec->mnet_host_id])));
} elseif ($accessctrl == 'deny') {
redirect('access_control.php', get_string('ssl_acl_deny','mnet', array('user'=>$idrec->username, 'host'=>$mnethosts[$idrec->mnet_host_id])));
redirect('access_control.php', get_string('ssl_acl_allow','mnet', array('user' => $idrec->username,
'host' => $mnethosts[$idrec->mnet_host_id])));
} else if ($accessctrl == 'deny') {
redirect('access_control.php', get_string('ssl_acl_deny','mnet', array('user' => $idrec->username,
'host' => $mnethosts[$idrec->mnet_host_id])));
}
}
break;
@@ -118,6 +118,8 @@ if ($form = data_submitted() and confirm_sesskey()) {
exit;
}
echo $OUTPUT->header();
// Explain
echo $OUTPUT->box(get_string('ssoacldescr','mnet'));
// Are the needed bits enabled?
+7 -7
View File
@@ -140,7 +140,7 @@ class core_admin_renderer extends plugin_renderer_base {
public function upgrade_confirm_page($strnewversion, $maturity, $testsite) {
$output = '';
$continueurl = new moodle_url('/admin/index.php', array('confirmupgrade' => 1));
$continueurl = new moodle_url('/admin/index.php', array('confirmupgrade' => 1, 'cache' => 0));
$continue = new single_button($continueurl, get_string('continue'), 'get');
$cancelurl = new moodle_url('/admin/index.php');
@@ -170,7 +170,7 @@ class core_admin_renderer extends plugin_renderer_base {
$output .= $this->environment_check_table($envstatus, $environment_results);
if (!$envstatus) {
$output .= $this->upgrade_reload(new moodle_url('/admin/index.php'), array('confirmupgrade' => 1));
$output .= $this->upgrade_reload(new moodle_url('/admin/index.php'), array('confirmupgrade' => 1, 'cache' => 0));
} else {
$output .= $this->notification(get_string('environmentok', 'admin'), 'notifysuccess');
@@ -179,7 +179,7 @@ class core_admin_renderer extends plugin_renderer_base {
$output .= $this->box(get_string('langpackwillbeupdated', 'admin'), 'generalbox', 'notice');
}
$output .= $this->continue_button(new moodle_url('/admin/index.php', array('confirmupgrade' => 1, 'confirmrelease' => 1)));
$output .= $this->continue_button(new moodle_url('/admin/index.php', array('confirmupgrade' => 1, 'confirmrelease' => 1, 'cache' => 0)));
}
$output .= $this->footer();
@@ -711,7 +711,7 @@ class core_admin_renderer extends plugin_renderer_base {
}
$updateinfo .= $this->container_start('checkforupdates');
$fetchurl = new moodle_url('/admin/index.php', array('fetchupdates' => 1, 'sesskey' => sesskey(), 'cache' => 1));
$fetchurl = new moodle_url('/admin/index.php', array('fetchupdates' => 1, 'sesskey' => sesskey(), 'cache' => 0));
$updateinfo .= $this->single_button($fetchurl, get_string('checkforupdates', 'core_plugin'));
if ($fetch) {
$updateinfo .= $this->container(get_string('checkforupdateslast', 'core_plugin',
@@ -962,7 +962,7 @@ class core_admin_renderer extends plugin_renderer_base {
$out .= $this->output->heading(get_string('nonehighlighted', 'core_plugin'));
if (empty($options['full'])) {
$out .= html_writer::link(new moodle_url('/admin/index.php',
array('confirmupgrade' => 1, 'confirmrelease' => 1, 'showallplugins' => 1)),
array('confirmupgrade' => 1, 'confirmrelease' => 1, 'showallplugins' => 1, 'cache' => 0)),
get_string('nonehighlightedinfo', 'core_plugin'));
}
$out .= $this->output->container_end();
@@ -972,11 +972,11 @@ class core_admin_renderer extends plugin_renderer_base {
$out .= $this->output->heading(get_string('somehighlighted', 'core_plugin', $sumofhighlighted));
if (empty($options['full'])) {
$out .= html_writer::link(new moodle_url('/admin/index.php',
array('confirmupgrade' => 1, 'confirmrelease' => 1, 'showallplugins' => 1)),
array('confirmupgrade' => 1, 'confirmrelease' => 1, 'showallplugins' => 1, 'cache' => 0)),
get_string('somehighlightedinfo', 'core_plugin'));
} else {
$out .= html_writer::link(new moodle_url('/admin/index.php',
array('confirmupgrade' => 1, 'confirmrelease' => 1, 'showallplugins' => 0)),
array('confirmupgrade' => 1, 'confirmrelease' => 1, 'showallplugins' => 0, 'cache' => 0)),
get_string('somehighlightedonly', 'core_plugin'));
}
$out .= $this->output->container_end();
+15 -5
View File
@@ -2,7 +2,12 @@
// This file defines settingpages and externalpages under the "appearance" category
if ($hassiteconfig) { // speedup for non-admins, add all caps used on this page
$capabilities = array(
'moodle/my:configsyspages',
'moodle/tag:manage'
);
if ($hassiteconfig or has_any_capability($capabilities, $systemcontext)) { // speedup for non-admins, add all caps used on this page
$ADMIN->add('appearance', new admin_category('themes', new lang_string('themes')));
// "themesettings" settingpage
@@ -36,8 +41,11 @@ if ($hassiteconfig) { // speedup for non-admins, add all caps used on this page
}
// calendar
// Calendar settings.
$temp = new admin_settingpage('calendar', new lang_string('calendarsettings','admin'));
$temp->add(new admin_setting_configselect('calendartype', new lang_string('calendartype', 'admin'),
new lang_string('calendartype_desc', 'admin'), 'gregorian', \core_calendar\type_factory::get_list_of_calendar_types()));
$temp->add(new admin_setting_special_adminseesall());
//this is hacky because we do not want to include the stuff from calendar/lib.php
$temp->add(new admin_setting_configselect('calendar_site_timeformat', new lang_string('pref_timeformat', 'calendar'),
@@ -186,10 +194,12 @@ if ($hassiteconfig) { // speedup for non-admins, add all caps used on this page
$temp->add(new admin_setting_configcheckbox('doctonewwindow', new lang_string('doctonewwindow', 'admin'), new lang_string('configdoctonewwindow', 'admin'), 0));
$ADMIN->add('appearance', $temp);
$temp = new admin_externalpage('mypage', new lang_string('mypage', 'admin'), $CFG->wwwroot . '/my/indexsys.php');
$temp = new admin_externalpage('mypage', new lang_string('mypage', 'admin'), $CFG->wwwroot . '/my/indexsys.php',
'moodle/my:configsyspages');
$ADMIN->add('appearance', $temp);
$temp = new admin_externalpage('profilepage', new lang_string('myprofile', 'admin'), $CFG->wwwroot . '/user/profilesys.php');
$temp = new admin_externalpage('profilepage', new lang_string('myprofile', 'admin'), $CFG->wwwroot . '/user/profilesys.php',
'moodle/my:configsyspages');
$ADMIN->add('appearance', $temp);
// coursecontact is the person responsible for course - usually manages enrolments, receives notification, etc.
@@ -219,7 +229,7 @@ if ($hassiteconfig) { // speedup for non-admins, add all caps used on this page
$ADMIN->add('appearance', $temp);
// link to tag management interface
$ADMIN->add('appearance', new admin_externalpage('managetags', new lang_string('managetags', 'tag'), "$CFG->wwwroot/tag/manage.php"));
$ADMIN->add('appearance', new admin_externalpage('managetags', new lang_string('managetags', 'tag'), $CFG->wwwroot.'/tag/manage.php', 'moodle/tag:manage'));
$temp = new admin_settingpage('additionalhtml', new lang_string('additionalhtml', 'admin'));
$temp->add(new admin_setting_heading('additionalhtml_heading', new lang_string('additionalhtml_heading', 'admin'), new lang_string('additionalhtml_desc', 'admin')));
+10
View File
@@ -485,6 +485,16 @@ if ($hassiteconfig) {
}
}
// Add Calendar type settings.
if ($hassiteconfig) {
$ADMIN->add('modules', new admin_category('calendartype', new lang_string('calendartypes', 'calendar')));
foreach (core_component::get_plugin_list_with_file('calendartype', 'settings.php') as $plugin => $settingspath) {
$settings = new admin_settingpage('calendartype_' . $plugin . '_settings', new lang_string('pluginname', 'calendartype_' . $plugin), 'moodle/site:config');
include($settingspath);
$ADMIN->add('calendartype', $settings);
}
}
/// Add all local plugins - must be always last!
if ($hassiteconfig) {
$ADMIN->add('modules', new admin_category('localplugins', new lang_string('localplugins')));
+9 -15
View File
@@ -17,7 +17,7 @@
/**
* Steps definitions related with administration.
*
* @package core
* @package core_admin
* @category test
* @copyright 2013 David Monllaó
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
@@ -35,7 +35,7 @@ use Behat\Behat\Context\Step\Given as Given,
/**
* Site administration level steps definitions.
*
* @package core
* @package core_admin
* @category test
* @copyright 2013 David Monllaó
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
@@ -59,7 +59,7 @@ class behat_admin extends behat_base {
// We expect admin block to be visible, otherwise go to homepage.
if (!$this->getSession()->getPage()->find('css', '.block_settings')) {
$this->getSession()->visit($this->locate_path('/'));
$this->wait(self::TIMEOUT, '(document.readyState === "complete")');
$this->wait(self::TIMEOUT * 1000, self::PAGE_READY_JS);
}
// Search by label.
@@ -68,7 +68,7 @@ class behat_admin extends behat_base {
$submitsearch = $this->find('css', 'form.adminsearchform input[type=submit]');
$submitsearch->press();
$this->wait(self::TIMEOUT, '(document.readyState === "complete")');
$this->wait(self::TIMEOUT * 1000, self::PAGE_READY_JS);
// Admin settings does not use the same DOM structure than other moodle forms
// but we also need to use lib/behat/form_field/* to deal with the different moodle form elements.
@@ -127,21 +127,15 @@ class behat_admin extends behat_base {
}
/**
* Goes to notification page ensuring site admin navigation is loaded.
* Will be deprecated in 2.7. Goes to notification page.
*
* @Given /^I go to notifications page$/
* @return Given[]
*/
public function i_go_to_notifications_page() {
if ($this->running_javascript()) {
return array(
new Given('I expand "' . get_string('administrationsite') . '" node'),
new Given('I follow "' . get_string('notifications') . '"')
);
} else {
return array(
new Given('I follow "' . get_string('administrationsite') . '"')
);
}
return array(
new Given('I expand "' . get_string('administrationsite') . '" node'),
new Given('I follow "' . get_string('notifications') . '"')
);
}
}
@@ -15,7 +15,7 @@ Feature: Display extended course names
And I should not see "C_shortname Course fullname"
Scenario: Courses list with extended course names
Given I go to notifications page
Given I expand "Site administration" node
And I click on "Courses" "link" in the "//div[@id='settingsnav']/descendant::li[contains(concat(' ', normalize-space(@class), ' '), ' type_setting ')][contains(., 'Appearance')]" "xpath_element"
And I check "Display extended course names"
When I press "Save changes"
+2 -3
View File
@@ -1,4 +1,4 @@
@core @core_admin @_only_local
@core @core_admin @_only_local @_file_upload
Feature: Upload users
In order to add users to the system
As an admin
@@ -19,7 +19,7 @@ Feature: Upload users
And I expand "Users" node
And I expand "Accounts" node
And I follow "Upload users"
When I upload "lib/tests/fixtures/upload_users.csv" file to "File" filepicker
When I upload "lib/tests/fixtures/upload_users.csv" file to "File" filemanager
And I press "Upload users"
Then I should see "Upload users preview"
And I should see "Tom"
@@ -42,5 +42,4 @@ Feature: Upload users
And I expand "Users" node
And I follow "Groups"
And I select "Section 1 (1)" from "groups"
And I wait "4" seconds
And the "members" select box should contain "Tom Jones"
+12 -16
View File
@@ -93,21 +93,17 @@ ini_set('log_errors', '1');
// Getting $CFG data.
require_once(__DIR__ . '/../../../../config.php');
// CFG->behat_prefix must be set and with value different than CFG->prefix and phpunit_prefix.
if (empty($CFG->behat_prefix) ||
($CFG->behat_prefix == $CFG->prefix) ||
(!empty($CFG->phpunit_prefix) && $CFG->behat_prefix == $CFG->phpunit_prefix)) {
behat_error(BEHAT_EXITCODE_CONFIG,
'Define $CFG->behat_prefix in config.php with a value different than $CFG->prefix and $CFG->phpunit_prefix');
}
// When we use the utilities we don't know how the site
// will be accessed, so if neither $CFG->behat_switchcompletely or
// $CFG->behat_wwwroot are set we must think that the site will
// be accessed using the built-in server which is set by default
// to localhost:8000. We need to do this to prevent uses of the production
// wwwroot when the site is being installed / dropped...
$CFG->behat_wwwroot = behat_get_wwwroot();
// CFG->behat_dataroot must be set and with value different than CFG->dataroot and phpunit_dataroot.
if (empty($CFG->behat_dataroot) ||
($CFG->behat_dataroot == $CFG->dataroot) ||
(!empty($CFG->phpunit_dataroot) && $CFG->behat_dataroot == $CFG->phpunit_dataroot)) {
behat_error(BEHAT_EXITCODE_CONFIG,
'Define $CFG->behat_dataroot in config.php with a value different than $CFG->dataroot and $CFG->phpunit_dataroot');
}
// Checking the integrity of the provided $CFG->behat_* vars
// to prevent conflicts with production and phpunit environments.
behat_check_config_vars();
// Create behat_dataroot if it doesn't exists.
if (!file_exists($CFG->behat_dataroot)) {
@@ -187,8 +183,8 @@ if ($options['install']) {
mtrace("Acceptance tests site dropped");
} else if ($options['enable']) {
behat_util::start_test_mode();
$runtestscommand = behat_command::get_behat_command() . ' --config '
. $CFG->behat_dataroot . DIRECTORY_SEPARATOR . 'behat' . DIRECTORY_SEPARATOR . 'behat.yml';
$runtestscommand = behat_command::get_behat_command(true) .
' --config ' . behat_config_manager::get_behat_cli_config_filepath();
mtrace("Acceptance tests environment enabled, to run the tests use:\n " . $runtestscommand);
} else if ($options['disable']) {
behat_util::stop_test_mode();
@@ -18,7 +18,7 @@ Feature: Page contents assertions
When I follow "Overview"
And I wait until the page is ready
And I wait "2" seconds
And I hover ".region-content .generaltable td span" "css_element"
And I hover "#region-main .generaltable td span" "css_element"
Then I should see "I'm the description"
And "Grouping" "select" in the "region-main" "region" should be visible
And "Group" "select" should be visible
@@ -26,8 +26,8 @@ Feature: Page contents assertions
And "Change password" "link" should not be visible
And I should see "Filter groups by"
And I should not see "Filter groupssss by"
And I should see "Group members" in the ".region-content table th.c1" "css_element"
And I should not see "Group membersssss" in the ".region-content table th.c1" "css_element"
And I should see "Group members" in the "#region-main table th.c1" "css_element"
And I should not see "Group membersssss" in the "#region-main table th.c1" "css_element"
And I follow "Groups"
And the "#groupeditform #showcreateorphangroupform" "css_element" should be enabled
And the "#groupeditform #showeditgroupsettingsform" "css_element" should be disabled
@@ -39,7 +39,7 @@ Feature: Page contents assertions
| Course 1 | C1 | 0 |
And I log in as "admin"
And I follow "Course 1"
When I click on "Move this to the dock" "button" in the "Administration" "block"
When I dock "Administration" block
Then I should not see "Question bank" in the "region-pre" "region"
And I click on "//div[@id='dock']/descendant::h2[normalize-space(.)='Administration']" "xpath_element"
@@ -49,5 +49,5 @@ Feature: Page contents assertions
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And I log in as "admin"
When I click on "Move this to the dock" "button" in the "Administration" "block"
When I dock "Administration" block
Then I should not see "Turn editing on" in the "region-pre" "region"
@@ -90,10 +90,10 @@ Feature: Set up contextual data for tests
And I expand "Users" node
And I follow "Permissions"
And I select "Student (1)" from "Advanced role override"
Then the "mod/forum:editanypost" field should match "1" value
Then "mod/forum:editanypost" capability has "Allow" permission
And I press "Cancel"
And I select "Teacher (1)" from "Advanced role override"
And the "mod/forum:replynews" field should match "-1" value
And "mod/forum:replynews" capability has "Prevent" permission
And I press "Cancel"
Scenario: Add course enrolments
@@ -143,13 +143,56 @@ Feature: Set up contextual data for tests
| fullname | shortname |
| Course 1 | C1 |
And the following "activities" exists:
| activity | name | intro | course | idnumber |
| assign | Test assignment name | Test assignment description | C1 | assign1 |
| data | Test database name | Test database description | C1 | data1 |
| activity | name | intro | course | idnumber |
| assign | Test assignment name | Test assignment description | C1 | assign1 |
| assignment | Test assignment22 name | Test assignment22 description | C1 | assignment1 |
| book | Test book name | Test book description | C1 | book1 |
| chat | Test chat name | Test chat description | C1 | chat1 |
| choice | Test choice name | Test choice description | C1 | choice1 |
| data | Test database name | Test database description | C1 | data1 |
| feedback | Test feedback name | Test feedback description | C1 | feedback1 |
| folder | Test folder name | Test folder description | C1 | folder1 |
| forum | Test forum name | Test forum description | C1 | forum1 |
| glossary | Test glossary name | Test glossary description | C1 | glossary1 |
| imscp | Test imscp name | Test imscp description | C1 | imscp1 |
| label | Test label name | Test label description | C1 | label1 |
| lesson | Test lesson name | Test lesson description | C1 | lesson1 |
| lti | Test lti name | Test lti description | C1 | lti1 |
| page | Test page name | Test page description | C1 | page1 |
| quiz | Test quiz name | Test quiz description | C1 | quiz1 |
| resource | Test resource name | Test resource description | C1 | resource1 |
| scorm | Test scorm name | Test scorm description | C1 | scorm1 |
| survey | Test survey name | Test survey description | C1 | survey1 |
| url | Test url name | Test url description | C1 | url1 |
| wiki | Test wiki name | Test wiki description | C1 | wiki1 |
| workshop | Test workshop name | Test workshop description | C1 | workshop1 |
When I log in as "admin"
And I follow "Course 1"
Then I should see "Test assignment name"
# Assignment 2.2 module type is disabled by default
# And I should see "Test assignment22 name"
And I should see "Test book name"
And I should see "Test chat name"
And I should see "Test choice name"
And I should see "Test database name"
# Feedback module type is disabled by default
# And I should see "Test feedback name"
And I should see "Test folder name"
And I should see "Test forum name"
And I should see "Test glossary name"
And I should see "Test imscp name"
# We don't see label name, we see only description:
And I should see "Test label description"
And I should see "Test lesson name"
And I should see "Test lti name"
And I should see "Test page name"
And I should see "Test quiz name"
And I should see "Test resource name"
And I should see "Test scorm name"
And I should see "Test survey name"
And I should see "Test url name"
And I should see "Test wiki name"
And I should see "Test workshop name"
And I follow "Test assignment name"
And I should see "Test assignment description"
@@ -187,8 +230,6 @@ Feature: Set up contextual data for tests
Then the "groups" select box should contain "Group 1 (1)"
And the "groups" select box should contain "Group 2 (1)"
And I select "Group 1 (1)" from "groups"
And I wait "5" seconds
And the "members" select box should contain "Student 1"
And I select "Group 2 (1)" from "groups"
And I wait "5" seconds
And the "members" select box should contain "Student 2"
@@ -25,10 +25,10 @@ Feature: Edit capabilities
| moodle/grade:managesharedforms | Prevent |
| moodle/course:request | Prohibit |
When I follow "Edit Teacher role"
Then the "block/mnet_hosts:myaddinstance" field should match "1" value
And the "moodle/community:add" field should match "0" value
And the "moodle/grade:managesharedforms" field should match "-1" value
And the "moodle/course:request" field should match "-1000" value
Then "block/mnet_hosts:myaddinstance" capability has "Allow" permission
And "moodle/community:add" capability has "Not set" permission
And "moodle/grade:managesharedforms" capability has "Prevent" permission
And "moodle/course:request" capability has "Prohibit" permission
@javascript
Scenario: Course capabilities overrides
@@ -41,9 +41,9 @@ Feature: Edit capabilities
| mod/forum:editanypost | Prevent |
| mod/forum:addquestion | Allow |
When I select "Student (3)" from "Advanced role override"
Then the "mod/forum:deleteanypost" field should match "-1000" value
And the "mod/forum:editanypost" field should match "-1" value
And the "mod/forum:addquestion" field should match "1" value
Then "mod/forum:deleteanypost" capability has "Prohibit" permission
And "mod/forum:editanypost" capability has "Prevent" permission
And "mod/forum:addquestion" capability has "Allow" permission
@javascript
Scenario: Module capabilities overrides
@@ -60,6 +60,6 @@ Feature: Edit capabilities
| mod/forum:editanypost | Prevent |
| mod/forum:addquestion | Allow |
When I select "Student (3)" from "Advanced role override"
Then the "mod/forum:deleteanypost" field should match "-1000" value
And the "mod/forum:editanypost" field should match "-1" value
And the "mod/forum:addquestion" field should match "1" value
Then "mod/forum:deleteanypost" capability has "Prohibit" permission
And "mod/forum:editanypost" capability has "Prevent" permission
And "mod/forum:addquestion" capability has "Allow" permission
@@ -0,0 +1,173 @@
@tool_behat
Feature: Verify that all form fields values can be get and set
In order to use behat steps definitions
As a test writer
I need to verify it all works in real moodle forms
Background:
Given the following "courses" exists:
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And the following "users" exists:
| username | email | firstname | lastname |
| student1 | s1@asd.com | Student | 1 |
| student2 | s2@asd.com | Student | 2 |
| student3 | s3@asd.com | Student | 3 |
And the following "course enrolments" exists:
| user | course | role |
| student1 | C1 | student |
| student2 | C1 | student |
| student3 | C1 | student |
| admin | C1 | editingteacher |
And the following "groups" exists:
| name | description | course | idnumber |
| Group 1 | G1 description | C1 | G1 |
| Group 2 | G1 description | C1 | G2 |
And the following "group members" exists:
| user | group |
| student1 | G1 |
| student2 | G1 |
| student2 | G2 |
| student3 | G2 |
And the following "activities" exists:
| activity | course | idnumber | name | intro | firstpagetitle | wikimode | visible |
| wiki | C1 | wiki1 | Test this one | Test this one | Test this one | collaborative | 0 |
And I log in as "admin"
And I expand "Site administration" node
And I expand "Appearance" node
And I follow "Manage tags"
# Select (multi-select) - We will check "I fill in...".
And I fill in "otagsadd" with "OT1, OT2, OT3, OT4, OT5"
And I press "Add official tags"
And I am on homepage
And I follow "Course 1"
And I turn editing mode on
And I follow "Test this one"
And I press "Create page"
# Select (multi-select) - Checking "the select box should contain".
And the "tags[officialtags][]" select box should contain "OT1"
And the "tags[officialtags][]" select box should contain "OT2"
And the "tags[officialtags][]" select box should contain "OT3"
And the "tags[officialtags][]" select box should contain "OT4"
And the "tags[officialtags][]" select box should contain "OT5"
And the "tags[officialtags][]" select box should contain "OT1, OT2, OT3, OT4, OT5"
And the "tags[officialtags][]" select box should contain "OT5, OT4, OT3, OT2, OT1"
And the "tags[officialtags][]" select box should not contain "OT6"
And the "tags[officialtags][]" select box should not contain "OT7"
And the "tags[officialtags][]" select box should not contain "OT6, OT7"
# Text (textarea & editor) & Select (multi-select) - Checking "I fill the moodle form with".
When I fill the moodle form with:
| HTML format | Student page contents to be tagged |
| tags[officialtags][] | OT1, OT3, OT5 |
And I press "Save"
Then I should see "Student page contents to be tagged" in the "region-main" "region"
And I should see "OT1" in the ".wiki-tags" "css_element"
And I should see "OT3" in the ".wiki-tags" "css_element"
And I should see "OT5" in the ".wiki-tags" "css_element"
And I should not see "OT2" in the ".wiki-tags" "css_element"
And I should not see "OT4" in the ".wiki-tags" "css_element"
And I follow "Edit"
# Select (multi-select) - Checking "I select from".
And I select "OT2, OT4" from "tags[officialtags][]"
And I press "Save"
And I should see "OT2" in the ".wiki-tags" "css_element"
And I should see "OT4" in the ".wiki-tags" "css_element"
And I should not see "OT1" in the ".wiki-tags" "css_element"
And I should not see "OT3" in the ".wiki-tags" "css_element"
And I should not see "OT5" in the ".wiki-tags" "css_element"
And I follow "Edit"
# Select (multi-select) - Checking "the field should match" and "the field does not match value".
And the "tags[officialtags][]" field should match "OT2, OT4" value
And the field "tags[officialtags][]" does not match value "OT4"
And the field "tags[officialtags][]" does not match value "OT2"
And the field "tags[officialtags][]" does not match value "OT1, OT3, OT5"
And I press "Cancel"
And I follow "Edit settings"
And I expand all fieldsets
# Checkbox - Checking "I check".
And I check "Display description on course page"
# Checkbox - Checking "I fill the moodle form with:".
And I fill the moodle form with:
| Force format | 1 |
# Checkbox - Checking "the field should match" and "the field does not match value".
And the "Display description on course page" field should match "1" value
And the field "Display description on course page" does not match value ""
And I press "Save and return to course"
And I should see "Test this one"
And I follow "Test this one"
And I follow "Edit settings"
# Checkbox - Checking "the field should match" and "the following fields match these values".
And the following fields match these values:
| Display description on course page | 1 |
| Default format | HTML |
| Wiki name | Test this one |
And the "Force format" field should match "1" value
# Select (simple) - Checking "I fill the moodle form with:".
And I fill the moodle form with:
| Default format | NWiki |
| Display description on course page | |
# Checkbox - Checking "I uncheck".
And I uncheck "Force format"
# Select (simple) - Checking "I select from".
And I select "Separate groups" from "Group mode"
And I press "Save and display"
And I follow "Edit settings"
And the following fields match these values:
| Default format | NWiki |
| Group mode | Separate groups |
| Display description on course page | |
| Force format | |
# All fields - Checking "the following fields do not match these values".
And the following fields do not match these values:
| Wiki name | Test this one baby |
| Default format | HTML |
| Force format | 1 |
And I press "Cancel"
And I follow "Course 1"
# Radio - Checking "I check" and "the field should match".
And I add a "Choice" to section "1" and I fill the form with:
| Choice name | Test choice name |
| Description | Test choice description |
| Allow choice to be updated | Yes |
| Option 1 | one |
| Option 2 | two |
| Option 3 | three |
And I follow "Test choice name"
And I check "one"
And I press "Save my choice"
And the "one" field should match "1" value
And the "two" field should match "" value
Scenario: with JS disabled all form fields getters and setters works as expected
@javascript
Scenario: with JS enabled all form fields getters and setters works as expected
Then I follow "Course 1"
And I expand "Users" node
And I follow "Groups"
# Select (multi-select & AJAX) - Checking "I select from" and "select box should contain".
And I select "Group 2" from "groups"
And the "members" select box should contain "Student 2"
And the "members" select box should contain "Student 3"
And the "members" select box should not contain "Student 1"
And I select "Group 1" from "groups"
And the "members" select box should contain "Student 1"
And the "members" select box should contain "Student 2"
And the "members" select box should not contain "Student 3"
# Checkbox (AJAX) - Checking "I check" and "I fill the moodle form with".
And I follow "Course 1"
And I add a "Lesson" to section "1"
And I fill the moodle form with:
| Name | Test lesson |
| available[enabled] | 1 |
And I check "deadline[enabled]"
# Checkbox (AJAX) - Checking "field should match" before saving.
And the "available[enabled]" field should match "1" value
And the "available[day]" "field" should be enabled
And the "deadline[enabled]" field should match "1" value
And I press "Save and display"
And I follow "Edit settings"
And the "available[enabled]" field should match "1" value
And the "available[day]" "field" should be enabled
And the "deadline[enabled]" field should match "1" value
And I press "Cancel"
@@ -32,5 +32,5 @@ Feature: Forms manipulation
Then I should see "Close the quiz"
And I should see "Group mode"
And I should see "Grouping"
And I should not see "Show more..." in the "region-main-box" "region"
And I should not see "Show more..." in the "region-main" "region"
And I should see "Show less..."
@@ -173,6 +173,9 @@ class tool_behat_testcase extends advanced_testcase {
// directories values.
$this->assertContains($CFG->dirroot . DIRECTORY_SEPARATOR . 'lib' . DIRECTORY_SEPARATOR . 'behat' . DIRECTORY_SEPARATOR . 'features', $contents);
// If it was empty should be filled by behat_config_manager::get_config_file_contents().
$this->assertNotNull($CFG->behat_wwwroot);
// Not quoted strings.
$this->assertContains('micarro: /me/lo/robaron', $contents);
$this->assertContains('class: behat_init_context', $contents);
@@ -183,6 +186,8 @@ class tool_behat_testcase extends advanced_testcase {
// Lists.
$this->assertContains('- feature1', $contents);
$this->assertContains('- feature3', $contents);
unset($CFG->behat_wwwroot);
}
}
+1 -1
View File
@@ -24,6 +24,6 @@
defined('MOODLE_INTERNAL') || die();
$plugin->version = 2013110500;
$plugin->version = 2013110501;
$plugin->requires = 2013110500; // Requires Moodle 2.5.
$plugin->component = 'tool_behat';
+9 -3
View File
@@ -74,9 +74,15 @@ function tool_capability_calculate_role_data($capability, array $roles) {
// Put the contexts into a tree structure.
foreach ($contexts as $conid => $con) {
$context = context::instance_by_id($conid);
$parentcontext = $context->get_parent_context();
if ($parentcontext) {
$contexts[$parentcontext->id]->children[] = $conid;
try {
$parentcontext = $context->get_parent_context();
if ($parentcontext) { // Will be false if $context is the system context.
$contexts[$parentcontext->id]->children[] = $conid;
}
} catch (dml_missing_record_exception $e) {
// Ignore corrupt context tree structure here. Don't let it break
// showing the rest of the report.
continue;
}
}
+1 -1
View File
@@ -87,7 +87,7 @@ class tool_capability_renderer extends plugin_renderer_base {
$table->attributes['class'] = 'comparisontable';
$table->head = array('&nbsp;');
foreach ($roles as $role) {
$url = new moodle_url('/admin/roles/override.php', array('contextid' => $contextid, 'roleid' => $role->id));
$url = new moodle_url('/admin/roles/define.php', array('action' => 'view', 'roleid' => $role->id));
$table->head[] = html_writer::div(html_writer::link($url, $role->localname));
}
$table->data = array();
+3
View File
@@ -42,5 +42,8 @@ function xmldb_tool_customlang_upgrade($oldversion) {
// Put any upgrade step following this.
// Moodle v2.6.0 release upgrade line.
// Put any upgrade step following this.
return true;
}
@@ -23,5 +23,7 @@
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
$string['multilangupgradeinfo'] = 'The multilang filter syntax was changed in 1.8, &lt;lang&gt; tag is not supported any more. <br /><br />Example: &lt;span lang="en" class="multilang">Hello!&lt;/span&gt;&lt;span lang="es" class="multilang">Hola!&lt;/span&gt;<br /><br /><strong>Do you want to upgrade the syntax in all existing texts now?</strong>';
$string['multilangupgradeinfo'] = '<p>The multilang filter syntax was changed in 1.8 and so the &lt;lang&gt; tag is not supported any more.</p>
<p>Example: &lt;span lang="en" class="multilang"&gt;Hello!&lt;/span&gt;&lt;span lang="es" class="multilang"&gt;Hola!&lt;/span&gt;</p>
<p>Do you want to upgrade the syntax in all existing texts now?</p>';
$string['pluginname'] = 'Multilang upgrade';
@@ -46,7 +46,7 @@ class tool_qeupgradehelper_extract_options_form extends moodleform {
$qtypes = core_component::get_plugin_list('qtype');
foreach ($qtypes as $qtype => $notused) {
$qtypes[$qtype] = get_string($qtype, 'qtype_' . $qtype);
$qtypes[$qtype] = get_string('pluginname', 'qtype_' . $qtype);
}
$mform->addElement('header', 'h1', 'Either extract a specific question_session');
+69
View File
@@ -0,0 +1,69 @@
<?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/>.
/**
* Site wide search-replace form.
*
* @package tool_replace
* @copyright 2013 Petr Skoda {@link http://skodak.org}
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
defined('MOODLE_INTERNAL') || die();
require_once("$CFG->libdir/formslib.php");
/**
* Site wide search-replace form.
*/
class tool_replace_form extends moodleform {
function definition() {
global $CFG, $DB;
$mform = $this->_form;
$mform->addElement('header', 'searchhdr', get_string('pluginname', 'tool_replace'));
$mform->setExpanded('searchhdr', true);
$mform->addElement('text', 'search', get_string('searchwholedb', 'tool_replace'), 'size="50"');
$mform->setType('search', PARAM_RAW);
$mform->addElement('static', 'searchst', '', get_string('searchwholedbhelp', 'tool_replace'));
$mform->addRule('search', get_string('required'), 'required', null, 'client');
$mform->addElement('text', 'replace', get_string('replacewith', 'tool_replace'), 'size="50"', PARAM_RAW);
$mform->addElement('static', 'replacest', '', get_string('replacewithhelp', 'tool_replace'));
$mform->setType('replace', PARAM_RAW);
$mform->addElement('checkbox', 'shorten', get_string('shortenoversized', 'tool_replace'));
$mform->addRule('replace', get_string('required'), 'required', null, 'client');
$mform->addElement('header', 'confirmhdr', get_string('confirm'));
$mform->setExpanded('confirmhdr', true);
$mform->addElement('checkbox', 'sure', get_string('disclaimer', 'tool_replace'));
$mform->addRule('sure', get_string('required'), 'required', null, 'client');
$this->add_action_buttons(false, get_string('doit', 'tool_replace'));
}
function validation($data, $files) {
$errors = parent::validation($data, $files);
if (empty($data['shorten']) and core_text::strlen($data['search']) < core_text::strlen($data['replace'])) {
$errors['shorten'] = get_string('required');
}
return $errors;
}
}
+20 -39
View File
@@ -17,8 +17,7 @@
/**
* Search and replace strings throughout all texts in the whole database
*
* @package tool
* @subpackage replace
* @package tool_replace
* @copyright 1999 onwards Martin Dougiamas (http://dougiamas.com)
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
@@ -31,56 +30,38 @@ require_once($CFG->libdir.'/adminlib.php');
admin_externalpage_setup('toolreplace');
$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(get_string('pageheader', 'tool_replace'));
if ($DB->get_dbfamily() !== 'mysql' and $DB->get_dbfamily() !== 'postgres') {
//TODO: add $DB->text_replace() to DML drivers
if (!$DB->replace_all_text_supported()) {
echo $OUTPUT->notification(get_string('notimplemented', 'tool_replace'));
echo $OUTPUT->footer();
die;
}
if (!data_submitted() or !$search or !$replace or !confirm_sesskey() or !$sure) { /// Print a form
echo $OUTPUT->notification(get_string('notsupported', 'tool_replace'));
echo $OUTPUT->notification(get_string('excludedtables', 'tool_replace'));
echo $OUTPUT->box_start();
echo '<div class="mdl-align">';
echo '<form action="index.php" method="post"><div>';
echo '<input type="hidden" name="sesskey" value="'.sesskey().'" />';
echo '<div><label for="search">'.get_string('searchwholedb', 'tool_replace').
' </label><input id="search" type="text" name="search" size="40" /> ('.
get_string('searchwholedbhelp', 'tool_replace').')</div>';
echo '<div><label for="replace">'.get_string('replacewith', 'tool_replace').
' </label><input type="text" id="replace" name="replace" size="40" /> ('.
get_string('replacewithhelp', 'tool_replace').')</div>';
echo '<div><label for="sure">'.get_string('disclaimer', 'tool_replace').' </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();
die;
}
echo $OUTPUT->box_start();
db_replace($search, $replace);
echo $OUTPUT->notification(get_string('notsupported', 'tool_replace'));
echo $OUTPUT->notification(get_string('excludedtables', 'tool_replace'));
echo $OUTPUT->box_end();
/// Rebuild course cache which might be incorrect now
echo $OUTPUT->notification(get_string('notifyrebuilding', 'tool_replace'), 'notifysuccess');
rebuild_course_cache();
echo $OUTPUT->notification(get_string('notifyfinished', 'tool_replace'), 'notifysuccess');
$form = new tool_replace_form();
if (!$data = $form->get_data()) {
$form->display();
echo $OUTPUT->footer();
die();
}
// Scroll to the end when finished.
$PAGE->requires->js_init_code("window.scrollTo(0, 5000000);");
echo $OUTPUT->box_start();
db_replace($data->search, $data->replace);
echo $OUTPUT->box_end();
// Course caches are now rebuilt on the fly.
echo $OUTPUT->continue_button(new moodle_url('/admin/index.php'));
echo $OUTPUT->footer();
+7 -4
View File
@@ -23,15 +23,18 @@
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
$string['disclaimer'] = 'I understand the risks of this operation:';
$string['cannotfit'] = 'The replacement is longer than original and shortening is not allow, cannot continue.';
$string['disclaimer'] = 'I understand the risks of this operation';
$string['doit'] = 'Yes, do it!';
$string['excludedtables'] = 'Several tables are not updated as part of the text replacement. This include configuration, log, events, and session tables.';
$string['pageheader'] = 'Search and replace text throughout the whole database';
$string['notifyfinished'] = '...finished';
$string['notifyrebuilding'] = 'Rebuilding course cache...';
$string['notimplemented'] = 'Sorry, this feature is implemented only for MySQL and PostgreSQL databases.';
$string['notimplemented'] = 'Sorry, this feature is not implemented in your database driver.';
$string['notsupported'] ='This script is not supported, always make complete backup before proceeding!<br />This operation can not be reverted!';
$string['pluginname'] = 'DB search and replace';
$string['replacewith'] = 'Replace with this string:';
$string['replacewith'] = 'Replace with this string';
$string['replacewithhelp'] = 'usually new server URL';
$string['searchwholedb'] = 'Search whole database for:';
$string['searchwholedb'] = 'Search whole database for';
$string['searchwholedbhelp'] = 'usually previous server URL';
$string['shortenoversized'] = 'Shorten result if necessary';
+1 -1
View File
@@ -25,7 +25,7 @@
defined('MOODLE_INTERNAL') || die();
$plugin->version = 2013110500; // The current plugin version (Date: YYYYMMDDXX)
$plugin->version = 2013110501; // The current plugin version (Date: YYYYMMDDXX)
$plugin->requires = 2013110500; // Requires this Moodle version
$plugin->component = 'tool_replace'; // Full name of the plugin (used for diagnostics)
+41 -7
View File
@@ -178,13 +178,47 @@ function search_spammers($keywords) {
$conditions6 = '( '.implode(' OR ', $keywordfull6).' )';
$conditions7 = '( '.implode(' OR ', $keywordfull7).' )';
$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";
$sql3 = "SELECT u.*, p.subject as postsubject FROM {user} AS u, {post} AS p WHERE $conditions3 AND u.deleted = 0 AND u.id=p.userid AND u.id <> :userid";
$sql4 = "SELECT u.*, c.content FROM {user} AS u, {comments} AS c WHERE $conditions4 AND u.deleted = 0 AND u.id=c.userid AND u.id <> :userid";
$sql5 = "SELECT u.*, m.fullmessage FROM {user} AS u, {message} AS m WHERE $conditions5 AND u.deleted = 0 AND u.id=m.useridfrom AND u.id <> :userid";
$sql6 = "SELECT u.*, fp.message FROM {user} AS u, {forum_posts} AS fp WHERE $conditions6 AND u.deleted = 0 AND u.id=fp.userid AND u.id <> :userid";
$sql7 = "SELECT u.*, fp.subject FROM {user} AS u, {forum_posts} AS fp WHERE $conditions7 AND u.deleted = 0 AND u.id=fp.userid AND u.id <> :userid";
$sql = "SELECT *
FROM {user}
WHERE deleted = 0
AND id <> :userid
AND $conditions"; // Exclude oneself
$sql2 = "SELECT u.*, p.summary
FROM {user} u, {post} p
WHERE $conditions2
AND u.deleted = 0
AND u.id=p.userid
AND u.id <> :userid";
$sql3 = "SELECT u.*, p.subject AS postsubject
FROM {user} u, {post} p
WHERE $conditions3
AND u.deleted = 0
AND u.id=p.userid
AND u.id <> :userid";
$sql4 = "SELECT u.*, c.content
FROM {user} u, {comments} c
WHERE $conditions4
AND u.deleted = 0
AND u.id=c.userid
AND u.id <> :userid";
$sql5 = "SELECT u.*, m.fullmessage
FROM {user} u, {message} m
WHERE $conditions5
AND u.deleted = 0
AND u.id=m.useridfrom
AND u.id <> :userid";
$sql6 = "SELECT u.*, fp.message
FROM {user} u, {forum_posts} fp
WHERE $conditions6
AND u.deleted = 0
AND u.id=fp.userid
AND u.id <> :userid";
$sql7 = "SELECT u.*, fp.subject
FROM {user} u, {forum_posts} fp
WHERE $conditions7
AND u.deleted = 0
AND u.id=fp.userid
AND u.id <> :userid";
$spamusers_desc = $DB->get_recordset_sql($sql, $params);
$spamusers_blog = $DB->get_recordset_sql($sql2, $params);
@@ -27,7 +27,8 @@ $string['pluginname'] = 'Spam cleaner';
$string['spamauto'] = 'Autodetect common spam patterns';
$string['spamcannotdelete'] = 'Cannot delete this user';
$string['spamcannotfinduser'] = 'No users matching your search';
$string['spamcleanerintro'] = 'This script allows you to search all user profiles for certain strings and then delete those accounts which are obviously created by spammers. You can search for multiple keywords using commas (eg casino, porn)<br /><br />Moodle docs has more information about <a href="http://docs.moodle.org/en/Reducing_spam_in_Moodle">Reducing spam in Moodle</a>.';
$string['spamcleanerintro'] = '<p>This script allows you to search all user profiles for certain strings and then delete those accounts which are obviously created by spammers. You can search for multiple keywords using commas (e.g. casino, porn).</p>
<p>For further information, see the documentation <a href="http://docs.moodle.org/en/Reducing_spam_in_Moodle">Reducing spam in Moodle</a>.</p>';
$string['spamdeleteall'] = 'Delete all these user accounts';
$string['spamdeleteallconfirm'] = 'Are you sure you want to delete all these user accounts? You can not undo this.';
$string['spamdeleteconfirm'] = 'Are you sure you want to delete this entry? You can not undo this.';
@@ -1,4 +1,4 @@
@tool @tool_uploadcourse @_only_local
@tool @tool_uploadcourse @_only_local @_file_upload
Feature: An admin can create courses using a CSV file
In order to create courses using a CSV file
As an admin
@@ -15,7 +15,7 @@ Feature: An admin can create courses using a CSV file
@javascript
Scenario: Creation of unexisting courses
Given I upload "admin/tool/uploadcourse/tests/fixtures/courses.csv" file to "File" filepicker
Given I upload "admin/tool/uploadcourse/tests/fixtures/courses.csv" file to "File" filemanager
And I click on "Preview" "button"
When I click on "Upload courses" "button"
Then I should see "The course exists and update is not allowed"
@@ -29,7 +29,7 @@ Feature: An admin can create courses using a CSV file
@javascript
Scenario: Creation of existing courses
Given I upload "admin/tool/uploadcourse/tests/fixtures/courses.csv" file to "File" filepicker
Given I upload "admin/tool/uploadcourse/tests/fixtures/courses.csv" file to "File" filemanager
And I select "Create all, increment shortname if needed" from "Upload mode"
And I click on "Preview" "button"
When I click on "Upload courses" "button"
@@ -1,4 +1,4 @@
@tool @tool_uploadcourse @_only_local
@tool @tool_uploadcourse @_only_local @_file_upload
Feature: An admin can update courses using a CSV file
In order to update courses using a CSV file
As an admin
@@ -15,7 +15,7 @@ Feature: An admin can update courses using a CSV file
@javascript
Scenario: Updating a course fullname
Given I upload "admin/tool/uploadcourse/tests/fixtures/courses.csv" file to "File" filepicker
Given I upload "admin/tool/uploadcourse/tests/fixtures/courses.csv" file to "File" filemanager
And I select "Only update existing courses" from "Upload mode"
And I select "Update with CSV data only" from "Update mode"
And I click on "Preview" "button"
+8 -11
View File
@@ -123,12 +123,11 @@ if (empty($iid)) {
$content = $mform1->get_file_content('userfile');
$readcount = $cir->load_csv_content($content, $formdata->encoding, $formdata->delimiter_name);
$csvloaderror = $cir->get_error();
unset($content);
if ($readcount === false) {
print_error('csvloaderror', '', $returnurl);
} else if ($readcount == 0) {
print_error('csvemptyfile', 'error', $returnurl);
if (!is_null($csvloaderror)) {
print_error('csvloaderror', '', $returnurl, $csvloaderror);
}
// test if columns ok
$filecolumns = uu_validate_user_upload_columns($cir, $STD_FIELDS, $PRF_FIELDS, $returnurl);
@@ -235,10 +234,10 @@ if ($formdata = $mform2->is_cancelled()) {
$user->$key['text'] = $value;
$user->$key['format'] = FORMAT_MOODLE;
} else {
$user->$key = $value;
$user->$key = trim($value);
}
} else {
$user->$key = $value;
$user->$key = trim($value);
}
if (in_array($key, $upt->columns)) {
@@ -550,8 +549,6 @@ if ($formdata = $mform2->is_cancelled()) {
continue;
}
if (!property_exists($user, $column) or !property_exists($existinguser, $column)) {
// this should never happen
debugging("Could not find $column on the user objects", DEBUG_DEVELOPER);
continue;
}
if ($updatetype == UU_UPDATE_MISSING) {
@@ -966,7 +963,7 @@ if ($formdata = $mform2->is_cancelled()) {
$status = null;
if (isset($user->{'enrolstatus'.$i})) {
$enrolstatus = trim($user->{'enrolstatus'.$i});
$enrolstatus = $user->{'enrolstatus'.$i};
if ($enrolstatus == '') {
$status = null;
} else if ($enrolstatus === (string)ENROL_USER_ACTIVE) {
@@ -1109,7 +1106,7 @@ while ($linenum <= $previewrows and $fields = $cir->next()) {
$rowcols = array();
$rowcols['line'] = $linenum;
foreach($fields as $key => $field) {
$rowcols[$filecolumns[$key]] = s($field);
$rowcols[$filecolumns[$key]] = s(trim($field));
}
$rowcols['status'] = array();
@@ -1135,7 +1132,7 @@ while ($linenum <= $previewrows and $fields = $cir->next()) {
}
if (isset($rowcols['city'])) {
$rowcols['city'] = trim($rowcols['city']);
$rowcols['city'] = $rowcols['city'];
}
// Check if rowcols have custom profile field with correct data and update error state.
$noerror = uu_check_custom_profile_data($rowcols) && $noerror;
@@ -53,6 +53,8 @@ class check_foreign_keys extends XMLDBCheckAction {
'noviolatedforeignkeysfound' => 'tool_xmldb',
'violatedforeignkeysfound' => 'tool_xmldb',
'violations' => 'tool_xmldb',
'unknowntable' => 'tool_xmldb',
'unknownfield' => 'tool_xmldb',
));
}
@@ -75,6 +77,19 @@ class check_foreign_keys extends XMLDBCheckAction {
}
$o.=' <li>' . $this->str['key'] . ': ' . $xmldb_key->readableInfo() . ' ';
$reftable = $xmldb_key->getRefTable();
if (!$dbman->table_exists($reftable)) {
$o.='<font color="red">' . $this->str['unknowntable'] . '</font>';
// Add the missing index to the list
$violation = new stdClass();
$violation->string = 'fkunknowntable';
$violation->table = $xmldb_table;
$violation->key = $xmldb_key;
$violation->reftable = $reftable;
$violatedkeys[] = $violation;
continue;
}
// Work out the SQL to find key violations.
$keyfields = $xmldb_key->getFields();
$reffields = $xmldb_key->getRefFields();
@@ -82,6 +97,19 @@ class check_foreign_keys extends XMLDBCheckAction {
$nullnessconditions = array();
$params = array();
foreach ($keyfields as $i => $field) {
if (!$dbman->field_exists($reftable, $reffields[$i])) {
$o.='<font color="red">' . $this->str['unknownfield'] . '</font>';
// Add the missing index to the list
$violation = new stdClass();
$violation->string = 'fkunknownfield';
$violation->table = $xmldb_table;
$violation->key = $xmldb_key;
$violation->reftable = $reftable;
$violation->reffield = $reffields[$i];
$violatedkeys[] = $violation;
continue 2;
}
$joinconditions[] = 't1.' . $field . ' = t2.' . $reffields[$i];
$xmldb_field = $xmldb_table->getField($field);
$default = $xmldb_field->getDefault();
@@ -97,7 +125,7 @@ class check_foreign_keys extends XMLDBCheckAction {
}
$nullnessconditions[] = 't2.id IS NULL';
$sql = 'SELECT count(1) FROM {' . $xmldb_table->getName() .
'} t1 LEFT JOIN {' . $xmldb_key->getRefTable() . '} t2 ON ' .
'} t1 LEFT JOIN {' . $reftable . '} t2 ON ' .
implode(' AND ', $joinconditions) . ' WHERE ' .
implode(' AND ', $nullnessconditions);
@@ -109,6 +137,7 @@ class check_foreign_keys extends XMLDBCheckAction {
$o.='<font color="red">' . $this->str['violations'] . '</font>';
// Add the missing index to the list
$violation = new stdClass;
$violation->string = 'fkviolationdetails';
$violation->table = $xmldb_table;
$violation->key = $xmldb_key;
$violation->numviolations = $violations;
@@ -145,8 +174,11 @@ class check_foreign_keys extends XMLDBCheckAction {
$violation->tablename = $violation->table->getName();
$violation->keyname = $violation->key->getName();
$r.= ' <li>' .get_string('fkviolationdetails', 'tool_xmldb', $violation) .
'<pre>' . s($violation->sql) . '; ' . s($violation->sqlparams) . '</pre></li>';
$r.= ' <li>' .get_string($violation->string, 'tool_xmldb', $violation);
if (!empty($violation->sql)) {
$r.= '<pre>' . s($violation->sql) . '; ' . s($violation->sqlparams) . '</pre>';
}
$r.= '</li>';
}
$r.= ' </ul>';
} else {
+12 -4
View File
@@ -106,6 +106,8 @@ $string['fieldsusedinindex'] = 'This field is used as index';
$string['fieldsusedinkey'] = 'This field is used as key.';
$string['filemodifiedoutfromeditor'] = 'Warning: File locally modified while using the XMLDB Editor. Saving will overwrite local changes.';
$string['filenotwriteable'] = 'File not writeable';
$string['fkunknownfield'] = 'Foreign key {$a->keyname} on table {$a->tablename} points to a non-existent field {$a->reffield} in referenced table {$a->reftable}.';
$string['fkunknowntable'] = 'Foreign key {$a->keyname} on table {$a->tablename} points to a non-existent table {$a->reftable}.';
$string['fkviolationdetails'] = 'Foreign key {$a->keyname} on table {$a->tablename} is violated by {$a->numviolations} out of {$a->numrows} rows.';
$string['floatincorrectdecimals'] = 'Incorrect number of decimals for float field';
$string['floatincorrectlength'] = 'Incorrect length for float field';
@@ -183,6 +185,8 @@ $string['selecttable'] = 'Select table:';
$string['table'] = 'Table';
$string['tablenameempty'] = 'The table name cannot be empty';
$string['tables'] = 'Tables';
$string['unknownfield'] = 'Refers to an unknown field';
$string['unknowntable'] = 'Refers to an unknown table';
$string['unload'] = 'Unload';
$string['up'] = 'Up';
$string['view'] = 'View';
@@ -206,7 +210,11 @@ $string['wronglengthforenum'] = 'Incorrect length for enum field';
$string['wrongnumberofreffields'] = 'Wrong number of reference fields';
$string['wrongreservedwords'] = 'Currently used reserved words<br />(note that table names aren\'t important if using $CFG->prefix)';
$string['wrongoraclesemantics'] = 'Wrong Oracle BYTE semantics found';
$string['yesmissingindexesfound'] = 'Some missing indexes have been found in your DB. Here are their details and the needed SQL statements to be executed with your favourite SQL interface to create all them (don\'t forget to backup your data before doing that).<br /><br />After doing that, it\'s highly recommended to execute this utility again to check that no more missing indexes are found.';
$string['yeswrongdefaultsfound'] = 'Some inconsistent defaults have been found in your DB. Here are their details and the needed SQL statements to be executed with your favourite SQL interface to fix them all (don\'t forget to backup your data before doing that).<br /><br />After doing that, it\'s highly recommended to execute this utility again to check that no more inconsistent defaults are found.';
$string['yeswrongintsfound'] = 'Some wrong integers have been found in your DB. Here are their details and the needed SQL statements to be executed with your favourite SQL interface to create all them (don\'t forget to backup your data before doing that).<br /><br />After doing that, it\'s highly recommended to execute this utility again to check that no more wrong integers are found.';
$string['yeswrongoraclesemanticsfound'] = 'Some Oracle columns using BYTE semantics have been found in your DB. Here are their details and the needed SQL statements to be executed with your favourite SQL interface to create all them (don\'t forget to backup your data before doing that).<br /><br />After doing that, it\'s highly recommended to execute this utility again to check that no more wrong semantics are found.';
$string['yesmissingindexesfound'] = '<p>Some missing indexes have been found in your DB. Here are their details and the needed SQL statements to be executed with your favourite SQL interface to create all of them. Remember to backup your data first!</p>
<p>After doing that, it\'s highly recommended to execute this utility again to check that no more missing indexes are found.</p>';
$string['yeswrongdefaultsfound'] = '<p>Some inconsistent defaults have been found in your DB. Here are their details and the needed SQL statements to be executed with your favourite SQL interface to fix them all. Remember to backup your data first!</p>
<p>After doing that, it\'s highly recommended to execute this utility again to check that no more inconsistent defaults are found.</p>';
$string['yeswrongintsfound'] = '<p>Some wrong integers have been found in your DB. Here are their details and the needed SQL statements to be executed with your favourite SQL interface to create all them. Remember to backup your data first!</p>
<p>After doing that, it\'s highly recommended to execute this utility again to check that no more wrong integers are found.</p>';
$string['yeswrongoraclesemanticsfound'] = '<p>Some Oracle columns using BYTE semantics have been found in your DB. Here are their details and the needed SQL statements to be executed with your favourite SQL interface to create all them. Remember to backup your data first!</p>
<p>After doing that, it\'s highly recommended to execute this utility again to check that no more wrong semantics are found.</p>';
+5
View File
@@ -10,6 +10,11 @@ $return = optional_param('return', '', PARAM_ALPHA);
/// no guest autologin
require_login(0, false);
if (isguestuser()) {
// Login as real user!
$SESSION->wantsurl = (string)new moodle_url('/admin/upgradesettings.php', array('return'=>$return));
redirect(get_login_url());
}
admin_externalpage_setup('upgradesettings'); // now hidden page
$PAGE->set_pagelayout('maintenance'); // do not print any blocks or other rubbish, we want to force saving
+8 -6
View File
@@ -207,12 +207,14 @@ class web_service_token_form extends moodleform {
if ($usertotal < 500) {
list($sort, $params) = users_order_by_sql('u');
//user searchable selector - get all users (admin and guest included)
//user must be confirmed, not deleted, not suspended, not guest
$sql = "SELECT u.id, u.firstname, u.lastname
FROM {user} u
WHERE u.deleted = 0 AND u.confirmed = 1 AND u.suspended = 0 AND u.id != :siteguestid
ORDER BY $sort";
// User searchable selector - return users who are confirmed, not deleted, not suspended and not a guest.
$sql = 'SELECT u.id, ' . get_all_user_name_fields(true, 'u') . '
FROM {user} u
WHERE u.deleted = 0
AND u.confirmed = 1
AND u.suspended = 0
AND u.id != :siteguestid
ORDER BY ' . $sort;
$params['siteguestid'] = $CFG->siteguest;
$users = $DB->get_records_sql($sql, $params);
$options = array();
+1 -1
View File
@@ -68,7 +68,7 @@ if ($usersettingsform->is_cancelled()) {
//TODO: assign capability
//display successful notification
$notification = $OUTPUT->notification(get_string('usersettingssaved', 'webservice'), 'success');
$notification = $OUTPUT->notification(get_string('usersettingssaved', 'webservice'), 'notifysuccess');
}
echo $OUTPUT->header();
+1
View File
@@ -422,6 +422,7 @@ class auth_plugin_cas extends auth_plugin_ldap {
// Test for group creator
if (!empty($this->config->groupecreators)) {
$ldapconnection = $this->ldap_connect();
if ($this->config->memberattribute_isdn) {
if(!($userid = $this->ldap_find_userdn($ldapconnection, $extusername))) {
return false;
+3
View File
@@ -49,5 +49,8 @@ function xmldb_auth_cas_upgrade($oldversion) {
upgrade_plugin_savepoint(true, 2013091700, 'auth', 'cas');
}
// Moodle v2.6.0 release upgrade line.
// Put any upgrade step following this.
return true;
}
+3
View File
@@ -399,6 +399,9 @@ class auth_plugin_db extends auth_plugin_base {
if (empty($user->lang)) {
$user->lang = $CFG->lang;
}
if (empty($user->calendartype)) {
$user->calendartype = $CFG->calendartype;
}
$user->timecreated = time();
$user->timemodified = $user->timecreated;
if ($collision = $DB->get_record_select('user', "username = :username AND mnethostid = :mnethostid AND auth <> :auth", array('username'=>$user->username, 'mnethostid'=>$CFG->mnet_localhost_id, 'auth'=>$this->authtype), 'id,username,auth')) {
+3
View File
@@ -90,6 +90,9 @@ class auth_plugin_email extends auth_plugin_base {
require_once($CFG->dirroot.'/user/lib.php');
$user->password = hash_internal_user_password($user->password);
if (empty($user->calendartype)) {
$user->calendartype = $CFG->calendartype;
}
$user->id = user_create_user($user, false);
+12 -4
View File
@@ -616,7 +616,6 @@ class auth_plugin_ldap extends auth_plugin_base {
if ($user->firstaccess == 0) {
$user->firstaccess = time();
}
require_once($CFG->dirroot.'/user/lib.php');
user_update_user($user, false);
return AUTH_CONFIRM_OK;
}
@@ -945,6 +944,9 @@ class auth_plugin_ldap extends auth_plugin_base {
if (empty($user->lang)) {
$user->lang = $CFG->lang;
}
if (empty($user->calendartype)) {
$user->calendartype = $CFG->calendartype;
}
$id = user_create_user($user, false);
echo "\t"; print_string('auth_dbinsertuser', 'auth_db', array('name'=>$user->username, 'id'=>$id)); echo "\n";
@@ -1180,6 +1182,7 @@ class auth_plugin_ldap extends auth_plugin_base {
return false;
}
$success = true;
$user_info_result = ldap_read($ldapconnection, $user_dn, '(objectClass=*)', $search_attribs);
if ($user_info_result) {
$user_entry = ldap_get_entries_moodle($ldapconnection, $user_info_result);
@@ -1234,8 +1237,10 @@ class auth_plugin_ldap extends auth_plugin_base {
if ($nuvalue !== $ldapvalue) {
// This might fail due to schema validation
if (@ldap_modify($ldapconnection, $user_dn, array($ldapkey => $nuvalue))) {
$changed = true;
continue;
} else {
$success = false;
error_log($this->errorlogtag.get_string ('updateremfail', 'auth_ldap',
array('errno'=>ldap_errno($ldapconnection),
'errstring'=>ldap_err2str(ldap_errno($ldapconnection)),
@@ -1254,6 +1259,7 @@ class auth_plugin_ldap extends auth_plugin_base {
$changed = true;
continue;
} else {
$success = false;
error_log($this->errorlogtag.get_string ('updateremfail', 'auth_ldap',
array('errno'=>ldap_errno($ldapconnection),
'errstring'=>ldap_err2str(ldap_errno($ldapconnection)),
@@ -1271,6 +1277,7 @@ class auth_plugin_ldap extends auth_plugin_base {
$changed = true;
continue;
} else {
$success = false;
error_log($this->errorlogtag.get_string ('updateremfail', 'auth_ldap',
array('errno'=>ldap_errno($ldapconnection),
'errstring'=>ldap_err2str(ldap_errno($ldapconnection)),
@@ -1284,6 +1291,7 @@ class auth_plugin_ldap extends auth_plugin_base {
}
if ($ambiguous and !$changed) {
$success = false;
error_log($this->errorlogtag.get_string ('updateremfailamb', 'auth_ldap',
array('key'=>$key,
'ouvalue'=>$ouvalue,
@@ -1293,12 +1301,11 @@ class auth_plugin_ldap extends auth_plugin_base {
}
} else {
error_log($this->errorlogtag.get_string ('usernotfound', 'auth_ldap'));
$this->ldap_close();
return false;
$success = false;
}
$this->ldap_close();
return true;
return $success;
}
@@ -1527,6 +1534,7 @@ class auth_plugin_ldap extends auth_plugin_base {
array_push($contexts, $this->config->create_context);
}
$ldap_cookie = '';
$ldap_pagedresults = ldap_paged_results_supported($this->config->ldap_version);
foreach ($contexts as $context) {
$context = trim($context);
+3
View File
@@ -39,5 +39,8 @@ function xmldb_auth_ldap_upgrade($oldversion) {
upgrade_plugin_savepoint(true, 2013052100, 'auth', 'ldap');
}
// Moodle v2.6.0 release upgrade line.
// Put any upgrade step following this.
return true;
}
+2 -4
View File
@@ -268,10 +268,8 @@ class auth_ldap_plugin_testcase extends advanced_testcase {
$sink->close();
// Check that the event is valid.
$this->assertCount(2, $events);
$event = $events[0];
$this->assertInstanceOf('\core\event\user_updated', $event);
$event = $events[1];
$this->assertCount(1, $events);
$event = reset($events);
$this->assertInstanceOf('\core\event\user_loggedin', $event);
$this->assertEquals('user', $event->objecttable);
$this->assertEquals('2', $event->objectid);
+3
View File
@@ -44,5 +44,8 @@ function xmldb_auth_manual_upgrade($oldversion) {
// Put any upgrade step following this.
// Moodle v2.6.0 release upgrade line.
// Put any upgrade step following this.
return true;
}
-1
View File
@@ -941,7 +941,6 @@ class auth_plugin_mnet extends auth_plugin_base {
// run the keepalive client
$this->keepalive_client();
// admin/cron.php should have run srand for us
$random100 = rand(0,100);
if ($random100 < 10) { // Approximately 10% of the time.
// nuke olden sessions
+3
View File
@@ -44,5 +44,8 @@ function xmldb_auth_mnet_upgrade($oldversion) {
// Put any upgrade step following this.
// Moodle v2.6.0 release upgrade line.
// Put any upgrade step following this.
return true;
}
+36 -3
View File
@@ -18,7 +18,7 @@
/**
* Basic authentication steps definitions.
*
* @package core
* @package core_auth
* @category test
* @copyright 2012 David Monllaó
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
@@ -34,7 +34,7 @@ use Behat\Behat\Context\Step\When as When;
/**
* Log in log out steps definitions.
*
* @package core
* @package core_auth
* @category test
* @copyright 2012 David Monllaó
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
@@ -48,12 +48,45 @@ class behat_auth extends behat_base {
*/
public function i_log_in_as($username) {
return array(new Given('I am on homepage'),
// Running this step using the API rather than a chained step because
// we need to see if the 'Log in' link is available or we need to click
// the dropdown to expand the navigation bar before.
$this->getSession()->visit($this->locate_path('/'));
// Generic steps (we will prefix them later expanding the navigation dropdown if necessary).
$steps = array(
new Given('I follow "' . get_string('login') . '"'),
new Given('I fill in "' . get_string('username') . '" with "' . $this->escape($username) . '"'),
new Given('I fill in "' . get_string('password') . '" with "'. $this->escape($username) . '"'),
new Given('I press "' . get_string('login') . '"')
);
// If Javascript is disabled we have enough with these steps.
if (!$this->running_javascript()) {
return $steps;
}
// Wait for the homepage to be ready.
$this->getSession()->wait(self::TIMEOUT * 1000, self::PAGE_READY_JS);
// Checking if we need to click the navbar button to show the navigation menu, it
// is hidden by default when using clean theme and a medium or small size screen size.
// The DOM and the JS should be all ready and loaded. Running without spinning
// as this is a widely used step and we can not spend time here trying to see
// a DOM node that is not always there (at the moment clean is not even the
// default theme...).
$navbuttonjs = "return (
Y.one('.btn-navbar') &&
Y.one('.btn-navbar').getComputedStyle('display') !== 'none'
)";
// Adding an extra click we need to show the 'Log in' link.
if ($this->getSession()->getDriver()->evaluateScript($navbuttonjs)) {
array_unshift($steps, new Given('I click on ".btn-navbar" "css_element"'));
}
return $steps;
}
/**
+7 -1
View File
@@ -4,8 +4,14 @@ Feature: Authentication
As a user
I need to log into the system
Scenario: Log in with the predefined admin user
Scenario: Log in with the predefined admin user with Javascript disabled
Given I log in as "admin"
Then I should see "You are logged in as Admin User"
@javascript
Scenario: Log in with the predefined admin user with Javascript enabled
Given I log in as "admin"
Then I should see "You are logged in as Admin User"
Scenario: Log in as an existing admin user filling the form
Given the following "users" exists:
+1 -1
View File
@@ -126,7 +126,7 @@ abstract class backup implements checksumable {
const OPERATION_RESTORE ='restore';// We are performing one restore
// Version (to keep CFG->backup_version (and release) updated automatically)
const VERSION = 2013110500;
const VERSION = 2013111800;
const RELEASE = '2.6';
}
+7
View File
@@ -130,6 +130,13 @@ if ($backup->get_stage() == backup_ui::STAGE_FINAL) {
// Carry out actual backup.
$backup->execute();
// Backup controller gets saved/loaded so the logger object changes and we
// have to retrieve it.
$logger = $backup->get_controller()->get_logger();
while (!is_a($logger, 'core_backup_html_logger')) {
$logger = $logger->get_next();
}
// Get HTML from logger.
$loghtml = $logger->get_html();
-1
View File
@@ -309,7 +309,6 @@ class entities {
$source = str_split($source, 1);
for ($i = 1; $i <= $length; $i++) {
mt_srand((double) microtime() * 1000000);
$num = mt_rand(1, count($source));
$response .= $source[$num - 1];
}
+1 -1
View File
@@ -176,7 +176,7 @@ if ($backup->get_stage() == backup_ui::STAGE_FINAL) {
// Display a notification and a continue button
if ($warnings) {
echo $OUTPUT->box_start();
echo $OUTPUT->notification(get_string('warning'), 'notifywarning');
echo $OUTPUT->notification(get_string('warning'), 'notifyproblem');
echo html_writer::start_tag('ul', array('class'=>'list'));
foreach ($warnings as $warning) {
echo html_writer::tag('li', $warning);
+24 -6
View File
@@ -131,20 +131,38 @@ class backup_course_task extends backup_task {
/**
* Code the transformations to perform in the course in
* order to get transportable (encoded) links
* @param string $content content in which to encode links.
* @return string content with links encoded.
*/
static public function encode_content_links($content) {
global $CFG;
$base = preg_quote($CFG->wwwroot, '/');
// Link to the course main page (it also covers "&topic=xx" and "&week=xx"
// because they don't become transformed (section number) in backup/restore
$search = '/(' . $base . '\/course\/view.php\?id\=)([0-9]+)/';
$content= preg_replace($search, '$@COURSEVIEWBYID*$2@$', $content);
// because they don't become transformed (section number) in backup/restore.
$content = self::encode_links_helper($content, 'COURSEVIEWBYID', '/course/view.php?id=');
// A few other key course links.
$content = self::encode_links_helper($content, 'GRADEINDEXBYID', '/grade/index.php?id=');
$content = self::encode_links_helper($content, 'GRADEREPORTINDEXBYID', '/grade/report/index.php?id=');
$content = self::encode_links_helper($content, 'BADGESVIEWBYID', '/badges/view.php?type=2&id=');
$content = self::encode_links_helper($content, 'USERINDEXVIEWBYID', '/user/index.php?id=');
return $content;
}
/**
* Helper method, used by encode_content_links.
* @param string $content content in which to encode links.
* @param unknown_type $name the name of this type of encoded link.
* @param unknown_type $path the path that identifies this type of link, up
* to the ?paramname= bit.
* @return string content with one type of link encoded.
*/
static private function encode_links_helper($content, $name, $path) {
global $CFG;
$base = preg_quote($CFG->wwwroot . $path, '/');
return preg_replace('/(' . $base . ')([0-9]+)/', '$@' . $name . '*$2@$', $content);
}
// Protected API starts here
/**
+13 -1
View File
@@ -107,7 +107,19 @@ class file_nested_element extends backup_nested_element {
backup_file_manager::copy_file_moodle2backup($this->backupid, $values);
} catch (file_exception $e) {
$this->add_result(array('missing_files_in_pool' => true));
$this->add_log('missing file in pool: ' . $e->debuginfo, backup::LOG_WARNING);
// Build helpful log message with all information necessary to identify
// file location.
$context = context::instance_by_id($values->contextid, IGNORE_MISSING);
$contextname = '';
if ($context) {
$contextname = ' \'' . $context->get_context_name() . '\'';
}
$message = 'Missing file in pool: ' . $values->filepath . $values->filename .
' (context ' . $values->contextid . $contextname . ', component ' .
$values->component . ', filearea ' . $values->filearea . ', itemid ' .
$values->itemid . ') [' . $e->debuginfo . ']';
$this->add_log($message, backup::LOG_WARNING);
}
}
}
+1 -1
View File
@@ -216,7 +216,7 @@ abstract class backup_questions_activity_structure_step extends backup_activity_
$qas = new backup_nested_element($nameprefix . 'question_attempts');
$qa = new backup_nested_element($nameprefix . 'question_attempt', array('id'), array(
'slot', 'behaviour', 'questionid', 'maxmark', 'minfraction', 'maxfraction',
'slot', 'behaviour', 'questionid', 'variant', 'maxmark', 'minfraction', 'maxfraction',
'flagged', 'questionsummary', 'rightanswer', 'responsesummary',
'timemodified'));
+10 -2
View File
@@ -124,6 +124,7 @@ class restore_course_task extends restore_task {
$contents = array();
$contents[] = new restore_decode_content('course', 'summary');
$contents[] = new restore_decode_content('event', 'description');
return $contents;
}
@@ -135,10 +136,17 @@ class restore_course_task extends restore_task {
static public function define_decode_rules() {
$rules = array();
$rules[] = new restore_decode_rule('COURSEVIEWBYID', '/course/view.php?id=$1', 'course');
// Link to the course main page (it also covers "&topic=xx" and "&week=xx"
// because they don't become transformed (section number) in backup/restore.
$rules[] = new restore_decode_rule('COURSEVIEWBYID', '/course/view.php?id=$1', 'course');
// A few other key course links.
$rules[] = new restore_decode_rule('GRADEINDEXBYID', '/grade/index.php?id=$1', 'course');
$rules[] = new restore_decode_rule('GRADEREPORTINDEXBYID', '/grade/report/index.php?id=$1', 'course');
$rules[] = new restore_decode_rule('BADGESVIEWBYID', '/badges/view.php?type=2&id=$1', 'course');
$rules[] = new restore_decode_rule('USERINDEXVIEWBYID', '/user/index.php?id=$1', 'course');
return $rules;
}
// Protected API starts here
+6 -1
View File
@@ -162,7 +162,12 @@ class restore_final_task extends restore_task {
// rules from other tasks (activities) not belonging to one module instance (cmid = 0), so are restored here
$rules = array_merge($rules, restore_logs_processor::register_log_rules_for_course());
// TODO: Other logs like 'calendar', 'upload'... will go here
// Calendar rules.
$rules[] = new restore_log_rule('calendar', 'add', 'event.php?action=edit&id={event}', '[name]');
$rules[] = new restore_log_rule('calendar', 'edit', 'event.php?action=edit&id={event}', '[name]');
$rules[] = new restore_log_rule('calendar', 'edit all', 'event.php?action=edit&id={event}', '[name]');
// TODO: Other logs like 'upload'... will go here
return $rules;
}
+10
View File
@@ -2223,6 +2223,7 @@ class restore_calendarevents_structure_step extends restore_structure_step {
$result = $DB->record_exists_sql($sql, $arg);
if (empty($result)) {
$newitemid = $DB->insert_record('event', $params);
$this->set_mapping('event', $oldid, $newitemid);
$this->set_mapping('event_description', $oldid, $newitemid, $restorefiles);
}
@@ -2832,6 +2833,12 @@ class restore_activity_grades_structure_step extends restore_structure_step {
}
// no need to save any grade_letter mapping
}
public function after_restore() {
// Fix grade item's sortorder after restore, as it might have duplicates.
$courseid = $this->get_task()->get_courseid();
grade_item::fix_duplicate_sortorder($courseid);
}
}
@@ -4062,6 +4069,9 @@ abstract class restore_questions_activity_structure_step extends restore_activit
$data->questionusageid = $this->get_new_parentid($nameprefix . 'question_usage');
$data->questionid = $question->newitemid;
if (!property_exists($data, 'variant')) {
$data->variant = 1;
}
$data->timemodified = $this->apply_date_offset($data->timemodified);
if (!property_exists($data, 'maxfraction')) {
+18 -10
View File
@@ -995,11 +995,7 @@ abstract class restore_dbops {
if ($includesfiles) {
// The file is not found in the backup.
if (!file_exists($backuppath)) {
$result = new stdClass();
$result->code = 'file_missing_in_backup';
$result->message = sprintf('missing file %s%s in backup', $file->filepath, $file->filename);
$result->level = backup::LOG_WARNING;
$results[] = $result;
$results[] = self::get_missing_file_result($file);
continue;
}
@@ -1028,11 +1024,7 @@ abstract class restore_dbops {
$fs->create_file_from_storedfile($file_record, $foundfile->id);
} else {
// A matching existing file record was not found in the database.
$result = new stdClass();
$result->code = 'file_missing_in_backup';
$result->message = sprintf('missing file %s%s in backup', $file->filepath, $file->filename);
$result->level = backup::LOG_WARNING;
$results[] = $result;
$results[] = self::get_missing_file_result($file);
continue;
}
}
@@ -1063,6 +1055,22 @@ abstract class restore_dbops {
return $results;
}
/**
* Returns suitable entry to include in log when there is a missing file.
*
* @param stdClass $file File definition
* @return stdClass Log entry
*/
protected static function get_missing_file_result($file) {
$result = new stdClass();
$result->code = 'file_missing_in_backup';
$result->message = 'Missing file in backup: ' . $file->filepath . $file->filename .
' (old context ' . $file->contextid . ', component ' . $file->component .
', filearea ' . $file->filearea . ', old itemid ' . $file->itemid . ')';
$result->level = backup::LOG_WARNING;
return $result;
}
/**
* Given one restoreid, create in DB all the users present
* in backup_ids having newitemid = 0, as far as
@@ -0,0 +1,56 @@
<?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/>.
/**
* @package core_backup
* @category phpunit
* @copyright 2013 The Open University
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
defined('MOODLE_INTERNAL') || die();
global $CFG;
require_once($CFG->dirroot . '/backup/util/includes/backup_includes.php');
require_once($CFG->dirroot . '/backup/moodle2/backup_course_task.class.php');
/**
* Tests for encoding content links in backup_course_task.
*
* The code that this tests is acutally in backup/moodle2/backup_course_task.class.php,
* but there is no place for unit tests near there, and perhaps one day it will
* be refactored so it becomes more generic.
*/
class backup_course_task_testcase extends basic_testcase {
/**
* Test the encode_content_links method for course.
*/
public function test_course_encode_content_links() {
global $CFG;
$encoded = backup_course_task::encode_content_links(
$CFG->wwwroot . '/course/view.php?id=123, ' .
$CFG->wwwroot . '/grade/index.php?id=123, ' .
$CFG->wwwroot . '/grade/report/index.php?id=123, ' .
$CFG->wwwroot . '/badges/view.php?type=2&id=123 and ' .
$CFG->wwwroot . '/user/index.php?id=123.');
$this->assertEquals('$@COURSEVIEWBYID*123@$, $@GRADEINDEXBYID*123@$, ' .
'$@GRADEREPORTINDEXBYID*123@$, $@BADGESVIEWBYID*123@$ and $@USERINDEXVIEWBYID*123@$.', $encoded);
}
}
@@ -115,7 +115,6 @@ abstract class core_backup_progress {
$this->currents[] = 0;
$this->parentcounts[] = $parentcount;
$this->update_progress();
$lastprogresstime = $this->get_time();
}
/**
+8
View File
@@ -73,6 +73,14 @@ abstract class base_moodleform extends moodleform {
*/
function __construct(base_ui_stage $uistage, $action=null, $customdata=null, $method='post', $target='', $attributes=null, $editable=true) {
$this->uistage = $uistage;
// Add a class to the attributes to prevent the default collapsible behaviour.
if (!$attributes) {
$attributes = array();
}
$attributes['class'] = 'unresponsive';
if (!isset($attributes['enctype'])) {
$attributes['enctype'] = 'application/x-www-form-urlencoded'; // Enforce compatibility with our max_input_vars hack.
}
parent::__construct($action, $customdata, $method, $target, $attributes, $editable);
}
/**
+1 -1
View File
@@ -410,7 +410,7 @@ class core_backup_renderer extends plugin_renderer_base {
}
if (array_key_exists('warnings', $results)) {
foreach ($results['warnings'] as $warning) {
$output .= $this->output->notification($warning, 'notifywarning notifyproblem');
$output .= $this->output->notification($warning, 'notifyproblem');
}
}
return $output.html_writer::end_tag('div');
@@ -846,6 +846,7 @@ class restore_ui_stage_process extends restore_ui_stage {
$html .= html_writer::start_tag('form', array(
'action' => $url->out_omit_querystring(),
'class' => 'backup-restore',
'enctype' => 'application/x-www-form-urlencoded', // Enforce compatibility with our max_input_vars hack.
'method' => 'post'));
foreach ($url->params() as $name => $value) {
$html .= html_writer::empty_tag('input', array(
@@ -38,7 +38,7 @@ Feature: Backup Moodle courses
And I press "Continue"
And I click on "Continue" "button" in the ".bcs-current-course" "css_element"
And "//div[contains(concat(' ', normalize-space(@class), ' '), ' fitem ')][contains(., 'Include calendar events')]/descendant::img" "xpath_element" should exists
And I check "Include course logs"
And "Include course logs" "checkbox" should exists
And I press "Next"
@javascript
+29 -8
View File
@@ -17,7 +17,7 @@
/**
* Backup and restore actions to help behat feature files writting.
*
* @package core
* @package core_backup
* @category test
* @copyright 2013 David Monllaó
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
@@ -35,7 +35,7 @@ use Behat\Gherkin\Node\TableNode as TableNode,
/**
* Backup-related steps definitions.
*
* @package core
* @package core_backup
* @category test
* @copyright 2013 David Monllaó
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
@@ -56,27 +56,32 @@ class behat_backup extends behat_base {
// Go to homepage.
$this->getSession()->visit($this->locate_path('/'));
$this->wait();
// Click the course link.
$this->find_link($backupcourse)->click();
$this->wait();
// Click the backup link.
$this->find_link(get_string('backup'))->click();
$this->wait();
// Initial settings.
$this->fill_backup_restore_form($options);
$this->find_button(get_string('backupstage1action', 'backup'))->press();
$this->wait();
// Schema settings.
$this->fill_backup_restore_form($options);
$this->find_button(get_string('backupstage2action', 'backup'))->press();
$this->wait();
// Confirmation and review, backup filename can also be specified.
$this->fill_backup_restore_form($options);
$this->find_button(get_string('backupstage4action', 'backup'))->press();
// Waiting for it to finish.
$this->wait(10);
$this->wait(self::EXTENDED_TIMEOUT);
// Last backup continue button.
$this->find_button(get_string('backupstage16action', 'backup'))->press();
@@ -101,12 +106,15 @@ class behat_backup extends behat_base {
// Go to homepage.
$this->getSession()->visit($this->locate_path('/'));
$this->wait();
// Click the course link.
$this->find_link($tocourse)->click();
$this->wait();
// Click the import link.
$this->find_link(get_string('import'))->click();
$this->wait();
// Select the course.
$exception = new ExpectationException('"' . $fromcourse . '" course not found in the list of courses to import from', $this->getSession());
@@ -121,18 +129,21 @@ class behat_backup extends behat_base {
$radionode->click();
$this->find_button(get_string('continue'))->press();
$this->wait();
// Initial settings.
$this->fill_backup_restore_form($options);
$this->find_button(get_string('importbackupstage1action', 'backup'))->press();
$this->wait();
// Schema settings.
$this->fill_backup_restore_form($options);
$this->find_button(get_string('importbackupstage2action', 'backup'))->press();
$this->wait();
// Run it.
$this->find_button(get_string('importbackupstage4action', 'backup'))->press();
$this->wait();
$this->wait(self::EXTENDED_TIMEOUT);
// Continue and redirect to 'to' course.
$this->find_button(get_string('continue'))->press();
@@ -294,17 +305,22 @@ class behat_backup extends behat_base {
// Settings.
$this->fill_backup_restore_form($options);
$this->find_button(get_string('restorestage4action', 'backup'))->press();
$this->wait();
// Schema.
$this->fill_backup_restore_form($options);
$this->find_button(get_string('restorestage8action', 'backup'))->press();
$this->wait();
// Review, no options here.
$this->find_button(get_string('restorestage16action', 'backup'))->press();
$this->wait(10);
$this->wait();
// Last restore continue button, redirected to restore course after this.
$this->find_button(get_string('restorestage32action', 'backup'))->press();
// Long wait when waiting for the restore to finish.
$this->wait(self::EXTENDED_TIMEOUT);
}
/**
@@ -325,11 +341,15 @@ class behat_backup extends behat_base {
return;
}
// Wait for the page to be loaded and the JS ready.
$this->wait();
// If we find any of the provided options in the current form we should set the value.
$datahash = $options->getRowsHash();
foreach ($datahash as $locator => $value) {
try {
// Using $this->find* to enforce stability over speed.
$fieldnode = $this->find_field($locator);
$field = behat_field_manager::get_form_field($fieldnode, $this->getSession());
$field->set_value($value);
@@ -341,9 +361,9 @@ class behat_backup extends behat_base {
}
/**
* Waits until the DOM is ready.
* Waits until the DOM and the page Javascript code is ready.
*
* @param int To override the default timeout
* @param int $timeout The number of seconds that we wait.
* @return void
*/
protected function wait($timeout = false) {
@@ -355,7 +375,8 @@ class behat_backup extends behat_base {
if (!$timeout) {
$timeout = self::TIMEOUT;
}
$this->getSession()->wait($timeout, '(document.readyState === "complete")');
$this->getSession()->wait($timeout * 1000, self::PAGE_READY_JS);
}
}
@@ -21,8 +21,8 @@ Feature: Duplicate activities
And I add a "Database" to section "1" and I fill the form with:
| Name | Test database name |
| Description | Test database description |
And I open "Test database name" actions menu
When I click on "Duplicate" "link" in the "Test database name" activity
And I duplicate "Test database name" activity
And I wait until section "1" is available
And I open "Test database name" actions menu
And I click on "Edit settings" "link" in the "Test database name" activity
And I fill the moodle form with:
+1 -1
View File
@@ -109,7 +109,7 @@ if (count($acceptedroles) > 1) {
$pageurl = new moodle_url('/badges/award.php', array('id' => $badgeid));
$issuerrole = new stdClass();
$issuerrole->roleid = $role;
$roleselect = get_string('selectaward', 'badges') . $OUTPUT->single_select(new moodle_url($pageurl), 'role', $select, $role);
$roleselect = get_string('selectaward', 'badges') . $OUTPUT->single_select(new moodle_url($pageurl), 'role', $select, $role, null);
}
} else {
echo $OUTPUT->header();
+9 -5
View File
@@ -42,7 +42,14 @@ if (empty($CFG->enablebadges)) {
print_error('badgesdisabled', 'badges');
}
$url = new moodle_url('/badges/mybadges.php');
$PAGE->set_url($url);
if (isguestuser()) {
$PAGE->set_context(context_system::instance());
echo $OUTPUT->header();
echo $OUTPUT->box(get_string('error:guestuseraccess', 'badges'), 'notifyproblem');
echo $OUTPUT->footer();
die();
}
@@ -56,10 +63,10 @@ if ($clearsearch) {
if ($hide) {
require_sesskey();
$DB->set_field('badge_issued', 'visible', 0, array('id' => $hide));
$DB->set_field('badge_issued', 'visible', 0, array('id' => $hide, 'userid' => $USER->id));
} else if ($show) {
require_sesskey();
$DB->set_field('badge_issued', 'visible', 1, array('id' => $show));
$DB->set_field('badge_issued', 'visible', 1, array('id' => $show, 'userid' => $USER->id));
} else if ($download && $hash) {
require_sesskey();
$badge = new badge($download);
@@ -80,9 +87,6 @@ if ($hide) {
$context = context_user::instance($USER->id);
require_capability('moodle/badges:manageownbadges', $context);
$url = new moodle_url('/badges/mybadges.php');
$PAGE->set_url($url);
$PAGE->set_context($context);
$title = get_string('mybadges', 'badges');
+1 -1
View File
@@ -91,7 +91,7 @@ $namefields = get_all_user_name_fields(true, 'u');
$sql = "SELECT b.userid, b.dateissued, b.uniquehash, $namefields
FROM {badge_issued} b INNER JOIN {user} u
ON b.userid = u.id
WHERE b.badgeid = :badgeid
WHERE b.badgeid = :badgeid AND u.deleted = 0
ORDER BY $sortby $sorthow";
$totalcount = $DB->count_records('badge_issued', array('badgeid' => $badge->id));
+16 -7
View File
@@ -279,7 +279,7 @@ class core_badges_renderer extends plugin_renderer_base {
// Outputs issued badge with actions available.
protected function render_issued_badge(issued_badge $ibadge) {
global $USER, $CFG, $DB;
global $USER, $CFG, $DB, $SITE;
$issued = $ibadge->issued;
$userinfo = $ibadge->recipient;
$badgeclass = $ibadge->badgeclass;
@@ -316,11 +316,18 @@ class core_badges_renderer extends plugin_renderer_base {
// Recipient information.
$datatable->data[] = array($this->output->heading(get_string('recipientdetails', 'badges'), 3), '');
$datatable->data[] = array(get_string('name'), fullname($userinfo));
if (empty($userinfo->backpackemail)) {
$datatable->data[] = array(get_string('email'), obfuscate_mailto($userinfo->accountemail));
if ($userinfo->deleted) {
$strdata = new stdClass();
$strdata->user = fullname($userinfo);
$strdata->site = format_string($SITE->fullname, true, array('context' => context_system::instance()));
$datatable->data[] = array(get_string('name'), get_string('error:userdeleted', 'badges', $strdata));
} else {
$datatable->data[] = array(get_string('email'), obfuscate_mailto($userinfo->backpackemail));
$datatable->data[] = array(get_string('name'), fullname($userinfo));
if (empty($userinfo->backpackemail)) {
$datatable->data[] = array(get_string('email'), obfuscate_mailto($userinfo->accountemail));
} else {
$datatable->data[] = array(get_string('email'), obfuscate_mailto($userinfo->backpackemail));
}
}
$datatable->data[] = array($this->output->heading(get_string('issuerdetails', 'badges'), 3), '');
@@ -663,7 +670,9 @@ class core_badges_renderer extends plugin_renderer_base {
}
if (has_capability('moodle/badges:viewawarded', $context)) {
$awarded = $DB->count_records('badge_issued', array('badgeid' => $badgeid));
$awarded = $DB->count_records_sql('SELECT COUNT(b.userid)
FROM {badge_issued} b INNER JOIN {user} u ON b.userid = u.id
WHERE b.badgeid = :badgeid AND u.deleted = 0', array('badgeid' => $badgeid));
$row[] = new tabobject('awards',
new moodle_url('/badges/recipients.php', array('id' => $badgeid)),
get_string('bawards', 'badges', $awarded)
@@ -936,7 +945,7 @@ class issued_badge implements renderable {
if ($rec) {
// Get a recipient from database.
$namefields = get_all_user_name_fields(true, 'u');
$user = $DB->get_record_sql("SELECT u.id, $namefields,
$user = $DB->get_record_sql("SELECT u.id, $namefields, u.deleted,
u.email AS accountemail, b.email AS backpackemail
FROM {user} u LEFT JOIN {badge_backpack} b ON u.id = b.userid
WHERE u.id = :userid", array('userid' => $rec->userid));
+1 -1
View File
@@ -233,7 +233,7 @@ class core_badges_badgeslib_testcase extends advanced_testcase {
$criteria_overall = award_criteria::build(array('criteriatype' => BADGE_CRITERIA_TYPE_OVERALL, 'badgeid' => $badge->id));
$criteria_overall->save(array('agg' => BADGE_CRITERIA_AGGREGATION_ANY));
$criteria_overall = award_criteria::build(array('criteriatype' => BADGE_CRITERIA_TYPE_ACTIVITY, 'badgeid' => $badge->id));
$criteria_overall->save(array('agg' => BADGE_CRITERIA_AGGREGATION_ANY, 'module_'.$this->module->id => $this->module->id));
$criteria_overall->save(array('agg' => BADGE_CRITERIA_AGGREGATION_ANY, 'module_'.$this->module->cmid => $this->module->cmid));
// Set completion for forum activity.
$c = new completion_info($this->course);
+2 -2
View File
@@ -1,4 +1,4 @@
@core @core_badges @_only_local
@core @core_badges @_only_local @_file_upload
Feature: Add badges to the system
In order to give badges to users for their achievements
As an admin
@@ -36,7 +36,7 @@ Feature: Add badges to the system
| Description | Test badge description |
| issuername | Test Badge Site |
| issuercontact | testuser@test-badge-site.com |
And I upload "badges/tests/behat/badge.png" file to "Image" filepicker
And I upload "badges/tests/behat/badge.png" file to "Image" filemanager
When I press "Create badge"
Then I should see "Edit details"
And I should see "Test Badge"
+9 -15
View File
@@ -1,16 +1,13 @@
@core @core_badges @_only_local
@core @core_badges @_only_local @_file_upload
Feature: Award badges
In order to award badges to users for their achievements
As an admin
I need to add criteria to badges in the system
Background:
Given I am on homepage
And I log in as "admin"
@javascript
Scenario: Award profile badge
Given I expand "Site administration" node
Given I log in as "admin"
And I expand "Site administration" node
And I expand "Badges" node
And I follow "Add a new badge"
And I fill the moodle form with:
@@ -18,7 +15,7 @@ Feature: Award badges
| Description | Test badge description |
| issuername | Test Badge Site |
| issuercontact | testuser@test-badge-site.com |
And I upload "badges/tests/behat/badge.png" file to "Image" filepicker
And I upload "badges/tests/behat/badge.png" file to "Image" filemanager
And I press "Create badge"
And I select "Profile completion" from "type"
And I check "First name"
@@ -46,6 +43,7 @@ Feature: Award badges
| username | firstname | lastname | email |
| teacher | teacher | 1 | teacher1@asd.com |
| student | student | 1 | student1@asd.com |
And I log in as "admin"
And I expand "Site administration" node
And I expand "Badges" node
And I follow "Add a new badge"
@@ -53,7 +51,7 @@ Feature: Award badges
| Name | Site Badge |
| Description | Site badge description |
| issuername | Tester of site badge |
And I upload "badges/tests/behat/badge.png" file to "Image" filepicker
And I upload "badges/tests/behat/badge.png" file to "Image" filemanager
And I press "Create badge"
And I select "Manual issue by role" from "type"
And I check "Teacher"
@@ -89,7 +87,6 @@ Feature: Award badges
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
| student2 | C1 | student |
And I log out
And I log in as "teacher1"
And I follow "Course 1"
And I click on "//span[text()='Badges']" "xpath_element" in the "Administration" "block"
@@ -98,7 +95,7 @@ Feature: Award badges
| Name | Course Badge |
| Description | Course badge description |
| issuername | Tester of course badge |
And I upload "badges/tests/behat/badge.png" file to "Image" filepicker
And I upload "badges/tests/behat/badge.png" file to "Image" filemanager
And I press "Create badge"
And I select "Manual issue by role" from "type"
And I check "Teacher"
@@ -133,7 +130,6 @@ Feature: Award badges
| user | course | role |
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
And I log out
And I log in as "admin"
And I set the following administration settings values:
| Enable completion tracking | 1 |
@@ -156,7 +152,7 @@ Feature: Award badges
| Name | Course Badge |
| Description | Course badge description |
| issuername | Tester of course badge |
And I upload "badges/tests/behat/badge.png" file to "Image" filepicker
And I upload "badges/tests/behat/badge.png" file to "Image" filemanager
And I press "Create badge"
And I select "Activity completion" from "type"
And I check "Test assignment name"
@@ -172,7 +168,6 @@ Feature: Award badges
And I follow "Home"
And I follow "Course 1"
And I press "Mark as complete: Test assignment name"
And I wait "2" seconds
And I expand "My profile" node
And I follow "My badges"
Then I should see "Course Badge"
@@ -190,7 +185,6 @@ Feature: Award badges
| user | course | role |
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
And I log out
And I log in as "admin"
And I set the following administration settings values:
| Enable completion tracking | 1 |
@@ -219,7 +213,7 @@ Feature: Award badges
| Name | Course Badge |
| Description | Course badge description |
| issuername | Tester of course badge |
And I upload "badges/tests/behat/badge.png" file to "Image" filepicker
And I upload "badges/tests/behat/badge.png" file to "Image" filemanager
And I press "Create badge"
And I select "Course completion" from "type"
And I fill the moodle form with:
-5
View File
@@ -73,11 +73,6 @@ if ($type == BADGE_TYPE_SITE) {
$PAGE->set_context(context_course::instance($course->id));
$PAGE->set_pagelayout('course');
$PAGE->set_heading($title);
// Fix course navigation.
$PAGE->navbar->ignore_active();
$PAGE->navbar->add($course->shortname, new moodle_url('/course/view.php', array('id' => $course->id)));
$PAGE->navbar->add(get_string('coursebadges', 'badges'));
}
$PAGE->set_title($title);
@@ -0,0 +1,176 @@
@block @block_activity_modules
Feature: Block activity modules
In order to overview activity modules in a course
As a manager
I can add activities block in a course or on the frontpage
Background:
Given I log in as "admin"
And I expand "Site administration" node
And I expand "Plugins" node
And I expand "Activity modules" node
And I follow "Manage activities"
And I click on "//a[@title=\"Show\"]" "xpath_element" in the "Feedback" "table_row"
And I click on "//a[@title=\"Show\"]" "xpath_element" in the "Assignment (2.2)" "table_row"
Scenario: Add activities block on the frontpage
Given the following "activities" exists:
| activity | name | intro | course | idnumber |
| assign | Frontpage assignment name | Frontpage assignment description | Acceptance test site | assign0 |
| assignment | Frontpage assignment22 name | Frontpage assignment22 description | Acceptance test site | assignment0 |
| book | Frontpage book name | Frontpage book description | Acceptance test site | book0 |
| chat | Frontpage chat name | Frontpage chat description | Acceptance test site | chat0 |
| choice | Frontpage choice name | Frontpage choice description | Acceptance test site | choice0 |
| data | Frontpage database name | Frontpage database description | Acceptance test site | data0 |
| feedback | Frontpage feedback name | Frontpage feedback description | Acceptance test site | feedback0 |
| forum | Frontpage forum name | Frontpage forum description | Acceptance test site | forum0 |
| label | Frontpage label name | Frontpage label description | Acceptance test site | label0 |
| lti | Frontpage lti name | Frontpage lti description | Acceptance test site | lti0 |
| page | Frontpage page name | Frontpage page description | Acceptance test site | page0 |
| quiz | Frontpage quiz name | Frontpage quiz description | Acceptance test site | quiz0 |
| resource | Frontpage resource name | Frontpage resource description | Acceptance test site | resource0 |
| imscp | Frontpage imscp name | Frontpage imscp description | Acceptance test site | imscp0 |
| folder | Frontpage folder name | Frontpage folder description | Acceptance test site | folder0 |
| glossary | Frontpage glossary name | Frontpage glossary description | Acceptance test site | glossary0 |
| scorm | Frontpage scorm name | Frontpage scorm description | Acceptance test site | scorm0 |
| lesson | Frontpage lesson name | Frontpage lesson description | Acceptance test site | lesson0 |
| survey | Frontpage survey name | Frontpage survey description | Acceptance test site | survey0 |
| url | Frontpage url name | Frontpage url description | Acceptance test site | url0 |
| wiki | Frontpage wiki name | Frontpage wiki description | Acceptance test site | wiki0 |
| workshop | Frontpage workshop name | Frontpage workshop description | Acceptance test site | workshop0 |
And I am on homepage
When I follow "Turn editing on"
And I add the "Activities" block
And I click on "Assignments" "link" in the "Activities" "block"
Then I should see "Frontpage assignment name"
And I am on homepage
And I click on "Assignments (2.2)" "link" in the "Activities" "block"
And I should see "Frontpage assignment22 name"
And I am on homepage
And I click on "Chats" "link" in the "Activities" "block"
And I should see "Frontpage chat name"
And I am on homepage
And I click on "Choices" "link" in the "Activities" "block"
And I should see "Frontpage choice name"
And I am on homepage
And I click on "Databases" "link" in the "Activities" "block"
And I should see "Frontpage database name"
And I am on homepage
And I click on "Feedback" "link" in the "Activities" "block"
And I should see "Frontpage feedback name"
And I am on homepage
And I click on "Forums" "link" in the "Activities" "block"
And I should see "Frontpage forum name"
And I am on homepage
And I click on "External Tools" "link" in the "Activities" "block"
And I should see "Frontpage lti name"
And I am on homepage
And I click on "Quizzes" "link" in the "Activities" "block"
And I should see "Frontpage quiz name"
And I am on homepage
And I click on "Glossaries" "link" in the "Activities" "block"
And I should see "Frontpage glossary name"
And I am on homepage
And I click on "SCORM packages" "link" in the "Activities" "block"
And I should see "Frontpage scorm name"
And I am on homepage
And I click on "Lessons" "link" in the "Activities" "block"
And I should see "Frontpage lesson name"
And I am on homepage
And I click on "Wikis" "link" in the "Activities" "block"
And I should see "Frontpage wiki name"
And I am on homepage
And I click on "Workshop" "link" in the "Activities" "block"
And I should see "Frontpage workshop name"
And I am on homepage
And I click on "Resources" "link" in the "Activities" "block"
And I should see "Frontpage book name"
And I should see "Frontpage page name"
And I should see "Frontpage resource name"
And I should see "Frontpage imscp name"
And I should see "Frontpage folder name"
And I should see "Frontpage url name"
Scenario: Add activities block in a course
Given the following "courses" exists:
| fullname | shortname | format |
| Course 1 | C1 | topics |
And the following "activities" exists:
| activity | name | intro | course | idnumber |
| assign | Test assignment name | Test assignment description | C1 | assign1 |
| assignment | Test assignment22 name | Test assignment22 description | C1 | assignment1 |
| book | Test book name | Test book description | C1 | book1 |
| chat | Test chat name | Test chat description | C1 | chat1 |
| choice | Test choice name | Test choice description | C1 | choice1 |
| data | Test database name | Test database description | C1 | data1 |
| feedback | Test feedback name | Test feedback description | C1 | feedback1 |
| folder | Test folder name | Test folder description | C1 | folder1 |
| forum | Test forum name | Test forum description | C1 | forum1 |
| glossary | Test glossary name | Test glossary description | C1 | glossary1 |
| imscp | Test imscp name | Test imscp description | C1 | imscp1 |
| label | Test label name | Test label description | C1 | label1 |
| lesson | Test lesson name | Test lesson description | C1 | lesson1 |
| lti | Test lti name | Test lti description | C1 | lti1 |
| page | Test page name | Test page description | C1 | page1 |
| quiz | Test quiz name | Test quiz description | C1 | quiz1 |
| resource | Test resource name | Test resource description | C1 | resource1 |
| scorm | Test scorm name | Test scorm description | C1 | scorm1 |
| survey | Test survey name | Test survey description | C1 | survey1 |
| url | Test url name | Test url description | C1 | url1 |
| wiki | Test wiki name | Test wiki description | C1 | wiki1 |
| workshop | Test workshop name | Test workshop description | C1 | workshop1 |
When I follow "Courses"
And I follow "Course 1"
And I turn editing mode on
And I add the "Activities" block
And I click on "Assignments" "link" in the "Activities" "block"
Then I should see "Test assignment name"
And I follow "Course 1"
And I click on "Assignments (2.2)" "link" in the "Activities" "block"
And I should see "Test assignment22 name"
And I follow "Course 1"
And I click on "Chats" "link" in the "Activities" "block"
And I should see "Test chat name"
And I follow "Course 1"
And I click on "Choices" "link" in the "Activities" "block"
And I should see "Test choice name"
And I follow "Course 1"
And I click on "Databases" "link" in the "Activities" "block"
And I should see "Test database name"
And I follow "Course 1"
And I click on "Feedback" "link" in the "Activities" "block"
And I should see "Test feedback name"
And I follow "Course 1"
And I click on "Forums" "link" in the "Activities" "block"
And I should see "Test forum name"
And I follow "Course 1"
And I click on "External Tools" "link" in the "Activities" "block"
And I should see "Test lti name"
And I follow "Course 1"
And I click on "Quizzes" "link" in the "Activities" "block"
And I should see "Test quiz name"
And I follow "Course 1"
And I click on "Glossaries" "link" in the "Activities" "block"
And I should see "Test glossary name"
And I follow "Course 1"
And I click on "SCORM packages" "link" in the "Activities" "block"
And I should see "Test scorm name"
And I follow "Course 1"
And I click on "Lessons" "link" in the "Activities" "block"
And I should see "Test lesson name"
And I follow "Course 1"
And I click on "Wikis" "link" in the "Activities" "block"
And I should see "Test wiki name"
And I follow "Course 1"
And I click on "Workshop" "link" in the "Activities" "block"
And I should see "Test workshop name"
And I follow "Course 1"
And I click on "Resources" "link" in the "Activities" "block"
And I should see "Test book name"
And I should see "Test page name"
And I should see "Test resource name"
And I should see "Test imscp name"
And I should see "Test folder name"
And I should see "Test url name"
@@ -107,7 +107,7 @@ class block_admin_bookmarks extends block_base {
$this->content->footer = '';
$this->page->settingsnav->initialise();
$node = $this->page->settingsnav->get('root', navigation_node::TYPE_SETTING);
$node = $this->page->settingsnav->get('root', navigation_node::TYPE_SITE_ADMIN);
if (!$node || !$node->contains_active_node()) {
return $this->content;
}
+1
View File
@@ -83,6 +83,7 @@ class block_blog_recent extends block_base {
$this->content = new stdClass();
$this->content->footer = '';
$this->content->text = '';
$context = $this->page->context;
@@ -17,7 +17,7 @@
/**
* Commenting system steps definitions.
*
* @package core_comment
* @package block_comments
* @category test
* @copyright 2013 David Monllaó
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
@@ -33,7 +33,7 @@ use Behat\Mink\Exception\ElementNotFoundException as ElementNotFoundException,
/**
* Steps definitions to deal with the commenting system
*
* @package core_comment
* @package block_comments
* @category test
* @copyright 2013 David Monllaó
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
@@ -65,9 +65,6 @@ class behat_block_comments extends behat_base {
$this->find_link(get_string('savecomment'))->click();
// Wait for the AJAX request.
$this->getSession()->wait(4 * 1000, false);
} else {
$commentstextarea = $this->find('css', '.block_comments form textarea', $exception);
@@ -103,7 +100,7 @@ class behat_block_comments extends behat_base {
$deleteicon = $this->find('css', '.comment-delete a img', $deleteexception, $commentnode);
$deleteicon->click();
// Wait for the AJAX request.
// Wait for the animation to finish, in theory is just 1 sec, adding 4 just in case.
$this->getSession()->wait(4 * 1000, false);
}
+3
View File
@@ -58,5 +58,8 @@ function xmldb_block_community_upgrade($oldversion) {
// Put any upgrade step following this.
// Moodle v2.6.0 release upgrade line.
// Put any upgrade step following this.
return true;
}
+3
View File
@@ -64,5 +64,8 @@ function xmldb_block_completionstatus_upgrade($oldversion, $block) {
// Put any upgrade step following this.
// Moodle v2.6.0 release upgrade line.
// Put any upgrade step following this.
return true;
}
+9 -3
View File
@@ -35,7 +35,14 @@ class block_course_list extends block_list {
if (empty($CFG->disablemycourses) and isloggedin() and !isguestuser() and
!(has_capability('moodle/course:update', context_system::instance()) and $adminseesall)) { // Just print My Courses
if ($courses = enrol_get_my_courses(NULL, 'visible DESC, fullname ASC')) {
// As this is producing navigation sort order should default to $CFG->navsortmycoursessort instead
// of using the default.
if (!empty($CFG->navsortmycoursessort)) {
$sortorder = 'visible DESC, ' . $CFG->navsortmycoursessort . ' ASC';
} else {
$sortorder = 'visible DESC, sortorder ASC';
}
if ($courses = enrol_get_my_courses(NULL, $sortorder)) {
foreach ($courses as $course) {
$coursecontext = context_course::instance($course->id);
$linkcss = $course->visible ? "" : " class=\"dimmed\" ";
@@ -121,8 +128,7 @@ class block_course_list extends block_list {
$this->content->items[] = get_string('remotecourses','mnet');
$this->content->icons[] = '';
foreach ($courses as $course) {
$coursecontext = context_course::instance($course->id);
$this->content->items[]="<a title=\"" . format_string($course->shortname, true, array('context' => $coursecontext)) . "\" ".
$this->content->items[]="<a title=\"" . format_string($course->shortname, true) . "\" ".
"href=\"{$CFG->wwwroot}/auth/mnet/jump.php?hostid={$course->hostid}&amp;wantsurl=/course/view.php?id={$course->remoteid}\">"
.$icon. format_string(get_course_display_name_for_list($course)) . "</a>";
}
+3
View File
@@ -69,5 +69,8 @@ function xmldb_block_course_summary_upgrade($oldversion, $block) {
// Put any upgrade step following this.
// Moodle v2.6.0 release upgrade line.
// Put any upgrade step following this.
return true;
}
+3
View File
@@ -44,5 +44,8 @@ function xmldb_block_html_upgrade($oldversion) {
// Put any upgrade step following this.
// Moodle v2.6.0 release upgrade line.
// Put any upgrade step following this.
return true;
}
-2
View File
@@ -1,2 +0,0 @@
.block.block_html .content {padding:0;}
.block.block_html .content .no-overflow {padding:4px;}
+3
View File
@@ -70,5 +70,8 @@ function xmldb_block_navigation_upgrade($oldversion, $block) {
// Put any upgrade step following this.
// Moodle v2.6.0 release upgrade line.
// Put any upgrade step following this.
return true;
}
@@ -58,14 +58,11 @@ Feature: View my courses in navigation block
And I should see "cat3" in the "Navigation" "block"
And I should not see "cat2" in the "Navigation" "block"
And I expand "cat3" node
And I wait "2" seconds
And I should see "cat31" in the "Navigation" "block"
And I should see "cat33" in the "Navigation" "block"
And I should not see "cat32" in the "Navigation" "block"
And I expand "cat31" node
And I wait "2" seconds
And I should see "c31" in the "Navigation" "block"
And I expand "cat33" node
And I wait "2" seconds
And I should see "c331" in the "Navigation" "block"
And I should not see "c332" in the "Navigation" "block"
@@ -404,6 +404,15 @@ Y.extend(TREE, Y.Base, TREE.prototype, {
}
return val;
}
},
/**
* The navigation tree block instance.
*/
instance : {
value : false,
setter : function(val) {
return parseInt(val, 10);
}
}
}
});
@@ -583,7 +592,7 @@ BRANCH.prototype = {
} else {
e.stopPropagation();
}
if (e.type === 'actionkey' && e.action === 'enter' && e.target.test('A')) {
if ((e.type === 'actionkey' && e.action === 'enter') || e.target.test('a')) {
// No ajaxLoad for enter.
this.node.setAttribute('data-expandable', '0');
this.node.setAttribute('data-loaded', '1');
@@ -640,6 +649,12 @@ BRANCH.prototype = {
this.node.setAttribute('data-loaded', '1');
try {
var object = Y.JSON.parse(outcome.responseText);
if (object.error) {
Y.use('moodle-core-notification-ajaxexception', function () {
return new M.core.ajaxException(object).show();
});
return false;
}
if (object.children && object.children.length > 0) {
var coursecount = 0;
for (var i in object.children) {
@@ -663,9 +678,16 @@ BRANCH.prototype = {
return true;
}
Y.log('AJAX loading complete but there were no children.', 'note', 'moodle-block_navigation');
} catch (ex) {
// If we got here then there was an error parsing the result.
Y.log('Error parsing AJAX response or adding branches to the navigation tree', 'error', 'moodle-block_navigation');
} catch (error) {
if (outcome && outcome.status && outcome.status > 0) {
// If we got here then there was an error parsing the result.
Y.log('Error parsing AJAX response or adding branches to the navigation tree', 'error', 'moodle-block_navigation');
Y.use('moodle-core-notification-exception', function () {
return new M.core.exception(error).show();
});
}
return false;
}
// The branch is empty so class it accordingly
this.node.replaceClass('branch', 'emptybranch');
File diff suppressed because one or more lines are too long
@@ -403,6 +403,15 @@ Y.extend(TREE, Y.Base, TREE.prototype, {
}
return val;
}
},
/**
* The navigation tree block instance.
*/
instance : {
value : false,
setter : function(val) {
return parseInt(val, 10);
}
}
}
});
@@ -582,7 +591,7 @@ BRANCH.prototype = {
} else {
e.stopPropagation();
}
if (e.type === 'actionkey' && e.action === 'enter' && e.target.test('A')) {
if ((e.type === 'actionkey' && e.action === 'enter') || e.target.test('a')) {
// No ajaxLoad for enter.
this.node.setAttribute('data-expandable', '0');
this.node.setAttribute('data-loaded', '1');
@@ -638,6 +647,12 @@ BRANCH.prototype = {
this.node.setAttribute('data-loaded', '1');
try {
var object = Y.JSON.parse(outcome.responseText);
if (object.error) {
Y.use('moodle-core-notification-ajaxexception', function () {
return new M.core.ajaxException(object).show();
});
return false;
}
if (object.children && object.children.length > 0) {
var coursecount = 0;
for (var i in object.children) {
@@ -659,8 +674,15 @@ BRANCH.prototype = {
}
return true;
}
} catch (ex) {
// If we got here then there was an error parsing the result.
} catch (error) {
if (outcome && outcome.status && outcome.status > 0) {
// If we got here then there was an error parsing the result.
Y.use('moodle-core-notification-exception', function () {
return new M.core.exception(error).show();
});
}
return false;
}
// The branch is empty so class it accordingly
this.node.replaceClass('branch', 'emptybranch');
+26 -4
View File
@@ -402,6 +402,15 @@ Y.extend(TREE, Y.Base, TREE.prototype, {
}
return val;
}
},
/**
* The navigation tree block instance.
*/
instance : {
value : false,
setter : function(val) {
return parseInt(val, 10);
}
}
}
});
@@ -581,7 +590,7 @@ BRANCH.prototype = {
} else {
e.stopPropagation();
}
if (e.type === 'actionkey' && e.action === 'enter' && e.target.test('A')) {
if ((e.type === 'actionkey' && e.action === 'enter') || e.target.test('a')) {
// No ajaxLoad for enter.
this.node.setAttribute('data-expandable', '0');
this.node.setAttribute('data-loaded', '1');
@@ -638,6 +647,12 @@ BRANCH.prototype = {
this.node.setAttribute('data-loaded', '1');
try {
var object = Y.JSON.parse(outcome.responseText);
if (object.error) {
Y.use('moodle-core-notification-ajaxexception', function () {
return new M.core.ajaxException(object).show();
});
return false;
}
if (object.children && object.children.length > 0) {
var coursecount = 0;
for (var i in object.children) {
@@ -661,9 +676,16 @@ BRANCH.prototype = {
return true;
}
Y.log('AJAX loading complete but there were no children.', 'note', 'moodle-block_navigation');
} catch (ex) {
// If we got here then there was an error parsing the result.
Y.log('Error parsing AJAX response or adding branches to the navigation tree', 'error', 'moodle-block_navigation');
} catch (error) {
if (outcome && outcome.status && outcome.status > 0) {
// If we got here then there was an error parsing the result.
Y.log('Error parsing AJAX response or adding branches to the navigation tree', 'error', 'moodle-block_navigation');
Y.use('moodle-core-notification-exception', function () {
return new M.core.exception(error).show();
});
}
return false;
}
// The branch is empty so class it accordingly
this.node.replaceClass('branch', 'emptybranch');
+4 -39
View File
@@ -16,7 +16,9 @@
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
/**
* Manage files in folder in private area - to be replaced by something better hopefully....
* Manage files in folder in private area.
*
* This page is not used and now redirects to the page to manage the private files.
*
* @package block_private_files
* @copyright 2010 Petr Skoda (http://skodak.org)
@@ -24,42 +26,5 @@
*/
require('../../config.php');
require_once("$CFG->dirroot/blocks/private_files/edit_form.php");
require_once("$CFG->dirroot/repository/lib.php");
require_login();
if (isguestuser()) {
die();
}
//TODO: add capability check here!
$context = context_user::instance($USER->id);
$title = get_string('privatefiles', 'block_private_files');
$struser = get_string('user');
$PAGE->set_url('/blocks/private_files/edit.php');
$PAGE->set_context($context);
$PAGE->set_title($title);
$PAGE->set_heading($title);
$PAGE->set_pagelayout('mydashboard');
$PAGE->set_pagetype('user-private-files');
$data = new stdClass();
$options = array('subdirs'=>1, 'maxbytes'=>$CFG->userquota, 'maxfiles'=>-1, 'accepted_types'=>'*');
file_prepare_standard_filemanager($data, 'files', $options, $context, 'user', 'private', 0);
$mform = new block_private_files_form(null, array('data'=>$data, 'options'=>$options));
if ($mform->is_cancelled()) {
redirect(new moodle_url('/my/'));
} else if ($formdata = $mform->get_data()) {
$formdata = file_postupdate_standard_filemanager($formdata, 'files', $options, $context, 'user', 'private', 0);
redirect(new moodle_url('/my/'));
}
echo $OUTPUT->header();
echo $OUTPUT->box_start('generalbox');
$mform->display();
echo $OUTPUT->box_end();
echo $OUTPUT->footer();
redirect(new moodle_url('/user/files.php'));
+5
View File
@@ -0,0 +1,5 @@
/* Rule so that the table tree view works with word-wrap: break-word. */
.block_private_files .content table {
table-layout: fixed;
width: 100%;
}
+3
View File
@@ -80,5 +80,8 @@ function xmldb_block_section_links_upgrade($oldversion, $block) {
// Put any upgrade step following this
// Moodle v2.6.0 release upgrade line.
// Put any upgrade step following this.
return true;
}
+3
View File
@@ -69,5 +69,8 @@ function xmldb_block_selfcompletion_upgrade($oldversion, $block) {
// Put any upgrade step following this.
// Moodle v2.6.0 release upgrade line.
// Put any upgrade step following this.
return true;
}
+3
View File
@@ -70,5 +70,8 @@ function xmldb_block_settings_upgrade($oldversion, $block) {
// Put any upgrade step following this.
// Moodle v2.6.0 release upgrade line.
// Put any upgrade step following this.
return true;
}
+1 -1
View File
@@ -27,4 +27,4 @@
$string['enabledock'] = 'Allow the user to dock this block';
$string['pluginname'] = 'Administration';
$string['settings:addinstance'] = 'Add a new administration block';
$string['settings:myaddinstance'] = 'Add a new settings block to My home';
$string['settings:myaddinstance'] = 'Add a new administration block to My home';
@@ -72,6 +72,8 @@ class block_site_main_menu extends block_list {
$strmovefull = strip_tags(get_string('movefull', '', "'$USER->activitycopyname'"));
$strcancel= get_string('cancel');
$stractivityclipboard = $USER->activitycopyname;
} else {
$strmove = get_string('move');
}
$editbuttons = '';
@@ -89,6 +91,14 @@ class block_site_main_menu extends block_list {
}
if (!$ismoving) {
$actions = course_get_cm_edit_actions($mod, -1);
// Prepend list of actions with the 'move' action.
$actions = array('move' => new action_menu_link_primary(
new moodle_url('/course/mod.php', array('sesskey' => sesskey(), 'copy' => $mod->id)),
new pix_icon('t/move', $strmove, 'moodle', array('class' => 'iconsmall', 'title' => '')),
$strmove
)) + $actions;
$editbuttons = html_writer::tag('div',
$courserenderer->course_section_cm_edit_actions($actions, $mod, array('donotenhance' => true)),
array('class' => 'buttons')

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