Commit graph

19281 commits

Author SHA1 Message Date
Rajesh Taneja
e259795c4f
MDL-55329 behat: PyStrings should end with : (colon) 2016-08-09 14:22:21 +08:00
Andrew Nicols
19491e68fe MDL-41126 mod_data: Add type hinting 2016-08-09 12:49:01 +08:00
Andrew Nicols
d5bd76f4e5 MDL-41126 mod_data: Styling fixes 2016-08-09 12:49:01 +08:00
Andrew Nicols
20195fb46a Merge branch 'wip-mdl-41126' of https://github.com/rajeshtaneja/moodle 2016-08-09 12:47:35 +08:00
Jun Pataleta
d3932d2b51 MDL-53765 core: Deprecate update_module_button functions
First stage deprecation for the functions update_module_button and
core_renderer::update_module_button().
2016-08-09 11:17:43 +08:00
Rajesh Taneja
9f2b916dee
MDL_41126 phpunit: Timestamp should be less than 2038
http://php.net/manual/en/datetime.gettimestamp.php#114590
In 32-bit system the unix timestamp will overflow if the date goes beyond year 2038
and this method will return false.
2016-08-09 10:50:07 +08:00
Andrew Nicols
675345475d MDL-55274 mod_chat: Add unit tests for special commands 2016-08-09 10:44:08 +08:00
Rex Lorenzo
6a853f7521 MDL-53765 mod_resource/mod_wiki: Removed update_module_button() 2016-08-09 10:00:54 +08:00
Andrew Nicols
fe88f065b7 Merge branch 'MDL-55274-master' of git://github.com/lameze/moodle 2016-08-09 09:05:09 +08:00
Dan Poltawski
49924b335e Merge branch 'MDL-55398_m32v1' of https://github.com/sbourget/moodle 2016-08-08 10:40:42 +01:00
Marina Glancy
e96c826c3d MDL-55333 mod_feedback: work around MySQL tables in join limit 2016-08-08 14:40:27 +08:00
Marina Glancy
8676e7c3e0 MDL-18592 mod_choice: Allow teachers to make choice for students
Capability to delete reponses becomes capability to delete or modify
responses.

