diff --git a/app/controllers/panel/personal_research/back_end/researchs_controller.rb b/app/controllers/panel/personal_research/back_end/researchs_controller.rb index 0460a07..e5d753a 100644 --- a/app/controllers/panel/personal_research/back_end/researchs_controller.rb +++ b/app/controllers/panel/personal_research/back_end/researchs_controller.rb @@ -101,7 +101,13 @@ class Panel::PersonalResearch::BackEnd::ResearchsController < OrbitBackendContro respond_to do |format| if @research.update_attributes(params[:research]) - format.html { redirect_to(panel_personal_research_back_end_researchs_url) } + + if params[:research][:user_id] + format.html { redirect_to(admin_users_new_interface_url(:id=>params[:research][:user_id],:show_plugin_profile=>"Research")) } + else + format.html { redirect_to(panel_personal_research_back_end_researchs_url) } + end + # format.js { render 'toggle_enable' } format.xml { head :ok } else @@ -119,7 +125,13 @@ class Panel::PersonalResearch::BackEnd::ResearchsController < OrbitBackendContro @research.destroy respond_to do |format| - format.html { redirect_to(panel_personal_research_back_end_researchs_url) } + + if params[:user_id] + format.html { redirect_to(admin_users_new_interface_url(:id=>params[:user_id],:show_plugin_profile=>"Research")) } + else + format.html { redirect_to(panel_personal_research_back_end_researchs_url) } + end + # format.xml { head :ok } format.js end diff --git a/app/views/panel/personal_research/front_end/researchs/show.html.erb b/app/views/panel/personal_research/front_end/researchs/show.html.erb index 971f9df..b874dc0 100644 --- a/app/views/panel/personal_research/front_end/researchs/show.html.erb +++ b/app/views/panel/personal_research/front_end/researchs/show.html.erb @@ -1,5 +1,6 @@ <% # encoding: utf-8 %> +
<%= t("personal_research.publication_date")%> | <%= @research.publish_date %> |
---|---|
<%= t("personal_research.publication_date")%> | <%= @research.publish_date.strftime("%Y.%m") %> |
<%= t("personal_research.url")%> | <%= link_to t(:url), @research.url, {:target => '_blank', :title => @research.url} if !@research.url.blank? %> |
<%= t("personal_research.authors")%> | <%= "#{User.from_id(@research.create_user_id).name rescue ''},#{@research.authors rescue ''}"%> |
<%= t("personal_research.authors")%> | <%= "#{@research.authors rescue ''}"%> |
<%= t("personal_research.file")%> | @@ -45,3 +48,4 @@ <% end %>
<%= check_box_tag 'to_change[]', research.id.to_s, false, :class => "list-check" %> @@ -64,6 +64,14 @@ | <%= research.publish_date.strftime("%Y.%m") %> |
<%= link_to research.research_title, panel_personal_research_front_end_research_path(research) %>
+
+
+ |