Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 
  • How to use widget parents and Children in OpenERP/Odoo ?

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 486
    Comment on it

    If you want to widget parents and Children in OpenERP(Odoo) follow the below mentioned code and paste it in your wizard .js file:

    local.HomePage = instance.Widget.extend({
        start: function() {
            var greeting = new local.GreetingsWidget(this);
            greeting.appendTo(this.$el);
            console.log(this.getChildren()[0].$el);
            // will print "div.oe_petstore_greetings" in the console
        },
    });

    Note- The first argument is this, which in that case was a Home-Page instance. This tells the widget being created which other widget is its parent.

 0 Comment(s)

Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: