mirror of
https://gitee.com/wonderful-code/buildadmin
synced 2024-11-21 14:41:29 +00:00
perf:使用 v-memo 指令缓存表格中的按钮组以提高性能
This commit is contained in:
parent
ce7c7b2885
commit
07a91cb906
@ -115,7 +115,7 @@
|
||||
|
||||
<!-- 按钮组 -->
|
||||
<!-- 只对默认的编辑、删除、排序按钮进行鉴权,其他按钮请通过 display 属性控制按钮是否显示 -->
|
||||
<div v-if="field.render == 'buttons' && field.buttons">
|
||||
<div v-if="field.render == 'buttons' && field.buttons" v-memo="[field]">
|
||||
<template v-for="(btn, idx) in field.buttons" :key="idx">
|
||||
<template v-if="btn.display ? btn.display(row, field) : true">
|
||||
<!-- 常规按钮 -->
|
||||
|
Loading…
Reference in New Issue
Block a user