18508 Commits

Author SHA1 Message Date
Frederic Massart
9189888989 MDL-55797 mod_quiz: Convert question chooser to template
Part of MDL-55071
2016-09-23 10:55:17 +01:00
Damyon Wiese
63e4df60f6 MDL-55839 behat: Behat fixes for theme_noname
This is a squash of many small fixes.
The list of changes are:

Initial set of behat selectors overrides required for new theme.

set core behat selectors if not overridden by theme

Remove pause

Fix for checkboxes not saving properly

Custom override for click in the user menu

Fix for behat guessing the field type.

Behat fix for guessing the correct field type.

Fix for missing closeElementBefore mforms mess.

Fix for textareas not displaying their contents.

Fix availability form element

Fix action menu selectors for activities in a course page

Fix textareas not retaining their values

Fix selector for blocks

I had to change the single select template to use an input instead of a button because of a
behat bug we have not tracked down yet.

Fix for frozen attribute in form elements

Use input instead of button while behat is still broken

Fix for navigation selector override

Behat selector fixes and multi-select fixes for templated select

Fix for configure blocks selector + booleans for autocomplete

Fixes for course_summary behat tests

Allow optgroups in single_select

Behat fixes for block_navigation

Fixes for url form element and activity chooser selectors

blocks_social - fix specific selector for behat

Fix export_for_template for selectgroups element.

Dont set empty id on the form

Fix direct call to behat_navigation in backup context

Checkbox empty value fix

Fix for assign grading panel popouts

file picker overrides to find a file manager in the page

Fix chat tests to use element name

Make selectors in mod_data behat less specific

MDL-55839: recent activity behat test relies on time()

SQUASH Honour mform element "class" attribute on the container

SQUASH Fixes for behat in mod_forum

SQUASH search form template showing value as text next to the button

SQUASH undo double selectgroup fix

SQUASH - The slightly different structure to action menus breaks course drag and drop

SQUASH Wrap loading icon in a span so the selector still works.

SQUASH Fix fragile javascript in report_loglive

SQUASH Fix tabtree, and selectgroups for mod_feedback

Also - do-not enhance the action menu - we are dropping support for this.

SQUASH Fix filemanager selector and pix_icon template for mod_forum tests.

SQUASH Fixes to breadcrumb and add formid to single select (fixes mod_glossary tests)

SQUASH lesson behat fixes. 95% of lesson styles were rubbish so they were disgarded.

SQUASH Fix lti behat tests - they were cheating and using a context step from quiz

SQUASH Behat fixes for quiz with new theme

SQUASH behat fixes for mod_wiki

SQUASH Workshop behat fixes

SQUASH Frozen form elements cannot use a readonly form element because it screws with the form JS "disabledIf" stuff.

SQUASH Fixes for grades behat tests

SQUASH behat fixes for groups

SQUASH blacklist action menu tests

SQUASH Fix for tag form element missing "manage standard tags" link

SQUASH Incomplete fixes for course behat tests

SQUASH behat fixes for badges

SQUASH Tags fixes for behat

SQUASH filepicker fixes for behat

SQUASH Abort guessing field type when we hit 'html'

SQUASH Fix for admin/tool/behat tests

SQUASH fix for admin tool behat tests

SQUASH fix for availabilty conditions hiding "aria-hidden" elements

SQUASH give the blocks more room. We get behat files because nav tree nodes are not in view

SQUASH Blocks fixed

Fix behaviour of unchecked checkboxes

SQUASH Remove incorrect step in user test

SQUASH behat fixes for course tests

Part of MDL-55071
2016-09-23 10:55:16 +01:00
Frederic Massart
c2f12b0d16 MDL-55831 mod_quiz: Fix selectors to handle renderer overrides
Part of MDL-55071
2016-09-23 10:55:16 +01:00
Frederic Massart
326a8e0c99 MDL-55805 mod_forum: Convert 'Add a new topic' to true single_button
Part of MDL-55071
2016-09-23 10:55:14 +01:00
Frederic Massart
525ef9c8b4 MDL-51948 core: Patch core areas for LTR forms
Part of MDL-55071
2016-09-23 10:55:14 +01:00
Frederic Massart
113efed5b0 MDL-51948 admin: Make admin settings RTL friendly
Part of MDL-55071
2016-09-23 10:54:22 +01:00
Frederic Massart
10deddd34e MDL-55594 mod_forum: Convert 'big' search form to templates
Part of MDL-55071
2016-09-23 10:53:56 +01:00
Frederic Massart
66bb9eadfe MDL-55497 mod_forum: Converted quick forum search to a renderable
Part of MDL-55071
2016-09-23 10:53:29 +01:00
Frederic Massart
69b06947d6 MDL-55377 output: Minor adjustments for automatic RTL support
Part of MDL-55071
2016-09-23 10:53:29 +01:00
Frederic Massart
ed7844b5f4 MDL-55224 theme_noname: RTL adjustments for auto-flipping era
Part of MDL-55071
2016-09-23 10:49:49 +01:00
Jun Pataleta
1e7490ad9a MDL-49609 mod_lti: Content-Item message type-related unit tests 2016-09-23 16:29:27 +08:00
Jun Pataleta
6696cdab8f MDL-49609 mod_lti: Content-Item message type-related Behat tests 2016-09-23 16:29:27 +08:00
Jun Pataleta
c1fae2b928 MDL-49609 mod_lti: Refactor content-item and make it work using JS
* Rebase and resolve conflicts from initial patch.
* Reorganise contentitem and contentitem_return pages.
* Add capability checks for contentitem and contentitem_return pages.
* Move the building of Content-Item selection request to a local
  lib function.
