antd Table每列样式修改

      {
        title: formatMessage({ id: 'OPERATE', defaultMessage: '操作' }),
        dataIndex: 'id',
        key: 'id',
        ellipsis: true,
        render: v => {
          const obj = {
            children: <div className={styles.iconStyle}>
               {/* <MyIcon
                      type="iconfile-copy"
                       title={formatMessage({ id: 'COMMON_EDIT', defaultMessage: '编辑' })}
               /> */}
                 <Popconfirm
                  title={formatMessage({ id: 'CONFIRM_DELETION', defaultMessage: '确认删除?' })}
                  onConfirm={() => {
                   singleListDelete(v);
                 }}
                >
                  <MyIcon
                    type="icondelete"
                    title={formatMessage({ id: 'COMMON_DELETE', defaultMessage: '删除' })}
                  />
                </Popconfirm>
               </div>,
            props: {
              rowSpan: 1,
              colSpan: 1,
              id: 'lastRowSpan',
            },
          };
          return obj;
        },
      },

 

posted @ 2021-06-04 10:19  lipu1993  阅读(1065)  评论(0编辑  收藏  举报