OroCRM Forums

Covering OroCRM topics, including community updates and company announcements.

Forums Forums OroCRM OroCRM – How do I? Questions Edit data before exporting to csv

This topic contains 4 replies, has 2 voices, and was last updated by  oro_newbie 6 years, 8 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
  • #29322

    oro_newbie
    Participant

    Hi,

    Is it possible to edit the data that is being exported? The reason for this is, in the Case Entity our descriptions are too long, so I do the following in datagrid to hide if it’s more than 60 characters:

    so when we export the cases records to csv, the description in the csv file is only of 60 characters. Therefore, I would like to know if it’s possible to get the full description only during export? I think we would often have cases anyway where we need to modify the data being exported.

    Not sure whether I need the Processor or the StrategyEvent to get this job done. The steps are confusing as well. Please advise!

    Thank you in advance.

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

    Dmitriy Pasechnik
    Participant

    Hi, oro_newbie

    Almost. You need to create your own normalizer to achieve this.
    Look at this documentation: https://github.com/orocrm/platform/blob/master/src/Oro/Bundle/ImportExportBundle/Resources/doc/index.md
    And then look at this example: https://github.com/orocommerce/orocommerce/blob/master/src/Oro/Bundle/ProductBundle/ImportExport/Normalizer/ProductNormalizer.php#L46 (its for orocommerce project, but in this case it doesnt matter – they are identical in terms of importexport functionality).

    #29324

    oro_newbie
    Participant

    Hi Dmitriy,

    I tried creating a custom normalizer but it doesn’t seem to pick any changes from this new file:

    and in my Custom\Bundle\CaseBundle\Resources\config\importexport.yml:

    Is there anything more that needs to be added?

    #29325

    oro_newbie
    Participant

    Bump. Anyone please?

    #29326

    oro_newbie
    Participant

    Bump. Is there a way I can see the normalizer that’s actually being used?

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

The forum ‘OroCRM – How do I? Questions’ is closed to new topics and replies.

Back to top