String productId = (String) orderItem.get("productId");
List<GenericValue> productContentList = delegator.findByAnd("ProductContent", UtilMisc.toMap("productId", productId, "productContentTypeId", "ONLINE_ACCESS"));
List<GenericValue> productContentListFiltered = EntityUtil.filterByDate(productContentList);
if (productContentListFiltered.size() > 0) {
context.put("productId", productId);
context.put("quantity", Integer.valueOf(qty.intValue()));
Map<String, Object> ctx = subscriptionModel.makeValid(context, "IN");
dispatcher.runSync("updateContentSubscriptionByProduct", ctx);
}
}
} catch (GenericEntityException e) {