171 Commits

Author SHA1 Message Date
Mark Johnson
6c484f9fc8
MDL-81611 assign: Close session early in gradingpanel fragment 2024-04-25 16:14:26 +01:00
Eloy Lafuente (stronk7)
ba1f804ffa
MDL-65292 style: Fix all function declarations white space
This has been generated running the following Sniffs, all
them part of the Moodle's CodeSniffer standard:
- PSR12.Functions.ReturnTypeDeclaration
- PSR12.Functions.NullableTypeDeclaration
- moodle.Methods.MethodDeclarationSpacing
- Squiz.Whitespace.ScopeKeywordSpacing

All them are, exclusively, about correct spacing, so the changes
are, all them, only white space changes.

Only exceptions to the above are 3 changes what were setting the
return type in a new line, and, when that happens, the closing
parenthesis (bracket) has to go to the same line than the colon.
2024-02-28 23:33:26 +01:00
Paul Holden
3f71011668
MDL-69497 mod_assign: amend preference definitions for current user.
Ensure they can always be updated when using the grader.
2023-12-01 10:34:35 +00:00
Alexander Van der Bellen
cf021d12c5 MDL-78650 mod_assign: Improve group submission action event handling
Don't return an event action when a group submission has already been submitted
by another student.
2023-11-01 20:24:24 +08:00
Paul Holden
ca95bee259
MDL-78333 mod_assign: final removal of deprecated log format methods. 2023-05-24 16:41:55 +01:00
Marina Glancy
8fc1486d36 MDL-77164 various: fix incorrect phpdocs 2023-04-13 11:35:06 +01:00
Mikhail Golenkov
6684ca3da7 MDL-74234 assign: Fix grading page for filtered out users 2022-06-14 19:04:06 +10:00
Andrew Nicols
4b388fc239 MDL-74235 core: Update core uses of activity icons to monologo 2022-04-07 12:56:14 +08:00
Mihail Geshoski
4a9c83ac9e MDL-73532 navigation: Modify methods that extend the setting nav
Introduces some changes to the exising _extend_settings_navigation()
methods that utilize the global $PAGE object. In order to accomodate
the changes done for the secondary navigation for single activity
courses, the methods that extend the settings navigation can no longer
rely on the $PAGE object, instead the more reliabe way to obtain this
infomation is through the get_page() method from settings_navigation
class.
2022-02-14 09:40:27 +08:00
Jake Dallimore
264e2b4781 Merge branch 'MDL-73354-master' of git://github.com/abgreeve/moodle 2022-02-10 14:14:41 +08:00
Adrian Greeve
33e6a36daf MDL-73354 mod_assign: General tidy up of tertiary navigation. 2022-02-09 10:52:34 +08:00
Mihail Geshoski
d0dad63bc3 MDL-73633 assign: Set 'Overrides' to link to user overrides by default 2022-02-02 10:34:29 +08:00
Bas Brands
f2ddd23ec1 MDL-71457 theme_boost: activity icon styling 2021-12-20 15:02:24 +01:00
Andrew Nicols
940097de9e Merge branch 'MDL-68913-master' of https://github.com/cameron1729/moodle 2021-11-11 10:49:05 +08:00
Matt Porritt
eaa1f56704 MDL-68913 Assign: Per attempt timing
This patch provides functionality to allow the
assign activity to have timed attempts for submissions.
It includes the logic, UI and adminstration changes
fot timed submissions.
2021-11-10 12:07:35 +08:00
abgreeve
e75eb8481d MDL-71912 mod_assign: Updating the activity to use the actionmenu.
Co-authored-by: Sujith Haridasan <sujith@moodle.com>
2021-11-09 11:24:08 +08:00
Simey Lameze
9afd980b4e MDL-72543 block_timeline: change the display of event names 2021-10-07 14:05:34 +08:00
Eloy Lafuente (stronk7)
ee22c95918 Merge branch 'MDL-70049-master_count_submissions' of https://github.com/agrowe/moodle 2021-05-06 23:26:50 +02:00
Shamim Rezaie
9e3b2d6f47 MDL-71163 core: support relative dates in activity dates
AMOS BEGIN
 CPY [relativedatessubmissionduedateafter,mod_assign],[relativedatessubmissionduedateafter,core_course]
 CPY [relativedatessubmissionduedatebefore,mod_assign],[relativedatessubmissionduedatebefore,core_course]
