use of org.broadleafcommerce.openadmin.dto.override.GroupMetadataOverride in project BroadleafCommerce by BroadleafCommerce.
the class BasicEntityMetadataProvider method overrideMetadataViaXml.
@Override
public MetadataProviderResponse overrideMetadataViaXml(OverrideViaXmlRequest overrideViaXmlRequest, Map<String, TabMetadata> metadata) {
Map<String, MetadataOverride> overrides = getTargetedOverride(overrideViaXmlRequest.getDynamicEntityDao(), overrideViaXmlRequest.getRequestedConfigKey(), overrideViaXmlRequest.getRequestedCeilingEntity());
if (overrides != null) {
for (String overrideKey : overrides.keySet()) {
MetadataOverride overrideMetadata = overrides.get(overrideKey);
if (overrideMetadata instanceof GroupMetadataOverride) {
GroupMetadataOverride groupOverrideMetadata = (GroupMetadataOverride) overrideMetadata;
applyGroupMetadataOverrideViaXml(overrideKey, groupOverrideMetadata, metadata);
} else if (!(overrideMetadata instanceof FieldMetadataOverride)) {
// Strictly applies to a Tab
applyTabMetadataOverrideViaXml(overrideKey, overrideMetadata, metadata);
}
}
}
return MetadataProviderResponse.HANDLED;
}
Aggregations