mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-12-27 02:04:33 +08:00
Code style fixes
This commit is contained in:
parent
affc429496
commit
4ea86d6aa1
2 changed files with 9 additions and 10 deletions
|
@ -10,13 +10,13 @@ class ExperimentsController < ApplicationController
|
|||
def new
|
||||
@experiment = Experiment.new
|
||||
respond_to do |format|
|
||||
format.json {
|
||||
render json:{
|
||||
html: render_to_string( {
|
||||
partial: "new_modal.html.erb"
|
||||
})
|
||||
format.json do
|
||||
render json: {
|
||||
html: render_to_string(
|
||||
partial: 'new_modal.html.erb'
|
||||
)
|
||||
}
|
||||
}
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
@ -11,7 +11,8 @@ class ProjectsController < ApplicationController
|
|||
:samples_index]
|
||||
before_action :check_view_notifications_permissions, only: [ :notifications ]
|
||||
before_action :check_edit_permissions, only: [ :edit ]
|
||||
before_action :check_experiment_archive_permissions, only: [:experiment_archive]
|
||||
before_action :check_experiment_archive_permissions,
|
||||
only: [:experiment_archive]
|
||||
|
||||
filter_by_archived = false
|
||||
|
||||
|
@ -306,9 +307,7 @@ class ProjectsController < ApplicationController
|
|||
end
|
||||
|
||||
def check_experiment_archive_permissions
|
||||
unless can_view_project_archive(@project)
|
||||
render_403
|
||||
end
|
||||
render_403 unless can_view_project_archive(@project)
|
||||
end
|
||||
|
||||
def choose_layout
|
||||
|
|
Loading…
Reference in a new issue