|
@@ -4,7 +4,7 @@ function Relation(legcerNo,regNo,regCapCurName,data){
|
|
this.regCapCurName = regCapCurName;
|
|
this.regCapCurName = regCapCurName;
|
|
this.data = data;
|
|
this.data = data;
|
|
this.modleFlag = data.nodes.length>15;
|
|
this.modleFlag = data.nodes.length>15;
|
|
- this.ispattern = this.modleFlag;
|
|
|
|
|
|
+ this.defaultIsPattern = this.modleFlag;
|
|
this.zoomlevel = 1;
|
|
this.zoomlevel = 1;
|
|
this.w = 0;
|
|
this.w = 0;
|
|
this.h = 0;
|
|
this.h = 0;
|
|
@@ -138,14 +138,14 @@ Relation.prototype.verbosemode = function(){
|
|
this.modleFlag = false;
|
|
this.modleFlag = false;
|
|
this.makeTextBg();
|
|
this.makeTextBg();
|
|
this.makeTitle();
|
|
this.makeTitle();
|
|
- if(this.ispattern){
|
|
|
|
|
|
+ if(this.defaultIsPattern){
|
|
this.tickFlag = true;
|
|
this.tickFlag = true;
|
|
this.force.linkDistance(Math.floor(Math.random()*60)+150).start();
|
|
this.force.linkDistance(Math.floor(Math.random()*60)+150).start();
|
|
}else{
|
|
}else{
|
|
this.tick();
|
|
this.tick();
|
|
this.force.tick();
|
|
this.force.tick();
|
|
}
|
|
}
|
|
- this.ispattern = false;
|
|
|
|
|
|
+ this.defaultIsPattern = false;
|
|
}
|
|
}
|
|
Relation.prototype.dataProcess = function(){
|
|
Relation.prototype.dataProcess = function(){
|
|
var reg = new RegExp(/(有限公司|有限责任公司|股份有限公司|总公司|分公司|公司|事务所|合伙企业)$|\(.*\)|\(.*\)/g);
|
|
var reg = new RegExp(/(有限公司|有限责任公司|股份有限公司|总公司|分公司|公司|事务所|合伙企业)$|\(.*\)|\(.*\)/g);
|
|
@@ -616,7 +616,7 @@ Relation.prototype.makeRelation = function(){
|
|
.size([this.w, this.h])
|
|
.size([this.w, this.h])
|
|
.linkDistance(function(){
|
|
.linkDistance(function(){
|
|
var distance = Math.floor(Math.random()*60)+100;
|
|
var distance = Math.floor(Math.random()*60)+100;
|
|
- if(!this.ispattern){
|
|
|
|
|
|
+ if(!this.defaultIsPattern){
|
|
distance += 50;
|
|
distance += 50;
|
|
}
|
|
}
|
|
return distance;
|
|
return distance;
|