order by subnodes
This commit is contained in:
parent
8144c72284
commit
8eeb66d99f
2 changed files with 5 additions and 2 deletions
|
@ -302,7 +302,7 @@ class SmqlToAR
|
||||||
col, o = o
|
col, o = o
|
||||||
col.joins builder, table
|
col.joins builder, table
|
||||||
t = table + col.path
|
t = table + col.path
|
||||||
raise OnlyOrderOnBaseError.new( t) unless 1 == t.length
|
#raise OnlyOrderOnBaseError.new( t) unless 1 == t.length
|
||||||
builder.order t, col.col, o
|
builder.order t, col.col, o
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -111,7 +111,10 @@ class SmqlToAR
|
||||||
end
|
end
|
||||||
|
|
||||||
def order table, col, o
|
def order table, col, o
|
||||||
@_order.push "#{column table, col} #{:DESC == o ? :DESC : :ASC}"
|
tc = column table, col
|
||||||
|
@_select.push ct
|
||||||
|
@_order.push "#{ct} #{:DESC == o ? :DESC : :ASC}"
|
||||||
|
self
|
||||||
end
|
end
|
||||||
|
|
||||||
class Dummy
|
class Dummy
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue