Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def on_enter(self):
- # getting data from real-time database
- self.firebase = firebase.FirebaseApplication('https://lexconnectionsapp-default-rtdb.firebaseio.com/', None)
- print('connecting........')
- self.result = self.firebase.get('lexconnectionsapp-default-rtdb/products', None)
- print((self.result))
- # data i fetched from my database
- self.data = self.result
- products = [item for item in self.data.values()] # ignore primary key, get the inner dicts
- for product in products:
- sc = ShowCard(**product) # same as Showcard(description=product['description'],...)
- self.ids.show_card.add_widget(sc)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement