Fixes #694 eager load associations in query_items

The associations of a resource needs to be eager loaded when selecting a record and the columns of the associated models are involved.

If no association exists nothing will be eager loaded.