質問編集履歴
3
編集
test
CHANGED
File without changes
|
test
CHANGED
@@ -32,7 +32,7 @@
|
|
32
32
|
|
33
33
|
|
34
34
|
|
35
|
-
= form_with model: [
|
35
|
+
= form_with model: [:admin, @user], local: true do |f|
|
36
36
|
|
37
37
|
.form-group
|
38
38
|
|
2
質問編集
test
CHANGED
File without changes
|
test
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
以下のslimファイルの3行目、
|
4
4
|
|
5
|
-
`= form_with model: [
|
5
|
+
`= form_with model: [:admin, @user], local: true do |f|`を
|
6
6
|
|
7
7
|
`= form_with model: @user, local: true do |f|`に変えると処理が通る理由を教えて下さい。
|
8
8
|
|
1
内容の編集
test
CHANGED
File without changes
|
test
CHANGED
@@ -24,7 +24,9 @@
|
|
24
24
|
|
25
25
|
|
26
26
|
|
27
|
-
|
27
|
+
views/admin/users/new.slim.html
|
28
|
+
|
29
|
+
```html
|
28
30
|
|
29
31
|
h1 ユーザー登録
|
30
32
|
|
@@ -70,7 +72,9 @@
|
|
70
72
|
|
71
73
|
|
72
74
|
|
73
|
-
|
75
|
+
config/routes.rb
|
76
|
+
|
77
|
+
```ruby
|
74
78
|
|
75
79
|
Rails.application.routes.draw do
|
76
80
|
|
@@ -90,7 +94,9 @@
|
|
90
94
|
|
91
95
|
|
92
96
|
|
93
|
-
|
97
|
+
app/controllers/admin/users_controller.rb
|
98
|
+
|
99
|
+
```ruby
|
94
100
|
|
95
101
|
class Admin::UsersController < ApplicationController
|
96
102
|
|