add emptyParent flag passing to custom methods

To distinct whether the url was /api/resource/subresource/id or /api/resource/id/subresource in custom methods