Py学习  »  Milan Velebit  »  全部回复
回复总数  1
5 年前
回复了 Milan Velebit 创建的主题 » nodejs中的双MongoDB请求

.get

app.get('/buildings', async (req, res) => {
    let res_obj = {}
    // Then execute your queries, and place the results inside this res_obj 
    ... queries and their handling ...
    res.send(res_obj);

{
    first_query_res: {
        ... 
    },
    second_query_res: {
        ... 
    }
}