質問編集履歴
2
ファイルパス記載
title
CHANGED
File without changes
|
body
CHANGED
@@ -9,19 +9,21 @@
|
|
9
9
|
もしどなたかお分かりの方いらっしゃいましたら、
|
10
10
|
教えていただければと思います。
|
11
11
|
|
12
|
-
|
13
|
-
|
12
|
+
app/controllers/test_controller.rb
|
13
|
+
```
|
14
14
|
class TestController < ApplicationController
|
15
15
|
def index
|
16
16
|
end
|
17
17
|
end
|
18
18
|
```
|
19
19
|
|
20
|
-
|
20
|
+
app/views/test/index.html.erb
|
21
|
+
```
|
21
22
|
<h1>aaadfsfds</h1>
|
22
23
|
```
|
23
24
|
|
24
|
-
|
25
|
+
config/routes.rb
|
26
|
+
```
|
25
27
|
Rails.application.routes.draw do
|
26
28
|
# For details on the DSL available within this file, see https://guides.rubyonrails.org/routing.html
|
27
29
|
resources :test
|
1
ソースコード追記
title
CHANGED
File without changes
|
body
CHANGED
@@ -9,6 +9,28 @@
|
|
9
9
|
もしどなたかお分かりの方いらっしゃいましたら、
|
10
10
|
教えていただければと思います。
|
11
11
|
|
12
|
+
|
13
|
+
```app/controllers/test_controller.rb
|
14
|
+
class TestController < ApplicationController
|
15
|
+
def index
|
16
|
+
end
|
17
|
+
end
|
18
|
+
```
|
19
|
+
|
20
|
+
```app/views/test/index.html.erb
|
21
|
+
<h1>aaadfsfds</h1>
|
22
|
+
```
|
23
|
+
|
24
|
+
```config/routes.rb
|
25
|
+
Rails.application.routes.draw do
|
26
|
+
# For details on the DSL available within this file, see https://guides.rubyonrails.org/routing.html
|
27
|
+
resources :test
|
28
|
+
get "test/index"
|
29
|
+
post "test/index"
|
30
|
+
resources :api
|
31
|
+
end
|
32
|
+
```
|
33
|
+
|
12
34
|
ソースは、下記になります。
|
13
35
|
https://github.com/sakusaka/docker-rails-mysql/tree/t-ogasawara/docker-compose-create
|
14
36
|
|