Skip to content

Commit

Permalink
Correct display of date/time
Browse files Browse the repository at this point in the history
  • Loading branch information
jimdogx committed Feb 2, 2025
1 parent df704cb commit 938932b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions components/search/SearchRow.bs
Original file line number Diff line number Diff line change
Expand Up @@ -84,15 +84,15 @@ function getData()
end function

sub addRow(data, title, type_filter)
startDate = createObject("roDateTime")

itemData = m.top.itemData
row = data.CreateChild("ContentNode")
row.title = title
for each item in itemData.Items
if LCase(item.type) = "program" and isValid(item.json.StartDate)
startDate.FromISO8601String(item.json.StartDate)
item.title += " - " + startDate.AsDateString("short-date") + " " + startDate.AsTimeStringLoc("short")
localStartDate = createObject("roDateTime")
localStartDate.FromISO8601String(item.json.StartDate)
localStartDate.ToLocalTime()
item.title += ` - ${localStartDate.asDateStringLoc("short")} ${localStartDate.asTimeStringLoc("short")}`
end if
if item.type = type_filter
row.appendChild(item)
Expand Down

0 comments on commit 938932b

Please sign in to comment.