* Move contentitem_return processing logic to a local lib function.
* Fix type settings update. Content-item checkbox does not get
  checked/unchecked on load.
* Fix  tool settings update. Disabled content-item checkbox gets unchecked when
  tool settings form is submitted.
* Add "Select content" button on load which launches the content item
  selection dialogue.
* Move hardcoded HTML and JS to mustache templates and AMD modules.
* Use standard YUI dialog for displaying the Content-Item selection page.
* Added processing for the following Content-Item properties:
  - text
  - icon
* On ContentItem selection, fill out form with the configuration data retrieved,
  instead of automatically saving the tool and redirecting to the course page.
* Removed section- and sectionreturn-related code since we're not automatically
  adding the tool on ContentItem selection.
* On mod_lti_mod_form, enable configuration fields if they support ContentItem
  selection.
* New form-field module for setting fields using JS
* Change types_config table's 'value' column from char(255) to text
2016-09-23 16:29:19 +08:00
Eloy Lafuente (stronk7)
0fba5b440d MDL-55327 mod_lesson: better convert back to plain response_editor 2016-09-22 19:17:47 +02:00
Andrew Nicols
dd193ba2ea Merge branch 'wip-MDL-55327-master-fix' of git://github.com/abgreeve/moodle 2016-09-22 15:51:04 +08:00
Simey Lameze
981356b23d MDL-54802 mod_quiz: Add validation to require passing grade greater than 0
This commit adds a form validation to prevent the creation of quizzes
using zero or null grade to pass when using require passing grade.
2016-09-22 08:48:11 +08:00
Andrew Nicols
41ff0ee58b MDL-55982 mod_forum: Allow discussion view in locked blog 2016-09-22 08:22:13 +08:00
Adrian Greeve
f4eef5fb25 MDL-55327 mod_lesson: Fix for copying essay and match.
Matching and essay questions would display errors when
being duplicated.
2016-09-21 18:04:08 +08:00
Eloy Lafuente (stronk7)
6cc077e90f Merge branch 'MDL-55982-master' of git://github.com/andrewnicols/moodle 2016-09-21 03:04:36 +02:00
Andrew Nicols
0f3bbfd4f8 MDL-55982 mod_forum: Add time-based discussion locking
This patch adds support for time-based locking of discussions.
Discussions are automatically locked after a user-definable period of
inactivity. After this time, only those with the the relevant capability
are able to add replies.

This has been designed to add support for other types of discussion locking
at a later date with relative ease.
2016-09-21 09:03:42 +08:00
Juan Leyva
fad980b26f MDL-55785 mod_glossary: Check user can create new entries 2016-09-20 10:52:53 +01:00
Juan Leyva
f0e1808fc4 MDL-55785 mod_glossary: New Web Service mod_glossary_add_entry 2016-09-20 10:52:53 +01:00
Juan Leyva
e6de11d7b7 MDL-55785 mod_glossary: Move edit.php code to new lib function
Most of the code that was in mod/glossary/edit.php has been moved to
mod/glossary/lib.php:glossary_edit_entry
2016-09-20 10:48:41 +01:00
Juan Leyva
114eaf519d MDL-55740 assign: Add assignment WS to the mobile service
* mod_assign_submit_grading_form
* mod_assign_get_participant to the mobile service
2016-09-20 10:31:50 +01:00
Andrew Nicols
5a766a9e21 MDL-55327 mod_lesson: Whitespace fix 2016-09-20 11:19:28 +08:00
Andrew Nicols
25804281f1 Merge branch 'wip-MDL-55327-master' of git://github.com/abgreeve/moodle 2016-09-20 11:15:54 +08:00
Adrian Greeve
329b68c9ca MDL-55327 mod_lesson: Behat test for page duplication. 2016-09-20 10:36:13 +08:00
Adrian Greeve
f847669e33 MDL-55327 mod_lesson: Unit tests for the new function 2016-09-20 10:36:13 +08:00
Adrian Greeve
9f937c3bb3 MDL-55327 mod_lesson: Added the ability to duplicate pages. 2016-09-20 10:36:13 +08:00
Dan Poltawski
a2184f971f Merge branch 'master_MDL-55820' of git://github.com/danmarsden/moodle 2016-09-19 11:32:19 +01:00
Dan Poltawski
daa571af9f Merge branch 'MDL-55944' of https://github.com/mr-russ/moodle 2016-09-19 11:25:12 +01:00
Dani Palou
d33c67bc47 MDL-56019 ws: Use itemid null when getting modules intro 2016-09-19 11:33:55 +02:00
David Monllao
9df9382e4d Merge branch 'MDL-42041-master' of git://github.com/andrewnicols/moodle 2016-09-19 15:08:56 +08:00
spvickers
d8f9109a12 MDL-49609 mod_lti: Add Content-Item message
Added option for tools to support Content-Item message and redirect
to/from tool provider when creating an instance.
2016-09-18 22:16:10 +08:00
Andrew Nicols
4e2e54eed0 MDL-55866 mod_data: Remember editor enabled state for templates
Some templates can legitimately contain invalid HTML (e.g. mismatched tags)
because the templates operate in pairs.

