FIX: Convert ID into integer before sorting
This commit is contained in:
parent
7933a29fa0
commit
c3959f903a
|
@ -90,7 +90,7 @@ module DiscourseAssign
|
||||||
.includes(:tags)
|
.includes(:tags)
|
||||||
.includes(:user)
|
.includes(:user)
|
||||||
.joins("JOIN topic_custom_fields tcf ON topics.id = tcf.topic_id AND tcf.name = 'assigned_to_id' AND tcf.value IS NOT NULL")
|
.joins("JOIN topic_custom_fields tcf ON topics.id = tcf.topic_id AND tcf.name = 'assigned_to_id' AND tcf.value IS NOT NULL")
|
||||||
.order('tcf.value, topics.bumped_at desc')
|
.order('tcf.value::integer, topics.bumped_at desc')
|
||||||
.offset(offset)
|
.offset(offset)
|
||||||
.limit(limit)
|
.limit(limit)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue