Open metenn opened 3 months ago
Seems like somebody forgot ordering = ['pk'] in Meta https://github.com/sio2project/oioioi/blob/5414a6ce7dbe790905114895e8b2415674a70f43/oioioi/problems/models.py#L818-L838 same goes for DifficultyTagLocalization, which is why this code returns unsorted rows (per SQL specs rows are not automatically sorted by any field) https://github.com/sio2project/oioioi/blob/5414a6ce7dbe790905114895e8b2415674a70f43/oioioi/problems/views.py#L556 so another fix would probably be adding an .order_by() here?
ordering = ['pk']
Meta
DifficultyTagLocalization
.order_by()
perhaps the ordering should be more explicit in the first place rather than relying on the autogenerated pk field?
pk
As a bonus: Seems like the styling on these buttons is a bit broken, not to mention the inconsistent heights.
https://github.com/sio2project/oioioi/assets/49620905/cb16c10b-9ef7-456b-b1db-32482b6472ac
Seems like somebody forgot
ordering = ['pk']
inMeta
https://github.com/sio2project/oioioi/blob/5414a6ce7dbe790905114895e8b2415674a70f43/oioioi/problems/models.py#L818-L838 same goes forDifficultyTagLocalization
, which is why this code returns unsorted rows (per SQL specs rows are not automatically sorted by any field) https://github.com/sio2project/oioioi/blob/5414a6ce7dbe790905114895e8b2415674a70f43/oioioi/problems/views.py#L556 so another fix would probably be adding an.order_by()
here?perhaps the ordering should be more explicit in the first place rather than relying on the autogenerated
pk
field?