I have successfully extended Order with some custom fields and everything is working fine. I see all data being inserted into my extended entity.
But when I try to use my extended OrderImpl in confirmation.html, it is giving an exception. The error appears to be that Thymeleaf is getting NullOrderImpl instead of MyOrderImpl.
Any ideas how this can be fixed?
Here is my log:
[ WARN] org.broadleafcommerce.common.email.service.message.NullMessageCreator.sendMessage(NullMessageCreator.java:45) 13:57:52 NullMessageCreator - NullMessageCreator is defined -- specify a real message creator to send emails
[ INFO] com.mycompany.domain.order.MyOrderImpl.getId(MyOrderImpl.java:47) 13:57:52 MyOrderImpl - In Get order id:5551
[ INFO] com.mycompany.domain.order.MyOrderImpl.getCustomer(MyOrderImpl.java:59) 13:57:52 MyOrderImpl - Logging customer:org.broadleafcommerce.profile.core.domain.CustomerImpl@2d72ad3
[ WARN] org.mortbay.log.Slf4jLog.warn(Slf4jLog.java:76) 13:57:52 log - No trackers were found, not outputting Google Analytics script. Set the googleAnalytics.webPropertyId and/or the googleAnalytics.masterWebPropertyId system properties to output Google Analytics
[ERROR] org.thymeleaf.TemplateEngine.process(TemplateEngine.java:1085) 13:57:52 TemplateEngine - [THYMELEAF][http-nio-8443-exec-2] Exception processing template "layout/fullPageNoNavLayout": Exception evaluating SpringEL expression: "cart.warehouse.name" (checkout/confirmation:7)
Mar 24, 2015 1:57:52 PM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet [mycompany] in context with path [/sahaj] threw exception [Request processing failed; nested exception is org.thymeleaf.exceptions.TemplateProcessingException: Exception evaluating SpringEL expression: "cart.warehouse.name" (checkout/confirmation:7)] with root cause
org.springframework.expression.spel.SpelEvaluationException: EL1008E:(pos 5): Property or field 'warehouse' cannot be found on object of type 'org.broadleafcommerce.core.order.domain.NullOrderImpl' - maybe not public?
This forum is in readonly mode and serves as an archive of old information. All posting, registration and commenting abilities have been turned off. To get help, the Broadleaf team reguarly monitors the broadleaf-commerce tag on Stack Overflow so please ask your questions there.