Open Arzorth opened 2 years ago
A new case in which the topo sorting is misbehaving:
https://www.thecrag.com/en/climbing/greece/area/448210704
In this example, all topos share the first route, therefore they are sorted by the topo ID, but before using that criteria, the following one should be taken into account:
This would sort the topos from more general to more specific, the expected topo order in this case is the following:
TOPO #6643167756 TOPO #513300558 TOPO #5349828555
Regards!
JositoGG
I'm editing rather complex series of topos and the behaviour regarding the order in which they are shown is not as expected.
Parent view
https://www.thecrag.com/en/climbing/spain/patones/area/350653239![image](https://user-images.githubusercontent.com/17315806/183358993-ae1e0235-77cc-49b9-b57d-cb70632d0943.png)
The expected order is:
While the first one is kind of obvious (it contains the lowest indexes of the sub-areas of both first and second current-level-areas), the second and the third are not that obvious, the reason they should be in this order is because they start with the same sub-areas (both 'Repisa del Stradivarius' [1.10] and 'Gominolas Central' [2.4]) but TOPO #4452844539 finishes first (with 'Viejo Charlie' [1.13]) while TOPO #4452840900 finishes later (with 'Perejil' [1.15])
Children views
https://www.thecrag.com/en/climbing/spain/patones/area/6407394459![image](https://user-images.githubusercontent.com/17315806/183361495-f5f4bb5e-f1eb-4300-a711-6369503f579a.png)
In this case, the order is as expected (as mentioned previously) but both TOPO #4452844539 and TOPO #4452840900 should appear on top of the sector 'Repisa del Stradivarius' and not in the upper most part of the page as they are being shown currently.
https://www.thecrag.com/en/climbing/spain/patones/area/6407399862![image](https://user-images.githubusercontent.com/17315806/183364176-d4156045-6fc2-40c6-b69b-093090a4db68.png)
In this other case, the problem is the same, both TOPO #4452844539 and TOPO #4452840900 should appear on top of the sector 'Gominolas central' and not on top of the page.
Conclusions
✅The system should take into account the current-level-areas to position and order the topos. ❌In case of having the same current-level-areas, the system should check the sub-areas to order the topos, if no sub-area is present it should order by an arbitrary criteria such as topo ID or randomly. ❌The system should ignore the upper-level-areas and cousin-areas to order and position the topos.
Regards!
JositoGG