国际化处理
This commit is contained in:
parent
4da9dc977b
commit
d87a4fff22
@ -33,5 +33,11 @@ export default {
|
||||
createSpeedLevelFailed: 'Failed to create speed level',
|
||||
createOperationGraphFailed: 'Failed to create operation diagram',
|
||||
loadingCityListFailed: 'Failed to load city list',
|
||||
cannotNarrowDown: 'You cannot narrow down the training list you created last time'
|
||||
cannotNarrowDown: 'You cannot narrow down the training list you created last time',
|
||||
scanningError: 'Scanning error',
|
||||
serviceException: 'Service exception',
|
||||
codeHasExist: 'Coding already exists',
|
||||
formartError: 'The format is incorrect, only characters/numbers/_',
|
||||
createDictionaryFailed: 'Failed to create dictionary',
|
||||
updateDictionaryFailed: 'Failed to update dictionary'
|
||||
};
|
||||
|
@ -13,7 +13,8 @@ export default {
|
||||
add: 'Add',
|
||||
query: 'Query',
|
||||
detail: 'Details',
|
||||
quickEntry: 'Quick Entry',
|
||||
quickEntry: 'Quick entry',
|
||||
scan: 'Scan',
|
||||
chooseDate: 'Please choose the date',
|
||||
chooseTime: 'Please choose the time',
|
||||
chooseDateTime: 'Please choose the date and time',
|
||||
@ -65,5 +66,18 @@ export default {
|
||||
filteringKeywords: 'Enter keywords for filtering',
|
||||
previousStep: 'PreviousStep',
|
||||
skip: 'Skip',
|
||||
modify: 'Modify'
|
||||
modify: 'Modify',
|
||||
language: 'Language',
|
||||
exit: 'Exit',
|
||||
chooseLanguage: 'Please choose the language',
|
||||
switchLanguage: 'Switch language',
|
||||
joinRoom: 'Join Room',
|
||||
synthesisTrainingTitle: 'Synthesis Training Fast Entrance',
|
||||
pleaseChooseRoom: 'You did not choose a room',
|
||||
inviteJoinRoom: 'Invite you to join the synthesis training!',
|
||||
trainingHasStart: "(name)'s room has begun",
|
||||
trainingNotStart: "(name)'s room hasn't started yet",
|
||||
inputRoomNumber: 'Please enter the room number.',
|
||||
chooseRoom: 'Choose Room'
|
||||
|
||||
};
|
||||
|
@ -23,7 +23,7 @@ export default {
|
||||
|
||||
dpSystem: 'Large screen',
|
||||
|
||||
planSystem: 'Lian Plan',
|
||||
planSystem: 'Lian plan',
|
||||
|
||||
replayManage: 'Playback',
|
||||
|
||||
|
@ -142,6 +142,11 @@ export default {
|
||||
endSectionCode: '请选择终到区段',
|
||||
|
||||
selectTurnoutID: '请选择道岔ID',
|
||||
switchesCannot: '道岔不能为同一个'
|
||||
switchesCannot: '道岔不能为同一个',
|
||||
|
||||
pleaseInputName: '请输入名称',
|
||||
pleaseSelectStatus: '请选择状态',
|
||||
pleaseInputCode: '请输入编码',
|
||||
strLength1To25: '长度在 1 到 25 个字符',
|
||||
strLengthNotExceed50: '不能超过 50 个字符'
|
||||
};
|
||||
|
@ -6,5 +6,11 @@ export default {
|
||||
createDirectory: 'Create dictionary',
|
||||
editDictionary: 'Edit dictionary',
|
||||
deleteSuccess: 'Successful deletion',
|
||||
dleeteTipContext: 'This operation will delete the type. Do you want to continue?'
|
||||
dleeteTipContext: 'This operation will delete the type. Do you want to continue?',
|
||||
createSuccess: 'Create successful',
|
||||
updateSuccess: 'Update successful',
|
||||
destory: 'Destory',
|
||||
simulationGroup: 'Simulation group',
|
||||
username: 'User name',
|
||||
phoneNumber: 'Cell-phone number'
|
||||
};
|
||||
|
@ -33,6 +33,12 @@ export default {
|
||||
createSpeedLevelFailed: '创建速度等级失败',
|
||||
createOperationGraphFailed: '创建运行图失败',
|
||||
loadingCityListFailed: '加载城市列表失败',
|
||||
cannotNarrowDown: '不能缩小上次创建的实训列表的范围'
|
||||
cannotNarrowDown: '不能缩小上次创建的实训列表的范围',
|
||||
scanningError: '扫码错误',
|
||||
serviceException: '服务异常',
|
||||
codeHasExist: '编码已存在',
|
||||
formartError: '格式不正确,只能是字符/数字/_',
|
||||
createDictionaryFailed: '创建字典失败',
|
||||
updateDictionaryFailed: '更新字典失败'
|
||||
|
||||
};
|
||||
|
@ -14,6 +14,7 @@ export default {
|
||||
query: '查 询',
|
||||
detail: '明 细',
|
||||
quickEntry: '快速入口',
|
||||
scan: '扫码',
|
||||
chooseDate: '请选择日期',
|
||||
chooseTime: '请选择时间',
|
||||
chooseDateTime: '请选择日期时间',
|
||||
@ -66,5 +67,17 @@ export default {
|
||||
filteringKeywords: '输入关键字进行过滤',
|
||||
previousStep: '上一步',
|
||||
skip: '跳过',
|
||||
modify: '修改'
|
||||
modify: '修改',
|
||||
language: '语言',
|
||||
exit: '退出',
|
||||
chooseLanguage: '请选择语言',
|
||||
switchLanguage: '切换语言',
|
||||
joinRoom: '加入房间',
|
||||
synthesisTrainingTitle: '综合演练快速入口',
|
||||
pleaseChooseRoom: '您没有选择房间',
|
||||
inviteJoinRoom: '邀请你加入综合演练!',
|
||||
trainingHasStart: '{{name}}的房间已开始',
|
||||
trainingNotStart: '{{name}}的房间未开始',
|
||||
inputRoomNumber: '请输入房间号',
|
||||
chooseRoom: '选择房间'
|
||||
};
|
||||
|
@ -142,6 +142,11 @@ export default {
|
||||
endSectionCode: '请选择终到区段',
|
||||
|
||||
selectTurnoutID: '请选择道岔ID',
|
||||
switchesCannot: '道岔不能为同一个'
|
||||
switchesCannot: '道岔不能为同一个',
|
||||
|
||||
pleaseInputName: '请输入名称',
|
||||
pleaseSelectStatus: '请选择状态',
|
||||
pleaseInputCode: '请输入编码',
|
||||
strLength1To25: '长度在 1 到 25 个字符',
|
||||
strLengthNotExceed50: '不能超过 50 个字符'
|
||||
};
|
||||
|
@ -6,5 +6,11 @@ export default {
|
||||
createDirectory: '创建目录',
|
||||
editDictionary: '编辑目录',
|
||||
deleteSuccess: '删除成功',
|
||||
dleeteTipContext: '此操作将删除该类型, 是否继续?'
|
||||
dleeteTipContext: '此操作将删除该类型, 是否继续?',
|
||||
createSuccess: '创建成功',
|
||||
updateSuccess: '更新成功',
|
||||
destory: '销 毁',
|
||||
simulationGroup: '仿真Group',
|
||||
username: '用户名',
|
||||
phoneNumber: '手机号'
|
||||
};
|
||||
|
@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div class="avatar-container" style="right: 80px;">
|
||||
<el-menu-item v-for="item in entryList" :key="item.name" class="avatar-wrapper" index="" @click="item.handle">
|
||||
<span style="color: white;">{{ item.name }}</span>
|
||||
<span style="color: white;">{{ $t(item.name) }}</span>
|
||||
</el-menu-item>
|
||||
<deomon-list ref="deomonList" />
|
||||
<qcode ref="qcode" />
|
||||
@ -22,11 +22,11 @@ export default {
|
||||
return {
|
||||
entryList: [
|
||||
{
|
||||
name: this.$t('global.quickEntry'),
|
||||
name: 'global.quickEntry',
|
||||
handle: this.quickEntry
|
||||
},
|
||||
{
|
||||
name: '扫码',
|
||||
name: 'global.scan',
|
||||
handle: this.qcodeEntry
|
||||
}
|
||||
],
|
||||
|
@ -1,13 +1,13 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
title="切换语言"
|
||||
:title="$t('global.switchLanguage')"
|
||||
:visible.sync="visible"
|
||||
width="360px"
|
||||
:before-close="doClose"
|
||||
>
|
||||
<div style="">
|
||||
<span>语言:</span>
|
||||
<el-select v-model="lang" placeholder="请选择语言">
|
||||
<span>{{ $t('global.language') }}:</span>
|
||||
<el-select v-model="lang" :placeholder="$t('global.chooseLanguage')">
|
||||
<el-option
|
||||
v-for="item in options"
|
||||
:key="item.value"
|
||||
@ -17,8 +17,8 @@
|
||||
</el-select>
|
||||
</div>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button @click="visible = false">取 消</el-button>
|
||||
<el-button type="primary" @click="handleConfirm">确 定</el-button>
|
||||
<el-button @click="visible = false">{{ $t('global.cancel') }}</el-button>
|
||||
<el-button type="primary" @click="handleConfirm">{{ $t('global.confirm') }}</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
@ -1,7 +1,6 @@
|
||||
<template>
|
||||
<el-dropdown class="avatar-container" trigger="hover" :show-timeout="100">
|
||||
<div class="avatar-wrapper">
|
||||
<!-- <img class="user-avatar" :src="avatar+'?imageView2/1/w/80/h/80'"> -->
|
||||
<span style="color: white;">
|
||||
{{ username }}
|
||||
</span>
|
||||
@ -9,10 +8,10 @@
|
||||
</div>
|
||||
<el-dropdown-menu slot="dropdown" class="user-dropdown">
|
||||
<el-dropdown-item>
|
||||
<span style="display:block;" @click="language">语言</span>
|
||||
<span style="display:block;" @click="language">{{ $t('global.language') }}</span>
|
||||
</el-dropdown-item>
|
||||
<el-dropdown-item>
|
||||
<span style="display:block;" @click="logout">退出</span>
|
||||
<span style="display:block;" @click="logout">{{ $t('global.exit') }}</span>
|
||||
</el-dropdown-item>
|
||||
</el-dropdown-menu>
|
||||
<language ref="language" />
|
||||
|
@ -1,9 +1,9 @@
|
||||
<template>
|
||||
<el-dialog title="输入房间号" :visible.sync="centerDialogVisible" width="30%" center>
|
||||
<el-input v-model="input" placeholder="请输入房间号" />
|
||||
<el-dialog :title="$t('global.chooseRoom')" :visible.sync="centerDialogVisible" width="30%" center>
|
||||
<el-input v-model="input" :placeholder="$t('global.inputRoomNumber')" />
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button @click="centerDialogVisible = false">取 消</el-button>
|
||||
<el-button type="primary" @click="comit">确 定</el-button>
|
||||
<el-button @click="centerDialogVisible = false">{{ $t('global.cancel') }}</el-button>
|
||||
<el-button type="primary" @click="comit">{{ $t('global.confirm') }}</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</template>
|
||||
@ -37,10 +37,10 @@ export default {
|
||||
await getPermissionJoint(`${this.input}`);
|
||||
this.centerDialogVisible = false;
|
||||
} catch (error) {
|
||||
this.$messageBox('扫码错误:' + error.message);
|
||||
this.$messageBox(`${this.$t('error.scanningError')}:${error.message}`);
|
||||
}
|
||||
} else {
|
||||
this.$messageBox('请输入房间号');
|
||||
this.$messageBox(this.$t('global.inputRoomNumber'));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -9,7 +9,6 @@
|
||||
:modal="false"
|
||||
:close-on-click-modal="false"
|
||||
>
|
||||
<!-- <el-input v-model="filterText" placeholder="输入关键字进行过滤" /> -->
|
||||
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{height: height+'px'}">
|
||||
<el-tree
|
||||
ref="tree"
|
||||
@ -22,14 +21,18 @@
|
||||
@node-click="clickEvent"
|
||||
>
|
||||
<span slot-scope="{ node, data }">
|
||||
<span>{{ data.creator.nickName }}的房间({{ data.state == '01' ? '未开始' : '已开始' }})</span>
|
||||
<span v-if="data.state=='01'">{{ $t('global.trainingHasStart').replace('(name)', data.creator.nickName) }}</span>
|
||||
<span v-else>{{ $t('global.trainingHasStart').replace('(name)', data.creator.nickName) }}</span>
|
||||
</span>
|
||||
</el-tree>
|
||||
</el-scrollbar>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<!-- <el-button type="primary" @click="handleWatch">观看</el-button> -->
|
||||
<el-button type="primary" @click="handleJoin">加入房间</el-button>
|
||||
<el-button @click="dialogShow = false">取 消</el-button>
|
||||
<span
|
||||
slot="
|
||||
footer"
|
||||
class="dialog-footer"
|
||||
>
|
||||
<el-button type="primary" @click="handleJoin">{{ $t('global.joinRoom') }}</el-button>
|
||||
<el-button @click="dialogShow = false">{{ $t('global.cancel') }}</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</template>
|
||||
@ -46,7 +49,6 @@ export default {
|
||||
dialogShow: false,
|
||||
loading: false,
|
||||
height: 120,
|
||||
// filterText: '',
|
||||
trainingList: [],
|
||||
defaultProps: {
|
||||
label: 'roomName'
|
||||
@ -61,7 +63,7 @@ export default {
|
||||
return this.dialogShow;
|
||||
},
|
||||
title() {
|
||||
return '综合演练快速入口';
|
||||
return this.$t('global.synthesisTrainingTitle');
|
||||
},
|
||||
isWatch() {
|
||||
return true;
|
||||
@ -116,7 +118,7 @@ export default {
|
||||
this.$router.push({ path: `/trainroom`, query: query });
|
||||
}
|
||||
} else {
|
||||
this.$message.info('您没有选择房间');
|
||||
this.$message.info(this.$t('global.pleaseChooseRoom'));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -9,10 +9,10 @@
|
||||
:modal="false"
|
||||
:close-on-click-modal="false"
|
||||
>
|
||||
<div style="height: 80px; line-height: 80px; font-size: 16px; padding-left: 10px;">{{ roomName }}邀请你加入综合演练!</div>
|
||||
<div style="height: 80px; line-height: 80px; font-size: 16px; padding-left: 10px;">{{ roomName }}{{ $t('global.inviteJoinRoom') }}</div>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="handleJoin">确认</el-button>
|
||||
<el-button @click="dialogShow = false">取 消</el-button>
|
||||
<el-button type="primary" @click="handleJoin">{{ $t('global.confirm') }}</el-button>
|
||||
<el-button @click="dialogShow = false">{{ $t('global.cancel') }}</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</template>
|
||||
@ -38,7 +38,7 @@ export default {
|
||||
return this.dialogShow;
|
||||
},
|
||||
title() {
|
||||
return '综合演练快速入口';
|
||||
return this.$t('global.synthesisTrainingTitle');
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
|
@ -286,7 +286,6 @@ export default {
|
||||
const data = { mapId: this.courseModel.mapId, code: this.currentPrdCode };
|
||||
this.buttonLoading = true;
|
||||
simulationNotify(data).then(resp => {
|
||||
// try 0 有权限不走试用
|
||||
const query = { skinCode: this.courseModel.skinCode, group: resp.data, prdType: this.courseModel.prdType, mapId: this.courseModel.mapId, code: this.currentPrdCode, goodsId: this.goodsId, try: this.tryUser };
|
||||
this.$router.push({ path: `${UrlConfig.display}/demon`, query: query });
|
||||
launchFullscreen();
|
||||
|
@ -36,12 +36,12 @@ export default {
|
||||
const form = {
|
||||
labelWidth: '60px',
|
||||
items: [
|
||||
{ prop: 'code', label: '编码', type: 'text', required: true, disabled: !isAdd },
|
||||
{ prop: 'name', label: '名称', type: 'text', required: true },
|
||||
{ prop: 'code', label: this.$t('system.code'), type: 'text', required: true, disabled: !isAdd },
|
||||
{ prop: 'name', label: this.$t('system.name'), type: 'text', required: true },
|
||||
{
|
||||
prop: 'status', label: '状态', type: 'select', required: true, options: this.$ConstSelect.Status
|
||||
prop: 'status', label: this.$t('system.status'), type: 'select', required: true, options: this.$ConstSelect.Status
|
||||
},
|
||||
{ prop: 'remarks', label: '备注', type: 'textarea', required: false }
|
||||
{ prop: 'remarks', label: this.$t('system.remarks'), type: 'textarea', required: false }
|
||||
]
|
||||
};
|
||||
return form;
|
||||
@ -49,21 +49,21 @@ export default {
|
||||
rules() {
|
||||
const crules = {
|
||||
name: [
|
||||
{ required: true, message: '请输入名称', trigger: 'blur' },
|
||||
{ min: 1, max: 25, message: '长度在 1 到 25 个字符', trigger: 'blur' }
|
||||
{ required: true, message: this.$t('rules.pleaseInputName'), trigger: 'blur' },
|
||||
{ min: 1, max: 25, message: this.$t('rules.strLength1To25'), trigger: 'blur' }
|
||||
],
|
||||
status: [
|
||||
{ required: true, message: '请选择状态', trigger: 'change' }
|
||||
{ required: true, message: this.$t('rules.pleaseSelectStatus'), trigger: 'change' }
|
||||
],
|
||||
remarks: [
|
||||
{ max: 50, message: '不能超过 50 个字符', trigger: 'blur' }
|
||||
{ max: 50, message: this.$t('rules.strLengthNotExceed50'), trigger: 'blur' }
|
||||
]
|
||||
};
|
||||
if (this.type === 'ADD') {
|
||||
return Object.assign(crules, {
|
||||
code: [
|
||||
{ required: true, message: '请输入编码', trigger: 'blur' },
|
||||
{ min: 1, max: 25, message: '长度在 1 到 25 个字符', trigger: 'blur' },
|
||||
{ required: true, message: this.$t('rules.pleaseInputCode'), trigger: 'blur' },
|
||||
{ min: 1, max: 25, message: this.$t('rules.strLength1To25'), trigger: 'blur' },
|
||||
{ validator: this.validateCode, trigger: 'blur' }
|
||||
]
|
||||
});
|
||||
@ -73,25 +73,25 @@ export default {
|
||||
},
|
||||
title() {
|
||||
if (this.type === 'ADD') {
|
||||
return '创建目录';
|
||||
return this.$t('system.createDirectory');
|
||||
} else {
|
||||
return '编辑目录';
|
||||
return this.$t('system.editDictionary');
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
validateCode(rule, value, callback) {
|
||||
if (!validateCharCode(value)) {
|
||||
return callback(new Error('格式不正确,只能是字符/数字/_'));
|
||||
return callback(new Error(this.$t('error.formartError')));
|
||||
} else {
|
||||
checkDicCodeExist(value).then(response => {
|
||||
if (response.data) {
|
||||
return callback(new Error('编码已存在'));
|
||||
return callback(new Error(this.$t('error.codeHasExist')));
|
||||
} else {
|
||||
return callback();
|
||||
}
|
||||
}).catch(() => {
|
||||
return callback(new Error('服务异常'));
|
||||
return callback(new Error(this.$t('error.serviceException')));
|
||||
});
|
||||
}
|
||||
},
|
||||
@ -117,21 +117,21 @@ export default {
|
||||
create() {
|
||||
const self = this;
|
||||
create(this.formModel).then(response => {
|
||||
self.$message.success('创建字典目录成功');
|
||||
self.$message.success(this.$t('system.createSuccess'));
|
||||
self.handleClose();
|
||||
self.$emit('reloadTable');
|
||||
}).catch(error => {
|
||||
self.$message.error('创建字典目录失败:' + error.message);
|
||||
self.$message.error(`${this.$t('error.createDictionaryFailed')}:${error.message}`);
|
||||
});
|
||||
},
|
||||
update() {
|
||||
const self = this;
|
||||
update(this.formModel).then(response => {
|
||||
self.$message.success('更新字典目录成功');
|
||||
self.$message.success(this.$t('system.updateSuccess'));
|
||||
self.handleClose();
|
||||
self.$emit('reloadTable');
|
||||
}).catch(error => {
|
||||
self.$message.error('更新字典目录失败:' + error.message);
|
||||
self.$message.error(`${this.$t('error.updateDictionaryFailed')}:${error.message}`);
|
||||
});
|
||||
},
|
||||
handleClose(done) {
|
||||
|
@ -2,8 +2,8 @@
|
||||
<el-dialog :title="title" :visible.sync="dialogVisible" width="30%" :before-close="handleClose" center>
|
||||
<data-form ref="dataform" :form="form" :form-model="formModel" :rules="rules" />
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="doSave">确 定</el-button>
|
||||
<el-button @click="dialogVisible = false">取 消</el-button>
|
||||
<el-button type="primary" @click="doSave">{{ $t('global.confirm') }}</el-button>
|
||||
<el-button @click="dialogVisible = false">{{ $t('global.cancel') }}</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
@ -24,15 +24,15 @@ export default {
|
||||
queryObject: {
|
||||
group: {
|
||||
type: 'text',
|
||||
label: '仿真Group'
|
||||
label: this.$t('system.simulationGroup')
|
||||
},
|
||||
userName: {
|
||||
type: 'text',
|
||||
label: '用户名'
|
||||
label: this.$t('system.username')
|
||||
},
|
||||
mobile: {
|
||||
type: 'text',
|
||||
label: '手机号'
|
||||
label: this.$t('system.phoneNumber')
|
||||
},
|
||||
skinCode: {
|
||||
type: 'select',
|
||||
@ -137,11 +137,10 @@ export default {
|
||||
},
|
||||
{
|
||||
type: 'button',
|
||||
title: '操作',
|
||||
// width: '250',
|
||||
title: this.$t('global.operate'),
|
||||
buttons: [
|
||||
{
|
||||
name: '销毁',
|
||||
name: this.$t('system.destory'),
|
||||
handleClick: this.handleDelete,
|
||||
type: 'danger'
|
||||
}
|
||||
|
@ -1,11 +1,26 @@
|
||||
<template>
|
||||
<el-dialog class="default route-cancel" :title="title" :visible.sync="show" width="20%" :zIndex="2000" :modal="true"
|
||||
:before-close="cancel" :close-on-click-modal="false" v-dialogDrag>
|
||||
<el-input placeholder="输入名称进行过滤" v-model="filterText" clearable> </el-input>
|
||||
<el-dialog
|
||||
v-dialogDrag
|
||||
class="default route-cancel"
|
||||
:title="title"
|
||||
:visible.sync="show"
|
||||
width="20%"
|
||||
:z-index="2000"
|
||||
:modal="true"
|
||||
:before-close="cancel"
|
||||
:close-on-click-modal="false"
|
||||
>
|
||||
<el-input v-model="filterText" placeholder="输入名称进行过滤" clearable />
|
||||
<ul class="listBox">
|
||||
<li class="listLi" v-for="item in list">
|
||||
<input class="checkbox" :class="item.disabled ? 'disabled' : ''" type="checkbox" v-model="item.select"
|
||||
:disabled="item.disabled" @change="handleNodeClick(item)"></input>
|
||||
<li v-for="item in list" :key="item" class="listLi">
|
||||
<input
|
||||
v-model="item.select"
|
||||
class="checkbox"
|
||||
:class="item.disabled ? 'disabled' : ''"
|
||||
type="checkbox"
|
||||
:disabled="item.disabled"
|
||||
@change="handleNodeClick(item)"
|
||||
>
|
||||
<span>{{ item.nickName }}</span>
|
||||
</li>
|
||||
</ul>
|
||||
@ -31,17 +46,17 @@
|
||||
},
|
||||
treeList: [],
|
||||
list: [],
|
||||
filterText: '',
|
||||
filterText: ''
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
show() {
|
||||
return this.dialogShow;
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
filterText(val) {
|
||||
this.list = this.treeList.filter(p => p.nickName.indexOf(val) !== -1);
|
||||
},
|
||||
},
|
||||
computed: {
|
||||
show() {
|
||||
return this.dialogShow;
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
@ -57,7 +72,7 @@
|
||||
if (data.select) {
|
||||
this.personList.push(data);
|
||||
} else {
|
||||
this.personList.splice(this.personList.findIndex(item => item.id == data.id), 1)
|
||||
this.personList.splice(this.personList.findIndex(item => item.id == data.id), 1);
|
||||
}
|
||||
},
|
||||
doClose() {
|
||||
@ -66,10 +81,10 @@
|
||||
this.list.forEach(nor => {
|
||||
nor.select = false;
|
||||
});
|
||||
this.$emit('handleUserList', this.list)
|
||||
this.$emit('handleUserList', this.list);
|
||||
},
|
||||
commit() {
|
||||
this.$emit('handleDispatch', this.personList)
|
||||
this.$emit('handleDispatch', this.personList);
|
||||
this.dialogShow = false;
|
||||
this.personList = [];
|
||||
},
|
||||
@ -77,7 +92,7 @@
|
||||
this.doClose();
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
|
Loading…
Reference in New Issue
Block a user