mirror of
https://github.com/TracksApp/tracks.git
synced 2026-02-27 17:44:08 +01:00
remove unused and unneccesary user_id from taggings table.
this way we can stay closer to the defaults of has_many_polymorphs thus making upgrading easier
This commit is contained in:
parent
65fe971d32
commit
f79c28231b
12 changed files with 1932 additions and 1911 deletions
|
|
@ -5,7 +5,6 @@ class Tagging < ActiveRecord::Base
|
|||
|
||||
belongs_to :tag
|
||||
belongs_to :taggable, :polymorphic => true
|
||||
# belongs_to :user
|
||||
|
||||
# If you also need to use <tt>acts_as_list</tt>, you will have to manage the tagging positions manually by creating decorated join records when you associate Tags with taggables.
|
||||
# acts_as_list :scope => :taggable
|
||||
|
|
|
|||
|
|
@ -104,8 +104,6 @@ class User < ActiveRecord::Base
|
|||
end
|
||||
has_many :notes, :order => "created_at DESC", :dependent => :delete_all
|
||||
has_one :preference, :dependent => :destroy
|
||||
has_many :taggings
|
||||
has_many :tags, :through => :taggings, :select => "DISTINCT tags.*"
|
||||
|
||||
attr_protected :is_admin
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue