From 19962f2695e28a0f3c77ba49ad2734c5453427e9 Mon Sep 17 00:00:00 2001 From: baiyu Date: Mon, 30 Sep 2013 16:20:56 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BA=86=E4=B8=BB=E9=A1=B5?= =?UTF-8?q?=E7=9A=84=E6=98=BE=E7=A4=BA=E6=A0=B7=E5=BC=8F=EF=BC=8C=20?= =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BA=86=E6=88=91=E7=9A=84=E8=AF=BE=E7=A8=8B?= =?UTF-8?q?=EF=BC=8C=E4=BD=BF=E5=BE=97=E5=8F=AF=E4=BB=A5=E7=9B=B4=E6=8E=A5?= =?UTF-8?q?=E5=88=9B=E5=BB=BA=E8=AF=BE=E7=A8=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/layouts/_base_header.html.erb | 4 ++-- app/views/users/_my_course.html.erb | 24 +++++++++++++----------- 2 files changed, 15 insertions(+), 13 deletions(-) diff --git a/app/views/layouts/_base_header.html.erb b/app/views/layouts/_base_header.html.erb index 551ce4a6a..4f696a18e 100644 --- a/app/views/layouts/_base_header.html.erb +++ b/app/views/layouts/_base_header.html.erb @@ -7,8 +7,8 @@ <%= content_tag('div', "#{link_to(l(:label_layouts_feedback)+'(' + User.current.count_new_jour.to_s + ')', feedback_path(User.current))}".html_safe, :id => 'loggedas') if User.current.logged? %> <%= content_tag('div', "#{l(:label_logged_as)} #{link_to_user(User.current, :format => :username)}".html_safe, :id => 'loggedas') if User.current.logged? %> - <%= content_tag('li', "#{link_to(l(:label_enterprise_college), :controller =>'projects', :action => 'course', :project_type => 1 )}".html_safe, :id=> 'account-enterprise') %> - <%= content_tag('li', "#{link_to(l(:lable_college_enterprise), :controller => 'projects', :action =>'index', :project_type => 0)}".html_safe, :id=> 'account-college') %> + <%= content_tag('li', "#{link_to(l(:label_enterprise_college), :controller =>'projects', :action => 'course_enterprise', :project_type => 1 )}".html_safe, :id=> 'account-enterprise') %> + <%= content_tag('li', "#{link_to(l(:lable_college_enterprise), :controller => 'projects', :action =>'enterprise_course', :project_type => 0)}".html_safe, :id=> 'account-college') %> diff --git a/app/views/users/_my_course.html.erb b/app/views/users/_my_course.html.erb index 1e155c5d9..eb81188b4 100644 --- a/app/views/users/_my_course.html.erb +++ b/app/views/users/_my_course.html.erb @@ -1,5 +1,16 @@
- <% unless @memberships.empty? %> + <% if @memberships.empty? %> + <% if @user != User.current %> +

+ <%= l(:label_project_course_un) %> +

+ <% else %> +

+ <%= l(:label_project_course_unadd) %><%= link_to"#{l(:label_course_new)}",:controller=>'projects',:action=>'new', :course => 1 %> +

+ <% end %> + <% else %> + <%= link_to"#{l(:label_course_new)}",:controller=>'projects',:action=>'new', :course => 1 %> - <% else %> - <% if @user != User.current %> -

- <%= l(:label_project_course_un) %> -

- <% else %> -

- <%= l(:label_project_course_unadd) %><%= link_to"#{l(:label_new)}",:controller=>'projects',:action=>'new', :course => 1 %> -

- <% end %> + <% end %> <%= call_hook :view_account_left_bottom, :user => @user %>