1. 12 May, 2016 6 commits
    • Goffin Simon's avatar
      [FIX] website: URL of website_published is wrong when using next/previous · 746cda7f
      Goffin Simon authored
      Steps to reproduce:
      
      -go to runbot 8.0 and connect
      -go into human ressources/job positions
      -pass into list view and click on the first item
      -click on the url to open this record into the website (website_published)
      -go back (back into the browser)
      -you're now into the form view again and then next step is to click on the button
      "next" to access the following record
      -click on the url of website_published
      
      Before the fix:
      
      wrong record, this is the previous one that is into the href
      
      After the fix:
      
      correct record with the correct id into the href
      
      Closes #11800
      opw:675832
      746cda7f
    • Goffin Simon's avatar
      [FIX] purchase: fiscal position from onchange_partner_id · 7061acd2
      Goffin Simon authored
      Used case:
      
      -Configure admin as multi-company user
      -Create 2 fiscal positions (one for company "Odoo BE" and one for company "Odoo US")
      -Set admin on company "Odoo BE"
      -On supplier (Asustek) configure fiscal position Odoo BE
      -Set admin on company "Odoo US"
      -On supplier (Asustek) configure fiscal position Odoo US
      -Configure a product (Laptop E5023) with:
         *route "Buy"
         *supplier (Asustek) without company
         *reordering rules (min qty: 20, max qty: 40)
      -Set admin on company "Odoo BE"
      -Run scheduler via the cron
      
      Behavior before the fix:
      
      -Fiscal position on the created PO is the fiscal position for "Odoo BE" (and PO is for the company "Odoo US")
      
      Behavior after the fix:
      
      -Fiscal position on the create PO is the fiscal position for "Odoo US".
      
      Closes #11537
      
      opw:673288
      7061acd2
    • Nicolas Seinlet's avatar
      [IMP] models: mark records as recomputed as soon as they are · 3a320211
      Nicolas Seinlet authored
      When recomputing stored function fields, the `write` may trigger a
      cache invalidation which lead to a recompute of all the recordset
      values, even the ones already saved in database.
      3a320211
    • Nicolas Seinlet's avatar
      [IMP] account: improve reconciliation speed · f207ef5f
      Nicolas Seinlet authored
       - Only invalidate cache for fields and records we modify
       - Rewrite query to be more efficient
       - Avoid o2m commands to be more efficient; write directly on reverse m2o
      f207ef5f
    • Nicolas Seinlet's avatar
      [FIX] mail: remove unneeded call to `refresh()` · 6f29bfc1
      Nicolas Seinlet authored
      With new api, this call is not wanted anymore. The cache is cleared
      automatically, no need to clear the whole cache; that's a little bit
      overkill and reduce performances.
      6f29bfc1
    • Nicolas Martinelli's avatar
      [FIX] purchase: date planned · 52948199
      Nicolas Martinelli authored
      When a PO is copied, the date planned of the order lines should be
      recomputed based on the order date.
      
      opw-675480
      52948199
  2. 11 May, 2016 3 commits
  3. 10 May, 2016 2 commits
    • Olivier Dony's avatar
      [FIX] http: clear environment/caches on transaction rollback · ac8b7e90
      Olivier Dony authored
      Backport of 8423a0df
      
      Clear the cache/environment in addition to rolling back
      the cursor, in order to retry the transaction with fresh
      data, not partially stale data.
      ac8b7e90
    • Denis Ledoux's avatar
      [FIX] google_calendar: do not copy user Google info · a0366b3a
      Denis Ledoux authored
      If a user syncs his calendar with Google,
      and a second user is created in the database by copying this first
      user, the Google information of the first user was copied
      (The Google account to sync, the token to use, the last
      syncrhonization date, ...), which is obviously wrong.
      
      On calendar syncrhonization, which can be done
      manually or automatically with the according cron, all
      events of the first user were created a second time,
      as a second user synchronized the same Google Calendar.
      
      opw-674141
      a0366b3a
  4. 09 May, 2016 5 commits
    • Denis Ledoux's avatar
      [FIX] account_anglo_saxon: default account value · 3954affc
      Denis Ledoux authored
      The default account value set for purchases invoices
      lines for product of type Service was wrong: It used
      the stock account, which is wrong as a Service
      as no stock. Instead, it should left the product
      expense account, as usual.
      
      opw-676110
      3954affc
    • Martin Trigaux's avatar
      [FIX] sale: outdated .pot file · 88749790
      Martin Trigaux authored
      Was having content of website_quote
      88749790
    • Raphael Collet's avatar
      [FIX] fields: invalidate x2many fields with a domain · 5676d812
      Raphael Collet authored
      Invalidate the cache of a x2many field when any of the fields appearing in its
      domain is modified.  Use the invalidation triggers mechanism for that purpose.
      5676d812
    • Denis Ledoux's avatar
      [FIX] google_calendar: user invited to one recurring event occurence only · 7923999f
      Denis Ledoux authored
      When a Google user was invited to one occurrence of a recurring event,
      but not to the recurring event itself (and the other occurrences, therefore),
      and the user owner of the recurring event did not sync his calendar in Odoo,
      the event occurrence could not be synced in Odoo, because it attempted
      to attach it to the parent/main recurring event, which was not present
      in Odoo.
      
      In such a case, Odoo now syncs the event occurrence as a simple classic
      event. In addition, if the owner of the event sync his calendar with Odoo
      afterwards, or if the user is invited later to the main/parent recurring event
      and then sync again his calendar,
      it then attach the event occurrence that was previously
      synced to this main event, to avoid events duplication.
      
      opw-676535
      7923999f
    • Nicolas Lempereur's avatar
      [IMP] web: multi-click on save on view form (no fp) · dd714ace
      Nicolas Lempereur authored
      When clicking on save several time when editing a view form it can be
      saved several times which can be an issue for one to many.
      
      The normal happenstance when saving should be as follow:
      
      -> save (click)
      -> wait write result
      -> received write result
      -> reload the form with updated data and updates buttons
      
      But when clicking several time, it could become:
      
      -> save (click)
      -> wait write result
      -> received write result
      -> save (click)
      -> wait write result
      -> received write result
      -> reload the form with updated data and updates buttons
      
      This commit only reinstate the saving feature once the form is reloaded.
      
      closes #11926
      opw-671793
      
      note: no need to forward-port
      dd714ace
  5. 08 May, 2016 1 commit
  6. 06 May, 2016 1 commit
  7. 05 May, 2016 3 commits
  8. 04 May, 2016 2 commits
  9. 03 May, 2016 1 commit
  10. 02 May, 2016 2 commits
    • Holger Brunn's avatar
      [FIX] project: make copy overridable in v8 api · a4c4c43b
      Holger Brunn authored
      Without the proper decorator, the method is matched as `cr_ui_context`.
      This is because the `guess` mechanism expects a name `res_id` instead of
      `record_id`.
      For stability reason it is better to add the decorator than modify the signature
      of the method.
      Closes #11735
      a4c4c43b
    • Frederik Kramer's avatar
      [CLA] update signature of initos · d6563f91
      Frederik Kramer authored
      Changes due to changes in the legal form of the company
      Closes #11759
      d6563f91
  11. 01 May, 2016 1 commit
  12. 30 Apr, 2016 1 commit
  13. 29 Apr, 2016 2 commits
    • Raphael Collet's avatar
      [FIX] expression: fix missing results in direct search on many2many fields · ba5f5614
      Raphael Collet authored
      This case corresponds to searches like `[(field, 'ilike', name)]` where `field`
      is a many2many field.  The domain processing performs a `name_search` on the
      field's comodel, then makes the relation match the returned record ids.
      
      Problem: the call to `name_search` uses the default limit (100), and this makes
      the search return less results than expected.  Make the search complete by
      forcing `limit=None`.
      ba5f5614
    • Raphael Collet's avatar
      [FIX] expression: fix missing results in direct search on many2many fields · c7baab67
      Raphael Collet authored
      This case corresponds to searches like `[(field, 'ilike', name)]` where `field`
      is a many2many field.  The domain processing performs a `name_search` on the
      field's comodel, then makes the relation match the returned record ids.
      
      Problem: the call to `name_search` uses the default limit (100), and this makes
      the search return less results than expected.  Make the search complete by
      forcing `limit=None`.
      c7baab67
  14. 28 Apr, 2016 1 commit
  15. 26 Apr, 2016 4 commits
    • Stefan Rijnhart's avatar
      [FIX] tools: export translated fields not included in _columns · 0c2f7bdb
      Stefan Rijnhart authored
      Non-stored new API computed fields are only defined in _fields
      but not in _columns, and they were never exported within translation
      files.
      
      Closes #9081
      0c2f7bdb
    • Christophe Simonis's avatar
      [FIX] calendar: correct search on mail.message and ir.attachment · 7e51d985
      Christophe Simonis authored
      Handle the case of immutable (tuple) domain leafs.
      7e51d985
    • Goffin Simon's avatar
      [FIX] account_asset: asset_create · d8121753
      Goffin Simon authored
      When creating assets from invoice lines, the system must check
      that assets have not already been created for the related invoice.
      If assets already exist then these assets have to be removed.
      
      Used case:
      
      - In the purchase journal, tick "allow canceling entries"
      - On a supplier invoice line, set an asset category
      - validate the invoice
      - cancel the invoice
      - set to draft
      - validate the invoice
      
      Before the fix: the asset is created twice.
      After the fix: the asset is created once.
      
      opw:674674
      d8121753
    • Nicolas Martinelli's avatar
      [FIX] website_sale: log if no pricelist · f5eae92f
      Nicolas Martinelli authored
      The pricelist field is not a mandatory field on the partner. A default
      value is usually defined for any new partner created. However, if the
      pricelist is manually removed from the partner, errors (tracebacks) will
      occur in the eCommerce when no pricelist is found.
      
      We cannot make the field mandatory, as it could potentially break the
      workflow of some users which are not using eCommerce. Therefore, we
      simply log an error message to help debugging.
      
      opw-673453
      f5eae92f
  16. 25 Apr, 2016 2 commits
  17. 24 Apr, 2016 1 commit
  18. 22 Apr, 2016 2 commits
    • Raphael Collet's avatar
      [FIX] models: fix *2many multi-onchange bug · 86d276b4
      Raphael Collet authored
      This fixes the case where the lines of a one2many field are modified several
      times by onchange methods: instead of retrieving the most recent updates, we
      merge them with former updates.
      
      This solution was written as an improvement of a proposal made by Alexis
      Delattre and Sébastien Beau as #11620.
      86d276b4
    • Martin Trigaux's avatar
      [FIX] orm: do not save empty translation as 'false' · fd7a7207
      Martin Trigaux authored
      When writting a value on a translatable field in a different language than
      English, the submitted *raw* value was saved in the database.
      
      This could cause the following issues:
      - empty value (provided as `False` by the web client) saved as the string
        'false' in the translations table
      - no encoding or sanitization convertion
      - ignore size parameter on the translatable field
      
      Process the submitted translation through symbol_set method to clean it before
      storing it blindly in the database.
      
      This allows to convert `False` into `''` for empty value and fixes #10862
      fd7a7207