1. 18 Aug, 2022 5 commits
    • Jérome Perrin's avatar
      *: reorganise indexation methods · 2bd1d4ed
      Jérome Perrin authored
      02011d8e (immediateReindexObject: use super user to reindex script,
      2015-12-14) did not apply for inventory, because they were overloading
      immediateReindexObject.
      Introduce a new level, _immediateReindexObject that will hold the actual
      reindexing logic.
      
      Previously this method was using PortalContent.reindexObject which was
      monkey patched, to make things less complex and more future proof, move
      the monkey patch to a method on base class.
      
      This also drops alternateReindexObject on BalanceTransaction, because it
      is already defined in Inventory
      2bd1d4ed
    • Jérome Perrin's avatar
      ERP5TypeLiveTestCase: close request at the end of each test · e605544e
      Jérome Perrin authored
      This is supposed to fix "Should not load state for ${oid of a skin} when
      the connection is closed" sometimes happening with live tests (especially
      when the test self.publish and the developer access the site while the
      test is suspended on a debugger breakpoint).
      
      The object accessed after the connection is closed was a skin (python
      script, sometimes page template or form) that was cached in SKINDATA.
      The mechanism to prune entries from the cache uses REQUEST.hold API
      which expects that REQUEST.close is called on request, but because
      requests were not closed at the end of the request, it happened that
      the cache was reused from another connection.
      
      This change to close the requests, like ERP5TypeTestCase is doing in
      tearDown (the actual close is done by Testing.ZopeTestCase.connections).
      
      By closing requests at the end of tests, we also have to change so that
      at the beginning of the test we initialize the request, by using the same
      setSite and setupCurrentSkin that are done in ERP5TypeTestCase.
      e605544e
    • Jérome Perrin's avatar
      ProxyField: use Skinnable API to get current skin · 8a8f9384
      Jérome Perrin authored
      SKINDATA is an implementation detail that should not be accessed from
      this level.
      8a8f9384
    • Jérome Perrin's avatar
      BusinessTemplate: drop useless fixZSQLMethod in SkinTemplateItem.install · 45e45842
      Jérome Perrin authored
      In SkinTemplateItem.install, self._objects contains entries for skin
      folders and for all skins. objectValues method calls was called for skin
      folders (as expected) and also for all skins, which acquire objectValues
      from skin folder and do the work again.
      
      This simplifies this by only running this for skin folders.
      45e45842
    • Jérome Perrin's avatar
      Listbox: refactor computation of "default" URL · 9ca9d73d
      Jérome Perrin authored
      "default" URL is the URL when listbox column does not use URL column
      and when the brains do not have a getListItemUrl method.
      
      Move the computation in a lazyMethod, so that it is computed only once
      per line instead of once per cell.
      
      Also remove a try/except, I don't think this code is supposed to get an
      AttributeError
      9ca9d73d
  2. 09 Aug, 2022 2 commits
  3. 02 Aug, 2022 10 commits
  4. 28 Jul, 2022 1 commit
  5. 13 Jul, 2022 1 commit
    • Jérome Perrin's avatar
      accounting: fix grouping dialog loosing section category on next page · 0d8242de
      Jérome Perrin authored
      In xhtml_style, just after clicking next or previous page in the listbox
      buttons, the values selected in 'Section Category' and 'Section Category
      Strict' were not used, because they were used from request and not from
      as normal script parameters.
      
      This fixes only the xhtml_style version, ERP5JS has another problem that
      dialog fields values are reset when going to next page, so it would also
      need this problem to be fixed.
      0d8242de
  6. 12 Jul, 2022 1 commit
  7. 07 Jul, 2022 2 commits
  8. 01 Jul, 2022 1 commit
  9. 27 Jun, 2022 1 commit
  10. 24 Jun, 2022 1 commit
  11. 23 Jun, 2022 2 commits
  12. 22 Jun, 2022 3 commits
  13. 21 Jun, 2022 4 commits
  14. 20 Jun, 2022 2 commits
  15. 15 Jun, 2022 4 commits