Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Rails: Record user activities without controller helpers, build on top of userstamps plugin

tree: ea929ac2be

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 lib
Octocat-spinner-32 README.markdown
Octocat-spinner-32 init.rb shuld work...
README.markdown

Problem

  • Activity loggin should not invole the controller

Solution

  • Build activity loggin on top of userstamps plugin

Install

script/plugin install git://github.com/grosser/record_activities.git

Setup

Install and setup userstamp Create an activities table in your database with user_id and string action.

Usage

class Comment < ActiveRecord::Base
  stampable
  record_activities #same as record_activities  :create, :update
end

Activity.find(:all,:conditions=>{:user_id=>12,:action=>'create')
or user has_many :activities in your user.rb
Something went wrong with that request. Please try again.