質問するログイン新規登録

質問編集履歴

1

誤字

2017/01/25 02:48

投稿

nk117
nk117

スコア31

title CHANGED
File without changes
body CHANGED
@@ -8,9 +8,9 @@
8
8
  gem 'mini_magick','~>3.7.0'
9
9
 
10
10
  ```
11
- building_image_uploader.rb
11
+ book_image_uploader.rb
12
12
  ```ruby
13
- class BuildingImageUploader < CarrierWave::Uploader::Base
13
+ class BookImageUploader < CarrierWave::Uploader::Base
14
14
  include CarrierWave::MiniMagick
15
15
  storage :file
16
16
  process :resize_to_limit => [800,1200]
@@ -24,28 +24,28 @@
24
24
  ```
25
25
  find.html.erb
26
26
  ```ruby
27
- <div class = "buildingFindImageList">
27
+ <div class = "bookFindImageList">
28
- <%= image_tag @building.building_image_url %>
28
+ <%= image_tag @book.book_image_url %>
29
29
  </div>
30
30
  ```
31
- building.rb
31
+ book.rb
32
32
  ```ruby
33
- class Building < ActiveRecord::Base
33
+ class book < ActiveRecord::Base
34
- mount_uploader :building_image, BuildingImageUploader
34
+ mount_uploader :book_image, bookImageUploader
35
35
  ```
36
36
  _form.html.erb
37
37
  ```ruby
38
38
 
39
- <div class = "buildingFindImageList">
39
+ <div class = "bookFindImageList">
40
- <div class = "buildingFindImagelistdemo">
40
+ <div class = "bookFindImagelistdemo">
41
- <% if @building.building_image? %>
41
+ <% if @book.book_image? %>
42
42
  <div class="thumbnail">
43
- <%= image_tag @building.building_image.url %>
43
+ <%= image_tag @book.book_image.url %>
44
44
  </div>
45
45
  <% end %>
46
46
  <p>Top画像</p>
47
- <%= f.file_field :building_image %>
47
+ <%= f.file_field :book_image %>
48
- <%= f.hidden_field :building_image_cache %>
48
+ <%= f.hidden_field :book_image_cache %>
49
49
  </div>
50
50
  </div>
51
51
  ```