Hello,

How to know ID wizard when execute it?

Example:
In top menu client, we have a diferents Wizard actions:

- Wizard 1
- Wizard 2
- Wizard 3
- ....

This wizards call same wizard class (in this example, call "example").

In default method, we need know what ID wizard execute this action. If is
"wizard 1", "wizard 2", ....

I review Transaction().context and it doesn't succesfully my search. Only
we have active_id or active_ids.

How to know ID wizard?

class Example(Wizard):
    "Example"
    _name = "example"

    start = StateView('example.start',
        'example_start', [
            Button('Cancel', 'end', 'tryton-cancel'),
            Button('Send', 'send', 'tryton-ok', default=True),
            ])
    export = StateTransition()
    result = StateView('example.result',
        'example_result', [
            Button('Close', 'end', 'tryton-close'),
            ])

    def default_start(self, session, fields):
        default = {}

        #Here we need know ID wizard that execute it

        return default

Example()


thanks

--
Raimon

-- 
tryton-dev@googlegroups.com mailing list

Reply via email to