From e89d7398aaf19ca8da76dd3c772184042d5871fc Mon Sep 17 00:00:00 2001
From: daiao <358551898@qq.com>
Date: Fri, 5 Aug 2016 19:02:05 +0800
Subject: [PATCH] =?UTF-8?q?=E7=94=B3=E8=AF=B7=E7=AE=A1=E7=90=86=E6=B6=88?=
=?UTF-8?q?=E6=81=AF=E9=80=9A=E7=9F=A5?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../layouts/_show_messages_list.html.erb | 42 +++++++++----------
1 file changed, 20 insertions(+), 22 deletions(-)
diff --git a/app/views/layouts/_show_messages_list.html.erb b/app/views/layouts/_show_messages_list.html.erb
index 5bd4a956d..300cc0879 100644
--- a/app/views/layouts/_show_messages_list.html.erb
+++ b/app/views/layouts/_show_messages_list.html.erb
@@ -94,6 +94,26 @@
<%= applied_project_tip_header(ma) %>以“<%= applied_project_message_type(ma.role) %>”身份加入<% project = Project.find(ma.project_id) %>
<%= link_to project.name, project_path(ma.project_id), :class => "link-blue", :target => '_blank', :title => "#{project.name}" %>
+ <% elsif ma.applied_type == "ApplyAddSchools" && ma.status == 0 %>
+
+ <% content = ''+User.where("id=?", ma.applied_user_id).first.show_name+' 提交了申请:添加新的单位:'+"“"+ma.name+"”" %>
+ <%= link_to content.html_safe, unapplied_schools_path(:flag => 1, :applied_message_id => ma.id), :title => "#{User.where("id=?", ma.applied_user_id).first.show_name}提交了申请:添加新的单位“#{ma.name}”", :target => '_blank' %>
+
+ <% elsif ma.applied_type == "ApplyAddSchools" && ma.status == 1 %>
+
+ <% content = "系统提示:“#{ma.name}”的申请,已通过审核。谢谢!" %>
+ <%= link_to content.html_safe, { :controller=> "my",:action => "account",:flag => 1, :applied_message_id => ma.id }, :title => "系统提示:“#{ma.name}”的申请,已通过审核。谢谢!", :target => '_blank'%>
+
+ <% elsif ma.applied_type == "ApplyAddSchools" && ma.status == 2 %>
+
+ <% content = "系统提示:“#{ma.applied.name}”的申请,因名称不符合规范,系统已将其更改为“#{ma.name}”。谢谢!" %>
+ <%= link_to content.html_safe, { :controller=> "my",:action => "account", :flag => 1, :applied_message_id => ma.id }, :title => "系统提示:“#{ma.applied.name}”的申请,因名称不符合规范,系统已将其更改为“#{ma.name}”。谢谢!", :target => '_blank'%>
+
+ <% elsif ma.applied_type == "ApplyAddSchools" && ma.status == 3 %>
+
+ <% content = "系统提示:“#{ma.name}”的申请,经确认为无效的单位信息,已被删除,请重新编辑您的单位资料。谢谢!" %>
+ <%= link_to content.html_safe, { :controller=> "my",:action => "account", :flag => 1, :applied_message_id => ma.id }, :title => "系统提示:“#{ma.name}”的申请,经确认为无效的单位信息,已被删除,请重新编辑您的单位资料。谢谢!", :target => '_blank'%>
+
<% end %>
<% elsif ma.class == ForgeMessage %>
<% if ma.forge_message_type == "AppliedProject" %>
@@ -142,28 +162,6 @@
<% content = ''+ma.author.show_name+' 提到了你:'+ma.subject.html_safe %>
<%=link_to content.html_safe, ma.url, :title => ma.author.show_name+' 提到了你:'+ma.subject.html_safe, :target => '_blank' %>
<% end %>
- <% elsif ma.class == AppliedMessage %>
- <% if ma.applied_type == "ApplyAddSchools" && ma.status == 0 %>
-
- <% content = ''+User.where("id=?", ma.applied_user_id).first.show_name+' 提交了申请:添加新的单位:'+"“"+ma.name+"”" %>
- <%= link_to content.html_safe, unapplied_schools_path(:flag => 1, :applied_message_id => ma.id), :title => "#{User.where("id=?", ma.applied_user_id).first.show_name}提交了申请:添加新的单位“#{ma.name}”", :target => '_blank' %>
-
- <% elsif ma.applied_type == "ApplyAddSchools" && ma.status == 1 %>
-
- <% content = "系统提示:“#{ma.name}”的申请,已通过审核。谢谢!" %>
- <%= link_to content.html_safe, { :controller=> "my",:action => "account",:flag => 1, :applied_message_id => ma.id }, :title => "系统提示:“#{ma.name}”的申请,已通过审核。谢谢!", :target => '_blank'%>
-
- <% elsif ma.applied_type == "ApplyAddSchools" && ma.status == 2 %>
-
- <% content = "系统提示:“#{ma.applied.name}”的申请,因名称不符合规范,系统已将其更改为“#{ma.name}”。谢谢!" %>
- <%= link_to content.html_safe, { :controller=> "my",:action => "account", :flag => 1, :applied_message_id => ma.id }, :title => "系统提示:“#{ma.applied.name}”的申请,因名称不符合规范,系统已将其更改为“#{ma.name}”。谢谢!", :target => '_blank'%>
-
- <% elsif ma.applied_type == "ApplyAddSchools" && ma.status == 3 %>
-
- <% content = "系统提示:“#{ma.name}”的申请,经确认为无效的单位信息,已被删除,请重新编辑您的单位资料。谢谢!" %>
- <%= link_to content.html_safe, { :controller=> "my",:action => "account", :flag => 1, :applied_message_id => ma.id }, :title => "系统提示:“#{ma.name}”的申请,经确认为无效的单位信息,已被删除,请重新编辑您的单位资料。谢谢!", :target => '_blank'%>
-
- <% end %>
<% end %>
<% end %>