}
public SkuWrapper findDefaultSkuByProductId(HttpServletRequest request, Long id) {
Product product = catalogService.findProductById(id);
if (product != null && product.getDefaultSku() != null) {
SkuWrapper wrapper = (SkuWrapper)context.getBean(SkuWrapper.class.getName());
wrapper.wrapDetails(product.getDefaultSku(), request);
return wrapper;
}
throw BroadleafWebServicesException.build(Response.Status.NOT_FOUND.getStatusCode())
.addMessage(BroadleafWebServicesException.PRODUCT_NOT_FOUND, id);
}