This commit is contained in:
joylink_cuiweidong 2020-04-10 10:42:19 +08:00
commit 9e45a0d342
11 changed files with 350 additions and 317 deletions

View File

@ -148,8 +148,8 @@
<el-button v-if="queryForm.reset" type="primary" size="small" :disabled="!canQuery" @click="doClean">{{ $t('global.reset') }}</el-button> <el-button v-if="queryForm.reset" type="primary" size="small" :disabled="!canQuery" @click="doClean">{{ $t('global.reset') }}</el-button>
<el-button v-if="exportFlag" type="primary" size="small" :disabled="!canQuery" @click="doExport">{{ $t('global.export') }}</el-button> <el-button v-if="exportFlag" type="primary" size="small" :disabled="!canQuery" @click="doExport">{{ $t('global.export') }}</el-button>
<template v-for="(button, index) in queryList.actions"> <template v-for="(button, index) in queryList.actions">
<el-button v-if="button.fileType==='file'" :key="index" :type="button.type ? button.type: 'primary'" size="small" class="button_style" :disabled="button.disabled" :loading="button.disabled"> <el-button v-if="button.fileType==='file' && (button.hasOwnProperty('show') ? button.show: true)" :key="index" :type="button.type ? button.type: 'primary'" size="small" class="button_style uploadDemo" :disabled="button.disabled" :loading="button.disabled">
<input ref="files" type="file" class="file_box" accept=".json, application/json" @change="button.handler"> <input id="queryFormFilesInput" type="file" class="file_box" accept=".json, application/json" @change="button.handler">
{{ $t('map.importMap') }} {{ $t('map.importMap') }}
</el-button> </el-button>
<el-button <el-button
@ -522,14 +522,33 @@ export default {
margin-right:10px; margin-right:10px;
margin-left: 0; margin-left: 0;
margin-bottom: 10px; margin-bottom: 10px;
}
.uploadDemo {
position: relative;
overflow: hidden;
margin-right: 3px;
cursor: pointer;
/*width: 60px;*/
padding: 0 15px;
height: 32px;
/*input {*/
/*width: 100%;*/
/*height: 100%;*/
/*position: relative;*/
/*left: 0;*/
/*top: 0;*/
/*opacity: 0;*/
/*cursor: pointer;*/
/*}*/
} }
.file_box { .file_box {
width: 50px; width: 100%;
height: 30px; height: 100%;
position: absolute; position: absolute;
left: 0; left: 0;
top: 0; top: 0;
opacity: 0; opacity: 0;
cursor: pointer; cursor: pointer;
z-index: 100;
} }
</style> </style>

View File

@ -18,7 +18,7 @@
<!-- <el-button class="expand" @click="expandPath">展开进路预览</el-button> --> <!-- <el-button class="expand" @click="expandPath">展开进路预览</el-button> -->
</el-col> </el-col>
</el-row> </el-row>
<el-table ref="table" :data="tempData" border :cell-style="tableStyle" style="width: 100%; margin-top:10px" size="mini" height="120" highlight-current-row :show-header="false" @row-click="clickEvent"> <el-table ref="table" :data="tempData" border :cell-style="tableStyle" style="width: 100%; height: 120px; margin-top:10px" size="mini" highlight-current-row :show-header="false" @row-click="clickEvent">
<el-table-column :id="domIdChoose" prop="name" style="margin-left:30px" /> <el-table-column :id="domIdChoose" prop="name" style="margin-left:30px" />
</el-table> </el-table>
<el-row justify="center" class="button-group"> <el-row justify="center" class="button-group">

View File

