Vue uses v-for loops, but the looped data is pieced together by data returned by multiple interfaces. How do you do that?

clipboard.png
if written in this way, an error will be reported because of asynchronism, and an error will be reported if you can"t get the value of totalList.
such as:

channelInfo=[{id:1,name:tom},{id:2,name:lili}]
totalList=  [{id:11,price:10},{id:22,price:20}]

these things

returned by two interfaces
Mar.15,2021

you can use promise.all to wait for two interfaces to return at the same time before assigning values to them, first assigning totalList and then assigning channelInfo to ensure that you get the value of totalList

Menu