Get record or page number for import

Comments

1 comment

  • Tyler Lamparter Principal Product Manager
    Awesome Follow-up
    Engaged
    Top Contributor
    Answer Pro
    Celigo University Level 4: Legendary

    Matt Carter I believe the only script to get pageIndex is with a preSavePage script on your export. Once you know that, you can use Celigo AI to write a quick script for you. Once you have that added, you can setup your mapper on your import.

    function preSavePage(options) {
      return {
        data: options.data.map((record, index) => ({ ...record, pageIndex: options.pageIndex, recordIndex: index })),
        errors: options.errors,
        abort: false,
        newErrorsAndRetryData: []
      };
    }
    0

Please sign in to leave a comment.