If it were my project, I'd probably add this kind of custom field to
your mapping:

mapping = {
    # list the normal columns first... then:
    'full_name': ['user__first_name', 'user__last_name'],
}

Then your render code would be something like this:

    def render(self):
        for row in self._data:
            for name, value in self._mapping.items():
                print 'name: %s' % name
                if hasattr(value, '__iter__'):
                    final_value = []
                    for value2 in value:
                        final_value.append(getattr(row, value2))
                    final_value = ' '.join(final_value)
                else:
                    final_value = getattr(row, value)
                print 'final_value: %s' % final_value

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to