|
@@ -12,6 +12,7 @@
|
|
:align="attrs.align"
|
|
:align="attrs.align"
|
|
:tree-config="{transform: attrs.transform, rowField: attrs.rowField, parentField: attrs.parentField}"
|
|
:tree-config="{transform: attrs.transform, rowField: attrs.rowField, parentField: attrs.parentField}"
|
|
:row-config="{isHover: true}"
|
|
:row-config="{isHover: true}"
|
|
|
|
+ :tooltip-config="{showAll: true}"
|
|
style="width: 100%">
|
|
style="width: 100%">
|
|
|
|
|
|
<vxe-column v-if="attrs.checkbox" type="checkbox" width="50" fixed="left" />
|
|
<vxe-column v-if="attrs.checkbox" type="checkbox" width="50" fixed="left" />
|
|
@@ -27,14 +28,16 @@
|
|
>
|
|
>
|
|
<template #default="{ row }">
|
|
<template #default="{ row }">
|
|
<template v-if="item.plugins">
|
|
<template v-if="item.plugins">
|
|
- <span class="col-action"
|
|
|
|
- v-for="(pluginsItem,_index) of item.plugins"
|
|
|
|
- :key="'plu'+_index"
|
|
|
|
- v-hasPermi="[item.audit]"
|
|
|
|
- @click="pluginClick(pluginsItem,row)">
|
|
|
|
- <i v-if="pluginsItem.icon" :class="pluginsItem.icon" ></i>
|
|
|
|
- {{ pluginsItem.name }}
|
|
|
|
- </span>
|
|
|
|
|
|
+ <template v-for="(pluginsItem,_index) of item.plugins" >
|
|
|
|
+ <span class="col-action"
|
|
|
|
+ :key="'plu'+_index"
|
|
|
|
+ v-hasPermi="[pluginsItem.audit]"
|
|
|
|
+ v-if="showPlugin(pluginsItem,row)"
|
|
|
|
+ @click="pluginClick(pluginsItem,row)">
|
|
|
|
+ <i v-if="pluginsItem.icon" :class="pluginsItem.icon" ></i>
|
|
|
|
+ {{ pluginsItem.name }}
|
|
|
|
+ </span>
|
|
|
|
+ </template>
|
|
</template>
|
|
</template>
|
|
</template>
|
|
</template>
|
|
</vxe-column>
|
|
</vxe-column>
|
|
@@ -46,6 +49,7 @@
|
|
:width="item.width"
|
|
:width="item.width"
|
|
:fixed="item.fixed"
|
|
:fixed="item.fixed"
|
|
:align="item.align"
|
|
:align="item.align"
|
|
|
|
+ show-overflow="ellipsis"
|
|
:tree-node="item.treeNode"
|
|
:tree-node="item.treeNode"
|
|
>
|
|
>
|
|
<template #default="{ row }">
|
|
<template #default="{ row }">
|
|
@@ -149,7 +153,6 @@ export default class ByTable extends VueViews {
|
|
}
|
|
}
|
|
})
|
|
})
|
|
}
|
|
}
|
|
-
|
|
|
|
|
|
|
|
//点击详情
|
|
//点击详情
|
|
detail(row:any){
|
|
detail(row:any){
|
|
@@ -201,6 +204,16 @@ export default class ByTable extends VueViews {
|
|
config.event.click(data)
|
|
config.event.click(data)
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
+ //操作按钮是否显示
|
|
|
|
+ showPlugin(config:any,row:any){
|
|
|
|
+ if(config?.event?.show){
|
|
|
|
+ let data = (this as any).$lodash.cloneDeep(row)
|
|
|
|
+ delete data[this.key_id];
|
|
|
|
+ return config.event.show(data)
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ return true
|
|
|
|
+ }
|
|
|
|
|
|
//组件值的变化
|
|
//组件值的变化
|
|
onChange(val:any,row:any,code:string){
|
|
onChange(val:any,row:any,code:string){
|