use of org.hisp.dhis.preheat.PreheatParams in project dhis2-core by dhis2.
the class DefaultObjectBundleService method create.
@Override
public ObjectBundle create(ObjectBundleParams params) {
PreheatParams preheatParams = params.getPreheatParams();
if (params.getUser() == null) {
params.setUser(currentUserService.getCurrentUser());
}
preheatParams.setUser(params.getUser());
preheatParams.setObjects(params.getObjects());
ObjectBundle bundle = new ObjectBundle(params, preheatService.preheat(preheatParams), params.getObjects());
bundle.setObjectBundleStatus(ObjectBundleStatus.CREATED);
bundle.setObjectReferences(preheatService.collectObjectReferences(params.getObjects()));
return bundle;
}
use of org.hisp.dhis.preheat.PreheatParams in project dhis2-core by dhis2.
the class ObjectBundleParams method getPreheatParams.
public PreheatParams getPreheatParams() {
PreheatParams params = new PreheatParams();
params.setPreheatIdentifier(preheatIdentifier);
params.setPreheatMode(preheatMode);
return params;
}
Aggregations