<% # encoding: utf-8 %>

<%= flash_messages %>

<% if @current_category %>
	<h1 class="h1"><%= @current_category.i18n_variable[I18n.locale] %></h1>
<% else %>
	<h1 class="h1"><%= t('announcement.announcement') %></h1>
<% end %>


<table class="table table-bordered">
  <tr>
	<th><%= t('announcement.bulletin.category') %></th>
	<th><%= t('announcement.bulletin.title') %></th>
	<th><%= t('announcement.bulletin.postdate') %></th>
  </tr>

<% @bulletins.each do |post| %>
  <tr>
	<td><%= post.bulletin_category.i18n_variable[I18n.locale] rescue nil %></td>
	<td><%= link_to post.title[I18n.locale], panel_announcement_front_end_bulletin_path(post, :category_id => post.bulletin_category_id) %>
	<%#= link_to post.title, panel_announcement_back_end_bulletin_path(post) %>
	</td>
	<td><%= display_date_time(post.postdate) %></td>
  </tr>
  
<% end %>

</table>

<%= paginate @bulletins, :param_name => :page_main, :params => {:inner => 'false'} %>

