Hi,
I am facing a performance issue in my OutSystems application and would appreciate your suggestions.
Scenario:I have two entities:
Each Order can have multiple BatchNumbers:BatchNumbers.OrderId = Orders.Id
Current Implementation:
Problem:
Requirements:
Hi @SreenivasuluReddy Lingala ,
Instead of using a normal dropdown I would recommend using either one of these two:
As @Mihai Melencu suggested you can use server side drop down. Apart from this you need to ensure follow right practice for database proper indexing, pagination, for drop down purpose fetch only limited attributes. It will help to reduce the performance issue.
regards
Hi @Mihai Melencu,
Thank you for your response.
I tried using the Dropdown Server-Side widget by referring to the documentation link: https://success.outsystems.com/documentation/11/building_apps/user_interface/patterns/using_mobile_and_reactive_patterns/interaction/dropdown_server_side/
However, I’m not clear on where and how the server-side data is actually being called. Could you please provide detailed guidance on how the server-side call works, especially how to handle it using the OnChange or OnSearch actions?
Thanks in advance for your help.
I am sharing the below OML.I have used server-side dropdown to achieve this. You can check that if you have any doubt let me know.
Thanks ,
Sudip
Hello SreenivasuluReddy Lingala,
May I suggest a different approach, because it looks to me that a dropdown (with server-side search or not) is probably not the best approach here.
Thinking of the user of the application, I imagine that if they want to change the Order to which the Batch is associated, they actually know to which order they will move it, or they have information about the order that would allow the to find the correct order (like the client, dates, etc).
I am also assuming that changing the order is not the task that will happen more frequently when in the Batch Detail screen? If this is the case, I would suggest a small change in terms of UI.
In the Detail screen, instead of a dropdown, you simply show the Order number.To allow the user to change the order, I would add a button, that would open a popup or a sidebar (or even navigate to a new screen), where the user would have an input to type the order number and maybe a search button, so that with no number or a partial order number he could see a paginated table with the results.
The advantage of this approach is that if you want, you can add more fields to the search so that the user can use other information to search the right order and select the new one.
Cheers!
Hi The dropdown replace with Search input(minimum 3 characters) calls Server Side action fetch top searched matching records only.
I would Highly recommend you to use Server Side Dropdown,
I you want to see the demo of it how it works, you can check here
Lazy Load Drop Down - https://www.outsystems.com/forge/component-overview/15205/lazy-load-dropdown-search-o11
Drop Down Server Side - https://www.outsystems.com/forge/component-overview/14690/dropdown-server-side-demo-o11
I hope this will help.
ThanksTousif Khan
Hi @SreenivasuluReddy Lingala,
The Dropdown Server Side component works with two main events:
The dropdown doesn't load all records when the screen opens. It stays empty initially and only retrieves data when the user types. This makes it suitable for large datasets, such as 100,000+ records.