ExplanationCache: optimizations

This also the following line in getBusinessLinkClosure():
  if simulation_path.startswith(path):

For example, '/erp5/portal_simulation/1/10'
should not match '/erp5/portal_simulation/1/1'
ExplanationCache: fix update of closure cache

>>> self.closure_cache[business_link] = new_business_process
was done after 'business_link' was overridden by the for loop.
ExplanationCache: do not create new business link closure if unnecessary

Also do not hardcode 'business_process_module'.
Followup f3f738ffca6ecbb19f9f67e32fb7ce2e8671a2c9

It is useless to clear the cache in activities, because this would only work when using only one zope instance. Instead, clear the cache in the test for now.
raise NotImplementedError, because implementation does not match comments
erp5_accounting_ui_test: clear the cache when we validate a new account

This cache is used by AccountingTransactionLine_getNodeItemList
rename dialog to respect naming conventions
test for dialog listbox with editable fields
fix list method returning duplicate uids
Listbox: calculate a mapping uid -> object once

Instead of looping through the list each time.
Also check that the list method does not return duplicate uids.
fix undefined variables
Revert commits pushed by mistake

Revert "fix undefined variables"

This reverts commit 77a53809e6015f41ca84e1154c0ffa5a74958364.

Revert "Listbox: calculate a mapping uid -> object once"

This reverts commit 84029c01e1c7e45f354aa9f7236772c05e0e1b01.

Revert "fix list method returning duplicate uids"

This reverts commit 386b0e6bf6f6a7251781f2b1e5232d7776619c49.

Revert "test for dialog listbox with editable fields"

This reverts commit e046d8f51c2bc7ce600a91d901ee7d9c04008d73.