diff --git a/app/controllers/organisations_controller.rb b/app/controllers/organisations_controller.rb index 5d5a5cd..355ad7d 100644 --- a/app/controllers/organisations_controller.rb +++ b/app/controllers/organisations_controller.rb @@ -81,13 +81,13 @@ format.json { head :no_content } end end - + def parent @organisation = Organisation.find(params[:id]) parent_org = @organisation.find_by {|o| o.parent_id } return parent_org end - + def children @organisation = Organisation.find(params[:id]) #if user_signed_in? then @@ -102,7 +102,7 @@ # render(:file => File.join(Rails.root, 'public/403.html'), :status => 403, :layout => false) # end end - + def templates @organisation = Organisation.find(params[:id]) #if user_signed_in? then diff --git a/app/models/user.rb b/app/models/user.rb index ab2a564..5416052 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -233,7 +233,8 @@ def can_modify_org_details? modify_org_details = roles.find_by(name: constant("user_role_types.change_org_details")) return !modify_org_details.nil? - + end + ## # checks what type the user's organisation is #