|
@@ -113,11 +113,7 @@
|
|
|
@click="onEdit(scope.row)"
|
|
|
/>
|
|
|
<CzrButton
|
|
|
- v-if="
|
|
|
- AppStore.isSuperAdmin &&
|
|
|
- state.query.form.tenantId === AppStore.tenantInfo.id &&
|
|
|
- AppStore.hasPermission($route.name, 'del')
|
|
|
- "
|
|
|
+ v-if="isDelCpt"
|
|
|
type="table-del"
|
|
|
@click="onDel(scope.row)"
|
|
|
/>
|
|
@@ -284,6 +280,16 @@ watch(
|
|
|
const isPTGLCpt = computed(() => {
|
|
|
return AppStore.tenantInfo?.id == (import.meta as any).env.VITE_TENANT_ID_PTGL
|
|
|
})
|
|
|
+const isDelCpt = computed(() => {
|
|
|
+ return (
|
|
|
+ AppStore.isSuperAdmin &&
|
|
|
+ (state.query.form.tenantId === AppStore.tenantInfo?.id ||
|
|
|
+ (isPTGLCpt.value &&
|
|
|
+ state.query.form.tenantId ==
|
|
|
+ (import.meta as any).env.VITE_TENANT_ID_GGKJ)) &&
|
|
|
+ AppStore.hasPermission($route.name, 'del')
|
|
|
+ )
|
|
|
+})
|
|
|
const onSort = ({ key, value }) => {
|
|
|
state.query.sort[key] = value
|
|
|
onSearch()
|