Following JS file can be included, that can disable
- Mouse Right Click
- Opening of developer console in Browser
- Disable Cut / Copy / Paste
Following is the code
You just need to unzip this. This will show an amd folder. this contains the compiled file as well.
put that folder into plugin
and call this js by putting this php code on any page
// remember : local_poc means you are writing local plugin name as poc, so you will put amd folder in poc directory
//if you are writing block then,
//$PAGE->requires->js_call_amd('block_poc/disabler', 'init');
$PAGE->requires->js_call_amd('local_poc/disabler', 'init');
for more about javascript in moodle , read following