diff --git a/app/views/bids/_list_projects.html.erb b/app/views/bids/_list_projects.html.erb new file mode 100644 index 00000000..d4037699 --- /dev/null +++ b/app/views/bids/_list_projects.html.erb @@ -0,0 +1,79 @@ + +<% bidding_project.each do |b_project|%> + + + + +
+ + + + + + + + + +
+
+ <%= link_to image_tag(url_to_avatar(b_project.project), :class => 'avatar3'), :class => "avatar" %> +
+ + + + + + + + + + <% if User.current.id == @bid.author_id %> + + <% end %> + + + + + + + + + +
+ <%= link_to(b_project.project.name, project_path(b_project.project)) %> + <%= l(:label_join_bidding)%> + + <% if get_prize(b_project).nil? or get_prize(b_project) == "" %> + 未评奖 + <% else %> + <%= get_prize(b_project) %> + <% end %> + + + <%= toggle_link '评价', b_project.id.to_s %> +
<%= b_project.project.description %>
+ <%= b_project.created_at%> +
+ + +
+ + + + + + + +
<%= l(:label_bidding_user) %> + <%= link_to(b_project.user.name, user_path(b_project.user)) %> +
<%= l(:label_bidding_reason) %><%= b_project.description %>
+
+<% end %> + diff --git a/app/views/bids/set_reward.js.erb b/app/views/bids/set_reward.js.erb new file mode 100644 index 00000000..85989c0f --- /dev/null +++ b/app/views/bids/set_reward.js.erb @@ -0,0 +1,12 @@ +$('#reward_result_<%= @biding_project_id %>').html('<%= j( + + if get_prize(@b_p).nil? or get_prize(@b_p) == "" + puts '未评奖' + else + get_prize(@b_p) + end + +) +%>') + +$('#<%= @biding_project_id %>').hide() diff --git a/db/migrate/20130904135804_add_reward_to_biding_projects.rb b/db/migrate/20130904135804_add_reward_to_biding_projects.rb new file mode 100644 index 00000000..395705cd --- /dev/null +++ b/db/migrate/20130904135804_add_reward_to_biding_projects.rb @@ -0,0 +1,5 @@ +class AddRewardToBidingProjects < ActiveRecord::Migration + def change + add_column :biding_projects, :reward, :string + end +end diff --git a/files/2013/09/130916200529_heart.svg b/files/2013/09/130916200529_heart.svg new file mode 100644 index 00000000..6cc8390b --- /dev/null +++ b/files/2013/09/130916200529_heart.svg @@ -0,0 +1,9 @@ + + + + + +