750 Commits

Author SHA1 Message Date
Andrew Nicols
61f56fd5f9 Merge branch 'MDL-43648_m35v2' of https://github.com/sbourget/moodle 2018-01-09 11:43:33 +08:00
Zig Tan
85ba9528c9 MDL-33886 backup: Add backup filename length < 255 char validation 2017-12-22 13:03:08 +08:00
Stephen Bourget
57422d7158 MDL-43648 course: Allow start /end dates to have times 2017-12-14 19:48:31 -05:00
Marina Glancy
dc9353a07b MDL-27886 backup: When setting is unlocked set it to original value 2017-11-23 12:21:03 +08:00
Damyon Wiese
18c02e9f28 Merge branch 'MDL-27886-master' of git://github.com/tobiasreischmann/moodle 2017-11-20 13:25:37 +08:00
Luca Bösch
9ae6cd775a MDL-60693 backup: Use multilang with course activities
On backup and restore, activities are shown after passing format_string,
supporting multilang.
2017-11-12 14:58:18 +01:00
Tobias Reischmann
34eb2faa0d MDL-27886 backup: Decision if a setting is fixed based on level
Previously, when a during backup/restore the "Schema"-stage is loaded,
some settings are fixed if they are LOCKED_BY_HIERARCHY. However, user
data fields of activities can be locked, when the section they are
contained in has user data set to false. When this setting is changed on
the same screen, the fixed setting of the activity can not be "unfixed"
by javascript.

This patch adds a settings-level to the call of is_changeable. With this
only those dependency_settings are considered, which belong to parent
settings, which are not changeable on the current stage.
2017-11-06 12:07:20 +01:00
Tobias Reischmann
8c067bb86d MDL-27886 backup: Enabled unlocking of backup settings
The function is_locked was changed to determine only, if the
dependency_setting want's the dependent setting to be locked.
In the previous version, is_locked did not only check, if the
dependency_setting want's the setting to be locked, but also if the
setting was already locked. A recursive call to the status of the
dependent setting leaded to problems, when unlocking locked settings.

Also the PHPDOC of the is_locked was adjusted to coincide with the current
usage in backup_ui_settings->is_changeable() and
base_setting->set_status(). In both functions all dependency_settings of
a setting are iterated to check if this setting should be or is LOCKED_BY_HIERARCHY.
The actual state of the setting was therefore either checked beforehand
or is not interesting, since the question is, if it shall be changed.
2017-11-06 12:07:20 +01:00
Tobias Reischmann
77a4d33755 MDL-27886 backup: Added behat tests for user data settings
This new test defines different combinations of global and local user
data settings during the restore process and tests that global defaults
can be overriden.
2017-11-06 12:07:20 +01:00
Eloy Lafuente (stronk7)
00e557a15d MDL-36580 backup: General support for decrypted contents in restore
- Uses site generated (on backup) key.
- Can be applied potentially everywhere in the restore process.
- Covered with unit tests.
- Authentication / integrity aware so can be used between any 2 servers
  (just requires matching key).
2017-10-19 10:11:47 +02:00
Marina Glancy
78da366b56 MDL-60281 general: various strict corrections for PHP7.2
- count() can only be called on arrays or Countable, it can not be called on null
- recordset is neither so iterator_count() should be used
- instanceof or get_class() can not be applied to non-objects
- class methods must have the same arguments as methods in parent class
2017-10-16 09:37:20 +08:00
Jake Dallimore
5bbea7338d MDL-35429 backup: Only show relevant actions for automated backups
- Users without permission to download or restore won't see the
respective links.
- The 'Manage backup files' button for the 'automated' backup filearea
now requires the same permissions as downloading does for this filearea,
those being 'restore:userinfo' and 'backup:downloadfile'.
2017-10-10 12:30:57 +08:00
Ankit Agarwal
23876070b9 MDL-59908 backup: Add tests to make sure both http(s) schemes are parsed 2017-08-24 10:33:24 +05:30
Andrew Nicols
34cf57f1d0 Merge branch 'MDL-53537_m34v4' of https://github.com/sbourget/moodle 2017-08-16 08:46:55 +08:00
Stephen Bourget
f5de9484e8 MDL-53537 core_backup: Add a course_backup_created event 2017-08-15 14:10:38 -04:00
Mark Nelson
f1dd575c6f MDL-59737 core_backup: changed reference to domain doesntexist.com 2017-08-07 17:17:58 +08:00
Andrew Nicols
77c5325f81 Merge branch 'MDL-9367-master' of git://github.com/ankitagarwal/moodle 2017-08-01 13:39:38 +08:00
Ankit Agarwal
0d14fcbc60 MDL-9367 restore: Roll only configuration dates
It was decided to roll only configuration dates and any date related to user content
such as 'timecreated' , 'timemodified' etc should not be rolled forward.
2017-08-01 10:46:37 +05:30
Mark Nielsen
197e2bca5b MDL-59602 behat: make use of new course nav steps 2017-07-21 13:50:47 -07:00
Dmitrii Metelkin
597c6f2a09 MDL-58811 backup: fix an extra slash on restore for the legacy files 2017-05-16 14:35:16 +10:00
Marina Glancy
0302548806 MDL-58594 backup: setting locked by permission can not be overriden 2017-05-01 17:04:04 +08:00
Eloy Lafuente (stronk7)
aa2b5b214d Merge branch 'wip-MDL-57769-master' of https://github.com/marinaglancy/moodle 2017-04-05 01:31:08 +02:00
Simey Lameze
fdeeaff954 MDL-58265 core_test: replace I turn editing on steps
Also remove few more unnecessary steps that redirects behat to
site home page to actually get to the course.

