I'm new to the Forena module but had a need to import data from a data block into custom entities for storage.

I watched the video here about doing feeds work: https://www.youtube.com/watch?v=bg4P747DmE8
During the mapping process it looked like the source values were available as textfields to place the Forena formatted values such as {id} for example.

I'm using the most recent versions of feeds and Forena but when trying to set up my mappings, the source value was a dropdown with only "Blank Value" as the single option.

I took a look at the Feeds CSV parser and it has an override function in the FeedsParser class to not get sources.

  /**
   * Override parent::getMappingSources().
   */
  public function getMappingSources() {
    return FALSE;
  }

I added this function to the FeedsForenaXMLParser.inc file and that did the trick. I now had text fields in the source area of the mapping configuration for my importer.
I completed the configuration using the replacement values for Forena and the import worked a treat.

I'm not sure if this is something that was introduced in the newer versions of feeds or not, but just wanted to pass it along in case someone else ran across it.

CommentFileSizeAuthor
#2 2696395-feeds-parser.patch374 bytesmetzlerd
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

jimmynash created an issue. See original summary.

metzlerd’s picture

Assigned: Unassigned » metzlerd
Status: Active » Needs review
FileSize
374 bytes

  • metzlerd committed 8ceaec5 on 7.x-4.x
    Issue #2696395 by metzlerd, jimmynash: Feeds Mapping Source
    
metzlerd’s picture

Status: Needs review » Fixed

Thanks for the catch!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.