- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-01-2018 03:12 PM
Hi,
I am trying to get a related list (change_task) which is shown on the Change form to default sort by the field Order instead of Number by default. I impersonated users which don't have any user preferences set, but for some reason it still sorts by Number instead of Order.
I found the documentation below for Jakarta (which we are on) and from that it appears the Order should take precedence.
The only issue I can think of is because the change_task table inherits from the task table, and the order field is on the task table instead of the change_task table that's causing the issue. Any help would be much appreciated:
Also, I added a dictionary override on the Task table (change_task) with attribute isOrder=true, and it still doesn't sort properly.
Solved! Go to Solution.
- Labels:
-
User Interface (UI)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-02-2018 08:06 AM
Also - if you want users to be able to override your sort order on just a normal related list (not based on Relationship record setup), you can create a user preference marked as "system":
The 2 preference names:
tablename.db.order.direction - value of "ASC" or "DESC"
tablename.db.order - value of desired field name to sort by
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-01-2018 03:14 PM
Also, I added a dictionary override on the Task table to change_task with attribute isOrder=true, and it still doesn't override.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-02-2018 08:02 AM
If you want a related list to always be sorted in a certain way, it's better to create a Relationship and use that as the related list instead.
https://docs.servicenow.com/bundle/jakarta-platform-user-interface/page/administer/form-administration/task/t_CreateDefinedRelatedLists.html
Example of one my Relationships I've set up with a default sort:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-15-2021 11:41 PM
I stumbled upon this solution after looking at and trying a lot of other things! It matched my requirements exactly, many thanks! 🙂
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-02-2018 08:06 AM
Also - if you want users to be able to override your sort order on just a normal related list (not based on Relationship record setup), you can create a user preference marked as "system":
The 2 preference names:
tablename.db.order.direction - value of "ASC" or "DESC"
tablename.db.order - value of desired field name to sort by