Tryton - Issues



Title Buttons list of wizard.State is not copied by deepcopy
Priority feature Status chatting
Superseder Nosy List resteve
Type Components trytond
Assigned To Keywords easy

Created on 2015-09-02.15:19:10 by resteve, last changed by ced.

msg22266 (view) Author: [hidden] (resteve) Date: 2015-09-02.15:19:08
I have a module add new class wizard: 

class TestClass(Wizard): 
    __name__ = 'test.class' 
    start = StateTransition() 
    picking = StateView('test.class.view', 
    tasktodo = StateTransition() 
    result = StateView('test.class.result', 
        'module.test_class_result', [ 
            Button('Done', 'end', 'tryton-ok'), 

I have three modules inherit TestClass to do more features. 

One module, add new btn in result view. 

    def __setup__(cls): 
        super(TestClass, cls).__setup__() 
        # add new button: Save Photo 
            Button('Save Photo', 'photo', 'tryton-go-next', True)) 

When I installed three modules inherit TestClass , I detect this new button (Save Photo), are duplicated (three modules = three buttons = three registration class).

It looks like the buttons list of wizard.State is not copied by deepcopy:

( Start feedback in!topic/tryton/6iSP5hm0oAM )
Date User Action Args
2015-11-05 20:22:21cedsetkeyword: + easy
2015-09-02 15:19:10restevecreate

Showing 10 items. Show all history (warning: this could be VERY long)