From 64f6175f22b15f3034d119f0812d53c22eb8ed4e Mon Sep 17 00:00:00 2001 From: zhanghaitao <562681745@qq.com> Date: Mon, 11 Aug 2014 17:06:45 +0800 Subject: [PATCH 1/4] =?UTF-8?q?1.#912=20admin=E7=AE=A1=E7=90=86=E9=85=8D?= =?UTF-8?q?=E7=BD=AE=E7=AA=97=E5=8F=A3=EF=BC=9A=E9=A1=B9=E7=9B=AE=E5=88=97?= =?UTF-8?q?=E8=A1=A8=E3=80=81=E7=94=A8=E6=88=B7=E5=88=97=E8=A1=A8=E7=95=8C?= =?UTF-8?q?=E9=9D=A2=E7=9A=84=E6=96=87=E5=AD=97=E8=B6=85=E5=87=BA=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=E6=A1=86=E7=9A=84=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/admin/projects.html.erb | 90 +++++++++++++++---------------- app/views/admin/users.html.erb | 8 +-- 2 files changed, 49 insertions(+), 49 deletions(-) diff --git a/app/views/admin/projects.html.erb b/app/views/admin/projects.html.erb index 2f520a236..762ceae9e 100644 --- a/app/views/admin/projects.html.erb +++ b/app/views/admin/projects.html.erb @@ -1,45 +1,45 @@ -
-<%= link_to l(:label_project_new), {:controller => 'projects', :action => 'new'}, :class => 'icon icon-add' %> -
- -

<%=l(:label_project_plural)%>

- -<%= form_tag({}, :method => :get) do %> -
<%= l(:label_filter_plural) %> - -<%= select_tag 'status', project_status_options_for_select(@status), :class => "small", :onchange => "this.form.submit(); return false;" %> - -<%= text_field_tag 'name', params[:name], :size => 30 %> -<%= submit_tag l(:button_apply), :class => "small", :name => nil %> -<%= link_to l(:button_clear), {:controller => 'admin', :action => 'projects'}, :class => 'icon icon-reload' %> -
-<% end %> -  - -
- - - - - - - - -<% project_tree(@projects) do |project, level| %> - <%= project.css_classes %> <%= level > 0 ? "idnt idnt-#{level}" : nil %>"> - - - - - -<% end %> - -
<%=l(:label_project)%><%=l(:field_is_public)%><%=l(:field_created_on)%>
<%= link_to_project_settings(project, {}, :title => project.short_description) %><%= checked_image project.is_public? %><%= format_date(project.created_on) %> - <%= link_to(l(:button_archive), { :controller => 'projects', :action => 'archive', :id => project, :status => params[:status] }, :data => {:confirm => l(:text_are_you_sure)}, :method => :post, :class => 'icon icon-lock') unless project.archived? %> - <%= link_to(l(:button_unarchive), { :controller => 'projects', :action => 'unarchive', :id => project, :status => params[:status] }, :method => :post, :class => 'icon icon-unlock') if project.archived? && (project.parent.nil? || !project.parent.archived?) %> - <%= link_to(l(:button_copy), { :controller => 'projects', :action => 'copy', :id => project }, :class => 'icon icon-copy') %> - <%= link_to(l(:button_delete), project_path(project), :method => :delete, :class => 'icon icon-del') %> -
-
- -<% html_title(l(:label_project_plural)) -%> +
+<%= link_to l(:label_project_new), {:controller => 'projects', :action => 'new'}, :class => 'icon icon-add' %> +
+ +

<%=l(:label_project_plural)%>

