【问题标题】:Set Parse "reset password" message content设置解析“重置密码”消息内容
【发布时间】:2014-07-10 08:13:31
【问题描述】:

有人知道在重置密码时是否可以指定 Parse 发送给用户的消息内容(PFUser requestPasswordResetForEmailInBackground])?

以下是创建用户并要求重置密码的伪代码

// create user
PFUser* pUser   =   [ [ PFUser alloc ] init ];

pUser.username  =   @"Batman";
pUser.password  =   @"Gr34tT0ys";
pUser.email     =   @"batman@arkham.com";

[ pUser signUpInBackgroundWithBlock: ^(BOOL succeeded, NSError *error) {
    ...
} ];

// ask for password reset
[ PFUser requestPasswordResetForEmailInBackground: @"batman@arkham.com" block:^(BOOL succeeded, NSError *error) {
    ...;
} ];

实际消息是:

嗨,

您请求重置 YOUR_APP_NAME 的密码。

点击这里重置:

A_RESET_LINK

至少,我希望将其内容本地化。

理想情况下,我想向 Parse 提供电子邮件文本

提前致谢

【问题讨论】:

    标签: parse-platform


    【解决方案1】:

    为此,您需要实现自己的功能。您可以使用云函数,它使用 Mandrill/Mailgun 发送电子邮件,将它们定向到 Parse Hosting 上的某个页面,其中包含一些令牌,该令牌验证并允许更改密码。提供的重置密码功能目前不支持修改。

    https://parse.com/docs/cloud_code_guide

    https://parse.com/docs/cloud_modules_guide#mailgun https://parse.com/docs/cloud_modules_guide#mandrill

    https://parse.com/docs/hosting_guide#hosting

    【讨论】:

    • 感谢您的快速答复@Fosco。
    • @hsarret 您最终对此有什么了解吗?
    【解决方案2】:

    您可以在 Parse.com 仪表板中为您的应用更改电子邮件模板。

    转到您的应用仪表板并点击:

    • 设置(在顶部选项卡中)
    • 电子邮件设置(左侧导航)

    您现在可以设置电子邮件模板。

    很遗憾,我认为您无法将这些本地化!

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-05-21
      • 1970-01-01
      • 1970-01-01
      • 2019-07-04
      • 2018-06-04
      相关资源
      最近更新 更多