@ -293,10 +293,10 @@ export default {
if (valid) { if (valid) {
this.doClose(); this.doClose();
} }
}).catch((error) => { }).catch(() => {
this.loading = false; this.loading = false;
this.doClose(); this.doClose();
this.$refs.noticeInfo.doShow({}, error.message); // this.$refs.noticeInfo.doShow({}, error.message);
}); });
} else { } else {
this.doClose(); this.doClose();

View File

@ -13,9 +13,9 @@
<menu-train ref="menuTrain" :selected="selected" /> <menu-train ref="menuTrain" :selected="selected" />
<menu-station ref="menuStation" :selected="selected" /> <menu-station ref="menuStation" :selected="selected" />
<menu-limit ref="menuLimit" :selected="selected" /> <menu-limit ref="menuLimit" :selected="selected" />
<passive-alarm ref="passiveAlarm" /> <!--<passive-alarm ref="passiveAlarm" />-->
<passive-contorl ref="passiveControl" /> <passive-contorl ref="passiveControl" />
<passive-Timeout ref="passiveTimeout" /> <!--<passive-Timeout ref="passiveTimeout" />-->
</template> </template>
</div> </div>
</template> </template>
@ -34,9 +34,9 @@ import MenuTrain from './menuTrain';
import MenuStation from './menuStation'; import MenuStation from './menuStation';
import MenuBar from './menuBar'; import MenuBar from './menuBar';
import MenuLimit from './menuLimit'; import MenuLimit from './menuLimit';
import PassiveAlarm from './passiveDialog/alarm'; // import PassiveAlarm from './passiveDialog/alarm';
import PassiveContorl from './passiveDialog/control'; import PassiveContorl from './passiveDialog/control';
import PassiveTimeout from './passiveDialog/timeout'; // import PassiveTimeout from './passiveDialog/timeout';
export default { export default {
name: 'Menus', name: 'Menus',
@ -53,9 +53,9 @@ export default {
MenuStation, MenuStation,
MenuTrain, MenuTrain,
MenuLimit, MenuLimit,
PassiveAlarm, // PassiveAlarm,
PassiveContorl, PassiveContorl
PassiveTimeout // PassiveTimeout
}, },
props: { props: {
selected: { selected: {
@ -113,7 +113,7 @@ export default {
.ningbo-01__systerm .el-dialog { .ningbo-01__systerm .el-dialog {
background: rgba(100, 100, 100, 0.3); background: rgba(100, 100, 100, 0.3);
border: 2px solid rgb(144, 144, 144, 0.8); border: 2px solid rgba(144, 144, 144, 0.8);
border-radius: 6px; border-radius: 6px;
color: #000; color: #000;
font-size: 14px; font-size: 14px;

View File

@ -1,40 +1,48 @@
<template> <template>
<el-dialog class="ningbo-01__systerm alarm-detail" :title="level+'级告警详细信息'" :visible.sync="show" width="760px" <el-dialog
:before-close="doClose" :zIndex="2000" :modal="false" :close-on-click-modal="false" v-dialogDrag> v-dialogDrag
class="ningbo-01__systerm alarm-detail"
:title="level+'级告警详细信息'"
:visible.sync="show"
width="760px"
:before-close="doClose"
:z-index="2000"
:modal="false"
:close-on-click-modal="false"
>
<el-form label-width="80px" size="mini"> <el-form label-width="80px" size="mini">
<el-row> <el-row>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="线路名称"> <el-form-item label="线路名称">
<el-input v-model="model.lineName" disabled></el-input> <el-input v-model="model.lineName" disabled />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="单位名称"> <el-form-item label="单位名称">
<el-input v-model="model.unitName" disabled></el-input> <el-input v-model="model.unitName" disabled />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="模块名称"> <el-form-item label="模块名称">
<el-input v-model="model.moduleName" disabled></el-input> <el-input v-model="model.moduleName" disabled />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<el-row> <el-row>
<el-col :span="9"> <el-col :span="9">
<el-form-item label="报警时间"> <el-form-item label="报警时间">
<el-date-picker v-model="model.alarmDate" type="datetime" placeholder="选择日期时间" disabled> <el-date-picker v-model="model.alarmDate" type="datetime" placeholder="选择日期时间" disabled />
</el-date-picker>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="7"> <el-col :span="7">
<el-form-item> <el-form-item>
<span slot="label">&emsp;</span> <span slot="label">&emsp;</span>
<el-input v-model="model.level" disabled></el-input> <el-input v-model="model.level" disabled />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="确认状态"> <el-form-item label="确认状态">
<el-input v-model="model.confirm" disabled></el-input> <el-input v-model="model.confirm" disabled />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -42,25 +50,24 @@
<el-col :span="9" class="alarm-type"> <el-col :span="9" class="alarm-type">
<el-form-item> <el-form-item>
<span slot="label">&emsp;&emsp;</span> <span slot="label">&emsp;&emsp;</span>
<el-input v-model="model.type" disabled></el-input> <el-input v-model="model.type" disabled />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="15" class="alarm-child-type"> <el-col :span="15" class="alarm-child-type">
<el-form-item label="子类型"> <el-form-item label="子类型">
<el-input v-model="model.childType" disabled></el-input> <el-input v-model="model.childType" disabled />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<el-form-item label="时间摘要"> <el-form-item label="时间摘要">
<el-input v-model="model.timeSummary" disabled></el-input> <el-input v-model="model.timeSummary" disabled />
</el-form-item> </el-form-item>
<el-form-item label="推荐操作"> <el-form-item label="推荐操作">
<el-input v-model="model.recommendedOperation" disabled></el-input> <el-input v-model="model.recommendedOperation" disabled />
</el-form-item> </el-form-item>
<div class="alarm-detail-description"> <div class="alarm-detail-description">
<span> 报警详细描述</span><br> <span> 报警详细描述</span><br>
<el-input type="textarea" :rows="5" placeholder="请输入内容" v-model="model.alarmDetail" disabled> <el-input v-model="model.alarmDetail" type="textarea" :rows="5" placeholder="请输入内容" disabled />
</el-input>
</div> </div>
</el-form> </el-form>
<el-row class="button-group"> <el-row class="button-group">
@ -68,17 +75,17 @@
<el-button :id="domIdCancel" type="primary" :loading="loading" @click="commit"> </el-button> <el-button :id="domIdCancel" type="primary" :loading="loading" @click="commit"> </el-button>
</el-col> </el-col>
<el-col :span="10"> <el-col :span="10">
<span style="line-height:26px">未确认{{level}}级报警数目1</span> <span style="line-height:26px">未确认{{ level }}级报警数目1</span>
</el-col> </el-col>
</el-row> </el-row>
</el-dialog> </el-dialog>
</template> </template>
<script> <script>
import { mapGetters } from 'vuex'; import { mapGetters } from 'vuex';
import { MapDeviceType, OperationEvent } from '@/scripts/ConstDic'; import { OperationEvent } from '@/scripts/ConstDic';
export default { export default {
name: 'AlarmDetail', name: 'AlarmDetail',
data() { data() {
return { return {
@ -103,40 +110,40 @@
recommendedOperation: '', recommendedOperation: '',
alarmDetail: '' alarmDetail: ''
} }
} };
}, },
computed: { computed: {
...mapGetters('map', [ ...mapGetters('map', [
'name', 'name'
]), ]),
show() { show() {
return this.dialogShow && !this.$store.state.menuOperation.break; return this.dialogShow && !this.$store.state.menuOperation.break;
}, },
domIdCancel() { domIdCancel() {
return this.dialogShow ? OperationEvent.Command.close.alarm.domId : ''; return this.dialogShow ? OperationEvent.Command.close.alarm.domId : '';
}, }
}, },
watch: { watch: {
'$store.state.socket.msgHead': function (elem) { '$store.state.socket.msgHead': function (elem) {
if (elem && elem.hasOwnProperty('success')) { if (elem && elem.hasOwnProperty('success')) {
if (elem.success) { if (elem.success) {
let operate = this.$store.state.training.operate; const operate = this.$store.state.training.operate;
let control = this.$store.getters['map/getDeviceByCode'](elem.stationControlCode); const control = this.$store.getters['map/getDeviceByCode'](elem.stationControlCode);
let station = this.$store.getters['map/getDeviceByCode'](control.stationCode); const station = this.$store.getters['map/getDeviceByCode'](control.stationCode);
let newOperate = { const newOperate = {
type: operate.type, type: operate.type,
name: station.name, name: station.name
} };
this.doShow(newOperate); this.doShow(newOperate);
} }
} }
}, }
}, },
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
this.$store.dispatch('training/tipReload'); this.$store.dispatch('training/tipReload');
}) });
}, },
methods: { methods: {
doShow(operate) { doShow(operate) {
@ -153,7 +160,7 @@
timeSummary: '控制模式摘要', timeSummary: '控制模式摘要',
recommendedOperation: '', recommendedOperation: '',
alarmDetail: `控制模式转换:${this.operate.name}由中控转为站控模式!` alarmDetail: `控制模式转换:${this.operate.name}由中控转为站控模式!`
} };
this.dialogShow = true; this.dialogShow = true;
this.$nextTick(function () { this.$nextTick(function () {
this.$store.dispatch('training/emitTipFresh'); this.$store.dispatch('training/emitTipFresh');
@ -167,41 +174,40 @@
this.$store.dispatch('training/emitTipFresh'); this.$store.dispatch('training/emitTipFresh');
}, },
cancel() { cancel() {
let operate = { const operate = {
type: this.operate.type, type: this.operate.type,
operation: OperationEvent.Command.close.alarm.operation, operation: OperationEvent.Command.close.alarm.operation
} };
this.$store.dispatch('training/next', operate).then(({ valid }) => { this.$store.dispatch('training/next', operate).then(({ valid }) => {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
if (valid) { if (valid) {
this.doClose(); this.doClose();
} }
}) });
}, },
commit() { commit() {
let operate = { const operate = {
type: this.operate.type, type: this.operate.type,
operation: OperationEvent.Command.close.alarm.operation, operation: OperationEvent.Command.close.alarm.operation
} };
this.$store.dispatch('training/next', operate).then(({ valid }) => { this.$store.dispatch('training/next', operate).then(({ valid }) => {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
if (valid) { if (valid) {
this.doClose(); this.doClose();
} }
}) });
}, },
isClose() { isClose() {
return this.dialogShow; return this.dialogShow;
} }
} }
} };
</script> </script>
<style rel="stylesheet/scss" lang="scss" scoped> <style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/mixin.scss"; @import "src/styles/mixin.scss";
.alarm-type .el-input { .alarm-type .el-input {
width: 220px; width: 220px;
} }

View File

@ -1,7 +1,16 @@
<template> <template>
<el-dialog class="ningbo-01__systerm cmd-notice" title="操作命令提示" :visible.sync="show" width="400px" :before-close="doClose" <el-dialog
:zIndex="2000" :modal="false" :close-on-click-modal="false" v-dialogDrag> v-dialogDrag
<span>{{name}}{{msg}}!</span> class="ningbo-01__systerm cmd-notice"
title="操作命令提示"
:visible.sync="show"
width="400px"
:before-close="doClose"
:z-index="2000"
:modal="false"
:close-on-click-modal="false"
>
<span>{{ name }}{{ msg }}!</span>
<el-row class="button-group"> <el-row class="button-group">
<el-button :id="domIdCancel" type="primary" :loading="loading" @click="commit">确认</el-button> <el-button :id="domIdCancel" type="primary" :loading="loading" @click="commit">确认</el-button>
</el-row> </el-row>
@ -9,8 +18,8 @@
</template> </template>
<script> <script>
import { MapDeviceType, OperationEvent } from '@/scripts/ConstDic'; import { OperationEvent } from '@/scripts/ConstDic';
export default { export default {
name: 'CmdNotice', name: 'CmdNotice',
data() { data() {
return { return {
@ -19,7 +28,7 @@
operate: null, operate: null,
name: '', name: '',
msg: '' msg: ''
} };
}, },
computed: { computed: {
show() { show() {
@ -27,18 +36,18 @@
}, },
domIdCancel() { domIdCancel() {
return this.dialogShow ? OperationEvent.Command.close.notice.domId : ''; return this.dialogShow ? OperationEvent.Command.close.notice.domId : '';
}, }
}, },
watch: { watch: {
'$store.state.socket.msgHead': function (elem) { '$store.state.socket.msgHead': function (elem) {
if (elem && (elem.hasOwnProperty('success') || elem.hasOwnProperty('timeout'))) { if (elem && (elem.hasOwnProperty('success') || elem.hasOwnProperty('timeout'))) {
let operate = this.$store.state.training.operate; const operate = this.$store.state.training.operate;
let control = this.$store.getters['map/getDeviceByCode'](elem.stationControlCode); const control = this.$store.getters['map/getDeviceByCode'](elem.stationControlCode);
let station = this.$store.getters['map/getDeviceByCode'](control.stationCode); const station = this.$store.getters['map/getDeviceByCode'](control.stationCode);
let newOperate = { const newOperate = {
type: operate.type, type: operate.type,
name: station.name, name: station.name
} };
if (elem.timeout) { if (elem.timeout) {
newOperate['msg'] = '请求超时'; newOperate['msg'] = '请求超时';
@ -48,12 +57,12 @@
this.doShow(newOperate); this.doShow(newOperate);
} }
} }
}, }
}, },
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
this.$store.dispatch('training/tipReload'); this.$store.dispatch('training/tipReload');
}) });
}, },
methods: { methods: {
doShow(operate) { doShow(operate) {
@ -73,34 +82,33 @@
this.$store.dispatch('training/emitTipFresh'); this.$store.dispatch('training/emitTipFresh');
}, },
cancel() { cancel() {
let operate = { const operate = {
operation: this.operate.type, operation: OperationEvent.Command.close.notice.operation
operation: OperationEvent.Command.close.notice.operation, };
}
this.$store.dispatch('training/next', operate).then(({ valid }) => { this.$store.dispatch('training/next', operate).then(({ valid }) => {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
if (valid) { if (valid) {
this.doClose(); this.doClose();
} }
}) });
}, },
commit() { commit() {
let operate = { const operate = {
type: this.operate.type, type: this.operate.type,
operation: OperationEvent.Command.close.notice.operation, operation: OperationEvent.Command.close.notice.operation
} };
this.$store.dispatch('training/next', operate).then(({ valid }) => { this.$store.dispatch('training/next', operate).then(({ valid }) => {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
if (valid) { if (valid) {
this.doClose(); this.doClose();
} }
}) });
}, },
isClose() { isClose() {
return this.dialogShow; return this.dialogShow;
} }
} }
} };
</script> </script>

