问题
I have two collections namely CURRENCY_PAIR and CURRENCY_PAIR_LIMIT. The CURRENCY_PAIR collection has the following fields in each document:
- CurrencyPair_Name
- CurrencyPair_id
- Currency_AskPrice
- Currency_BidPrice
and theCURRENCY_PAIR_LIMIT collection contain the following fields in each document:
- Limit_id
- Limit_Buy_Price_Threshhold
- Limit_Sell_Price_Threshhold
- Limit_Currency_Pair_Id (references to the Currencypair_Id in the
CURRENCY_PAIRcollection)
I wanted to map each CurrencyPair_Name to its respective Limit_Buy_Price_Threshhold and Limit_Sell_Price_Threshhold then display them in react but i'm stuck. How can i get around this.
来源:https://stackoverflow.com/questions/64953805/how-to-fetch-data-from-two-firestore-collection-merge-and-display-it