|
|
@@ -53,6 +53,15 @@
|
|
|
@click="bindingProcess"
|
|
|
>绑定关键工序</el-button
|
|
|
>
|
|
|
+ <el-button
|
|
|
+ v-if="$hasPermission('main:user:push')"
|
|
|
+ :disabled="selection?.length === 0"
|
|
|
+ type="primary"
|
|
|
+ size="mini"
|
|
|
+ plain
|
|
|
+ @click="allPushBtn"
|
|
|
+ >批量推送</el-button
|
|
|
+ >
|
|
|
</template>
|
|
|
<!-- 角色列 -->
|
|
|
<template v-slot:roles="{ row }">
|
|
|
@@ -204,7 +213,8 @@
|
|
|
import {
|
|
|
getUserPage,
|
|
|
removePersonnel,
|
|
|
- unbindLoginName
|
|
|
+ unbindLoginName,
|
|
|
+ employeePush
|
|
|
} from '@/api/system/organization';
|
|
|
import { pageUsers, exportUsers } from '@/api/system/user';
|
|
|
import dictMixins from '@/mixins/dictMixins';
|
|
|
@@ -334,6 +344,16 @@
|
|
|
return dom ? dom.label : '';
|
|
|
}
|
|
|
},
|
|
|
+ {
|
|
|
+ prop: 'code',
|
|
|
+ label: '是否推送',
|
|
|
+ align: 'center',
|
|
|
+ showOverflowTooltip: true,
|
|
|
+ minWidth: 120,
|
|
|
+ formatter: (_row, _column, cellValue) => {
|
|
|
+ return _row.code? '已推送' : '未推送';
|
|
|
+ }
|
|
|
+ },
|
|
|
{
|
|
|
prop: 'isEnabled',
|
|
|
align: 'center',
|
|
|
@@ -461,6 +481,15 @@
|
|
|
};
|
|
|
},
|
|
|
methods: {
|
|
|
+ allPushBtn() {
|
|
|
+ const dataId = this.selection.map((v) => v.id);
|
|
|
+ employeePush(dataId).then((res) => {
|
|
|
+ this.$message.success('推送成功!');
|
|
|
+ this.reload();
|
|
|
+ }).catch(() => {
|
|
|
+ console.log('推送失败!');
|
|
|
+ });
|
|
|
+ },
|
|
|
async addUsers(row) {
|
|
|
// this.userRow = null;
|
|
|
this.currentRow = row;
|