Skip to content
Snippets Groups Projects
  1. Aug 07, 2022
  2. Aug 05, 2022
    • Leo Tran's avatar
      [CLA] Viindoo updates Odoo's CLA · a362257e
      Leo Tran authored
      
      closes odoo/odoo#97569
      
      X-original-commit: 8ba0c300
      Signed-off-by: default avatarMartin Trigaux (mat) <mat@odoo.com>
      a362257e
    • Nshimiyimana Séna's avatar
      [FIX] sale: set correct invoice status · c7dd2815
      Nshimiyimana Séna authored
      
      Steps to reproduce:
      - Create a quotation
      - Add a product that is invoiced on "ordered quantities" and set the
        quantity to a negative number.
      - Leave 'delivered' to 0
      - Confirm the quotation
      - Create the Invoice and validate it.
      - Go to the SO list view (Orders > Orders)
      
      You should see that the Invoice Status of the order you just created is
      'Upselling Opportunity', which is not correct.
      
      Why this is happening:
      
      Here's an explanation on the 'Upselling Opportunity' state (found in
      the code):
      " upselling: this is possible only for a product invoiced on ordered
      quantities for which *we delivered more than expected.* "
      
      In our case, the invoice line's state is set to 'upselling'
      because we have a negative ordered quantity and a zero delivered
      quantity (i.e. we delivered more than expected)
      
      opw-2895218
      
      closes odoo/odoo#97555
      
      X-original-commit: 8480ce07
      Signed-off-by: default avatarNshimiyimana Serge Séna (sesn) <sesn@odoo.com>
      c7dd2815
    • dbkosky's avatar
      [FIX] l10n_it_edi: IT Company pa index demo data · 42c08b29
      dbkosky authored
      
      In order to perform reverse charge self-invoicing, a company must have
      its codice destinario (pa index) defined. This commit adds a valid
      pa_index (from the sdicoop test channel) to the demo company.
      
      closes odoo/odoo#97572
      
      Signed-off-by: default avatarJosse Colpaert <jco@odoo.com>
      42c08b29
    • Abdelouahab (abla)'s avatar
      [FIX] account : remove QR code method for credit note · 039bf8c5
      Abdelouahab (abla) authored
      
      To reproduce
      ============
      
      Enable "Qr Codes" under Accounting Settinsgs > Create Invoice > set "Payment QR-code" method (tab "More Info")
      > issue Credit Note > try to "Send and Print" credit note > Error:
      
      ` The chosen QR-code type is not eligible for this invoice. `
      
      Specification
      =============
      
      Generating QR code on Credit Note doesn't make sense, so the field `qr_code_method` is set to `False`
      when creating a Credit Note.
      
      opw-2900112
      
      closes odoo/odoo#97018
      
      Signed-off-by: default avatarJosse Colpaert <jco@odoo.com>
      039bf8c5
    • Guillaume (guva)'s avatar
      [FIX] l10n_it_edi: fiscal code format · 262eb7bd
      Guillaume (guva) authored
      
      According to
      www.agenziaentrate.gov.it/portale/web/guest/schede/istanze/richiesta-ts_cf/informazioni-codificazione-pf
      
      The tax identification number of natural persons
      consists of an alphanumeric expression of sixteen characters.
      
      The first fifteen characters are indicative of the master data
      of each individual in the following order:
      
      - 3 alphabetic characters for the surname;
      - 3 alphabetic characters for the first name;
      - 2 numeric characters for the year of birth;
      - 1 alphabetic character for the month of birth;
      - 2 numeric characters for the day of birth and sex;
      - 4 characters, 1 alphabetic and 3 numeric for the Italian municipality
        or foreign state of birth.
      The sixteenth character, alphabetic, serves as a control.
      
      The main fix is about this part:
      
      When two or more individuals have master data generating
      the same tax code (homocodes), the tax code is differentiated
      for each of them. For this purpose, systematic substitutions
      of one or more digits starting from the right one are made
      within the seven numeric characters contained in the code
      with corresponding alphabetic characters according to the
      following table:
      
      0 = L 4 = Q 8 = U
      1 = M 5 = R 9 = V
      2 = N 6 = S
      3 = P 7 = T
      
      Also the check for iva number format was incomplete.
      Indeed, The three penultimate digits correspond to the region of the
      VAT office and must be between 001 and 100 inclusive,
      or equal to 120, 121, 888 or 999.
      
      We use the stdnum library's methods for the validation of fiscal code
      and iva number format.
      
      opw-2797408
      
      closes odoo/odoo#95594
      
      Signed-off-by: default avatarJosse Colpaert <jco@odoo.com>
      262eb7bd
    • dbkosky's avatar
      [FIX] l10n_it_edi: negative template values for reverse charge refunds · ca2f4c8e
      dbkosky authored
      
      When issuing a refund for a reverse charge bill, the document type
      should be the same as the parent bill type (either TD16, TD17 or TD18,
      rather than TD04), and the values of the lines and totals should be
      negative.
      
      To fix this the values are made negative dependent upon whether the
      invoice is a 'rc_refund' as in a "reverse charge refund". The way that
      the document type is ascertained is also changed in order to include the
      'in_refund' (for the case of the reverse charge refund).
      
      The way document_total (ImportoTotaleDocumento) has been made
      conditionally negative in the case when the invoice is a reverse charge
      refund.
      
      A test has been added for the reverse charge refund case, and the test
      taxes have been adapted so that the correct tags are being used (and so
      that tags are used on the refund lines).
      
      closes odoo/odoo#97263
      
      Ticket-id: 2936967
      Signed-off-by: default avatarJosse Colpaert <jco@odoo.com>
      ca2f4c8e
    • clementmbr's avatar
      [FIX] purchase_stock: avoid updating kit components price_unit · d0537e32
      clementmbr authored
      
      closes odoo/odoo#97503
      
      Signed-off-by: default avatarWilliam Henrotin (whe) <whe@odoo.com>
      d0537e32
  3. Aug 04, 2022
    • Hubert Van de Walle (huvw)'s avatar
      [FIX] web: parseMonetary with NBSP as a thousands separator · abaa3756
      Hubert Van de Walle (huvw) authored
      Steps to reproduce:
      
        - Switch odoo language to french
        - Create a client bill for Azure Interior of $1 000 000
        - Confirm it
        - Go to the accounting dashboard
        - On the bank, click on reconcile
        - Select Azure interior
        - Click on the correct bill
        - Switch to Manual operations
        -> $1 000 000 is not a correct monetary field
      
      Cause of the issue:
      
        Recently in https://github.com/odoo/odoo/pull/94126
      
       , `formatMonetary`
        switched from joining the currency and symbol from `&nbsp;` to a non
        breaking space, NBSP.
        To parse monetary values, the behavior was to split around NBSP to
        get the symbol on one side and the value on the other which is then
        passed to `parseFloat`.
      
        For the following examples, NBSP is replaced with an underscore.
        So `$_1000` becomes `$, 1000`
        But some languages such as french uses the same char as thousands
        separator.
      
        In that case, `$_1_000` becomes `$, 1, 000` and then the parse fails.
      
      opw-2937403
      
      closes odoo/odoo#97462
      
      X-original-commit: 9d367227
      Signed-off-by: default avatarJorge Pinna Puissant (jpp) <jpp@odoo.com>
      Signed-off-by: default avatarHubert Van De Walle <huvw@odoo.com>
      abaa3756
    • Audric Onockx (auon)'s avatar
      [FIX] base: address operation context keys in calendar view · 8d108f32
      Audric Onockx (auon) authored
      
      Prior this fix, creating an action with (e.g.)
      additional_context : {create: 0} wouldn't have any effect
      on calendar view.
      
      Now, if this context key is added, the user won't be able to create.
      Also true for delete and write.
      
      closes odoo/odoo#97022
      
      Signed-off-by: default avatarLaurent Stukkens (ltu) <ltu@odoo.com>
      8d108f32
    • Florian(flg)'s avatar
      [FIX] l10n_be: change tab to space · a674e687
      Florian(flg) authored
      
      This old file is indented with tabs instead of spaces.
      This is a problem because the file is using as template to
      write new localization.
      
      closes odoo/odoo#97452
      
      X-original-commit: 56f9e90d
      Signed-off-by: default avatarJosse Colpaert <jco@odoo.com>
      Signed-off-by: default avatarFlorian Gilbert (flg) <flg@odoo.com>
      a674e687
    • Pierre Paridans's avatar
      [FIX] web: don't hide datepicker on scroll for iOS · a233cfe2
      Pierre Paridans authored
      
      This commit fixes a glitch on iOS (both iPhone & iPad landscape) where,
      when the user attempts to open the datepicker of a custom filter's
      field, it pops up and immediately close.
      
      This is due to the desktop behavior which hides datepickers on scroll to
      avoid hidding fields behind it.
      
      In our case, a scroll is triggered once the focus is set in the date's
      input and the virtual keyboard opens up... which then hides the
      datepicker!
      
      Sadly, this behavior's purpose being still useful in desktop, we don't
      have much other solution than "just" disabling it on affected platforms
      (ie. iOS) as it affects both small screens (ie. iPhones) and
      dekstop-like ones (ie. iPad).
      
      Hopefully, a better solution will be found at some point in a future
      version, avoiding this kind of "trick"...
      
      Note: replacing the "scroll" event with the "wheel" event seems to fix
      the issue at first glance... but actually has side-effects for devices
      using both touchscreens and a mouse (ie. 2-in-1 laptops).
      
      Steps to reproduce:
      - Open any collection view (list, kanban...)
      - Open "Filter" dropdown and add a custom filter
      - Choose a date/datetime field (ie. created_on)
      - Tap the input
      => datepicker opens up and close immediately
      
      opw-2671618
      opw-28192998
      
      closes odoo/odoo#97467
      
      Signed-off-by: default avatarAdrien Dieudonné (adr) <adr@odoo.com>
      a233cfe2
    • Romain Derie's avatar
      [FIX] website: correctly show language dropdown in rtl langs · f3a19057
      Romain Derie authored
      Before this commit, the lang entries in the language switcher's dropdown
      would overflow the dropdown (which was way too small).
      
      There were no issue in 13.0 as the issue seems to have appeared since
      commit [1] which was merged in 14.0 (13.5 at the time).
      That commit added a `min-width: 0;` on the `.dropdown-menu` making the
      dropdown visually broken in rtl languages.
      
      There is no issue in saas-15.5 (current master) as it was converted to
      BS5 where the issue do not appear.
      
      There is probably a cleaner solution to be found to have a full
      understanding of the real issue and probably make a generic solution
      instead of only fixing footer language selector, but this would need to
      spend more time investigating the issue.
      As the error seems gone with BS5 anyway, and only this dropdown seems to
      be impacted, this is a reasonable fix.
      
      [1]: https://github.com/odoo/odoo/commit/745ef9de97544d5c1a97e03be67e903feca40c2a
      
      
      
      Fixes #64774, fixes #63764
      opw-2904798
      
      closes odoo/odoo#96455
      
      Signed-off-by: default avatarRomain Derie (rde) <rde@odoo.com>
      f3a19057
  4. Aug 02, 2022
    • Vikash Tiwari's avatar
      [FIX] mrp: set default `Operation Type` in picking · b28c44a3
      Vikash Tiwari authored
      
      Purpose
      ======
      When creating a specific Operation Type of type 'Manufacture' the default
      operation type is not the correct one on object creation.
      
      So in this commit, we set default `Operation Type` in picking when Type of
      Operation is `Manufacture`.
      
      taskID - 2939078
      
      closes odoo/odoo#97299
      
      Signed-off-by: default avatarWilliam Henrotin (whe) <whe@odoo.com>
      b28c44a3
    • qsm-odoo's avatar
      [FIX] web_editor: fix the look of the indent symbol in the editor panel · bc19050d
      qsm-odoo authored
      
      As a stable fix, to not touch XML templates and break existing
      translations, the ⌙ character is automatically replaced by └ which makes
      more sense for the usecase and should work properly in all browsers. The
      ⌙ character is actually rendered mirrored on Windows 11 Chrome (and
      others) as the font used for those unicode characters is left to the
      browser. We could force a font of our own but it's probably not worth it.
      
      A better solution with a SVG or CSS solution has to be done in master.
      That would unify the look of the symbol across all browsers and
      also prevent special characters to be placed in translations.
      
      closes odoo/odoo#97338
      
      Signed-off-by: default avatarRomain Derie (rde) <rde@odoo.com>
      bc19050d
    • Luis González's avatar
      [FIX] mass_mailing: btn to select template not hidden in other languages · a91dcadb
      Luis González authored
      
      The button to select a template when using the editor was hidden on
      a012019c because it was deemed useless. However, the way to determine
      what button to hide relies on the button text, which doesn't work when
      we're on a different language.
      
      To solve the above, button is now identified by other attributes
      (tabindex and accesskey).
      
      closes odoo/odoo#93768
      
      Signed-off-by: default avatarMartin Trigaux (mat) <mat@odoo.com>
      a91dcadb
    • Ahmad Khanalizadeh's avatar
      [FIX] point_of_sale: use taxed prices in discount comparison · a182ef31
      Ahmad Khanalizadeh authored
      
      Before this commit, If "Show public price & discount to the customer"
      discount display policy is selected, taxed prices in the pricelist with
      discounts are compared with untaxed prices in the public pricelist,
      which leads to not showing the discounted values when the pricelist
      value is less than untaxed list price, but the taxed value is more than
      untaxed list price.
      
      Steps to reproduce:
      
      1. Create a product, add it to a pricelist with a lower price in a way
       that if the tax is added the price is more than its sale price, add a
       tax option to the product
      2. Set the pricelist discount display policy as `Show public price &
      discount to the customer`
      3. Set the PoS to use tax-included prices, and to use the discounted
      pricelist
      4. start the PoS session, add the product, you will see that the
      public price isn't shown (with a strike-through)
      
      To fix, we can use a different function that computes the taxed public
      price, so it could be compared with the pricelist price.
      
      opw-2919734
      
      closes odoo/odoo#96749
      
      Signed-off-by: default avatarJoseph Caburnay (jcb) <jcb@odoo.com>
      a182ef31
    • Nicolas Seinlet's avatar
      [FIX] stock_dropshipping: lack of picking type · dd9a9d54
      Nicolas Seinlet authored
      
      Sometimes, no picking type match the domain, but picking_type_id is a required field.
      
      closes odoo/odoo#97250
      
      X-original-commit: afcad067
      Signed-off-by: default avatarWilliam Henrotin (whe) <whe@odoo.com>
      dd9a9d54
    • Florian Vranckx's avatar
      [FIX] product : pricelist rules archiving · e0e2ab59
      Florian Vranckx authored
      
      backport of  #85323
      
      closes odoo/odoo#97242
      
      X-original-commit: 01feeb84
      Signed-off-by: default avatarVranckx Florian (flvr) <flvr@odoo.com>
      Co-authored-by: default avatarauon-odoo <auon@odoo.com>
      e0e2ab59
  5. Aug 01, 2022
    • Andrea Grazioso (agr-odoo)'s avatar
      [FIX] l10n_it_edi: attachments from xml missing res_model/res_id · 377e8eed
      Andrea Grazioso (agr-odoo) authored
      
      Install Documents
      Open Settings > Documents, enable 'Accounting' files centralization
      Configure 'Journals' with a single line
      - Journal -> Vendor Bills
      - Workspace -> Finance / Supplier Invoices
      Now in go to Accounting>Vendor>Bills
      Upload an xml representing a vendor bill, including an attachment
      encoded in the <Allegati> tag
      Open created bill
      
      Traceback. The error is caused by the attachment included in the xml
      registered without res_id/res_model.
      In the document flow the attachment will receive a res_id, but not the
      res_model, causing the traceback when retrieving the attachment
      
      opw-2919610
      
      closes odoo/odoo#97061
      
      Signed-off-by: default avatarJosse Colpaert <jco@odoo.com>
      377e8eed
    • Alejandro Santillan's avatar
      [IMP] website_sale_stock: facilite inheritance _cart_update behavior · 94ffec7b
      Alejandro Santillan authored
      It is currently impossible to modify the _cart_update behavoiur from website_sale_stock
      
      The sale.order method _cart_update() updates the lines on the e-commerce shop
      cart, some modules override the method adding new features, the module
      website_sale_stock is one of them.
      
      The specific behavior of _cart_update() in the module website_sale_stock allows
      to delete from the sale order the products whose demand is greater than the stock.
      
      If the specific behavior of the module website_sale_stock is needed to be
      expanded or totally changed, that is not possible because the method _cart_update()
      should be always super called, even if the website_sale_stock code for
      _cart_update will be totally changed.
      
      To allow inheriting just the specific behavior of website_sale_stock without
      affecting other modules. This commit creates a new method _cart_lines_stock_update()
      which have the important behavior for this module and will allow to be
      easier to inherit it.
      
      Based on: https://github.com/odoo/enterprise/commit/f5d92e70aaa472324cc1f0374ddb108d100bec59
      
      
      
      OPW#2500355
      
      closes odoo/odoo#97195
      
      X-original-commit: 1e3adbf6
      Signed-off-by: default avatarWilliam Braeckman (wbr) <wbr@odoo.com>
      94ffec7b
    • Alvaro Fuentes's avatar
      [FIX] stock: fix KeyError for archived warehouses · aaa7fb8f
      Alvaro Fuentes authored
      The below line raises a KeyError when `warehouse` refers to an archived
      warehouse.
      https://github.com/odoo/odoo/blob/01cc43b0578ecc9d1fed37a12b2468ffc9d4aedd/addons/stock/models/stock_orderpoint.py#L396
      
      The reason is that the SQL view created on
      https://github.com/odoo/odoo/blob/01cc43b0578ecc9d1fed37a12b2468ffc9d4aedd/addons/stock/report/report_stock_quantity.py#L28-L37
      
      
      doesn't take into account whether the warehouses are archived or not.
      
      The solution proposed here is to fetch all warehouses to ensure the
      lookup doesn't fail. Alternatively the view could be updated but that
      will be a bigger change.
      
      This issue was detected during the upgrade 226754
      
      closes odoo/odoo#88204
      
      Signed-off-by: default avatarWilliam Henrotin (whe) <whe@odoo.com>
      aaa7fb8f
    • Adrien Widart's avatar
      [FIX] stock: get product qty in specific location · 1bd8c15c
      Adrien Widart authored
      When getting the on hand quantity of a product in a specific location,
      the result may be incorrect.
      
      To reproduce the issue:
      1. In Settings, enable "Storage Locations"
      2. Create a storable product P
      3. Update its quantity:
          - 5 x P at WH/Stock/Shelf 1
      4. Inventory > Reporting > Inventory Report
      5. Apply the following filters:
          - Product: P
          - Location: WH/Stock/Shelf 1
          - => There is a line with 5 x P at WH/Stock/Shelf 1, which is
      correct
      6. Click on Inventory at Date, set <Today>, confirm
      7. Apply the following filters:
          - Product: P
          - Location: WH/Stock/Shelf 1
      
      Error: There is a line for P but its on hand quantity is 0, which is
      incorrect (should be 5)
      
      In the first search, we let the ORM handle the domain conversion. When
      searching for `('location_id', 'ilike', 'WH/Stock/Shelf 1')`, it will
      use the `_rec_name` of the model to find the record. In case of a stock
      location, its `_rec_name` is the field `complete_name`:
      https://github.com/odoo/odoo/blob/94a8ad3fae914b046064bb7ce17572be8280f6e0/addons/stock/models/stock_location.py#L19
      
      
      
      However, for the second search, when getting the on-hand quantity of the
      product, we force the use of the field `name` to find the location.
      Because the `name` of the searched location is "Shelf 1", using
      "WH/Stock/Shelf 1" as key search will not work.
      
      OPW-2920904
      
      closes odoo/odoo#97091
      
      X-original-commit: 9a651e13
      Signed-off-by: default avatarWilliam Henrotin (whe) <whe@odoo.com>
      Signed-off-by: default avatarAdrien Widart <awt@odoo.com>
      1bd8c15c
    • Kevin Baptiste's avatar
      [FIX] google_drive: fix deprecation date check · 0a6689ea
      Kevin Baptiste authored
      
      Original PR: #96572
      
      closes odoo/odoo#97168
      
      X-original-commit: 5a53d0d6
      Signed-off-by: default avatarKevin Baptiste <kba@odoo.com>
      0a6689ea
    • Andrea Grazioso (agr-odoo)'s avatar
      [FIX] account: reconciliation of 0 balance line in automatic entry · 2433d5da
      Andrea Grazioso (agr-odoo) authored
      
      Open Accounting>Journal Items
      Select 1+ items with 0 credit/debit
      Hit Actions>Automatic Entries
      In the wizard choose 'Change Period', select an Accrued Account with
      'reconcile' flag and confirm
      
      Error will raise 'You are trying to reconcile some entries that are
      already reconciled.'
      This occurs because new entries, with 0 balance, will be created to match
      the selected one. The flow include a reconciliation step in which the 0
      balance will raise the error.
      
      With this patch the problematic lines will be created but not reconciled
      
      opw-2909058
      
      closes odoo/odoo#96733
      
      Signed-off-by: default avatarGrazioso Andrea (agr) <agr@odoo.com>
      2433d5da
    • mafo-odoo's avatar
      [FIX] sale,l10n_de_sale: Add the proforma in the title for din5008 sale report · 157ef2bf
      mafo-odoo authored
      
      Step to reproduce:
      	- install sale, accounting and l10n_de
      	- activate proforma in sale settings
      	- set the template to external_layout_din5008 in the settings (use developer mod)
      	- create sales order or quotation
      	- print it as a proforma
      
      Current behavior:
      	- the proforma is missing from the title in the document
      
      Behaviour after PR:
      	- the proforma is in the document title
      
      The l10n_de_sale module was missing the case scenario of a proforma sales report and the sale module only
      gives the information of a proforma report in the xml context. Then we add the case scenario and propagate
      the proforma info from the sale module also in the python context using the proforma variable.
      
      opw-2796603
      
      backport of bb9db7e2c95a161b240977baf4e526c5b03c5842
      
      closes odoo/odoo#97039
      
      Signed-off-by: default avatarJosse Colpaert <jco@odoo.com>
      157ef2bf
  6. Jul 31, 2022
  7. Jul 30, 2022
  8. Jul 29, 2022
  9. Jul 28, 2022
    • Nasreddin Boulif (bon)'s avatar
      [FIX] website_sale: fix tests · 0ab552a7
      Nasreddin Boulif (bon) authored
      
      Steps to reproduce:
      
        Create a new DB with `-i l10n_ar_website_sale` and `--test-enable`
      
      Issue:
      
        Multiple test fails.
      
      Cause:
      
        By installing only a l10n module, main company will be altered
        (espcialy the fiscal country and currency among other things).
        By doing so, it will raise at least 2 issue:
        - Previous pricelists linked to main company got the previous currency
        - Some fields can be required (depending company fiscal country)
      
      Solution:
      
        - Alter company's website pricelist currency to match company currency
        - Reset country and fiscal country, so that fields added by
          localizations are hidden and non-required.
          Also remove default taxes from the company and its accounts,
          to avoid inconsistencies with empty fiscal country.
      
      opw-2767684
      
      closes odoo/odoo#96887
      
      Signed-off-by: default avatarNasreddin Boulif (bon) <bon@odoo.com>
      0ab552a7
    • Yas-Elak's avatar
      [FIX] payulatam: error when amount is more than 2 decimals · bbb987ed
      Yas-Elak authored
      
      When redirected to the payment acquirer PayuLatam, if the amount is more than 2
      decimals we can have two errors (invalid sign and unique reference).
      Even with the decimal accuracy set to 2, we still can have a rounding issue and get
      an amount like 1661.340000001
      
      fixes opw-2900105
      
      closes odoo/odoo#96974
      
      X-original-commit: deaf27a7
      Signed-off-by: default avatarAntoine Vandevenne (anv) <anv@odoo.com>
      bbb987ed
    • Florian(flg)'s avatar
      [FIX] account: Remove useless check on bank statement button post. · b1b66f71
      Florian(flg) authored
      
      As we allow editing balances in processing state, we do not want
      to check balances before the validation of the bank statement
      (only in case of a bank journal).
      Commit about editing balances: 03f83eb8
      This fix split the _check_balance_end_real_same_as_computed into
      2 functions. One to check "bank" bank statement and one to check
      "cash" bank statement. It allows to keep the same behavior for
      a "cash" bank statement when we post the bank statement, and
      having the right behavior for a "bank" bank statement.
      
      opw-2835728
      
      closes odoo/odoo#96829
      
      Signed-off-by: default avatarLaurent Smet <las@odoo.com>
      b1b66f71
  10. Jul 27, 2022
Loading