質問編集履歴

1

ビューファイルを追加しました。

2020/11/09 06:19

投稿

jones
jones

スコア36

test CHANGED
File without changes
test CHANGED
@@ -130,6 +130,174 @@
130
130
 
131
131
 
132
132
 
133
+ ```html
134
+
135
+ <%=form_with model: @charter_user, local: true do |f|%>
136
+
137
+ <div class='chat-room-form__field'>
138
+
139
+ <div class='chat-room-form__field--left'>
140
+
141
+ <%= f.label :出発地, class: 'chat-room-form__label'%>
142
+
143
+ </div>
144
+
145
+ <div class='chat-room-form__field--right'>
146
+
147
+ <%= f.text_field :departure, class: 'chat__room_name chat-room-form__input', placeholder: '出発地を入力してください'%>
148
+
149
+ </div>
150
+
151
+ </div>
152
+
153
+ <div class='chat-room-form__field'>
154
+
155
+ <div class='chat-room-form__field--left'>
156
+
157
+ <%= f.label :到着地, class: 'chat-room-form__label'%>
158
+
159
+ </div>
160
+
161
+ <div class='chat-room-form__field--right'>
162
+
163
+ <%= f.text_field :arrive, class: 'chat__room_name chat-room-form__input', placeholder: '到着地を入力してください'%>
164
+
165
+ </div>
166
+
167
+ </div>
168
+
169
+ <div class='chat-room-form__field'>
170
+
171
+ <div class='chat-room-form__field--left'>
172
+
173
+ <%= f.label :才数, class: 'chat-room-form__label'%>
174
+
175
+ </div>
176
+
177
+ <div class='chat-room-form__field--right'>
178
+
179
+ <%= f.text_field :size, class: 'chat__room_name chat-room-form__input', placeholder: '才数'%>
180
+
181
+ </div>
182
+
183
+ </div>
184
+
185
+ <div class='chat-room-form__field'>
186
+
187
+ <div class='chat-room-form__field--left'>
188
+
189
+ <%= f.label :到着希望日, class: 'chat-room-form__label'%>
190
+
191
+ </div>
192
+
193
+ <div class='chat-room-form__field--right'>
194
+
195
+ <%= f.text_field :delivery_date, class: 'chat__room_name chat-room-form__input', placeholder: '2020-01-01'%>
196
+
197
+ </div>
198
+
199
+ </div>
200
+
201
+ <div class='chat-room-form__field'>
202
+
203
+ <div class='chat-room-form__field--left'>
204
+
205
+ <%= f.label :希望価格, class: 'chat-room-form__label'%>
206
+
207
+ </div>
208
+
209
+ <div class='chat-room-form__field--right'>
210
+
211
+ <%= f.text_field :buy_price, class: 'chat__room_name chat-room-form__input', placeholder: '50000'%>
212
+
213
+ </div>
214
+
215
+ </div>
216
+
217
+ <div class='chat-room-form__field'>
218
+
219
+ <%# 都道府県をActiveHashにする %>
220
+
221
+ <div class='chat-room-form__field--left'>
222
+
223
+ <%= f.label :都道府県, class: 'chat-room-form__label'%>
224
+
225
+ </div>
226
+
227
+ <div class='chat-room-form__field--right'>
228
+
229
+ <%= f.text_field :prefecture_id, class: 'chat__room_name chat-room-form__input', placeholder: '東京都'%>
230
+
231
+ </div>
232
+
233
+ </div>
234
+
235
+ <div class='chat-room-form__field'>
236
+
237
+ <div class='chat-room-form__field--left'>
238
+
239
+ <%= f.label :市区町村, class: 'chat-room-form__label'%>
240
+
241
+ </div>
242
+
243
+ <div class='chat-room-form__field--right'>
244
+
245
+ <%= f.text_field :city, class: 'chat__room_name chat-room-form__input', placeholder: '千代田区'%>
246
+
247
+ </div>
248
+
249
+ </div>
250
+
251
+ <div class='chat-room-form__field'>
252
+
253
+ <div class='chat-room-form__field--left'>
254
+
255
+ <%= f.label :番地, class: 'chat-room-form__label'%>
256
+
257
+ </div>
258
+
259
+ <div class='chat-room-form__field--right'>
260
+
261
+ <%= f.text_field :charter_address, class: 'chat__room_name chat-room-form__input', placeholder: '1-1'%>
262
+
263
+ </div>
264
+
265
+ </div>
266
+
267
+ <div class='chat-room-form__field'>
268
+
269
+ <div class='chat-room-form__field--left'>
270
+
271
+ <%= f.label :建物名, class: 'chat-room-form__label'%>
272
+
273
+ </div>
274
+
275
+ <div class='chat-room-form__field--right'>
276
+
277
+ <%= f.text_field :build_name, class: 'chat__room_name chat-room-form__input', placeholder: '〇〇ビル〇〇'%>
278
+
279
+ </div>
280
+
281
+ </div>
282
+
283
+ <div class='chat-room-form__field'>
284
+
285
+ <div class='chat-room-form__field--left'>
286
+
287
+ <%= f.label :電話番号, class: 'chat-room-form__label'%>
288
+
289
+ </div>
290
+
291
+ <div class='chat-room-form__field--right'>
292
+
293
+ <%= f.text_field :tell_number, class: 'chat__room_name chat-room-form__input', placeholder: '09012345678'%>
294
+
295
+ </div>
296
+
297
+ </div>
298
+
299
+ ```
300
+
133
301
  ### 試してみたこと
134
302
 
135
303
  コントローラーの記述で