locationBind
This commit is contained in:
parent
dec05c1907
commit
6e154680b2
|
@ -193,14 +193,16 @@
|
||||||
//表单提交方法
|
//表单提交方法
|
||||||
submit() {
|
submit() {
|
||||||
let that = this;
|
let that = this;
|
||||||
|
let item = this.form.location;
|
||||||
/*let item = this.form.location;
|
/*let item = this.form.location;
|
||||||
let tool = new jsmap.JSMapCoordTool(window.map);
|
let tool = new jsmap.JSMapCoordTool(window.map);
|
||||||
let coordinate = {x:item[0],y:item[1],z:item.z};
|
let coordinate = {x:item[0],y:item[1],z:item.z};
|
||||||
let pixel = tool.mapToScreenCoordinate(coordinate);
|
let pixel = tool.mapToScreenCoordinate(coordinate);
|
||||||
that.form.location = pixel;*/
|
that.form.location = pixel;*/
|
||||||
this.form.code = this.channelCode;
|
that.form.code = that.channelCode;
|
||||||
this.form.type = this.channelType;
|
that.form.type = that.channelType;
|
||||||
this.form.name = this.channelName;
|
that.form.name = that.channelName;
|
||||||
|
that.form.location = {x:item[0],y:item[1],z:item.z};
|
||||||
that.$API.am.tdevice.labelLocation.req(that.form)
|
that.$API.am.tdevice.labelLocation.req(that.form)
|
||||||
.then(res => {
|
.then(res => {
|
||||||
that.isSaveing = false;
|
that.isSaveing = false;
|
||||||
|
|
|
@ -327,7 +327,13 @@
|
||||||
<div class="simple-btn-bg alarm-btn">需充电卡片0人</div>
|
<div class="simple-btn-bg alarm-btn">需充电卡片0人</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="info-body">
|
<div class="info-body">
|
||||||
<el-table :data="areaList" style="width: 100%" highlight-current-row class="bigScreenTable">
|
<el-table
|
||||||
|
:data="areaList"
|
||||||
|
style="width: 100%"
|
||||||
|
highlight-current-row
|
||||||
|
class="bigScreenTable"
|
||||||
|
@row-click="areaRowClick"
|
||||||
|
>
|
||||||
<el-table-column label="区域" prop="name"></el-table-column>
|
<el-table-column label="区域" prop="name"></el-table-column>
|
||||||
<el-table-column label="当前人数" prop="count_people"></el-table-column>
|
<el-table-column label="当前人数" prop="count_people"></el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
|
@ -342,7 +348,18 @@
|
||||||
@node-click="groupClick"
|
@node-click="groupClick"
|
||||||
></el-tree>-->
|
></el-tree>-->
|
||||||
</div>
|
</div>
|
||||||
|
<div class="alarm-detail-info left_arrow" v-if="areaDetail">
|
||||||
|
<div class="simple-title">
|
||||||
|
<div><span>区域统计</span></div>
|
||||||
|
<span class="icon-close" @click="areaDetail=false"></span>
|
||||||
|
</div>
|
||||||
|
<div class="detail-content">
|
||||||
|
<div class="content-head">
|
||||||
|
</div>
|
||||||
|
<div class="content-body">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!--切换-->
|
<!--切换-->
|
||||||
|
@ -701,7 +718,7 @@
|
||||||
<!--风险区域-->
|
<!--风险区域-->
|
||||||
<div class="screen-risk" v-if="screenRisk">
|
<div class="screen-risk" v-if="screenRisk">
|
||||||
<div class="simple-title">
|
<div class="simple-title">
|
||||||
<div>区域风险详情</div>
|
<div>风险区域详情</div>
|
||||||
<div class="simple-btn" @click="closeScreenRisk">关闭</div>
|
<div class="simple-btn" @click="closeScreenRisk">关闭</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="risk-content">
|
<div class="risk-content">
|
||||||
|
@ -818,6 +835,7 @@
|
||||||
countIndex: '2',
|
countIndex: '2',
|
||||||
markList: [false, false, false, false, false, false, false],
|
markList: [false, false, false, false, false, false, false],
|
||||||
autoRun: false,
|
autoRun: false,
|
||||||
|
areaDetail: false,
|
||||||
screenJob: false,
|
screenJob: false,
|
||||||
screenUser: false,
|
screenUser: false,
|
||||||
screenRisk: false,
|
screenRisk: false,
|
||||||
|
@ -1069,8 +1087,12 @@
|
||||||
this.getWarnings();//报警统计$$
|
this.getWarnings();//报警统计$$
|
||||||
this.getAreas();//区域*/
|
this.getAreas();//区域*/
|
||||||
},3000)
|
},3000)
|
||||||
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
areaRowClick(){
|
||||||
|
this.areaDetail = true;
|
||||||
|
},
|
||||||
//岗位
|
//岗位
|
||||||
getAllPost(){
|
getAllPost(){
|
||||||
this.$API.system.post.list.req({page:0}).then(res=>{
|
this.$API.system.post.list.req({page:0}).then(res=>{
|
||||||
|
@ -1427,67 +1449,24 @@
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
that.userMaskerLayer.addMarker(iconTextMarker);
|
that.userMaskerLayer.addMarker(iconTextMarker);
|
||||||
debugger;
|
|
||||||
let employee_1 = that.userList[1].my_info.employee_;
|
|
||||||
iconTextMarker1 = new jsmap.JSIconTextMarker({
|
|
||||||
id: that.userList[1].my_info.code,
|
|
||||||
position: {x: 114.62923138539462, y: 38.8133418942642, z: 0}, //坐标
|
|
||||||
floorId: 1, //楼层id,默认为1(地面)
|
|
||||||
image: "/img/user.png",
|
|
||||||
text: employee_1.name,
|
|
||||||
font: '10px sans-serif',
|
|
||||||
fontColor: '#ffffff',
|
|
||||||
imageHeight: 25,
|
|
||||||
imageWidth: 25,
|
|
||||||
backgroundColor: 'rgba(0,0,0,0.3)',
|
|
||||||
backgroundRadius: 1,
|
|
||||||
backgroundStrokeColor: 'rgba(0,0,0,0.3)',
|
|
||||||
backgroundStrokeWidth: 1,
|
|
||||||
iconTextType: jsmap.JSIconTextType.TOPTEXT_BOTTOMICON,
|
|
||||||
allowPicking: true,
|
|
||||||
displayCondition: new jsmap.JSDisplayCondition(0.0, 1000),
|
|
||||||
nearFarScale: new jsmap.JSNearFarScale(0.0, 1, 500, 1),
|
|
||||||
show: true,
|
|
||||||
properties: {
|
|
||||||
employee: employee_1
|
|
||||||
},
|
|
||||||
callback: (marker) => {
|
|
||||||
return employee_1
|
|
||||||
}
|
|
||||||
});
|
|
||||||
that.userMaskerLayer.addMarker(iconTextMarker1);
|
|
||||||
}else{
|
|
||||||
setTimeout(function () {
|
setTimeout(function () {
|
||||||
let employee_ = that.userList[0].my_info.employee_;
|
console.log(that.userMaskerLayer);
|
||||||
iconTextMarker = new jsmap.JSIconTextMarker({
|
that.userMaskerLayer.updateMarkerPosition(iconTextMarker,{
|
||||||
id: that.userList[0].my_info.code,
|
floorId:1,
|
||||||
position: {x: 114.6315404372349, y: 38.813557855009435, z: 0}, //坐标
|
position: {x:114.62923138539462, y:38.8133418942642, z:0},
|
||||||
floorId: 1, //楼层id,默认为1(地面)
|
animate: true
|
||||||
image: "/img/user.png",
|
});//动画效果,持续时间一秒
|
||||||
text: employee_.name,
|
},3000);
|
||||||
font: '10px sans-serif',
|
/*setTimeout(function () {
|
||||||
fontColor: '#ffffff',
|
console.log(that.userMaskerLayer);
|
||||||
imageHeight: 25,
|
that.userMaskerLayer.updateMarkerPosition(iconTextMarker,{
|
||||||
imageWidth: 25,
|
floorId:1,
|
||||||
backgroundColor: 'rgba(0,0,0,0.3)',
|
position: {x:114.6315404372349, y: 38.813557855009435, z:0},
|
||||||
backgroundRadius: 1,
|
animate: true
|
||||||
backgroundStrokeColor: 'rgba(0,0,0,0.3)',
|
});//动画效果,持续时间一秒
|
||||||
backgroundStrokeWidth: 1,
|
},6000);*/
|
||||||
iconTextType: jsmap.JSIconTextType.TOPTEXT_BOTTOMICON,
|
debugger;
|
||||||
allowPicking: true,
|
/*let employee_1 = that.userList[1].my_info.employee_;
|
||||||
displayCondition: new jsmap.JSDisplayCondition(0.0, 1000),
|
|
||||||
nearFarScale: new jsmap.JSNearFarScale(0.0, 1, 500, 1),
|
|
||||||
show: true,
|
|
||||||
properties: {
|
|
||||||
employee: employee_
|
|
||||||
},
|
|
||||||
callback: (marker) => {
|
|
||||||
return employee_
|
|
||||||
}
|
|
||||||
});
|
|
||||||
that.userMaskerLayer.addMarker(iconTextMarker);
|
|
||||||
|
|
||||||
let employee_1 = that.userList[1].my_info.employee_;
|
|
||||||
iconTextMarker1 = new jsmap.JSIconTextMarker({
|
iconTextMarker1 = new jsmap.JSIconTextMarker({
|
||||||
id: that.userList[1].my_info.code,
|
id: that.userList[1].my_info.code,
|
||||||
position: {x: 114.62923138539462, y: 38.8133418942642, z: 0}, //坐标
|
position: {x: 114.62923138539462, y: 38.8133418942642, z: 0}, //坐标
|
||||||
|
@ -1515,7 +1494,15 @@
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
that.userMaskerLayer.addMarker(iconTextMarker1);
|
that.userMaskerLayer.addMarker(iconTextMarker1);
|
||||||
},3000)
|
setTimeout(function () {
|
||||||
|
that.userMaskerLayer.updateMarkerPosition(jsmap.JSIconTextMarker,{
|
||||||
|
floorId:1,
|
||||||
|
position: {x:114.6315404372349, y:38.813557855009435, z:0},
|
||||||
|
animate: true
|
||||||
|
});//动画效果,持续时间一秒
|
||||||
|
|
||||||
|
},3000)*/
|
||||||
|
}else{
|
||||||
}
|
}
|
||||||
/*that.userList.forEach(item => {
|
/*that.userList.forEach(item => {
|
||||||
if (item.my_info.code) {
|
if (item.my_info.code) {
|
||||||
|
|
Loading…
Reference in New Issue