Fixes #1171 - Be a bit more descriptive on detection for entity class transforming and throw an exception if we detect that a class could not be transformed

(cherry picked from commit d1d74894f6dd86344cc9d2d3b27f38edcdc0efec)
Merge branch 'BroadleafCommerce-3.1.x' into develop