Fix User Name Unavailable/Invalid modulename passed to HtmlUtil::getSelector_ObjectArray

create a new doctrine-based method to use from template based on old dbobject method.
also contains other fixes.

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #1099
| Refs tickets  | -
| License       | MIT
| Doc PR        | -

todo
 - [x] confirm the new method works where needed.