Sort Controller in MVC

This forum allows users to post and respond to "How Do I Do ....." questions. The information contained in this forum has not been validated by K-Rise Systems and, as such, K-Rise Systems cannot guarantee the accuracy of the information.
Post Reply
smackie
Posts: 46
Joined: August 26th, 2021, 2:02 pm
Contact:

Sort Controller in MVC

Unread post by smackie »

I am attempting to use a sort controller in my MVC webpage; however the controller runs but the page does not reflect a change in the order. I am not sure if my controller is setup improperly or if I need some other service to update the page. I am using the update element service pointing to the name of the table but this is not working.
word count: 67

Tags:
JustinVanRegenmorter
Posts: 571
Joined: August 26th, 2021, 9:56 am
Contact:

Re: Sort Controller in MVC

Unread post by JustinVanRegenmorter »

Hello Sheryl,

When setting up a sort controller you must make sure that the name of the database service is the same as in the model. We would recommend that you use a SubMethod and just have the database service in their so it can be called from both the model and any controller.

For example, when you setup a list using our List / Grid creation tool you can see that the Sort Controller calls a SubMethod and an UpdateElement service.
SortController.PNG
Then inside the SubMethod the original database service runs and does the sorting.
The attachment SubMethod.PNG is no longer available
When the UpdateElement service runs it will replace the entire table if you have it set to the HtmlId of the table.
Attachments
SubMethod.PNG
word count: 124
Post Reply