In these instances we should not use an editor because the nature of the
editor (content editable) means that the browser automatically corrects all
HTML supplied to it, thus breaking the template entirely.

Therefore we need to disable HTML editors for some templates, and do so in
a way tied to the instance of the activity, rather than to a specific user.

This patch adds a new 'config' field, with matching setters and getters, to
allow such per-instance values to be stored.
2016-09-15 08:38:10 +08:00
David Mudrák
161131f057 MDL-55957 workshop: Add behat tests for embedded images
This tests basic functionality of the images embedded into the
instructions and conclusion fields.
2016-09-14 14:25:41 +02:00
David Mudrák
e46aec4c45 MDL-55957 workshop: Fix the embedded files serving
There was a bug with serving the files from the areas instructauthors,
instructreviewers and conclusion. These three areas should not use the
itemid in the plugininfo URLs. But they did use 0 as the itemid which
broke the file previews when browsing via server files repository.

The first part of the patch fixes all relevant calls to
file_rewrite_pluginfile_urls() so that null is now properly used instead
of zero.

The second part of the fix is that we no longer delete the first $args
element in the workshop_pluginfile() function - the itemid is not
supposed to appear there now.

The last part of the patch is that instead of repeating the same code
block copy&pasted for each file area in workshop_pluginfile(), we now
have a single block covering them all.
2016-09-14 12:14:56 +02:00
Andrew Nicols
8bdd97a35a MDL-54872 mod_assign: Allocate Unique IDs before tests 2016-09-14 09:20:33 +08:00
Russell Smith
74ee9d29d2 MDL-55944 testing: Reduce sleep usage.
Remove sleep() and replace with waiting for a second to roll over,
this results in a simpler call the guarantee time() has moved forward
2016-09-14 09:49:30 +10:00
David Monllao
c46432ad6c Merge branch 'MDL-54872-master' of git://github.com/andrewnicols/moodle 2016-09-13 10:05:26 +08:00
Eloy Lafuente (stronk7)
9579b52372 Merge branch 'wip-MDL-55505-master' of git://github.com/abgreeve/moodle 2016-09-12 19:19:45 +02:00
Eloy Lafuente (stronk7)
61b246fd0e Merge branch 'MDL-55632-master' of git://github.com/andrewnicols/moodle 2016-09-12 19:12:26 +02:00
Andrew Nicols
eb4c466162 MDL-54872 assign: Order blindly marked assignments more blindly 2016-09-12 09:29:45 +08:00
Adrian Greeve
a14cde804e MDL-55505 mod_assign: Editing previous attempt works correctly.
Editing a previous attempt keeps the current feedback and grades
as it should and does not override them.
2016-09-08 20:31:05 +08:00
Adrian Greeve
80753d3107 MDL-41174 mod_workshop: Added workshop_refresh_events
This function was missing from this activity.
2016-09-07 14:29:13 +08:00
Andrew Nicols
64ebf3955b MDL-37669 mod_forum: Mark posts as read on notify to user pref
Some people prefer to have posts marked as read when they receive them, and
some prefer not to. Let us allow them to choose.
2016-09-07 12:32:42 +08:00
Eloy Lafuente (stronk7)
a6a787c011 Merge branch 'MDL-55236' of https://github.com/bostelm/moodle 2016-09-06 20:30:49 +02:00
Eloy Lafuente (stronk7)
69e18dbf70 Merge branch 'wip-MDL-55832-master' of git://github.com/marinaglancy/moodle 2016-09-06 15:56:01 +02:00
Dan Poltawski
2e79c7305d MDL-42125 quiz stats: removal trivial additional phpdocs newline 2016-09-06 11:47:57 +01:00
Dan Poltawski
7c5b0bbcbe Merge branch 'MDL-42125' of git://github.com/timhunt/moodle 2016-09-06 11:46:52 +01:00