質問編集履歴
4
コード追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -115,3 +115,75 @@
|
|
115
115
|
end
|
116
116
|
|
117
117
|
```
|
118
|
+
|
119
|
+
|
120
|
+
|
121
|
+
#### 追記
|
122
|
+
|
123
|
+
- views/devise/registrations/new.html.haml
|
124
|
+
|
125
|
+
```ruby
|
126
|
+
|
127
|
+
.contents-row
|
128
|
+
|
129
|
+
.container
|
130
|
+
|
131
|
+
%h2
|
132
|
+
|
133
|
+
Sign up!
|
134
|
+
|
135
|
+
= form_with model: @user, url: user_registration_path, id: 'new_user', class: 'new_user', local: true do |f|
|
136
|
+
|
137
|
+
= devise_error_messages!
|
138
|
+
|
139
|
+
|
140
|
+
|
141
|
+
.field
|
142
|
+
|
143
|
+
= f.label :name
|
144
|
+
|
145
|
+
%i (6文字以内)
|
146
|
+
|
147
|
+
.field__name
|
148
|
+
|
149
|
+
= f.text_field :name, autofocus: true, maxlength: "6"
|
150
|
+
|
151
|
+
|
152
|
+
|
153
|
+
.field
|
154
|
+
|
155
|
+
= f.label :email
|
156
|
+
|
157
|
+
.field__address
|
158
|
+
|
159
|
+
= f.email_field :email
|
160
|
+
|
161
|
+
|
162
|
+
|
163
|
+
.field
|
164
|
+
|
165
|
+
= f.label :password
|
166
|
+
|
167
|
+
%i (6文字以上)
|
168
|
+
|
169
|
+
.field__pass
|
170
|
+
|
171
|
+
= f.password_field :password, autocomplete: "off"
|
172
|
+
|
173
|
+
|
174
|
+
|
175
|
+
.field
|
176
|
+
|
177
|
+
= f.label :password_confirmation
|
178
|
+
|
179
|
+
.field__pass-confirmation
|
180
|
+
|
181
|
+
= f.password_field :password_confirmation, autocomplete: "off"
|
182
|
+
|
183
|
+
|
184
|
+
|
185
|
+
.actions
|
186
|
+
|
187
|
+
= f.submit "Sign up" , class: 'sign-btn'
|
188
|
+
|
189
|
+
```
|
3
コードの記述もれ
test
CHANGED
File without changes
|
test
CHANGED
@@ -110,7 +110,7 @@
|
|
110
110
|
|
111
111
|
resources :posts
|
112
112
|
|
113
|
-
resources :users, only[:new, :show, :create]
|
113
|
+
resources :users, only:[:new, :show, :create]
|
114
114
|
|
115
115
|
end
|
116
116
|
|
2
初心者アイコン付加
test
CHANGED
@@ -1 +1 @@
|
|
1
|
-
「新規投稿」や「ログイン」画面に遷移できない
|
1
|
+
Rails「新規投稿」や「ログイン」画面に遷移できない
|
test
CHANGED
File without changes
|
1
記載漏れ
test
CHANGED
File without changes
|
test
CHANGED
@@ -97,3 +97,21 @@
|
|
97
97
|
= link_to "新規登録", "new_user_registration_path", class: "post"
|
98
98
|
|
99
99
|
```
|
100
|
+
|
101
|
+
- routes.rb
|
102
|
+
|
103
|
+
```ruby
|
104
|
+
|
105
|
+
Rails.application.routes.draw do
|
106
|
+
|
107
|
+
devise_for :users
|
108
|
+
|
109
|
+
root "posts#index"
|
110
|
+
|
111
|
+
resources :posts
|
112
|
+
|
113
|
+
resources :users, only[:new, :show, :create]
|
114
|
+
|
115
|
+
end
|
116
|
+
|
117
|
+
```
|