Add nccu icon

Change news list in front-end
Hide links and files in news and announcement front-end show when nothing
This commit is contained in:
Christophe Vilayphiou 2012-05-08 15:27:43 +08:00
parent ba4385e3fd
commit caba8ce7a4
6 changed files with 41 additions and 34 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

@ -3,6 +3,7 @@
<head>
<meta charset="utf-8">
<title><%= @title || APP_CONFIG['orbit'] %></title>
<link rel="shortcut icon" href="<%= asset_path "ncculogo.ico" %>">
<!--[if lt IE 9]>
<%= javascript_include_tag "html5" %>
<![endif]-->

View File

@ -3,6 +3,7 @@
<head>
<meta charset="utf-8">
<%= page_title(@item).html_safe %>
<link rel="shortcut icon" href="<%= asset_path "ncculogo.ico" %>">
<%= page_metas(@item).html_safe %>
<!--[if lt IE 9]>
<%= javascript_include_tag "html5" %>

View File

@ -15,15 +15,18 @@
<%= @bulletin.text[I18n.locale].html_safe %>
</div>
<b><%= t('announcement.link') %></b>
<% @bulletin.bulletin_links.each do | blink | %>
<%= link_to blink.i18n_variable[I18n.locale], blink.url, :target => '_blank' %>
<% if @bulletin.bulletin_links.size > 0 %>
<b><%= t('announcement.link') %></b>
<% @bulletin.bulletin_links.each do | blink | %>
<%= link_to blink.i18n_variable[I18n.locale], blink.url, :target => '_blank' %>
<% end %>
<% end %>
</li>
<li>
<b><%= t('announcement.file') %></b>
<% @bulletin.bulletin_files.each do | bfile | %>
<%= link_to bfile.filetitle[I18n.locale], bfile.file.url, {:target => '_blank', :title => bfile.description} if bfile.file.file %>
<% if @bulletin.bulletin_files.size > 0 %>
<b><%= t('announcement.file') %></b>
<% @bulletin.bulletin_files.each do | bfile | %>
<%= link_to bfile.filetitle[I18n.locale], bfile.file.url, {:target => '_blank', :title => bfile.description} if bfile.file.file %>
<% end %>
<% end %>
<div class="fb">

View File

@ -8,25 +8,24 @@
<h1 class="h1"><%= t('news.list_news') %></h1>
<% end %>
<table class="table table-bordered">
<tr>
<th><%= t('news.news_bulletin.category') %></th>
<th><%= t('news.news_bulletin.title') %></th>
<th><%= t('news.news_bulletin.postdate') %></th>
</tr>
<% @news_bulletins.each do |post| %>
<tr>
<td><%= post.news_bulletin_category.i18n_variable[I18n.locale] %></td>
<td><%= link_to post.title[I18n.locale], panel_news_front_end_news_bulletin_path(post) %>
<%#= link_to post.title, panel_news_back_end_news_bulletin_path(post) %>
</td>
<td><%= post.postdate %></td>
</tr>
<% end %>
<tbody>
<tr>
<th><%= t('news.news_bulletin.image') %></th>
<th><%= t('news.news_bulletin.title') %></th>
<th><%= t('news.news_bulletin.postdate') %></th>
</tr>
<% @news_bulletins.each do |post| %>
<tr>
<td><%= image_tag post.image %></td>
<td>
<%= link_to post.title[I18n.locale], panel_news_front_end_news_bulletin_path(post) %>
<%= post.subtitle[I18n.locale].html_safe %>
</td>
<td><%= post.postdate %></td>
</tr>
<% end %>
</tbody>
</table>
<%= paginate @news_bulletins, :params => {:inner => 'false'} %>

View File

@ -15,15 +15,18 @@
<%= @news_bulletin.text[I18n.locale].html_safe %>
</div>
<b><%= t('announcement.link') %></b>
<% @news_bulletin.bulletin_links.each do | blink | %>
<%= link_to blink.i18n_variable[I18n.locale], blink.url, :target => '_blank' %>
<% if @news_bulletin.news_bulletin_links.size > 0 %>
<b><%= t('announcement.link') %></b>
<% @news_bulletin.news_bulletin_links.each do | blink | %>
<%= link_to blink.i18n_variable[I18n.locale], blink.url, :target => '_blank' %>
<% end %>
<% end %>
</li>
<li>
<b><%= t('announcement.file') %></b>
<% @news_bulletin.bulletin_files.each do | bfile | %>
<%= link_to bfile.filetitle[I18n.locale], bfile.file.url, {:target => '_blank', :title => bfile.description} if bfile.file.file %>
<% if @news_bulletin.news_bulletin_files.size > 0 %>
<b><%= t('announcement.file') %></b>
<% @news_bulletin.news_bulletin_files.each do | bfile | %>
<%= link_to bfile.filetitle[I18n.locale], bfile.file.url, {:target => '_blank', :title => bfile.description} if bfile.file.file %>
<% end %>
<% end %>
<div class="fb">