OroCRM Forums

Covering OroCRM topics, including community updates and company announcements.

Forums Forums OroCRM OroCRM – Programming Questions How to extend the integration with magento process

This topic contains 4 replies, has 4 voices, and was last updated by  msulima 6 years, 11 months ago.

Starting from March 1, 2020 the forum has been switched to the read-only mode. Please head to StackOverflow for support.

  • Creator
    Topic
  • #25351

    adriwan_kenoby
    Participant

    Hi OroTeam,

    I would like to create a user associated to the MagentoUser.

    I think it is possible to customize the oro:cron:integration:sync command.

    How could I do ?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Author
    Replies
  • #25352

    Artem Liubeznyi
    Spectator

    Hi Adriwan,

    You should add a new API request that will create/update OroCRM users with data from Magento users. Please refer to our API documentation and use any other entity sync as an example.

    #25353

    Mike Kudelya
    Participant

    Hi

    As I understand, you want to sync Magento ‘admin_user’ table into Oro, right? If yes, then you need to research how import works. You should create a new job, a reader, a processor (it contains data converter, strategy and entity name), and a writer. Here is an example. These components connect to the Magento bridge, retrieve information, convert/process it (optional) and save to the database. Afterwards, create an API to access Magento users, update api.xml and wsdl.xml.

    #25354

    adriwan_kenoby
    Participant

    I would like to override the Magento sync process.

    For example I would like to create an Account per group which belong the magento_customer and for each magento_customer, like it already is, a contact.

    Could you provide me more informations about how can I do ?

    #25355

    msulima
    Moderator

    Hi. To achieve that you should create new bundle that will contain all customizations. That bundle should extend original MagentoBundle from crm.
    Then you should override logic in:
    channels.yml – add configuration for entity entity that you need to addinf it to the new channel. It will add new connector in the integration.
    processes.yml – you should add new process that should process new entity and disable old, that you want to override
    batch_jobs.yml – add configuration for processing import of new entity

    Of course on Magento side should be available API for needed entity. And you should override Oro\Bundle\MagentoBundle\Provider\TransportSoapTransport and add to it new method, that should be called for importing data of new entity.


Viewing 4 replies - 1 through 4 (of 4 total)

The forum ‘OroCRM – Programming Questions’ is closed to new topics and replies.

Back to top