add_action( 'admin_footer-post-new.php', 'firmasite_mediapanel_lock_uploaded' );
add_action( 'admin_footer-post.php', 'firmasite_mediapanel_lock_uploaded' );
function firmasite_mediapanel_lock_uploaded() { ?>
<script type="text/javascript">
jQuery(document).on("DOMNodeInserted", function(){
// Lock uploads to "Uploaded to this post"
jQuery('select.attachment-filters [value="uploaded"]').attr( 'selected', true ).parent().trigger('change');
});
</script>
<?php }
Just place that into your child-theme's functions.php file :)