refactored to move entityList specific logic out of the general form handler