调整车站值班员按钮
This commit is contained in:
parent
8a28526fe1
commit
88ec572564
@ -1,11 +1,22 @@
|
||||
<template>
|
||||
<div class="chatBox" :class="{'active': drawer}" :style="{'bottom':bottom+'px'}">
|
||||
<div class="menuTrainListBtn" @click="clickBtn">
|
||||
<!-- <i class="el-icon-more" /> -->
|
||||
<template v-if="userRole == 'DISPATCHER'">
|
||||
<p style="margin: 0;">调</p>
|
||||
<p style="margin: 0;">度</p>
|
||||
<p style="margin: 0;">电</p>
|
||||
<p style="margin: 0;">话</p>
|
||||
</template>
|
||||
<template v-if="userRole != 'AUDIENCE' && userRole != 'DISPATCHER'">
|
||||
<p style="margin: 0;">电</p>
|
||||
<p style="margin: 0;">话</p>
|
||||
</template>
|
||||
<template v-if="userRole == 'AUDIENCE'">
|
||||
<p style="margin: 0;">通</p>
|
||||
<p style="margin: 0;">话</p>
|
||||
<p style="margin: 0;">记</p>
|
||||
<p style="margin: 0;">录</p>
|
||||
</template>
|
||||
</div>
|
||||
<div class="chat-box-main">
|
||||
<!-- v-if="!conversitionId && userRole !== 'AUDIENCE' && !commonConversation" -->
|
||||
@ -116,20 +127,8 @@
|
||||
width="360px"
|
||||
@changeMessageList="changeMessageList"
|
||||
/>
|
||||
<!-- <div v-if="recordSending" class="chat_record_tip">
|
||||
<div id="record_progress_bar" :style="'width:'+100/60*seconds+'%'" />
|
||||
<div class="record_icon" />
|
||||
<div class="record_tip_text">正在录音...</div>
|
||||
<div class="record_tip_confirm" @click="stopRecording()">确定</div>
|
||||
<div class="record_tip_cancle" @click="cancleRecording()">取消</div>
|
||||
</div> -->
|
||||
<chat-member-list ref="chatMemberList" :conversition-member-list="conversitionMemberList" :simulation-users="simulationUsers" />
|
||||
</div>
|
||||
<!-- <div class="chat-box-footer">
|
||||
<div class="chat-box-footer-tool" />
|
||||
<el-button v-if="isButtonShow && !commonConversation" size="mini" type="danger" class="chat-box-footer-quit" :loading="quitLoading" @click="quitConversition()">退出会话</el-button>
|
||||
<el-button v-if="isButtonShow && !commonConversation" class="chat-box-footer-send" size="mini" type="primary" :disabled="recordSending" @click="startRecording()">发送语音</el-button>
|
||||
</div> -->
|
||||
</template>
|
||||
</div>
|
||||
<chat-setting ref="chatSetting" :form="form" @setSetting="setSetting" />
|
||||
@ -320,7 +319,7 @@ export default {
|
||||
},
|
||||
'$store.state.training.memberList': function (val) {
|
||||
if (val && val.length) {
|
||||
this.memberData = this.$store.state.training.memberData;
|
||||
this.memberData = JSON.parse(JSON.stringify(this.$store.state.training.memberData));
|
||||
const dispatcherList = [];
|
||||
const electricDispatcherList = [];
|
||||
const depotDispatcherList = [];
|
||||
@ -361,6 +360,7 @@ export default {
|
||||
break;
|
||||
}
|
||||
});
|
||||
stationSupervisorList.push({ label: '全部集中站', value: 'allConcentrateStation', active: false }, { label: '全部车站', value: 'allStation', active: false });
|
||||
this.treeData = [{
|
||||
label: '行调',
|
||||
id: 'dispatcher',
|
||||
@ -549,8 +549,30 @@ export default {
|
||||
handleSetting() {
|
||||
this.$refs.chatSetting.doShow();
|
||||
},
|
||||
handleCheckChange(data) {
|
||||
handleCheckChange(data, jude = false) {
|
||||
if (data.value == 'allConcentrateStation' || data.value == 'allStation') {
|
||||
data.active = !data.active;
|
||||
if (data.value == 'allConcentrateStation') {
|
||||
this.treeData[1] && this.treeData[1]['children'].forEach(item => {
|
||||
const stationModel = this.$store.getters['map/getDeviceByCode'](item.deviceCode);
|
||||
if (stationModel && stationModel.centralized) {
|
||||
item.active = data.active;
|
||||
this.handleCheckChange(item, true);
|
||||
}
|
||||
});
|
||||
}
|
||||
if (data.value == 'allStation') {
|
||||
this.treeData[1] && this.treeData[1]['children'].forEach(item => {
|
||||
if (item.value != 'allConcentrateStation' && item.value != 'allStation') {
|
||||
item.active = data.active;
|
||||
this.handleCheckChange(item, true);
|
||||
}
|
||||
});
|
||||
}
|
||||
} else {
|
||||
if (!jude) {
|
||||
data.active = !data.active;
|
||||
}
|
||||
const member = data;
|
||||
if (data.active) {
|
||||
if (member && member.type === 'DRIVER' && !this.activeTrains.includes(member.deviceCode)) {
|
||||
@ -570,6 +592,7 @@ export default {
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
},
|
||||
filterNode() {
|
||||
this.treeData[2] && this.treeData[2]['children'].forEach(train => {
|
||||
|
@ -26,7 +26,7 @@
|
||||
@node-click="handleNodeClick"
|
||||
>
|
||||
<span :id="data.id" slot-scope="{ node, data }" class="custom-tree-node">
|
||||
<span>{{ data.label }}</span>
|
||||
<span>{{ node.label }}</span>
|
||||
<span v-if="data.type">
|
||||
<el-select :key="data.id" v-model="data.userId" placeholder="请选择" clearable size="mini" @change="nodeMemberChange($event, data)">
|
||||
<el-option
|
||||
@ -147,7 +147,7 @@ export default {
|
||||
},
|
||||
'$store.state.training.memberList': function (val) {
|
||||
if (val && val.length) {
|
||||
this.memberData = this.$store.state.training.memberData;
|
||||
this.memberData = JSON.parse(JSON.stringify(this.$store.state.training.memberData));
|
||||
const dispatcherList = [];
|
||||
const electricDispatcherList = [];
|
||||
const depotDispatcherList = [];
|
||||
|
Loading…
Reference in New Issue
Block a user