This commit is contained in:
ival 2019-08-20 12:47:53 +08:00
commit 424482dd4b
28 changed files with 536 additions and 782 deletions

View File

@ -1,79 +1,79 @@
export default {
confirm: '确 定',
cancel: '取 消',
creatingSuccessful: '创建成功!',
creatingFailed: '创建失败',
confirmDeletion: '是否确认删除?',
confirmBatchGeneration: '是否确认批量生成?',
hint: '提示',
cancelledDelete: '已取消删除',
cancelGeneration: '已取消批量生成',
confirm: 'confirm',
cancel: 'cancel',
creatingSuccessful: 'Created successfully!',
creatingFailed: 'Create a failure',
confirmDeletion: 'Confirm deletion?',
confirmBatchGeneration: 'Is batch generation confirmed?',
hint: 'hint',
cancelledDelete: 'Cancelled delete',
cancelGeneration: 'Batch generation has been cancelled',
updateSuccessfully: '更新成功',
saveSuccessfully: '保存成功',
saveFailed: '保存失败',
updateFailed: '更新失败',
successfullyDelete: '删除成功',
failDelete: '删除失败',
operationAbnormal: '操作异常',
createSuccess: '创建成功',
updateSuccessfully: 'The update is successful',
saveSuccessfully: 'Save success',
saveFailed: 'Save failed',
updateFailed: 'Update failed',
successfullyDelete: 'Delete the success',
failDelete: 'Delete failed',
operationAbnormal: 'Abnormal operation',
createSuccess: 'Creating a successful',
cannotCoincide: '起始坐标和结束坐标不能重合',
cannotMerged: '存在非物理区段,不能合并',
linkCannotMerged: '不在同一Link上的物理区段不能合并',
cannotCoincide: 'The starting and ending coordinates cannot coincide',
cannotMerged: 'Non-physical extents exist and cannot be merged',
linkCannotMerged: 'Physical extents that are not on the same Link cannot be merged',
selectedSectionEmpty: '选择的区段为空',
selectedStationEmpty: '选择的车站为空',
selectedSectionEmpty: 'The selected section is empty',
selectedStationEmpty: 'The selected station is empty',
selectMap: '请先选择地图',
selectTrainType: '请选择查看的列车模型',
selectMap: 'Please select the map first',
selectTrainType: 'Please select the train model to view',
stationFont: '车站字体',
kilometerFont: '公里标字体',
meter: '',
angle: '',
stationFont: 'The font',
kilometerFont: 'Kilometer mark font',
meter: 'meter',
angle: 'angle',
operationSuccessfully: '操作成功',
operationFailed: '操作失败',
setupSuccessfully: '设置成功',
setupFailed: '设置失败',
recoveryPrivilegesSuccessful: '回收权限成功',
recoveryPrivilegesFailed: '回收权限失败',
unpackingSuccessful: '解包成功',
unpackingFailed: '解包失败',
pleaseEnterNameQuery: '请输入名称查询',
routeSameID: '相同ID的数据已存在',
operationSuccessfully: 'Operation is successful',
operationFailed: 'The operation failure',
setupSuccessfully: 'Set up the success',
setupFailed: 'Setup failed',
recoveryPrivilegesSuccessful: 'Successful recovery authority',
recoveryPrivilegesFailed: 'Recovery authority failed',
unpackingSuccessful: 'Unpack the success',
unpackingFailed: 'Unpack the failure',
pleaseEnterNameQuery: 'Please enter name query',
routeSameID: 'Data with the same ID already exists',
skinDeleteSuccessfully: '删除皮肤成功',
skinDeleteFailed: '删除皮肤失败',
publishedOperationalGraphSuccessfully: '发布运行图成功',
publishedOperationalGraphFailed: '发布运行图失败',
deleteOperationGraphFailed: '删除运行图失败',
importOperationGraphSuccessfully: '导入运行图成功!',
importOperationGraphFailed: '导入运行图失败!',
parsingOperationGraphFailed: '解析运行图失败!',
productCreationSuccessfully: '创建产品成功',
productCreationFailed: '创建产品失败',
updateProductSuccessfully: '更新产品成功',
updateProductFailed: '更新产品失败',
deleteProductSuccessfully: '删除产品成功',
deleteProductFailed: '删除产品失败',
cannotDeleteProduct: '产品已被使用无法删除',
pathCreationSuccessful: '创建交路成功!',
createRoutingFailed: '创建交路失败',
pathUpdataSuccessful: '更新交路成功!',
pathUpdataFailed: '更新交路失败',
skinDeleteSuccessfully: 'Skin removed successfully',
skinDeleteFailed: 'Failed to remove skin',
publishedOperationalGraphSuccessfully: 'Published operational diagram successfully',
publishedOperationalGraphFailed: 'Failed to publish operation diagram',
deleteOperationGraphFailed: 'Failed to delete operation diagram',
importOperationGraphSuccessfully: 'The operation diagram was successfully imported!',
importOperationGraphFailed: 'Failed to import operation diagram!',
parsingOperationGraphFailed: 'Failed to parse the operational diagram!',
productCreationSuccessfully: 'Product creation success',
productCreationFailed: 'Failed to create product',
updateProductSuccessfully: 'Product update is successful.',
updateProductFailed: 'Product update failed',
deleteProductSuccessfully: 'Product deleted successfully',
deleteProductFailed: 'Product deletion failed',
cannotDeleteProduct: 'The product has been used and cannot be deleted',
pathCreationSuccessful: 'Create road successfully!',
createRoutingFailed: 'Failed to create junction',
pathUpdataSuccessful: 'Road update successful!',
pathUpdataFailed: 'Update traffic failed',
failedLoadMap: '加载地图数据失败',
sectionPointsDeficiency: '区段坐标缺失',
failedLoadMap: 'Failed to load map data',
sectionPointsDeficiency: 'Segment coordinates missing',
dataValidationFailed: '数据校验不通过',
dataValidationSuccess: '数据校验通过!',
dataValidationFailed: 'Data validation failed',
dataValidationSuccess: 'Data verified!',
requestFailed: '请求失败',
requestFailed: 'The request failed',
dataQuestion: '有问题数据',
dataList: '数据列表',
dataQuestion: 'Data in question',
dataList: 'Data list',
updateProductTip: 'Will this operation modify the commodity status?',
deleteProductTip: 'This operation will delete the item. Do you want to continue?',

View File

@ -267,7 +267,7 @@ export default {
group: this.group,
conversationId: this.conversationId
};
const res = await postDataBd(param).catch(error => {
await postDataBd(param).catch(error => {
this.sending = false;
const message = JSON.parse(error.message);
if (message.err_no == 3301) {

View File

@ -7,8 +7,8 @@
<i class="el-icon-close" />
</div>
</div>
<el-row type="flex" justify="center">
<el-form label-width="100px" class="demo-ruleForm">
<el-row type="flex" justify="center" class="content_box">
<el-form label-width="80px" class="demo-ruleForm">
<el-form-item :label="$t('map.viewShows')">
<el-checkbox-group v-model="viewSelect" :min="1" @change="handleSelectView">
<el-checkbox :label="ViewMode.LOGIC">{{ $t('map.logicalView') }}</el-checkbox>
@ -28,6 +28,12 @@
{{ view.name }}</el-checkbox>
</el-checkbox-group>
</el-row>
<el-row v-if=" viewSelect.length == 2" class="physical-view" type="flex" justify="center" style="width: 100%;">
<el-checkbox-group v-model="hybridLevelsSelect" @change="handleSelectHybridView">
<el-checkbox v-for="view in HybridViewTypeList" :key="view.code" :label="view.code">
{{ view.name }}</el-checkbox>
</el-checkbox-group>
</el-row>
</el-form-item>
</el-form>
</el-row>
@ -53,8 +59,15 @@ export default {
{ code: 'Signal', name: this.$t('map.signal') },
{ code: 'Switch', name: this.$t('map.switch') }
],
HybridViewTypeList: [],
defaultLogicalSelect: [],
defaultPhysicalSelect: [],
defaultHybridSelect: [],
logicalLevelsSelect: [],
physicalLevelsSelect: []
physicalLevelsSelect: [],
hybridLevelsSelect: [] //
};
},
watch: {
@ -75,22 +88,40 @@ export default {
initPage() {
this.$Dictionary.logicalViewType().then(list => {
this.LogicalViewTypeList = list;
list.forEach(v => {
this.HybridViewTypeList.push(v);
this.hybridLevelsSelect.push(v.code);
this.defaultHybridSelect.push(v.code);
});
this.LogicalViewTypeList.forEach(elem => {
this.logicalLevelsSelect.push(elem.code);
this.defaultLogicalSelect.push(elem.code);
});
});
this.$Dictionary.physicalViewType().then(list => {
this.PhysicalViewTypeList = list;
list.forEach(v => {
this.HybridViewTypeList.push(v);
this.hybridLevelsSelect.push(v.code);
this.defaultHybridSelect.push(v.code);
});
this.PhysicalViewTypeList.forEach(elem => {
this.physicalLevelsSelect.push(elem.code);
this.defaultPhysicalSelect.push(elem.code);
});
});
},
handleSelectView(value) {
if (value.length == 2) {
this.$emit('handleSelectView', '03');
this.hybridLevelsSelect = this.copyList(this.defaultHybridSelect);
} else {
this.$emit('handleSelectView', value);
if (this.viewSelect[0] == this.ViewMode.LOGIC) {
this.logicalLevelsSelect = this.copyList(this.defaultLogicalSelect);
} else {
this.physicalLevelsSelect = this.copyList(this.defaultPhysicalSelect);
}
}
},
handleSelectLogicalView(handle) {
@ -98,6 +129,12 @@ export default {
},
handleSelectPhysicalView(handle) {
this.$emit('handleSelectPhysicalView', handle);
},
handleSelectHybridView(handle) {
this.$emit('handleSelectHybridView', handle);
},
copyList(list) {
return JSON.parse(JSON.stringify(list));
}
}
};
@ -126,11 +163,11 @@ export default {
right: 24px;
top: 43px;
z-index: 10;
padding: 15px;
.title{
margin-bottom: 8px;
overflow: hidden;
border-bottom: 1px solid #ccc;
padding: 9px;
.fl-title{
float: left;
}
@ -140,17 +177,23 @@ export default {
}
}
.content_box{
padding: 15px;
padding-top: 4px;
}
/deep/{
.el-dialog__body{
padding: 0 8px 8px 21px;
}
.el-checkbox{
margin-right: 14px;
margin-right: 10px;
width: 75px;
}
.el-form-item{
margin-bottom: 2px;
margin-bottom: -4px;
}
}
}

View File

@ -28,7 +28,7 @@
@click="showMap"
>{{ $t('map.viewLayer') }}</el-button>
</div>
<el-tabs v-model="enabledTab" type="card" @tab-click="changePane">
<el-tabs v-model="enabledTab" type="card" class="map_card" @tab-click="changePane">
<el-tab-pane label="进路" name="route">
<route-operate
ref="routeOperate"
@ -228,6 +228,12 @@ export default {
margin-right: 30px;
}
}
/deep/ {
.map_card .el-tabs__header .el-tabs__item.is-active {
border-bottom-color: #f5f7fa;
background: #f5f7fa;
}
}
/deep/ .map-draft-group {
float: right;

View File

@ -97,7 +97,7 @@ export default {
prop: 'stationCode'
},
{
title: this.$t('map.routeType'),
title: this.$t('map.accessType'),
prop: 'natureType'
},
@ -129,7 +129,7 @@ export default {
},
{
type: 'button',
title: this.$t('map.routeSideTurnoutData'),
title: this.$t('map.accessSideTurnoutData'),
buttons: [
{
name: this.$t('map.preview'),
@ -165,7 +165,7 @@ export default {
{
type: 'button',
title: this.$t('map.routePhysical'),
title: this.$t('map.accessPhysical'),
buttons: [
{
name: this.$t('map.preview'),

View File

@ -27,7 +27,7 @@
<span>s</span>
</el-form-item>
<el-form-item :label="$t('map.routeTypeColon')" prop="natureType">
<el-form-item :label="$t('map.accessType')" prop="natureType">
<el-select v-model="addModel.natureType" :filterable="true">
<el-option
v-for="item in RouteNatureTypeList"
@ -457,10 +457,10 @@ export default {
{ required: true, message: this.$t('rules.proximitySection'), trigger: 'change' }
],
natureType: [
{ required: true, message: this.$t('rules.routePropertyType'), trigger: 'change' }
{ required: true, message: this.$t('rules.accessPropertyType'), trigger: 'change' }
],
autoType: [
{ required: true, message: this.$t('rules.autoRouteType'), trigger: 'change' }
{ required: true, message: this.$t('rules.autoAccessType'), trigger: 'change' }
],
routeSectionList: [
{ required: true, message: '请选择进路物理区段数据', trigger: 'change' }

View File

@ -4,15 +4,14 @@
<div class="map-view">
<jlmap-visual ref="jlmapVisual" @onSelect="clickEvent" @onMenu="onContextmenu" />
</div>
<div v-loading="loading" class="map-draft">
<div v-if="viewDraft==='draft'">
<div class="map-draft">
<div v-show="viewDraft==='draft'">
<map-operate
ref="mapOperate"
:card-height="cardHeight"
:map-info="mapInfo"
:selected="selected"
:map-saveing="mapSaveing"
@hook:mounted="loading = false"
@handleSelectLogicalView="handleSelectLogicalView"
@handleSelectPhysicalView="handleSelectPhysicalView"
@saveMapEvent="saveMapEvent"
@ -24,14 +23,13 @@
@showMap="showMap"
/>
</div>
<div v-if="viewDraft != 'draft'">
<div v-show="viewDraft != 'draft'">
<data-relation
ref="dataRelation"
:card-height="cardHeight"
:map-info="mapInfo"
:selected="selected"
@selectView="selectViewDraft"
@hook:mounted="loading = false"
@showMap="showMap"
/>
</div>
@ -40,6 +38,7 @@
@handleSelectView="handleSelectView"
@handleSelectLogicalView="handleSelectLogicalView"
@handleSelectPhysicalView="handleSelectPhysicalView"
@handleSelectHybridView="handleSelectHybridView"
/>
</div>
</div>
@ -57,7 +56,6 @@ import { EventBus } from '@/scripts/event-bus';
import ConfigMap from './configMap';
import DataRelation from './dataRelation/index';
import { setTimeout } from 'timers';
export default {
name: 'MapView',
@ -80,8 +78,7 @@ export default {
autoSaveTask: null,
selected: null,
mapInfo: { name: this.$t('map.pleaseSelectMap') },
timeDemon: null,
loading: false
timeDemon: null
};
},
watch: {
@ -125,10 +122,7 @@ export default {
this.$refs.configMap.doShow();
},
selectViewDraft(data) {
this.loading = true;
setTimeout(() => {
this.viewDraft = data;
}, 300);
this.viewDraft = data;
},
loadInitPage() {
this.$store.dispatch('training/changeMode', { mode: TrainingMode.MAP_EDIT });
@ -180,6 +174,11 @@ export default {
this.$refs.jlmapVisual.setLevelVisible(handle);
}
},
handleSelectHybridView(handle) {
if (this.$refs && this.$refs.jlmapVisual) {
this.$refs.jlmapVisual.setLevelVisible(handle);
}
},
clickEvent(em) {
var device = this.getDeviceByEm(em);
this.onSelect(device);

View File

@ -1,22 +1,26 @@
<template>
<div>
<el-tabs v-model="activeName">
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="form" :form="dataForm" :form-model="editModel" :rules="rules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-data ref="make" :form="makeForm" :form-model="addModel" :rules="createRules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
</div>
@ -109,6 +113,10 @@ export default {
const form = {
labelWidth: '150px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
@ -271,7 +279,11 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
.coordinate {
overflow: hidden;

View File

@ -1,7 +1,7 @@
<template>
<el-form ref="form" :label-width="form.labelWidth" size="mini" :rules="rules" :model="formModel">
<el-form ref="form" :label-width="form.labelWidth" size="mini" :rules="rules" :model="formModel" class="form_data">
<template v-for="(items, index) in form.items">
<div v-if="items.item.length" :key="index" class="card">
<div v-if="items.item.length" :key="index" class="card" :class="{'card_code' : !items.name}">
<div class="card_title">{{ items.name }}</div>
<template v-for="item in items.item">
<template v-if="checkFieldType(item, 'select')">
@ -305,14 +305,16 @@ export default {
width: 110px;
}
.el-form{
.form_data{
padding: 10px;
padding-bottom: 0;
padding-top: 6px;
padding-bottom: 10px;
}
.card{
border: 1px solid #ccc;
padding: 10px;
padding-top: 18px;
box-sizing: border-box;
position: relative;
margin-bottom: 15px;
@ -329,6 +331,10 @@ export default {
padding: 0px 5px;
}
}
.card_code{
border: 0px solid #ccc;
padding: 0px;
}
/deep/ {
.input-with-select .el-input-group__prepend {
background-color: #fff;

View File

@ -1,14 +1,16 @@
<template>
<div>
<el-tabs v-model="activeName">
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="form" :form="form" :form-model="editModel" :rules="rules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
@ -35,9 +37,11 @@
</el-form-item>
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
</div>
@ -135,6 +139,10 @@ export default {
const form = {
labelWidth: '120px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
@ -269,4 +277,9 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
</style>

View File

@ -1,14 +1,16 @@
<template>
<div>
<el-tabs v-model="activeName">
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="form" :form="form" :form-model="editModel" :rules="editRules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
@ -25,9 +27,11 @@
</el-form-item>
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
</div>
@ -117,6 +121,10 @@ export default {
const form = {
labelWidth: '120px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
@ -250,4 +258,9 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
</style>

View File

@ -329,7 +329,7 @@ export default {
},
resizeCardHeight() {
var padding = 0;
this.cardHeights = this.cardHeight - padding - 90;
this.cardHeights = this.cardHeight - padding - 74;
},
handleSelectControlPage(device) {
const type = device._type;
@ -394,7 +394,7 @@ export default {
/deep/ .map-draft-group {
float: right;
margin: 10px 5px;
margin: 6px 5px;
}
/deep/ .view-control {
@ -405,6 +405,19 @@ export default {
.mapEdit .el-tabs__nav-wrap.is-scrollable {
padding: 0 20px;
}
.mapEdit .el-tabs__header .el-tabs__item.is-active {
border-bottom-color: #f5f7fa;
background: #f5f7fa;
}
.mapEdit .el-tabs__active-bar{
background: transparent;
}
.card .el-tabs__nav .el-tabs__item.is-active {
border-bottom: 2px solid #E4E7ED;
background: #409eff;
color: #fff;
}
.mapEdit .el-tabs__nav-prev {
width: 20px;

View File

@ -1,14 +1,16 @@
<template>
<div>
<el-tabs v-model="activeName">
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="form" :form="form" :form-model="editModel" :rules="rules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
@ -37,9 +39,11 @@
</div>
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
</div>
@ -127,6 +131,10 @@ export default {
const form = {
labelWidth: '150px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
@ -240,7 +248,11 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
.coordinate {
overflow: hidden;

View File

@ -1,22 +1,26 @@
<template>
<div>
<el-tabs v-model="activeName">
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="form" :form="form" :form-model="editModel" :rules="rules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-data ref="make" :form="formMake" :form-model="addModel" :rules="createRules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
</div>
@ -93,6 +97,10 @@ export default {
const form = {
labelWidth: '150px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
@ -231,7 +239,11 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
.coordinate {
overflow: hidden;

View File

@ -1,13 +1,13 @@
<template>
<div>
<el-tabs v-model="activeName">
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="form" :form="form" :form-model="editModel" :rules="rules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
@ -69,7 +69,7 @@
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="create">{{ $t('map.create') }}</el-button>
<el-button type="primary" size="small" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
</el-tab-pane>
</el-tabs>
@ -150,6 +150,10 @@ export default {
const form = {
labelWidth: '120px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
@ -276,7 +280,11 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
.view-control {
overflow-y: auto;
}

View File

@ -1,14 +1,16 @@
<template>
<div>
<el-tabs v-model="activeName">
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="dataform" :form="form" :form-model="editModel" :rules="rules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
@ -36,11 +38,13 @@
</template>
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button v-if="isNew" type="primary" @click="isNewCreate">{{ $t('map.create') }}</el-button>
<el-button v-if="isFd" type="primary" @click="isFdCreate">{{ $t('map.create') }}</el-button>
<el-button v-if="isSd" type="primary" @click="isSdCreate">{{ $t('map.create') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button v-if="isNew" type="primary" size="small" @click="isNewCreate">{{ $t('map.create') }}</el-button>
<el-button v-if="isFd" type="primary" size="small" @click="isFdCreate">{{ $t('map.create') }}</el-button>
<el-button v-if="isSd" type="primary" size="small" @click="isSdCreate">{{ $t('map.create') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
</div>
@ -157,6 +161,10 @@ export default {
const form = {
labelWidth: '130px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
@ -568,6 +576,12 @@ export default {
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
.coordinate {
overflow: hidden;

View File

@ -1,14 +1,16 @@
<template>
<div>
<el-tabs v-model="activeName" @tab-click="handleClick">
<el-tabs v-model="activeName" class="card" @tab-click="handleClick">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="dataform" :form="form" :form-model="editModel" :rules="rules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.create')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
@ -25,9 +27,11 @@
</el-form-item>
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.splitMerge')" name="three">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight+60+'px' }">
@ -43,6 +47,7 @@
</el-select>
<el-button
:type="field === 'splitSection' ? 'danger' : 'primary'"
size="small"
@click="hover('splitSection')"
>{{ $t('map.activate') }}</el-button>
</el-form-item>
@ -67,6 +72,7 @@
</el-select>
<el-button
:type="field === 'leftSection' ? 'danger' : 'primary'"
size="small"
@click="hover('leftSection')"
>{{ $t('map.activate') }}</el-button>
</el-form-item>
@ -81,6 +87,7 @@
</el-select>
<el-button
:type="field === 'rightSection' ? 'danger' : 'primary'"
size="small"
@click="hover('rightSection')"
>{{ $t('map.activate') }}</el-button>
</el-form-item>
@ -113,9 +120,11 @@
</el-table-column>
</el-table>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="editSectionNum">{{ $t('map.updateObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="editSectionNum">{{ $t('map.updateObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.switchSection')" name="five">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight+60+'px' }">
@ -145,9 +154,11 @@
</el-form-item>
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="editSectionTrain">{{ $t('map.updateObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="editSectionTrain">{{ $t('map.updateObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
</div>
@ -284,13 +295,17 @@ export default {
const form = {
labelWidth: '160px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
{ prop: 'code', label: this.$t('map.blockCoding'), type: 'select', mode: false, optionLabel: 'name&&code', optionValue: 'code', options: this.sectionList, change: true, deviceChange: this.deviceChange },
{ prop: 'name', label: this.$t('map.sectionNameColon'), type: 'input' },
{ prop: 'stationCode', label: this.$t('map.equipmentStation'), type: 'select', mode: true, optionLabel: 'name&&code', optionValue: 'code', disabled: this.isStationCodeDisabled, options: this.stationList },
{ prop: 'parentCode', label: this.$t('map.associatedSection'), type: 'select', mode: true, optionLabel: 'code&&name', optionValue: 'code', disabled: true, options: this.sectionList, isHidden: !this.isParentCode },
{ prop: 'code', label: this.$t('map.blockCoding'), type: 'select', mode: false, optionLabel: 'code&&name', optionValue: 'code', options: this.sectionList, change: true, deviceChange: this.deviceChange },
{ prop: 'name', label: this.$t('map.sectionNameColon'), type: 'input' },
{ prop: 'namePoint', label: this.$t('map.sectionNameOffset'), type: 'coordinate', width: '150px', children: [
{ prop: 'namePoint.x', firstLevel: 'namePoint', secondLevel: 'x', label: 'x:', type: 'number', labelWidth: '20px' },
{ prop: 'namePoint.y', firstLevel: 'namePoint', secondLevel: 'y', label: 'y:', type: 'number', labelWidth: '20px' }
@ -1360,7 +1375,11 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
.el-transfer {
text-align: left;
}

View File

@ -1,13 +1,15 @@
<template>
<el-tabs v-model="activeName">
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="dataform" :form="form" :form-model="editModel" :rules="rules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
@ -54,9 +56,11 @@
</el-form-item>
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
</template>
@ -197,12 +201,16 @@ export default {
const form = {
labelWidth: '150px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
{ prop: 'stationCode', label: this.$t('map.equipmentStation'), type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.stationList },
{ prop: 'code', label: this.$t('map.signalCodeColon'), type: 'select', optionLabel: 'code&&name', optionValue: 'code', options: this.signalList, change: true, deviceChange: this.deviceChange },
{ prop: 'code', label: this.$t('map.signalCodeColon'), type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.signalList, change: true, deviceChange: this.deviceChange },
{ prop: 'name', label: this.$t('map.signalNameColon'), type: 'input' },
{ prop: 'stationCode', label: this.$t('map.equipmentStation'), type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.stationList },
{ prop: 'nameShow', label: this.$t('map.signalDisplayName'), type: 'checkbox' },
{ prop: 'lampPostType', label: this.$t('map.lampPostType'), type: 'select', optionLabel: 'name', optionValue: 'code', options: this.SignalLampPostTypeList },
{ prop: 'lampPositionType', label: this.$t('map.lampPositionType'), type: 'select', optionLabel: 'name', optionValue: 'code', options: this.SignalLampPositionTypeList },
@ -269,7 +277,7 @@ export default {
{ required: true, message: this.$t('rules.signalGuidePositionX'), trigger: 'blur' }
],
'guidePosition.y': [
{ required: true, message: this.$t('rules,signalGuidePositionY'), trigger: 'blur' }
{ required: true, message: this.$t('rules.signalGuidePositionY'), trigger: 'blur' }
]
};
//
@ -508,4 +516,9 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
</style>

View File

@ -1,14 +1,16 @@
<template>
<div>
<el-tabs v-model="activeName">
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="dataform" :form="form" :form-model="editModel" :rules="rules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
@ -25,9 +27,11 @@
</el-form-item>
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
</div>
@ -101,12 +105,16 @@ export default {
const form = {
labelWidth: '150px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
{ prop: 'concentrateStationCode', label: this.$t('map.concentrateStationCode'), type: 'select', optionLabel: 'code&&name', optionValue: 'code', options: this.stationList },
{ prop: 'code', label: this.$t('map.stationCode'), type: 'select', optionLabel: 'code&&name', optionValue: 'code', options: this.stationList, change: true, deviceChange: this.deviceChange },
{ prop: 'code', label: this.$t('map.stationCode'), type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.stationList, change: true, deviceChange: this.deviceChange },
{ prop: 'name', label: this.$t('map.stationName'), type: 'input' },
{ prop: 'concentrateStationCode', label: this.$t('map.concentrateStationCode'), type: 'select', optionLabel: 'code&&name', optionValue: 'code', options: this.stationList },
{ prop: 'visible', label: this.$t('map.stationVisible'), type: 'checkbox' },
{ prop: 'nameFont', label: this.$t('map.stationNameFont'), type: 'font', placeholder: this.$t('tip.stationFont') },
{ prop: 'nameFontColor', label: this.$t('map.stationNameFontColor'), type: 'color' },
@ -317,4 +325,9 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
</style>

View File

@ -1,14 +1,16 @@
<template>
<div>
<el-tabs v-model="activeName">
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="dataform" :form="form" :form-model="editModel" :rules="rules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
@ -25,9 +27,11 @@
</el-form-item>
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
</div>
@ -92,12 +96,16 @@ export default {
const form = {
labelWidth: '160px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
{ prop: 'stationCode', label: this.$t('map.equipmentStation'), type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.stationList },
{ prop: 'code', label: this.$t('map.stationControlCode'), type: 'select', optionLabel: 'code', optionValue: 'code', options: this.stationControlList, change: true, deviceChange: this.deviceChange },
{ prop: 'name', label: this.$t('map.stationControlName'), type: 'input' },
{ prop: 'stationCode', label: this.$t('map.equipmentStation'), type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.stationList },
{ prop: 'zokContent', label: this.$t('map.zokContent'), type: 'input' },
{ prop: 'zakContent', label: this.$t('map.zakContent'), type: 'input' },
{ prop: 'jjzkContent', label: this.$t('map.jjzkContent'), type: 'input' },
@ -272,4 +280,9 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
</style>

View File

@ -1,14 +1,16 @@
<template>
<div>
<el-tabs v-model="activeName">
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="dataform" :form="form" :form-model="editModel" :rules="rules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
@ -48,9 +50,11 @@
</el-form-item>
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
</div>
@ -122,12 +126,16 @@ export default {
const form = {
labelWidth: '130px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
{ prop: 'deviceStationCode', label: this.$t('map.equipmentStation'), type: 'select', optionLabel: 'name', optionValue: 'code', options: this.stationList },
{ prop: 'code', label: this.$t('map.relStandCode'), type: 'select', optionLabel: 'code&&name', optionValue: 'code', options: this.stationStandList, change: true, deviceChange: this.deviceChange },
{ prop: 'code', label: this.$t('map.relStandCode'), type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.stationStandList, change: true, deviceChange: this.deviceChange },
{ prop: 'name', label: this.$t('map.stationstandNameColon'), type: 'input', disabled: true },
{ prop: 'deviceStationCode', label: this.$t('map.equipmentStation'), type: 'select', optionLabel: 'name', optionValue: 'code', options: this.stationList },
{ prop: 'direction', label: this.$t('map.stationstandTopBottom'), type: 'select', optionLabel: 'name', optionValue: 'code', options: this.RunDirectionTypeList },
{ prop: 'visible', label: this.$t('map.stationVisible'), type: 'checkbox' },
{ prop: 'nameShow', label: this.$t('map.stationstandShowName'), type: 'checkbox' },
@ -176,10 +184,10 @@ export default {
{ required: true, message: this.$t('rules.stationstandHeight'), trigger: 'change' }
],
'position.x': [
{ required: true, message: this.$t('rule.stationstandPositionX'), trigger: 'change' }
{ required: true, message: this.$t('rules.trainPositionX'), trigger: 'change' }
],
'position.y': [
{ required: true, message: this.$t('rule.stationstandPositionY'), trigger: 'change' }
{ required: true, message: this.$t('rules.trainPositionY'), trigger: 'change' }
]
};
//
@ -334,4 +342,9 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
</style>

View File

@ -1,14 +1,16 @@
<template>
<div>
<el-tabs v-model="activeName">
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="dataform" :form="form" :form-model="editModel" :rules="rules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
@ -25,9 +27,11 @@
</el-form-item>
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
</div>
@ -97,12 +101,16 @@ export default {
const form = {
labelWidth: '170px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
{ prop: 'stationCode', label: this.$t('map.equipmentStation'), type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.stationList },
{ prop: 'code', label: this.$t('map.switchCode'), type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.switchList, change: true, deviceChange: this.deviceChange },
{ prop: 'name', label: this.$t('map.switchName'), type: 'input' },
{ prop: 'stationCode', label: this.$t('map.equipmentStation'), type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.stationList },
{ prop: 'nameShow', label: this.$t('map.switchShowName'), type: 'checkbox' },
{ prop: 'namePoint.x', firstLevel: 'namePoint', secondLevel: 'x', label: this.$t('map.switchPositionX'), type: 'number', placeholder: 'px' },
{ prop: 'namePoint.y', firstLevel: 'namePoint', secondLevel: 'y', label: this.$t('map.switchPositionY'), type: 'number', placeholder: 'px' },
@ -412,7 +420,11 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
.el-transfer {
text-align: left;
}

View File

@ -1,14 +1,16 @@
<template>
<div>
<el-tabs v-model="activeName">
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="form" :form="form" :form-model="editModel" :rules="rules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
@ -29,9 +31,11 @@
</el-form-item>
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
</div>
@ -116,6 +120,10 @@ export default {
const form = {
labelWidth: '130px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
@ -234,7 +242,11 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
/deep/ {
.el-select .el-input {
width: 130px;

View File

@ -1,299 +0,0 @@
<template>
<div>
<el-tabs v-model="activeName">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<el-form ref="form" :model="editModel" label-width="110px" size="mini" :rules="rules">
<el-form-item :label="$t('map.trainCode')" prop="code">
<el-select v-model="editModel.code" filterable @change="deviceChange">
<el-option
v-for="item in trainList"
:key="item.code"
:label="item.code"
:value="item.code"
/>
</el-select>
</el-form-item>
<el-form-item :label="$t('map.groupNumber')" prop="groupNumber">
<el-input v-model="editModel.groupNumber" />
</el-form-item>
<el-form-item :label="$t('map.modelCode')" prop="modelCode">
<el-select v-model="editModel.modelCode" filterable>
<el-option
v-for="item in trainModelList"
:key="item.code"
:label="item.name"
:value="item.code"
/>
</el-select>
<el-button-group>
<el-button type="primary" size="small" @click="newTrainMode">{{ $t('map.add') }}</el-button>
<el-button type="primary" size="small" @click="uptTrainMode(editModel.modelCode)">{{ $t('map.updata') }}
</el-button>
<el-button type="primary" size="small" @click="delTrainMode(editModel.modelCode)">{{ $t('map.deleteObj') }}
</el-button>
</el-button-group>
</el-form-item>
<el-form-item :label="$t('map.pointX')" prop="position.x">
<el-input-number v-model="editModel.position.x" />
</el-form-item>
<el-form-item :label="$t('map.pointY')" prop="position.y">
<el-input-number v-model="editModel.position.y" />
</el-form-item>
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<el-form ref="make" label-width="100px" :rules="createRules" :model="addModel" size="mini">
<el-form-item :label="$t('map.groupNumber')" prop="groupNumber">
<el-input v-model="addModel.groupNumber" />
</el-form-item>
<el-form-item :label="$t('map.modelCode')" prop="modelCode">
<el-select v-model="addModel.modelCode" filterable>
<el-option
v-for="item in trainModelList"
:key="item.code"
:label="item.name"
:value="item.code"
/>
</el-select>
<el-button-group>
<el-button type="primary" size="small" @click="newTrainMode">{{ $t('map.add') }}</el-button>
<el-button type="primary" size="small" @click="uptTrainMode(addModel.modelCode)">{{ $t('map.updata') }}
</el-button>
<el-button type="primary" size="small" @click="delTrainMode(addModel.modelCode)">{{ $t('map.deleteObj') }}
</el-button>
</el-button-group>
</el-form-item>
<el-form-item :label="$t('map.pointX')" prop="position.x">
<el-input-number v-model="addModel.position.x" />
</el-form-item>
<el-form-item :label="$t('map.pointY')" prop="position.y">
<el-input-number v-model="addModel.position.y" />
</el-form-item>
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
</el-tab-pane>
</el-tabs>
<train-model ref="trainMode" />
</div>
</template>
<script>
import { mapGetters } from 'vuex';
import { getUID } from '@/jmap/utils/Uid';
import TrainModel from './trainmodel';
export default {
name: 'TrainDraft',
components: {
TrainModel
},
props: {
selected: {
type: Object,
default: function () {
return null;
}
},
cardHeight: {
type: [String, Number],
required: true
}
},
data() {
return {
activeName: 'first',
mapData: null,
editModel: {
code: '',
groupNumber: '',
modelCode: '',
position: {
x: 0,
y: 0
}
},
addModel: {
modelCode: '',
groupNumber: '',
position: {
x: 0,
y: 0
}
},
rules: {
code: [
{ required: true, message: this.$t('rules.pleaseReSelectDevice'), trigger: 'change' }
],
groupNumber: [
{ required: true, message: this.$t('rules.pleaseEnterGroupNumber'), trigger: 'blur' }
],
modelCode: [
{ required: true, message: this.$t('rules.selectTrainType'), trigger: 'change' }
],
'position.x': [
{ required: true, message: this.$t('rules.trainPositionX'), trigger: 'blur' }
],
'position.y': [
{ required: true, message: this.$t('rules.trainPositionY'), trigger: 'blur' }
]
}
};
},
computed: {
...mapGetters('map', [
'sectionList',
'trainList',
'trainModelList',
'skinCode'
]),
createRules: function () {
return {
modelCode: [
{ required: true, message: this.$t('rules.selectTrainType'), trigger: 'change' }
],
groupNumber: [
{ required: true, message: this.$t('rules.pleaseEnterTrainNumber'), trigger: 'blur' }
],
'position.x': [
{ required: true, message: this.$t('rules.trainPositionX'), trigger: 'change' }
],
'position.y': [
{ required: true, message: this.$t('rules.trainPositionY'), trigger: 'change' }
]
};
}
},
watch: {
selected: function (val, oldVal) {
this.deviceSelect(val);
},
$route() {
this.$nextTick(() => {
this.$refs.form.resetFields();
this.activeName = 'first';
});
}
},
methods: {
deviceChange(code) {
this.$emit('setCenter', code);
this.deviceSelect(this.$store.getters['map/getDeviceByCode'](code));
},
deviceSelect(selected) {
this.$refs.form.resetFields();
this.$refs.make.resetFields();
if (selected && selected._type.toUpperCase() === 'Train'.toUpperCase()) {
this.editModel.code = selected.code;
this.editModel.modelCode = selected.modelCode;
this.editModel.groupNumber = selected.groupNumber;
this.editModel.position = {
x: selected.position.x,
y: selected.position.y
};
this.activeName = 'first';
} else {
this.activeName = 'second';
}
},
create() {
this.$refs.make.validate((valid) => {
if (valid) {
const uid = getUID('Train');
const model = {
_type: 'Train',
code: uid,
safeDistance: '100',
maxSafeDistance: '100',
modelCode: this.addModel.modelCode,
groupNumber: this.addModel.groupNumber,
position: {
x: this.addModel.position.x,
y: this.addModel.position.y
}
};
this.$emit('addOrUpdateMapModel', model);
}
});
},
//
edit() {
this.$refs['form'].validate((valid) => {
if (valid) {
this.$emit('addOrUpdateMapModel', this.buildEditModel());
}
});
},
buildEditModel() {
const model = {
_type: 'Train',
code: this.editModel.code,
safeDistance: this.editModel.safeDistance,
maxSafeDistance: this.editModel.maxSafeDistance,
modelCode: this.editModel.modelCode,
groupNumber: this.editModel.groupNumber,
position: {
x: this.editModel.position.x,
y: this.editModel.position.y
}
};
return model;
},
//
deleteObj() {
const selected = this.$store.getters['map/getDeviceByCode'](this.editModel.code);
if (selected && selected._type.toUpperCase() === 'Train'.toUpperCase()) {
const _that = this;
this.$confirm(this.$t('tip.confirmDeletion'), this.$t('tip.hint'), {
confirmButtonText: this.$t('tip.confirm'),
cancelButtonText: this.$t('tip.cancel'),
type: 'warning'
}).then(() => {
_that.$emit('delMapModel', selected);
_that.deviceSelect();
}).catch(() => {
_that.$message.info(this.$t('tip.cancelledDelete'));
});
}
},
newTrainMode() {
if (Object.keys(this.$store.state.map.map || {}).length) {
this.$refs.trainMode.doShow({}, 'ADD');
} else {
this.$messageBox(this.$t('tip.selectMap'));
}
},
uptTrainMode(code) {
if (code) {
this.trainModelList.forEach(elem => {
if (elem.code === code) {
this.$refs.trainMode.doShow(elem, 'UPT');
return;
}
});
} else {
this.$messageBox(this.$t('tip.selectTrainType'));
}
},
delTrainMode(code) {
if (code) {
const model = { code };
this.$refs.trainMode.operateTrainModel({ model, type: 'DEL' });
this.addModel.modelCode = this.editModel.modelCode = '';
}
}
}
};
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
</style>

View File

@ -1,63 +1,26 @@
<template>
<div>
<el-tabs v-model="activeName">
<!-- <el-tab-pane class="view-control" label="属性" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<el-form ref="form" :model="editModel" label-width="110px" size="mini" :rules="rules">
<el-form-item label="列车编号:" prop="code">
<el-select v-model="editModel.code" filterable @change="deviceChange">
<el-option
v-for="item in trainList"
:key="item.code"
:label="item.code"
:value="item.code"
/>
</el-select>
</el-form-item>
<el-form-item label="车组号:" prop="groupNumber">
<el-input v-model="editModel.groupNumber" />
</el-form-item>
<el-form-item label="车类型:" prop="modelCode">
<el-select v-model="editModel.modelCode" filterable>
<el-option
v-for="item in trainModelList"
:key="item.code"
:label="item.name"
:value="item.code"
/>
</el-select>
<el-button-group>
<el-button type="primary" size="small" @click="newTrainMode">添加</el-button>
<el-button type="primary" size="small" @click="uptTrainMode(editModel.modelCode)">更新
</el-button>
<el-button type="primary" size="small" @click="delTrainMode(editModel.modelCode)">删除
</el-button>
</el-button-group>
</el-form-item>
</el-form>
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">修改</el-button>
<el-button type="primary" @click="deleteObj">删除</el-button>
</el-button-group>
</el-tab-pane> -->
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" label="操作" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<el-table :data="trainList.filter(data => !search || data.groupNumber.toLowerCase().includes(search.toLowerCase()))" style="width: 100%">
<el-table-column label="车组号" prop="groupNumber" />
<el-table-column label="编码" prop="code" />
<el-table-column align="right">
<template slot="header" slot-scope="scope">
<template slot="header">
<el-input v-model="search" size="mini" placeholder="输入关键字搜索" />
</template>
<template slot-scope="scope">
<el-button size="mini" type="danger" @click="handleDelete(scope.$index, scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table></el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="handleCreate">创建</el-button>
</el-button-group>
</el-table>
</el-scrollbar>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="handleCreate">创建</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
<train-model ref="trainMode" />
@ -214,4 +177,9 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
</style>

View File

@ -1,186 +0,0 @@
<template>
<el-dialog :title="isNew? $t('map.trainmodelCreate'): $t('map.trainmodelUpdate')" :visible.sync="dialogShow" width="30%" :before-close="doClose">
<el-card shadow="never">
<el-form
ref="form"
:model="formModel"
:rules="rules"
label-width="120px"
size="mini"
style="margin: 20px 20px;"
>
<el-input v-model="formModel.code" :disabled="!isNew" type="hidden" />
<el-form-item :label="$t('map.trainTypeName')" prop="name">
<el-input v-model="formModel.name" :disabled="!isNew" />
</el-form-item>
<el-form-item :label="$t('map.trainLength')" prop="length">
<el-input-number v-model="formModel.length" :min="0" />
</el-form-item>
<el-form-item :label="$t('map.trainSafeDistance')" prop="safeDistance">
<el-input-number v-model="formModel.safeDistance" :min="0" />
</el-form-item>
<el-form-item :label="$t('map.trainMaxSafeDistance')" prop="maxSafeDistance">
<el-input-number v-model="formModel.maxSafeDistance" :min="0" />
</el-form-item>
<el-form-item :label="$t('map.averageVelocity')" prop="averageVelocity">
<el-input-number v-model="formModel.averageVelocity" :min="0" />km/h
</el-form-item>
<el-form-item :label="$t('map.averageDeceleration')" prop="averageDeceleration">
<el-input-number v-model="formModel.averageDeceleration" :min="0" />km/h
</el-form-item>
<el-form-item :label="$t('map.defaultVelocity')" prop="defaultVelocity">
<el-input-number v-model="formModel.defaultVelocity" :min="0" />km/h
</el-form-item>
<el-form-item :label="$t('map.maxVelocity')" prop="maxVelocity">
<el-input-number v-model="formModel.maxVelocity" :min="0" />km/h
</el-form-item>
</el-form>
</el-card>
<span slot="footer" class="dialog-footer">
<el-button type="primary" @click="handleSure">{{ isNew? $t('map.create'): $t('map.updata') }}</el-button>
<el-button @click="dialogShow = false">{{ $t('map.cancel') }}</el-button>
</span>
</el-dialog>
</template>
<script>
import { getUID } from '@/jmap/utils/Uid';
export default {
name: 'TrainModeOperate',
data() {
return {
dialogShow: false,
loading: false,
rules: null,
mapList: [],
formModel: {
code: '',
name: '',
length: 0,
safeDistance: '',
maxSafeDistance: '',
averageVelocity: 0,
averageDeceleration: 0,
defaultVelocity: 0,
maxVelocity: 0
},
type: ''
};
},
computed: {
addRules: function () {
return {
code: [
{ required: true, message: this.$t('rules.trainCode'), trigger: 'change' }
],
name: [
{ required: true, message: this.$t('rules.pleaseEnterTrainTypeName'), trigger: 'change' }
],
length: [
{ required: true, message: this.$t('rules.trainLength'), trigger: 'change' }
],
safeDistance: [
{ required: true, message: this.$t('rules.safeDistance'), trigger: 'change' }
],
maxSafeDistance: [
{ required: true, message: this.$t('rules.maxSafeDistance'), trigger: 'change' }
],
averageVelocity: [
{ required: true, message: this.$t('rules.averageVelocity'), trigger: 'change' }
],
averageDeceleration: [
{ required: true, message: this.$t('rules.averageDeceleration'), trigger: 'change' }
],
defaultVelocity: [
{ required: true, message: this.$t('rules.defaultVelocity'), trigger: 'change' }
],
maxVelocity: [
{ required: true, message: this.$t('rules.maxVelocity'), trigger: 'change' }
]
};
},
viewRules() {
return {};
},
isNew() {
return this.type == 'ADD';
},
isUpt() {
return this.type == 'UPT';
},
isDel() {
return this.type == 'DEL';
}
},
methods: {
doShow(model, type) {
this.type = type;
this.dialogShow = true;
this.$nextTick(() => {
if (this.$refs && this.$refs.form) {
this.$refs.form.resetFields();
}
if (type !== 'ADD') {
if (model) {
this.formModel.code = model.code;
this.formModel.name = model.name;
this.formModel.length = model.length;
this.formModel.safeDistance = model.safeDistance;
this.formModel.maxSafeDistance = model.maxSafeDistance;
this.formModel.averageVelocity = model.averageVelocity;
this.formModel.averageDeceleration = model.averageDeceleration;
this.formModel.defaultVelocity = model.defaultVelocity;
this.formModel.maxVelocity = model.maxVelocity;
}
this.rules = this.viewRules;
} else {
this.rules = this.addRules;
}
this.$nextTick(() => {
this.$refs.form.clearValidate();
});
});
},
doClose() {
this.dialogShow = false;
},
handleSure() {
this.$refs.form.validate((valid) => {
if (valid) {
if (this.isNew) {
this.formModel.code = getUID('TrainModel');
this.operateTrainModel({ model: this.formModel, type: 'ADD' });
} else if (this.isUpt) {
this.operateTrainModel({ model: this.formModel, type: 'UPT' });
} else if (this.isDel) {
this.operateTrainModel({ model: this.formModel, type: 'DEL'});
}
this.doClose();
}
});
},
operateTrainModel({ model, type }) {
this.$store.dispatch('map/operateTrainModel', { model, type });
}
}
};
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.create-box {
width: 800px;
margin: 0 auto;
padding-top: 20px;
height: 100%;
/deep/ {
.el-step__icon.is-icon {
width: 95px;
}
}
}
</style>

View File

@ -1,14 +1,16 @@
<template>
<div>
<el-tabs v-model="activeName">
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="form" :form="form" :form-model="editModel" :rules="rules" />
</el-scrollbar>
<el-button-group class="map-draft">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
@ -28,9 +30,11 @@
:titles="['Section集合', '选择Section']"
/>
</el-scrollbar>
<el-button-group class="map-draft">
<el-button type="primary" @click="createTrainWindowByCollection">{{ $t('map.create') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="createTrainWindowByCollection">{{ $t('map.create') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
</div>
@ -126,6 +130,10 @@ export default {
const form = {
labelWidth: '120px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
@ -364,4 +372,9 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
</style>

View File

@ -1,22 +1,26 @@
<template>
<div>
<el-tabs v-model="activeName">
<el-tabs v-model="activeName" class="card">
<el-tab-pane class="view-control" :label="$t('map.property')" name="first">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-list ref="dataform" :form="form" :form-model="editModel" :rules="rules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="primary" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="edit">{{ $t('map.updateObj') }}</el-button>
<el-button type="danger" size="small" @click="deleteObj">{{ $t('map.deleteObj') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
<el-tab-pane class="view-control" :label="$t('map.operation')" name="second">
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
<config-data ref="make" :form="formMake" :form-model="addModel" :rules="createRules" />
</el-scrollbar>
<el-button-group class="map-draft-group">
<el-button type="primary" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
<div class="button_box">
<el-button-group class="map-draft-group">
<el-button type="primary" size="small" @click="create">{{ $t('map.create') }}</el-button>
</el-button-group>
</div>
</el-tab-pane>
</el-tabs>
</div>
@ -98,10 +102,14 @@ export default {
const form = {
labelWidth: '150px',
items: {
code: {
name: '',
item: []
},
draw: {
name: this.$t('map.drawData'),
item: [
{ prop: 'code', label: this.$t('map.code'), type: 'select', optionLabel: 'code', optionValue: 'code', options: this.zcList, change: true, deviceChange: this.deviceChange },
{ prop: 'code', label: this.$t('map.code'), type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.zcList, change: true, deviceChange: this.deviceChange },
{ prop: 'name', label: this.$t('map.statusSignalName'), type: 'input' },
{ prop: 'visible', label: this.$t('map.showZc'), type: 'checkboxx' },
{ prop: 'position', label: this.$t('map.stateSignalsPlotCoordinates'), type: 'coordinate', width: '140px', children: [
@ -241,7 +249,11 @@ export default {
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss";
.button_box{
width: 100%;
background: #f0f0f0;
overflow: hidden;
}
.coordinate {
overflow: hidden;