Acts As Line plugin
Plugin details
Documentation
Install the plugin:
ruby script/plugin install git://github.com/broughcut/acts_as_line.git
Example
=======
table must already have a start_date and end_date column of type date or datetime.
script/generate datesgeom_migration table_name
runs the following on target table:
execute("ALTER TABLE table_name ADD COLUMN geom geometry;") execute("CREATE INDEX idx_table_name_dates_geom ON table_name USING GIST (geom);")
object = Foo.find(:first) results = Foo.touching(object) | results = Foo.intersects(object,true) results = Foo.not_touching(object) | results = Foo.intersects(object,false) results = Foo.touching(object,{:id => 123}) results = Foo.touching(object,{:id => '>123'}) results = Foo.touching(object,{:id => '<>123'}) etc results = Foo.touching(object,{:id => 123, :title => 'bar'})
Further Documentation
There is currently no advanced documentation for this plugin.
New documentationEdit plugin | (0 older versions) | Last edited by: hardway, 2 months ago

