Odoo Help

Welcome!

This community 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.

1

How to open wizard from workflow activity

By
fussions
on 7/18/14, 7:41 AM 1,020 views

I'm trying to open a wizard from workflow activity. As far as I know it should be done through server action. Below are the snippets of my code.

1. Workflow activity, refering server action:

<record id="act_pending" model="workflow.activity">
            <field name="wkf_id" ref="subscription_workflow"/>
            <field name="flow_start">True</field>
            <field name="action_id" ref="invokeSubscription_clientAction" />
            <field name="name">Pending</field>            
       </record>

2. Server action definition:

<record model="ir.actions.server" id="invokeSubscription_clientAction" >
            <field name="name">Subscriptions Invocation Server Action</field>
            <field name="model_id" ref="model_subscription_wizard" />            
            <field name="type">ir.actions.server</field>    
            <field name='state'>client_action</field>        
            <field name="action_id" ref="ask4subscription" />           
        </record>

3. Finally client action invoked by server action:

<record model="ir.actions.act_window" id="ask4subscription">
               <field name="name">Subscriptions Invocation Window</field>
            <field name="res_model">subscription.wizard</field>
            <field name="type">ir.actions.act_window</field>
            <field name="view_type">form</field>
            <field name="view_mode">tree,form</field>
            <field name="view_id" ref="proposeSubscriptionForm"/>
            <field name="target">new</field>
        </record>

 

My workflow is run as a subworkflow of invoice workflow. It is instantiated and is active, but my wizard window won't open. Am I missing something?

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 7/18/14, 7:41 AM
Seen: 1020 times
Last updated: 6/12/15, 1:13 AM