dawarich/db/migrate/20250123145954_create_tracks.rb
2025-01-24 12:01:54 +01:00

14 lines
354 B
Ruby

# frozen_string_literal: true
class CreateTracks < ActiveRecord::Migration[8.0]
def change
create_table :tracks do |t|
t.datetime :started_at, null: false
t.datetime :ended_at, null: false
t.references :user, null: false, foreign_key: true
t.line_string :path, srid: 3857, null: false
t.timestamps
end
end
end