erp5_core: Fixups in Base_getRelatedDocumentList

- Remove passing of **kw to query, since it would break Listbox
pagination
- Avoid code duplication
- Fix indentation
1 job for graphic_gadget_js
in 0 seconds, using 0 compute credits, and was queued for 0 seconds