Skip to content
Snippets Groups Projects
  1. Feb 01, 2021
    • Christophe Monniez's avatar
      [FIX] packaging: add a bom to nsi script · ca5f1f61
      Christophe Monniez authored
      
      When using the windows installer in French language, the `Hôte` label
      used to configure postgresql server does not display correctly.
      
      The LangString documentation does not specify how to use the special
      characters but after some tests, specifying a BOM for the nsi file seems
      to be the way to go.
      
      closes odoo/odoo#65370
      
      X-original-commit: 3d0871d1
      Signed-off-by: default avatarChristophe Monniez (moc) <moc@odoo.com>
      ca5f1f61
    • Nicolas (vin)'s avatar
      [IMP] account: Improve distinction between payment and bank statement · 164c467c
      Nicolas (vin) authored
      
      Increase the distinction between a journal entry linked to a bank
      statement line and another one linked to a payment by adding a smart
      button linked to them.
      
      Also improve the navigation from the Bank And Cash view to directly
      open the linked bank statement line or payment.
      
      Task id #2448618
      
      closes odoo/odoo#65316
      
      Signed-off-by: default avatarWilliam André (wan) <wan@odoo.com>
      164c467c
    • fw-bot's avatar
      [FIX] website, website_sale: preconfigure Dynamic Products w/ 1st option · 6ce10faf
      fw-bot authored
      
      Before this commit the Dynamic Products snippet was displaying a message
      box instead of its content until its template and product category were
      selected.
      
      After this commit the Dynamic Products snippet is automatically
      configured on drop with the first available template and the first
      available product category. The message box only appears if no product
      category exists yet. Also an "All Products" category was added as first
      element of the list to make the snippet usable before categories are
      defined.
      
      task-2439295
      
      closes odoo/odoo#65342
      
      X-original-commit: db3ced474e44b5a8188f0d77521bfcaee2575060
      Signed-off-by: default avatarJérémy Kersten (jke) <jke@openerp.com>
      6ce10faf
    • Nicolas Lempereur's avatar
      [FIX] im_livechat: smiley feedback correspond to choice · 7dc1552c
      Nicolas Lempereur authored
      When a user on website sends livechat feedbacks:
      
      - Good -> send an average smiley :neutral_face:
      - Average -> send ?? instead of smiley
      
      This is because in e4a4ffb9 value of good (:blush:) was changed from 10 to 5,
      and value for average (:neutral_face:
      
      ) was changed from 5 to 3, but it was not
      reflected in one part of the code.
      
      opw-2447246
      
      closes odoo/odoo#65338
      
      X-original-commit: 45ea88e5
      Signed-off-by: default avatarNicolas Lempereur (nle) <nle@odoo.com>
      7dc1552c
    • dht-odoo's avatar
      [IMP] website_event[_track]: allow to show/hide tag categories on website · 7087a168
      dht-odoo authored
      
      In backend, we may want to use tags for advanced use cases like reporting,
      filtering, aggregating in spreadsheet, ... However right now we cannot
      define tag categories dedicated for 'internal use only'.
      
      Similar to eLearning, this commit introduces facility to decide whether or
      not to show the tag categories on the website. It is based on website.published
      mixin. is_published field will be used for taht purpose. ACLs are updated
      accordingly. If the category is hidden from the website then it is used for
      internal purpose only.
      
      In order to make all the events menu together, this commit moves the
      'Event Tags Categories' menu after 'Event Stages'.
      
      COM PR odoo/odoo#63485
      UPG PR odoo/upgrade#2088
      Task Id-2300230
      
      Signed-off-by: default avatarThibault Delavallee (tde) <tde@openerp.com>
      7087a168
    • Olivier Dony's avatar
      [FIX] registry: prevent inherited phantom cache clears · 12225d5c
      Olivier Dony authored
      
      This patch complements the previous one by ensuring that any
      `cache_invalidated=True` flag inherited from the master process
      (pre-fork mode) cannot trigger a cache clear.
      
      This could occur when the first request is served, because the flag was
      never clear in the master process, which never server any request.
      
      At the end of `check_signaling()`, the local cache has either been
      cleared because a (real) increment of the cache sequence was detected,
      or it is considered still valid. The final state of the
      `cache_invalidated` flag should reflect this, by being `False`.
      
      closes odoo/odoo#65346
      
      X-original-commit: 3585c2c3
      Signed-off-by: default avatarRaphael Collet (rco) <rco@openerp.com>
      12225d5c
    • Olivier Dony's avatar
      [FIX] registry: do not signal a phantom cache clear on load · 654052d5
      Olivier Dony authored
      During loading, the registry clears all `ormcache` data multiple
      times, in order to ensure consistency with the newly loaded module
      data.
      
      Since 083c70bb, this was done by
      calling `self.clear_caches()`, with the side-effect
      of signalling to all other worker processes that the cache
      *needs* to be invalidated, which is actually untrue.
      
      If the other workers have any reason to reload their own registries,
      they will also clear their own cache in the process - there is no
      need to forcefully invalidate it globally.
      
      One could think that combining the pre-fork mode with the `-d <db>`
      parameter would mitigate this issue, by making all workers inherit from
      a fully loaded registry, In reality it doesn't work, because they also
      inherit from the `cache_invalidated=True` flag, that was never cleared
      in the master process. So despite having a fully loaded registry, the
      newly forked workers will signal a cache invalidation upon serving
      their first request.
      
      Further, in a multi-tenant setup with large numbers of databases,
      registries may be recycled and loaded much more frequently than
      new workers are starting, due to the limited registry LRU, amplifying
      this effect a bit.
      
      ~~
      
      This patch directly clears the cache LRU without going through
      `clear_cache()`, avoiding setting the `cache_invalidated` flag of the
      registry, and thus not signalling to other workers.
      
      This is similar to what was being done before 083c70bb,
      where the LRU was dropped like all other lazy properties.
      
      X-original-commit: 87aef4e3
      654052d5
    • Anh Thao Pham (pta)'s avatar
      [FIX] pos_cash_rounding: fix cash rounding for cash method only · ccf5f070
      Anh Thao Pham (pta) authored
      
      - Go to Point of Sale > Configuration > Settings & enable "Cash Rounding"
      - Configure POS:
        * Enable Invoicing
        * Enable "Cash Rounding" and "Only on cash methods"
        * Select 0.05 HALF-UP Rounding Method
      - Start POS session
      - Select a Product and change its Price to a value that should be rounded (i.e. $ 16.51)
      - Select a Customer
      - Proceed to Payment
      - Enable Invoice
      - Select Bank Payment method
      - Validate
      No rounding is applied as expected, but the rounding line still appears on printed Invoice.
      
      opw-2449222
      
      closes odoo/odoo#65345
      
      X-original-commit: d207a0fb
      Signed-off-by: default avatarpimodoo <pimodoo@users.noreply.github.com>
      Signed-off-by: default avatarAnh Thao PHAM <kitan191@users.noreply.github.com>
      ccf5f070
    • Odoo's Mergebot's avatar
      [MERGE] partner_autocomplete: enrich user companies · 48eacdb7
      Odoo's Mergebot authored
      
      In order to make a wow effect right after DB install we enrich the base
      company based on the given email address or company website at install.
      In order to achieve that goal we use the partner_autocomplete service from
      IAP. It uses free credits that are offered to new clients on saas platform.
      
      Only the fields that are not filled yet are enriched to avoid erasing user
      entered data, except logo. Indeed as partner_autocomplete is probably installed
      as a core app (mail -> iap -> partner_autocomplete auto install chain) it is
      unlikely that people already updated their company logo.
      
      We consider that having a call to IAP consuming a token is ok for a standard
      use case, especially that
      
        * if no iap service is configured call to IAP won't add much timing;
        * on Odoo SaaS free credits are given and company is enriched;
        * on custom SaaS with custom iap service, at db creation probably no
          credits are given and call will simply give no results back;
      
      We decided to call IAP asynchronously at client web load. Session combined to
      a boolean field on company model allows to do this call only once per company.
      Doing this allows to avoid adding yet another post init hook. It also eases
      behavior tweak through inheritance.
      
      This call is limited to admin for obvious security reasons as well as
      performance reason (limiting calls to external providers). As call will be
      done once per company generally admin is the first person to log into the
      its newly created Odoo.
      
      In addition to enriching companies on the fly, we also enrich companies
      when creating them. It allows to have an enrich on companies existing
      before using autocomplete, and have results of enrich directly at create
      for companies created after installing this module.
      
      LINKS
      
      Task ID-2322455
      PR odoo/odoo#64600
      PR odoo/upgrade#2086
      
      Signed-off-by: default avatarThibault Delavallee (tde) <tde@openerp.com>
      Co-authored-by: default avatarDavid Beguin <dbe@odoo.com>
      Co-authored-by: default avatarThibault Delavallee <tde@odoo.com>
      48eacdb7
    • Thibault Delavallée's avatar
      [IMP] partner_autocomplete: enrich companies at creation · 1b00a0b5
      Thibault Delavallée authored
      
      In addition to enriching companies on the fly, we also enrich companies
      when creating them. It allows to have an enrich on companies existing
      before using autocomplete, and have results of enrich directly at create
      for companies created after installing this module.
      
      LINKS
      
      Task ID-2322455
      PR #64600
      PR odoo/upgrade#2086
      
      Co-Authored-By: default avatarDavid Beguin <dbe@odoo.com>
      Co-Authored-By: default avatarThibault Delavallee <tde@odoo.com>
      1b00a0b5
    • Aline Preillon's avatar
      [IMP] partner_autocomplete: automatically enrich user companies · 97f29578
      Aline Preillon authored
      
      In order to make a wow effect right after DB install we enrich the base
      company based on the given email address or company website at install.
      In order to achieve that goal we use the partner_autocomplete service from
      IAP. It uses free credits that are offered to new clients on saas platform.
      
      Only the fields that are not filled yet are enriched to avoid erasing user
      entered data, except logo. Indeed as partner_autocomplete is probably installed
      as a core app (mail -> iap -> partner_autocomplete auto install chain) it is
      unlikely that people already updated their company logo.
      
      We consider that having a call to IAP consuming a token is ok for a standard
      use case, especially that
      
        * if no iap service is configured call to IAP won't add much timing;
        * on Odoo SaaS free credits are given and company is enriched;
        * on custom SaaS with custom iap service, at db creation probably no
          credits are given and call will simply give no results back;
      
      We decided to call IAP asynchronously at client web load. Session combined to
      a boolean field on company model allows to do this call only once per company.
      Doing this allows to avoid adding yet another post init hook. It also eases
      behavior tweak through inheritance.
      
      This call is limited to admin for obvious security reasons as well as
      performance reason (limiting calls to external providers). As call will be
      done once per company generally admin is the first person to log into the
      its newly created Odoo.
      
      LINKS
      
      Task ID-2322455
      PR odoo/odoo#64600
      PR odoo/upgrade#2086
      
      Co-Authored-By: default avatarDavid Beguin <dbe@odoo.com>
      Co-Authored-By: default avatarThibault Delavallee <tde@odoo.com>
      97f29578
    • Thibault Delavallée's avatar
      [IMP] partner_autocomplete: simplify some marshmalling code for IAP data · 832c451c
      Thibault Delavallée authored
      
      Purpose is to achieve more readable code.
      
      LINKS
      
      Task ID-2322455
      PR #64600
      PR odoo/upgrade#2086
      
      Co-Authored-By: default avatarDavid Beguin <dbe@odoo.com>
      Co-Authored-By: default avatarThibault Delavallee <tde@odoo.c>
      832c451c
    • Thibault Delavallée's avatar
      [IMP] partner_autocomplete: extract iap calls in a separate model and add a mock · d3c53002
      Thibault Delavallée authored
      
      In this commit we move iap functions onto a small tool model. It allows to
      hide some details in a sub model. It also allows to define a mock that will
      be used in tests afterwards.
      
      LINKS
      
      Task ID-2322455
      PR #64600
      PR odoo/upgrade#2086
      
      Co-Authored-By: default avatarDavid Beguin <dbe@odoo.com>
      Co-Authored-By: default avatarThibault Delavallee <tde@odoo.com>
      d3c53002
    • nie's avatar
      [FIX] hr_attendance: user can see other users attendances · 57b52e80
      nie authored
      
      Steps:
      - As admin, go to Settings > Users & Companies > Users
      - Edit Mark Demo (demo)
      - In Human Resources > Attendances, select Manual Attendance or blank
      - As demo, go to My Profile
      - Click the smart button showing the hours worked for the last month
      - Remove all filters
      
      Bug:
      The demo user, who hasn't the rights to see the other employees
      attendances, can see them.
      
      Explanation:
      Every user must have the right to read attendances in order to see their
      own attendances. Not giving the users the read rights in the security
      record rule prevents the record rule from being applied when reading
      attendances. This makes the read access rights the only rule and allows
      everyone to see the attendances of the others.
      
      This commit also fixes the default selected employee when going to the
      attendances tree view on these paths:
      - User
      - Employee
      - User > Employee
      
      In fact, sometime, `active_id` is the ÌD of the user and not of the
      employee. This leads to incorrect results since another employee's
      attendances are shown.
      
      Finally, this commit prevents users from creating attendances from other
      apps since only attendance officers and above can have access to the
      creation form within the Attendances app.
      
      opw:2440117
      
      closes odoo/odoo#65334
      
      X-original-commit: b3247c81
      Signed-off-by: default avatarbackspac <backspac@users.noreply.github.com>
      57b52e80
  2. Jan 29, 2021
    • std-odoo's avatar
      [FIX] mass_mailing: fix the mailing tour (rename the targeted button) · 9dcb196f
      std-odoo authored
      
      Bug
      ===
      Since e598e746 the action button "Launch"
      in the mailing form view was renamed. Therefor, the mass mailing tour is
      broken and need to be updated.
      
      Task 2446835
      
      closes odoo/odoo#65300
      
      X-original-commit: ef0f483612316fbf354bd27a4573ec3292b94328
      Signed-off-by: default avatarThibault Delavallee (tde) <tde@openerp.com>
      9dcb196f
    • Christophe Monniez's avatar
      [FIX] packaging: update rpm packaging for fedora 32 · 2d4c3834
      Christophe Monniez authored
      
      As Fedora 32 was the current release when Odoo 14.0 was released, this
      should be the supported version.
      
      Also, a few  old libs were still in mentioned in the packaging files.
      They flew under the radar because they never broke the packaging.
      This is not the case anymore, those libs disappeared from the Fedora
      repos.
      
      It seems that pyparsing is not used anymore since 5a1c06a1 and thus can
      be safely removed from `requirements.txt` too.
      
      pychart is not used anymore since 3425752e.
      
      While at it, remove mix of tabs and spaces in package.dffedora, also add
      missing packages to avoid installation at test time.
      
      Now that I started down the slippery slope, also removed some `-dev`
      packages in package.dfsrc as wheel's are available.
      
      Finally, the rpm install script now detects the python ABI version in
      order to avoid update this file at each ABI change in Fedora.
      
      Fixes #63719
      
      closes odoo/odoo#65288
      
      X-original-commit: a8deb1dd
      Signed-off-by: default avatarChristophe Monniez (moc) <moc@odoo.com>
      2d4c3834
  3. Jan 26, 2021
  4. Feb 01, 2021
  5. Jan 30, 2021
  6. Jan 29, 2021
  7. Jan 28, 2021
  8. Jan 29, 2021
    • Martin Trigaux's avatar
      [FIX] web: translate remaining days · 51d173d4
      Martin Trigaux authored
      This is the javascript equivalent of `_("Foo %s" % bar)`
      https://www.odoo.com/documentation/master/reference/translations.html#variables
      
      
      
      Forward port of odoo/odoo#65004
      
      closes odoo/odoo#65245
      
      X-original-commit: a672b37240170b554bdd5993e4049cf5d5b040db
      Related: odoo/enterprise#16027
      Signed-off-by: default avatarMartin Trigaux (mat) <mat@odoo.com>
      51d173d4
    • Mohammed Shekha's avatar
      [FIX] *: update tour sequence · 706929e1
      Mohammed Shekha authored
      
      with this commit we are updating sequence of onboarding tours
      
      task-2444153
      
      closes odoo/odoo#65244
      
      X-original-commit: a928beccb09f4db4234356e5e4f7bdf090ecc964
      Related: odoo/enterprise#16026
      Signed-off-by: default avatarAaron Bohy (aab) <aab@odoo.com>
      706929e1
    • Jérémy Hennecart's avatar
      [FIX] mass_mailing: adapt the year in the footer theme · 81377dab
      Jérémy Hennecart authored
      
      Replace the hardcoded year in the footer by the year dynamicaly
      fetch from the current date.
      
      task-2431308
      
      closes odoo/odoo#65243
      
      X-original-commit: f4663c69df03c9219cc613164b03e5860956b837
      Signed-off-by: default avatarMartin Trigaux (mat) <mat@odoo.com>
      Signed-off-by: default avatarThibault Delavallee (tde) <tde@openerp.com>
      81377dab
    • Odoo's Mergebot's avatar
      [MERGE] crm: fix randomly failing tests about query counters and assign domain · 8e1bb0cd
      Odoo's Mergebot authored
      
      PURPOSE
      
      Fix recently added lead assignment tests, notably about query counters
      and random behavior of lead merge.
      
      SPECIFICATIONS
      
      Split performance tests from unit tests. Performance tests should be
      reproducible. Currently there are too much varying query counters.
      
      Fix lead merge process done during assign. As duplicate leads are merged
      final opportunity could not fit team domain anymore. This is a side effect
      of lead deduplication. In this case this is linked to priority field that is set
      to the value of the "final" opportunity, whatever the value of other leads
      merged into it. We think that priority is a field that should be managed
      more carefully. We choose to set it as the highest value found in leads
      merged.
      
      LINKS
      
      Task ID-2446759 (lead merge priority field management)
      Task ID-2446883 (query counters fix)
      PR odoo/odoo#65016
      
      Signed-off-by: default avatarThibault Delavallee (tde) <tde@openerp.com>
      8e1bb0cd
    • Thibault Delavallée's avatar
      [IMP] crm: take highest priority when merging leads · 9d096592
      Thibault Delavallée authored
      When merging leads final priority is currently the one of the lead considered
      as the master lead. This is based on ``_sort_by_confidence_level`` who sorts
      on confidence but not on priority.
      
      We think final priority should be the highest one from merged leads. Indeed
      if a top priority lead is merged into a low priority one we should not loose
      the priority information. It is better to keep the final lead with an high
      priority and let salesmen move it downwards.
      
      LINKS
      
      Task ID-2446759 (lead merge priority field management)
      Task ID-2446883 (query counters fix)
      PR odoo/odoo#65016
      9d096592
    • Thibault Delavallée's avatar
      [REF] crm: improve code of value computation in _merge_opportunity · 3fff6f6a
      Thibault Delavallée authored
      Purpose of this commit is to make clearer how final opportunity value are
      computed or chosen when merging leads. Functionally nothing should change
      with this commit.
      
      LINKS
      
      Task ID-2446759 (lead merge priority field management)
      Task ID-2446883 (query counters fix)
      PR odoo/odoo#65016
      3fff6f6a
    • Thibault Delavallée's avatar
      [IMP] crm: add some test about _merge_opportunity internals · ec382636
      Thibault Delavallée authored
      Purpose is to test internals of lead merge method, notably about values
      of final opportunity. That way we ensure future changes will be reflected
      in tests and regressions will be avoided.
      
      LINKS
      
      Task ID-2446759 (lead merge priority field management)
      Task ID-2446883 (query counters fix)
      PR odoo/odoo#65016
      ec382636
    • Thibault Delavallée's avatar
      [IMP] crm: split results-oriented from perf-oriented assign tests · 79e3636b
      Thibault Delavallée authored
      Purpose is to split assign tests related to results (leads being assigned,
      with deduplication, compared to team and member domains) from tests related
      to performance (query counters).
      
      Assign process is a random process: randomizing teams leads to searching,
      assigning and de-duplicating leads in various order. As a lot of search
      are implied during assign process query counters may vary from run to run.
      "Heavy" performance test included here ranged from 6K to 6.3K queries. Either
      we set high counters maximum which makes those tests less useful. Either we
      avoid random if possible which is what we decided to do by setting the seed
      of random in tests.
      
      SPECIFICATIONS
      
      For results oriented tests remove query counters. Those tests should simply
      ensure results of assign process, notably that even with random choice between
      team and users we always have leads assigned with right domain and counts.
      
      For performance oriented tests using query counters set random seed to have
      a reproducible scenario and have less random in query counters.
      
      LINKS
      
      Task ID-2446759 (lead merge priority field management)
      Task ID-2446883 (query counters fix)
      PR odoo/odoo#65016
      79e3636b
  9. Jan 25, 2021
    • Xavier BOL (xbo)'s avatar
      [FIX] sale_timesheet: review views inherited from project.task model · b2d2cfba
      Xavier BOL (xbo) authored
      
      Before this commit, when the user with no access right to Timesheet App
      wants to see the tasks in a project and sale_timesheet module is
      installed, the user has a traceback saying remaining_hours field is not
      find in the parent view of
      `sale_timesheet.view_task_form2_inherit_sale_timesheet`.
      
      This traceback is raised because the
      `hr_timesheet.view_task_form2_inherited` is not used if the user has no
      access right to Timesheet App and then remaining_hours field is not
      defined for this user because this field is appeared in the view in
      hr_timesheet module.
      
      This commit revises the views inherited from the project.task model to
      give the user without access rights in Timesheet the possibility to see
      the tasks in any project he can see.
      
      opw-2429662
      
      closes odoo/odoo#65000
      
      X-original-commit: d6361403
      Signed-off-by: default avatarSimon Goffin (sig) <sig@openerp.com>
      b2d2cfba
Loading