Skip to content
Snippets Groups Projects
  1. Apr 19, 2019
    • Lucas Perais (lpe)'s avatar
      [FIX] website_quote: portal optional products qty change · 4730a884
      Lucas Perais (lpe) authored
      
      Have a SO with a quotation template and some optional products set
      Display it on the portal
      On an optional product, click on the cart icon
      to add it to the SO
      
      Modify the quantity of the optional product
      
      Before this commit, the feature was barely working:
      - the total price of the optional product did not change
      - negative quantities were allowed
      - there was no reaction when directly putting a number in the input
      - when decrementing the quantity, it crashed
      - untaxed and tax amounts were not dynamic
      
      After this commit:
      - the total price of the optional product changes as a function of the quantity input
      - negative quantities are not allowed
      - it is not possible to manually input the quantity with a keyboard
        only +/- buttons are used to change the quantity
      - decrementing the quantity works
      - untaxed and tax amounts are dynamic
      
      OPW 1947769
      
      closes odoo/odoo#32715
      
      Signed-off-by: default avatarLucas Perais (lpe) <lpe@odoo.com>
      4730a884
  2. Mar 06, 2019
  3. Apr 19, 2019
    • David's avatar
      [FIX] point_of_sale: put PoS picking sequence in noupdate · d3c980e9
      David authored
      
      The default PoS picking sequence should not be reset.
      Losing custom configuration can lead to errors.
      
      For instance:
      - A customer initially uses the default sequence until POS09999
      - he changes it to another one of his own taste starting the
        sequence over, like: WH/POS/00001
      - In a module update, the sequence is reset and then we get the POS
        prefix again.
      - In the next picking, we could have a duplicated name, and an error
        would raise in the Point of Sale.
      
      opw 1962302
      closes #32299
      
      closes odoo/odoo#32842
      
      Signed-off-by: default avatarNans Lefebvre (len) <len@odoo.com>
      d3c980e9
    • Lucas Perais (lpe)'s avatar
      [FIX] account: report overdue: name of company duplicated · f9ce7d1f
      Lucas Perais (lpe) authored
      
      Have a partner which is only a company
      Print "Due Payments" report
      
      Before this commit, the name of the company was shown in double
      this was because both `name` and `contact_address` are shown in that report
      but in the case of a company, or child of a company, the company's name
      is included in contact_address
      
      After this commit, the name appears only once
      
      OPW 1970581
      
      closes odoo/odoo#32838
      
      Signed-off-by: default avatarLucas Perais (lpe) <lpe@odoo.com>
      f9ce7d1f
    • Lucas Perais (lpe)'s avatar
      [FIX] website_quote: change website_description when the template id changes · 0106fcd5
      Lucas Perais (lpe) authored
      
      Have a SO with a partner in another language
      Apply a quote template to a SO
      Customize the portal view to show website_description of a product on the template
      Translate it
      Show the SO on the portal
      
      Before this commit, the description of the product was not translated
      This was because the field was not included in the onchange of template_id
      causing that field to never have changed, that is, it kept the description
      done injected with the first write
      
      After this commit, the description is changed according to the partner's lang
      
      OPW 1960977
      
      closes odoo/odoo#32825
      
      Signed-off-by: default avatarLucas Perais (lpe) <lpe@odoo.com>
      0106fcd5
    • Joseph Caburnay's avatar
      [FIX] auth_signup: portal user redirect to /web after signup · 0229ef4c
      Joseph Caburnay authored
      
      To reproduce:
      0. Start an odoo v10 instance with --load=saas_worker,web
      1. Install ecommerce.
      2. Enable "Allow external users to sign up" and "Enable password
      reset from Login page" from General Settings.
      3. Open different session then signup a new user.
      4. After successfull signup, the new user will be redirected
      to the backend (/web).
      
      Facts to consider:
      1. odoo.addons.auth_signup.controllers.main.AuthSignupHome and
      odoo.addons.website.controllers.main.Website both inherit
      odoo.addons.web.controllers.main.Home
      2. When instantiating an odoo instance *without* saas_worker,web,
      the mro is the following:
      
      ( <class 'odoo.http.Home (extended by Website, AuthSignupHome)'>
      , <class 'odoo.addons.auth_signup.controllers.main.AuthSignupHome'>
      , <class 'odoo.addons.website.controllers.main.Website'>
      , <class 'odoo.addons.web.controllers.main.Home'>
      , <class 'odoo.http.Controller'>
      , <type 'object'>
      )
      
      while the mro *with* saas_worker,web loaded is:
      
      ( <class 'odoo.http.Home (extended by AuthSignupHome, Website)'>
      , <class 'odoo.addons.website.controllers.main.Website'>
      , <class 'odoo.addons.auth_signup.controllers.main.AuthSignupHome'>
      , <class 'odoo.addons.web.controllers.main.Home'>
      , <class 'odoo.http.Controller'>
      , <type 'object'>
      )
      
      You can notice that depending on how the instance is instantiated,
      the order of inheritance is different.
      
      The problem occurs when saas_worker is loaded, so this bug can be
      experienced by saas clients.
      
      Explanation of the fix:
      Notice that the original code calls web_login of its super in its
      web_auth_signup method. This is technique is used normally during
      optimization (according to RCO). If website is installed, the
      portal user should be redirected to '/' instead of '/web' and this
      is defined in web_login of website. However, the web_login of
      "website" is not called after signup because "website" is not super
      of "auth_signup" when saas_worker is loaded (see the mro above).
      
      Calling self.web_login will make sure that web_login is called from
      top to bottom, and regardless of the order of website and auth_signup,
      web_login of "website" will be called and makes sure that the
      new portal user is redirected to the '/' and not to '/web'.
      
      opw-1956980
      
      closes odoo/odoo#32741
      
      Signed-off-by: default avatarNicolas Martinelli (nim) <nim@odoo.com>
      0229ef4c
  4. Apr 18, 2019
  5. Apr 16, 2019
    • Nicolas Martinelli's avatar
      [FIX] l10n_fr_pos_cert: fpos settings · 1ab61efe
      Nicolas Martinelli authored
      
      The computation of hash integrity depends on the field
      `tax_ids_after_fiscal_position`. However, this field is computed, but
      not stored.
      
      It means that if one modifies a fiscal position used in the POS, the
      computation of `tax_ids_after_fiscal_position` will change.
      Consequently, the hash computation of the order will be modified, and
      the hash integrity of the journal will be corrupted.
      
      We prevent the modification of the taxes implied in a fiscal position if
      any POS order use it.
      
      Closes #32665
      opw-1969009
      
      closes odoo/odoo#32701
      
      Signed-off-by: default avatarNicolas Martinelli (nim) <nim@odoo.com>
      1ab61efe
  6. Apr 10, 2019
    • Olivier Dony's avatar
      [FIX] requirements: bump up jinja2 reqs · 78ba90d5
      Olivier Dony authored
      
      Recommended by GitHub's repository alerts.
      
      We normally stick as close as possible to the version we depend
      on in the official DEB packages. This in turn depends on the version of
      Debian stable at the time of release - for 10.0 that would be Debian 8
      (jessie) and thus Jinja 2.7.3 (albeit with security backports).
      
      However Jinja2 before 2.10.1 suffers from a few issues that could lead
      to crashes of Odoo processes.
      
      It seems it's worth an exception to our rule for pip users, similarly to
      previous bump up at d2605bcc.
      
      closes odoo/odoo#32602
      
      Signed-off-by: default avatarChristophe Simonis <chs@odoo.com>
      78ba90d5
    • Denis Ledoux's avatar
      [FIX] point_of_sale: lost pos orders on IntegrityError · 39fd19ff
      Denis Ledoux authored
      
      This revision is similar to
      605b94e6
      
      except that instead of an OperationalError
      (e.g. a conccurent update),
      this is an IntegrityError which is raised,
      an sql constraint which is not met,
      e.g. a unique or required constraint.
      
      In the case of this opw,
      this is the picking name unique constraint
      which was not met,
      the picking sequence number has somehow been re-used.
      
      Both
      `psycopg2.OperationalError`
      and
      `psycopg2.IntegrityError`
      inherits from
      `psycopg2.DatabaseError`
      
      We therefore choose to use this Exception class,
      to include all kind of psycopg2 exceptions that prevent
      the transaction to be committed.
      
      opw-1965679
      
      closes odoo/odoo#32577
      
      Signed-off-by: default avatarDenis Ledoux <beledouxdenis@users.noreply.github.com>
      39fd19ff
  7. Mar 27, 2019
  8. Apr 09, 2019
    • Gert Pellin's avatar
      [FIX] point_of_sale: fix decimal point · 41137c30
      Gert Pellin authored
      
      Before this fix there was no check if there was already a decimal point
      in the value when using the onscreen keypad.
      
      Fixes #32034
      
      Steps to reproduce:
      
      * Open up POS interface
      * Add an item
      * Press the decimal point button multiple times (2 or more)
      * Note that pressing additional number keys do not display
      * Backspace must be pressed for the number of digits entered,
        plus the multiple decimal points, to clear
        all the hidden characters in the value buffer
      * Same behavior occurs with the Discount and Price
        values
      
      Current behavior:
      Multiple decimal point characters can be
      "entered" and are inserted into value buffer
      (Qty, Disc, or Price), but do not display on
      screen.
      Additional digits entered after multiple decimal
      point presses are inserted into buffer, but do
      not display on screen.
      Additional digits entered after the last valid
      digit on the screen are also inserted into the
      buffer.
      Backspace must be used to remove the invisible
      characters from the value buffer.
      
      Expected behavior:
      The value buffer for Qty, Disc, or Price should
      more closely match what is displayed on the
      screen.
      Characters which are invalid and aren't
      displayed on the screen, should not be inserted
      into the value buffer, including the decimal
      point button.
      
      closes odoo/odoo#32089
      
      Signed-off-by: default avatarQuentin Lejeune (qle) <qle@odoo.com>
      41137c30
  9. Apr 08, 2019
  10. Apr 05, 2019
  11. Apr 04, 2019
  12. Apr 03, 2019
    • Nicolas Lempereur's avatar
      [FIX] point_of_sale: allow connect proxy https error · e14c386a
      Nicolas Lempereur authored
      
      Since 79af654fc61 if we had unexpected configuration of usage such as
      being in HTTPS, having a POS hardware in HTTPS but an error is received
      (eg. the device is closed) => the POS interface can't be opened being
      blocked on an error:
      
       Https connection to IoT Box failed
       Make sure you are using IoT Box v18.10 or higher.
      
       Navigate to {proxy_ip} to accept the certificate of your IoT Box.
      
      With this changeset, we have a popup that does not prevent to open the
      point of sale interface (and  the red disconnected status in the top
      left allow to retry connection as before) on first load.
      
      opw-1934413
      closes #32306
      
      Signed-off-by: default avatarNicolas Lempereur (nle) <nle@odoo.com>
      e14c386a
  13. Apr 02, 2019
    • Nicolas Martinelli's avatar
      [FIX] product, purchase: seller in multi-company · 9f2dd49c
      Nicolas Martinelli authored
      
      - Create 2 companies A & B
      - For a product P, create a supplier info for each company using the
        same partner, with a different price and delay.
      - Order the supplier so that the one for A has a higher priority than
        the one for B.
      - Create a reordering rule for P in company B.
      - Run the scheduler as admin (e.g. thanks to the cron).
      
      The price taken is the price for company A instead of B.
      
      `_select_seller` is not company-aware, therefore the first matching
      supplier is chosen.
      
      opw-1959263
      
      closes odoo/odoo#32328
      
      Signed-off-by: default avatarNicolas Martinelli (nim) <nim@odoo.com>
      9f2dd49c
  14. Apr 03, 2019
  15. Apr 01, 2019
  16. Mar 29, 2019
    • Nans Lefebvre's avatar
      [FIX] base_geolocalize: raise a helpful error to configure the Google account · 6b9b9d89
      Nans Lefebvre authored
      
      Google maps used to be free, but became a paid API.
      Technically, the usage could be part of the free offer,
      but to benefit from it the account needs to have billing enabled.
      Since it's a paid feature security had to be ramped up,
      so now APIs have to be explicitly enabled (here geolocating/geocoding).
      All this makes it so that the Google account has to be properly configured
      before the calls to the Maps API can work.
      As a result we add an explicit UserError if the request fails,
      to help the user configure the Google account
      (before the error was entirely hidden as to give the user no chance at all).
      
      Also exports transaltions, including for commit e6ca846c
      which raised a similar error message if no API key was found.
      
      opw 1946485
      opw 1947292
      opw 1947337
      
      closes odoo/odoo#32162
      
      Signed-off-by: default avatarNans Lefebvre (len) <len@odoo.com>
      6b9b9d89
  17. Mar 28, 2019
  18. Mar 25, 2019
  19. Mar 20, 2019
  20. Mar 18, 2019
    • Fabien Meghazi's avatar
      [FIX] base: fix ir.logging database locking when using --log-db · f1c72ee8
      Fabien Meghazi authored
      
      Before this patch, the ir.logging's write_uid field was a many2one which
      could cause a module install/update to hang when the module is changing
      the res.users model schema and when this module causes to orm to warn
      through the logger. (eg: declaring two res.users fields with the same
      string attribute)
      
      In such situation the transaction cursor that is processing the
      res_users table alteration will be granted an exclusive postgresql lock
      hence causing the ir_logging insertion to block because of the write_uid
      foreign key to res_users.
      
      This issue has never been raised by runbot as it is using a remote
      database with --log-db
      
      Note: the write_uid conversion from m2o to int was left over in commit e6a5d820
      
      closes odoo/odoo#32015
      
      Signed-off-by: default avatarChristophe Simonis <chs@odoo.com>
      f1c72ee8
  21. Mar 15, 2019
  22. Mar 14, 2019
  23. Mar 15, 2019
  24. Mar 12, 2019
  25. Mar 15, 2019
  26. Mar 13, 2019
    • Toufik Ben Jaa's avatar
      [FIX] portal: Portal User creation login check · 7ac7c977
      Toufik Ben Jaa authored
      
      - When creating a user from the "Grant Portal Access" wizard, the code
        checks for duplicate users.
        It does so by checking if there is a user with the same login as the
        one we want to create.
      
        The check is case sensitive which could lead to issues.
        For example a mistyped email (with a uppercase somewhere) could fail
        the duplicate user check.
        Since emails are not case sensitive, we want the check to be case
        insensitive too.
      
        OPW-1932918
      
      closes odoo/odoo#31818
      
      Signed-off-by: default avatarToufik Benjaa (tbe) <tbe@odoo.com>
      7ac7c977
    • xmo-odoo's avatar
      [IMP] base: remove prefetch when getting commercial fields · 747e05db
      xmo-odoo authored
      
      This is related to issue #31549, fixing it in 10 since it's already a
      minor issue here (importing 500 partners which all have the same parent,
      on my system the import time goes from 2:30 to 2:00).
      
      This is mostly a problem for such fields as `property_product_pricelist`
      (added do the commercial fields list by `product`): since we're first
      getting it then writing a field it depends on (updating the address,
      which contains the country), the field gets invalidated for all records
      on each record being imported, so if we're importing a bunch of partners
      which all have the same parent (e.g. company employees)
      `property_product_pricelist` is going to be re-computed for every
      partner imported so far as well as the one parent we're interested in,
      for every new partner we're creating.
      
      The problem is much more prevalent with 12.0's batched creates as we're
      first creating all the new partners then doing the updates, and thus for
      each new partner we're computing `property_product_pricelist` for all
      new partners and the one parent we're interested in, roughly doubling
      the import time of a series of partners which all have the same parent.
      
      closes odoo/odoo#31804
      
      Signed-off-by: default avatarRaphael Collet (rco) <rco@openerp.com>
      747e05db
  27. Mar 11, 2019
    • Rémi Rahir's avatar
      [FIX] website_sale: filter fiscal positions on company v2 · 49ca43d7
      Rémi Rahir authored
      
      Sequel of cc54194e.
      The mentioned fix only worked when the user was public.
      
      The problem arises when calling the function `_get_fpos_by_region()`
      in `sudo` without specifying the company and this happens, for instance,
      in every `onchange_partner_*` function of a sale order.
      
      We propose to add the `force_company` key in the context of the sale
      order to ensure the right company when selecting the fiscal position.
      
      closes odoo/odoo#31751
      
      Signed-off-by: default avatarRémi Rahir (rar) <rar@odoo.com>
      49ca43d7
    • Yoshi Tashiro's avatar
      [FIX] l10n_jp: wrong user type, add accounts · 084246a5
      Yoshi Tashiro authored
      
      - Fixes incorrect user type assignments on some accounts
      - Fixes incorrect account assignments on taxes
      - Adds a few accounts that Japanese companies would typically need
      - Changes some account codes to make the structure more consistent
      - Updates descriptions of some taxes to make them appear more natural
        on PDF reports
      
      closes odoo/odoo#30780
      
      Signed-off-by: default avatarNicolas Martinelli (nim) <nim@odoo.com>
      084246a5
  28. Mar 08, 2019
  29. Mar 07, 2019
Loading