Commit 5b4aa026 authored by zhengjiangtao's avatar zhengjiangtao

首页点击三维公司orgcode获取调整

parent b6afecb1
...@@ -662,41 +662,47 @@ class IndexMap extends Component { ...@@ -662,41 +662,47 @@ class IndexMap extends Component {
* 点击名称切换三维 * 点击名称切换三维
*/ */
markerOnClick = (city) => { markerOnClick = (city) => {
// let { orgCode } = this.getOrgCode(city, this.state.companys);
if (city === 'xian' || city === 'xianyang' || city === 'xidajie'){
this.state.isOnClickCity=true; this.state.isOnClickCity=true;
let selectedCompanyOrg = lsTool.read('selectedCompanyOrg');
let dictionaryList = lsTool.read('dictionaryList'); let dictionaryList = lsTool.read('dictionaryList');
let dicCodeList = JSON.parse(dictionaryList); let dicCodeList = JSON.parse(dictionaryList);
let orgCode = this.getSelectOrgCode(city, dicCodeList);
let selectedCompanyOrg = lsTool.read('selectedCompanyOrg');
let companyName = this.getSelectCityByOrgCode(selectedCompanyOrg, dicCodeList); let companyName = this.getSelectCityByOrgCode(selectedCompanyOrg, dicCodeList);
let map = null; let map = null;
if (companyName && companyName.indexOf("清算中心") !== -1) {
if(companyName && companyName.indexOf("清算中心") !== -1){
let orgCode = this.getSelectOrgCode(city, dicCodeList);
if (city === 'xian' || city === 'xianyang' || city === 'xidajie'){
map = { 'is3DPage': true, 'city': city, 'orgCode': orgCode }; map = { 'is3DPage': true, 'city': city, 'orgCode': orgCode };
}else{
map = { 'is3DPage': true, 'city': '', 'orgCode': '' };
}
} else { } else {
//如果不是西安CCPC,orgCode为空 map = { 'is3DPage': true, 'city': '', 'orgCode': selectedCompanyOrg };
map = { 'is3DPage': true, 'city': city, 'orgCode': '' };
} }
this.props.indexViewChange(map); this.props.indexViewChange(map);
}
} }
markerOnClick1 = (city,flag,id, pointName,pointAttrs,floor,pointtype) => { markerOnClick1 = (city,flag,id, pointName,pointAttrs,floor,pointtype) => {
// let { orgCode } = this.getOrgCode(city, this.state.companys);
let selectedCompanyOrg = lsTool.read('selectedCompanyOrg');
let dictionaryList = lsTool.read('dictionaryList'); let dictionaryList = lsTool.read('dictionaryList');
let dicCodeList = JSON.parse(dictionaryList); let dicCodeList = JSON.parse(dictionaryList);
let orgCode = this.getSelectOrgCode(city,dicCodeList);
// let selectedCompany = lsTool.read('selectedCompany');
let selectedCompanyOrg = lsTool.read('selectedCompanyOrg');
let companyName = this.getSelectCityByOrgCode(selectedCompanyOrg, dicCodeList); let companyName = this.getSelectCityByOrgCode(selectedCompanyOrg, dicCodeList);
let map = null; let map = null;
if (companyName.indexOf("清算中心")!==-1){
if(companyName && companyName.indexOf("清算中心") !== -1){
let orgCode = this.getSelectOrgCode(city, dicCodeList);
if (city === 'xian' || city === 'xianyang' || city === 'xidajie'){
//map = { 'is3DPage': true, 'city': city, 'orgCode': orgCode };
map = { 'is3DPage': true, 'city': city, 'orgCode': orgCode ,'flag':flag,'pid':id,'pointName':pointName,'pointAttrs':pointAttrs,'floor':floor,'pointtype':pointtype}; map = { 'is3DPage': true, 'city': city, 'orgCode': orgCode ,'flag':flag,'pid':id,'pointName':pointName,'pointAttrs':pointAttrs,'floor':floor,'pointtype':pointtype};
} else { }else{
//如果不是西安CCPC,orgCode为空
map = { 'is3DPage': true, 'city': city, 'orgCode': '','flag':flag ,'pid':id,'pointName':pointName,'pointAttrs':pointAttrs,'floor':floor,'pointtype':pointtype}; map = { 'is3DPage': true, 'city': city, 'orgCode': '','flag':flag ,'pid':id,'pointName':pointName,'pointAttrs':pointAttrs,'floor':floor,'pointtype':pointtype};
} }
} else {
map = { 'is3DPage': true, 'city': city, 'orgCode': selectedCompanyOrg ,'flag':flag,'pid':id,'pointName':pointName,'pointAttrs':pointAttrs,'floor':floor,'pointtype':pointtype};
}
this.props.indexViewChange(map); this.props.indexViewChange(map);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment