diff --git a/app/controllers/bids_controller.rb b/app/controllers/bids_controller.rb index 87b0d8dcf..cdf6e7d5a 100644 --- a/app/controllers/bids_controller.rb +++ b/app/controllers/bids_controller.rb @@ -695,7 +695,7 @@ class BidsController < ApplicationController @bid.budget = 0 @bid.author_id = User.current.id @bid.commit = 0 - @bid.homework_type = params[:bid][:homework_type] + @bid.homework_type = 1 @bid.save_attachments(params[:attachments] || (params[:bid] && params[:bid][:uploads])) # @bid. if @bid.save diff --git a/app/views/bids/_fork_form.html.erb b/app/views/bids/_fork_form.html.erb index ea110473c..1bfb4550b 100644 --- a/app/views/bids/_fork_form.html.erb +++ b/app/views/bids/_fork_form.html.erb @@ -15,9 +15,10 @@ <%= f.text_field :budget, :required => true, :size => 60, :style => "width:350px;", :placeholder => l(:label_bids_reward_what) %>

-->

<%= f.text_field :deadline, :value => nil,:required => true, :size => 60, :style => "width:150px;" %><%= calendar_for('bid_deadline')%> -

+
<%= l(:label_attachment_plural) %>

<%= render :partial => 'attachments/form', :locals => {:container => @homework} %>

\ No newline at end of file diff --git a/app/views/bids/_homework_form.html.erb b/app/views/bids/_homework_form.html.erb index 5aa3462fa..f726c038f 100644 --- a/app/views/bids/_homework_form.html.erb +++ b/app/views/bids/_homework_form.html.erb @@ -32,8 +32,10 @@

-->

<%= f.text_field :deadline, :required => true, :size => 60, :style => "width:150px;" %><%= calendar_for('bid_deadline')%>

+

<%= hidden_field_tag 'course_id', @project_id %>

<%= l(:label_attachment_plural) %> diff --git a/app/views/projects/_homework_form.html.erb b/app/views/projects/_homework_form.html.erb index e4a471367..13255120f 100644 --- a/app/views/projects/_homework_form.html.erb +++ b/app/views/projects/_homework_form.html.erb @@ -32,8 +32,10 @@

-->

<%= f.text_field :deadline, :required => true, :size => 60, :style => "width:150px;" %><%= calendar_for('bid_deadline')%>

+

<%= hidden_field_tag 'course_id', @project.id %>

<%= l(:label_attachment_plural) %>