New feature : User, Guest and Gestionnaire can be upload a document with theirs comments

This commit is contained in:
Xavier J 2016-04-20 16:51:57 +02:00
parent fb2eeddf97
commit b15c2bbb2b
19 changed files with 214 additions and 59 deletions

View file

@ -0,0 +1,5 @@
class AddPieceJustificativeReferenceToCommentaire < ActiveRecord::Migration
def change
add_reference :commentaires, :piece_justificative, references: :piece_justificatives
end
end

View file

@ -11,7 +11,7 @@
#
# It's strongly recommended that you check this file into your version control system.
ActiveRecord::Schema.define(version: 20160317153115) do
ActiveRecord::Schema.define(version: 20160419142017) do
# These are extensions that must be enabled in order to support this database
enable_extension "plpgsql"
@ -84,10 +84,11 @@ ActiveRecord::Schema.define(version: 20160317153115) do
create_table "commentaires", force: :cascade do |t|
t.string "email"
t.datetime "created_at", null: false
t.datetime "created_at", null: false
t.string "body"
t.integer "dossier_id"
t.datetime "updated_at", null: false
t.datetime "updated_at", null: false
t.integer "piece_justificative_id"
end
add_index "commentaires", ["dossier_id"], name: "index_commentaires_on_dossier_id", using: :btree