Set entity id to nullable in entity permission