配置页面新建二级域名样式

This commit is contained in:
huang 2016-05-04 15:50:53 +08:00
parent a691fb7eb7
commit 8dfe95dfd1
4 changed files with 5 additions and 7 deletions

View File

@ -5,6 +5,7 @@ class SubDomainsController < ApplicationController
def new
@subdomain = SubDomain.new
@org_subfield = OrgSubfield.find(params[:org_subfield_id])
@organization = @org_subfield.organization
end
def create

View File

@ -1,2 +1,3 @@
module SubDomainsHelper
include OrganizationsHelper
end

View File

@ -172,11 +172,10 @@
if ($("#subfield_name").val().trim() != "")
$("#add_subfield_form").submit();
}
function add_org_subfield_subdomain(){
if ($("#subfield_name_subdomain").val().trim() != "")
alert("Test");
$("#add_subfield_form_subdomain").submit();
$("#add_subfield_form_subdomain").submit();
$("#org_subfield_list").html('<%= escape_javascript(render(:partial => 'organizations/subfield_list', :locals => {:subfields => @organization.org_subfields.order("priority")} )) %>');
}
var $is_exist = false;
function apply_subdomain(id, domain){

View File

@ -23,8 +23,5 @@
<script type="javascript">
function add_org_subfield_subdomain(){
if ($("#subfield_name_subdomain").val().trim() != "")
$("#add_subfield_form_subdomain").submit();
}
</script>