AMOS END
2021-04-30 17:13:51 +10:00
Jun Pataleta
11df82e9f7 Merge branch 'MDL-71410-master' of git://github.com/rezaies/moodle 2021-04-27 12:36:24 +08:00
Shamim Rezaie
4532d3f8b7 MDL-71410 mod_assign: Cache assign times in modinfo for performance
We update the dates with user/group overrides
2021-04-27 14:00:06 +10:00
Sara Arjona
12f64a02c9 Merge branch 'MDL-71144-master' of git://github.com/rezaies/moodle 2021-04-23 13:16:01 +02:00
Jun Pataleta
d484b3e371 MDL-71144 mod_assign: Deprecate assign_get_completion_state() 2021-04-22 10:08:04 +10:00
Luca Bösch
aee27d0a9b MDL-71118 core: Add grade (verb) string.
AMOS BEGIN
 CPY [grade,core],[gradenoun,core]
 CPY [grade,core],[gradeverb,core]
AMOS END
2021-04-17 11:46:09 +02:00
Alex Rowe
c8be1d7e94 MDL-70049 assign: count_submissions_need_grading call when can't grade 2021-04-06 10:32:56 +10:00
sam marshall
5e72715e4f MDL-71099 Lib: Move new user_fields class from core to core_user
This class would belong more appropriately within the 'user' API
(core_user) instead of within the 'core' API, since it is
directly related to user data.

Since the class has only just been added to Moodle, now is a good
time to move it.
2021-03-25 13:47:23 +00:00
Simey Lameze
1fcd850859 MDL-71182 calendar: Revert "Merge branch 'MDL-67494-master' of git://github.com/lameze/moodle"
This reverts commit 9d58d4de46e9415eb4ac405a340381de44c510c1, reversing
changes made to 535c0277de3547f02d94959fbe103e44a6706d4e.
2021-03-24 09:11:01 +08:00
sam marshall
558cc1b85e MDL-45242 Lib: Replace calls to deprecated functions
In all cases changes have been kept to a minimum while not making
the code completely horrible. For example, there are many instances
where it would probably be better to rewrite a query entirely, but
I have not done that (in order to reduce the risk of changes).
2021-03-10 10:57:10 +00:00
Simey Lameze
ac0a0bad63 MDL-67494 calendar: only user overrides should retain userid 2021-03-03 16:06:32 +08:00
David Mudrák
005b00dd9b MDL-68645 output: Do not apply filters when creating calendar events
Applying filters on an activity module description when using it as a
new calendar event's description is bad m'kay? We need to store the raw
text and apply the filters only when we actually display the text. That
way, filters (such as multi-language content) may actually fully work
and we do not initialise the theme and output machinery.

Additionally, we need to explicitly set the format of the description
text to HTML (because we have converted it to it already). Otherwise it
defaults to the current user's preferred editor format.

This is still a pragmatic hot-fix solution. The proper solution would be
to pass the raw text, format and embedded files.
2020-05-13 10:03:01 +02:00
Luca Bösch
439c8c5933 MDL-68216 block_recent_activity: Format elements more nicely. 2020-05-05 22:09:19 +02:00
Adrian Greeve
51cc5e1789 Merge branch 'MDL-66074-OCT28' of git://github.com/Chocolate-lightning/moodle_forum-project 2019-10-30 13:44:59 +08:00
Andrew Nicols
629726dd3f MDL-66079 assign: Switch to new gradeitem API
Part of MDL-66074
2019-10-30 10:23:40 +08:00
Sara Arjona
810d7a3d2e MDL-66609: core_h5p: Add <component>_get_path_from_pluginfile method
This method has been added to all the components having some exceptions
with the way they treat the itemid in the pluginfile paths.
2019-10-29 10:22:43 +08:00
Amaia Anabitarte
c0375ba73f MDL-66369 libraries: Remove [modname]_scale_used functions
These functions were only used by the deprecated function
which was deprecated in 3.1, and removed in 3.6.
2019-08-16 11:56:17 +08:00
John Yao
96e444665e MDL-65517 block_timeline: Hide completed course modules in Timeline
When some activities are manually completed by students, some are still showing in students' timeline.
This commit fix that for module assign,chat,choice,feedback,lesson,quiz,scorm and workshop.
2019-07-12 09:16:40 +10:00
Sara Arjona
375e2ecea0 MDL-57487 mod_assign: final deprecation xxx_print_overview
Apart from deprecating assign_print_overview , the following methods
have been also deprecated because they are not used anymore:
- assign_get_mysubmission_details_for_print_overview
- assign_get_grade_details_for_print_overview
2019-06-14 17:41:18 +02:00
Simey Lameze
c3781ebeb3 MDL-64879 mod_assign: deprecate legacy assign_cron() function 2019-02-26 11:25:58 +08:00
Marcus Fabriczy
f5d1dbb37f MDL-62893 mod: Grade visibility bug in the Outline/Complete reports
Grades that have been hidden will appear in the outline/complete
report - even if the user is a student.

