ntue emailer approval fix and announcement widget add unit field
This commit is contained in:
parent
dda603c27c
commit
f42d25c46b
|
@ -90,6 +90,10 @@ class Bulletin
|
||||||
self.bulletin_category.title
|
self.bulletin_category.title
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def bulletin_create_dept
|
||||||
|
User.get_member_list_attribute_value(self.create_user_id,"staff","Unit").get_value_by_locale(I18n.locale)
|
||||||
|
end
|
||||||
|
|
||||||
def share_item
|
def share_item
|
||||||
Item.first(conditions:{name: 'announcement'})
|
Item.first(conditions:{name: 'announcement'})
|
||||||
end
|
end
|
||||||
|
|
|
@ -4,8 +4,8 @@
|
||||||
<div class="info1">
|
<div class="info1">
|
||||||
<span class="pull-right"><%= dislpay_view_count(@bulletin) %></span>
|
<span class="pull-right"><%= dislpay_view_count(@bulletin) %></span>
|
||||||
<span class="date"><%= display_date_time(@bulletin.postdate) %></span>
|
<span class="date"><%= display_date_time(@bulletin.postdate) %></span>
|
||||||
<% unit = @bulletin.cache_dept[I18n.locale.to_s] rescue nil %>
|
<% unit = User.get_member_list_attribute_value(@bulletin.create_user_id,"staff","Unit").get_value_by_locale(I18n.locale) rescue nil %>
|
||||||
<span><%= link_to unit,panel_announcement_front_end_index_bulletins_by_unit_path(:name=>unit) unless unit.blank? %></span>
|
<span><%= t('announcement.default_widget.bulletin_create_dept') + ": " + unit unless unit.blank? %></span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="news_image">
|
<div class="news_image">
|
||||||
|
|
|
@ -17,6 +17,7 @@ en:
|
||||||
postdate: Post Date
|
postdate: Post Date
|
||||||
title: Title
|
title: Title
|
||||||
subtitle: SubTitle
|
subtitle: SubTitle
|
||||||
|
bulletin_create_dept: Unit
|
||||||
editing_announcement: Edit Announcement
|
editing_announcement: Edit Announcement
|
||||||
editing_announcement_category: Edit Category
|
editing_announcement_category: Edit Category
|
||||||
error:
|
error:
|
||||||
|
|
|
@ -17,6 +17,7 @@ zh_tw:
|
||||||
postdate: 張貼日期
|
postdate: 張貼日期
|
||||||
title: 標題
|
title: 標題
|
||||||
subtitle: 副標題
|
subtitle: 副標題
|
||||||
|
bulletin_create_dept: 單位
|
||||||
editing_announcement: 編輯類別
|
editing_announcement: 編輯類別
|
||||||
editing_announcement_category: 編輯類別
|
editing_announcement_category: 編輯類別
|
||||||
error:
|
error:
|
||||||
|
|
|
@ -37,6 +37,7 @@ module Announcement
|
||||||
link_field :title,{:method => 'panel_announcement_front_end_bulletin_path',:args=>:self,:preview=>true}
|
link_field :title,{:method => 'panel_announcement_front_end_bulletin_path',:args=>:self,:preview=>true}
|
||||||
link_field :bulletin_category_with_title,{:method => 'panel_announcement_front_end_bulletins_path',:args=>{:category_id => [:bulletin_category,:id]}}
|
link_field :bulletin_category_with_title,{:method => 'panel_announcement_front_end_bulletins_path',:args=>{:category_id => [:bulletin_category,:id]}}
|
||||||
field :subtitle
|
field :subtitle
|
||||||
|
field :bulletin_create_dept
|
||||||
link_to_more 'panel_announcement_front_end_bulletins_path',:title_i18n=> 'more_plus'
|
link_to_more 'panel_announcement_front_end_bulletins_path',:title_i18n=> 'more_plus'
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -11,6 +11,14 @@
|
||||||
|
|
||||||
</iframe>
|
</iframe>
|
||||||
|
|
||||||
|
<% if @email_er.email_er_files.size > 0 %>
|
||||||
|
<%= label_tag t('file_')%>
|
||||||
|
<% @email_er.email_er_files.each do | efile | %>
|
||||||
|
<%= link_to (!efile.title.blank? ? efile.title : t('download')), efile.file.url, {:target => '_blank', :title => efile.title} if efile.file.file %>
|
||||||
|
<% end %>
|
||||||
|
<br />
|
||||||
|
<% end %>
|
||||||
|
|
||||||
<% if !@email_er.email_group.blank? %>
|
<% if !@email_er.email_group.blank? %>
|
||||||
<%= label_tag 'group_mail' %>
|
<%= label_tag 'group_mail' %>
|
||||||
<%= @email_er.get_email_group_data(@email_group_data) %>
|
<%= @email_er.get_email_group_data(@email_group_data) %>
|
||||||
|
|
|
@ -1 +1,4 @@
|
||||||
<%= @email_er.mail_content.html_safe %>
|
<ul>
|
||||||
|
<li><%= label_tag t("er_email.mail_subject") %><%= @email_er.mail_subject %></li>
|
||||||
|
<li><%= label_tag t("er_email.mail_content") %><%= @email_er.mail_content.html_safe %></li>
|
||||||
|
</ul>
|
Loading…
Reference in New Issue