If you can't hack the code you can try placing the page in an iframe and add to the grade report the desired behavior from the parent frame.
Gradebook
Is there a way to personalize the Moodle Gradebook?
This discussion has been locked so you can no longer reply to it.