vendredi 7 avril 2017

Save on FCM database message's timestamp

So I'm using the follow steps from the tutorial in order to understant fcm and I'm wondering if there is anyway to save the timestamp from the send/recieved messages?

Google FCM Tutorial Page 8

 this.messagesRef.push({
      name: currentUser.displayName,
      text: this.messageInput.value,
      photoUrl: currentUser.photoURL || '/images/profile_placeholder.png'
    })

As you can see on this sample code I push name, text and photoUrl but I want also the time.




Aucun commentaire:

Enregistrer un commentaire