Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

block_attendance: Incorrect user attendance data being displayed #11

Closed
kiratskitizing opened this issue Feb 5, 2017 · 3 comments
Closed

Comments

@kiratskitizing
Copy link

kiratskitizing commented Feb 5, 2017

Hi Dan,

With the recent upgrade of mod_attendance, the function construct_full_user_stat_html_table has been modified (mod/attendance/renderhelpers.php). This is now the current function definition:
function construct_full_user_stat_html_table($attendance, $user) {

However, it is being called this way (blocks/attendance/block_attendance.php):
$this->content->text .= construct_full_user_stat_html_table($attinst, $COURSE, $USER, $cm);

Which displays incorrect data due to $COURSE being passed instead of $USER.

@kiratskitizing
Copy link
Author

kiratskitizing commented Feb 5, 2017

This is my fix for this issue.

-   $this->content->text .= construct_full_user_stat_html_table($attinst, $COURSE, $USER, $cm);
+  $this->content->text .= construct_full_user_stat_html_table($attinst, $USER);

I am not sure if I should create a Moodle Tracker item for this so as it gets integrated upstream.

Please advise.

@danmarsden
Copy link
Owner

thanks for the report - I've pushed a fix here, will tidy up the branches a bit and release it in the plugins db.

The Moodle Tracker is not used for tracking bugs with the attendance plugin. We use the github issue tracker here.

danmarsden added a commit that referenced this issue Feb 6, 2017
we probably shouldn't have done this in the main mod.
danmarsden added a commit that referenced this issue Feb 6, 2017
@kiratskitizing
Copy link
Author

Thanks for that Dan. Have a great day.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants