去除修改删除按钮
This commit is contained in:
@@ -968,7 +968,7 @@ onMounted(() => {
|
|||||||
<template #icon><ProfileOutlined /></template>
|
<template #icon><ProfileOutlined /></template>
|
||||||
</a-button>
|
</a-button>
|
||||||
</a-tooltip>
|
</a-tooltip>
|
||||||
<a-tooltip v-if="record.roleId !== '1'">
|
<a-tooltip v-if="record.roleId !== '1' && record.roleKey !== 'tenant'">
|
||||||
<template #title>{{ t('common.editText') }}</template>
|
<template #title>{{ t('common.editText') }}</template>
|
||||||
<a-button
|
<a-button
|
||||||
type="link"
|
type="link"
|
||||||
@@ -978,7 +978,7 @@ onMounted(() => {
|
|||||||
<template #icon><FormOutlined /></template>
|
<template #icon><FormOutlined /></template>
|
||||||
</a-button>
|
</a-button>
|
||||||
</a-tooltip>
|
</a-tooltip>
|
||||||
<a-tooltip v-if="record.roleId !== '1'">
|
<a-tooltip v-if="record.roleId !== '1' && record.roleKey !== 'tenant'">
|
||||||
<template #title>{{ t('common.deleteText') }}</template>
|
<template #title>{{ t('common.deleteText') }}</template>
|
||||||
<a-button
|
<a-button
|
||||||
type="link"
|
type="link"
|
||||||
|
|||||||
@@ -814,11 +814,21 @@ function fnGetDeptTree() {
|
|||||||
|
|
||||||
function handleChange(value: any, options: any) {
|
function handleChange(value: any, options: any) {
|
||||||
modalState.from.roleIds = [value];
|
modalState.from.roleIds = [value];
|
||||||
|
console.log(modalState.from.roleIds, options.roleKey);
|
||||||
|
|
||||||
modalState.showTenant = options.roleKey === 'tenant';
|
modalState.showTenant = options.roleKey === 'tenant';
|
||||||
// 获取租户树结构数据
|
// 获取租户树结构数据
|
||||||
if (modalState.showTenant) fnGetDeptTree();
|
if (modalState.showTenant) fnGetDeptTree();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function handleDel(value: any, options: any) {
|
||||||
|
console.log(modalState.from.roleIds, options.roleKey);
|
||||||
|
modalState.showTenant = options.roleKey !== 'tenant';
|
||||||
|
// 获取租户树结构数据
|
||||||
|
if (modalState.showTenant) fnGetDeptTree();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
// 初始字典数据
|
// 初始字典数据
|
||||||
Promise.allSettled([
|
Promise.allSettled([
|
||||||
@@ -1496,6 +1506,7 @@ onMounted(() => {
|
|||||||
:field-names="{ label: 'roleName', value: 'roleId' }"
|
:field-names="{ label: 'roleName', value: 'roleId' }"
|
||||||
:placeholder="t('common.selectPlease')"
|
:placeholder="t('common.selectPlease')"
|
||||||
@select="handleChange"
|
@select="handleChange"
|
||||||
|
@deselect="handleDel"
|
||||||
>
|
>
|
||||||
</a-select>
|
</a-select>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
|
|||||||
Reference in New Issue
Block a user