Class CommerceDiscountLocalServiceUtil
com.liferay.commerce.discount.service.impl.CommerceDiscountLocalServiceImpl
and
is an access point for service operations in application layer code running
on the local server. Methods of this service will not have security checks
based on the propagated JAAS credentials because this service can only be
accessed from within the same VM.- See Also:
- Generated:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic CommerceDiscount
addCommerceDiscount
(long userId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) static CommerceDiscount
addCommerceDiscount
(long userId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, String externalReferenceCode, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) Deprecated.static CommerceDiscount
addCommerceDiscount
(long userId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, int limitationTimesPerAccount, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, String externalReferenceCode, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) Deprecated.As of Cavanaugh (7.4.x), replaced by#addCommerceDiscount(String, long, String, String, boolean, String, boolean, BigDecimal, String, BigDecimal, BigDecimal, BigDecimal, BigDecimal, BigDecimal, String, int, int, boolean, boolean, int, int, int, int, int, int, int, int, int, int, boolean, ServiceContext)
static CommerceDiscount
addCommerceDiscount
(long userId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) static CommerceDiscount
addCommerceDiscount
(CommerceDiscount commerceDiscount) Adds the commerce discount to the database.static CommerceDiscount
addCommerceDiscount
(String externalReferenceCode, long userId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) static CommerceDiscount
addCommerceDiscount
(String externalReferenceCode, long userId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, int limitationTimesPerAccount, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) static CommerceDiscount
addOrUpdateCommerceDiscount
(String externalReferenceCode, long userId, long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) static CommerceDiscount
addOrUpdateCommerceDiscount
(String externalReferenceCode, long userId, long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, int limitationTimesPerAccount, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) static CommerceDiscount
addOrUpdateCommerceDiscount
(String externalReferenceCode, long userId, long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) static void
static CommerceDiscount
createCommerceDiscount
(long commerceDiscountId) Creates a new commerce discount with the primary key.static com.liferay.portal.kernel.model.PersistedModel
createPersistedModel
(Serializable primaryKeyObj) static CommerceDiscount
deleteCommerceDiscount
(long commerceDiscountId) Deletes the commerce discount with the primary key from the database.static CommerceDiscount
deleteCommerceDiscount
(CommerceDiscount commerceDiscount) Deletes the commerce discount from the database.static void
deleteCommerceDiscounts
(long companyId) static com.liferay.portal.kernel.model.PersistedModel
deletePersistedModel
(com.liferay.portal.kernel.model.PersistedModel persistedModel) static <T> T
dslQuery
(com.liferay.petra.sql.dsl.query.DSLQuery dslQuery) static int
dslQueryCount
(com.liferay.petra.sql.dsl.query.DSLQuery dslQuery) static com.liferay.portal.kernel.dao.orm.DynamicQuery
static <T> List<T>
dynamicQuery
(com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) Performs a dynamic query on the database and returns the matching rows.static <T> List<T>
dynamicQuery
(com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, int end) Performs a dynamic query on the database and returns a range of the matching rows.static <T> List<T>
dynamicQuery
(com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, int end, com.liferay.portal.kernel.util.OrderByComparator<T> orderByComparator) Performs a dynamic query on the database and returns an ordered range of the matching rows.static long
dynamicQueryCount
(com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) Returns the number of rows matching the dynamic query.static long
dynamicQueryCount
(com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, com.liferay.portal.kernel.dao.orm.Projection projection) Returns the number of rows matching the dynamic query.static CommerceDiscount
fetchCommerceDiscount
(long commerceDiscountId) static CommerceDiscount
fetchCommerceDiscountByExternalReferenceCode
(String externalReferenceCode, long companyId) static CommerceDiscount
fetchCommerceDiscountByUuidAndCompanyId
(String uuid, long companyId) Returns the commerce discount with the matching UUID and company.static CommerceDiscount
fetchDefaultCommerceDiscount
(long commerceChannelAccountEntryRelId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) static List<CommerceDiscount>
getAccountAndChannelAndOrderTypeCommerceDiscounts
(long commerceAccountId, long commerceChannelId, long commerceOrderTypeId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) static List<CommerceDiscount>
getAccountAndChannelAndOrderTypeCommerceDiscounts
(long commerceAccountId, long commerceChannelId, long commerceOrderTypeId, String target) static List<CommerceDiscount>
getAccountAndChannelCommerceDiscounts
(long commerceAccountId, long commerceChannelId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) static List<CommerceDiscount>
getAccountAndChannelCommerceDiscounts
(long commerceAccountId, long commerceChannelId, String target) static List<CommerceDiscount>
getAccountAndOrderTypeCommerceDiscounts
(long commerceAccountId, long commerceOrderTypeId, String target) static List<CommerceDiscount>
getAccountCommerceAndOrderTypeDiscounts
(long commerceAccountId, long commerceOrderTypeId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) static List<CommerceDiscount>
getAccountCommerceDiscounts
(long commerceAccountId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) static List<CommerceDiscount>
getAccountCommerceDiscounts
(long commerceAccountId, String target) static List<CommerceDiscount>
getAccountGroupAndChannelAndOrderTypeCommerceDiscount
(long[] commerceAccountGroupIds, long commerceChannelId, long commerceOrderTypeId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) static List<CommerceDiscount>
getAccountGroupAndChannelAndOrderTypeCommerceDiscount
(long[] commerceAccountGroupIds, long commerceChannelId, long commerceOrderTypeId, String target) static List<CommerceDiscount>
getAccountGroupAndChannelCommerceDiscount
(long[] commerceAccountGroupIds, long commerceChannelId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) static List<CommerceDiscount>
getAccountGroupAndChannelCommerceDiscount
(long[] commerceAccountGroupIds, long commerceChannelId, String target) static List<CommerceDiscount>
getAccountGroupAndOrderTypeCommerceDiscount
(long[] commerceAccountGroupIds, long commerceOrderTypeId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) static List<CommerceDiscount>
getAccountGroupAndOrderTypeCommerceDiscount
(long[] commerceAccountGroupIds, long commerceOrderTypeId, String target) static List<CommerceDiscount>
getAccountGroupCommerceDiscount
(long[] commerceAccountGroupIds, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) static List<CommerceDiscount>
getAccountGroupCommerceDiscount
(long[] commerceAccountGroupIds, String target) static com.liferay.portal.kernel.dao.orm.ActionableDynamicQuery
static CommerceDiscount
getActiveCommerceDiscount
(long companyId, String couponCode, boolean active) static int
getActiveCommerceDiscountsCount
(long companyId, String couponCode, boolean active) static List<CommerceDiscount>
getChannelAndOrderTypeCommerceDiscounts
(long commerceChannelId, long commerceOrderTypeId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) static List<CommerceDiscount>
getChannelAndOrderTypeCommerceDiscounts
(long commerceChannelId, long commerceOrderTypeId, String target) static List<CommerceDiscount>
getChannelCommerceDiscounts
(long commerceChannelId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) static List<CommerceDiscount>
getChannelCommerceDiscounts
(long commerceChannelId, String target) static CommerceDiscount
getCommerceDiscount
(long commerceDiscountId) Returns the commerce discount with the primary key.static CommerceDiscount
getCommerceDiscountByExternalReferenceCode
(String externalReferenceCode, long companyId) static CommerceDiscount
getCommerceDiscountByUuidAndCompanyId
(String uuid, long companyId) Returns the commerce discount with the matching UUID and company.static List<CommerceDiscount>
getCommerceDiscounts
(int start, int end) Returns a range of all the commerce discounts.static List<CommerceDiscount>
getCommerceDiscounts
(long companyId, String couponCode) Deprecated.As of Athanasius (7.3.x)static List<CommerceDiscount>
getCommerceDiscounts
(long companyId, String level, boolean active, int status) static int
Returns the number of commerce discounts.static int
getCommerceDiscountsCount
(long companyId, String couponCode) Deprecated.As of Athanasius (7.3.x)static int
getCommerceDiscountsCountByPricingClassId
(long commercePricingClassId, String title) static com.liferay.portal.kernel.dao.orm.ExportActionableDynamicQuery
getExportActionableDynamicQuery
(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext) static com.liferay.portal.kernel.dao.orm.IndexableActionableDynamicQuery
static List<CommerceDiscount>
getOrderTypeCommerceDiscounts
(long commerceOrderTypeId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) static List<CommerceDiscount>
getOrderTypeCommerceDiscounts
(long commerceOrderTypeId, String target) static String
Returns the OSGi service identifier.static com.liferay.portal.kernel.model.PersistedModel
getPersistedModel
(Serializable primaryKeyObj) static List<CommerceDiscount>
getPriceListCommerceDiscounts
(long[] commerceDiscountIds, long cpDefinitionId) static CommerceDiscountLocalService
static List<CommerceDiscount>
getUnqualifiedCommerceDiscounts
(long companyId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) static List<CommerceDiscount>
getUnqualifiedCommerceDiscounts
(long companyId, String target) static int
getValidCommerceDiscountsCount
(long commerceAccountId, long[] commerceAccountGroupIds, long commerceChannelId, long commerceDiscountId) static int
getValidCommerceDiscountsCount
(long commerceDiscountId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) static CommerceDiscount
incrementCommerceDiscountNumberOfUse
(long commerceDiscountId) static List<CommerceDiscount>
searchByCommercePricingClassId
(long commercePricingClassId, String title, int start, int end) static com.liferay.portal.kernel.search.BaseModelSearchResult<CommerceDiscount>
searchCommerceDiscounts
(long companyId, long[] groupIds, String keywords, int status, int start, int end, com.liferay.portal.kernel.search.Sort sort) static com.liferay.portal.kernel.search.BaseModelSearchResult<CommerceDiscount>
searchCommerceDiscounts
(com.liferay.portal.kernel.search.SearchContext searchContext) static CommerceDiscount
updateCommerceDiscount
(long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) static CommerceDiscount
updateCommerceDiscount
(long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, int limitationTimesPerAccount, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) static CommerceDiscount
updateCommerceDiscount
(long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) static CommerceDiscount
updateCommerceDiscount
(CommerceDiscount commerceDiscount) Updates the commerce discount in the database or adds it if it does not yet exist.static CommerceDiscount
updateCommerceDiscountExternalReferenceCode
(long commerceDiscountId, String externalReferenceCode) Deprecated.As of Cavanaugh (7.4.x), replaced byupdateCommerceDiscountExternalReferenceCode(String, long)
static CommerceDiscount
updateCommerceDiscountExternalReferenceCode
(String externalReferenceCode, long commerceDiscountId) static CommerceDiscount
updateStatus
(long userId, long commerceDiscountId, int status, com.liferay.portal.kernel.service.ServiceContext serviceContext, Map<String, Serializable> workflowContext) static CommerceDiscount
upsertCommerceDiscount
(long userId, long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, String externalReferenceCode, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) Deprecated.As of Cavanaugh (7.4.x), replaced byaddOrUpdateCommerceDiscount(String, long, long, String, String, boolean, String, boolean, BigDecimal, String, BigDecimal, BigDecimal, BigDecimal, BigDecimal, String, int, boolean, boolean, int, int, int, int, int, int, int, int, int, int, boolean, ServiceContext)
static CommerceDiscount
upsertCommerceDiscount
(long userId, long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, int limitationTimesPerAccount, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, String externalReferenceCode, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) Deprecated.As of Cavanaugh (7.4.x), replaced byaddOrUpdateCommerceDiscount(String, long, long, String, String, boolean, String, boolean, BigDecimal, String, BigDecimal, BigDecimal, BigDecimal, BigDecimal, String, int, int, boolean, boolean, int, int, int, int, int, int, int, int, int, int, boolean, ServiceContext)
static CommerceDiscount
upsertCommerceDiscount
(long userId, long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, String externalReferenceCode, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext)
-
Constructor Details
-
CommerceDiscountLocalServiceUtil
public CommerceDiscountLocalServiceUtil()
-
-
Method Details
-
addCommerceDiscount
Adds the commerce discount to the database. Also notifies the appropriate model listeners.Important: Inspect CommerceDiscountLocalServiceImpl for overloaded versions of the method. If provided, use these entry points to the API, as the implementation logic may require the additional parameters defined there.
- Parameters:
commerceDiscount
- the commerce discount- Returns:
- the commerce discount that was added
-
addCommerceDiscount
public static CommerceDiscount addCommerceDiscount(long userId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
addCommerceDiscount
public static CommerceDiscount addCommerceDiscount(long userId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
addCommerceDiscount
@Deprecated public static CommerceDiscount addCommerceDiscount(long userId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, String externalReferenceCode, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException Deprecated.- Throws:
com.liferay.portal.kernel.exception.PortalException
-
addCommerceDiscount
@Deprecated public static CommerceDiscount addCommerceDiscount(long userId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, int limitationTimesPerAccount, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, String externalReferenceCode, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException Deprecated.As of Cavanaugh (7.4.x), replaced by#addCommerceDiscount(String, long, String, String, boolean, String, boolean, BigDecimal, String, BigDecimal, BigDecimal, BigDecimal, BigDecimal, BigDecimal, String, int, int, boolean, boolean, int, int, int, int, int, int, int, int, int, int, boolean, ServiceContext)
- Throws:
com.liferay.portal.kernel.exception.PortalException
-
addCommerceDiscount
public static CommerceDiscount addCommerceDiscount(String externalReferenceCode, long userId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
addCommerceDiscount
public static CommerceDiscount addCommerceDiscount(String externalReferenceCode, long userId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, int limitationTimesPerAccount, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
addOrUpdateCommerceDiscount
public static CommerceDiscount addOrUpdateCommerceDiscount(String externalReferenceCode, long userId, long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
addOrUpdateCommerceDiscount
public static CommerceDiscount addOrUpdateCommerceDiscount(String externalReferenceCode, long userId, long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
addOrUpdateCommerceDiscount
public static CommerceDiscount addOrUpdateCommerceDiscount(String externalReferenceCode, long userId, long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, int limitationTimesPerAccount, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
checkCommerceDiscounts
public static void checkCommerceDiscounts() throws com.liferay.portal.kernel.exception.PortalException- Throws:
com.liferay.portal.kernel.exception.PortalException
-
createCommerceDiscount
Creates a new commerce discount with the primary key. Does not add the commerce discount to the database.- Parameters:
commerceDiscountId
- the primary key for the new commerce discount- Returns:
- the new commerce discount
-
createPersistedModel
public static com.liferay.portal.kernel.model.PersistedModel createPersistedModel(Serializable primaryKeyObj) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
deleteCommerceDiscount
public static CommerceDiscount deleteCommerceDiscount(CommerceDiscount commerceDiscount) throws com.liferay.portal.kernel.exception.PortalException Deletes the commerce discount from the database. Also notifies the appropriate model listeners.Important: Inspect CommerceDiscountLocalServiceImpl for overloaded versions of the method. If provided, use these entry points to the API, as the implementation logic may require the additional parameters defined there.
- Parameters:
commerceDiscount
- the commerce discount- Returns:
- the commerce discount that was removed
- Throws:
com.liferay.portal.kernel.exception.PortalException
-
deleteCommerceDiscount
public static CommerceDiscount deleteCommerceDiscount(long commerceDiscountId) throws com.liferay.portal.kernel.exception.PortalException Deletes the commerce discount with the primary key from the database. Also notifies the appropriate model listeners.Important: Inspect CommerceDiscountLocalServiceImpl for overloaded versions of the method. If provided, use these entry points to the API, as the implementation logic may require the additional parameters defined there.
- Parameters:
commerceDiscountId
- the primary key of the commerce discount- Returns:
- the commerce discount that was removed
- Throws:
com.liferay.portal.kernel.exception.PortalException
- if a commerce discount with the primary key could not be found
-
deleteCommerceDiscounts
public static void deleteCommerceDiscounts(long companyId) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
deletePersistedModel
public static com.liferay.portal.kernel.model.PersistedModel deletePersistedModel(com.liferay.portal.kernel.model.PersistedModel persistedModel) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
dslQuery
public static <T> T dslQuery(com.liferay.petra.sql.dsl.query.DSLQuery dslQuery) -
dslQueryCount
public static int dslQueryCount(com.liferay.petra.sql.dsl.query.DSLQuery dslQuery) -
dynamicQuery
public static com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery() -
dynamicQuery
Performs a dynamic query on the database and returns the matching rows.- Parameters:
dynamicQuery
- the dynamic query- Returns:
- the matching rows
-
dynamicQuery
public static <T> List<T> dynamicQuery(com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, int end) Performs a dynamic query on the database and returns a range of the matching rows.Useful when paginating results. Returns a maximum of
end - start
instances.start
andend
are not primary keys, they are indexes in the result set. Thus,0
refers to the first result in the set. Setting bothstart
andend
tocom.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS
will return the full result set. IforderByComparator
is specified, then the query will include the given ORDER BY logic. IforderByComparator
is absent, then the query will include the default ORDER BY logic fromcom.liferay.commerce.discount.model.impl.CommerceDiscountModelImpl
.- Parameters:
dynamicQuery
- the dynamic querystart
- the lower bound of the range of model instancesend
- the upper bound of the range of model instances (not inclusive)- Returns:
- the range of matching rows
-
dynamicQuery
public static <T> List<T> dynamicQuery(com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, int end, com.liferay.portal.kernel.util.OrderByComparator<T> orderByComparator) Performs a dynamic query on the database and returns an ordered range of the matching rows.Useful when paginating results. Returns a maximum of
end - start
instances.start
andend
are not primary keys, they are indexes in the result set. Thus,0
refers to the first result in the set. Setting bothstart
andend
tocom.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS
will return the full result set. IforderByComparator
is specified, then the query will include the given ORDER BY logic. IforderByComparator
is absent, then the query will include the default ORDER BY logic fromcom.liferay.commerce.discount.model.impl.CommerceDiscountModelImpl
.- Parameters:
dynamicQuery
- the dynamic querystart
- the lower bound of the range of model instancesend
- the upper bound of the range of model instances (not inclusive)orderByComparator
- the comparator to order the results by (optionallynull
)- Returns:
- the ordered range of matching rows
-
dynamicQueryCount
public static long dynamicQueryCount(com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) Returns the number of rows matching the dynamic query.- Parameters:
dynamicQuery
- the dynamic query- Returns:
- the number of rows matching the dynamic query
-
dynamicQueryCount
public static long dynamicQueryCount(com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, com.liferay.portal.kernel.dao.orm.Projection projection) Returns the number of rows matching the dynamic query.- Parameters:
dynamicQuery
- the dynamic queryprojection
- the projection to apply to the query- Returns:
- the number of rows matching the dynamic query
-
fetchCommerceDiscount
-
fetchCommerceDiscountByExternalReferenceCode
public static CommerceDiscount fetchCommerceDiscountByExternalReferenceCode(String externalReferenceCode, long companyId) -
fetchCommerceDiscountByUuidAndCompanyId
Returns the commerce discount with the matching UUID and company.- Parameters:
uuid
- the commerce discount's UUIDcompanyId
- the primary key of the company- Returns:
- the matching commerce discount, or
null
if a matching commerce discount could not be found
-
fetchDefaultCommerceDiscount
public static CommerceDiscount fetchDefaultCommerceDiscount(long commerceChannelAccountEntryRelId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) -
getAccountAndChannelAndOrderTypeCommerceDiscounts
public static List<CommerceDiscount> getAccountAndChannelAndOrderTypeCommerceDiscounts(long commerceAccountId, long commerceChannelId, long commerceOrderTypeId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) -
getAccountAndChannelAndOrderTypeCommerceDiscounts
public static List<CommerceDiscount> getAccountAndChannelAndOrderTypeCommerceDiscounts(long commerceAccountId, long commerceChannelId, long commerceOrderTypeId, String target) -
getAccountAndChannelCommerceDiscounts
public static List<CommerceDiscount> getAccountAndChannelCommerceDiscounts(long commerceAccountId, long commerceChannelId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) -
getAccountAndChannelCommerceDiscounts
public static List<CommerceDiscount> getAccountAndChannelCommerceDiscounts(long commerceAccountId, long commerceChannelId, String target) -
getAccountAndOrderTypeCommerceDiscounts
public static List<CommerceDiscount> getAccountAndOrderTypeCommerceDiscounts(long commerceAccountId, long commerceOrderTypeId, String target) -
getAccountCommerceAndOrderTypeDiscounts
public static List<CommerceDiscount> getAccountCommerceAndOrderTypeDiscounts(long commerceAccountId, long commerceOrderTypeId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) -
getAccountCommerceDiscounts
public static List<CommerceDiscount> getAccountCommerceDiscounts(long commerceAccountId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) -
getAccountCommerceDiscounts
public static List<CommerceDiscount> getAccountCommerceDiscounts(long commerceAccountId, String target) -
getAccountGroupAndChannelAndOrderTypeCommerceDiscount
public static List<CommerceDiscount> getAccountGroupAndChannelAndOrderTypeCommerceDiscount(long[] commerceAccountGroupIds, long commerceChannelId, long commerceOrderTypeId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) -
getAccountGroupAndChannelAndOrderTypeCommerceDiscount
public static List<CommerceDiscount> getAccountGroupAndChannelAndOrderTypeCommerceDiscount(long[] commerceAccountGroupIds, long commerceChannelId, long commerceOrderTypeId, String target) -
getAccountGroupAndChannelCommerceDiscount
public static List<CommerceDiscount> getAccountGroupAndChannelCommerceDiscount(long[] commerceAccountGroupIds, long commerceChannelId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) -
getAccountGroupAndChannelCommerceDiscount
public static List<CommerceDiscount> getAccountGroupAndChannelCommerceDiscount(long[] commerceAccountGroupIds, long commerceChannelId, String target) -
getAccountGroupAndOrderTypeCommerceDiscount
public static List<CommerceDiscount> getAccountGroupAndOrderTypeCommerceDiscount(long[] commerceAccountGroupIds, long commerceOrderTypeId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) -
getAccountGroupAndOrderTypeCommerceDiscount
public static List<CommerceDiscount> getAccountGroupAndOrderTypeCommerceDiscount(long[] commerceAccountGroupIds, long commerceOrderTypeId, String target) -
getAccountGroupCommerceDiscount
public static List<CommerceDiscount> getAccountGroupCommerceDiscount(long[] commerceAccountGroupIds, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) -
getAccountGroupCommerceDiscount
public static List<CommerceDiscount> getAccountGroupCommerceDiscount(long[] commerceAccountGroupIds, String target) -
getActionableDynamicQuery
public static com.liferay.portal.kernel.dao.orm.ActionableDynamicQuery getActionableDynamicQuery() -
getActiveCommerceDiscount
public static CommerceDiscount getActiveCommerceDiscount(long companyId, String couponCode, boolean active) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
getActiveCommerceDiscountsCount
public static int getActiveCommerceDiscountsCount(long companyId, String couponCode, boolean active) -
getChannelAndOrderTypeCommerceDiscounts
public static List<CommerceDiscount> getChannelAndOrderTypeCommerceDiscounts(long commerceChannelId, long commerceOrderTypeId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) -
getChannelAndOrderTypeCommerceDiscounts
public static List<CommerceDiscount> getChannelAndOrderTypeCommerceDiscounts(long commerceChannelId, long commerceOrderTypeId, String target) -
getChannelCommerceDiscounts
public static List<CommerceDiscount> getChannelCommerceDiscounts(long commerceChannelId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) -
getChannelCommerceDiscounts
public static List<CommerceDiscount> getChannelCommerceDiscounts(long commerceChannelId, String target) -
getCommerceDiscount
public static CommerceDiscount getCommerceDiscount(long commerceDiscountId) throws com.liferay.portal.kernel.exception.PortalException Returns the commerce discount with the primary key.- Parameters:
commerceDiscountId
- the primary key of the commerce discount- Returns:
- the commerce discount
- Throws:
com.liferay.portal.kernel.exception.PortalException
- if a commerce discount with the primary key could not be found
-
getCommerceDiscountByExternalReferenceCode
public static CommerceDiscount getCommerceDiscountByExternalReferenceCode(String externalReferenceCode, long companyId) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
getCommerceDiscountByUuidAndCompanyId
public static CommerceDiscount getCommerceDiscountByUuidAndCompanyId(String uuid, long companyId) throws com.liferay.portal.kernel.exception.PortalException Returns the commerce discount with the matching UUID and company.- Parameters:
uuid
- the commerce discount's UUIDcompanyId
- the primary key of the company- Returns:
- the matching commerce discount
- Throws:
com.liferay.portal.kernel.exception.PortalException
- if a matching commerce discount could not be found
-
getCommerceDiscounts
Returns a range of all the commerce discounts.Useful when paginating results. Returns a maximum of
end - start
instances.start
andend
are not primary keys, they are indexes in the result set. Thus,0
refers to the first result in the set. Setting bothstart
andend
tocom.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS
will return the full result set. IforderByComparator
is specified, then the query will include the given ORDER BY logic. IforderByComparator
is absent, then the query will include the default ORDER BY logic fromcom.liferay.commerce.discount.model.impl.CommerceDiscountModelImpl
.- Parameters:
start
- the lower bound of the range of commerce discountsend
- the upper bound of the range of commerce discounts (not inclusive)- Returns:
- the range of commerce discounts
-
getCommerceDiscounts
@Deprecated public static List<CommerceDiscount> getCommerceDiscounts(long companyId, String couponCode) Deprecated.As of Athanasius (7.3.x) -
getCommerceDiscounts
public static List<CommerceDiscount> getCommerceDiscounts(long companyId, String level, boolean active, int status) -
getCommerceDiscountsCount
public static int getCommerceDiscountsCount()Returns the number of commerce discounts.- Returns:
- the number of commerce discounts
-
getCommerceDiscountsCount
Deprecated.As of Athanasius (7.3.x) -
getCommerceDiscountsCountByPricingClassId
public static int getCommerceDiscountsCountByPricingClassId(long commercePricingClassId, String title) -
getExportActionableDynamicQuery
public static com.liferay.portal.kernel.dao.orm.ExportActionableDynamicQuery getExportActionableDynamicQuery(com.liferay.exportimport.kernel.lar.PortletDataContext portletDataContext) -
getIndexableActionableDynamicQuery
public static com.liferay.portal.kernel.dao.orm.IndexableActionableDynamicQuery getIndexableActionableDynamicQuery() -
getOrderTypeCommerceDiscounts
public static List<CommerceDiscount> getOrderTypeCommerceDiscounts(long commerceOrderTypeId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) -
getOrderTypeCommerceDiscounts
public static List<CommerceDiscount> getOrderTypeCommerceDiscounts(long commerceOrderTypeId, String target) -
getOSGiServiceIdentifier
Returns the OSGi service identifier.- Returns:
- the OSGi service identifier
-
getPersistedModel
public static com.liferay.portal.kernel.model.PersistedModel getPersistedModel(Serializable primaryKeyObj) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
getPriceListCommerceDiscounts
public static List<CommerceDiscount> getPriceListCommerceDiscounts(long[] commerceDiscountIds, long cpDefinitionId) -
getUnqualifiedCommerceDiscounts
public static List<CommerceDiscount> getUnqualifiedCommerceDiscounts(long companyId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) -
getUnqualifiedCommerceDiscounts
-
getValidCommerceDiscountsCount
public static int getValidCommerceDiscountsCount(long commerceDiscountId, long cpDefinitionId, long cpInstanceId, String unitOfMeasureKey) -
getValidCommerceDiscountsCount
public static int getValidCommerceDiscountsCount(long commerceAccountId, long[] commerceAccountGroupIds, long commerceChannelId, long commerceDiscountId) -
incrementCommerceDiscountNumberOfUse
public static CommerceDiscount incrementCommerceDiscountNumberOfUse(long commerceDiscountId) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
searchByCommercePricingClassId
public static List<CommerceDiscount> searchByCommercePricingClassId(long commercePricingClassId, String title, int start, int end) -
searchCommerceDiscounts
public static com.liferay.portal.kernel.search.BaseModelSearchResult<CommerceDiscount> searchCommerceDiscounts(long companyId, long[] groupIds, String keywords, int status, int start, int end, com.liferay.portal.kernel.search.Sort sort) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
searchCommerceDiscounts
public static com.liferay.portal.kernel.search.BaseModelSearchResult<CommerceDiscount> searchCommerceDiscounts(com.liferay.portal.kernel.search.SearchContext searchContext) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
updateCommerceDiscount
Updates the commerce discount in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.Important: Inspect CommerceDiscountLocalServiceImpl for overloaded versions of the method. If provided, use these entry points to the API, as the implementation logic may require the additional parameters defined there.
- Parameters:
commerceDiscount
- the commerce discount- Returns:
- the commerce discount that was updated
-
updateCommerceDiscount
public static CommerceDiscount updateCommerceDiscount(long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
updateCommerceDiscount
public static CommerceDiscount updateCommerceDiscount(long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
updateCommerceDiscount
public static CommerceDiscount updateCommerceDiscount(long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, int limitationTimesPerAccount, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
updateCommerceDiscountExternalReferenceCode
@Deprecated public static CommerceDiscount updateCommerceDiscountExternalReferenceCode(long commerceDiscountId, String externalReferenceCode) throws com.liferay.portal.kernel.exception.PortalException Deprecated.As of Cavanaugh (7.4.x), replaced byupdateCommerceDiscountExternalReferenceCode(String, long)
- Throws:
com.liferay.portal.kernel.exception.PortalException
-
updateCommerceDiscountExternalReferenceCode
public static CommerceDiscount updateCommerceDiscountExternalReferenceCode(String externalReferenceCode, long commerceDiscountId) throws com.liferay.portal.kernel.exception.PortalException - Throws:
com.liferay.portal.kernel.exception.PortalException
-
updateStatus
public static CommerceDiscount updateStatus(long userId, long commerceDiscountId, int status, com.liferay.portal.kernel.service.ServiceContext serviceContext, Map<String, Serializable> workflowContext) throws com.liferay.portal.kernel.exception.PortalException- Throws:
com.liferay.portal.kernel.exception.PortalException
-
upsertCommerceDiscount
@Deprecated public static CommerceDiscount upsertCommerceDiscount(long userId, long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, String externalReferenceCode, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException Deprecated.- Throws:
com.liferay.portal.kernel.exception.PortalException
-
upsertCommerceDiscount
@Deprecated public static CommerceDiscount upsertCommerceDiscount(long userId, long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, String externalReferenceCode, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException Deprecated.As of Cavanaugh (7.4.x), replaced byaddOrUpdateCommerceDiscount(String, long, long, String, String, boolean, String, boolean, BigDecimal, String, BigDecimal, BigDecimal, BigDecimal, BigDecimal, String, int, boolean, boolean, int, int, int, int, int, int, int, int, int, int, boolean, ServiceContext)
- Throws:
com.liferay.portal.kernel.exception.PortalException
-
upsertCommerceDiscount
@Deprecated public static CommerceDiscount upsertCommerceDiscount(long userId, long commerceDiscountId, String title, String target, boolean useCouponCode, String couponCode, boolean usePercentage, BigDecimal maximumDiscountAmount, String level, BigDecimal level1, BigDecimal level2, BigDecimal level3, BigDecimal level4, String limitationType, int limitationTimes, int limitationTimesPerAccount, boolean rulesConjunction, boolean active, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int displayDateMinute, int expirationDateMonth, int expirationDateDay, int expirationDateYear, int expirationDateHour, int expirationDateMinute, String externalReferenceCode, boolean neverExpire, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException Deprecated.As of Cavanaugh (7.4.x), replaced byaddOrUpdateCommerceDiscount(String, long, long, String, String, boolean, String, boolean, BigDecimal, String, BigDecimal, BigDecimal, BigDecimal, BigDecimal, String, int, int, boolean, boolean, int, int, int, int, int, int, int, int, int, int, boolean, ServiceContext)
- Throws:
com.liferay.portal.kernel.exception.PortalException
-
getService
-
addCommerceDiscount(String, long, String, String, boolean, String, boolean, BigDecimal, String, BigDecimal, BigDecimal, BigDecimal, BigDecimal, String, int, boolean, boolean, int, int, int, int, int, int, int, int, int, int, boolean, ServiceContext)