fixup! erp5_core: Make two queries in Base_getRelatedDocumentList

My suggestion of using sorted in
!1373 (comment 129103) was wrong,
ERP5 document do not sort in deterministic order. Use a key function to make
sure we get results in same order
4 jobs for fix/cmp_document_test_failure in 0 seconds
Status Job ID Name Coverage
  External
running ERP5.CodingStyleTest-Master

32535:58:32

passed ERP5.CodingStyleTest-TestRunner1

00:41:58

passed ERP5.PerformanceTest-TestRunner1

00:22:41

failed ERP5.UnitTest-TestRunner1

01:14:19