21 lines
546 B
JavaScript
21 lines
546 B
JavaScript
function createRoute(){
|
|
|
|
$.ajax({
|
|
headers: { "X-CSRFToken": $('input[name=csrfmiddlewaretoken]').val() },
|
|
url: '/ru/user_account/new_route_view/',
|
|
type: "POST",
|
|
// async: true,
|
|
cache: false,
|
|
processData: false,
|
|
contentType: false,
|
|
// enctype: 'json',
|
|
// data: {},
|
|
success: function(data){
|
|
console.log('data received')
|
|
// location.href = '/profile'
|
|
document.querySelector(".profile").innerHTML = data.html
|
|
}
|
|
});
|
|
}
|
|
|