1
19
20 package com.liferay.portlet.shopping.service;
21
22
23
44 public class ShoppingCouponLocalServiceUtil {
45 public static com.liferay.portlet.shopping.model.ShoppingCoupon addShoppingCoupon(
46 com.liferay.portlet.shopping.model.ShoppingCoupon shoppingCoupon)
47 throws com.liferay.portal.SystemException {
48 return getService().addShoppingCoupon(shoppingCoupon);
49 }
50
51 public static com.liferay.portlet.shopping.model.ShoppingCoupon createShoppingCoupon(
52 long couponId) {
53 return getService().createShoppingCoupon(couponId);
54 }
55
56 public static void deleteShoppingCoupon(long couponId)
57 throws com.liferay.portal.PortalException,
58 com.liferay.portal.SystemException {
59 getService().deleteShoppingCoupon(couponId);
60 }
61
62 public static void deleteShoppingCoupon(
63 com.liferay.portlet.shopping.model.ShoppingCoupon shoppingCoupon)
64 throws com.liferay.portal.SystemException {
65 getService().deleteShoppingCoupon(shoppingCoupon);
66 }
67
68 public static java.util.List<Object> dynamicQuery(
69 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
70 throws com.liferay.portal.SystemException {
71 return getService().dynamicQuery(dynamicQuery);
72 }
73
74 public static java.util.List<Object> dynamicQuery(
75 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
76 int end) throws com.liferay.portal.SystemException {
77 return getService().dynamicQuery(dynamicQuery, start, end);
78 }
79
80 public static com.liferay.portlet.shopping.model.ShoppingCoupon getShoppingCoupon(
81 long couponId)
82 throws com.liferay.portal.PortalException,
83 com.liferay.portal.SystemException {
84 return getService().getShoppingCoupon(couponId);
85 }
86
87 public static java.util.List<com.liferay.portlet.shopping.model.ShoppingCoupon> getShoppingCoupons(
88 int start, int end) throws com.liferay.portal.SystemException {
89 return getService().getShoppingCoupons(start, end);
90 }
91
92 public static int getShoppingCouponsCount()
93 throws com.liferay.portal.SystemException {
94 return getService().getShoppingCouponsCount();
95 }
96
97 public static com.liferay.portlet.shopping.model.ShoppingCoupon updateShoppingCoupon(
98 com.liferay.portlet.shopping.model.ShoppingCoupon shoppingCoupon)
99 throws com.liferay.portal.SystemException {
100 return getService().updateShoppingCoupon(shoppingCoupon);
101 }
102
103 public static com.liferay.portlet.shopping.model.ShoppingCoupon addCoupon(
104 long userId, long plid, java.lang.String code, boolean autoCode,
105 java.lang.String name, java.lang.String description,
106 int startDateMonth, int startDateDay, int startDateYear,
107 int startDateHour, int startDateMinute, int endDateMonth,
108 int endDateDay, int endDateYear, int endDateHour, int endDateMinute,
109 boolean neverExpire, boolean active, java.lang.String limitCategories,
110 java.lang.String limitSkus, double minOrder, double discount,
111 java.lang.String discountType)
112 throws com.liferay.portal.PortalException,
113 com.liferay.portal.SystemException {
114 return getService()
115 .addCoupon(userId, plid, code, autoCode, name, description,
116 startDateMonth, startDateDay, startDateYear, startDateHour,
117 startDateMinute, endDateMonth, endDateDay, endDateYear,
118 endDateHour, endDateMinute, neverExpire, active, limitCategories,
119 limitSkus, minOrder, discount, discountType);
120 }
121
122 public static void deleteCoupon(long couponId)
123 throws com.liferay.portal.PortalException,
124 com.liferay.portal.SystemException {
125 getService().deleteCoupon(couponId);
126 }
127
128 public static void deleteCoupons(long groupId)
129 throws com.liferay.portal.SystemException {
130 getService().deleteCoupons(groupId);
131 }
132
133 public static com.liferay.portlet.shopping.model.ShoppingCoupon getCoupon(
134 long couponId)
135 throws com.liferay.portal.PortalException,
136 com.liferay.portal.SystemException {
137 return getService().getCoupon(couponId);
138 }
139
140 public static com.liferay.portlet.shopping.model.ShoppingCoupon getCoupon(
141 java.lang.String code)
142 throws com.liferay.portal.PortalException,
143 com.liferay.portal.SystemException {
144 return getService().getCoupon(code);
145 }
146
147 public static java.util.List<com.liferay.portlet.shopping.model.ShoppingCoupon> search(
148 long plid, long companyId, java.lang.String code, boolean active,
149 java.lang.String discountType, boolean andOperator, int start, int end)
150 throws com.liferay.portal.SystemException {
151 return getService()
152 .search(plid, companyId, code, active, discountType,
153 andOperator, start, end);
154 }
155
156 public static int searchCount(long groupId, long companyId,
157 java.lang.String code, boolean active, java.lang.String discountType,
158 boolean andOperator) throws com.liferay.portal.SystemException {
159 return getService()
160 .searchCount(groupId, companyId, code, active, discountType,
161 andOperator);
162 }
163
164 public static com.liferay.portlet.shopping.model.ShoppingCoupon updateCoupon(
165 long userId, long couponId, java.lang.String name,
166 java.lang.String description, int startDateMonth, int startDateDay,
167 int startDateYear, int startDateHour, int startDateMinute,
168 int endDateMonth, int endDateDay, int endDateYear, int endDateHour,
169 int endDateMinute, boolean neverExpire, boolean active,
170 java.lang.String limitCategories, java.lang.String limitSkus,
171 double minOrder, double discount, java.lang.String discountType)
172 throws com.liferay.portal.PortalException,
173 com.liferay.portal.SystemException {
174 return getService()
175 .updateCoupon(userId, couponId, name, description,
176 startDateMonth, startDateDay, startDateYear, startDateHour,
177 startDateMinute, endDateMonth, endDateDay, endDateYear,
178 endDateHour, endDateMinute, neverExpire, active, limitCategories,
179 limitSkus, minOrder, discount, discountType);
180 }
181
182 public static ShoppingCouponLocalService getService() {
183 if (_service == null) {
184 throw new RuntimeException("ShoppingCouponLocalService is not set");
185 }
186
187 return _service;
188 }
189
190 public void setService(ShoppingCouponLocalService service) {
191 _service = service;
192 }
193
194 private static ShoppingCouponLocalService _service;
195 }