I need to redirect to a page that i get from my DB, but, i need to do this in my controller.
Is there any way to redirect to another page using some angular function?
Because $locate
and window.location
just put the link after my website base url.
Here an example of what it is doing now:
http://ip/cliente_ecommerce_v2/em_desenvolvimento/front/bernardo/%EF%BB%BF%EF%BB%BFhttps://sandbox.pagseguro.uol.com.br/v2/checkout/payment.html?code=nope
The code:
Conecta('get','getFinalizaCompra', Cookies.get("hash_cliente")).then(function(valor) {
console.log(valor);
window.location.href = valor;
});