gpt4 book ai didi

symfony - 更改密码在 FOS 用户 bundle + Sonata 用户 bundle +sonata 管理员 bundle 中不起作用

转载 作者:行者123 更新时间:2023-12-02 21:04:21 25 4
gpt4 key购买 nike

我可以使用 Sonata User Bundle 将 FOS 包集成到 sonata Admin 包中。我的登录功能正常。现在我想添加 FOSUserBundle 中的更改密码等功能到 sonata Admin Bundle

我可以使用访问 FOS User Bundle 的配置文件功能

localhost/myproject/web/app_dev.php/profile

但更改密码也是一样

localhost/myproject/web/app_dev.php/change-password 无法访问。

我想将它与 SonataAdminBundle 集成

localhost/myproject/web/app_dev.php/admin/change-password

你能建议我哪里应该改变或者哪里出错了吗?

在我的路由中,我有

fos_user_security:
resource: "@FOSUserBundle/Resources/config/routing/security.xml"

fos_user_profile:
resource: "@FOSUserBundle/Resources/config/routing/profile.xml"
prefix: /profile

fos_user_register:
resource: "@FOSUserBundle/Resources/config/routing/registration.xml"
prefix: /register

fos_user_resetting:
resource: "@FOSUserBundle/Resources/config/routing/resetting.xml"
prefix: /resetting

fos_user_change_password:
resource: "@FOSUserBundle/Resources/config/routing/change_password.xml"
prefix: /change-password

最佳答案

您是否设置了更改密码的路径?

fos_user_change_password:
resource: "@FOSUserBundle/Resources/config/routing/change_password.xml"
prefix: /profile

关于symfony - 更改密码在 FOS 用户 bundle + Sonata 用户 bundle +sonata 管理员 bundle 中不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12559606/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com