Feature: Extended user stats in user export csv

This commit is contained in:
Daniel Fernández 2014-10-31 15:21:43 -02:00
parent 22525ff74c
commit 757cea05a4

View File

@ -26,7 +26,10 @@ module Jobs
user_data.each do |user|
user_array = Array.new
group_names = get_group_names(user).join(';')
user_array.push(user['id']).push(user['name']).push(user['username']).push(user['email'])
user_array.push(user['id']).push(user['name']).push(user['username']).push(user['email']).push(user['created_at'])
.push(user.user_stat['topics_entered']).push(user.user_stat['posts_read_count']).push(user.user_stat['time_read'])
.push(user.user_stat['topic_count']).push(user.user_stat['post_count']).push(user.user_stat['likes_given'])
.push(user.user_stat['likes_received'])
user_array.push(group_names) if group_names != ''
data.push(user_array)
end