Interface ConfigurationService
- All Known Implementing Classes:
DefaultConfigurationService
public interface ConfigurationService
Configuration service.
-
Method Summary
Modifier and TypeMethodDescriptioncloneConfiguration(String configId, boolean permanent) Clones the configuration for given configIdcreateConfiguration(String productCode) Creates a new configuration, based on a root product codebooleandeleteConfiguration(String configId) Delete the configuration for given configIdgetConfigurationSummary(String configId) Retrieves the CPQ configuration summarydefault ConfigurationSummaryDatagetConfigurationSummary(String configId, AbstractOrderEntryModel entry) Retrieves the CPQ configuration summary.getLineItems(String configId) get's the list of line itemsintgetNumberOfConfigurationIssues(String configId) get's the total number of configuration issuesdefault intgetNumberOfConfigurationIssues(String configId, AbstractOrderEntryModel entry) Get's the total number of configuration issues.booleanhasConfigurationIssues(String configId) Checks if a configuration has issuesdefault booleanhasConfigurationIssues(String configId, AbstractOrderEntryModel entry) Checks if a configuration has issues.voidmakeConfigurationPermanent(String configId) Marks a persisted configuration as permanent.
Should be called when the UI is 'done' configuring.voidremoveCachedConfigurationSummary(String configId) Removes a cached configuration summary if present.
-
Method Details
-
createConfiguration
Creates a new configuration, based on a root product code- Parameters:
productCode- Root product code- Returns:
- Configuration Identifier
-
getConfigurationSummary
Retrieves the CPQ configuration summary- Parameters:
configId- CPQ configuration Id- Returns:
- CPQ configuration summary
-
deleteConfiguration
Delete the configuration for given configId- Parameters:
configId- CPQ configuration Id- Returns:
- true if deletion was successful
-
cloneConfiguration
Clones the configuration for given configId- Parameters:
configId- CPQ configuration Idpermanent- indicates whether clone should be permanent- Returns:
- CPQ configuration Id of cloned configuration
-
removeCachedConfigurationSummary
Removes a cached configuration summary if present. Tolerates summary not being present- Parameters:
configId- Configuration identifier
-
hasConfigurationIssues
Checks if a configuration has issues- Parameters:
configId- Configuration ID- Returns:
- Issues?
-
getNumberOfConfigurationIssues
get's the total number of configuration issues- Parameters:
configId- Identifies the CPQ configuration- Returns:
- number of configuration issues
-
makeConfigurationPermanent
Marks a persisted configuration as permanent.
Should be called when the UI is 'done' configuring. Afterwards admin/server is required to do any changes. UI/Client scope is not sufficient anymore to do changes.- Parameters:
configId- config id
-
getLineItems
get's the list of line items- Parameters:
configId- Identifies the CPQ configuration- Returns:
- line items
-
getConfigurationSummary
default ConfigurationSummaryData getConfigurationSummary(String configId, AbstractOrderEntryModel entry) Retrieves the CPQ configuration summary. As a rule, CPQ configuration can be retrieved only for the origin user or a user from the same company. However, there are some processes in commerce which run asynchronous with the anonymous user and need to retrieve the CPQ configuration. In these cases, the required authorization is already verified by the parent process. This method allows such processes to retrieve the CPQ configuration summary even if the process is running with anonymous user.- Parameters:
configId- CPQ configuration Identry- entry containing this CPQ configurable product- Returns:
- CPQ configuration summary
-
getNumberOfConfigurationIssues
Get's the total number of configuration issues. As a rule, CPQ configuration can be retrieved only for the origin user or a user from the same company. However, there are some processes in commerce which run asynchronous with the anonymous user and need to retrieve the CPQ configuration. In these cases, the required authorization is already verified by the parent process. This method allows such processes to retrieve the number of issues in the CPQ configuration even if the process is running with anonymous user.- Parameters:
configId- Identifies the CPQ configurationentry- entry containing this CPQ configurable product- Returns:
- number of configuration issues
-
hasConfigurationIssues
Checks if a configuration has issues. As a rule, CPQ configuration can be retrieved only for the origin user or a user from the same company. However, there are some processes in commerce which run asynchronous with the anonymous user and need to retrieve the CPQ configuration. In these cases, the required authorization is already verified by the parent process. This method allows such processes to verify whether the CPQ configuration has issues even if the process is running with anonymous user.- Parameters:
configId- Configuration IDentry- entry containing this CPQ configurable product- Returns:
- Issues?
-