Fixed level order
This commit is contained in:
parent
ccae285b81
commit
35aa2574f8
@ -37,6 +37,8 @@ class LevelRepositoryService(LevelRepositoryABC):
|
|||||||
int(self._get_value_from_result(sql_result[3])), # min xp
|
int(self._get_value_from_result(sql_result[3])), # min xp
|
||||||
int(self._get_value_from_result(sql_result[4])), # permissions
|
int(self._get_value_from_result(sql_result[4])), # permissions
|
||||||
self._servers.get_server_by_id(sql_result[5]), # server
|
self._servers.get_server_by_id(sql_result[5]), # server
|
||||||
|
sql_result[6], # created_at
|
||||||
|
sql_result[7], # modified_at
|
||||||
id=self._get_value_from_result(sql_result[0]), # id
|
id=self._get_value_from_result(sql_result[0]), # id
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -77,7 +77,7 @@ class ServerQuery(DataQueryWithHistoryABC):
|
|||||||
)
|
)
|
||||||
self.add_collection(
|
self.add_collection(
|
||||||
"level",
|
"level",
|
||||||
lambda server, *_: self._levels.get_levels_by_server_id(server.id),
|
lambda server, *_: self._levels.get_levels_by_server_id(server.id).order_by_descending(lambda x: x.min_xp),
|
||||||
LevelFilter,
|
LevelFilter,
|
||||||
)
|
)
|
||||||
self.set_field(
|
self.set_field(
|
||||||
|
Loading…
Reference in New Issue
Block a user