$('#login').click(function() {
console.log("login");
var lg_user_id=$('#user_id').val();
var lg_password=$('#password').val();
console.log(lg_user_id);
console.log(lg_password);
$.ajax({
type: "POST",
url: "http://104.199.167.228/api/v1/token/get",
data: JSON.stringify({user_id:lg_user_id,password:lg_password}),
success: function(resultData) {
console.log(resultData.token);
localStorage.setItem('token', resultData.token);
},
contentType: "application/json"
});
var forward = url('?');
console.log(forward);
window.location = forward.target;
});