fix based from TomH-Home

This commit is contained in:
Steve Coast 2007-06-07 00:38:09 +00:00
parent 6efdcaa993
commit c72f6a4182

View file

@ -6,8 +6,8 @@ class Trace < ActiveRecord::Base
validates_inclusion_of :inserted, :in => [ true, false]
belongs_to :user
has_many :tags, :class_name => 'Tracetag', :foreign_key => 'gpx_id', :dependent => :destroy
has_many :points, :class_name => 'Tracepoint', :foreign_key => 'gpx_id', :dependent => :destroy
has_many :tags, :class_name => 'Tracetag', :foreign_key => 'gpx_id', :dependent => :delete_all
has_many :points, :class_name => 'Tracepoint', :foreign_key => 'gpx_id', :dependent => :delete_all
def tagstring=(s)
self.tags = s.split().collect {|tag|