modify
All checks were successful
构建并部署前端到测试环境 / build-and-deploy (push) Successful in 6m13s

This commit is contained in:
sexygoat
2026-04-02 13:42:57 +08:00
parent 411206e039
commit 8df7024a45
83 changed files with 1830 additions and 1865 deletions

View File

@@ -28,9 +28,7 @@ export const useAuth = () => {
if (Array.isArray(permission)) {
// 多个权限(满足任意一个即可)
return permission.some(
(perm) => userStore.hasPermission(perm) || userStore.hasButton(perm)
)
return permission.some((perm) => userStore.hasPermission(perm) || userStore.hasButton(perm))
}
return false
@@ -45,9 +43,7 @@ export const useAuth = () => {
if (!permissions || !Array.isArray(permissions)) return false
// 需要全部满足
return permissions.every(
(perm) => userStore.hasPermission(perm) || userStore.hasButton(perm)
)
return permissions.every((perm) => userStore.hasPermission(perm) || userStore.hasButton(perm))
}
return {

View File

@@ -94,7 +94,10 @@ export function useCheckedColumns(columnsFactory: () => ColumnOption[]) {
cols.forEach((column) => {
// 为普通列添加空值处理
if (!column.type || (column.type !== 'selection' && column.type !== 'expand' && column.type !== 'index')) {
if (
!column.type ||
(column.type !== 'selection' && column.type !== 'expand' && column.type !== 'index')
) {
const originalFormatter = column.formatter
// 包装原有的 formatter,在其基础上添加空值处理

View File

@@ -21,12 +21,7 @@ export function useTableContextMenu() {
/**
* 单元格鼠标进入事件处理
*/
const handleCellMouseEnter = (
row: any,
column: any,
cell: HTMLElement,
event: MouseEvent
) => {
const handleCellMouseEnter = (row: any, column: any, cell: HTMLElement, event: MouseEvent) => {
// 清除之前的定时器
if (hintTimer) {
clearTimeout(hintTimer)