質問編集履歴

2

追記

2015/06/28 06:17

投稿

退会済みユーザー
test CHANGED
File without changes
test CHANGED
File without changes

1

追記

2015/06/28 06:17

投稿

退会済みユーザー
test CHANGED
File without changes
test CHANGED
@@ -245,3 +245,189 @@
245
245
  });
246
246
 
247
247
  ```
248
+
249
+
250
+
251
+
252
+
253
+
254
+
255
+
256
+
257
+
258
+
259
+
260
+
261
+
262
+
263
+
264
+
265
+ **html.erb**
266
+
267
+ ```lang-<html.erb>
268
+
269
+ <div class="pinGridWrapper">
270
+
271
+ <div class="pinGrid">
272
+
273
+ <% @items.each do |item| %><!-- アイテムインデックス start-->
274
+
275
+ <div class="pin">
276
+
277
+ <% if item.picture_1.present? %>
278
+
279
+ <%= link_to(item) { image_tag item.picture_1_url(:thumb),:class =>"index_border_radius" } %>
280
+
281
+
282
+
283
+ <% unless item.infraction %>
284
+
285
+ <h2 class="palette-paragraph">
286
+
287
+ <%= item.title %>
288
+
289
+ </h2>
290
+
291
+ <% else %>
292
+
293
+ <h4 class="palette-paragraph">
294
+
295
+ 違反アイテム
296
+
297
+ </h4>
298
+
299
+ <% end %>
300
+
301
+
302
+
303
+
304
+
305
+ <p><small><small>
306
+
307
+ <i class="fa fa-clock-o"></i>
308
+
309
+ <span class="countdown" data-until= "<%= item.limit_day.to_datetime %>" ></span>
310
+
311
+ </small></small></p>
312
+
313
+ <% else %>
314
+
315
+ <%= link_to(item) {image_tag("opps.jpg", :size => '135x135') } %>
316
+
317
+ <% end %>
318
+
319
+ </div>
320
+
321
+ <% end %><!-- アイテムインデックス end -->
322
+
323
+ </div>
324
+
325
+ </div>
326
+
327
+
328
+
329
+
330
+
331
+ <div class="col-xs-12 col-sm-12 col-md-12 col-lg-12 text-center">
332
+
333
+ <div class="form-group">
334
+
335
+ <div class="pagination">
336
+
337
+ <%= paginate @items %>
338
+
339
+ </div>
340
+
341
+ </div>
342
+
343
+ </div>
344
+
345
+
346
+
347
+ ```
348
+
349
+
350
+
351
+
352
+
353
+ 生成されるHTML
354
+
355
+ ```lang-<html>
356
+
357
+ <div class="pinGridWrapper">
358
+
359
+ <div class="pinGrid">
360
+
361
+ <% @items.each do |item| %><!-- アイテムインデックス start-->
362
+
363
+ <div class="pin">
364
+
365
+ <% if item.picture_1.present? %>
366
+
367
+ <%= link_to(item) { image_tag item.picture_1_url(:thumb),:class =>"index_border_radius" } %>
368
+
369
+
370
+
371
+ <% unless item.infraction %>
372
+
373
+ <h2 class="palette-paragraph">
374
+
375
+ <%= item.title %>
376
+
377
+ </h2>
378
+
379
+ <% else %>
380
+
381
+ <h4 class="palette-paragraph">
382
+
383
+ 違反アイテム
384
+
385
+ </h4>
386
+
387
+ <% end %>
388
+
389
+
390
+
391
+
392
+
393
+ <p><small><small>
394
+
395
+ <i class="fa fa-clock-o"></i>
396
+
397
+ <span class="countdown" data-until= "<%= item.limit_day.to_datetime %>" ></span>
398
+
399
+ </small></small></p>
400
+
401
+ <% else %>
402
+
403
+ <%= link_to(item) {image_tag("opps.jpg", :size => '135x135') } %>
404
+
405
+ <% end %>
406
+
407
+ </div>
408
+
409
+ <% end %><!-- アイテムインデックス end -->
410
+
411
+ </div>
412
+
413
+ </div>
414
+
415
+
416
+
417
+
418
+
419
+ <div class="col-xs-12 col-sm-12 col-md-12 col-lg-12 text-center">
420
+
421
+ <div class="form-group">
422
+
423
+ <div class="pagination">
424
+
425
+ <%= paginate @items %>
426
+
427
+ </div>
428
+
429
+ </div>
430
+
431
+ </div>
432
+
433
+ ```