Coder Social home page Coder Social logo

Comments (4)

AndreasA avatar AndreasA commented on April 28, 2024

also: is that controller actually necessary? why not just call the store api directly as I think shopware does also?

from adyen-shopware6.

peterojo avatar peterojo commented on April 28, 2024

@AndreasA this controller was created only to be able to access store-api routes from our frontend components in shopware 6.5 and this is necessary because of this change

from adyen-shopware6.

AndreasA avatar AndreasA commented on April 28, 2024

Hi @peterojo

Ok. So did not add another solution regarding proxy routing except to implement a corresponding contorller manually. Weird.

Anyway, my main point was that if I use a service decoration for e.g. Shopware\Core\Checkout\Cart\SalesChannel\CartOrderRoute like:

namespace Foo;

public class DecoratedCartOrderRoute extends AbstractCartOrder {
   ....
}
<?xml version="1.0" encoding="UTF-8" ?>
<container xmlns="http://symfony.com/schema/dic/services"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema-instance"
    xsd:schemaLocation="http://symfony.com/schema/dic/services https://symfony.com/schema/dic/services/services-1.0.xsd">
    <services>
        <service id="Foo\DecoratedCartOrderRoute "
            decorates="Shopware\Core\Checkout\Cart\SalesChannel\CartOrderRoute"
        />
    </services>
</container>

Routes like /adyen/proxy-switch-context will fail to work as the controller expects the property to be of the type CartOrderRoute not AbstractCartOrderRoute

from adyen-shopware6.

AndreasA avatar AndreasA commented on April 28, 2024

@peterojo I could create a PR for this, it should be quite straight forward.

from adyen-shopware6.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.