parent
a9e9171441
commit
bad170fdb2
@ -1,3 +1,4 @@
|
|||||||
class Softapplication < ActiveRecord::Base
|
class Softapplication < ActiveRecord::Base
|
||||||
attr_accessible :android_min_version_available, :app_type_id, :app_type_name, :description, :name, :user_id
|
attr_accessible :android_min_version_available, :app_type_id, :app_type_name, :description, :name, :user_id
|
||||||
|
acts_as_attachable
|
||||||
end
|
end
|
||||||
|
@ -1,12 +1,64 @@
|
|||||||
<h3><%=l(:label_release_softapplication)%></h3>
|
<h3><%= l(:label_release_softapplication)%></h3> <!-- <%= render 'form' %>
|
||||||
<!-- <%= render 'form' %>
|
|
||||||
|
|
||||||
<%= link_to 'Back', softapplications_path %> -->
|
<%= link_to 'Back', softapplications_path %> -->
|
||||||
|
|
||||||
<%= labelled_form_for @softapplication, :url => {:controller => 'softapplications', :action => 'create'}, method: :post do |f| %>
|
|
||||||
<div class="box tabular">
|
|
||||||
<%= render :partial => 'form', :locals => { :f => f } %>
|
|
||||||
<%= submit_tag l(:button_create) %>
|
|
||||||
|
|
||||||
|
<div id="put-bid-form" style="">
|
||||||
|
<%= form_for Softapplication.new, :url => {:controller => 'softapplications', :action => 'create'}, :update => "bidding_project_list", :complete => '$("#put-bid-form").hide();', :html => {:multipart => true, :id => 'add_homework_form'} do |f| %>
|
||||||
|
<fieldset>
|
||||||
|
<legend>
|
||||||
|
<%= l(:label_attachment_plural) %>
|
||||||
|
</legend>
|
||||||
|
<tr style="width:700px; margin-left: -10px">
|
||||||
|
<td><%= l(:label_softapplication_name) %></td>
|
||||||
|
<td style="require, color: #bb0000"> * </td>: <td ><%= f.text_field :name, :required => true, :size => 60, :style => "width:400px;" %></td>
|
||||||
|
<td><%= l(:label_softapplication_name_condition)%></td>
|
||||||
|
</tr></ br>
|
||||||
|
<br />
|
||||||
|
<br />
|
||||||
|
|
||||||
|
<tr style="width:800px;">
|
||||||
|
<td><%= l(:label_softapplication_version_available) %></td>
|
||||||
|
<td style="require, color: #bb0000"> * </td>: <td style="width: 100px"><%= f.text_field :android_min_version_available, :required => true, :size => 60, :style => "width:400px;" %></td>
|
||||||
|
|
||||||
|
</tr></ br>
|
||||||
|
<br />
|
||||||
|
<br />
|
||||||
|
|
||||||
|
<tr style="width:800px;">
|
||||||
|
<td><%= l(:label_softapplication_type) %></td>
|
||||||
|
|
||||||
|
<td style="require, color: #bb0000"> * </td>: <td style="width: 100px"><%= f.text_field :app_type_name, :required => true, :size => 60, :style => "width:400px;" %></td>
|
||||||
|
|
||||||
|
</tr></ br>
|
||||||
|
<br />
|
||||||
|
<br />
|
||||||
|
|
||||||
|
<tr style="width:800px;">
|
||||||
|
<td><%= l(:label_softapplication_description) %></td>
|
||||||
|
<td style="require, color: #bb0000"> * </td>: <td style="width: 100px"><%= f.text_field :description, :required => true, :size => 60, :style => "width:400px;" %></td>
|
||||||
|
|
||||||
|
</tr></ br>
|
||||||
|
<br />
|
||||||
|
<br />
|
||||||
|
<%= render_flash_messages %>
|
||||||
|
<p id="put-bid-form-partial">
|
||||||
|
<%= render :partial => 'attachments/form' %>
|
||||||
|
</p>
|
||||||
|
</fieldset>
|
||||||
|
<%= submit_tag l(:button_create), :onclick => "return true" %>
|
||||||
|
<script type="text/javascript">
|
||||||
|
function j_submit () {
|
||||||
|
alert('start')
|
||||||
|
var submit_homework = function(){
|
||||||
|
$('#add_homework_form').clone().attr('action', '<%= url_for({:controller => "softapplications", :action => "create"})+".js" %>').ajaxSubmit()
|
||||||
|
};
|
||||||
|
alert('stop')
|
||||||
|
$.globalEval(submit_homework());
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
</div>
|
||||||
|
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
Loading…
Reference in new issue