Non-core contributed modules

Patch to put current location (from mrbs) onto users' profiles

Details

  • Type: New Feature New Feature
  • Status: Open Open
  • Priority: Minor Minor
  • Resolution: Unresolved
  • Affects Version/s: 1.9.4
  • Fix Version/s: None
  • Component/s: Block: Mrbs
  • Labels:
    None
  • Affected Branches:
    MOODLE_19_STABLE

Description

As mentioned previously, here is a patch to display 'current location' on users profiles. It only displays to users with block/mrbs:viewalltt and links to the user's timetable, so therefore requires CONTRIB-1200.

current_location.php goes in blocks/mrbs and then you just need an include line in user/view.php around line 224 onwards (depending on where in the list you want the detail)

Issue Links

Activity

Hide
Mike Worth added a comment -

Is there any way of packaging this other than an optional additional patch in the tracker? It is a feature that I have found useful, but does need one line inserted into core.

Show
Mike Worth added a comment - Is there any way of packaging this other than an optional additional patch in the tracker? It is a feature that I have found useful, but does need one line inserted into core.
Hide
Anthony Borrow added a comment -

Mike - As I am attempting to race through issues in the tracker, I am not sure I follow your question here. If we are using a capability check why not just put this in as part of MRBS block. I have no problems building it up to do what you think is best. Let me know what you need from me but know that I trust your judgment on this. Peace - Anthony

Show
Anthony Borrow added a comment - Mike - As I am attempting to race through issues in the tracker, I am not sure I follow your question here. If we are using a capability check why not just put this in as part of MRBS block. I have no problems building it up to do what you think is best. Let me know what you need from me but know that I trust your judgment on this. Peace - Anthony
Hide
Mike Worth added a comment -

This can't be packaged with mrbs as it requires current_location.php (which can go in mrbs) to be included in moodle/user/view.php around line 224

It puts the room the user is in onto their main moodle profile as 'current location' (assuming the user viewing the profile is allowed to view their timetable)

It can't be packaged strait into mrbs for that reason, and can't go straight into core because not everyone has mrbs; could an install function for mrbs go and modify the file and a corresponding uninstall function change it back if/when mrbs is uninstalled? For security reasons a lot of the time php does not have permission to modify these files, what would happen in these cases? Is there a better way to do it?

Thanks,
Mike

Show
Mike Worth added a comment - This can't be packaged with mrbs as it requires current_location.php (which can go in mrbs) to be included in moodle/user/view.php around line 224 It puts the room the user is in onto their main moodle profile as 'current location' (assuming the user viewing the profile is allowed to view their timetable) It can't be packaged strait into mrbs for that reason, and can't go straight into core because not everyone has mrbs; could an install function for mrbs go and modify the file and a corresponding uninstall function change it back if/when mrbs is uninstalled? For security reasons a lot of the time php does not have permission to modify these files, what would happen in these cases? Is there a better way to do it? Thanks, Mike
Hide
Anthony Borrow added a comment -

Mike - Sorry for the delay in responding as you can tell I am back in to catch up mode. In any case, I would recommend that this be treated as a patch. I would not automate the installation. It is better to require site admins to apply a patch and then if they wish to uninstall they can go back to managing the modified file however they wish (download from zip or CVS). Because of the differences in how folks manage and secure their systems I do not think it is feasible to have an automated type install. Let me know if you have any questions. Peace - Anthony

Show
Anthony Borrow added a comment - Mike - Sorry for the delay in responding as you can tell I am back in to catch up mode. In any case, I would recommend that this be treated as a patch. I would not automate the installation. It is better to require site admins to apply a patch and then if they wish to uninstall they can go back to managing the modified file however they wish (download from zip or CVS). Because of the differences in how folks manage and secure their systems I do not think it is feasible to have an automated type install. Let me know if you have any questions. Peace - Anthony

People

Vote (0)
Watch (1)

Dates

  • Created:
    Updated: