Commit 5b4aa026 authored by zhengjiangtao's avatar zhengjiangtao

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

parent b6afecb1
...@@ -662,40 +662,46 @@ class IndexMap extends Component { ...@@ -662,40 +662,46 @@ class IndexMap extends Component {
* 点击名称切换三维 * 点击名称切换三维
*/ */
markerOnClick = (city) => { markerOnClick = (city) => {
// let { orgCode } = this.getOrgCode(city, this.state.companys); this.state.isOnClickCity=true;
if (city === 'xian' || city === 'xianyang' || city === 'xidajie'){ let selectedCompanyOrg = lsTool.read('selectedCompanyOrg');
this.state.isOnClickCity=true; let dictionaryList = lsTool.read('dictionaryList');
let dictionaryList = lsTool.read('dictionaryList'); let dicCodeList = JSON.parse(dictionaryList);
let dicCodeList = JSON.parse(dictionaryList); let companyName = this.getSelectCityByOrgCode(selectedCompanyOrg, dicCodeList);
let map = null;
if(companyName && companyName.indexOf("清算中心") !== -1){
let orgCode = this.getSelectOrgCode(city, dicCodeList); let orgCode = this.getSelectOrgCode(city, dicCodeList);
let selectedCompanyOrg = lsTool.read('selectedCompanyOrg'); if (city === 'xian' || city === 'xianyang' || city === 'xidajie'){
let companyName = this.getSelectCityByOrgCode(selectedCompanyOrg, dicCodeList);
let map = null;
if (companyName && companyName.indexOf("清算中心") !== -1) {
map = { 'is3DPage': true, 'city': city, 'orgCode': orgCode }; map = { 'is3DPage': true, 'city': city, 'orgCode': orgCode };
} else { }else{
//如果不是西安CCPC,orgCode为空 map = { 'is3DPage': true, 'city': '', 'orgCode': '' };
map = { 'is3DPage': true, 'city': city, 'orgCode': '' };
} }
} else {
this.props.indexViewChange(map); map = { 'is3DPage': true, 'city': '', 'orgCode': selectedCompanyOrg };
} }
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){
map = { 'is3DPage': true, 'city': city, 'orgCode': orgCode ,'flag':flag,'pid':id,'pointName':pointName,'pointAttrs':pointAttrs,'floor':floor,'pointtype':pointtype}; if(companyName && companyName.indexOf("清算中心") !== -1){
} else { let orgCode = this.getSelectOrgCode(city, dicCodeList);
//如果不是西安CCPC,orgCode为空 if (city === 'xian' || city === 'xianyang' || city === 'xidajie'){
map = { 'is3DPage': true, 'city': city, 'orgCode': '','flag':flag ,'pid':id,'pointName':pointName,'pointAttrs':pointAttrs,'floor':floor,'pointtype':pointtype}; //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};
}else{
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