Organizations list in Commerce showing max 1000 items

Vote:
 

Commerce 14.3.0

We have 3634 organizations in the database but the list in Commerce only shows max 1000 items?

Anyone know if this is by design?

Sure, it will not be common to page through all organizations but at least the TOTAL number of organizations should be correct?

#280407
May 16, 2022 20:15
Vote:
 

This is controlled by MetaObjectOptions

The default value is 1000.  I will register bug though as it should show the correct total number is a the api returns the total count.

#280472
May 17, 2022 21:40
Vote:
 

We already have a bug that was tested and in testing. which should solve this problem 

#280521
May 18, 2022 8:58
Vote:
 

OK thanks, it works by updating the MetaObjectOptions but to be honest there is something rotten over this. Or rather the usage of getting organizations in the UI.

  1. Just because we have 3634 organizations we don't want to load them all at once in the UI. Which is what happens
  2. When opening a contact, the UI will make a call to get ALL organizations and then filter. Look at these requests: Commerce is requesting 3.0 MB of organizations only to
    set the contacts Primary Organization.
  3. Since the contact view has this behaviour of loading all organizations - which in turn is set by the MetaObjectOptions... we will only really see the Primary Organization if that organization is WITHIN
    the max allowed. Meaning, if we have it set to 1000 max... and a contacts organization happens to be the 1001th... the field will be empty.
  4. The same behaviour is used for the Organizations view. Commerce requests ALL organizations in one request. The result looks nice and paginated though, even if the pagination is actually done on the client. Same for the search. You are basically dumping every single organization into the browser memory just to do pagination and search?
#280533
May 18, 2022 13:04
Vote:
 

Is there a way to pull Organizations beyond 1000 without setting the MetaObjectOptions. We have almost 100k orgs and when I set that property my application crashes from memory and CPU overutilization. I did see the GetOrganizationsByPattern(), but I think that method is still restricted by the first 1000.

#303889
Jun 21, 2023 12:53
Vote:
 
#304228
Jun 28, 2023 11:11
Viktor Bergman Talani - Jul 05, 2023 3:03
Quan, could this possibly be implemented by internally Optimizely for the management UI? As far as I am aware, the issue with loading organizations and contacts in the Customer Manager still persists (i.e, the browser loads every organization it can based on the metaobjectoptions, and is'nt doing any kind of pagination)
Billy Bensinger - Jul 05, 2023 3:05
Thank you, Quan! I saw your blog post the other day. It does address my question. Great work!
Quan Mai - Jul 05, 2023 5:18
@Viktor I think (need to look it up) I already filed a bug for using paging API for management UI.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.