Uploaded image for project: 'PUBLIC - Liferay Commerce'
  1. PUBLIC - Liferay Commerce
  2. COMMERCE-6925

On the product Details page, data are not updated when selecting a product option

    Details

      Description

      Steps to reproduce:

      1. Create a site using Minium
      2. Navigate to Minium Catalog page
      3. Navigate to a product with multiple SKUs(e.g. Hoses or Brake Fluid)

      Case 1:

      Expected Behavior:

      On the product details page, data are updated when selecting a product option.

       The quantity selector is visible.

       If a product option different from the default one is selected and then added to the cart, the selected option should be visible on the mini-cart item.

      Actual Behavior:

       On the product details page, data are not updated when selecting a product option.

       The quantity selector is not visible.

      If a product option different from the default one is selected and then added to the cart, the option visible on the mini-cart item is the default one.

      Case 2:

      Expected Behavior:

      When there are no accounts active, Add to Cart button should be disabled.

      Actual Behavior:

       When there are no accounts active, Add to Cart button is active and can be clicked. When clicked, a danger alert is shown, an error is thrown by the browser console and this NPE is thrown by portal log:

      2021-07-19 16:24:42.448 ERROR [http-nio-8080-exec-2][ExceptionMapper:52] java.lang.NullPointerException2021-07-19 16:24:42.448 ERROR [http-nio-8080-exec-2][ExceptionMapper:52] java.lang.NullPointerExceptionjava.lang.NullPointerException: null at com.liferay.headless.commerce.delivery.cart.internal.resource.v1_0.CartResourceImpl._addCommerceOrder(CartResourceImpl.java:271) ~[?:?] at com.liferay.headless.commerce.delivery.cart.internal.resource.v1_0.CartResourceImpl.postChannelCart(CartResourceImpl.java:216) ~[?:?] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_221] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_221] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_221] at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_221] at org.apache.cxf.service.invoker.AbstractInvoker.performInvocation(AbstractInvoker.java:179) ~[bundleFile:3.4.3] at org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.java:96) ~[bundleFile:3.4.3] at org.apache.cxf.jaxrs.JAXRSInvoker.invoke(JAXRSInvoker.java:201) [bundleFile:3.4.3] at org.apache.cxf.jaxrs.JAXRSInvoker.invoke(JAXRSInvoker.java:104) [bundleFile:3.4.3] at org.apache.cxf.interceptor.ServiceInvokerInterceptor$1.run(ServiceInvokerInterceptor.java:59) [bundleFile:3.4.3] at org.apache.cxf.interceptor.ServiceInvokerInterceptor.handleMessage(ServiceInvokerInterceptor.java:96) [bundleFile:3.4.3] at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308) [bundleFile:3.4.3] at org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121) [bundleFile:3.4.3] at org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDestination.java:265) [bundleFile:3.4.3] at org.apache.cxf.transport.servlet.ServletController.invokeDestination(ServletController.java:234) [bundleFile:3.4.3] at org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:208) [bundleFile:3.4.3] at org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:160) [bundleFile:3.4.3] at org.apache.cxf.transport.servlet.CXFNonSpringServlet.invoke(CXFNonSpringServlet.java:225) [bundleFile:3.4.3] at org.apache.cxf.transport.servlet.AbstractHTTPServlet.handleRequest(AbstractHTTPServlet.java:298) [bundleFile:3.4.3] at org.apache.cxf.transport.servlet.AbstractHTTPServlet.doPost(AbstractHTTPServlet.java:217) [bundleFile:3.4.3] at javax.servlet.http.HttpServlet.service(HttpServlet.java:652) [servlet-api.jar:4.0.FR] at org.apache.cxf.transport.servlet.AbstractHTTPServlet.service(AbstractHTTPServlet.java:273) [bundleFile:3.4.3] at org.eclipse.equinox.http.servlet.internal.registration.EndpointRegistration.service(EndpointRegistration.java:153) [bundleFile:?] at org.eclipse.equinox.http.servlet.internal.servlet.FilterChainImpl.doFilter(FilterChainImpl.java:50) [bundleFile:?] at com.liferay.portal.security.auth.verifier.internal.tracker.AuthVerifierFilterTracker$RemoteAccessFilter.doFilter(AuthVerifierFilterTracker.java:164) [bundleFile:?] at org.eclipse.equinox.http.servlet.internal.registration.FilterRegistration.doFilter(FilterRegistration.java:121) [bundleFile:?] at org.eclipse.equinox.http.servlet.internal.servlet.FilterChainImpl.doFilter(FilterChainImpl.java:45) [bundleFile:?] at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:147) [portal-kernel.jar:?] at com.liferay.portal.servlet.filters.authverifier.AuthVerifierFilter.processFilter(AuthVerifierFilter.java:214) [portal-impl.jar:?] at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:49) [portal-kernel.jar:?] at org.eclipse.equinox.http.servlet.internal.registration.FilterRegistration.doFilter(FilterRegistration.java:121) [bundleFile:?] at org.eclipse.equinox.http.servlet.internal.servlet.FilterChainImpl.doFilter(FilterChainImpl.java:45) [bundleFile:?] at org.eclipse.equinox.http.servlet.internal.servlet.ResponseStateHandler.processRequest(ResponseStateHandler.java:71) [bundleFile:?] at org.eclipse.equinox.http.servlet.internal.context.DispatchTargets.doDispatch(DispatchTargets.java:120) [bundleFile:?] at org.eclipse.equinox.http.servlet.internal.HttpServiceRuntimeImpl.doDispatch(HttpServiceRuntimeImpl.java:372) [bundleFile:?] at org.eclipse.equinox.http.servlet.internal.servlet.ProxyServlet.service(ProxyServlet.java:70) [bundleFile:?] at javax.servlet.http.HttpServlet.service(HttpServlet.java:733) [servlet-api.jar:4.0.FR] at com.liferay.portal.module.framework.ModuleFrameworkServletAdapter.service(ModuleFrameworkServletAdapter.java:52) [portal-impl.jar:?] at javax.servlet.http.HttpServlet.service(HttpServlet.java:733) [servlet-api.jar:4.0.FR] at com.liferay.shielded.container.internal.proxy.ServletWrapper.service(ServletWrapper.java:113) [com.liferay.shielded.container.impl.jar:?] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:227) [catalina.jar:9.0.43] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162) [catalina.jar:9.0.43] at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53) [tomcat-websocket.jar:9.0.43] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189) [catalina.jar:9.0.43] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162) [catalina.jar:9.0.43] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:124) [portal-kernel.jar:?] at com.liferay.portal.remote.cors.internal.servlet.filter.PortalCORSServletFilter.processFilter(PortalCORSServletFilter.java:237) [bundleFile:?] at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:49) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:215) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:116) [portal-kernel.jar:?] at com.liferay.portal.servlet.filters.password.modified.PasswordModifiedFilter.processFilter(PasswordModifiedFilter.java:62) [portal-impl.jar:?] at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:49) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:215) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:116) [portal-kernel.jar:?] at com.liferay.portal.servlet.filters.lockout.LockoutFilter.processFilter(LockoutFilter.java:58) [portal-impl.jar:?] at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:49) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:215) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:116) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:147) [portal-kernel.jar:?] at com.liferay.portal.sharepoint.SharepointFilter.processFilter(SharepointFilter.java:88) [portal-impl.jar:?] at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:49) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:215) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:116) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:147) [portal-kernel.jar:?] at com.liferay.portal.servlet.filters.virtualhost.VirtualHostFilter.processFilter(VirtualHostFilter.java:248) [portal-impl.jar:?] at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:49) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:215) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:116) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDirectCallFilter(InvokerFilterChain.java:196) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:99) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDirectCallFilter(InvokerFilterChain.java:196) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:99) [portal-kernel.jar:?] at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:176) [urlrewritefilter.jar:4.0.4] at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:145) [urlrewritefilter.jar:4.0.4] at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:92) [urlrewritefilter.jar:4.0.4] at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:389) [urlrewritefilter.jar:4.0.4] at com.liferay.portal.servlet.filters.urlrewrite.UrlRewriteFilter.processFilter(UrlRewriteFilter.java:65) [portal-impl.jar:?] at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:49) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDoFilter(InvokerFilterChain.java:215) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:116) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDirectCallFilter(InvokerFilterChain.java:175) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:99) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDirectCallFilter(InvokerFilterChain.java:175) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:99) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.processDirectCallFilter(InvokerFilterChain.java:196) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:99) [portal-kernel.jar:?] at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.doFilter(InvokerFilter.java:104) [portal-kernel.jar:?] at com.liferay.shielded.container.internal.proxy.FilterWrapper.doFilter(FilterWrapper.java:79) [com.liferay.shielded.container.impl.jar:?] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189) [catalina.jar:9.0.43] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162) [catalina.jar:9.0.43] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:202) [catalina.jar:9.0.43] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:97) [catalina.jar:9.0.43] at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:542) [catalina.jar:9.0.43] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:143) [catalina.jar:9.0.43] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) [catalina.jar:9.0.43] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:78) [catalina.jar:9.0.43] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:346) [catalina.jar:9.0.43] at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:374) [tomcat-coyote.jar:9.0.43] at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65) [tomcat-coyote.jar:9.0.43] at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:887) [tomcat-coyote.jar:9.0.43] at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1684) [tomcat-coyote.jar:9.0.43] at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-coyote.jar:9.0.43] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_221] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_221] at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-util.jar:9.0.43] at java.lang.Thread.run(Thread.java:748) [?:1.8.0_221]
      

      Note: The 2 cases may have the same root cause.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              lorenzo.lapescara Lorenzo La Pescara
              Reporter:
              lorenzo.lapescara Lorenzo La Pescara
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Packages

                  Version Package
                  7.4.2 CE GA3
                  Master