<% # encoding: utf-8 %>

		<%= form_for @news_bulletin_file, :url => @file_url, :html => {:id => 'ajaxForm', :multipart => true} do |f| %>
        
            <div class="modal-header">
                <a class="close" data-dismiss="modal">×</a>
                <h3><%= (@news_bulletin_file.new_record? ? 'Add File' : 'Edit File') %></h3>
            </div>
            <div class="modal-body form-horizontal">
				<div class="control-group">
					<div class="controls">
					<%= f.file_field :file %>
					</div>
				</div>
				
				<%= f.fields_for :filetitle, (@news_bulletin_file.new_record? ? @news_bulletin_file.build_filetitle : @news_bulletin_file.filetitle ) do |f| %>
				  <% @site_valid_locales.each do |locale| %>
					<div class="control-group">
						<label for="file-<%= locale %>" class="control-label">Name <%= I18nVariable.first(:conditions => {:key => locale})[I18n.locale] %></label>
						<div class="controls">
						<%= f.text_field locale, :id => "file-#{locale}", :class => "input-xlarge" %>
						</div>
					</div>
				  <% end %>
				<% end %>	
				
				<%= f.fields_for :description, (@news_bulletin_file.new_record? ? @news_bulletin_file.build_description : @news_bulletin_file.description ) do |f| %>
				  <% @site_valid_locales.each do |locale| %>
					<div class="control-group">
						<label for="file-<%= locale %>" class="control-label">Description <%= I18nVariable.first(:conditions => {:key => locale})[I18n.locale] %></label>
						<div class="controls">
						<%= f.text_field locale, :id => "file-#{locale}", :class => "input-xlarge" %>
						</div>
					</div>
				  <% end %>
				<% end %>
				
            </div>
			
            <div class="modal-footer">
							<%= hidden_field_tag 'news_bulletin_file[news_bulletin_id]', @news_bulletin_file.news_bulletin_id %>
        			<a class="btn btn-primary" id='ajax_form_submit'><%= t('submit')%></a>
               <a class="btn" data-dismiss="modal"><%= t('cancel')%></a>
				
            </div>

		
		<% end %>
		

 		