king
2023-05-31 836dc03f4dd7f3e5e1770723f5b406c4bb1c1a18
src/tabviews/custom/components/share/normalTable/index.jsx
@@ -6,13 +6,13 @@
import asyncComponent from '@/utils/asyncComponent'
import { getMark } from '@/utils/utils.js'
import MkIcon from '@/components/mk-icon'
import MKEmitter from '@/utils/events.js'
import Encrypts from '@/components/encrypts'
import './index.scss'
const { Paragraph } = Typography
const Video = asyncComponent(() => import('@/components/video'))
const MkIcon = asyncComponent(() => import('@/components/mk-icon'))
const MkPicture = asyncComponent(() => import('@/components/mkPicture'))
const CardCellComponent = asyncComponent(() => import('@/tabviews/custom/components/card/cardcellList'))
const PicRadio = {
@@ -340,7 +340,16 @@
          // eslint-disable-next-line
          content = eval(content)
        } catch (e) {
          if (window.debugger) {
            console.info(content)
            console.warn(e)
          }
          content = ''
        }
        if (col.round && typeof(content) === 'number') {
          content = Math.round(content * col.round) / col.round
          content = content.toFixed(col.decimal)
        }
      }
@@ -375,14 +384,6 @@
        style = {...style, ...col.style}
      }
      resProps.children = (
        <CardCellComponent data={record} cards={config} elements={col.elements}/>
      )
    } else if (col.type === 'action') {
      style.padding = '0px'
      if (col.style) {
        style = {...style, ...col.style}
      }
      resProps.children = (
        <CardCellComponent data={record} cards={config} elements={col.elements}/>
      )
@@ -477,7 +478,7 @@
              onCell: record => ({
                record,
                col: item,
                config: item.type === 'custom' || item.type === 'action' ? {setting, columns: fields} : null,
                config: item.type === 'custom' ? {setting, columns: fields} : null,
                triggerLink: this.triggerLink
              })
            }
@@ -987,6 +988,9 @@
    }
    let height = setting.height || false
    if (height && height <= 100) {
      height = height + 'vh'
    }
    let loading = this.props.loading
    if (setting.mask === 'hidden') {
      loading = false
@@ -1020,6 +1024,7 @@
            return {
              lineMarks: setting.tableMode !== 'fast' ? lineMarks : null,
              data: record,
              title: setting.tipField ? record[setting.tipField] : '',
              className: index === activeIndex ? ' mk-row-active ' : '',
              onClick: () => {this.changeRow(record, index)},
              onDoubleClick: () => {this.doubleClickLine(record)}