fix(接口测试): 替换定义详情icon&权限调整

This commit is contained in:
xinxin.wu 2024-10-21 16:06:40 +08:00 committed by Craftsman
parent 8515a49ae3
commit fe8f215fe5
3 changed files with 6 additions and 6 deletions

View File

@ -12,7 +12,7 @@
> >
<template #right> <template #right>
<ShareButton <ShareButton
v-if="hasAnyPermission(['PROJECT_API_DEFINITION_DOC:READ+SHARE'])" v-if="hasAnyPermission(['PROJECT_API_DEFINITION:READ+SHARE'])"
ref="shareButtonRef" ref="shareButtonRef"
@create="createShare" @create="createShare"
@show-share-list="showShareList" @show-share-list="showShareList"

View File

@ -9,7 +9,7 @@
<template #titleAppend> <template #titleAppend>
<a-tooltip v-if="!docShareId" :content="t('report.detail.api.copyLink')"> <a-tooltip v-if="!docShareId" :content="t('report.detail.api.copyLink')">
<MsIcon <MsIcon
type="icon-icon_copy_outlined" type="icon-icon_unlink"
class="cursor-pointer text-[var(--color-text-4)]" class="cursor-pointer text-[var(--color-text-4)]"
:size="16" :size="16"
@click="share" @click="share"

View File

@ -10,7 +10,7 @@
<div class="p-[16px]"> <div class="p-[16px]">
<div class="mb-4 flex items-center justify-between"> <div class="mb-4 flex items-center justify-between">
<a-button <a-button
v-permission="['PROJECT_API_DEFINITION_DOC:READ+SHARE']" v-permission="['PROJECT_API_DEFINITION:READ+SHARE']"
class="w-[84px]" class="w-[84px]"
type="primary" type="primary"
@click="emit('editOrCreate')" @click="emit('editOrCreate')"
@ -32,7 +32,7 @@
{{ record.isPrivate ? t('apiTestManagement.passwordView') : t('apiTestManagement.publicityView') }} {{ record.isPrivate ? t('apiTestManagement.passwordView') : t('apiTestManagement.publicityView') }}
</template> </template>
<template #operation="{ record }"> <template #operation="{ record }">
<div v-permission="['PROJECT_API_DEFINITION_DOC:READ+SHARE']" class="flex items-center"> <div v-permission="['PROJECT_API_DEFINITION:READ+SHARE']" class="flex items-center">
<a-tooltip :disabled="!!record.apiShareNum" :content="t('apiTestManagement.apiShareNumberTip')"> <a-tooltip :disabled="!!record.apiShareNum" :content="t('apiTestManagement.apiShareNumberTip')">
<MsButton class="!mx-0" :disabled="!record.apiShareNum" @click="viewLink(record)"> <MsButton class="!mx-0" :disabled="!record.apiShareNum" @click="viewLink(record)">
{{ t('apiTestManagement.viewLink') }} {{ t('apiTestManagement.viewLink') }}
@ -139,11 +139,11 @@
showDrag: true, showDrag: true,
}, },
{ {
title: hasAnyPermission(['PROJECT_API_DEFINITION_DOC:READ+SHARE']) ? 'common.operation' : '', title: hasAnyPermission(['PROJECT_API_DEFINITION:READ+SHARE']) ? 'common.operation' : '',
slotName: 'operation', slotName: 'operation',
dataIndex: 'operation', dataIndex: 'operation',
fixed: 'right', fixed: 'right',
width: operationWidth(215, hasAnyPermission(['PROJECT_API_DEFINITION_DOC:READ+SHARE']) ? 180 : 50), width: operationWidth(215, hasAnyPermission(['PROJECT_API_DEFINITION:READ+SHARE']) ? 180 : 50),
showInTable: true, showInTable: true,
showDrag: false, showDrag: false,
}, },