protected Event toUnwrappedModel(Event event) {
if (event instanceof EventImpl) {
return event;
}
EventImpl eventImpl = new EventImpl();
eventImpl.setNew(event.isNew());
eventImpl.setPrimaryKey(event.getPrimaryKey());
eventImpl.setEventId(event.getEventId());
eventImpl.setName(event.getName());
eventImpl.setDescription(event.getDescription());
eventImpl.setDate(event.getDate());
eventImpl.setCompanyId(event.getCompanyId());
eventImpl.setGroupId(event.getGroupId());
eventImpl.setUserId(event.getUserId());
eventImpl.setCreateDate(event.getCreateDate());
eventImpl.setModifiedDate(event.getModifiedDate());
eventImpl.setLocationId(event.getLocationId());
return eventImpl;
}