Fix translations for attributes_table when using `row`

For some reason `@resource` from `AttributeTable` is `nil`, only
`@collection` is available. This fixes try to get the `@resource` class
from both `@resource` and `@collection`

**Issue:** #2556