forked from bofh/fetsite
Merge remote-tracking branch 'origin/documentmeeting' into documentmeeting
Conflicts: app/controllers/documents_controller.rb app/controllers/meetings_controller.rb app/models/ability.rb app/models/document.rb app/models/meeting.rb app/models/meetingtyp.rb app/views/documents/_document.html.erb app/views/documents/_nested_form.html.erb app/views/documents/edit.js.erb app/views/documents/new.js.erb app/views/meetings/_meeting.html.erb app/views/themen/_small.html.erb config/routes.rb
This commit is contained in:
@@ -9,7 +9,6 @@ class DocumentsController < ApplicationController
|
||||
def new
|
||||
@document=Document.new
|
||||
@parent=params[:parent_type].constantize.find(params[:parent_id])
|
||||
|
||||
@document.parent=@parent
|
||||
|
||||
@document.typ = 1
|
||||
@@ -19,7 +18,10 @@ class DocumentsController < ApplicationController
|
||||
end
|
||||
def edit
|
||||
@document = Document.find(params[:id])
|
||||
<<<<<<< HEAD
|
||||
@parent=@document.parent
|
||||
=======
|
||||
>>>>>>> origin/documentmeeting
|
||||
respond_to do |format|
|
||||
format.js
|
||||
end
|
||||
@@ -28,7 +30,11 @@ class DocumentsController < ApplicationController
|
||||
|
||||
def create
|
||||
@document = Document.new(params[:document])
|
||||
<<<<<<< HEAD
|
||||
@parent=@document.parent
|
||||
=======
|
||||
|
||||
>>>>>>> origin/documentmeeting
|
||||
respond_to do |format|
|
||||
if @document.save
|
||||
# format.html { redirect_to @document, notice: 'Document was successfully created.' }
|
||||
@@ -42,9 +48,15 @@ class DocumentsController < ApplicationController
|
||||
end
|
||||
end
|
||||
|
||||
<<<<<<< HEAD
|
||||
def update
|
||||
@document = Document.find(params[:id])
|
||||
@parent=@document.parent
|
||||
=======
|
||||
def update
|
||||
@document = Document.find(params[:id])
|
||||
|
||||
>>>>>>> origin/documentmeeting
|
||||
respond_to do |format|
|
||||
if @document.update_attributes(params[:document])
|
||||
format.html { redirect_to @document, notice: 'Document was successfully updated.' }
|
||||
@@ -60,7 +72,10 @@ class DocumentsController < ApplicationController
|
||||
def destroy
|
||||
logger.info("-------------delete------------------")
|
||||
@document = Document.find(params[:id])
|
||||
<<<<<<< HEAD
|
||||
@parent=@document.parent
|
||||
=======
|
||||
>>>>>>> origin/documentmeeting
|
||||
@document_id = params[:id]
|
||||
|
||||
@document.destroy
|
||||
|
||||
Reference in New Issue
Block a user