Merge branch 'develop' of http://10.0.6.99/gwall/gwall.git into develop

This commit is contained in:
zhangwei
2018-05-31 09:33:41 +08:00
9 changed files with 225 additions and 205 deletions

View File

@@ -71,59 +71,131 @@ $(function(){
if($(this).is(":visible")){
if(val==0){
$("#areaIp").removeClass("hidden");
/*$("#areaIsp").find(".container-fluid:visible").find("input,select,div,button").each(function(){
$(this).attr("disabled","true");
});*/
$("#areaIsp").addClass("hidden");
if($("#areaIp").find(".container-fluid:visible").size() <1){
$("#areaIp").find(".glyphicon-plus").click();
}
/*$("#areaIp").find(".container-fluid:visible").find("input,select,div,button").each(function(){
$(this).removeAttr("disabled");
});*/
$("#areaIp").find(".container-fluid").each(function(){
$(this).find("input,select,div,button").each(function(){
$(this).removeAttr("disabled");
$(this).removeClass("disabled");
})
});
$("#areaIsp").find(".container-fluid").each(function(){
$(this).find("input,select,div,button").each(function(){
$(this).attr("disabled","disabled");
})
});
}else{
$("#areaIsp").removeClass("hidden");
/*$("#areaIp").find(".container-fluid:visible").find("input,select,div,button").each(function(){
$(this).attr("disabled","true");
});*/
$("#areaIp").addClass("hidden");
if($("#areaIsp").find(".container-fluid:visible").size() <1){
$("#areaIsp").find(".glyphicon-plus").click();
}
/*$("#areaIsp").find(".container-fluid:visible").find("input,select,div,button").each(function(){
$(this).removeAttr("disabled");
});*/
$("#areaIsp").find(".container-fluid").each(function(){
$(this).find("input,select,div,button").each(function(){
$(this).removeAttr("disabled");
$(this).removeClass("disabled");
})
});
$("#areaIp").find(".container-fluid").each(function(){
$(this).find("input,select,div,button").each(function(){
$(this).attr("disabled","disabled");
})
});
}
}else{
$("#areaIsp").addClass("hidden");
$("#areaIp").addClass("hidden");
$("#areaIsp").find(".container-fluid").each(function(){
$(this).find("input,select,div,button").each(function(){
$(this).attr("disabled","disabled");
})
});
$("#areaIp").find(".container-fluid").each(function(){
$(this).find("input,select,div,button").each(function(){
$(this).attr("disabled","disabled");
})
});
}
});
$("input[name='isAreaEffective']").on('change',function(){
var val=$(this).val();
if(val==1){
$(".areaType").find("input,select,div,button").each(function(){
$(this).removeAttr("disabled");
$(this).removeClass("disabled");
});
$(".areaType").removeClass("hidden");
if($("input[name='areaType']:checked").val()==1){//areaISP
$("#areaIsp").removeClass("hidden");
if($("#areaIsp").find(".container-fluid:visible").size() <1){
$("#areaIsp").find(".glyphicon-plus").click();
}
$("#areaIsp").find(".container-fluid").each(function(){
$(this).find("input,select,div,button").each(function(){
$(this).removeAttr("disabled");
$(this).removeClass("disabled");
})
});
$("#areaIp").find(".container-fluid").each(function(){
$(this).find("input,select,div,button").each(function(){
$(this).attr("disabled","disabled");
})
});
}else if($("input[name='areaType']:checked").val()==0){//areaIp
$("#areaIp").removeClass("hidden");
if($("#areaIp").find(".container-fluid:visible").size() <1){
$("#areaIp").find(".glyphicon-plus").click();
}
$("#areaIp").find(".container-fluid").each(function(){
$(this).find("input,select,div,button").each(function(){
$(this).removeAttr("disabled");
$(this).removeClass("disabled");
})
});
$("#areaIsp").find(".container-fluid").each(function(){
$(this).find("input,select,div,button").each(function(){
$(this).attr("disabled","disabled");
})
});
}else{
$(".areaType").find("[value='1']").prop("checked",true);
$("#areaIsp").removeClass("hidden");
if($("#areaIsp").find(".container-fluid:visible").size() <1){
$("#areaIsp").find(".glyphicon-plus").click();
}
$("#areaIsp").find(".container-fluid").each(function(){
$(this).find("input,select,div,button").each(function(){
$(this).removeAttr("disabled");
$(this).removeClass("disabled");
})
});
$("#areaIp").find(".container-fluid").each(function(){
$(this).find("input,select,div,button").each(function(){
$(this).attr("disabled","disabled");
})
});
}
}else{
$(".areaType").addClass("hidden");
$("#areaIp").addClass("hidden");
$("#areaIsp").addClass("hidden");
$(".areaType").find("input,select,div,button").each(function(){
$(this).attr("disabled","disabled");
});
$("#areaIsp").find(".container-fluid").each(function(){
$(this).find("input,select,div,button").each(function(){
$(this).attr("disabled","disabled");
})
});
$("#areaIp").find(".container-fluid").each(function(){
$(this).find("input,select,div,button").each(function(){
$(this).attr("disabled","disabled");
})
});
}
});
areaControlInit();