fix: disable clickable material name links for users without edit permissions across all inbound tables
This commit is contained in:
@ -150,9 +150,10 @@
|
||||
:sortable="isColumnSortable(col.prop) ? 'custom' : false"
|
||||
>
|
||||
<template #default="scope" v-if="col.prop === 'material_name'">
|
||||
<span class="clickable-text" @click="handleUpdate(scope.row)">
|
||||
<span v-if="userStore.hasPermission('inbound_buy:operation')" class="clickable-text" @click="handleUpdate(scope.row)">
|
||||
{{ scope.row.material_name }}
|
||||
</span>
|
||||
<span v-else>{{ scope.row.material_name }}</span>
|
||||
</template>
|
||||
|
||||
<template #default="scope" v-else-if="col.prop === 'sn_bn'">
|
||||
|
||||
@ -154,9 +154,10 @@
|
||||
>
|
||||
|
||||
<template #default="scope" v-if="col.prop === 'material_name'">
|
||||
<span class="clickable-text" @click="handleUpdate(scope.row)">
|
||||
<span v-if="userStore.hasPermission('inbound_product:operation')" class="clickable-text" @click="handleUpdate(scope.row)">
|
||||
{{ scope.row.material_name }}
|
||||
</span>
|
||||
<span v-else>{{ scope.row.material_name }}</span>
|
||||
</template>
|
||||
|
||||
<template #default="scope" v-else-if="col.prop === 'company_name'">
|
||||
|
||||
@ -166,9 +166,10 @@
|
||||
show-overflow-tooltip
|
||||
>
|
||||
<template #default="scope" v-if="col.prop === 'material_name'">
|
||||
<span class="clickable-text" @click="handleUpdate(scope.row)">
|
||||
<span v-if="userStore.hasPermission('inbound_semi:operation')" class="clickable-text" @click="handleUpdate(scope.row)">
|
||||
{{ scope.row.material_name }}
|
||||
</span>
|
||||
<span v-else>{{ scope.row.material_name }}</span>
|
||||
</template>
|
||||
|
||||
<template #default="scope" v-else-if="col.prop === 'company_name'">
|
||||
|
||||
Reference in New Issue
Block a user