Skip to content

Commit

Permalink
change detail background
Browse files Browse the repository at this point in the history
  • Loading branch information
xxseason committed Oct 25, 2015
1 parent 3b18b60 commit f5e0796
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion app/views/projects/show.html.erb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<div class="details">
<%= image_tag "http://7xleh2.dl1.z0.glb.clouddn.com/church-in-detail.png", class: "main-image" %>
<%= image_tag @project.detail, class: "main-image" %>
<div class="small-infos">
<div class="distance">
<%= image_tag "http://7xleh2.dl1.z0.glb.clouddn.com/location.png" %>
Expand Down
9 changes: 9 additions & 0 deletions lib/tasks/mock_data.rake
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,13 @@ namespace :db do
Project.find_by(address: '武汉大学').update_attributes(image: 'http://7xleh2.dl1.z0.glb.clouddn.com/wu_da.png')
end

task add_detail_image: :environment do
Project.find_by(address: '武汉大学').update_attributes(detail: 'http://7xleh2.dl1.z0.glb.clouddn.com/detail_toppic.png')
Project.find_by(address: '红楼').update_attributes(detail: 'http://7xleh2.dl1.z0.glb.clouddn.com/detail_toppic2.png')
Project.find_by(address: '省博').update_attributes(detail: 'http://7xleh2.dl1.z0.glb.clouddn.com/detail_toppic3.png')
Project.find_by(address: '昙华林').update_attributes(detail: 'http://7xleh2.dl1.z0.glb.clouddn.com/detail_toppic4.png')
Project.find_by(address: '黄鹤楼').update_attributes(detail: 'http://7xleh2.dl1.z0.glb.clouddn.com/detail_toppic5-1.png', image: "http://7xleh2.dl1.z0.glb.clouddn.com/huanghelou_list.png")
Project.find_by(address: '青年大教堂').update_attributes(detail: 'http://7xleh2.dl1.z0.glb.clouddn.com/church-in-detail.png')
end

end

0 comments on commit f5e0796

Please sign in to comment.