Skip to content
Snippets Groups Projects
  1. Jun 28, 2023
  2. Jun 27, 2023
  3. Jun 26, 2023
  4. Jun 25, 2023
  5. Jun 24, 2023
    • Denis Ledoux's avatar
      [FIX] base_import_module: restore `<field file="...">` feature · 2a3ef939
      Denis Ledoux authored
      
      Revision odoo/odoo@cabb9e7e573b86cd523980588360d8514090d370 introduced a
      regression: This is no longer possible to import a data module
      using `<field file="..."/>` in their data file.
      
      This revision targets to restore the feature as expected.
      The unit tests added covers the feature, so that regression
      no longer happens in the future.
      
      It introduces a new concept of temporary directory `file_open`
      can read from.
      e.g.
      ```py
      with odoo.tools.file_open_temporary_directory(self.env) as module_dir:
         with zipfile.ZipFile('foo.zip', "r") as z:
            z.extract('foo/__manifest__.py', module_dir)
         with odoo.tools.file_open('foo/__manifest__.py', env=self.env) as f:
            manifest = f.read()
      ```
      
      Note that `file_open` will be allowed to read from that temporary
      directory only if `env` is passed to `file_open`,
      and if the `env` is part of the same transaction/request than the `env`
      passed to `file_open_temporary_directory`.
      
      This is to avoid having users, whether from other databases,
      or even the same database,
      trying to access these directories not belonging to them.
      e.g. If an admin uploads sensitive data in this temporary directory,
      no one than him must be allowed to read from these files, not even
      another user from his database.
      
      closes odoo/odoo#126278
      
      closes odoo/odoo#126337
      
      Signed-off-by: default avatarDenis Ledoux (dle) <dle@odoo.com>
      2a3ef939
    • OCA Git Bot's avatar
      98231227
  6. Jun 23, 2023
    • Julien Van Roy's avatar
      [FIX] mail: UTF-8 text/xml attachment and omitted charset · b2aa5883
      Julien Van Roy authored
      When parsing an email containing an xml attachment, the `email` python
      module will decode the base64 attachment using the charset or ascii if
      the charset is missing.
      
      In some cases, the payload is in UTF-8 but the charset is omitted. This
      results in replacement characters for the non ASCII characters.
      
      The solution is to force the charset to UTF-8, since it is a superset of
      ASCII that should not be a problem.
      
      NB1: Omitting the charset for text/xml is not recommended. See the RFC
      (section 6.4): https://www.ietf.org/rfc/rfc2376.txt
      
      
      
      opw-3144519
      
      closes odoo/odoo#125628
      
      Signed-off-by: default avatarJulien Castiaux (juc) <juc@odoo.com>
      b2aa5883
    • Yolann Sabaux's avatar
      [FIX] account_edi_ubl_cii: exclude note-section · fb716296
      Yolann Sabaux authored
      
      Steps to reproduce:
      - Install the lux localization
      - Configure Peppol for a customer: Select a customer > tab accounting > under "electronic invoicing":
      format: Peppol BIS Billing 3.0
      Peppol e-address: 0130 - Directorates of the European Commission
      Peppol Endpont: testendpoint
      
      - Create an invoice for the peppol customer
      - Add a section or a note in the Invoice
      - Confirm the Invoice
      
      Issue:
      Raise user error:  Odoo requires a tax for EACH LINE, instead of each product
      
      Solution:
      Exclude the section/note line
      
      opw-3354757
      
      closes odoo/odoo#124806
      
      Signed-off-by: default avatarLaurent Smet (las) <las@odoo.com>
      fb716296
    • Julien Van Roy's avatar
      [FIX] account_edi_ubl_cii: add italian EAS code for peppol Bis 3 · 030b55b2
      Julien Van Roy authored
      Currently, it's not possible to check the 'Peppol Bis 3' option on the
      journals of Italian companies, since Italy is not present in our mapping
      `COUNTRY_EAS`.
      
      The EAS for Italian companies may be the codice fiscal (code: 0210) or
      the VAT number (code: 0211). See
      https://peppol.agid.gov.it/en/news/expiration-validity-codes/
      
      
      
      Use the VAT number by default, and add it in our mapping such that the
      option now appears for Italian companies.
      
      opw-3346572
      
      closes odoo/odoo#126168
      
      Signed-off-by: default avatarFlorian Gilbert (flg) <flg@odoo.com>
      030b55b2
    • Mohit Beniwal's avatar
      [FIX] base: prevent json decoder error for default values · 0e6e322d
      Mohit Beniwal authored
      
      JSONDecoderError occurs when users enters invalid JSON format data in
      'Default Value' field inside 'User-defined Defaults' and wherever this field is
      being accessed to get default value this traceback will be generated.
      
      Steps to reproduce:
      1) Install 'Contacts' module.
      2) Open 'Settings' > 'Technical' > 'User-defined Defaults'.
      3) Click on record 'Language' > 'EDIT' button > in 'Default Value' field enter
         any improper JSON format data (e.g 'Maa' : FI ) .
      4) Now, open 'Contacts' module > click on 'CREATE' button and traceback would be
         generated.
      
      By applying this, it will check for proper JSON format.
      
      Sentry-4169062951
      
      closes odoo/odoo#124051
      
      Signed-off-by: default avatarRémy Voet (ryv) <ryv@odoo.com>
      0e6e322d
    • Enric Tobella's avatar
      [FIX] maintenance: Allow to see your created maintenances requests · df1badee
      Enric Tobella authored
      
      closes odoo/odoo#105495
      
      Signed-off-by: default avatarWilliam Henrotin (whe) <whe@odoo.com>
      df1badee
    • Guillaume (gdi)'s avatar
      [FIX] website_links: support foreign language for links graphs · e690da6e
      Guillaume (gdi) authored
      
      When a user creates a link that is tracked, an interface with graphs is
      presented to him so that he can track the performance of his tracked
      link. Unfortunately, these graphs did not work when the site was in a
      foreign language. This was due to the fact that the code had not been
      designed to handle this. This commit fixes the code so that it works in
      all languages.
      
      Note that the data is received via RPC and the python code format the
      dates for the current language of the website. So we had to do a little
      hack to make it work properly.
      
      Steps to reproduce the issue:
      - Install website_links module
      - Go to the website app
      - Click on Promote > Link Tracker
      - Create a tracked link
      - Visit the link
      - Install Arabic (Syria) for your website
      - Check the stats of your link in Arabic
      
      => There is a traceback and the data is not displayed.
      
      task-3289167
      
      closes odoo/odoo#119375
      
      Signed-off-by: default avatarOutagant Mehdi (mou) <mou@odoo.com>
      e690da6e
    • OCA Git Bot's avatar
      ec664471
  7. Jun 22, 2023
  8. Jun 21, 2023
  9. Jun 20, 2023
  10. Jun 19, 2023
    • Romain Derie's avatar
      [IMP] website: make website_nightly build work before 16.4 · 231a7d63
      Romain Derie authored
      We have introduced a new tag `website_nightly` which is linked to a
      custom build on the nightly.
      It has been introduced with this commit [1].
      
      The goal is to extract the `external` tagged tests linked to the website
      app to another special build linked to the website team.
      Otherwise, we would not see when the test fail, as the `external` build
      of the nightly is always red and we don't check why all the time.
      
      Encapsulating this in a new build and linking to our team means that
      whenever the test fail in a nightly, we will be visually warned on the
      runbot homepage by a red warning, see screenshot on the PR of this
      commit.
      
      Sadly, before 16.4, as there is not yet `website_nightly` tours, the
      build is considered failed, showing the error.
      Another solution would have been to somehow disable this tour on Odoo
      versions < 16.4 but it we opted for this solution as:
      - It's simpler, no need to add yet another custom stuff in runbot
      - It will work out of the box should be introduce such a test in those
        versions: we won't need to ask runbot to activate the test in another
        version, should we even think about it..
      
      [1]: https://github.com/odoo/odoo/commit/a0d0afb20594aa103eb1d0476d53012b9821e861
      
      
      
      closes odoo/odoo#125662
      
      Signed-off-by: default avatarXavier Dollé (xdo) <xdo@odoo.com>
      231a7d63
    • mega-odoo's avatar
      [FIX] web_editor: prevent error when edit the float, monetary section in website · b895175c
      mega-odoo authored
      
      'replace() argument 1 must be str, not bool' is generated if the user edit a
      float or monetary section in the website view.
      
      Steps to Reproduce
      
      - Make debugger mode ON.
      - Go to Settings > Translations > Languages.
      - Remove the value of the 'Thousands Separator' field from the current user
      language.
      - Install the 'eCommerce' module.
      - Go to the website.
      - Go to the shop menu, and click any product from the product list.
      - Click on the Edit button and try to edit any float or
      monetary section like a product price (eg. change a product price from 750 to
      70) and click on the Save button.
      
      And traceback will be generated.
      
      Applying this commit will resolve this issue.
      
      sentry-4148693017
      
      closes odoo/odoo#124245
      
      Signed-off-by: default avatarDavid Monjoie (dmo) <dmo@odoo.com>
      b895175c
    • OCA Git Bot's avatar
      b39ac080
  11. Jun 18, 2023
  12. Jun 17, 2023
  13. Jun 16, 2023
Loading