q@new install / new model

17 views
Skip to first unread message

der_tom

unread,
Mar 23, 2012, 4:47:14 AM3/23/12
to CommunityEngine
hi,just installed latest CE and i added a model which i want assign
the current user to. it looks likek this:
class ProductsController < BaseController
def create
@product= Product.new(params[:producttest])
@product.user = current_user
end

but current_user is not present. how do i access the current user?

thx

sethg

unread,
Apr 3, 2012, 11:57:35 AM4/3/12
to communi...@googlegroups.com
this is my question too . . . 
Reply all
Reply to author
Forward
0 new messages