3

I must create new cartridge for integration in BM but I don't want use pipelines. Can I use the controllers for this? If yes, please provide information on how to do this.

.

James Z
  • 12,209
  • 10
  • 24
  • 44
Bohdan K.
  • 33
  • 2

1 Answers1

2

Yes, you can. You need to create the bm_extensions.xml and add all the actions/entries.

Note: The file mention pipeline but It can actually be a Controller as you can see in the example I linked below.

<?xml version="1.0" encoding="ISO-8859-1" ?>
<extensions xmlns="http://www.demandware.com/xml/bmmodules/2007-12-11"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://www.demandware.com/xml/bmmodules/2007-12-11 bmext.xsd">

    <menuaction id="paypal_transactions_manager" menupath="orders" position="200" site="true">
        <name xml:lang="x-default">PayPal Transactions</name>
        <short_description xml:lang="x-default">Manage the PayPal transactions related with this site orders.</short_description>
        <description xml:lang="x-default">Manage the PayPal transactions related with this site orders.</description>
        <exec pipeline="PaypalAdmin" node="Orders" />
        <sub-pipelines>
            <pipeline name="PaypalAdmin-Orders" />
            <pipeline name="PaypalAdmin-OrderTransaction" />
            <pipeline name="PaypalAdmin-Action" />
            <pipeline name="PaypalAdmin-CreateNewTransaction" />
        </sub-pipelines>
        <icon>paypalbm/images/icon_transactions.png</icon>
    </menuaction>
</extensions>

PayPal Cartridge bm_paypal is a good example to understand how is done: https://github.com/SalesforceCommerceCloud/link_paypal/tree/master/cartridges/bm_paypal/cartridge

Ps: Let me know if you cannot access the link.

ddon-90
  • 2,816
  • 1
  • 20
  • 29
  • Hello, thank you for replying. I do not have access to the repository. May you grant access? Ps: My email is fletfast1107@gmail.com . – Bohdan K. Feb 25 '20 at 12:13
  • Please complete this module in order to get access to the repo: https://trailhead.salesforce.com/en/content/learn/modules/b2c-developer-resources-and-tools/b2c-developer-access-repositories?trail_id=develop-for-commerce-cloud – ddon-90 Feb 25 '20 at 12:15
  • Thank you, my friend gave me **bm_paypal**, i looked, you are right. I will try to create a new cartridge based on it. After that I made sure to apply for access to the repository.if there are problems that I cannot solve, I will write here. – Bohdan K. Feb 25 '20 at 12:48