The modules that have been fixed are:
* mod_assign
* mod_data
* mod_forum
* mod_glossary
* mod_lesson
* mod_scorm
* mod_workshop
2019-02-05 20:01:32 +10:30
Damyon Wiese
064f15033f MDL-60474 assign: Consistent user filters
Use the current filters and sorting on the user grading table in the single
page grading app when it is possible.

This replaces the popover used to configure the filters to one that closely matches the
one from the grading table. It supports standard filters, workflow filters and allocated marker filters.

It will also support group filtering and suspended user filtering but we don't show the controls for those in
the single grading page.
2018-12-19 10:10:23 +08:00
Tim Hunt
939218c2b6 MDL-46783 permissions: let some moodle/ caps be overriden in all mods
The capabilities changed ('contextlevel' => CONTEXT_COURSE changed to
'contextlevel' => CONTEXT_MODULE) are:

* moodle/site:accessallgroups
* moodle/site:viewfullnames
* moodle/site:trustcontent
* moodle/site:viewuseridentity

This list came from reviewing the _get_extra_capabilities functions in
all core activities. They were all somewhat inconsistent, but I think it
makes sense that these capabilities are consistently overridable in all
activities. E.g. moodle/site:accessallgroups affects conditional
availability even if there is no other user of groups, and
moodle/site:viewuseridentity and moodle/site:viewfullnames affect the
logs report, if nothing else.

As a result of this, several _get_extra_capabilities functions are no
longer needed, and all the rest have been simplified.
2018-12-05 16:44:25 +00:00
Eloy Lafuente (stronk7)
bd5fdcfccd MDL-63422 general: review core loop / switch / case / continue
This commit reviews all continue uses in core happening within a
loop / switch / case hierarchy. This does not cover:

- Changes to libraries. Will be handled in another issue / commit.
- Uses out from loops, will be reviewed by other commit.

The policy followed has been:
- When possible, take rid of the continue.
- When clearly the intention was to jump to next element in loop
  change to continue 2
- When it was not clear, keep old behavior switching to break, no
  matter how weird the behavior may be.
2018-10-31 00:17:59 +01:00
Neill Magill
bbf1fde412 MDL-62944 activities: Activities should not require capability
Activities should not require the user manipulating them to have
calendar capabilities for their events to be added to the Moodle
calendar
2018-08-31 10:15:37 +01:00
Eloy Lafuente (stronk7)
521ebb76b0 Merge branch 'MDL-61870-master' of git://github.com/damyon/moodle 2018-08-07 23:48:31 +02:00
Zig Tan
8ea4df50c9 MDL-61870 mod_assign: Fix/clean up imported group override duedates
Applying patch supplied from Damyon Wiese to address the root-cause
of this issue in the backup/restore logic.
2018-08-02 12:55:13 +08:00
Zig Tan
6bcc6f877a MDL-61870 mod_assign: Fix/clean up imported group override duedates
- Prevent group override duedate events from being imported when groups are excluded
- Clean up any existing group override duedate events when editing assignment in upgradelib.php
- Updated lib.php unit tests
2018-08-02 12:55:12 +08:00
Shamim Rezaie
fda4374a67 MDL-58768 mod_assign: Added userid param to calendar callbacks
The mod_assign_core_calendar_is_event_visible and mod_assign_core_calendar_provide_event_action
functions now accept a new parameter ($userid) so they are not always dependet to the logged in user.
2018-07-28 07:51:33 +10:00
Ryan Wyllie
6688ae2ba2 MDL-60062 calendar: prevent drag and drop of override events 2017-11-07 05:47:18 +00:00
Ryan Wyllie
478b1d194f MDL-60062 calendar: remove validate_event_timestart callback 2017-11-07 01:25:33 +00:00
Ryan Wyllie
dbe537fb50 MDL-60058 assign: add missing locallib require_once calls 2017-10-17 03:04:47 +00:00