Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
immerda
Immerda Apps
users
Commits
0672a0a5
Commit
0672a0a5
authored
Dec 07, 2020
by
o
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix paths in resources
parent
5fe6c534
Pipeline
#4830
passed with stages
in 17 minutes and 24 seconds
Changes
2
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
+4
-4
app/controllers/resources_controller.rb
app/controllers/resources_controller.rb
+3
-3
config/routes.rb
config/routes.rb
+1
-1
No files found.
app/controllers/resources_controller.rb
View file @
0672a0a5
...
...
@@ -49,7 +49,7 @@ class ResourcesController < ApplicationController
update_account_properties
flash
[
:success
]
=
:resource_created
end
redirect_to
resource
s_path
redirect_to
action: :show
,
kind:
@
resource
_name
rescue
ApiError
=>
e
flash
[
:danger
]
=
e
.
api_msg
redirect_to
new_resource_path
...
...
@@ -64,10 +64,10 @@ class ResourcesController < ApplicationController
flash
[
:success
]
=
:success
end
redirect_to
resources_path
redirect_to
action: :show
,
kind:
params
[
:kind
]
rescue
ApiError
=>
e
flash
[
:danger
]
=
e
.
api_msg
redirect_to
resources_path
redirect_to
action: :show
,
kind:
params
[
:kind
]
end
end
config/routes.rb
View file @
0672a0a5
...
...
@@ -66,7 +66,7 @@ Rails.application.routes.draw do
get
'/msg'
,
to:
'application#msg'
get
'/resources/:kind'
,
to:
'resources#show'
post
'/resources
'
,
to:
'resources#update'
post
'/resources
/:kind'
,
to:
'resources#update'
get
'/new_resource'
,
to:
'resources#create'
post
'/new_resource'
,
to:
'resources#do_create'
else
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment