|
@@ -28,13 +28,23 @@ const { drawGraph,updateTree,getGraph,getTree,getNode,getTab,renderTab} = requir
|
|
|
window.select_type="疾病";
|
|
|
window.select_type_noSearch="疾病";
|
|
|
window.refreshTree = true
|
|
|
- const clientHei = $(window).height()
|
|
|
- const contentHei = clientHei - 80
|
|
|
- $(".left").css("height",contentHei+'px')
|
|
|
- $(".right").css("height",contentHei+'px')
|
|
|
- $(".tabBottom").css("height",contentHei-80-43-10+'px')
|
|
|
- $(".ztree").css("height",contentHei-80-43-60-20+'px')
|
|
|
- $("#main").css("height",contentHei-20-20+'px')
|
|
|
+
|
|
|
+ setHei()
|
|
|
+ function setHei(){
|
|
|
+ const clientHei = $(window).height()
|
|
|
+ const contentHei = clientHei - 80
|
|
|
+ $(".left").css("height",contentHei+'px')
|
|
|
+ $(".right").css("height",contentHei+'px')
|
|
|
+ $(".tabBottom").css("height",contentHei-80-43-10+'px')
|
|
|
+ $(".ztree").css("height",contentHei-80-43-60-20+'px')
|
|
|
+ $("#main").css("height",contentHei-20-20+'px')
|
|
|
+ }
|
|
|
+ $(window).resize(function(){
|
|
|
+ setHei()
|
|
|
+ console.log('graphTxt',graphTxt)
|
|
|
+ getGraph(graphTxt,select_type);
|
|
|
+ })
|
|
|
+
|
|
|
//关系图
|
|
|
getGraph("高血压3级",select_type);
|
|
|
getTree(1,1,"高血压3级");
|
|
@@ -64,7 +74,6 @@ $('.selectList .selectItem').click(function(){
|
|
|
|
|
|
$(".selectedName").attr('title',txt)
|
|
|
$("#searchInp").attr("placeholder",`请输入${txt}名称`)
|
|
|
- $("#searchInp").attr
|
|
|
if(txt != oldTxt){
|
|
|
$('#searchInp').val("")
|
|
|
}
|
|
@@ -130,7 +139,10 @@ $('#searchBtn').click(function(e){
|
|
|
$(".ztree").css("height",contentHei-80-43-60-20+'px')
|
|
|
}else{
|
|
|
$(".radioList").hide()
|
|
|
- $(".ztree").css("height",contentHei-80-43-20+'px')
|
|
|
+ $(".ztree").css("height",contentHei-80-43-20-20+'px')
|
|
|
+ $(".ztree").css({
|
|
|
+ margin: '20 0 0 0px'
|
|
|
+ })
|
|
|
}
|
|
|
let renderTabInfo = getTab("疾病")
|
|
|
renderTab(renderTabInfo)
|