title: How to add a button on a tree inside a form in Odoo 10?
body: <p>I want to add a button to the order_line tree in the sale form, I added like this:</p>
  
  <pre><code>&lt;xpath expr="/form/sheet/notebook/page[1]/field[@name='order_line']/tree/field[@name='price_subtotal']" position="after"&gt;
      &lt;button name="%{action_view_wizard}d" string="" type="action" icon="fa-archive" attrs="{'invisible':[('product_id','=', False)]}"/&gt;
  &lt;/xpath&gt;
  </code></pre>
  
  <p>And the wizard is defined</p>
  
  <pre><code>&lt;record id="check_stock" model="ir.ui.view"&gt;
      &lt;field name="name"&gt;sale_warehouse.check_stock_wizard&lt;/field&gt;
      &lt;field name="model"&gt;sale_warehouse.check_stock_wizard&lt;/field&gt;
      &lt;field name="arch" type="xml"&gt;
          &lt;form string="Stock by warehouse"&gt;
              &lt;group col="1"&gt;
                  &lt;field name="stock" nolabel="1"/&gt;
              &lt;/group&gt;
              &lt;footer&gt;
                  &lt;button string="Close" class="btn-default" special="cancel" /&gt;
              &lt;/footer&gt;
          &lt;/form&gt;
      &lt;/field&gt;
  &lt;/record&gt;
  
  &lt;record id="action_view_wizard" model="ir.actions.act_window"&gt;
      &lt;field name="name"&gt;Stock by warehouse&lt;/field&gt;
      &lt;field name="type"&gt;ir.actions.act_window&lt;/field&gt;
      &lt;field name="res_model"&gt;sale_warehouse.check_stock_wizard&lt;/field&gt;
      &lt;field name="view_type"&gt;form&lt;/field&gt;
      &lt;field name="view_mode"&gt;form&lt;/field&gt;
      &lt;field name="view_id" ref="check_stock"/&gt;
      &lt;field name="target"&gt;new&lt;/field&gt;
  &lt;/record&gt;
  </code></pre>
  
  <p>The button is added ok but its load as disable and so when clicked the wizard is no call, if I take the button out the tree the wizard is called ok, but I need to be call from the order_line becouse I need to pass the context with product_id of the line to get the stock in each warehouse.</p>
  
  <p>I'm using odoo10.
  What I'm doing wrong?</p>