use of io.lumeer.engine.api.event.CreateSelectionList in project engine by Lumeer.
the class MongoSelectionListDao method createList.
@Override
public SelectionList createList(final SelectionList selection) {
try {
databaseCollection().insertOne(selection);
if (createEvent != null) {
mapList(selection);
createEvent.fire(new CreateSelectionList(getOrganization().get().getId(), selection));
}
return selection;
} catch (MongoException ex) {
throw new StorageException("Cannot create selection list " + selection, ex);
}
}
Aggregations