123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384 |
- import { copy } from "@/utils/utils"
- import { TableProps } from "antd"
- import React from "react"
- const columns = (edit: (data: any) => void): TableProps<any>['columns'] => {
- const data: TableProps<any>['columns'] = [
- {
- title: '操作',
- dataIndex: 'cz',
- key: 'cz',
- align: 'center',
- width: 70,
- render: (_, b) => {
- return <a style={{ fontSize: 12 }} onClick={() => edit(b)}>修改</a>
- }
- },
- {
- title: '企业微信名称',
- dataIndex: 'corpName',
- key: 'corpName',
- ellipsis: true,
- width: 180,
- render: (a) => {
- return <span style={{ fontSize: "12px" }}>{a}</span>
- }
- },
- {
- title: '投放端企业微信ID',
- dataIndex: 'tencentCorpId',
- key: 'tencentCorpId',
- ellipsis: true,
- render: (a) => {
- return <a style={{ fontSize: "12px" }} onClick={() => copy(a)}>{a}</a>
- }
- },
- {
- title: '企微端企业微信ID',
- dataIndex: 'localCorpId',
- key: 'localCorpId',
- ellipsis: true,
- render: (a) => {
- return <a style={{ fontSize: "12px" }} onClick={() => copy(a)}>{a}</a>
- }
- },
- {
- title: '腾讯广告第三方企微应用ID',
- dataIndex: 'agentId',
- key: 'agentId',
- ellipsis: true,
- render: (a) => {
- return <a style={{ fontSize: "12px" }} onClick={() => copy(a)}>{a}</a>
- }
- },
- {
- title: '创建时间',
- dataIndex: 'createTime',
- key: 'createTime',
- align: 'center',
- width: 140,
- ellipsis: true,
- render: (a) => {
- return <span style={{ fontSize: "12px" }}>{a}</span>
- }
- },
- {
- title: '更新时间',
- dataIndex: 'updateTime',
- key: 'updateTime',
- align: 'center',
- width: 140,
- ellipsis: true,
- render: (a) => {
- return <span style={{ fontSize: "12px" }}>{a}</span>
- }
- }
- ]
- return data
- }
- export default columns
|