A question about async/await asynchronous requests?

inside the asyncData method of the nuxt.js framework

 let [
        FindInstitutionsDetailed,
        EnterpriseHot,
    ]
    = await Promise.all([
                P.FindInstitutionsDetailed({"id":context.route.query.id+""}),
                P.EnterpriseHot()
            ])
            return {
                ***FindInstitutionsDetailed***: FindInstitutionsDetailed.data,
                EnterpriseHot: EnterpriseHot.data,
            }

as shown in the figure above, it is always written like this. Promise.all requests all APIs concurrently before the page is rendered. There"s no problem with that.

however, there is now an interface that needs to get userId as a parameter from the FindInstitutionsDetailed interface.

would you like to ask how to write it? You cannot access this in nuxt.
or after Promise.all (...) . Then ?



async function f(){
    var result = await new Promise(function(resolve){
        setTimeout(function(){
            resolve('hello')
        })
    })
    await new Promise(function(resolve){
        resolve(result+' world')
    }).then(console.log);
}
f()
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b34cd4-40f83.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b34cd4-40f83.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?