Fixed bugs in entity dsl