title: TypeError: 'tuple' object is not callable - Odoo v8
body: <p>I have this button action, to relate a document to an invoice on Odoo v8.</p>
  
  <pre><code>@api.multi
  def button_generate_wh_doc(self):
      context = self._context
      partner = self.env['res.partner']
      res = {}
      for inv in self:
          view_id = self.env['ir.ui.view'].search([
              ('name', '=', 'account.invoice.wh.iva.customer')])
          context = self.env.context.copy()
          context.update({'domain':[(
              ('invoice_id','=',inv.id)
              ('type','=',inv.type)
              ('default_partner_id','=', partner._find_accounting_partner(
                  inv.partner_id).id)
              ('default_name' ,'=', inv.name or inv.number)
              ('view_id' ,'=', view_id))]})
      res = {
              'name': _('Withholding vat customer'),
              'type': 'ir.actions.act_window',
              'res_model': 'account.wh.iva',
              'view_type': 'form',
              'view_id': False,
              'view_mode': 'form',
              'nodestroy': True,
              'target': 'current',
              'domain': "[('type', '=', '" + inv.type + "')]",
              'context': context
          }
      return res
  </code></pre>
  
  <p>But every time I call this action from button, it throws me this:</p>
  
  <pre><code>Odoo Server Error
  
  Traceback (most recent call last):
  File "/home/kristian/odoov8/odoo-8.0-20161017/openerp/http.py", line 544, in _handle_exception
  return super(JsonRequest, self)._handle_exception(exception)
  File "/home/kristian/odoov8/odoo-8.0-20161017/openerp/http.py", line 581, in dispatch
  result = self._call_function(**self.params)
  File "/home/kristian/odoov8/odoo-8.0-20161017/openerp/http.py", line 317, in _call_function
  return checked_call(self.db, *args, **kwargs)
  File "/home/kristian/odoov8/odoo-8.0-20161017/openerp/service/model.py", line 118, in wrapper
  return f(dbname, *args, **kwargs)
  File "/home/kristian/odoov8/odoo-8.0-20161017/openerp/http.py", line 314, in checked_call
  return self.endpoint(*a, **kw)
  File "/home/kristian/odoov8/odoo-8.0-20161017/openerp/http.py", line 810, in __call__
  return self.method(*args, **kw)
  File "/home/kristian/odoov8/odoo-8.0-20161017/openerp/http.py", line 410, in response_wrap
  response = f(*args, **kw)
  File "/home/kristian/odoov8/odoo-8.0-20161017/openerp/addons/web/controllers/main.py", line 948, in call_button
  action = self._call_kw(model, method, args, {})
  File "/home/kristian/odoov8/odoo-8.0-20161017/openerp/addons/web/controllers/main.py", line 936, in _call_kw
  return getattr(request.registry.get(model), method)(request.cr, request.uid, *args, **kwargs)
  File "/home/kristian/odoov8/odoo-8.0-20161017/openerp/api.py", line 268, in wrapper
  return old_api(self, *args, **kwargs)
  File "/home/kristian/odoov8/odoo-8.0-20161017/openerp/api.py", line 399, in old_api
  result = method(recs, *args, **kwargs)
  File "/home/kristian/odoov8/odoo-venezuela/l10n_ve_withholding_iva/model/invoice.py", line 424, in button_generate_wh_doc
  ('type','=',inv.type)
  TypeError: 'tuple' object is not callable
  </code></pre>
  
  <p>I've looked for commas or typos but it seems to be alright, any ideas?</p>