diff options
author | hellekin <hellekin@cepheide.org> | 2020-10-06 16:17:44 +0200 |
---|---|---|
committer | hellekin <hellekin@cepheide.org> | 2020-10-06 16:21:40 +0200 |
commit | 77d78b9023106cedd81703a1c6735e9109f631bb (patch) | |
tree | 66547d568d713d1d6e01efbe80e3d10f4d9da36b /db/schema.rb | |
parent | 341293217aefc15a10fc81dfc1d7850f89acfb1f (diff) | |
download | incommon-map-77d78b9023106cedd81703a1c6735e9109f631bb.tar.gz |
Add Resource model
Resources will be stored as JSON, in the (GeoJSON) :feature column.
They are assigned an UUID upon creation if they don't comme with one.
They belong to an Agent.
Diffstat (limited to 'db/schema.rb')
-rw-r--r-- | db/schema.rb | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/db/schema.rb b/db/schema.rb index ef4f4cd..8433cd9 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -10,7 +10,7 @@ # # It's strongly recommended that you check this file into your version control system. -ActiveRecord::Schema.define(version: 2020_10_05_155004) do +ActiveRecord::Schema.define(version: 2020_10_06_140511) do # These are extensions that must be enabled in order to support this database enable_extension "plpgsql" @@ -34,6 +34,14 @@ ActiveRecord::Schema.define(version: 2020_10_05_155004) do t.index ["uuid"], name: "index_agents_on_uuid", unique: true end + create_table "resources", force: :cascade do |t| + t.uuid "uuid" + t.jsonb "feature" + t.datetime "created_at", precision: 6, null: false + t.datetime "updated_at", precision: 6, null: false + t.index ["uuid"], name: "index_resources_on_uuid", unique: true + end + create_table "users", force: :cascade do |t| t.string "name" t.string "username" |