This also resolves MDL-51659 (incorrect events answer_submitted and
answer_updated) by deprecating them and replacing with the answer_created
2016-08-08 14:16:57 +08:00
Andrew Nicols
6ab25fa0b2 Merge branch 'MDL-41126' of git://github.com/dg711/moodle 2016-08-08 13:24:25 +08:00
Nick Phillips
376be6ae86 MDL-55274 mod_chat: regain beep and / command in mod_chat.
format_text cannot be called on the whole input text, but must be
called on user-supplied text that will be output into chats. This
means it cannot simply be called in one place, but must instead be
called on the relevant parts of text once commands have been matched.
2016-08-08 12:30:33 +08:00
Andrew Nicols
e6ab38f3ca Merge branch 'MDL-55454' of git://github.com/timhunt/moodle 2016-08-08 10:00:30 +08:00
Stephen Bourget
9f03fc3119 MDL-55464 mod_label: Add view permissions 2016-08-04 21:27:02 -04:00
Devang Gaur
400eb2d0e5 MDL-41126 mod_data: added field and entry generator 2016-08-05 04:08:50 +05:30
Rajesh Taneja
99ad3223a5
MDL-54656 behat: Skip test if db family is not mysql or postgres 2016-08-04 08:46:04 +08:00
Tim Hunt
0e9132e56e MDL-55454 quiz: loses shufflequestion setting restoring old backups 2016-08-03 18:42:51 +01:00
Andrew Nicols
1a354b81b6 MDL-54941 glossary: Correct variable naming for entry files 2016-08-03 14:33:53 +08:00
Simey Lameze
472ac2d390 MDL-55355 mod_feedback: Change show chart data step to avoid errors 2016-08-03 10:22:58 +08:00
Eloy Lafuente (stronk7)
bc7817edab Merge branch 'MDL-54656_m32v3' of https://github.com/sbourget/moodle 2016-08-03 00:50:19 +02:00
Eloy Lafuente (stronk7)
8c7840df32 Merge branch 'MDL-54941-master' of git://github.com/jleyva/moodle 2016-08-03 00:29:45 +02:00
Eloy Lafuente (stronk7)
dffeff0a4b Merge branch 'MDL-55322-master' of https://github.com/snake/moodle 2016-08-03 00:12:10 +02:00
Eloy Lafuente (stronk7)
5fe1db394b Merge branch 'MDL-54745_master' of https://github.com/snake/moodle 2016-08-02 23:13:25 +02:00
Eloy Lafuente (stronk7)
e0519d032d Merge branch 'MDL-55314-master' of https://github.com/mrmark/moodle 2016-08-02 17:16:07 +02:00
Eloy Lafuente (stronk7)
8a78cb42da Merge branch 'MDL-55315-master' of https://github.com/mrmark/moodle 2016-08-02 17:07:16 +02:00
Eloy Lafuente (stronk7)
03961256d1 Merge branch 'MDL-55348-master' of git://github.com/dpalou/moodle 2016-08-02 16:48:26 +02:00
Simey Lameze
30452f23cb MDL-55352 mod_feedback: Change series labels on multi choice rated 2016-08-02 09:23:18 +08:00
Andrew Nicols
b34d7e700b Merge branch 'MDL-54879-master' of git://github.com/junpataleta/moodle 2016-08-02 09:10:19 +08:00
Stephen Bourget
952c6e2697 MDL-55398 mod_feedback: prevent direct script access to lib files. 2016-08-01 20:53:46 -04:00
Andrew Nicols
8f33657dae Merge branch 'MDL-55140_m32v2' of https://github.com/sbourget/moodle 2016-08-02 08:48:36 +08:00
Dan Poltawski
6349765c44 Merge branch 'MDL-55360-master-workshopgradepass' of git://github.com/mudrd8mz/moodle 2016-08-01 18:57:00 +01:00
Dan Poltawski
4638a26eca MDL-55376 assign: trailing whitespace 2016-08-01 16:07:43 +01:00
Dan Poltawski
b9fe2f38d4 Merge branch 'MDL-55376-master' of git://github.com/cameron1729/moodle 2016-08-01 16:07:00 +01:00
Dan Poltawski
307e63cb00 Merge branch 'MDL-55374-master' of git://github.com/damyon/moodle 2016-08-01 13:50:37 +01:00
Dan Poltawski
a5cb07477c Merge branch 'MDL-55352-master' of git://github.com/lameze/moodle 2016-08-01 09:30:33 +01:00
Jake Dallimore
0cced3ced3 MDL-54745 mod_assign: Remove leftover changegradewarning string and js 2016-08-01 12:48:25 +08:00
Jake Dallimore
243ddbcf50 MDL-55322 assignfeedback_editpdf: Prevent scroll when moving comments
Prevent the default scroll behaviour when using gestures to move
comments on the mobile site.
2016-08-01 09:43:03 +08:00
Cameron Ball
867b413181
MDL-55376 mod_assign: Fix bug stopping admin from editing submissions 2016-07-29 19:05:22 +08:00
Simey Lameze
9698ca2d20 MDL-55352 core: Label values series should override tooltip 2016-07-29 13:22:59 +08:00
Damyon Wiese
fca211bf05 MDL-55374 mod_assign: Force utf-8 for DOMDocument
This prevents charset issues on some sites.
2016-07-29 10:43:25 +08:00
Juan Leyva
145900708c MDL-54941 webservice: Refactor file handling in WS
This commit reduces boilerplate code.
It also forces WS returning files to always return the following
fields: filename, filepath, mimetype, filesize, timemodified and
fileurl.
2016-07-28 12:07:04 +02:00
Dani Palou
3b40103c2f MDL-55348 wiki: Convert 'section' WS params to PARAM_RAW 2016-07-28 10:35:24 +02:00
David Mudrák
aea8c5541e MDL-55360 workshop: Add tests for setting grades to pass via mod form
These scenarios should cover common cases of defining the grades to pass
pass via the workshop settings form. Note that behaviour of the fields
in terms of locale-specific decimals input (MDL-51806) is not covered
with these tests as I want to avoid installation of additional language
pack. Instead, I assume that functionality of unformat_float() is tested
separately in the core.
2016-07-28 09:54:43 +02:00
David Mudrák
3c4cc10eff MDL-55360 workshop: Emptying grades to pass should set them to zero
When editing existing workshop with a grade to pass defined, when the
field is emptied, it should be interpreted as setting it to zero. This
was not happening because unformat_float replaces the field with null,
therefore effectively unsetting it.

By casting to float, we interpret all empty values (including null) as
zeros. This behaviour is consistent with how gradebook setup UI works.
2016-07-28 09:54:43 +02:00
David Mudrák
ebf0598e21 MDL-55360 workshop: Allow creating workshops with empty grades to pass
As a regression of MDL-55360, it was not possible to create new
workshops if the field "Submission grade to pass" or "Assessment grade
to pass" was left empty. The validation failed with "You must enter a
number here".

The fields submissiongradepass and gradinggradepass are always present
as we explicitly define them in the mod form. So the isset() condition
in the validation was useless and it did not allow to submit the form
with these fields empty.

Additionally, the unformat_float() returns null only if it receives
empty value on the input. Which can't happen in our case so I am
removing this condition to improve the readability of the code.
2016-07-28 09:54:43 +02:00
David Mudrák
87b5c584fb MDL-55289 workshop: Fix files processing in example submissions
While testing the issue MDL-55289 I realized that attaching files to
workshop example submissions does not work at all and throws an error.

The reason was that in MDL-50794 (996f7e82), the variables $contentopts
and $attachmentopts were replaced with the result of the methods
submission_content_options() and submission_attachment_options().
But I forgot to perform the full refactoring in exsubmission.php too.

Attached behat test should cover both issues on this branch.
2016-07-28 09:51:16 +02:00
David Mudrák
21d49a3f93 MDL-55289 workshop: Include repository/lib.php to use its constants
As a result of MDL-41556 (146893d6), the repository/lib.php was included
in submission.php so that its constant FILE_INTERNAL could be used in
field options. Recent development in MDL-50794 (996f7e8) moved the
options declaration to standalone methods but we forgot to check they
work in exsubmission.php too.

This patch moves the repository/lib.php inclusion to where the
library is actually needed.

Additionally it unifies how options are set for overall feedback content
and overall feedback attachment fields.
2016-07-28 09:51:16 +02:00
Jun Pataleta
653b8ef24b MDL-54879 mod_lti: Add fallback options for error message upon failure 2016-07-28 14:38:29 +08:00