Part of MDL-55611 epic.
2017-04-03 11:37:07 +08:00
Simey Lameze
93be3f730c MDL-58265 core_test: remove unnecessary steps
This commmit removes steps that take behat to site home page
to actually get to a course page.

Part of MDL-55611 epic.
2017-04-03 11:37:07 +08:00
Simey Lameze
c987d1b2ef MDL-58265 core_test: replace all uses of I follow course steps
Part of MDL-55611 epic.
2017-04-03 11:37:07 +08:00
Marina Glancy
1091687ac2 MDL-57769 backup: support removed 'numsections' in backup/restore 2017-03-30 08:26:17 +08:00
Marina Glancy
af0698c007 MDL-57769 format_topics: remove numsections option 2017-03-30 08:26:17 +08:00
Dan Poltawski
48f5c05019 Merge branch 'wip-MDL-34859-master' of git://github.com/marinaglancy/moodle 2017-03-20 07:54:22 +00:00
Marina Glancy
44e86fb3d5 MDL-34859 backup: add restore defaults 2017-03-20 14:59:45 +08:00
Damyon Wiese
3e6adcd69c MDL-40759 icons: Rename activity_icon
image_icon is a better name because there are some valid uses for these other than for activity icons.

E.g. Old JS code that is not worth re-writing.
2017-03-17 15:52:18 +08:00
Damyon Wiese
8857c715d1 MDL-40759 icons: Behat fixes for font-awesome 2017-03-17 15:52:18 +08:00
Damyon Wiese
c2dde7eebc MDL-40759 icons: Split pix_icon from activity_icon
Activity icons always use the standard icon renderer.
2017-03-17 15:51:29 +08:00
Marina Glancy
92253b15b7 MDL-40838 backup: restore enrolment methods without users 2017-02-20 12:08:35 +08:00
B Krishnan Iyer
5c3e1eedb7 MDL-57354 output: Render continue button as a primary button. 2017-02-13 15:50:52 +00:00
Rajesh Taneja
2700a9aff1
MDL-57325 behat: Fixed backup/restore steps to use proper api 2016-12-09 09:30:18 +08:00
Marina Glancy
e5287f9b3b MDL-56614 behat: navigate without navigation and admin blocks 2016-12-06 11:49:14 +08:00
David Herney
5634310997 MDL-57169 backup: ensure images in category descriptions are shown 2016-11-29 11:40:47 +08:00
Marina Glancy
392367c4f7 MDL-56586 behat: fix behat tests to work with new add block 2016-11-25 14:04:10 +08:00
Frederic Massart
3d3fb328b4
MDL-57063 backup: Do not try to set default value on locked setting
We cannot set a default value on settings which are 'config' or
'permission' locked or an exception will be thrown from
base_setting::set_value.
2016-11-21 11:03:41 +08:00
Rajesh Taneja
4ea8f814a0
MDL-56981 behat: Fixed xpath of radio button to contain class 2016-11-16 08:14:07 +08:00
Damyon Wiese
813afc6797 MDL-56618 behat: Fix xpath for behat
We changed the output so the test needs to match
2016-11-15 09:07:39 +00:00
Damyon Wiese
fe3db0ca08 MDL-56618 theme_boost: Fix backup / restore pages (again)
I removed most of the layout styles and started again.
2016-11-14 15:00:46 +08:00
Jake Dallimore
ff4230d88e MDL-54751 behat: Support for adhoc module and section deletion in behat
Introduced new behat step for running all pending adhoc tasks and
modified the relavant behat tests.
2016-11-07 07:41:59 +08:00
Jake Dallimore
3869d77411 MDL-54751 core_course: Edit course libs to support deletion flag
Changed the course libs such that module and section deletion is now
handed off to relevant functions in the util class and exempted
modules scheduled for deletion from the course backups.
2016-11-07 07:41:59 +08:00
Eric Merrill
880fc15bf0 MDL-47162 core_message: Updating all uses of messaging to add courseid 2016-10-31 14:13:13 -04:00
Amanda Doughty
cc350fd9c8 MDL-47162 core_message: Add course id to message eventdata 2016-10-27 18:11:27 +02:00
Dan Poltawski
7af5ad97c1 MDL-46942 events: fix naming of other param
originalcourseid matches coding style
2016-10-25 20:18:35 +01:00
Dan Poltawski
7e670910ed Merge branch 'MDL-46942-added-original-course' of https://github.com/jmalmsten-panopto/moodle 2016-10-25 20:15:55 +01:00
jmalmsten-panopto
3480411e0d MDL-46942 core_backup: added original course id to restore event 2016-10-24 09:01:34 -07:00
Frédéric Massart
17553c6350 MDL-56213 theme_boost: Visual inconsistencies in backup/restore
* Some additional SCSS rules were added to be more visually pleasing
* Javascript had to be tweaked as targets were too specific
2016-10-24 10:29:38 +01:00