Let me preface this by saying this should absolutely be included with open atrium, either in the official OA release, or a re-roll. It is the vinegar to atrium's chips.

However when creating or commenting on nodes via email, Open Atrium's "recent activity" log shows all posts/comments as being submitted by Anonymous.

Any suggestions on where to start so for the correct user name to show up in recent activity?

The site is not using anonymous commenting, but is a small membership site where all users have accounts.

CommentFileSizeAuthor
Picture 1.png28.99 KBforestmars
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

kyle_mathews’s picture

Yum, chips with vinegar!

I'm not sure why OA would be doing that -- are the nodes / comments actually anonymous in the db?

forestmars’s picture

The UID is correct in the node table however node_revisions shows the UID for each of the posts as 0.

Thus, the published nodes have the correct author, but since the UID is 0 in node_revisions for all nodes created by og_mailinglist, the recent activity view in OA lists them all as created by anonymous.

What needs to be done for og_mailinglist to set the UID correctly in node_revisions?

kyle_mathews’s picture

So weird... this is a bug. I'd never noticed this problem before. I'll look into it later hopefully. Thanks for pointing it out.

forestmars’s picture

Took a cursory look for the problem here and didn't see it.

Anything I can do to move this issue forward, or any hints on where in the code the problem is?

clemens.tolboom’s picture

Subscribe and adding the development list responses

[Stock Response - Relates to issue ]

This relates to [#355421]

[Stock Response - Depends on ]

This issue depends on #398110: node_submit resets $node->uid for it's completion.

clemens.tolboom’s picture

In my http://drupal.org/project/node_factory module I set some default values.

See http://drupalcode.org/project/node_factory.git/blob_plain/refs/heads/mas...

function node_factory_create_node( $nodetype) 
...
  // default settings
  $edit['uid'] = $user->uid;
  $edit['name'] = $user->name;
  $edit['promote'] = in_array('promote', $node_type_default);
  $edit['comment'] = variable_get('comment_'. $edit['type'], 2);
  $edit['revision'] = in_array('revision', $node_type_default);
  $edit['format'] = FILTER_FORMAT_DEFAULT;
  $edit['status'] = in_array('status', $node_type_default);
...

Maybe that solves it.

ghostyzx’s picture

I'm having the same problem, does anyone have a fix?

My workaround for now is an ugly patch in the function node_save from modules/node/node.module

mahfiaz’s picture

PhpMyAdmin shows that nothing like this happens with D7.

mahfiaz’s picture

Issue summary: View changes
Status: Active » Closed (won't fix)

I think keeping this bug open serves no greater cause. Let's face the reality.