Browse Source

ts 报错

main
chenyang 3 months ago
parent
commit
99de611c1a
  1. 2
      src/components/x-form/utils/index.tsx

2
src/components/x-form/utils/index.tsx

@ -117,6 +117,8 @@ export const transformAntdTableProColumns = (columns: XFormTypes.IColumn[], over
const data = has(res.data, resKey) ? get(res.data, resKey) : res.data const data = has(res.data, resKey) ? get(res.data, resKey) : res.data
return mapTree(data || [], (i: any) => { return mapTree(data || [], (i: any) => {
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
// @ts-ignore
const disabled = has(i, disabledKey) ? get(i, disabledKey) : ('status' in i ? !convertToBool(i.status) : false) const disabled = has(i, disabledKey) ? get(i, disabledKey) : ('status' in i ? !convertToBool(i.status) : false)
return { return {
title: i[label || 'label'], title: i[label || 'label'],

Loading…
Cancel
Save