Add Cadastre table
This commit is contained in:
parent
0f93aba6bc
commit
b5f2163c51
4 changed files with 56 additions and 1 deletions
18
db/migrate/20160115135025_create_cadastre_table.rb
Normal file
18
db/migrate/20160115135025_create_cadastre_table.rb
Normal file
|
@ -0,0 +1,18 @@
|
|||
class CreateCadastreTable < ActiveRecord::Migration
|
||||
def change
|
||||
create_table :cadastres do |t|
|
||||
t.string :surface_intersection
|
||||
t.float :surface_parcelle
|
||||
t.string :numero
|
||||
t.integer :feuille
|
||||
t.string :section
|
||||
t.string :code_dep
|
||||
t.string :nom_com
|
||||
t.string :code_com
|
||||
t.string :code_arr
|
||||
t.text :geometry
|
||||
end
|
||||
|
||||
add_reference :cadastres, :dossier, references: :dossiers
|
||||
end
|
||||
end
|
16
db/schema.rb
16
db/schema.rb
|
@ -11,7 +11,7 @@
|
|||
#
|
||||
# It's strongly recommended that you check this file into your version control system.
|
||||
|
||||
ActiveRecord::Schema.define(version: 20160106100227) do
|
||||
ActiveRecord::Schema.define(version: 20160115135025) do
|
||||
|
||||
# These are extensions that must be enabled in order to support this database
|
||||
enable_extension "plpgsql"
|
||||
|
@ -35,6 +35,20 @@ ActiveRecord::Schema.define(version: 20160106100227) do
|
|||
add_index "administrateurs", ["email"], name: "index_administrateurs_on_email", unique: true, using: :btree
|
||||
add_index "administrateurs", ["reset_password_token"], name: "index_administrateurs_on_reset_password_token", unique: true, using: :btree
|
||||
|
||||
create_table "cadastres", force: :cascade do |t|
|
||||
t.string "surface_intersection"
|
||||
t.float "surface_parcelle"
|
||||
t.string "numero"
|
||||
t.integer "feuille"
|
||||
t.string "section"
|
||||
t.string "code_dep"
|
||||
t.string "nom_com"
|
||||
t.string "code_com"
|
||||
t.string "code_arr"
|
||||
t.text "geometry"
|
||||
t.integer "dossier_id"
|
||||
end
|
||||
|
||||
create_table "cerfas", force: :cascade do |t|
|
||||
t.string "content"
|
||||
t.integer "dossier_id"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue