Skip to Content
author's profile photo Former Member
Former Member

Access a bean defined in b2ccheckoutaddon-web-spring.xml

Hi everyone,

I'm trying to access a bean defined in b2ccheckoutaddon-web-spring.xml but my AddOn can not see it. I already defined the in extensioninfo.xml, and I added the reference in merchandisecheckoutaddon-web-spring.xml - which is the xml for my extension.

The errro I'm getting is

Error creating bean with name 'merchandiseMultiFlowCheckoutGroup' defined in class path resource [merchandisecheckoutaddon/web/spring/merchandisecheckoutaddon-web-spring.xml]: Cannot resolve reference to bean 'multiStepCheckout' while setting bean property 'checkoutStepMap' with key [TypedStringValue: value [multi], target type [null]]; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'multiStepCheckout' is defined

Any idea what can happen?

Thanks.

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Jun 27, 2016 at 10:17 PM

    Did you look inside b2ccheckoutaddon-web-spring.xml to see if the multiStepCheckout bean is defined?

    If it is and you are still facing issues, a temporary issue might be to copy the bean defined in b2ccheckoutaddon-web-spring.xml into your merchandiseaddon-web-spring.xml

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Kyle.. Thanks for yout time on this.

      I tried to copy and paste the bean definition placed in b2ccheckoutaddon, but it start to complaining for more references, so I don't think that is a good approach.

      I just need to understand how to make visible one bean into the spring context, so it can be used in other addOn.

      Any idea on what else can I do ?

      Appreciate it.

  • author's profile photo Former Member
    Former Member
    Posted on Jun 28, 2016 at 04:49 PM
    -1

    Hi Kyle.. Thanks for yout time on this.

    I tried to copy and paste the bean definition placed in b2ccheckoutaddon, but it start to complaining for more references, so I don't think that is a good approach.

    I just need to understand how to make visible one bean into the spring context, so it can be used in other addOn.

    Any idea on what else can I do ?

    Appreciate it.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.