【发布时间】:2019-07-02 06:56:28
【问题描述】:
示例:如果我的触发器在 (Users/{userId}/Billings/{billingId}) 等路径上是 onWrite,我如何访问用户文档数据
functions.firestore.document('Users/{userId}/Billings/{billingId}')
.onWrite((change, context) => {
});
我知道我可以通过 context.params 和通配符 userId 和 billingId 访问帐单数据。
我将如何访问触发此事件的用户文档数据?
【问题讨论】:
标签: javascript firebase google-cloud-firestore google-cloud-functions