Author: ashish
Date: Thu Jun 23 04:13:56 2016
New Revision: 1749809
URL:
http://svn.apache.org/viewvc?rev=1749809&view=revLog:
Applied patch from jira issue - OFBIZ-7308 - Add standard product features is not working from Quick Admin page.
Thanks Ravi for the contribution. Thanks Montalbano for your help in discussion.
Modified:
ofbiz/trunk/applications/product/src/org/ofbiz/product/product/ProductEvents.java
Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/product/ProductEvents.java
URL:
http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/product/ProductEvents.java?rev=1749809&r1=1749808&r2=1749809&view=diff==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/product/ProductEvents.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/product/ProductEvents.java Thu Jun 23 04:13:56 2016
@@ -875,9 +875,10 @@ public class ProductEvents {
Delegator delegator = (Delegator) request.getAttribute("delegator");
String productId = request.getParameter("productId");
String productFeatureApplTypeId = request.getParameter("productFeatureApplTypeId");
- String fromDate = request.getParameter("fromDate");
- if ((fromDate == null) || (fromDate.trim().length() == 0)) {
- fromDate = UtilDateTime.nowTimestamp().toString();
+ String fromDateStr = request.getParameter("fromDate");
+ Timestamp fromDate = UtilDateTime.nowTimestamp();
+ if (UtilValidate.isNotEmpty(fromDateStr)) {
+ fromDate = Timestamp.valueOf(fromDateStr);
}
String[] productFeatureIdArray = request.getParameterValues("productFeatureId");
if (productFeatureIdArray != null && productFeatureIdArray.length > 0) {