Merge branch 'dev' of https://git.code.tencent.com/lian-cbtc/jl-client into dev
This commit is contained in:
commit
0656f04dd5
@ -857,7 +857,7 @@ export default class Section extends Group {
|
|||||||
checkIsDrawMap() {
|
checkIsDrawMap() {
|
||||||
const path = window.location.href;
|
const path = window.location.href;
|
||||||
if (path.includes('/map/draw')) {
|
if (path.includes('/map/draw')) {
|
||||||
this.highlight = new EHighlight(this.section);
|
this.highlight = new EHighlight(this);
|
||||||
this.add(this.highlight);
|
this.add(this.highlight);
|
||||||
this.on('mouseout', () => { this.highlight.mouseout(); });
|
this.on('mouseout', () => { this.highlight.mouseout(); });
|
||||||
this.on('mouseover', () => { this.highlight.mouseover(); });
|
this.on('mouseover', () => { this.highlight.mouseover(); });
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
import Group from 'zrender/src/container/Group';
|
import Group from 'zrender/src/container/Group';
|
||||||
import Rect from 'zrender/src/graphic/shape/Rect';
|
import Rect from 'zrender/src/graphic/shape/Rect';
|
||||||
|
import Polygon from 'zrender/src/graphic/shape/Polygon';
|
||||||
|
|
||||||
class EHighlight extends Group {
|
class EHighlight extends Group {
|
||||||
constructor(device) {
|
constructor(device) {
|
||||||
@ -11,17 +12,38 @@ class EHighlight extends Group {
|
|||||||
create() {
|
create() {
|
||||||
if (this.device) {
|
if (this.device) {
|
||||||
const rect = this.device.getBoundingRect();
|
const rect = this.device.getBoundingRect();
|
||||||
this.lineBorder = new Rect({
|
if (this.device._type === 'Section') {
|
||||||
zlevel: this.device.zlevel,
|
const points = [];
|
||||||
z: this.device.z + 1,
|
this.device.model.points.forEach(item => {
|
||||||
shape: rect,
|
points.unshift([item.x + 2, item.y + 2]);
|
||||||
style: {
|
});
|
||||||
lineDash: [3, 3],
|
this.device.model.points.forEach(item => {
|
||||||
stroke: '#fff',
|
points.push([item.x - 2, item.y - 2]);
|
||||||
fill: 'rgba(204,255,255,0.5)'
|
});
|
||||||
}
|
this.lineBorder = new Polygon({
|
||||||
});
|
zlevel: this.device.zlevel,
|
||||||
|
z:this.device.z + 1,
|
||||||
|
shape: {
|
||||||
|
points: points
|
||||||
|
},
|
||||||
|
style: {
|
||||||
|
lineDash: [3, 3],
|
||||||
|
stroke: '#fff',
|
||||||
|
fill: 'rgba(204,255,255,0.5)'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
this.lineBorder = new Rect({
|
||||||
|
zlevel: this.device.zlevel,
|
||||||
|
z: this.device.z + 1,
|
||||||
|
shape: rect,
|
||||||
|
style: {
|
||||||
|
lineDash: [3, 3],
|
||||||
|
stroke: '#fff',
|
||||||
|
fill: 'rgba(204,255,255,0.5)'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
this.add(this.lineBorder);
|
this.add(this.lineBorder);
|
||||||
this.lineBorder.hide();
|
this.lineBorder.hide();
|
||||||
}
|
}
|
||||||
|
@ -195,6 +195,11 @@
|
|||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
|
<el-form ref="showDelimiter" label-width="130px" size="mini">
|
||||||
|
<el-form-item label="是否显示分隔符" style="margin-top:30px;margin-left:30px;">
|
||||||
|
<el-checkbox v-model="isDelimiter"/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
</el-scrollbar>
|
</el-scrollbar>
|
||||||
</div>
|
</div>
|
||||||
<div class="button_box">
|
<div class="button_box">
|
||||||
@ -235,6 +240,7 @@ export default {
|
|||||||
TrainPositionTypeList: [],
|
TrainPositionTypeList: [],
|
||||||
regionList: [],
|
regionList: [],
|
||||||
viewSelect: false,
|
viewSelect: false,
|
||||||
|
isDelimiter:false,
|
||||||
editModel: {
|
editModel: {
|
||||||
code: '',
|
code: '',
|
||||||
name: '',
|
name: '',
|
||||||
@ -807,6 +813,10 @@ export default {
|
|||||||
region: model.region,
|
region: model.region,
|
||||||
relevanceSectionList: []
|
relevanceSectionList: []
|
||||||
};
|
};
|
||||||
|
if(this.isDelimiter){
|
||||||
|
data.sepTypeLeft='01';
|
||||||
|
data.sepTypeRight='01';
|
||||||
|
}
|
||||||
return data;
|
return data;
|
||||||
},
|
},
|
||||||
// 创建逻辑区段
|
// 创建逻辑区段
|
||||||
|
Loading…
Reference in New Issue
Block a user