I’m trying to pass options hash in a iron router server side like this:
this.response.writeHead(302, {“Location”: “/results/” + busq.id_investigador}, {id_investigador: busq.id_investigador});
Is possible this?
The idea is that when i run the ‘sales’ path this redirect me to other path (results) but with a option hash like a dictionary.
And the results path set like /results/id_investigador --> ex: 6WCoQ6YAAAAJ
It is undserstood?
Router.route('/sales', function(){
.
.
.
.
var busq = Busquedas.findOne({id_investigador : Busquedas.findOne({sec : Busquedas.find().count()}).id_investigador});
this.response.writeHead(302, {"Location": "/results/" + busq.id_investigador}, {id_investigador: busq.id_investigador});
this.response.end();
}, {where : "server"});