title: Error while creating invoices
body: <p>An attempt to create invoices in bulk fails with the error as below :</p>
  
  <p>Integrity error:-</p>
  
  <pre><code>The operation can not be completed, probably due to following you may be trying to delete a record while other records still reference it.
  -creation/updation :a mandatory field is not set 
  object with reference :Sales order -sale.order
  </code></pre>
  
  <p>What am I missing?</p>
  
  <pre><code>4-24 05:41:32,637 4190 ERROR odoo_production_6 openerp.addons.base.ir.ir_cron: Call of self.pool.get('product.from_button').price_import_file(cr, uid, *()) failed in Job 29
  Traceback (most recent call last):
    File "/mnt/odoo/openerp/addons/base/ir/ir_cron.py", line 138, in _callback
      getattr(model, method_name)(cr, uid, *args)
    File "/mnt/odoo/openerp/api.py", line 237, in wrapper
      return old_api(self, *args, **kwargs)
  TypeError: price_import_file() takes at least 4 arguments (3 given)
  2015-04-24 05:41:52,947 4190 ERROR odoo_production_6 openerp.sql_db: bad query: INSERT INTO "account_move" ("id", "name", "company_id", "journal_id", "state", "period_id", "narration", "date", "ref", "to_check", "create_uid", "write_uid", "create_date", "write_date") VALUES(nextval('account_move_id_seq'), '/', 1, 2, 'draft', 5, '', '2015-04-19', 'SO99761', false, 1, 1, (now() at time zone 'UTC'), (now() at time zone 'UTC')) RETURNING id
  Traceback (most recent call last):
    File "/mnt/odoo/openerp/sql_db.py", line 234, in execute
      res = self._obj.execute(query, params)
  TransactionRollbackError: could not serialize access due to concurrent update
  CONTEXT:  SQL statement "SELECT 1 FROM ONLY "public"."res_users" x WHERE "id" OPERATOR(pg_catalog.=) $1 FOR KEY SHARE OF x"
  
  2015-04-24 05:41:52,948 4190 ERROR odoo_production_6 openerp.addons.base.ir.ir_cron: Call of self.pool.get('warehouse.picklist').create_invoices(cr, uid, *(['R105743853', 'R113227005', 'R146600137', 'R188375618', 'R220118225', 'R351012872', 'R420506806', 'R421507556', 'R426354681', 'R434108532', 'R441768276', 'R502478873', 'R571730346', 'R605517828', 'R630802333', 'R635404642', 'R654263524', 'R664533651', 'R685142753', 'R724478234', 'R761380645', 'R775785828', 'R776745047', 'R786383714', 'R820154123', 'R825637222', 'R826210504', 'R857286181', 'R858340517', 'R868485853'],)) failed in Job 31
  Traceback (most recent call last):
    File "/mnt/odoo/openerp/addons/base/ir/ir_cron.py", line 138, in _callback
      getattr(model, method_name)(cr, uid, *args)
    File "/mnt/odoo/openerp/api.py", line 237, in wrapper
      return old_api(self, *args, **kwargs)
    File "/mnt/odoo/voylla_modules/outbound/outbound.py", line 215, in create_invoices
      invoice_confirm_obj.invoice_confirm_1(cr, uid, invoice_ids, context)
    File "/mnt/odoo/openerp/api.py", line 237, in wrapper
  </code></pre>