Merge remote-tracking branch 'origin/master'
This commit is contained in:
@@ -31,3 +31,6 @@ VITE_APP_SUB_jeecg-app-1 = '//localhost:8092'
|
||||
|
||||
# 在线文档编辑版本。可选属性:wps, onlyoffice
|
||||
VITE_GLOB_ONLINE_DOCUMENT_VERSION=wps
|
||||
|
||||
# AutoLogin SSO - 指向 demo 网关
|
||||
VITE_AUTOLOGIN_URL=http://localhost:9100/api/sys/autoLogin
|
||||
|
||||
@@ -32,3 +32,6 @@ VITE_GLOB_API_URL_PREFIX=
|
||||
|
||||
# 在线文档编辑版本。可选属性:wps, onlyoffice
|
||||
VITE_GLOB_ONLINE_DOCUMENT_VERSION=wps
|
||||
|
||||
# AutoLogin SSO - 指向生产网关(地址由运维提供)
|
||||
VITE_AUTOLOGIN_URL=http://200.100.65.101:9100/api/sys/autoLogin
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
import { defHttp } from '/@/utils/http/axios';
|
||||
|
||||
enum AutoLoginApi {
|
||||
AutoLogin = '/sys/autoLogin',
|
||||
IpAutoLogin = '/sys/ipAutoLogin',
|
||||
}
|
||||
|
||||
/** 自动登录 — 请求网关地址(由 VITE_AUTOLOGIN_URL 控制),form 表单格式 */
|
||||
export function autoLoginApi() {
|
||||
const url = import.meta.env.VITE_AUTOLOGIN_URL || AutoLoginApi.AutoLogin;
|
||||
return defHttp.post({
|
||||
url,
|
||||
data: 'username=&password=',
|
||||
headers: { 'Content-Type': 'application/x-www-form-urlencoded' },
|
||||
});
|
||||
}
|
||||
@@ -0,0 +1,158 @@
|
||||
<template>
|
||||
<div>
|
||||
<a-row class="j-select-row" type="flex" :gutter="8">
|
||||
<a-col class="left">
|
||||
<a-select
|
||||
:value="selectDisplayValue"
|
||||
:placeholder="'请选择人员'"
|
||||
:disabled="disabled"
|
||||
:open="false"
|
||||
mode="multiple"
|
||||
:maxTagCount="3"
|
||||
style="width: 100%"
|
||||
/>
|
||||
</a-col>
|
||||
<a-col class="right">
|
||||
<a-button type="primary" @click="openModal()" :disabled="disabled">选择</a-button>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-modal
|
||||
:width="1200"
|
||||
title="选择人员"
|
||||
v-model:open="visible"
|
||||
centered
|
||||
:confirm-loading="confirmLoading"
|
||||
@ok="handleOk"
|
||||
@cancel="handleCancel"
|
||||
:mask-closable="false"
|
||||
>
|
||||
<SzDeptUserSelect
|
||||
:checkedUser="tempSelectedUsers"
|
||||
@update:checkedUser="handleTempUsersChange"
|
||||
:secLevel="secLevel"
|
||||
:departId="innerDepartId"
|
||||
:role="role"
|
||||
:isSpecial="isSpecial"
|
||||
:multi="multi"
|
||||
/>
|
||||
<template #footer>
|
||||
<a-button @click="handleCancel">取消</a-button>
|
||||
<a-button type="primary" :loading="confirmLoading" @click="handleOk">确定</a-button>
|
||||
</template>
|
||||
</a-modal>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { ref, computed, watch } from 'vue';
|
||||
import { defHttp } from '/@/utils/http/axios';
|
||||
import { useUserStore } from '/@/store/modules/user';
|
||||
import SzDeptUserSelect from './SzDeptUserSelect.vue';
|
||||
import SzDeptUserSelectedList from './SzDeptUserSelectedList.vue';
|
||||
import type { UserItem } from './types';
|
||||
|
||||
const props = withDefaults(
|
||||
defineProps<{
|
||||
value?: string;
|
||||
departId?: string;
|
||||
secLevel?: any;
|
||||
role?: string | number;
|
||||
isSpecial?: number;
|
||||
disabled?: boolean;
|
||||
multi?: boolean;
|
||||
}>(),
|
||||
{
|
||||
value: '',
|
||||
departId: '',
|
||||
secLevel: 0,
|
||||
role: 1,
|
||||
isSpecial: 0,
|
||||
disabled: false,
|
||||
multi: true,
|
||||
}
|
||||
);
|
||||
|
||||
const emit = defineEmits(['update:value', 'change']);
|
||||
|
||||
const userStore = useUserStore();
|
||||
const visible = ref(false);
|
||||
const confirmLoading = ref(false);
|
||||
const innerSelectedUsers = ref<UserItem[]>([]);
|
||||
const tempSelectedUsers = ref<UserItem[]>([]);
|
||||
|
||||
const innerDepartId = computed(() => {
|
||||
return props.departId || userStore.getUserInfo?.orgCode || '';
|
||||
});
|
||||
|
||||
const selectDisplayValue = computed(() => {
|
||||
return innerSelectedUsers.value.map((u) => u.realname);
|
||||
});
|
||||
|
||||
watch(
|
||||
() => props.value,
|
||||
(newVal) => {
|
||||
if (newVal) {
|
||||
loadUsersByUsernames(newVal);
|
||||
} else {
|
||||
innerSelectedUsers.value = [];
|
||||
}
|
||||
},
|
||||
{ immediate: true }
|
||||
);
|
||||
|
||||
async function loadUsersByUsernames(usernames: string) {
|
||||
try {
|
||||
const res: any = await defHttp.get({
|
||||
url: '/sys/user/queryUserComponentData',
|
||||
params: { username: usernames, isMultiTranslate: 'true', pageNo: 1, pageSize: 9999 },
|
||||
});
|
||||
innerSelectedUsers.value = [...(res.records || res)];
|
||||
} catch {
|
||||
innerSelectedUsers.value = [];
|
||||
}
|
||||
}
|
||||
|
||||
function openModal() {
|
||||
if (props.disabled) return;
|
||||
tempSelectedUsers.value = [...innerSelectedUsers.value];
|
||||
visible.value = true;
|
||||
}
|
||||
|
||||
function handleTempUsersChange(users: UserItem[]) {
|
||||
tempSelectedUsers.value = [...users];
|
||||
}
|
||||
|
||||
function clearTemp() {
|
||||
tempSelectedUsers.value = [];
|
||||
}
|
||||
|
||||
function handleOk() {
|
||||
innerSelectedUsers.value = [...tempSelectedUsers.value];
|
||||
const usernames = innerSelectedUsers.value.map((u) => u.username).join(',');
|
||||
emit('update:value', usernames);
|
||||
emit('change', usernames);
|
||||
visible.value = false;
|
||||
}
|
||||
|
||||
function handleCancel() {
|
||||
visible.value = false;
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.j-select-row {
|
||||
@width: 82px;
|
||||
|
||||
.left {
|
||||
width: calc(100% - @width - 8px);
|
||||
}
|
||||
|
||||
.right {
|
||||
width: @width;
|
||||
}
|
||||
|
||||
:deep(.ant-select-search__field) {
|
||||
display: none !important;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,389 @@
|
||||
<template>
|
||||
<a-row :gutter="0" style="height: 556px">
|
||||
<!-- 部门树 -->
|
||||
<a-col :span="6" style="height: 100%; border-right: 1px solid #e8e8e8; padding: 0 12px; display: flex; flex-direction: column">
|
||||
<a-input-search v-model:value="searchDepartValue" style="margin-bottom: 12px; margin-top: 0" placeholder="请输入部门名称" />
|
||||
<a-directory-tree
|
||||
selectable
|
||||
v-model:selectedKeys="selectedDepIds"
|
||||
:check-strictly="true"
|
||||
:dropdown-style="{ maxHeight: '200px', overflow: 'auto' }"
|
||||
:tree-data="filterDepartTreeData"
|
||||
:expand-action="false"
|
||||
v-model:expandedKeys="expandedKeys"
|
||||
@select="onDepSelect"
|
||||
style="height: 500px; overflow: auto"
|
||||
/>
|
||||
</a-col>
|
||||
<!-- 人员表格 -->
|
||||
<a-col :span="10" style="height: 100%; padding: 0 12px; border-right: 1px solid #e8e8e8; display: flex; flex-direction: column">
|
||||
<div style="margin-bottom: 12px; margin-top: 0; display: flex; align-items: center; gap: 8px; flex-wrap: wrap">
|
||||
<a-input-search
|
||||
style="flex: 1; min-width: 120px"
|
||||
placeholder="输入姓名"
|
||||
v-model:value="queryParam.realname"
|
||||
@search="onSearch"
|
||||
/>
|
||||
<a-button @click="searchReset(1)">重置</a-button>
|
||||
<a-button type="primary" @click="selectAll">全选</a-button>
|
||||
<a-button type="danger" @click="unselectAll">清空</a-button>
|
||||
</div>
|
||||
<div style="flex: 1; min-height: 0; overflow: auto">
|
||||
<a-empty v-if="selectedDepIds.length === 0" description="请先选择部门!" />
|
||||
<a-table
|
||||
v-else
|
||||
:scroll="{ y: 430 }"
|
||||
size="middle"
|
||||
row-key="id"
|
||||
:columns="columns"
|
||||
:data-source="dataSource"
|
||||
:pagination="ipagination"
|
||||
:row-selection="{ selectedRowKeys: selectedRowKeys, onSelectAll: onSelectAll, onSelect: onSelect, type: getType }"
|
||||
:loading="loading"
|
||||
@change="handleTableChange"
|
||||
:custom-row="customRow"
|
||||
/>
|
||||
</div>
|
||||
</a-col>
|
||||
<!-- 已选列表 -->
|
||||
<a-col :span="8" style="height: 100%; padding: 0 12px; display: flex; flex-direction: column">
|
||||
<div style="margin-bottom: 12px; margin-top: 0; display: flex; align-items: center; gap: 8px; flex-wrap: wrap">
|
||||
<span style="font-weight: 500">已选 ({{ selectedRows.length }})</span>
|
||||
<a-button type="danger" @click="clearSelected">清空</a-button>
|
||||
</div>
|
||||
<div style="flex: 1; overflow: auto; min-height: 0">
|
||||
<SzDeptUserSelectedList
|
||||
:selectedUsers="selectedRows"
|
||||
@update:selectedUsers="(users) => emit('update:checkedUser', users)"
|
||||
/>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { ref, reactive, computed, watch, onMounted } from 'vue';
|
||||
import { queryTreeList } from '/@/api/common/api';
|
||||
import { defHttp } from '/@/utils/http/axios';
|
||||
import { filterObj } from '/@/utils/common/compUtils';
|
||||
import { deleteIfExist, pushIfNotExist, filterDepartTree, recurTree } from './types';
|
||||
import type { UserItem, DepartTreeNode } from './types';
|
||||
import SzDeptUserSelectedList from './SzDeptUserSelectedList.vue';
|
||||
|
||||
const props = withDefaults(
|
||||
defineProps<{
|
||||
secLevel: any;
|
||||
checkedUser?: UserItem[];
|
||||
departId: string;
|
||||
role: string | number;
|
||||
isSpecial?: number;
|
||||
multi?: boolean;
|
||||
}>(),
|
||||
{
|
||||
checkedUser: () => [],
|
||||
isSpecial: 0,
|
||||
multi: true,
|
||||
}
|
||||
);
|
||||
|
||||
const emit = defineEmits(['update:checkedUser']);
|
||||
|
||||
const searchDepartValue = ref('');
|
||||
const queryParam = reactive<Record<string, any>>({ realname: '' });
|
||||
const dataSource = ref<UserItem[]>([]);
|
||||
const allUserList = ref<UserItem[]>([]);
|
||||
const selectedDepIds = ref<string[]>([]);
|
||||
const selectedRows = ref<UserItem[]>([]);
|
||||
const departTree = ref<DepartTreeNode[]>([]);
|
||||
const fullDepartTree = ref<DepartTreeNode[]>([]);
|
||||
const loading = ref(false);
|
||||
const expandedKeys = ref<string[]>([]);
|
||||
|
||||
function findDepartIdByOrgCode(tree: DepartTreeNode[], orgCode: string): string | null {
|
||||
for (const node of tree) {
|
||||
if (node.orgCode === orgCode) {
|
||||
return node.id;
|
||||
}
|
||||
if (node.children && node.children.length > 0) {
|
||||
const found = findDepartIdByOrgCode(node.children, orgCode);
|
||||
if (found) return found;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
function resolveDepartId(departIdOrOrgCode: string): string {
|
||||
if (!departIdOrOrgCode) return departIdOrOrgCode;
|
||||
const uuidPattern = /^[0-9a-f]{32}$/i;
|
||||
if (uuidPattern.test(departIdOrOrgCode.replace(/-/g, ''))) return departIdOrOrgCode;
|
||||
const realId = findDepartIdByOrgCode(fullDepartTree.value, departIdOrOrgCode);
|
||||
if (realId) return realId;
|
||||
return departIdOrOrgCode;
|
||||
}
|
||||
|
||||
const columns = [
|
||||
{ title: '用户姓名', align: 'center' as const, dataIndex: 'realname' },
|
||||
{ title: '人员密级', align: 'center' as const, dataIndex: 'userSecurityLevel_dictText' },
|
||||
];
|
||||
|
||||
const ipagination = reactive({
|
||||
current: 1,
|
||||
pageSize: 7,
|
||||
showQuickJumper: true,
|
||||
total: 0,
|
||||
});
|
||||
|
||||
const isorter = reactive({
|
||||
column: 'createTime',
|
||||
order: 'desc',
|
||||
});
|
||||
|
||||
const url = {
|
||||
pageUserDepart: '/sys/user/queryUserComponentData',
|
||||
listUserDepart: '/sys/user/queryUserComponentData',
|
||||
};
|
||||
|
||||
const getType = computed(() => (props.multi ? 'checkbox' : 'radio'));
|
||||
const selectedRowKeys = computed(() => selectedRows.value.map((item) => item.id));
|
||||
|
||||
const filterDepartTreeData = computed(() => {
|
||||
if (!searchDepartValue.value) return departTree.value;
|
||||
return filterDepartTree(departTree.value, searchDepartValue.value);
|
||||
});
|
||||
|
||||
watch(
|
||||
() => props.checkedUser,
|
||||
() => {
|
||||
selectedRows.value = [...(props.checkedUser || [])];
|
||||
}
|
||||
);
|
||||
|
||||
watch(
|
||||
() => props.departId,
|
||||
() => {
|
||||
queryDepartTree();
|
||||
},
|
||||
{ immediate: true }
|
||||
);
|
||||
|
||||
watch(
|
||||
() => props.role,
|
||||
() => {
|
||||
queryDepartTree();
|
||||
}
|
||||
);
|
||||
|
||||
watch(
|
||||
() => props.secLevel,
|
||||
() => {
|
||||
if (selectedDepIds.value.length > 0) {
|
||||
getAllUsersInDepart();
|
||||
loadData();
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
function initData() {
|
||||
const depId = props.departId;
|
||||
if (depId) {
|
||||
const resolvedId = resolveDepartId(depId);
|
||||
selectedDepIds.value = [resolvedId];
|
||||
getAllUsersInDepart();
|
||||
loadData();
|
||||
}
|
||||
if (props.checkedUser) {
|
||||
selectedRows.value = [...props.checkedUser];
|
||||
}
|
||||
}
|
||||
|
||||
async function loadData(arg?: number) {
|
||||
if (selectedDepIds.value.length > 0) {
|
||||
if (arg === 1) {
|
||||
ipagination.current = 1;
|
||||
}
|
||||
const params = getQueryParams();
|
||||
loading.value = true;
|
||||
try {
|
||||
const res: any = await defHttp.get({ url: url.pageUserDepart, params });
|
||||
dataSource.value = (res.records || []).filter((user: UserItem) => {
|
||||
const userLevel = user.userSecurityLevel;
|
||||
const docLevel = props.secLevel;
|
||||
return userLevel !== null && userLevel > docLevel;
|
||||
});
|
||||
ipagination.total = res.total;
|
||||
} finally {
|
||||
loading.value = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function getQueryParams() {
|
||||
const param = Object.assign({}, queryParam, isorter);
|
||||
param.searchSecurityLevel = props.secLevel;
|
||||
param.field = getQueryField();
|
||||
param.pageNo = ipagination.current;
|
||||
param.pageSize = ipagination.pageSize;
|
||||
param.departId = selectedDepIds.value.join(',');
|
||||
param.isSpecial = props.isSpecial;
|
||||
return filterObj(param);
|
||||
}
|
||||
|
||||
function getQueryField() {
|
||||
let str = 'id,';
|
||||
for (let a = 0; a < columns.length; a++) {
|
||||
str += ',' + columns[a].dataIndex;
|
||||
}
|
||||
return str;
|
||||
}
|
||||
|
||||
function searchReset(num?: number) {
|
||||
if (num !== 0) {
|
||||
queryParam.realname = '';
|
||||
loadData(1);
|
||||
}
|
||||
}
|
||||
|
||||
function handleTableChange(pagination: any, _filters: any, sorter: any) {
|
||||
if (Object.keys(sorter).length > 0) {
|
||||
isorter.column = sorter.field;
|
||||
isorter.order = sorter.order === 'ascend' ? 'asc' : 'desc';
|
||||
}
|
||||
Object.assign(ipagination, pagination);
|
||||
loadData();
|
||||
}
|
||||
|
||||
async function getAllUsersInDepart() {
|
||||
if (selectedDepIds.value.length === 0 || (selectedDepIds.value.length === 1 && !selectedDepIds.value[0])) {
|
||||
allUserList.value = [];
|
||||
return;
|
||||
}
|
||||
const param = Object.assign({}, queryParam);
|
||||
param.searchSecurityLevel = props.secLevel;
|
||||
param.field = getQueryField();
|
||||
param.departId = selectedDepIds.value.join(',');
|
||||
param.isSpecial = props.isSpecial;
|
||||
param.pageNo = 1;
|
||||
param.pageSize = 9999;
|
||||
const filteredParam = filterObj(param);
|
||||
try {
|
||||
const res: any = await defHttp.get({ url: url.listUserDepart, params: filteredParam });
|
||||
allUserList.value = (res.records || res).filter((user: UserItem) => {
|
||||
const userLevel = user.userSecurityLevel;
|
||||
const docLevel = props.secLevel;
|
||||
return userLevel !== null && userLevel > docLevel;
|
||||
});
|
||||
} catch (e) {
|
||||
allUserList.value = [];
|
||||
}
|
||||
}
|
||||
|
||||
function onDepSelect(keys: string[]) {
|
||||
if (keys.length > 0 && keys[0] != null) {
|
||||
selectedDepIds.value = [keys[0]];
|
||||
loadData(1);
|
||||
getAllUsersInDepart();
|
||||
}
|
||||
}
|
||||
|
||||
function onSelect(record: UserItem, selected: boolean) {
|
||||
if (selected) {
|
||||
pushIfNotExist(selectedRows.value, record, 'id');
|
||||
} else {
|
||||
deleteIfExist(selectedRows.value, record, 'id');
|
||||
}
|
||||
selectedRows.value.sort((a, b) => (a.sortno || 0) - (b.sortno || 0));
|
||||
emit('update:checkedUser', selectedRows.value);
|
||||
}
|
||||
|
||||
function onSelectAll(selected: boolean, selectedRecords: UserItem[], changeRecords: UserItem[]) {
|
||||
if (selected) {
|
||||
selectedRecords.forEach((item) => {
|
||||
pushIfNotExist(selectedRows.value, item, 'id');
|
||||
});
|
||||
} else {
|
||||
const rowsToRemove = changeRecords && changeRecords.length > 0 ? changeRecords : dataSource.value;
|
||||
rowsToRemove.forEach((item) => {
|
||||
deleteIfExist(selectedRows.value, item, 'id');
|
||||
});
|
||||
}
|
||||
selectedRows.value.sort((a, b) => (a.sortno || 0) - (b.sortno || 0));
|
||||
emit('update:checkedUser', selectedRows.value);
|
||||
}
|
||||
|
||||
function onSearch() {
|
||||
loadData(1);
|
||||
}
|
||||
|
||||
async function queryDepartTree() {
|
||||
expandedKeys.value = [];
|
||||
departTree.value = [];
|
||||
try {
|
||||
const res: any = await queryTreeList();
|
||||
const arr = [...res];
|
||||
fullDepartTree.value = [...arr];
|
||||
|
||||
if (props.role === 1 || props.role === '1') {
|
||||
departTree.value = [...arr];
|
||||
} else {
|
||||
const resolvedDepartId = resolveDepartId(props.departId);
|
||||
const tree = recurTree(arr, (node) => {
|
||||
if (node.id === resolvedDepartId) return [node];
|
||||
return [];
|
||||
});
|
||||
departTree.value = [...tree];
|
||||
}
|
||||
departTree.value.forEach((item) => {
|
||||
expandedKeys.value.push(item.key);
|
||||
});
|
||||
await initData();
|
||||
} catch (e) {
|
||||
console.error('queryDepartTree error:', e);
|
||||
}
|
||||
}
|
||||
|
||||
function selectAll() {
|
||||
allUserList.value.forEach((item) => {
|
||||
pushIfNotExist(selectedRows.value, item, 'id');
|
||||
});
|
||||
selectedRows.value.sort((a, b) => (a.sortno || 0) - (b.sortno || 0));
|
||||
emit('update:checkedUser', selectedRows.value);
|
||||
}
|
||||
|
||||
function unselectAll() {
|
||||
allUserList.value.forEach((item) => {
|
||||
deleteIfExist(selectedRows.value, item, 'id');
|
||||
});
|
||||
emit('update:checkedUser', selectedRows.value);
|
||||
}
|
||||
|
||||
function clearSelected() {
|
||||
selectedRows.value = [];
|
||||
emit('update:checkedUser', selectedRows.value);
|
||||
}
|
||||
|
||||
function customRow(record: UserItem) {
|
||||
return {
|
||||
onClick: (_event: Event) => {
|
||||
const clickRowKey = record.id;
|
||||
if (selectedRowKeys.value.includes(clickRowKey)) {
|
||||
deleteIfExist(selectedRows.value, record, 'id');
|
||||
} else {
|
||||
pushIfNotExist(selectedRows.value, record, 'id');
|
||||
}
|
||||
selectedRows.value.sort((a, b) => (a.sortno || 0) - (b.sortno || 0));
|
||||
emit('update:checkedUser', selectedRows.value);
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
onMounted(async () => {
|
||||
await queryDepartTree();
|
||||
});
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.ant-table-tbody .ant-table-row td {
|
||||
padding-top: 10px;
|
||||
padding-bottom: 10px;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,55 @@
|
||||
<template>
|
||||
<div style="margin-left: 1px">
|
||||
<a-empty v-if="selectedUsers.length === 0" />
|
||||
<div v-else>
|
||||
<a-button-group
|
||||
v-for="(user, index) in selectedUsers"
|
||||
:key="'user-' + user.id + '-' + index"
|
||||
class="small-space"
|
||||
>
|
||||
<a-button class="btn-green" size="small">
|
||||
<UserOutlined />
|
||||
{{ user.realname }}
|
||||
</a-button>
|
||||
<a-button v-if="!disabled" class="btn-green" size="small" @click="deleteUser(index)">
|
||||
<CloseOutlined />
|
||||
</a-button>
|
||||
</a-button-group>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { UserOutlined, CloseOutlined } from '@ant-design/icons-vue';
|
||||
import type { UserItem } from './types';
|
||||
|
||||
const props = withDefaults(
|
||||
defineProps<{
|
||||
disabled?: boolean;
|
||||
selectedUsers: UserItem[];
|
||||
}>(),
|
||||
{
|
||||
disabled: false,
|
||||
selectedUsers: () => [],
|
||||
}
|
||||
);
|
||||
|
||||
const emit = defineEmits(['update:selectedUsers']);
|
||||
|
||||
function deleteUser(index: number) {
|
||||
const arr = [...props.selectedUsers];
|
||||
arr.splice(index, 1);
|
||||
emit('update:selectedUsers', arr);
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.small-space {
|
||||
margin: 2px;
|
||||
}
|
||||
.btn-green {
|
||||
background-color: #52c41a;
|
||||
color: #fff;
|
||||
border-color: #52c41a;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,68 @@
|
||||
export interface UserItem {
|
||||
id: string;
|
||||
username: string;
|
||||
realname: string;
|
||||
orgCodeTxt?: string;
|
||||
userSecurityLevel?: number;
|
||||
userSecurityLevel_dictText?: string;
|
||||
sex_dictText?: string;
|
||||
sortno?: number;
|
||||
departId?: string;
|
||||
departName?: string;
|
||||
}
|
||||
|
||||
export interface DepartTreeNode {
|
||||
id: string;
|
||||
key: string;
|
||||
value: string;
|
||||
title: string;
|
||||
isLeaf?: boolean;
|
||||
departType?: string | number;
|
||||
distributable?: number;
|
||||
disableCheckbox?: boolean;
|
||||
children?: DepartTreeNode[];
|
||||
description?: string;
|
||||
parentId?: string;
|
||||
orgCode?: string;
|
||||
}
|
||||
|
||||
export function deleteIfExist<T extends Record<string, any>>(array: T[], value: T, key: string): void {
|
||||
const idx = array.findIndex((item) => item[key] === value[key]);
|
||||
if (idx >= 0) {
|
||||
array.splice(idx, 1);
|
||||
}
|
||||
}
|
||||
|
||||
export function pushIfNotExist<T extends Record<string, any>>(array: T[], value: T, key: string): void {
|
||||
const idx = array.findIndex((item) => item[key] === value[key]);
|
||||
if (idx < 0) {
|
||||
array.push(value);
|
||||
}
|
||||
}
|
||||
|
||||
export function filterDepartTree<T extends Record<string, any>>(departTree: T[], searchValue: string): T[] {
|
||||
let filtered: T[] = [];
|
||||
departTree.forEach((item) => {
|
||||
if (item.title && item.title.includes(searchValue)) {
|
||||
filtered.push(Object.assign({}, item, { children: null, isLeaf: true }));
|
||||
}
|
||||
if (item.children) {
|
||||
const result = filterDepartTree(item.children, searchValue);
|
||||
if (result.length > 0) {
|
||||
filtered = filtered.concat(result);
|
||||
}
|
||||
}
|
||||
});
|
||||
return filtered;
|
||||
}
|
||||
|
||||
export function recurTree<T extends Record<string, any>, R>(tree: T[], callback: (node: T) => R[]): R[] {
|
||||
let res: R[] = [];
|
||||
tree.forEach((item) => {
|
||||
res = res.concat(callback(item));
|
||||
if (item.children) {
|
||||
res = res.concat(recurTree(item.children, callback));
|
||||
}
|
||||
});
|
||||
return res;
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
export enum PageEnum {
|
||||
// basic login path
|
||||
BASE_LOGIN = '/login',
|
||||
BASE_LOGIN = '/user/login',
|
||||
// basic home path
|
||||
BASE_HOME = '/dashboard/analysis',
|
||||
// error page path
|
||||
@@ -12,5 +12,9 @@ export enum PageEnum {
|
||||
//文件路由
|
||||
SYS_FILES_PATH = '/file/share',
|
||||
// 邮件中的跳转地址
|
||||
TOKEN_LOGIN = '/tokenLogin'
|
||||
TOKEN_LOGIN = '/tokenLogin',
|
||||
// 自动登录路径
|
||||
AUTOLOGIN_PATH = '/user/autoLogin',
|
||||
// 登出结果页路径
|
||||
LOGOUT_RESULT_PATH = '/user/logoutResult',
|
||||
}
|
||||
|
||||
@@ -28,7 +28,7 @@ const ROOT_PATH = RootRoute.path;
|
||||
|
||||
//update-begin---author:wangshuai ---date:20220629 for:[issues/I5BG1I]vue3不支持auth2登录------------
|
||||
//update-begin---author:wangshuai ---date:20221111 for: [VUEN-2472]分享免登录------------
|
||||
const whitePathList: PageEnum[] = [LOGIN_PATH, OAUTH2_LOGIN_PAGE_PATH,SYS_FILES_PATH, TOKEN_LOGIN ];
|
||||
const whitePathList: PageEnum[] = [LOGIN_PATH, OAUTH2_LOGIN_PAGE_PATH,SYS_FILES_PATH, TOKEN_LOGIN, PageEnum.AUTOLOGIN_PATH, PageEnum.LOGOUT_RESULT_PATH ];
|
||||
//update-end---author:wangshuai ---date:20221111 for: [VUEN-2472]分享免登录------------
|
||||
//update-end---author:wangshuai ---date:20220629 for:[issues/I5BG1I]vue3不支持auth2登录------------
|
||||
|
||||
@@ -57,7 +57,7 @@ export function createPermissionGuard(router: Router) {
|
||||
|
||||
// Whitelist can be directly entered
|
||||
if (whitePathList.includes(to.path as PageEnum)) {
|
||||
if (to.path === LOGIN_PATH && token) {
|
||||
if ((to.path === LOGIN_PATH || to.path === PageEnum.AUTOLOGIN_PATH) && token) {
|
||||
const isSessionTimeout = userStore.getSessionTimeout;
|
||||
|
||||
//update-begin---author:scott ---date:2023-04-24 for:【QQYUN-4713】登录代码调整逻辑有问题,改造待观察--
|
||||
@@ -122,7 +122,7 @@ export function createPermissionGuard(router: Router) {
|
||||
//---------【首次登陆并且是企业微信或者钉钉的情况下才会调用】------------------------------------------------
|
||||
//update-end---author:wangshuai ---date:20230302 for:只有首次登陆并且是企业微信或者钉钉的情况下才会调用------------
|
||||
// 如果当前是在OAuth2APP环境,就跳转到OAuth2登录页面,否则跳转到登录页面
|
||||
path = isOAuth2AppEnv() ? OAUTH2_LOGIN_PAGE_PATH : LOGIN_PATH;
|
||||
path = isOAuth2AppEnv() ? OAUTH2_LOGIN_PAGE_PATH : PageEnum.AUTOLOGIN_PATH;
|
||||
}
|
||||
//update-end---author:wangshuai ---date:20220629 for:[issues/I5BG1I]vue3 Auth2未实现------------
|
||||
// redirect login page
|
||||
|
||||
@@ -29,7 +29,7 @@ export const RootRoute: AppRouteRecordRaw = {
|
||||
};
|
||||
|
||||
export const LoginRoute: AppRouteRecordRaw = {
|
||||
path: '/login',
|
||||
path: '/user/login',
|
||||
name: 'Login',
|
||||
//新版后台登录,如果想要使用旧版登录放开即可
|
||||
// component: () => import('/@/views/sys/login/Login.vue'),
|
||||
@@ -65,6 +65,26 @@ export const TokenLoginRoute: AppRouteRecordRaw = {
|
||||
},
|
||||
};
|
||||
// update-begin--author:liaozhiyang---date:20240301---for:【QQYUN-7967】新增、编辑路由访问
|
||||
export const AutoLoginRoute: AppRouteRecordRaw = {
|
||||
path: '/user/autoLogin',
|
||||
name: 'AutoLogin',
|
||||
component: () => import('/@/views/sys/login/AutoLogin.vue'),
|
||||
meta: {
|
||||
title: '自动登录',
|
||||
ignoreAuth: true,
|
||||
},
|
||||
};
|
||||
|
||||
export const LogoutResultRoute: AppRouteRecordRaw = {
|
||||
path: '/user/logoutResult',
|
||||
name: 'LogoutResult',
|
||||
component: () => import('/@/views/sys/login/LogoutResult.vue'),
|
||||
meta: {
|
||||
title: '退出登录',
|
||||
ignoreAuth: true,
|
||||
},
|
||||
};
|
||||
|
||||
export const formUrlDetail = {
|
||||
path: '/online/formUrlDetail/:id/:dataId',
|
||||
name: 'formUrlDetail',
|
||||
@@ -107,4 +127,4 @@ export const formUrlSuccess = {
|
||||
// update-end--author:liaozhiyang---date:20240301---for:【QQYUN-7967】新增、编辑路由访问
|
||||
|
||||
// Basic routing without permission
|
||||
export const basicRoutes = [LoginRoute, RootRoute, ...mainOutRoutes, REDIRECT_ROUTE, PAGE_NOT_FOUND_ROUTE, TokenLoginRoute, Oauth2LoginRoute,formUrlDetail, formUrlAdd, formUrlEdit, formUrlSuccess];
|
||||
export const basicRoutes = [LoginRoute, RootRoute, ...mainOutRoutes, REDIRECT_ROUTE, PAGE_NOT_FOUND_ROUTE, TokenLoginRoute, Oauth2LoginRoute, AutoLoginRoute, LogoutResultRoute,formUrlDetail, formUrlAdd, formUrlEdit, formUrlSuccess];
|
||||
|
||||
@@ -8,6 +8,7 @@ import { ROLES_KEY, TOKEN_KEY, USER_INFO_KEY, LOGIN_INFO_KEY, DB_DICT_DATA_KEY,
|
||||
import { getAuthCache, setAuthCache, removeAuthCache } from '/@/utils/auth';
|
||||
import { GetUserInfoModel, LoginParams, ThirdLoginParams } from '/@/api/sys/model/userModel';
|
||||
import { doLogout, getUserInfo, loginApi, phoneLoginApi, thirdLogin } from '/@/api/sys/user';
|
||||
import { autoLoginApi } from '/@/api/sys/autologin';
|
||||
import { useI18n } from '/@/hooks/web/useI18n';
|
||||
import { useMessage } from '/@/hooks/web/useMessage';
|
||||
import { router } from '/@/router';
|
||||
@@ -161,6 +162,20 @@ export const useUserStore = defineStore({
|
||||
return Promise.reject(error);
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 网关自动登录 — 跳过密码,由网关注入身份
|
||||
*/
|
||||
async autoLogin(goHome = true): Promise<GetUserInfoModel | null> {
|
||||
try {
|
||||
const data = await autoLoginApi();
|
||||
const { token, userInfo } = data;
|
||||
this.setToken(token);
|
||||
this.setTenant(userInfo.loginTenantId);
|
||||
return this.afterLoginAction(goHome, data);
|
||||
} catch (error) {
|
||||
return Promise.reject(error);
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 扫码登录事件
|
||||
*/
|
||||
@@ -330,7 +345,7 @@ export const useUserStore = defineStore({
|
||||
}else{
|
||||
// update-begin-author:sunjianlei date:20230306 for: 修复登录成功后,没有正确重定向的问题
|
||||
goLogin && (await router.push({
|
||||
path: PageEnum.BASE_LOGIN,
|
||||
path: PageEnum.LOGOUT_RESULT_PATH,
|
||||
query: {
|
||||
// 传入当前的路由,登录成功后跳转到当前路由
|
||||
redirect: router.currentRoute.value.fullPath,
|
||||
|
||||
@@ -184,13 +184,10 @@
|
||||
</a-col>
|
||||
<a-col v-if="showSubApproveUserSelector" :span="12">
|
||||
<a-form-item label="部门经办人" :labelCol="wideLabelCol" :wrapperCol="wideWrapperCol">
|
||||
|
||||
<j-select-user
|
||||
v-model:value="subApproveUser"
|
||||
:disabled="savingSubApproveUser"
|
||||
allow-clear
|
||||
/>
|
||||
|
||||
<sz-dept-user-modal
|
||||
v-model:value="subApproveUser"
|
||||
:disabled="savingSubApproveUser"
|
||||
/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<!-- <a-col :span="24">-->
|
||||
@@ -226,7 +223,7 @@
|
||||
import JDictSelectTag from "../../../../components/Form/src/jeecg/components/JDictSelectTag.vue";
|
||||
import BgPartymatterBPMFeedbackModal from './BgPartymatterBPMFeedbackModal.vue';
|
||||
import SUploadFile from '/@/components/semri/fileComponent/SUploadFile.vue';
|
||||
import JSelectUser from "../../../../components/Form/src/jeecg/components/JSelectUser.vue";
|
||||
import SzDeptUserModal from '/@/components/semri/deptUserComponent/SzDeptUserModal.vue';
|
||||
const { isDisabledAuth, hasPermission, initBpmFormData} = usePermission();
|
||||
|
||||
const props = defineProps({
|
||||
|
||||
@@ -262,6 +262,7 @@
|
||||
:claim="claim"
|
||||
:showSelnextUser="showSelnextUser"
|
||||
:beforeHandle="saveMainFormBeforeProcessHandle"
|
||||
:defaultReason="defaultHandleReason"
|
||||
@success="handleProcessSuccess"
|
||||
@claimSuccess="handleClaimSuccess"
|
||||
/>
|
||||
@@ -441,6 +442,59 @@
|
||||
processTableName: props.formData?.processTableName,
|
||||
}));
|
||||
|
||||
// ==================== 默认审批意见 ====================
|
||||
const handleReasonTemplateMap: Record<string, () => string> = {
|
||||
// TODO: 填写各节点的 taskDefKey
|
||||
// 部门负责人审批 / 所党委审批 / 督办部门负责人审批 / 纪检负责人审批
|
||||
// 'Task_': buildApproveReason,
|
||||
// 部门经办人反馈完成情况 / 收集流程部门经办人填写 / 反馈流程部门经办人填写反馈
|
||||
// 'Task_': buildDeptHandlerFeedbackReason,
|
||||
// 部门负责人接受任务并分配
|
||||
// 'Task_': buildDeptLeaderAssignReason,
|
||||
// 部门负责人直接反馈
|
||||
// 'Task_': buildDeptLeaderDirectFeedbackReason,
|
||||
// 督办部门经办人确认全部反馈事项
|
||||
// 'Task_': buildSuperviseConfirmAllReason,
|
||||
// 督办经办人核查 / 反馈流程督办经办人核查
|
||||
// 'Task_': buildSuperviseCheckReason,
|
||||
// 纪检经办人监察
|
||||
// 'Task_': buildJiJianCheckReason,
|
||||
};
|
||||
|
||||
const defaultHandleReason = computed(() => {
|
||||
const builder = handleReasonTemplateMap[String(processInfo.value.taskDefKey || '')];
|
||||
return builder ? builder() : '';
|
||||
});
|
||||
|
||||
function buildApproveReason() {
|
||||
return '同意。';
|
||||
}
|
||||
|
||||
function buildDeptHandlerFeedbackReason() {
|
||||
return '已完成反馈,请领导审批。';
|
||||
}
|
||||
|
||||
function buildDeptLeaderAssignReason() {
|
||||
const userNameText = subApproveUser.value || '';
|
||||
return userNameText ? `请${userNameText}办理。` : '';
|
||||
}
|
||||
|
||||
function buildDeptLeaderDirectFeedbackReason() {
|
||||
return '已完成反馈。';
|
||||
}
|
||||
|
||||
function buildSuperviseConfirmAllReason() {
|
||||
return '已确认全部反馈事项。';
|
||||
}
|
||||
|
||||
function buildSuperviseCheckReason() {
|
||||
return '已核查。';
|
||||
}
|
||||
|
||||
function buildJiJianCheckReason() {
|
||||
return '已监察。';
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
initFormData();
|
||||
});
|
||||
|
||||
@@ -29,7 +29,12 @@
|
||||
</div>
|
||||
<a-row class="base-info-row" :gutter="[12, 4]">
|
||||
<a-col :span="24">
|
||||
<a-form-item label="具体问题" name="problemId" :labelCol="{ xs: { span: 24 }, sm: { span: 4 } }" :wrapperCol="{ xs: { span: 24 }, sm: { span: 20 } }">
|
||||
<a-form-item
|
||||
label="具体问题"
|
||||
name="problemId"
|
||||
:labelCol="{ xs: { span: 24 }, sm: { span: 4 } }"
|
||||
:wrapperCol="{ xs: { span: 24 }, sm: { span: 20 } }"
|
||||
>
|
||||
<a-tree-select
|
||||
v-model:value="mainForm.problemId"
|
||||
:tree-data="problemTreeData"
|
||||
@@ -43,14 +48,25 @@
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="24">
|
||||
<a-form-item label="整改措施" name="improveMeasure" :labelCol="{ xs: { span: 24 }, sm: { span: 4 } }" :wrapperCol="{ xs: { span: 24 }, sm: { span: 20 } }">
|
||||
<a-form-item
|
||||
label="整改措施"
|
||||
name="improveMeasure"
|
||||
:labelCol="{ xs: { span: 24 }, sm: { span: 4 } }"
|
||||
:wrapperCol="{ xs: { span: 24 }, sm: { span: 20 } }"
|
||||
>
|
||||
<a-textarea v-model:value="mainForm.improveMeasure" :auto-size="{ minRows: 1, maxRows: 4 }" :disabled="mainDisabled" allow-clear />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<template v-if="showBaseInfoDetail">
|
||||
<a-col :span="12">
|
||||
<a-form-item label="密级" name="secretLevel">
|
||||
<j-dict-select-tag v-model:value="mainForm.secretLevel" dictCode="secret_level" placeholder="请选择密级" :disabled="mainDisabled" allow-clear />
|
||||
<j-dict-select-tag
|
||||
v-model:value="mainForm.secretLevel"
|
||||
dictCode="secret_level"
|
||||
placeholder="请选择密级"
|
||||
:disabled="mainDisabled"
|
||||
allow-clear
|
||||
/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
@@ -214,6 +230,8 @@
|
||||
:claim="claim"
|
||||
:showSelnextUser="showSelnextUser"
|
||||
:beforeHandle="saveMainFormBeforeProcessHandle"
|
||||
:defaultReason="defaultHandleReason"
|
||||
:defaultCc="defaultCcUsers"
|
||||
@success="handleProcessSuccess"
|
||||
@claimSuccess="handleClaimSuccess"
|
||||
/>
|
||||
@@ -273,6 +291,33 @@
|
||||
const isNeedLeaderApprove = ref(0);
|
||||
const leaderApproveUser = ref('');
|
||||
const savingIsNeedLeaderApprove = ref(false);
|
||||
const defaultCcUsers = ref<Array<{ username: string; realname: string }>>([]);
|
||||
|
||||
const handleReasonTemplateMap: Record<string, () => string> = {
|
||||
Task_0g8sc6n: () => '同意。',
|
||||
Task_0ixi1rs: () => '已收集完成,同意。',
|
||||
Task_0l5ik22: () => '同意。',
|
||||
Task_0mbr735: () => '已完成反馈,请领导审批。',
|
||||
Task_0mxtg05: () => '已审批。',
|
||||
Task_14226iy: () => '已审查。',
|
||||
Task_1c64uvl: () => '请相关部门办理。',
|
||||
Task_1i99s6v: () => '同意。',
|
||||
Task_1nj4k7b: () => '已发起督办流程。',
|
||||
|
||||
Task_09qxoto: () => '纪委书记已审批。',
|
||||
Task_0cfjknn: () => '党委书记已审批。',
|
||||
Task_0r2vutj: () => '责任经办部门已审批。',
|
||||
Task_1azpeqj: () => '纪检经办人已监察。',
|
||||
Task_1cvft2f: () => '党群经办人已确认。',
|
||||
Task_1k1zt37: () => '分管所领导已审批。',
|
||||
Task_1k36lmv: () => '责任部门负责人已审批。',
|
||||
Task_1k6n75g: () => '分配人办理流程。',
|
||||
};
|
||||
|
||||
const defaultHandleReason = computed(() => {
|
||||
const builder = handleReasonTemplateMap[String(processInfo.value.taskDefKey || '')];
|
||||
return builder ? builder() : '';
|
||||
});
|
||||
|
||||
const mainForm = reactive<Record<string, any>>({
|
||||
id: '',
|
||||
@@ -333,33 +378,21 @@
|
||||
if (explicit === '1') return true;
|
||||
return props.formBpm && !!props.formData?.taskId;
|
||||
});
|
||||
const showAddFeedback = computed(
|
||||
() => String(props.formData?.extendUrlParams?.showAddFeedback ?? '') === '1'
|
||||
);
|
||||
const showAddFeedback = computed(() => String(props.formData?.extendUrlParams?.showAddFeedback ?? '') === '1');
|
||||
const showFeedbackInfo = computed(() => {
|
||||
const p = props.formData?.extendUrlParams;
|
||||
const explicit = p?.showFeedbackInfo;
|
||||
if (explicit === '0') return false;
|
||||
if (explicit === '1') return true;
|
||||
return (
|
||||
String(p?.showAddFeedback ?? '') === '1' ||
|
||||
String(p?.showEditFeedback ?? '') === '1' ||
|
||||
String(p?.showDeptFeedback ?? '') === '1'
|
||||
);
|
||||
return String(p?.showAddFeedback ?? '') === '1' || String(p?.showEditFeedback ?? '') === '1' || String(p?.showDeptFeedback ?? '') === '1';
|
||||
});
|
||||
const showEditFeedback = computed(
|
||||
() => String(props.formData?.extendUrlParams?.showEditFeedback ?? '') === '1'
|
||||
);
|
||||
const showDeptFeedback = computed(
|
||||
() => String(props.formData?.extendUrlParams?.showDeptFeedback ?? '') === '1'
|
||||
);
|
||||
const showEditFeedback = computed(() => String(props.formData?.extendUrlParams?.showEditFeedback ?? '') === '1');
|
||||
const showDeptFeedback = computed(() => String(props.formData?.extendUrlParams?.showDeptFeedback ?? '') === '1');
|
||||
const showJiJianFields = computed(() => String(props.formData?.extendUrlParams?.showJiJianFields ?? '') === '1');
|
||||
const jiJianFieldsReadonly = computed(() => String(props.formData?.extendUrlParams?.jiJianFieldsReadonly ?? '') === '1');
|
||||
const nonJiJianFieldsReadonly = computed(() => String(props.formData?.extendUrlParams?.nonJiJianFieldsReadonly ?? '') === '1');
|
||||
const showSelnextUser = computed(() => String(props.formData?.extendUrlParams?.showSelnextUser ?? '') === '1');
|
||||
const showSubApproveUser = computed(
|
||||
() => String(props.formData?.extendUrlParams?.showSubApproveUser ?? '') === '1'
|
||||
);
|
||||
const showSubApproveUser = computed(() => String(props.formData?.extendUrlParams?.showSubApproveUser ?? '') === '1');
|
||||
const showIsNeedLeaderApprove = computed(
|
||||
() => String(props.formData?.extendUrlParams?.showIsNeedLeaderApprove ?? '') === '1'
|
||||
);
|
||||
@@ -407,6 +440,37 @@
|
||||
{ immediate: true }
|
||||
);
|
||||
|
||||
async function fetchDefaultCcUsers() {
|
||||
try {
|
||||
const res = await defHttp.get({
|
||||
url: '/sys/user/queryUserRoleComponentData',
|
||||
params: {
|
||||
departId: '2044677562460508161',
|
||||
roleId: '2044676455280570370',
|
||||
searchSecurityLevel: 5,
|
||||
pageNo: 1,
|
||||
pageSize: 999,
|
||||
},
|
||||
});
|
||||
const records = res?.records || res?.result?.records || [];
|
||||
defaultCcUsers.value = records;
|
||||
} catch {
|
||||
defaultCcUsers.value = [];
|
||||
}
|
||||
}
|
||||
|
||||
watch(
|
||||
() => processInfo.value.taskDefKey,
|
||||
(key) => {
|
||||
if (key === 'Task_0ixi1rs') {
|
||||
fetchDefaultCcUsers();
|
||||
} else {
|
||||
defaultCcUsers.value = [];
|
||||
}
|
||||
},
|
||||
{ immediate: true }
|
||||
);
|
||||
|
||||
async function loadProblemTree() {
|
||||
loadingProblemOptions.value = true;
|
||||
try {
|
||||
@@ -462,7 +526,9 @@
|
||||
const deptId = getCurrentUserDeptId();
|
||||
if (deptId) {
|
||||
list = list.filter((item: any) => {
|
||||
const deptIds = String(item.feedbackDeptId || '').split(',').map((s: string) => s.trim());
|
||||
const deptIds = String(item.feedbackDeptId || '')
|
||||
.split(',')
|
||||
.map((s: string) => s.trim());
|
||||
return deptIds.includes(String(deptId));
|
||||
});
|
||||
}
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
/**
|
||||
* 流程审批中选择用户用 - 只管选择,不管回显
|
||||
*/
|
||||
import { ref, toRaw, computed } from 'vue';
|
||||
import { ref, toRaw, computed, watch } from 'vue';
|
||||
import BpmSelectUserModal from './BpmSelectUserModal.vue';
|
||||
import { useModal } from '/@/components/Modal';
|
||||
|
||||
@@ -27,15 +27,32 @@
|
||||
type: String,
|
||||
default: '',
|
||||
},
|
||||
value: {
|
||||
type: Array,
|
||||
default: () => [],
|
||||
},
|
||||
},
|
||||
emits: ['change'],
|
||||
setup(_p, { emit }) {
|
||||
setup(props, { emit }) {
|
||||
let selectedUserList = [];
|
||||
const options = ref([]);
|
||||
const selectValue = ref([]);
|
||||
const [registerModal, { openModal }] = useModal();
|
||||
const lastSelectedRows = ref([]);
|
||||
|
||||
watch(
|
||||
() => props.value,
|
||||
(val) => {
|
||||
const list = (Array.isArray(val) ? val : []).filter((u) => u?.username);
|
||||
if (!list.length) return;
|
||||
selectValue.value = list.map((u) => u.username);
|
||||
options.value = list.map((u) => ({ value: u.username }));
|
||||
selectedUserList = list;
|
||||
lastSelectedRows.value = list;
|
||||
},
|
||||
{ immediate: true }
|
||||
);
|
||||
|
||||
function openSelect() {
|
||||
let arr = getModalData();
|
||||
openModal(true, {
|
||||
|
||||
+20
-2
@@ -83,7 +83,7 @@
|
||||
<!-- 抄送 -->
|
||||
<a-list-item style="line-height: 32px" v-show="checkedCc">
|
||||
<span>抄送给:</span>
|
||||
<bpm-select-user style="display: inline-block" placeholder="请选择抄送人" @change="handleSelectCcUser"></bpm-select-user>
|
||||
<bpm-select-user style="display: inline-block" placeholder="请选择抄送人" :value="defaultCc" @change="handleSelectCcUser"></bpm-select-user>
|
||||
</a-list-item>
|
||||
</a-list>
|
||||
|
||||
@@ -187,7 +187,11 @@
|
||||
defaultReason: {
|
||||
type: String,
|
||||
default: '',
|
||||
}
|
||||
},
|
||||
defaultCc: {
|
||||
type: Array,
|
||||
default: () => [],
|
||||
},
|
||||
},
|
||||
emits: ['success'],
|
||||
setup(props, { emit }) {
|
||||
@@ -288,6 +292,20 @@
|
||||
ccPersonList.value = [];
|
||||
}
|
||||
|
||||
watch(
|
||||
() => props.defaultCc,
|
||||
(val) => {
|
||||
const list = (Array.isArray(val) ? val : []).filter((u) => u?.username);
|
||||
if (!list.length) return;
|
||||
checkedCc.value = true;
|
||||
const usernames = list.map((u) => u.username);
|
||||
const realnames = list.map((u) => u.realname);
|
||||
model.ccUserIds = usernames.join(',');
|
||||
model.ccUserRealNames = realnames.join(',');
|
||||
},
|
||||
{ immediate: true }
|
||||
);
|
||||
|
||||
function changeReasonSelection(value) {
|
||||
model.reason = value;
|
||||
}
|
||||
|
||||
+5
@@ -21,6 +21,7 @@
|
||||
:allowReject="allowReject"
|
||||
:beforeHandle="beforeHandle"
|
||||
:defaultReason="defaultReason"
|
||||
:defaultCc="defaultCc"
|
||||
:currentTaskName="currentNode.taskName">
|
||||
</my-handle-content>
|
||||
|
||||
@@ -66,6 +67,10 @@
|
||||
type: String,
|
||||
default: '',
|
||||
},
|
||||
defaultCc: {
|
||||
type: Array,
|
||||
default: () => [],
|
||||
},
|
||||
showSelnextUser: {
|
||||
type: Boolean,
|
||||
default: true,
|
||||
|
||||
@@ -0,0 +1,287 @@
|
||||
<template>
|
||||
<div class="login-wrapper">
|
||||
<div class="decorations">
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="line line-1"></span>
|
||||
<span class="line line-2"></span>
|
||||
<span class="line line-3"></span>
|
||||
</div>
|
||||
<div class="login-main">
|
||||
<!-- 研究所标识 -->
|
||||
<div class="institute-logo">
|
||||
<img src="/resource/img/institute_logo.png" alt="七〇四研究所" />
|
||||
</div>
|
||||
|
||||
<!-- 系统标题 -->
|
||||
<div class="system-title">
|
||||
<img class="system-logo" src="/resource/img/logo.png" alt="Logo" />
|
||||
<span class="system-name">事项督办系统</span>
|
||||
</div>
|
||||
|
||||
<!-- 单点登录卡片 -->
|
||||
<div class="login-card">
|
||||
<template v-if="loading">
|
||||
<div class="loading-spinner"></div>
|
||||
<div class="card-title">正在单点登录</div>
|
||||
<div class="card-desc">正在验证身份,请稍候...</div>
|
||||
</template>
|
||||
<template v-else>
|
||||
<div class="card-icon error-icon">!</div>
|
||||
<div class="card-title">登录失败</div>
|
||||
<div class="card-desc">{{ errorMsg }}</div>
|
||||
<button class="retry-btn" @click="handleRetry">重试</button>
|
||||
</template>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 底部版权 -->
|
||||
<div class="footer-text">
|
||||
中国船舶集团有限公司第七〇四研究所 数智化中心©2026
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { ref, onMounted } from 'vue';
|
||||
import { useRouter } from 'vue-router';
|
||||
import { useUserStore } from '/@/store/modules/user';
|
||||
|
||||
const router = useRouter();
|
||||
const userStore = useUserStore();
|
||||
const loading = ref(true);
|
||||
const errorMsg = ref('');
|
||||
|
||||
async function doAutoLogin() {
|
||||
loading.value = true;
|
||||
errorMsg.value = '';
|
||||
try {
|
||||
await userStore.autoLogin(true);
|
||||
} catch (error: any) {
|
||||
loading.value = false;
|
||||
errorMsg.value = error?.message || '单点登录失败,请稍后重试';
|
||||
}
|
||||
}
|
||||
|
||||
function handleRetry() {
|
||||
doAutoLogin();
|
||||
}
|
||||
|
||||
|
||||
onMounted(() => {
|
||||
doAutoLogin();
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.login-wrapper {
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
min-height: 100vh;
|
||||
background: #fff;
|
||||
overflow: hidden;
|
||||
|
||||
&::before,
|
||||
&::after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
border-radius: 50%;
|
||||
opacity: 0.6;
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
&::before {
|
||||
width: 600px;
|
||||
height: 600px;
|
||||
bottom: -280px;
|
||||
left: -120px;
|
||||
background: radial-gradient(circle, rgba(59, 130, 246, 0.12), transparent 70%);
|
||||
}
|
||||
|
||||
&::after {
|
||||
width: 500px;
|
||||
height: 500px;
|
||||
bottom: -200px;
|
||||
right: -100px;
|
||||
background: radial-gradient(circle, rgba(16, 185, 129, 0.10), transparent 70%);
|
||||
}
|
||||
}
|
||||
|
||||
.decorations {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
pointer-events: none;
|
||||
z-index: 0;
|
||||
|
||||
.dot {
|
||||
position: absolute;
|
||||
border-radius: 50%;
|
||||
opacity: 0.55;
|
||||
}
|
||||
|
||||
.dot:nth-child(1) { width: 18px; height: 18px; bottom: 22%; left: 12%; background: #3b82f6; opacity: 0.35; }
|
||||
.dot:nth-child(2) { width: 12px; height: 12px; bottom: 32%; right: 15%; background: #f59e0b; opacity: 0.45; }
|
||||
.dot:nth-child(3) { width: 24px; height: 24px; bottom: 15%; left: 30%; background: #10b981; opacity: 0.3; }
|
||||
.dot:nth-child(4) { width: 10px; height: 10px; bottom: 28%; right: 28%; background: #8b5cf6; opacity: 0.5; }
|
||||
.dot:nth-child(5) { width: 16px; height: 16px; bottom: 18%; left: 55%; background: #ec4899; opacity: 0.35; }
|
||||
.dot:nth-child(6) { width: 20px; height: 20px; bottom: 10%; right: 10%; background: #06b6d4; opacity: 0.4; }
|
||||
.dot:nth-child(7) { width: 8px; height: 8px; bottom: 35%; left: 20%; background: #f97316; opacity: 0.5; }
|
||||
.dot:nth-child(8) { width: 14px; height: 14px; bottom: 8%; left: 45%; background: #6366f1; opacity: 0.4; }
|
||||
.dot:nth-child(9) { width: 20px; height: 20px; top: 8%; left: 10%; background: #3b82f6; opacity: 0.25; }
|
||||
.dot:nth-child(10) { width: 10px; height: 10px; top: 14%; right: 18%; background: #ec4899; opacity: 0.35; }
|
||||
.dot:nth-child(11) { width: 16px; height: 16px; top: 5%; right: 8%; background: #10b981; opacity: 0.3; }
|
||||
.dot:nth-child(12) { width: 8px; height: 8px; top: 18%; left: 25%; background: #f59e0b; opacity: 0.4; }
|
||||
|
||||
.line {
|
||||
position: absolute;
|
||||
pointer-events: none;
|
||||
border-radius: 2px;
|
||||
opacity: 0.15;
|
||||
}
|
||||
|
||||
.line-1 { top: 12%; right: 5%; width: 120px; height: 2px; background: #3b82f6; transform: rotate(-15deg); }
|
||||
.line-2 { top: 20%; left: 8%; width: 80px; height: 2px; background: #ec4899; transform: rotate(10deg); }
|
||||
.line-3 { top: 6%; right: 15%; width: 60px; height: 2px; background: #10b981; transform: rotate(-8deg); }
|
||||
}
|
||||
|
||||
.login-main {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 40px 24px;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.institute-logo {
|
||||
margin-bottom: 48px;
|
||||
|
||||
img {
|
||||
width: 400px;
|
||||
height: auto;
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
|
||||
.system-title {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 12px;
|
||||
margin-bottom: 48px;
|
||||
|
||||
.system-logo {
|
||||
width: 72px;
|
||||
height: 72px;
|
||||
}
|
||||
|
||||
.system-name {
|
||||
font-size: 28px;
|
||||
font-weight: 600;
|
||||
color: #1a1a1a;
|
||||
letter-spacing: 2px;
|
||||
}
|
||||
}
|
||||
|
||||
.login-card {
|
||||
width: 100%;
|
||||
max-width: 360px;
|
||||
padding: 40px 32px;
|
||||
background: #fafbfc;
|
||||
border-radius: 12px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.loading-spinner {
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
margin: 0 auto 20px;
|
||||
border: 3px solid #e5e7eb;
|
||||
border-top-color: #1a6dd4;
|
||||
border-radius: 50%;
|
||||
animation: spin 0.8s linear infinite;
|
||||
}
|
||||
|
||||
@keyframes spin {
|
||||
to { transform: rotate(360deg); }
|
||||
}
|
||||
|
||||
.card-icon {
|
||||
width: 48px;
|
||||
height: 48px;
|
||||
margin: 0 auto 16px;
|
||||
border-radius: 50%;
|
||||
font-size: 24px;
|
||||
font-weight: 700;
|
||||
line-height: 48px;
|
||||
}
|
||||
|
||||
.error-icon {
|
||||
background: #fee2e2;
|
||||
color: #ef4444;
|
||||
}
|
||||
|
||||
.card-title {
|
||||
font-size: 18px;
|
||||
font-weight: 600;
|
||||
color: #1a1a1a;
|
||||
margin-bottom: 8px;
|
||||
}
|
||||
|
||||
.card-desc {
|
||||
font-size: 14px;
|
||||
color: rgba(0, 0, 0, 0.45);
|
||||
margin-bottom: 24px;
|
||||
}
|
||||
|
||||
.retry-btn {
|
||||
width: 100%;
|
||||
height: 44px;
|
||||
border: none;
|
||||
border-radius: 8px;
|
||||
background: #1a6dd4;
|
||||
color: #fff;
|
||||
font-size: 15px;
|
||||
font-weight: 500;
|
||||
cursor: pointer;
|
||||
transition: background 0.2s;
|
||||
margin-bottom: 12px;
|
||||
|
||||
&:hover {
|
||||
background: #155ab0;
|
||||
}
|
||||
}
|
||||
|
||||
.login-link {
|
||||
display: inline-block;
|
||||
font-size: 14px;
|
||||
color: #1a6dd4;
|
||||
cursor: pointer;
|
||||
|
||||
&:hover {
|
||||
color: #155ab0;
|
||||
text-decoration: underline;
|
||||
}
|
||||
}
|
||||
|
||||
.footer-text {
|
||||
position: relative;
|
||||
z-index: 1;
|
||||
text-align: center;
|
||||
font-size: 13px;
|
||||
color: rgba(0, 0, 0, 0.65);
|
||||
padding: 16px 0;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,251 @@
|
||||
<template>
|
||||
<div class="login-wrapper">
|
||||
<div class="decorations">
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="dot"></span>
|
||||
<span class="line line-1"></span>
|
||||
<span class="line line-2"></span>
|
||||
<span class="line line-3"></span>
|
||||
</div>
|
||||
<div class="login-main">
|
||||
<!-- 研究所标识 -->
|
||||
<div class="institute-logo">
|
||||
<img src="/resource/img/institute_logo.png" alt="七〇四研究所" />
|
||||
</div>
|
||||
|
||||
<!-- 系统标题 -->
|
||||
<div class="system-title">
|
||||
<img class="system-logo" src="/resource/img/logo.png" alt="Logo" />
|
||||
<span class="system-name">事项督办系统</span>
|
||||
</div>
|
||||
|
||||
<!-- 退出登录卡片 -->
|
||||
<div class="login-card">
|
||||
<div class="card-icon success-icon">
|
||||
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round">
|
||||
<polyline points="20 6 9 17 4 12"></polyline>
|
||||
</svg>
|
||||
</div>
|
||||
<div class="card-title">已退出登录</div>
|
||||
<div class="card-desc">您已安全退出系统</div>
|
||||
<button class="sso-btn" @click="handleAutoLogin">重新单点登录</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 底部版权 -->
|
||||
<div class="footer-text">
|
||||
中国船舶集团有限公司第七〇四研究所 数智化中心©2026
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { useRouter } from 'vue-router';
|
||||
|
||||
const router = useRouter();
|
||||
|
||||
function handleAutoLogin() {
|
||||
router.replace('/user/autoLogin');
|
||||
}
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.login-wrapper {
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
min-height: 100vh;
|
||||
background: #fff;
|
||||
overflow: hidden;
|
||||
|
||||
&::before,
|
||||
&::after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
border-radius: 50%;
|
||||
opacity: 0.6;
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
&::before {
|
||||
width: 600px;
|
||||
height: 600px;
|
||||
bottom: -280px;
|
||||
left: -120px;
|
||||
background: radial-gradient(circle, rgba(59, 130, 246, 0.12), transparent 70%);
|
||||
}
|
||||
|
||||
&::after {
|
||||
width: 500px;
|
||||
height: 500px;
|
||||
bottom: -200px;
|
||||
right: -100px;
|
||||
background: radial-gradient(circle, rgba(16, 185, 129, 0.10), transparent 70%);
|
||||
}
|
||||
}
|
||||
|
||||
.decorations {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
pointer-events: none;
|
||||
z-index: 0;
|
||||
|
||||
.dot {
|
||||
position: absolute;
|
||||
border-radius: 50%;
|
||||
opacity: 0.55;
|
||||
}
|
||||
|
||||
.dot:nth-child(1) { width: 18px; height: 18px; bottom: 22%; left: 12%; background: #3b82f6; opacity: 0.35; }
|
||||
.dot:nth-child(2) { width: 12px; height: 12px; bottom: 32%; right: 15%; background: #f59e0b; opacity: 0.45; }
|
||||
.dot:nth-child(3) { width: 24px; height: 24px; bottom: 15%; left: 30%; background: #10b981; opacity: 0.3; }
|
||||
.dot:nth-child(4) { width: 10px; height: 10px; bottom: 28%; right: 28%; background: #8b5cf6; opacity: 0.5; }
|
||||
.dot:nth-child(5) { width: 16px; height: 16px; bottom: 18%; left: 55%; background: #ec4899; opacity: 0.35; }
|
||||
.dot:nth-child(6) { width: 20px; height: 20px; bottom: 10%; right: 10%; background: #06b6d4; opacity: 0.4; }
|
||||
.dot:nth-child(7) { width: 8px; height: 8px; bottom: 35%; left: 20%; background: #f97316; opacity: 0.5; }
|
||||
.dot:nth-child(8) { width: 14px; height: 14px; bottom: 8%; left: 45%; background: #6366f1; opacity: 0.4; }
|
||||
.dot:nth-child(9) { width: 20px; height: 20px; top: 8%; left: 10%; background: #3b82f6; opacity: 0.25; }
|
||||
.dot:nth-child(10) { width: 10px; height: 10px; top: 14%; right: 18%; background: #ec4899; opacity: 0.35; }
|
||||
.dot:nth-child(11) { width: 16px; height: 16px; top: 5%; right: 8%; background: #10b981; opacity: 0.3; }
|
||||
.dot:nth-child(12) { width: 8px; height: 8px; top: 18%; left: 25%; background: #f59e0b; opacity: 0.4; }
|
||||
|
||||
.line {
|
||||
position: absolute;
|
||||
pointer-events: none;
|
||||
border-radius: 2px;
|
||||
opacity: 0.15;
|
||||
}
|
||||
|
||||
.line-1 { top: 12%; right: 5%; width: 120px; height: 2px; background: #3b82f6; transform: rotate(-15deg); }
|
||||
.line-2 { top: 20%; left: 8%; width: 80px; height: 2px; background: #ec4899; transform: rotate(10deg); }
|
||||
.line-3 { top: 6%; right: 15%; width: 60px; height: 2px; background: #10b981; transform: rotate(-8deg); }
|
||||
}
|
||||
|
||||
.login-main {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 40px 24px;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.institute-logo {
|
||||
margin-bottom: 48px;
|
||||
|
||||
img {
|
||||
width: 400px;
|
||||
height: auto;
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
|
||||
.system-title {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 12px;
|
||||
margin-bottom: 48px;
|
||||
|
||||
.system-logo {
|
||||
width: 72px;
|
||||
height: 72px;
|
||||
}
|
||||
|
||||
.system-name {
|
||||
font-size: 28px;
|
||||
font-weight: 600;
|
||||
color: #1a1a1a;
|
||||
letter-spacing: 2px;
|
||||
}
|
||||
}
|
||||
|
||||
.login-card {
|
||||
width: 100%;
|
||||
max-width: 360px;
|
||||
padding: 40px 32px;
|
||||
background: #fafbfc;
|
||||
border-radius: 12px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.card-icon {
|
||||
width: 56px;
|
||||
height: 56px;
|
||||
margin: 0 auto 16px;
|
||||
border-radius: 50%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.success-icon {
|
||||
background: #dcfce7;
|
||||
color: #22c55e;
|
||||
}
|
||||
|
||||
.card-title {
|
||||
font-size: 18px;
|
||||
font-weight: 600;
|
||||
color: #1a1a1a;
|
||||
margin-bottom: 8px;
|
||||
}
|
||||
|
||||
.card-desc {
|
||||
font-size: 14px;
|
||||
color: rgba(0, 0, 0, 0.45);
|
||||
margin-bottom: 24px;
|
||||
}
|
||||
|
||||
.sso-btn {
|
||||
width: 100%;
|
||||
height: 44px;
|
||||
border: none;
|
||||
border-radius: 8px;
|
||||
background: #1a6dd4;
|
||||
color: #fff;
|
||||
font-size: 15px;
|
||||
font-weight: 500;
|
||||
cursor: pointer;
|
||||
transition: background 0.2s;
|
||||
margin-bottom: 12px;
|
||||
|
||||
&:hover {
|
||||
background: #155ab0;
|
||||
}
|
||||
}
|
||||
|
||||
.login-link {
|
||||
display: inline-block;
|
||||
font-size: 14px;
|
||||
color: #1a6dd4;
|
||||
cursor: pointer;
|
||||
|
||||
&:hover {
|
||||
color: #155ab0;
|
||||
text-decoration: underline;
|
||||
}
|
||||
}
|
||||
|
||||
.footer-text {
|
||||
position: relative;
|
||||
z-index: 1;
|
||||
text-align: center;
|
||||
font-size: 13px;
|
||||
color: rgba(0, 0, 0, 0.65);
|
||||
padding: 16px 0;
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user