
Comment Post Options
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎May 15, 2024 02:08 AM
Hi community, I have set up a trigger that loads a record and passes on linked records values to a script supposed to order those by date from earliest to latest. I'm struggling to get this to work, can anyone advise? Thanks!
const inputConfig = input.config()
const linkedRecords = inputConfig.linkedRecords
linkedRecords.sort(function(a,b) {
var c= new Date(a.date).getTime();
var d= new Date(b.name).getTime();
return c-d;
})
output.set("linkedRecords", linkedRecords)
0 Replies 0
