Class DefaultSAPB2BUnitService
- java.lang.Object
-
- de.hybris.platform.b2b.services.impl.DefaultB2BUnitService
-
- com.sap.hybris.sapcustomerb2b.inbound.DefaultSAPB2BUnitService
-
- All Implemented Interfaces:
B2BUnitService<B2BUnitModel,B2BCustomerModel>
public class DefaultSAPB2BUnitService extends DefaultB2BUnitService
Enhancement of DefaultB2BUnitService to determine the sales area dependent B2BUnit
-
-
Constructor Summary
Constructors Constructor Description DefaultSAPB2BUnitService()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected BaseStoreServicegetBaseStoreService()java.util.Set<B2BUnitModel>getBranch(B2BUnitModel unit)Gets the branch of a unit.protected java.lang.StringgetCommonDistributionChannel(java.lang.String salesOrganization, java.lang.String distributionChannel)Gets the common distribution channelprotected java.lang.StringgetCommonDivision(java.lang.String salesOrganization, java.lang.String division)Gets the common divisionprotected FlexibleSearchServicegetFlexibleSearchService()B2BUnitModelgetParent(B2BCustomerModel b2bCustomer)Gets the parent unit of a user.protected java.lang.StringgetSalesAreaSuffix()Gets the sales area suffixprotected booleanisSalesAreaDependentB2BUnit(B2BUnitModel unit)Checks whether the current B2BUnit is a sales area dependent B2BUnitvoidsetBaseStoreService(BaseStoreService baseStoreService)voidsetFlexibleSearchService(FlexibleSearchService flexibleSearchService)-
Methods inherited from class de.hybris.platform.b2b.services.impl.DefaultB2BUnitService
addMember, disableBranch, disableUnit, enableBranch, enableUnit, findAccountManagerForUnit, findApprovalProcessCodeForUnit, findUnitByUid, findUnitWithCreditLimit, getAccountManagerForUnit, getActiveCreditLimit, getAllApprovalProcesses, getAllParents, getAllProcessDefinitionsNames, getAllUnitsOfOrganization, getAllUnitsOfOrganization, getAllUserGroupMembersForType, getApprovalProcessCodeForUnit, getB2BCustomers, getB2bUnitDao, getB2BUnits, getBranch, getConfigurationService, getCustomers, getModelService, getParent, getPrincipalGroupMembersDao, getProcessDefinitionFactory, getRootUnit, getSearchRestrictionService, getSessionService, getTypeService, getUnitForUid, getUnitWithCreditLimit, getUserService, getUsersOfUserGroup, getUsersOfUserGroup, lookupPriceGroupFromClosestParent, setB2bUnitDao, setConfigurationService, setCurrentUnit, setModelService, setPrincipalGroupMembersDao, setProcessDefinitionFactory, setSearchRestrictionService, setSessionService, setTypeService, setUserService, toggleBranch, toggleUnit, updateBranchInSession, updateParentB2BUnit
-
-
-
-
Method Detail
-
getBranch
public java.util.Set<B2BUnitModel> getBranch(B2BUnitModel unit)
Description copied from interface:B2BUnitServiceGets the branch of a unit.- Specified by:
getBranchin interfaceB2BUnitService<B2BUnitModel,B2BCustomerModel>- Overrides:
getBranchin classDefaultB2BUnitService- Parameters:
unit- the unit- Returns:
- the branch
-
isSalesAreaDependentB2BUnit
protected boolean isSalesAreaDependentB2BUnit(B2BUnitModel unit)
Checks whether the current B2BUnit is a sales area dependent B2BUnit- Parameters:
unit-- Returns:
- true = B2BUnit is a sales area dependent B2BUnit; false B2BUnit is a sales area independent B2BUnit
-
getParent
public B2BUnitModel getParent(B2BCustomerModel b2bCustomer)
Description copied from interface:B2BUnitServiceGets the parent unit of a user.- Specified by:
getParentin interfaceB2BUnitService<B2BUnitModel,B2BCustomerModel>- Overrides:
getParentin classDefaultB2BUnitService- Parameters:
b2bCustomer- the employee- Returns:
- the parent
-
getSalesAreaSuffix
protected java.lang.String getSalesAreaSuffix()
Gets the sales area suffix- Returns:
- String sales area suffix
-
getCommonDistributionChannel
protected java.lang.String getCommonDistributionChannel(java.lang.String salesOrganization, java.lang.String distributionChannel)Gets the common distribution channel- Parameters:
salesOrganization-distributionChannel-- Returns:
- String common distribution channel
-
getCommonDivision
protected java.lang.String getCommonDivision(java.lang.String salesOrganization, java.lang.String division)Gets the common division- Parameters:
salesOrganization-division-- Returns:
- String common division
-
getBaseStoreService
protected BaseStoreService getBaseStoreService()
-
setBaseStoreService
public void setBaseStoreService(BaseStoreService baseStoreService)
-
getFlexibleSearchService
protected FlexibleSearchService getFlexibleSearchService()
-
setFlexibleSearchService
public void setFlexibleSearchService(FlexibleSearchService flexibleSearchService)
-
-