Commit 8f6ac4c993c9ea0375b37ce7ca7e1c43d0da284a
1 parent
1def090d
Exists in
master
and in
28 other branches
ActionItem6: migration renamed
git-svn-id: https://svn.colivre.coop.br/svn/noosfero/trunk@195 3f533792-8f58-4932-b0fe-aaf55b0a4547
Showing
6 changed files
with
26 additions
and
14 deletions
Show diff stats
app/models/enterprise.rb
1 | #A enterprise is a kind of profile. According to the system concept, only enterprises can offer priducts/services | 1 | #A enterprise is a kind of profile. According to the system concept, only enterprises can offer priducts/services |
2 | class Enterprise < Profile | 2 | class Enterprise < Profile |
3 | - | ||
4 | end | 3 | end |
app/models/user.rb
@@ -5,7 +5,7 @@ require 'digest/sha1' | @@ -5,7 +5,7 @@ require 'digest/sha1' | ||
5 | class User < ActiveRecord::Base | 5 | class User < ActiveRecord::Base |
6 | 6 | ||
7 | after_create do |user| | 7 | after_create do |user| |
8 | - Profile.create!(:identifier => user.login, :profile_owner_id => user.id, :profile_owner_type => 'User') | 8 | + Person.create!(:identifier => user.login, :profile_owner_id => user.id, :profile_owner_type => 'User') |
9 | end | 9 | end |
10 | 10 | ||
11 | has_one :personal_profile, :class_name => 'Profile', :as => :profile_owner | 11 | has_one :personal_profile, :class_name => 'Profile', :as => :profile_owner |
db/migrate/008_create_affiliations.rb
test/fixtures/enterprises.yml