View File

@ -213,11 +213,11 @@ export default {
operateType: 'Stand_View_Status', operateType: 'Stand_View_Status',
skinCode: '06', skinCode: '06',
trainingName: '查看站台信息({10}-{12}站台)', trainingName: '查看站台信息({10}-{12}站台)',
trainingRemark: '查看站台信息功能', trainingRemark: '站台详细信息功能',
trainingType: 'Stand', trainingType: 'Stand',
productTypes: ['01', '02'], productTypes: ['01', '02'],
stepVOList: [ stepVOList: [
{ deviceType: '06', orderNum: 1, operateCode: '507', tip: '鼠标右键菜单选择【查看站台信息】' }, { deviceType: '06', orderNum: 1, operateCode: '507', tip: '鼠标右键菜单选择【站台详细信息】' },
{ deviceType: '06', orderNum: 2, operateCode: '0012', tip: '鼠标左键点击【确定】按钮' } { deviceType: '06', orderNum: 2, operateCode: '0012', tip: '鼠标左键点击【确定】按钮' }
] ]
}, },
@ -292,12 +292,12 @@ export default {
operateType: 'Section_Set_Limit_Speed', operateType: 'Section_Set_Limit_Speed',
skinCode: '06', skinCode: '06',
trainingName: '设置临时限速({8}{9})', trainingName: '设置临时限速({8}{9})',
trainingRemark: '设置临时限速功能(限速值:自动', trainingRemark: '设置临时限速功能(限速值:不限速',
trainingType: 'Section', trainingType: 'Section',
productTypes: ['02'], productTypes: ['02'],
stepVOList: [ stepVOList: [
{ deviceType: '03', orderNum: 1, operateCode: '407', tip: '鼠标右键菜单选择【设置临时限速】' }, { deviceType: '03', orderNum: 1, operateCode: '407', tip: '鼠标右键菜单选择【设置临时限速】' },
{ deviceType: '03', orderNum: 2, operateCode: '4076', tip: '鼠标左键选择【限速值自动】', val: '0' }, { deviceType: '03', orderNum: 2, operateCode: '4076', tip: '鼠标左键选择【限速】', val: '0' },
{ deviceType: '03', orderNum: 3, operateCode: '4071', tip: '鼠标左键点击【下达】按钮' }, { deviceType: '03', orderNum: 3, operateCode: '4071', tip: '鼠标左键点击【下达】按钮' },
{ deviceType: '03', orderNum: 4, operateCode: '4072', tip: '鼠标左键点击【确认】按钮' }, { deviceType: '03', orderNum: 4, operateCode: '4072', tip: '鼠标左键点击【确认】按钮' },
{ deviceType: '03', orderNum: 5, operateCode: '4073', tip: '鼠标左键点击【确认1】按钮' }, { deviceType: '03', orderNum: 5, operateCode: '4073', tip: '鼠标左键点击【确认1】按钮' },
@ -453,7 +453,7 @@ export default {
trainingType: 'Switch', trainingType: 'Switch',
productTypes: ['01'], productTypes: ['01'],
stepVOList: [ stepVOList: [
{ deviceType: '03', orderNum: 1, operateCode: '104', tip: '鼠标右键菜单选择【区段解封】' }, { deviceType: '03', orderNum: 1, operateCode: '104', tip: '鼠标右键菜单选择【道岔单解】' },
{ deviceType: '03', orderNum: 2, operateCode: '1043', tip: '鼠标左键点击【确定】按钮' }, { deviceType: '03', orderNum: 2, operateCode: '1043', tip: '鼠标左键点击【确定】按钮' },
{ deviceType: '03', orderNum: 3, operateCode: '1046', tip: '鼠标左键选择({7})区段', val: '{17}' }, { deviceType: '03', orderNum: 3, operateCode: '1046', tip: '鼠标左键选择({7})区段', val: '{17}' },
{ deviceType: '03', orderNum: 4, operateCode: '1044', tip: '鼠标左键点击【确定】按钮' }, { deviceType: '03', orderNum: 4, operateCode: '1044', tip: '鼠标左键点击【确定】按钮' },
@ -484,7 +484,7 @@ export default {
trainingType: 'Switch', trainingType: 'Switch',
productTypes: ['01'], productTypes: ['01'],
stepVOList: [ stepVOList: [
{ deviceType: '03', orderNum: 1, operateCode: '106', tip: '鼠标右键菜单选择【区段解封】' }, { deviceType: '03', orderNum: 1, operateCode: '106', tip: '鼠标右键菜单选择【道岔解封】' },
{ deviceType: '03', orderNum: 2, operateCode: '1063', tip: '鼠标左键点击【确定】按钮' }, { deviceType: '03', orderNum: 2, operateCode: '1063', tip: '鼠标左键点击【确定】按钮' },
{ deviceType: '03', orderNum: 3, operateCode: '1066', tip: '鼠标左键选择({7})区段', val: '{17}' }, { deviceType: '03', orderNum: 3, operateCode: '1066', tip: '鼠标左键选择({7})区段', val: '{17}' },
{ deviceType: '03', orderNum: 4, operateCode: '1064', tip: '鼠标左键点击【确定】按钮' }, { deviceType: '03', orderNum: 4, operateCode: '1064', tip: '鼠标左键点击【确定】按钮' },

View File

@ -2,11 +2,11 @@ export function getBaseUrl() {
let BASE_API; let BASE_API;
if (process.env.NODE_ENV === 'development') { if (process.env.NODE_ENV === 'development') {
// BASE_API = 'https://joylink.club/jlcloud'; // BASE_API = 'https://joylink.club/jlcloud';
// BASE_API = 'https://test.joylink.club/jlcloud'; BASE_API = 'https://test.joylink.club/jlcloud';
// BASE_API = 'http://192.168.3.5:9000'; // 袁琪 // BASE_API = 'http://192.168.3.5:9000'; // 袁琪
BASE_API = 'http://192.168.3.6:9000'; // 旭强 // BASE_API = 'http://192.168.3.6:9000'; // 旭强
// BASE_API = 'http://192.168.3.41:9000'; // 张赛 // BASE_API = 'http://192.168.3.41:9000'; // 张赛
BASE_API = 'http://192.168.3.82:9000'; // 杜康 // BASE_API = 'http://192.168.3.82:9000'; // 杜康
// BASE_API = 'http://192.168.3.41:9000'; // 张赛 // BASE_API = 'http://192.168.3.41:9000'; // 张赛
// BASE_API = 'http://b29z135112.zicp.vip'; // BASE_API = 'http://b29z135112.zicp.vip';
// BASE_API = 'http://2925963m2a.zicp.vip'; // 杜康 // BASE_API = 'http://2925963m2a.zicp.vip'; // 杜康

View File

@ -196,11 +196,11 @@ export default {
name: this.$t('map.mapData'), name: this.$t('map.mapData'),
item: [ item: [
{ prop: 'stationCode', label: this.$t('map.equipmentStation') + ':', type: 'select', mode: true, optionLabel: 'name&&code', optionValue: 'code', disabled: this.isStationCodeDisabled, options: this.centralizedStationList, isHidden: this.isStationCodeDisabled}, { prop: 'stationCode', label: this.$t('map.equipmentStation') + ':', type: 'select', mode: true, optionLabel: 'name&&code', optionValue: 'code', disabled: this.isStationCodeDisabled, options: this.centralizedStationList, isHidden: this.isStationCodeDisabled},
{ prop: 'lengthFact', label: this.$t('map.actualLength') + ':', type: 'number', min: 0, placeholder: this.$t('map.meter'), isHidden: !this.hasAssociatedSection }, { prop: 'lengthFact', label: this.$t('map.actualLength') + ':', type: 'number', min: 0, placeholder: this.$t('map.meter'), isHidden: !this.isSwitchSectionType },
{ prop: 'leftStopPointOffset', label: this.$t('map.leftStopPointOffset'), type: 'number', min: 0, disabled: true, isHidden: !this.isStopPointOffset }, { prop: 'leftStopPointOffset', label: this.$t('map.leftStopPointOffset'), type: 'number', min: 0, disabled: true, isHidden: !this.isStopPointOffset },
{ prop: 'rightStopPointOffset', label: this.$t('map.rightStopPointOffset'), type: 'number', min: 0, disabled: true, isHidden: !this.isStopPointOffset }, { prop: 'rightStopPointOffset', label: this.$t('map.rightStopPointOffset'), type: 'number', min: 0, disabled: true, isHidden: !this.isStopPointOffset },
{ prop: 'region', label: this.$t('map.sectionColon'), type: 'select', optionLabel: 'label', optionValue: 'value', options: this.regionList, isHidden: !this.sectionColonShow }, { prop: 'region', label: this.$t('map.sectionColon'), type: 'select', optionLabel: 'label', optionValue: 'value', options: this.regionList, isHidden: !this.sectionColonShow },
{ prop: 'trainWindowCode', label: '关联车次窗', type: 'input', disabled: true}, { prop: 'trainWindowCode', label: '关联车次窗', type: 'input', disabled: true, isHidden: this.hasAssociatedSection },
{ prop: 'kmRangeLeft', label: this.$t('map.leftKilometerMark'), type: 'number', min: 0, placeholder: this.$t('map.meter') }, { prop: 'kmRangeLeft', label: this.$t('map.leftKilometerMark'), type: 'number', min: 0, placeholder: this.$t('map.meter') },
{ prop: 'kmRangeRight', label: this.$t('map.rightKilometerMark'), type: 'number', min: 0, placeholder: this.$t('map.meter') } { prop: 'kmRangeRight', label: this.$t('map.rightKilometerMark'), type: 'number', min: 0, placeholder: this.$t('map.meter') }
] ]

View File

@ -18,6 +18,7 @@ import UpdateOperate from './draft.vue';
import SetProject from './project'; import SetProject from './project';
import CopyMap from './copy'; import CopyMap from './copy';
import LocalMap from './localMap'; import LocalMap from './localMap';
import { superAdmin } from '@/router/index_APP_TARGET';
export default { export default {
name: 'PublishMap', name: 'PublishMap',
@ -139,8 +140,8 @@ export default {
], ],
actions: [ actions: [
{ text: '地图排序', handler: this.mapSort }, { text: '地图排序', handler: this.mapSort },
{ text: '导出', handler: this.localExport}, { text: '导出', handler: this.localExport, show: () => { return this.$store.state.user.roles.indexOf(superAdmin) > 0; }},
{ text: '导入', handler: this.localImport, fileType: 'file'} { text: '导入', handler: this.localImport, fileType: 'file', show: () => { return this.$store.state.user.roles.indexOf(superAdmin) > 0; }}
] ]
}, },
@ -373,7 +374,7 @@ export default {
background: 'rgba(0, 0, 0, 0.7)' background: 'rgba(0, 0, 0, 0.7)'
}); });
setTimeout(() => { setTimeout(() => {
const obj = this.$refs.files; const obj = document.getElementById('queryFormFilesInput');
if (!obj.files) return; if (!obj.files) return;
const f = obj.files[0]; const f = obj.files[0];
const reader = new FileReader(); const reader = new FileReader();
@ -384,7 +385,6 @@ export default {
localImportMap(JSON.parse(data)).then(res => { localImportMap(JSON.parse(data)).then(res => {
loading.close(); loading.close();
that.$message.success('导入成功!'); that.$message.success('导入成功!');
that.loadInitData();
loading.close(); loading.close();
}).catch(error => { }).catch(error => {
loading.close(); loading.close();

View File

@ -1,6 +1,6 @@
<template> <template>
<el-dialog v-dialogDrag title="导出地图" :visible.sync="dialogVisible" width="30%" center> <el-dialog v-dialogDrag title="导出地图" :visible.sync="dialogVisible" width="20%" center>
<el-select v-model="selectMapList" multiple placeholder="请选择" style="text-align: center"> <el-select v-model="selectMapList" multiple placeholder="请选择地图" style="width: 60%; position: relative; left: 20%;">
<el-option <el-option
v-for="item in publishMapList" v-for="item in publishMapList"
:key="item.id" :key="item.id"