support and cast relationship references as ReadonlyField

Cleaned, single-commit PR from #73