+ +<%= form_tag({}, :method => :get) do %> +
<%= l(:label_filter_plural) %> + +<%= select_tag 'status', project_status_options_for_select(@status), :class => "small", :onchange => "this.form.submit(); return false;" %> + +<%= text_field_tag 'name', params[:name], :size => 30 %> +<%= submit_tag l(:button_apply), :class => "small", :name => nil %> +<%= link_to l(:button_clear), {:controller => 'admin', :action => 'projects'}, :class => 'icon icon-reload' %> +
+<% end %> +  + +
+ + + + + + + + +<% project_tree(@projects) do |project, level| %> + <%= project.css_classes %> <%= level > 0 ? "idnt idnt-#{level}" : nil %>"> + + + + + +<% end %> + +
<%=l(:label_project)%><%=l(:field_is_public)%><%=l(:field_created_on)%>
<%= link_to_project_settings(project, {}) %><%= checked_image project.is_public? %><%= format_date(project.created_on) %> + <%= link_to(l(:button_archive), { :controller => 'projects', :action => 'archive', :id => project, :status => params[:status] }, :data => {:confirm => l(:text_are_you_sure)}, :method => :post, :class => 'icon icon-lock') unless project.archived? %> + <%= link_to(l(:button_unarchive), { :controller => 'projects', :action => 'unarchive', :id => project, :status => params[:status] }, :method => :post, :class => 'icon icon-unlock') if project.archived? && (project.parent.nil? || !project.parent.archived?) %> + <%= link_to(l(:button_copy), { :controller => 'projects', :action => 'copy', :id => project }, :class => 'icon icon-copy') %> + <%= link_to(l(:button_delete), project_path(project), :method => :delete, :class => 'icon icon-del') %> +
+
+ +<% html_title(l(:label_project_plural)) -%> diff --git a/app/views/admin/users.html.erb b/app/views/admin/users.html.erb index 834c9f6c2..8bd1ef446 100644 --- a/app/views/admin/users.html.erb +++ b/app/views/admin/users.html.erb @@ -40,13 +40,13 @@ - - - - + + + + From 7b3468718fc990f86a3de378e6ad6bed565fd1cd Mon Sep 17 00:00:00 2001 From: zhanghaitao <562681745@qq.com> Date: Tue, 12 Aug 2014 10:24:27 +0800 Subject: [PATCH 2/4] =?UTF-8?q?#898=20=E5=BC=95=E7=94=A8=E5=9B=9E=E5=B8=96?= =?UTF-8?q?=E4=B8=8D=E8=BD=AC=E4=B9=89=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/messages/_project_show.html.erb | 3 ++- app/views/messages/show.html.erb | 10 +++++----- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/app/views/messages/_project_show.html.erb b/app/views/messages/_project_show.html.erb index 4456f36e9..66027e6ec 100644 --- a/app/views/messages/_project_show.html.erb +++ b/app/views/messages/_project_show.html.erb @@ -161,7 +161,8 @@
- <%= textilizable message, :content, :attachments => message.attachments %> + <%#= textilizable message,:content,:attachments => message.attachments %> + <%= message.content.html_safe %>
<%= link_to_attachments message, :author => false %> diff --git a/app/views/messages/show.html.erb b/app/views/messages/show.html.erb index 6e5888363..5996852ef 100644 --- a/app/views/messages/show.html.erb +++ b/app/views/messages/show.html.erb @@ -1,5 +1,5 @@ -<% if @project %> - <%= render :partial => 'project_show', locals: {project: @project} %> -<% elsif @course %> - <%= render :partial => 'course_show', locals: {course: @course} %> -<% end %> +<% if @project %> + <%= render :partial => 'project_show', locals: {project: @project} %> +<% elsif @course %> + <%= render :partial => 'course_show', locals: {course: @course} %> +<% end %> From 835ef9751081a60be2749f9c61b075fc45a1436c Mon Sep 17 00:00:00 2001 From: sw <939547590@qq.com> Date: Tue, 12 Aug 2014 11:22:37 +0800 Subject: [PATCH 3/4] =?UTF-8?q?wiki=E7=BC=96=E8=BE=91=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=E6=8F=92=E4=BB=B6=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/wiki/_content.html.erb | 1 + app/views/wiki/edit.html.erb | 12 ++++++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/app/views/wiki/_content.html.erb b/app/views/wiki/_content.html.erb index 60b6a7452..fcfcc1351 100644 --- a/app/views/wiki/_content.html.erb +++ b/app/views/wiki/_content.html.erb @@ -1,4 +1,5 @@
<%= textilizable content, :text, :attachments => content.page.attachments, :edit_section_links => (@sections_editable && {:controller => 'wiki', :action => 'edit', :project_id => @page.project, :id => @page.title}) %> + <%#= content.text.html_safe %>
diff --git a/app/views/wiki/edit.html.erb b/app/views/wiki/edit.html.erb index 85b964a9b..35f905eef 100644 --- a/app/views/wiki/edit.html.erb +++ b/app/views/wiki/edit.html.erb @@ -1,5 +1,6 @@ <%= wiki_page_breadcrumb(@page) %> +

<%= h @page.pretty_title %>

<%= form_for @content, :as => :content, @@ -12,8 +13,15 @@ <% end %> <%= error_messages_for 'content' %> +
+

<%=text_area_tag 'content[text]', @text, :required => true, :id => 'editor02', :cols => 100, :rows => 25 %>

+ +
+
-<%= text_area_tag 'content[text]', @text, :cols => 100, :rows => 25, +<%#= text_area_tag 'content[text]', @text, :cols => 100, :rows => 25, :class => 'wiki-edit', :accesskey => accesskey(:edit) %>