This commit is contained in:
Huong Nguyen
2024-08-20 09:30:44 +07:00
395 changed files with 787 additions and 785 deletions
+1 -1
View File
@@ -93,7 +93,7 @@ trait form_trait {
* @throws \coding_exception If the form is not moodleform_mod and $modname is null.
*/
protected function add_completion_elements(
string $modname = null,
?string $modname = null,
bool $supportviews = false,
bool $supportgrades = false,
bool $rating = false,
+2 -2
View File
@@ -232,7 +232,7 @@ class provider implements
* @param int $courseid The course id. Provide this if you want course completion and activity completion deleted.
* @param int $cmid The course module id. Provide this if you only want activity completion deleted.
*/
public static function delete_completion(\stdClass $user = null, int $courseid = null, int $cmid = null) {
public static function delete_completion(?\stdClass $user = null, ?int $courseid = null, ?int $cmid = null) {
global $DB;
if (isset($cmid)) {
@@ -285,7 +285,7 @@ class provider implements
* @param int $courseid The course id. Provide this if you want course completion and activity completion deleted.
* @param int $cmid The course module id. Provide this if you only want activity completion deleted.
*/
public static function delete_completion_by_approved_userlist(approved_userlist $userlist, int $courseid = null, int $cmid = null) {
public static function delete_completion_by_approved_userlist(approved_userlist $userlist, ?int $courseid = null, ?int $cmid = null) {
global $DB;
$userids = $userlist->get_userids();