Skip to content
Snippets Groups Projects
  1. Jun 20, 2023
    • Arnold Moyaux's avatar
      [FIX] mrp: merge moves in pick before manufacturing · f7414901
      Arnold Moyaux authored
      
      Use case:
      It happens that a product is consumed in different operations.
      So it needs two distinct BoM lines. Since commit [1] the stock.move
      in pbm are not merged. However [1] was design for kit.
      In our case we would like to have only one stock.move for all the
      quantities.
      
      The fix is not perfect because it won't work if we confirm at the
      same time a move with a kit and without it. But at least it will let
      people using MO without kit has the correct behavior
      
      + remove a duplicate of the function
      
      [1] commit 741d2fe9
      
      closes odoo/odoo#122682
      
      X-original-commit: 07b192b8
      Signed-off-by: default avatarWilliam Henrotin (whe) <whe@odoo.com>
      f7414901
    • mega-odoo's avatar
      [FIX] web_editor: prevent error when edit the float, monetary section in website · 40290102
      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#125634
      
      X-original-commit: b895175c
      Signed-off-by: default avatarDavid Monjoie (dmo) <dmo@odoo.com>
      40290102
  2. Jun 19, 2023
  3. Jun 18, 2023
  4. Jun 16, 2023
  5. Jun 15, 2023
    • Julien Van Roy's avatar
      [FIX] account_edi_ubl_cii: no xml declaration with the send & print · d771f745
      Julien Van Roy authored
      
      Issue: the xml declaration "<?xml version='1.0' encoding='UTF-8'?>" is
      lost when opening the send & print wizard with existing xml attachments.
      
      Explanation: When opening the send and print wizard, the PDF are
      generated and postprocessed by `_postprocess_pdf_report`. In the
      `_postprocess_pdf_report` override in `account_edi_ubl_cii`, the xml
      attachments are parsed through `tree = etree.fromstring(xml)`, then the
      base64 PDF is inserted, and the etree is converted to a bytes through
      `etree.tostring(cleanup_xml_node(tree))` and the resulting bytes is
      written back on the attachment, but the xml declaration disappeared.
      
      Solution: include the arguments `xml_declaration=True, encoding='UTF-8'`
      in the `tostring` function when converting the etree to a bytes.
      
      opw-3144519
      
      closes odoo/odoo#125266
      
      X-original-commit: d89f5cb2
      Signed-off-by: default avatarLaurent Smet <las@odoo.com>
      d771f745
    • Antoine Dupuis (andu)'s avatar
      [FIX] l10n_it_edi: Generate correct XML for negative invoice lines · 34e6b2f7
      Antoine Dupuis (andu) authored
      
      When creating an invoice with a positive line and a negative line, with
      different taxes, the DatiRiepilogo node for the tax of the negative
      line contained positive amounts when they should be negative.
      
      This is because we were applying `abs()` too naively in the XML template
      and in the code of _l10n_it_edi_prepare_fatturapa_tax_details.
      
      This bugfix commit changes the logic to no longer use abs().
      
      We also include a test to check that the XML is correctly generated for
      credit notes.
      
      Back-port of #121933
      
      opw-3316300
      
      closes odoo/odoo#125198
      
      X-original-commit: 17f336e4
      Signed-off-by: default avatarJosse Colpaert <jco@odoo.com>
      Signed-off-by: default avatarAntoine Dupuis (andu) <andu@odoo.com>
      34e6b2f7
    • VAN BOSSUYT Nicolas's avatar
      [FIX] website: prevent date input to fallback on today's date · d127b6ec
      VAN BOSSUYT Nicolas authored
      
      The cause of the issue is that `datetimepicker('viewDate')` will return
      the datetime of today by default event if the user selects nothing, to
      remedy this, we now check if the user has chosen something before
      storing the content of the field in `form_values`.
      
      Step to reproduce:
      - Install website_crm_partner_assign to have the "Partnership Date"
        field on res.partner.
      - Install website_sale to have the "Create customer" capability on the
        website forms.
      - Drag & drop a form snippet on any page
      - Select "Create customer" as form action
      - Add a custom field "Partnership Date"
      - Submit the form without filling the Partnership Date field
      - The field will be set to today's date while it should have been left
        void.
      
      opw-3333364
      
      closes odoo/odoo#124548
      
      X-original-commit: a2a49579
      Signed-off-by: default avatarRomain Derie (rde) <rde@odoo.com>
      d127b6ec
    • Bruno Boi's avatar
      [FIX] web: sync reposition for nested poppers · 4de65cca
      Bruno Boi authored
      This commit will have nested components making use of
      the usePosition hook to synchronize their repositioning.
      
      **Before this commit**
      Each component handles its own repositioning logic.
      If it is mounted somehow inside another component using that
      same logic, conflicts occur in some circumstances.
      
      **After this commit**
      It is now ensured that, in case of nested positioned components,
      the whole chain of repositioning computations is called in the
      proper order: from the parent to the children.
      
      **Example**
      - Before
        ![before]
      - After
        ![after]
      
      [before]: https://github.com/odoo/odoo/assets/1159815/3c9cfae7-db68-4707-a73c-ad7e2e71d4bf
      [after]: https://github.com/odoo/odoo/assets/1159815/a21f56e0-d8e3-48c1-9509-8e6ee5040d4b
      
      
      
      closes odoo/odoo#125048
      
      Signed-off-by: default avatarMichaël Mattiello (mcm) <mcm@odoo.com>
      4de65cca
    • Bruno Boi's avatar
      [REV] web: revert wrong fix on popper reposition · 690f7b94
      Bruno Boi authored
      This reverts commit a9273ced.
      
      The IntersectionObserver strategy it implements do not
      fullfil properly its purpose.
      It was a mistake trying to use this kind of observer as
      it is specifically meant for a different use case than
      the one we tried to solve in the first place.
      
      Another fix should follow directly this revert commit.
      
      Part-of: odoo/odoo#125048
      690f7b94
    • Victor Feyens's avatar
      [FIX] sale: multi-company conflict at reinvoicing · 126ef649
      Victor Feyens authored
      
      Since d88409e8, taxes from different companies
      are forbidden on sale.order.line records (which is the expected behavior).
      
      Nonetheless, this highlighted some flows where the taxes were not properly
      set/recomputed, especially re-invoicing, which is fixed by the current commit.
      
      Fixes #123675
      
      closes odoo/odoo#124483
      
      Signed-off-by: default avatarVictor Feyens (vfe) <vfe@odoo.com>
      126ef649
    • Mayurrajsinh Rathod's avatar
      [FIX] website_slides: prevent copy of a attendee in course · 0991c757
      Mayurrajsinh Rathod authored
      
      Before this commit:
      
      Duplicating the contact that is linked to an attendee of a course also
      creates a copy of an attendee as well.
      
      After this commit:
      
      It does not create duplicate attendee in course.
      
      Task-3253983
      
      closes odoo/odoo#125148
      
      X-original-commit: 13f03853
      Signed-off-by: default avatarThibault Delavallee (tde) <tde@openerp.com>
      0991c757
    • Robin Lejeune (role)'s avatar
      [FIX] web_editor: adapt options' icons in RTL · 53ef2e1a
      Robin Lejeune (role) authored
      
      The triangle pointing towards an option in the editor is pointing
      right. In a RTL setting, this does not make sense and should be
      mirrored.
      
      task-3284274
      
      closes odoo/odoo#125076
      
      X-original-commit: f65a9bff
      Signed-off-by: default avatarQuentin Smetz (qsm) <qsm@odoo.com>
      53ef2e1a
    • Eric Antones's avatar
      [FIX] l10n_ch: a QR report is generated although the option is disabled · 14d78f96
      Eric Antones authored
      
       This takes into account the option that allows to disable/enable the QR file generation
      
       Closes #85283
      
      closes odoo/odoo#125038
      
      X-original-commit: 7b433492
      Signed-off-by: default avatarJohn Laterre (jol) <jol@odoo.com>
      14d78f96
    • David Monjoie's avatar
      [FIX] web_editor: fix html table paste tests · 63123733
      David Monjoie authored
      
      Those tests happened to fail nondeterministically for no apparent
      reason and with multiple different wrong tests results.
      
      Some of those wrong results were particularly striking like having
      completely empty contents, while others looked more like some kind
      of race condition.
      
      Aiming to kill two birds with one stone, I moved the html contents
      of the tests into their very own test file so that no asynchronous
      file loading on the server is done during testing at runtime anymore.
      
      closes odoo/odoo#125020
      
      Signed-off-by: default avatarDavid Monjoie (dmo) <dmo@odoo.com>
      63123733
    • Hamza (hisl)'s avatar
      [FIX] hr_timesheet : update effective_hours for progress_hours computation · 12bdb8e0
      Hamza (hisl) authored
      
      Steps to reproduce the issue:
      
      Add a project and create a task with a timesheet in it
      set the allocated hours to 00:03
      add a line in the timesheet with hours spent 00:03
      Current Behaviour:
      The percentage calculated would be 96%, even though the time allocated and time spent are equal.
      
      Desired Behaviour:
      The percentage should be 100 as both values i.e. time spent and time allocated are equal.
      
      This is happening because effective_hours value is being rounded off to 2 decimal places, and is not accurate enough to compute the progress_hours.
      
      Here, I have used the same line, that is used to compute effective_hours, to compute the task_total_hours but without rounding off. This will make the calculate more precise and accurate.
      
      OPW-3270858
      
      closes odoo/odoo#124892
      
      X-original-commit: 3b1316e7
      Signed-off-by: default avatarXavier Bol (xbo) <xbo@odoo.com>
      12bdb8e0
    • Andrea Grazioso (agr-odoo)'s avatar
      [FIX] point_of_sale: duplicate internal reference in invoice · 4fbcbd2b
      Andrea Grazioso (agr-odoo) authored
      
      Have a product with internal reference
      Open POS session
      Create an order with the product
      Invoice
      
      Issue: Internal reference is shown twice on the invoice line
      
      opw-3343170
      
      closes odoo/odoo#124620
      
      Signed-off-by: default avatarJoseph Caburnay (jcb) <jcb@odoo.com>
      4fbcbd2b
    • Benoit Socias's avatar
      [FIX] *: adapt front-end HTML field sanitization · 6b800ba3
      Benoit Socias authored
      
      *: account, event_booth, gamification, hr, project,
         website_event_track, website_slides
      
      HTML fields that appear in the front-end can be modified using the
      website editor. Some of them are sanitized in a way that breaks the
      behavior of snippets that can be dropped within them.
      
      This commit adapts the sanitization of those HTML fields so that the
      snippets behave as expected.
      
      opw-3267589
      
      closes odoo/odoo#119543
      
      Related: odoo/enterprise#40211
      Signed-off-by: default avatarRomain Derie (rde) <rde@odoo.com>
      6b800ba3
    • Nguyen Viet Phuong's avatar
      [IMP] account: remove label on the views avoid same label. · 9f213748
      Nguyen Viet Phuong authored
      
      closes odoo/odoo#125132
      
      Signed-off-by: default avatarBrice Bartoletti (bib) <bib@odoo.com>
      9f213748
    • Valentin Vallaeys (vava)'s avatar
      [FIX] payment: fallback on transaction partner parent name · 505109d4
      Valentin Vallaeys (vava) authored
      
      In a Sale Order, it is possible to select an invoice address without a
      name. The partner of the transaction does not have a name, which leads
      to a traceback when trying to split the name.
      
      The idea is to force the name to be filled, with a fallback on the
      partner' parent name.
      
      OPW-3338406
      
      closes odoo/odoo#124825
      
      Signed-off-by: default avatarAntoine Vandevenne (anv) <anv@odoo.com>
      505109d4
    • Saurabh Choraria's avatar
      [FIX] event_sms: check model of sms template · a5f345a2
      Saurabh Choraria authored
      
      When notification type is set as sms we need to check whether the template
      which is referenced is coming from a correct model or not.
      
      Applying this commit will fix this issue.
      
      sentry-4195133685
      
      closes odoo/odoo#122026
      
      Related: odoo/enterprise#41322
      Signed-off-by: default avatarThibault Delavallee (tde) <tde@openerp.com>
      a5f345a2
    • arsi's avatar
      [FIX] point_of_sale: add outstanding accounts set in payment methods · c002e6bf
      arsi authored
      
      For a `pos.payment.method`, it is possible to define an outstanding
      account, but if this account is not defined as an outstanding account in
      the company settings nor in the journal, the payment will not be
      considered in the bank reconciliation, nor in the bank reconciliation
      report.
      
      Steps to reproduce (demo-data with POS and Accounting installed):
      -go to 'Point of Sale/Configuration/Payment Methods'.
      -click on the "Bank" payment method.
      -add an 'Outstanding Account' which is not the default outstanding
       account of the company, nor an outstanding account of an
       `account.payment.method.line`.  So for example "Liquidity Transfer".
      -then open a POS session, sell smth, pay with the Bank method, validate,
       then close the session.
      -If you go to 'Accounting/Customers/Payments', you can see that an
       `account.payment` has been created, with the outstanding account being
       "Liquidity Transfer".
      ->It is not possible to reconcile that payment with a
       `account.bank.statement.line`. If you go to the accounting dashboard,
       then click the reconcile button of the journal "Bank", then on a
       statement line with no partner, you will not see the outstanding line
       of that payment.
      ->If you open the 'Reconciliation Report' of the journal "Bank"
       (accessible from the journal dashboard, by clicking the options of the
       journal), the line will not show in the 'Outstanding Receipts'
       category.
      
      FIX:
      Override the `_get_journal_inbound_outstanding_payment_accounts`
      method of `account.journal`, to add the accounts from each
      `pos.payment.method` linked to the journal.  Using the field
      `pos_payment_method_ids` from `account.journal`.
      
      opw-3271090
      
      closes odoo/odoo#121158
      
      Signed-off-by: default avatarJoseph Caburnay (jcb) <jcb@odoo.com>
      c002e6bf
    • Benjamin Vray's avatar
      [FIX] website: fix the scrolling of table of content in website slides · b9324016
      Benjamin Vray authored
      
      Steps to reproduce the bug:
      
      - Install the Website Slides module.
      - Got to the /slides page.
      - Click on a course.
      - Click on the "Add Content" button.
      - Choose "Web Page" in the modal.
      - Once in edit mode, drag and drop a "Table of Content" snippet onto the
      page.
      - Save the page.
      - Scroll the page and observe that the navbar items are updated as you
      scroll.
      - Click on the "Fullscreen" button.
      - Bug: When scrolling the page, the navbar items are no longer updated
      as you scroll.
      
      This commit fixes the issue by detecting the scrolling element by
      traversing up the ancestors from the 'table of content' snippet, instead
      of using the 'getScrollingElement' function, which always returned the
      '#wrapwrap' when a Website Slides page is in fullscreen.
      
      opw-3302118
      
      closes odoo/odoo#124893
      
      X-original-commit: 1ac274c3
      Signed-off-by: default avatarRomain Derie (rde) <rde@odoo.com>
      Signed-off-by: default avatarVray Benjamin (bvr) <bvr@odoo.com>
      b9324016
    • Benoit Socias's avatar
      [FIX] web_editor: fix border width options on zoomed browser · 74dceaf8
      Benoit Socias authored
      
      When the browser is zoomed, the value of the `border-width` CSS
      properties obtained through `getComputedStyle` are impacted by the
      zoom. Because of this, entering a "10px" border in a Chrome zoomed at
      125% turns it into "9.6px" when leaving the input field.
      
      This commit neutralizes the zoom effect by rounding the value up.
      The rounding operation was empirically determined by observing values,
      see table below.
      
      When zoomed out this does not always work: e.g. at 50% zoom, a value
      of 11px becomes 10px. But zooming out is an unxpected use case, that
      situation is therefore not handled by this fix.
      
      Observed values of the border-width property:
      Set value => `getComputedStyle`
      ```
      Value  Chrome 125%  Firefox 120%
        1px        0.8px     0.83333px
        2px        1.6px     1.66667px
        3px        2.4px     2.50000px
        4px        4.0px     3.33333px
        5px        4.8px     5.00000px
        6px        5.6px     5.83333px
        7px        6.4px     6.66667px
        8px        8.0px     7.50000px
        9px        8.8px     8.33333px
       10px        9.6px    10.00000px
       11px       10.4px    10.83333px
       12px       12.0px    11.66667px
      ```
      
      Steps to reproduce:
      - Drop a "Text - Image" block.
      - Select the text column.
      - Zoom with ctrl+mouse wheel or ctrl-plus.
      - Set a 10px border.
      - Leave input field.
      
      => Border option field displayed a different size.
      
      task-3172235
      
      closes odoo/odoo#125068
      
      X-original-commit: 6398b0c7
      Signed-off-by: default avatarQuentin Smetz (qsm) <qsm@odoo.com>
      Signed-off-by: default avatarBenoit Socias (bso) <bso@odoo.com>
      74dceaf8
    • Thomas Lefebvre (thle)'s avatar
      [FIX] website_hr_recruitment: prevent applying for unpublished job · 547355a5
      Thomas Lefebvre (thle) authored
      
      Issue:
      ------
      When we have the link to the form to apply for a job,
      even if the job is not published, we can still apply.
      
      Solution:
      ---------
      Check that the job is published before the creation of the record
      in the `website_form_input_filter`.
      
      opw-3331717
      
      closes odoo/odoo#124987
      
      X-original-commit: 508f373f
      Signed-off-by: default avatarKevin Baptiste <kba@odoo.com>
      Signed-off-by: default avatarLefebvre Thomas (thle) <thle@odoo.com>
      547355a5
  6. Jun 14, 2023
Loading