1
I have a View called Invoice, inside a controller named Order. If I take my jquery and leave url: ''
, it already mounts in the browser that:
locahost:porta/dominio/order/FaturarPara
I’ll go to jquery and do it
url: /Order/GetDados
, there in the Chrome Network I pick this up
locahost:porta/dominio/order/FaturarPara/Order/GetDados
Any configuration I make, I can’t mount the url correct. This is my jquery
$(document).ready(function () {
$('#faturarParaDrop').change(function () {
var $div = $('#modalPartial'); //exibir a modal
var idcustomer = $(this).val(); //valor do id da dropdownlist
$.ajax({
url: '/Order/GetDados/' + idcustomer,
type: 'GET',
success: function (dados) {
alert(JSON.stringify(dados));
},
error: function (erro) {
}
})
});
});
if I take this url and play in the browser, log in to Jsonresult
locahost:porta/dominio/Order/GetDados/1
How do I access my Jsonresult in the controller?