I think issue is with the AJAX function
$.ajax({
type:"POST",
url: 'Sales/GetPrice',
contentType: "application/json; charset=utf-8",
data: {"ProductId": pid },
dataType: "json",
success: function (data)
{
alert("Success!");
},
failure: function (response) {
alert("Fail!");
}
});
I have corrected
data: {"ProductId": pid }
and
dataType: "json"
If still issue persist please check in browsers developer console and share the detail.