Fix table sorting: URLs now end with /, even the queries
This commit is contained in:
parent
65a37864ff
commit
dcf8189cb0
|
@ -1219,7 +1219,7 @@ get_sort_query(Q) ->
|
||||||
end.
|
end.
|
||||||
get_sort_query2(Q) ->
|
get_sort_query2(Q) ->
|
||||||
{value, {_, Binary}} = lists:keysearch(<<"sort">>, 1, Q),
|
{value, {_, Binary}} = lists:keysearch(<<"sort">>, 1, Q),
|
||||||
Integer = binary_to_integer(Binary),
|
Integer = binary_to_integer(lists:nth(1, binary:split(Binary, <<"/">>))),
|
||||||
case Integer >= 0 of
|
case Integer >= 0 of
|
||||||
true -> {ok, {normal, Integer}};
|
true -> {ok, {normal, Integer}};
|
||||||
false -> {ok, {reverse, abs(Integer)}}
|
false -> {ok, {reverse, abs(Integer)}}
|
||||||
|
|
Loading…
Reference in New Issue