Your 'request' variable having null value file catching in controller from ajax request, you may check it using break point. Do it like done below.
<script type="text/javascript">
$.ajax({
type: 'Post',
url: '/Consultas/MostrarTipusPersona',
dataType: 'json',
contentType: 'application/json',
data: {ProjecteId: $('#ProjecteId').val()},
success: function (data) {
console.log('sample', data);
},
error: function () {
}
});
});
</script>