解析 - 为未来用户使用 ACL [英] Parse - using ACL for future users

查看:20
本文介绍了解析 - 为未来用户使用 ACL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我的基于解析的应用程序中,默认情况下,每个用户都会有一个他私有的笔记列表.用户将能够邀请其他用户(通过他们的电子邮件地址识别)查看笔记.

On my parse based application, each user will have a list of notes that are private to him by default. The user will be able to invite other users (identified by their email address) to view the notes.

我想为此使用 ACL,但想知道如果受邀用户尚未注册为 Parse 受邀用户,我该怎么办.在这种情况下,笔记创建者用户无法将他添加到笔记的 ACL 中,因为还没有 ParseUser 对象.

I want to use ACL for that, but was wondering what should I do if the invited user is not registered yet as a Parse user on invitation. In that case, the notes creator user cannot add him to the note's ACL since there is no ParseUser object yet.

此类邀请的最佳解决方案是什么?

What is the best solution for this type of invitation?

我可以为此使用 ACL 还是必须自己管理访问权限?

Can I use ACL for this or do I have to manage the access myself?

推荐答案

如果您熟悉称为 Cloud Code 的 Parse 技术,那么您应该查看此 https://gist.github.com/mikevansnell/5140654

If you're familiar with Parse technology called Cloud Code then you should check this https://gist.github.com/mikevansnell/5140654

此代码根据传递给函数的电子邮件创建未来用户,并为其分配一些随机密码.然后邀请电子邮件将发送到通过的电子邮件,其中包含所有信息,包括密码.当受邀用户进入应用程序时,只需填写登录名

This code creates future user from the email passed to the function and asign it with some random password. And then an invitation email is send to the passed email with all the info, including password. And when the invited user goes to the app just fill the logi

这篇关于解析 - 为未来用户使用 ACL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