Odoo中文社区可以通过以下三个域名访问:shine-it.net , odoocn.org,odoo.net.cn

原论坛用户的基本信息和发帖这里都予以保留,请注意:原论坛用户无需重新注册新用户,但是您的密码需要重置

开发人员可以登录gitter讨论组: http://gitter.im/odoo-china/Talk, 需要github账号

如果您登录系统碰到问题,请在微信公众号留言:

Odoo中重置密码BUG



  • 开启重置密码功能后提示'NoneType' object has no attribute 'get' ,调试代码发现

    def action_reset_password(self, cr, uid, ids, context=None):<br />&nbsp; &nbsp; &nbsp; &nbsp; &quot;&quot;&quot; create signup token for each user, and send their signup url by email &quot;&quot;&quot;<br />&nbsp; &nbsp; &nbsp; &nbsp; # prepare reset password signup<br />&nbsp; &nbsp; &nbsp; &nbsp; create_mode = bool(context.get(&#039;create_user&#039;))<br />&nbsp; &nbsp; &nbsp; &nbsp; res_partner = self.pool.get(&#039;res.partner&#039;)<br />&nbsp; &nbsp; &nbsp; &nbsp; partner_ids = [user.partner_id.id for user in self.browse(cr, uid, ids, context)]<br /><br />&nbsp; &nbsp; &nbsp; &nbsp; # no time limit for initial invitation, only for reset password<br />&nbsp; &nbsp; &nbsp; &nbsp; expiration = False if create_mode else now(days=+1)<br /><br />&nbsp; &nbsp; &nbsp; &nbsp; res_partner.signup_prepare(cr, uid, partner_ids, signup_type=&quot;reset&quot;, expiration=expiration, context=context)<br /><br />&nbsp; &nbsp; &nbsp; &nbsp; if not context:<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; context = {}
    


    context为空造成的,把这个代码放前面就可以了。

    if not context:<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; context = {}