-
Bug
-
Resolution: Fixed
-
Minor
-
4.1
-
MOODLE_401_STABLE
-
MOODLE_401_STABLE
-
MDL-76073-master -
This came up while working on MDL-75358
Several display callbacks in the 'badge' entity of report builder assume that badge is always present and do not have nullable arguments.
To reproduce it you can use the datasource "user left join badge_issues left join badges"
- Put this file https://gist.github.com/marinaglancy/4d73664dc907a56db33cd95e0811b82a
in badges/classes/reportbuilder/datasource/userbadges.php - Login as admin, purge caches
- Create a badge (Site administration>Badges>Manage badges) and assign it to at least one user. Make sure you have users who do not have badges too
- Go to Reports (in user picture menu)
- Create a new report from the "User badges" datasource
- Add all fields from the "Badge" entity - make sure the badges info is displayed for users who have badges and nothing is displayed for users without badges
Prior to the patch you will not be able to add all columns, there are a lot of exceptions coming from callbacks
- Discovered while testing
-
MDL-75358 Nulls are displayed as "0" in the report builder numeric columns
- Closed