Make possible to map to the teaser

Aron Novak - August 18, 2009 - 08:47
Project:Feed Element Mapper
Version:6.x-2.x-dev
Component:Code
Category:task
Priority:normal
Assigned:Unassigned
Status:needs work
Description

It's trivial and why shouldn't we do that?
I committed a change to feedapi_node already, so that module won't mess with the teaser: http://drupal.org/node/491594#comment-1852122

AttachmentSize
map_teaser.patch1.38 KB

#1

Aron Novak - August 18, 2009 - 10:35
Priority:normal» critical

Should be in FeedAPI mapper 2.0 beta 1

#2

alex_b - August 23, 2009 - 00:06
Priority:critical» normal

Not critical for 2.0 beta 1.

How will this work when there are two different mappings to teaser and body? I'm not sure whether we can handle possible conflicts.

#3

gordon - August 23, 2009 - 23:56
Status:needs review» needs work

+++ mappers/feedapi_mapper_node.inc 18 Aug 2009 08:46:15 -0000
@@ -23,10 +23,10 @@ function node_feedapi_mapper($op, $feed_
-    return array('title' => t('Title'), 'created' => t('Published date'), 'body' => t('Body'), 'status' => t('Published state'));
+    return array('title' => t('Title'), 'created' => t('Published date'), 'body' => t('Body'), 'teaser' => t('Teaser'), 'status' => t('Published state'));

I think this should actually be put across multiple lines

Also the problem that this patch doesn't allow for is that fact that you can't map the same field to multiple places. In the case of the body and teaser I would think that most of the time the same thing will get mapped to both since most feeds are only the teasers.

This review is powered by Dreditor.

#4

Antinoo - October 18, 2009 - 22:28

Subscribing.
I'm getting empty teasers when retrieving nodes using FeedAPI+FeedElementMapper. :(

 
 

Drupal is a registered trademark of Dries Buytaert.