Merge remote-tracking branch 'origin/thailand' into thailand

This commit is contained in:
joylink_zhangsai 2023-07-10 14:17:51 +08:00
commit de0d06c994
5 changed files with 34 additions and 35 deletions

View File

@ -55,16 +55,6 @@ export default {
title: 'Signal Device Control',
operate: '',
children: []
},
{
title: 'Operation Plan',
operate: '',
children: []
},
{
title: 'Plan Details:',
operate: '',
children: []
}
]
};

View File

@ -7,6 +7,7 @@
<train-operation ref="trainOperation" />
<switch-control ref="switchControl" />
<signal-control ref="signalControl" />
<operation-plan-detail ref="operationPlanDetail" />
</div>
</template>
<script>
@ -14,6 +15,7 @@ import { mapGetters } from 'vuex';
import MenuBar from '@/jmapNew/theme/components/menus/menuBarNew';
import {menuOperate} from '@/jmapNew/theme/components/utils/menuOperate';
import TrainFixedPathPane from './menuDialog/trainFixedPathPane';
import OperationPlanDetail from './menuDialog/operationPlanDetail.vue';
import { EventBus } from '@/scripts/event-bus';
import { destroySimulationByAdmin, exitSimulation} from '@/api/simulation';
import ViewName from './menuDialog/viewName';
@ -32,7 +34,8 @@ export default {
StationControlConvert,
TrainOperation,
SwitchControl,
SignalControl
SignalControl,
OperationPlanDetail
},
data() {
return {
@ -120,14 +123,10 @@ export default {
}
]
},
{
title: 'Operation Plan',
operate: '',
children: []
},
{
title: 'Plan Details',
operate: '',
click: this.openPlanDetail,
children: []
}
]
@ -314,6 +313,9 @@ export default {
callback: action => {
}
});
},
openPlanDetail() {
this.$refs.operationPlanDetail.doShow();
}
}
};

View File

@ -5,7 +5,7 @@
title="Operation Plan Detail"
:visible.sync="show"
width="660px"
height="500px"
height="500px"
:before-close="doClose"
:z-index="2000"
:modal="false"
@ -15,6 +15,7 @@
ref="detailTable"
class="table"
:data="detailData"
:row-class-name="tableRowClassName"
border
style="width: 100%"
size="mini"
@ -29,32 +30,43 @@
</el-dialog>
</template>
<script>
import { getSandTableRunPlanDetail } from '@/api/simulation'
import { getSandTableRunPlanDetail } from '@/api/simulation';
export default {
data() {
return {
dialogShow: false,
detailData: [],
}
};
},
computed: {
show() {
return this.dialogShow && !this.$store.state.menuOperation.break
return this.dialogShow && !this.$store.state.menuOperation.break;
},
},
methods: {
async doShow() {
this.dialogShow = true
const resp = await getSandTableRunPlanDetail(this.$route.query.group)
this.detailData = resp.data
console.log(resp)
this.dialogShow = true;
const resp = await getSandTableRunPlanDetail(this.$route.query.group);
this.detailData = resp.data;
console.log(resp);
},
doClose() {
this.dialogShow = false
this.$store.dispatch('training/emitTipFresh')
this.dialogShow = false;
this.$store.dispatch('training/emitTipFresh');
},
tableRowClassName({ row }) {
if (row.finished) {
return 'finished';
}
},
},
}
};
</script>
<style scoped></style>
<style lang="scss" scoped>
/deep/ {
.el-table .finished {
color: green;
}
}
</style>

View File

@ -43,7 +43,7 @@
</template>
<script>
import { sandTableRunAsPlan, setOccupy } from '@/api/simulation';
import { sandTableRunAsPlan } from '@/api/simulation';
import { mapGetters } from 'vuex';
export default {
name: 'SetOperationPlanDialog',
@ -99,11 +99,6 @@ export default {
const sectionCodes = this.formData.map(_ => _.trackCode);
const runData = this.formData;
try {
const res = await setOccupy(simulationId, sectionCodes.join(','));
if (res.code !== 200) {
console.err(res);
return;
}
await sandTableRunAsPlan(simulationId, runData);
this.doClose();
} catch (err) {

View File

@ -29,7 +29,7 @@ export function handlerUrl() {
// BASE_API = 'http://114.116.51.125/jlcloud';
// BASE_API = 'http://192.168.3.47:9000'; // 周寅
// BASE_API = 'http://192.168.3.94:9000'; // 旭强
BASE_API = 'http://192.168.3.15:9000'; // 张赛
BASE_API = 'http://192.168.3.15:9000'; // 张赛
// BASE_API = 'http://192.168.3.5:9000'; // 夏增彬
// BASE_API = 'http://192.168.3.37:9000'; // 卫志宏
// BASE_API = 'http://b29z135112.zicp.vip';