Odoo Help

2 Answers

Axel Mendoza

--Axel Mendoza--
| 7 8 8
Camaguey, Cuba
--Axel Mendoza--

DevOps - Full stack - Software Architect - Developer - Technology Integrator

I could help you to develop anything and solve complex problems based on technologies, integrations and tricky stuffs mostly in Python with OpenERP/Odoo, Zato, Django and many others frameworks programming languages and technologies.

I offers consulting services to anyone with an unanswered questions or needs for customizations. Think about it, maybe it's better to have an expert to solve your issues and projects than having a full-time employee trying to understand what to do and how

Reach me at aekroft@gmail.com

Axel Mendoza
10/8/15, 6:03 PM

You could vote it then at that link. :D

You should use a button of type object to return the action dict with the user id as the active_id in the context and also the res_id field of the action with the same value too. Like this:

    def open_user_form(self, cr, uid, ids, context=None):
return {
'type': 'ir.actions.act_window',
'name': 'Configure your Company',
'res_model': 'res.users',
'res_id': user_id,
'context': {'active_id': user_id},
'view_mode': 'form',
Lucas Huber
10/9/15, 5:50 AM

I did found somewhare a solution within the xml file, which more or less is doing the same. It works, but the view that I have created is not used. Instead a view from base that shows only the photo and some basic parameter will be used. Must be a typo in view_id.

        <record id="act_membership_my_prefs" model="ir.actions.server">

            <field name="name">My Preferences</field>
            <field name="model_id" ref="base.model_res_users"/>
            <field name="state">code</field>
            <field name="code">
                action = {
                    'type': 'ir.actions.act_window',
                    'name': 'My Preferences',
                    'view_mode': 'form',
                    'view_type': 'form',
                    'res_model': 'res.users',
                    'nodestroy': 'true',
                    'res_id': uid,
                    'views': [(False, 'form')],
                    'view_id': 'ref="membership_my_prefs_view"',
Ask a Question
Keep Informed
2 follower(s)
About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now