action_tracker.rb
557 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
require 'noosfero/i18n'
require 'action_tracker_config'
# ActionTracker plugin stuff
ActionTrackerConfig.verbs = {
  create_article: {
  },
  new_friendship: {
    type: :groupable
  },
  join_community: {
    type: :groupable
  },
  add_member_in_community: {
  },
  upload_image: {
    type: :groupable
  },
  leave_scrap: {
  },
  leave_scrap_to_self: {
  },
  reply_scrap_on_self: {
  },
  favorite_enterprise: {
  },
}
ActionTrackerConfig.current_user = proc do
  User.current.person rescue nil
end
ActionTrackerConfig.timeout = 24.hours