action_tracker.rb
603 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
45
46
47
48
49
50
51
52
require 'noosfero/i18n'
# 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: {
  },
  create_product: {
  },
  update_product: {
  },
  remove_product: {
  },
  favorite_enterprise: {
  },
}
ActionTrackerConfig.current_user = proc do
  User.current.person rescue nil
end
ActionTrackerConfig.timeout = 24.hours