Sunday, 9 April 2017

node js pass variable from loop

hi I can't pass a variable from another loop into other loop that works for mongodb

how can I do that?

regards

 for (i = 0; i < vLojas.length; i++){
           vLojaAtual= vLojas[i];
           console.log('atual'+vLojaAtual); 

console.log(vLojas);
var test=  vDevicec;
var send = false;
                db.collection('loja').find({idLoja: vLojaAtual}).toArray(function(err, resLoja) {   
//console.log('inspoectdddddddloopdsdssdaend    ' + util.inspect(test, false, null)); 



via saddd

No comments:

Post a Comment