diff --git a/app/controllers/sub_domains_controller.rb b/app/controllers/sub_domains_controller.rb
index 5ca9b07ed..d16444a74 100644
--- a/app/controllers/sub_domains_controller.rb
+++ b/app/controllers/sub_domains_controller.rb
@@ -1,10 +1,10 @@
class SubDomainsController < ApplicationController
layout 'base_org'
- before_filter :find_org_subfield_and_subdomain, :only => [:show, :index, :new]
+ before_filter :find_org_subfield_and_subdomain, :only => [:show, :index]
def new
@subdomain = SubDomain.new
-
+ @org_subfield = OrgSubfield.find(params[:org_subfield_id])
end
def create
diff --git a/app/views/layouts/base_org2.html.erb b/app/views/layouts/base_org2.html.erb
index 3bf0188a8..3fe002539 100644
--- a/app/views/layouts/base_org2.html.erb
+++ b/app/views/layouts/base_org2.html.erb
@@ -90,7 +90,7 @@
<% end %>
<% if User.current.admin_of_org?(@organization) %>
-
+
<% end %>
diff --git a/app/views/layouts/base_sub_domain.html.erb b/app/views/layouts/base_sub_domain.html.erb
index 71649df54..5f9a0566e 100644
--- a/app/views/layouts/base_sub_domain.html.erb
+++ b/app/views/layouts/base_sub_domain.html.erb
@@ -34,13 +34,13 @@
$(document).ready(function(){
$(".nav-element").mouseover(function(){
$(this).next().show();
- });
+ });
$(".sn-grey-opacity").mouseover(function(){
$(this).show();
});
$(".nav-element").mouseout(function(){
$(this).next().hide();
- });
+ });
$(".sn-grey-opacity").mouseout(function(){
$(this).hide();
});
@@ -144,7 +144,9 @@
-
-
-
您的位置:首页 > 数据资源 > 仿真数据
-
-
-
最新资讯
-
- <% documents.each do |document| %>
- -
- <%=link_to document.title, org_subfield_sub_domain_sub_document_comment_path(document, :org_subfield_id => @org_subfield, :sub_domain_id => @subdomain), :class => "sn-newslist-titile fl", :target => "_blank" %>
- <%= format_date(document.created_at) %>>回复(100)(100)
-
-
- <% end %>
-
-
-
-
- <%= pagination_links_full @atta_pages, @atta_count, :per_page_links => true, :remote => @is_remote, :flag => true %>
-
-
-
-
-
+
+
+
+
您的位置:首页 > 数据资源 > 仿真数据
+
+
+
最新资讯
+
+ <% documents.each do |document| %>
+ -
+ <%=link_to document.title, org_subfield_sub_domain_sub_document_comment_path(document, :org_subfield_id => @org_subfield, :sub_domain_id => @subdomain), :class => "sn-newslist-titile fl", :target => "_blank" %>
+ <%= format_date(document.created_at) %>>回复(100)(100)
+
+
+ <% end %>
+
+
+
+
+ <%= pagination_links_full @atta_pages, @atta_count, :per_page_links => true, :remote => @is_remote, :flag => true %>
+
+
+
+
+
\ No newline at end of file
diff --git a/app/views/sub_domains/_new.html.erb b/app/views/sub_domains/_new.html.erb
index 3c63c073d..510d469cf 100644
--- a/app/views/sub_domains/_new.html.erb
+++ b/app/views/sub_domains/_new.html.erb
@@ -1,3 +1,30 @@
-
- test
-
\ No newline at end of file
+
+
+
+
\ No newline at end of file
diff --git a/app/views/sub_domains/new.html.erb b/app/views/sub_domains/new.html.erb
index a497b71cf..e69de29bb 100644
--- a/app/views/sub_domains/new.html.erb
+++ b/app/views/sub_domains/new.html.erb
@@ -1,6 +0,0 @@
-$('#ajax-modal').html('<%= escape_javascript(render :partial => 'sub_domains/new',:locals => {:course => @course,:course_attachment_type => 1}) %>');
-showModal('ajax-modal', '513px');
-$('#ajax-modal').siblings().remove();
-$('#ajax-modal').before("
");
-$('#ajax-modal').parent().css("top","40%").css("left","50%").css("border","3px solid #269ac9");
-$('#ajax-modal').parent().addClass("popbox_polls");
\ No newline at end of file
diff --git a/app/views/sub_domains/new.js.erb b/app/views/sub_domains/new.js.erb
index 66d9aeca2..3f7f1ad47 100644
--- a/app/views/sub_domains/new.js.erb
+++ b/app/views/sub_domains/new.js.erb
@@ -1 +1,6 @@
-alert("test");
\ No newline at end of file
+$('#ajax-modal').html('<%= escape_javascript(render :partial => 'sub_domains/new',:locals => {:field => @org_subfield}) %>');
+showModal('ajax-modal', '513px');
+$('#ajax-modal').siblings().remove();
+$('#ajax-modal').before("
");
+$('#ajax-modal').parent().css("top","40%").css("left","50%").css("border","3px solid #269ac9");
+$('#ajax-modal').parent().addClass("popbox_polls");
diff --git a/public/images/default_blank/icons-add.png b/public/images/default_blank/icons-add.png
new file mode 100644
index 000000000..059585a0d
Binary files /dev/null and b/public/images/default_blank/icons-add.png differ
diff --git a/public/stylesheets/org2.css b/public/stylesheets/org2.css
index 0debbe405..9de2bf56f 100644
--- a/public/stylesheets/org2.css
+++ b/public/stylesheets/org2.css
@@ -61,7 +61,8 @@ a.sn-link-select {color:#809df9;}
.sn-bg-blue {background-color:#24366e;}
.sn-login {width:1200px; height:45px; line-height:45px; margin:0 auto; font-size:14px; color:#24366e; vertical-align:middle; text-align:right;}
.sn-login2 {width:1200px; height:54px; line-height:54px; margin:0 auto; font-size:14px; color:#24366e; vertical-align:middle; text-align:right;}
-.sn-logo {width:1200px; height:90px; line-height:90px; margin:0 auto; vertical-align:middle;}
+.sn-logo {width:1200px; height:90px; line-height:90px; margin:0 auto; vertical-align:middle;position:relative;}
+.sn-logo-add{ display:block; top:10px; left:0px; position:absolute; width:20px; height:20px;background:url(../images/default_blank/icons-add.png) -0px -3px no-repeat;}
.sn-search-input {width:328px; height:40px; font-size:16px; color:#ccc; padding-left:10px; border:1px solid #ccc; border-right:none; float:right; background-color:#fff; outline:none;}
a.sn-search-button {width:53px; height:40px; border:1px solid #ccc; border-left:none; float:right; outline:none; background:url(../images/sn_search_icon.jpg) 0 3px no-repeat;}
.sn-nav {width:1200px; height:55px; margin:0 auto; font-size:16px; position:relative; line-height:1;}
@@ -75,6 +76,8 @@ a.sn-search-button {width:53px; height:40px; border:1px solid #ccc; border-left:
.sn-sub-nav li a:hover {border-bottom:3px solid #ffbd18; height:37px;}
.sn-subnav-slice {margin:12px 5px;}
.sn-banner {width:1200px; height:210px; margin:0 auto;}
+.sn-logo-add{ display:block; top:5px; left:0px; position:absolute; width:20px; height:20px;background:url(../images/default_blank/icons-add.png) 0px -3px no-repeat;}
+.sn-banner-add{ display:block; position:absolute; top:10px; left:10px;width:27px; height:27px; background:url(../images/default_blank/icons-add.png) -32px -0px no-repeat;}
.sn-content-position {width:1200px; height:50px; line-height:50px; vertical-align:middle; font-size:14px; color:#888; margin:0 auto;}
/*footer样式*/
.sn-footer {width:1200px; height:220px; margin:0 auto; text-align:center; font-size:14px; color:#fff; line-height:normal;}