Преглед на файлове

Merge branch 'develop' of http://git.zanxiangnet.com/wjx/ad-manage

shenwu преди 2 години
родител
ревизия
e92d46ee81

+ 2 - 1
config/routerConfig.ts

@@ -42,6 +42,7 @@ function btnFun(items: any) {
 //返回子路由
 function routeFun(items: any) {
     return items.children.map((route: any) => {//循环重组
+        // console.log(route)
         if (route?.children?.length > 0) {
             let arr = routeFun(route)
             return { path: route.path, name: route.meta.title, component: route.component, routes: arr, icon: route.meta.icon, key: route?.menuId }
@@ -50,7 +51,7 @@ function routeFun(items: any) {
             let arr = btnFun(route)
             return { path: route.path, name: route.meta.title, component: route.component, routes: arr, icon: route.meta.icon, key: route?.menuId }
         }
-        return { path: route.path, name: route.meta.title, component: route.component, icon: items.meta.icon, key: route?.menuId }
+        return { path: route.path, name: route.meta.title, component: route.component, icon: route.icon, key: route?.menuId }
     })
 }
 /**获取线上菜单并重组路由格式和权限*/

+ 4 - 0
src/app.tsx

@@ -11,6 +11,8 @@ import { getMyMenu, headrRouter } from '../config/routerConfig';
 import { ReactComponent as LaunchSvg } from '@/assets/launch.svg'
 import { ReactComponent as AdLaunchSvg } from '@/assets/adLaunch.svg'
 import { ReactComponent as MaterialSvg } from '@/assets/material.svg'
+import { ReactComponent as GdtSvg } from '@/assets/gdt.svg'
+import { ReactComponent as MonitorSvg } from '@/assets/monitor.svg'
 import versions from './utils/versions';
 
 
@@ -103,6 +105,8 @@ const IconMap = {
   launch: <span role="img" aria-label="fund-view" className="anticon anticon-fund-view"><LaunchSvg /></span>,
   adLaunch: <span role="img" aria-label="fund-view" className="anticon anticon-fund-view"><AdLaunchSvg /></span>,
   material: <span role="img" aria-label="fund-view" className="anticon anticon-fund-view"><MaterialSvg /></span>,
+  gdt: <span role="img" aria-label="fund-view" className="anticon anticon-fund-view"><GdtSvg /></span>,
+  monitor: <span role="img" aria-label="fund-view" className="anticon anticon-fund-view"><MonitorSvg /></span>,
   eye: <EyeOutlined />
 };
 //处理菜单

Файловите разлики са ограничени, защото са твърде много
+ 0 - 0
src/assets/gdt.svg


+ 1 - 0
src/assets/monitor.svg

@@ -0,0 +1 @@
+<svg viewBox="64 64 896 896" focusable="false" data-icon="fund-view" width="1em" height="1em" fill="currentColor" aria-hidden="true"><path d="M855.04 101.76H168.96a80.64 80.64 0 0 0-81.28 80.64v539.52a81.28 81.28 0 0 0 81.28 81.28h312.32v55.04H234.88a32.64 32.64 0 0 0-32 32 32 32 0 0 0 32 32h556.16a32 32 0 0 0 32-32 32 32 0 0 0-32-32H545.28v-55.04h309.76a81.28 81.28 0 0 0 81.28-81.28V182.4a80.64 80.64 0 0 0-81.28-80.64z m17.28 620.16a17.28 17.28 0 0 1-17.28 17.28H168.96a17.28 17.28 0 0 1-17.28-17.28V182.4a17.28 17.28 0 0 1 17.28-16.64h686.08a17.28 17.28 0 0 1 17.28 16.64z" fill="#bfbfbf" p-id="6637"></path><path d="M721.28 289.28L557.44 492.16l-120.32-128a30.72 30.72 0 0 0-23.04-10.24 30.72 30.72 0 0 0-23.04 10.24l-123.52 128a32 32 0 0 0 46.72 44.16l99.84-104.32 121.6 128a33.28 33.28 0 0 0 23.68 16 30.08 30.08 0 0 0 23.68-12.16L768 328.96a31.36 31.36 0 1 0-49.28-39.68z" fill="#bfbfbf" p-id="6638"></path></svg>

+ 2 - 1
src/pages/adMonitor/adMonitorList/components/planDetail.tsx

@@ -9,6 +9,7 @@ import columns from './tableConfig'
 import { compare } from '@/utils/utils'
 import { formatDate, downloadFile1 } from '@/utils/downloadFile'
 import { downLoadSpeedApi } from "@/services/adMonitor/adMonitor";
+import '../index.less'
 
 type Props = {
     visible?: boolean,
@@ -77,7 +78,7 @@ function PlanDetail(props: Props) {
 
     return <Modal
         title={<><Space>
-            <span style={{ fontSize: 15, color: '#999' }}>计划名称:<span style={{ color: '#40a9ff' }}>{props?.data?.campaignName}</span></span>
+            <span style={{ fontSize: 15, color: '#999' }}>计划名称:<span style={{ color: '#40a9ff' }}>{props?.data?.campaignName || '--'}</span></span>
             &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
             <span style={{ fontSize: 15, color: '#999' }}>广告名称:<span style={{ color: '#40a9ff' }}>{props?.data?.adgroupName}</span></span>
         </Space></>}

+ 1 - 1
src/pages/adMonitor/adMonitorList/tablePlanListConfig.tsx

@@ -2,7 +2,7 @@ import { Statistic, Tooltip } from 'antd'
 import React from 'react'
 import './index.less'
 import { ReactComponent as RocketSvg } from '@/assets/rocket.svg'
-import { GOUMAILEIXING, GUANGGAOZHUANGTAI, TUIGUANGMUBIAO, CHUANGYIZHUANGTAI, YOUHUAMUBIAO, CHUJIAFANGSHI } from './enum'
+import { TUIGUANGMUBIAO, YOUHUAMUBIAO, CHUJIAFANGSHI } from './enum'
 import Box from './components/box'
 import { GGStateData } from './data'
 import { copy } from '@/utils/utils'

+ 14 - 2
src/pages/launchSystemNew/adq/ad/index.tsx

@@ -9,7 +9,7 @@ import { putAdqAdgroupsSync, getAdqAdgroupsList, delListAdqAdgroupsApi, newEditA
 import { CopyOutlined, DeleteOutlined, FieldTimeOutlined, PauseCircleOutlined, PlayCircleOutlined, TransactionOutlined } from '@ant-design/icons'
 import UpdateAd from './updateAd'
 import Copy from './copy'
-import { DataType } from '@/components/Tables'
+import PlanDetail from '@/pages/adMonitor/adMonitorList/components/planDetail'
 
 type Props = {
     accountId: string,
@@ -43,6 +43,8 @@ const Ad: React.FC<Props> = (props) => {
     const [update, setUpdate] = useState<{ visible: boolean, title: string }>({ visible: false, title: '' })
     const [model, setModel] = useState(true)
     const [copyData, setCopyData] = useState<{ visible: boolean }>({ visible: false })
+    const [detailShow, setDetailShow] = useState<boolean>(false)
+    const [detailData, setDetailData] = useState<any>({})
     const [queryFrom, set_queryFrom] = useState<{
         pageNum: number;
         pageSize: number;
@@ -163,12 +165,21 @@ const Ad: React.FC<Props> = (props) => {
     }
 
     const handleSave = (row: any) => {
+        const hide = message.loading(`广告“${row.adgroupId}”广告名称修改成<${row.adgroupName}>,修改中`, 0, () => {
+            message.success('修改成功');
+        });
         editAdqAdgroups.run({ adgroupIds: [row.adgroupId], adgroupName: row.adgroupName }).then(res => {
             message.success('修改广告名称成功')
             listAjax.refresh()
+            hide()
         })
     }
 
+    const details = (data: any) => {
+        setDetailData(data)
+        setDetailShow(true)
+    }
+
     return <div>
         {/* 修改广告 */}
         {update.visible && <UpdateAd
@@ -185,7 +196,7 @@ const Ad: React.FC<Props> = (props) => {
         {copyData.visible && <Copy selectedRows={selectedRows} {...copyData} onClose={() => setCopyData({ visible: false })} onChange={() => { setCopyData({ visible: false }); listAjax.refresh(); setSelectedRows([]) }} />}
         <TableData
             isCard={false}
-            columns={() => tableConfig(onChange, tableIdClick)}
+            columns={() => tableConfig(onChange, details, tableIdClick)}
             ajax={listAjax}
             syncAjax={sync}
             dataSource={listAjax?.data?.data?.records}
@@ -543,6 +554,7 @@ const Ad: React.FC<Props> = (props) => {
                 getList({...queryFrom, pageNum: current, pageSize })
             }}
         />
+        {detailShow && <PlanDetail visible={detailShow} onClose={() => { setDetailShow(false) }} data={detailData} />}
     </div>
 }
 export default Ad

+ 57 - 40
src/pages/launchSystemNew/adq/ad/tableConfig.tsx

@@ -1,12 +1,16 @@
 import { AdStatusEnum, BidModeEnum, BidStrategyEnum, OptimizationGoalEnum, PromotedObjectType } from '@/services/launchAdq/enum'
 import React from 'react'
-import { Badge, Switch } from 'antd'
+import { Badge, Space } from 'antd'
 import Box from '@/pages/adMonitor/adMonitorList/components/box'
-import { copy } from '@/utils/utils'
 import SwitchStatus from './switchStatus'
 import TimeSeriesLook from './timeSeriesLook'
+import { ReactComponent as RocketSvg } from '@/assets/rocket.svg'
+import '../index.less'
+import { CopyOutlined } from '@ant-design/icons'
+import { copy } from '@/utils/utils'
 function tableConfig(
     onChange: () => void,
+    details: (data: any) => void,
     tableIdClick: (props: {
         activeKey: string,
         parma: {
@@ -27,7 +31,7 @@ function tableConfig(
             width: 55,
             fixed: 'left',
             render: (a: string, b: any) => {
-                return <SwitchStatus configuredStatus={a} isDeleted={b?.isDeleted} adgroupId={b?.adgroupId} onChange={onChange}/>
+                return <SwitchStatus configuredStatus={a} isDeleted={b?.isDeleted} adgroupId={b?.adgroupId} onChange={onChange} />
             }
         },
         {
@@ -35,13 +39,15 @@ function tableConfig(
             dataIndex: 'accountId',
             key: 'accountId',
             align: 'center',
-            width: 70,
+            width: 100,
             fixed: 'left',
             ellipsis: true,
             render: (a: string) => {
-                return <a onClick={() => {
-                    tableIdClick({ activeKey: '1', parma: { accountId: a } })
-                }}>{a}</a>
+                return <Space>
+                    <a onClick={() => copy(a)} style={{color:'#00bcd4'}}><CopyOutlined /></a><a onClick={() => {
+                        tableIdClick({ activeKey: '1', parma: { accountId: a } })
+                    }}>{a}</a>
+                </Space>
             }
         },
         {
@@ -49,7 +55,7 @@ function tableConfig(
             dataIndex: 'memo',
             key: 'memo',
             align: 'center',
-            width: 100,
+            width: 90,
             fixed: 'left',
             ellipsis: true,
         },
@@ -58,7 +64,7 @@ function tableConfig(
             dataIndex: 'remark',
             key: 'remark',
             align: 'center',
-            width: 100,
+            width: 90,
             fixed: 'left',
             ellipsis: true,
         },
@@ -67,13 +73,16 @@ function tableConfig(
             dataIndex: 'adgroupId',
             key: 'adgroupId',
             align: 'center',
-            width: 85,
+            width: 120,
             fixed: 'left',
             ellipsis: true,
-            render: (a: string) => {
-                return <a onClick={() => {
-                    tableIdClick({ activeKey: '3', parma: { adgroupId: a } })
-                }}>{a}</a>
+            render: (a: string, b: any) => {
+                return <Space>
+                    <a onClick={() => copy(a)} style={{color:'#00bcd4'}}><CopyOutlined /></a>
+                    <a onClick={() => {
+                        tableIdClick({ activeKey: '3', parma: { adgroupId: a } })
+                    }}>{a}</a>
+                </Space>
             }
         },
         {
@@ -81,13 +90,16 @@ function tableConfig(
             dataIndex: 'campaignId',
             key: 'campaignId',
             align: 'center',
-            width: 85,
+            width: 120,
             fixed: 'left',
             ellipsis: true,
-            render: (a: string) => {
-                return <a onClick={() => {
-                    tableIdClick({ activeKey: '2', parma: { campaignId: a } })
-                }}>{a}</a>
+            render: (a: string, b: any) => {
+                return <Space >
+                    <a onClick={() => copy(a)} style={{color:'#00bcd4'}}><CopyOutlined /></a>
+                    <a onClick={() => {
+                        tableIdClick({ activeKey: '2', parma: { campaignId: a } })
+                    }}>{a}</a>
+                </Space>
             }
         },
         {
@@ -135,7 +147,7 @@ function tableConfig(
             align: 'center',
             width: 55,
             render: (a: string, b: { endDate: string }) => {
-                return <TimeSeriesLook timeSeries={a}/>
+                return <TimeSeriesLook timeSeries={a} />
             }
         },
         {
@@ -242,26 +254,31 @@ function tableConfig(
                 return <Box b={b} />
             }
         },
-        // {
-        //     title: '操作',
-        //     dataIndex: 'cz',
-        //     key: 'cz',
-        //     width: 65,
-        //     align: 'center',
-        //     fixed: 'right',
-        //     render: (a: any, b: any) => {
-        //         return <Space>
-        //             {b?.status !== 'STATUS_DELETED' && <Popconfirm
-        //                 title="确定删除?"
-        //                 onConfirm={() => deleteHandle(0, b?.adgroupId)}
-        //                 okText="是"
-        //                 cancelText="否"
-        //             >
-        //                 <Button danger type='text' size='small'>删除</Button>
-        //             </Popconfirm>}
-        //         </Space>
-        //     }
-        // },
+        {
+            title: '单位时间消耗速度',
+            dataIndex: 'costSpeed',
+            key: 'costSpeed',
+            align: 'center',
+            width: 80,
+            className: 'padding2',
+            fixed: 'right',
+            render: (a: any, b: any) => {
+                return <div style={{ display: 'flex', justifyContent: 'center', alignItems: 'center', lineHeight: 'normal', fontSize: 10 }}>
+                    <RocketSvg /> <a onClick={() => details(b)} style={{ marginLeft: 10 }}>详情</a>
+                </div>
+            }
+        },
+        {
+            title: '操作',
+            dataIndex: 'cz',
+            key: 'cz',
+            width: 65,
+            align: 'center',
+            fixed: 'right',
+            render: (a: any, b: any) => {
+                return <a style={{ color: '#1890ff' }} onClick={() => window.open(`https://ad.qq.com/atlas/${b?.accountId}/admanage/adcreative?adgroupid=${b?.adgroupId}&query={%22configured_status%22:[%22AD_STATUS_EXCLUDE_DELETED%22],%22status%22:[]}`)} target="_blank">腾讯广告</a>
+            }
+        },
     ]
 }
 export default tableConfig

+ 2 - 2
src/pages/launchSystemNew/adq/adAccount/index.tsx

@@ -29,7 +29,7 @@ type Props = {
     }) => void
 }
 function AdAccount(props: Props) {
-    let { adAccountId, userId } = props
+    let { adAccountId, userId ,tableIdClick} = props
     let [selectedRowKeys, setSelectedRowKeys] = useState<any[]>([])
     const [queryForm, setQueryForm] = useState<{
         pageNum: number;
@@ -63,7 +63,7 @@ function AdAccount(props: Props) {
     return <div>
         <TableData
             isCard={false}
-            columns={() => tableConfig()}
+            columns={() => tableConfig(tableIdClick)}
             ajax={listAjax}
             syncAjax={sync}
             dataSource={listAjax?.data?.data?.records}

+ 7 - 3
src/pages/launchSystemNew/adq/adAccount/tableConfig.tsx

@@ -1,8 +1,9 @@
 import { FundStatusEnum, } from '@/services/launchAdq/enum'
 import React from 'react'
-import { Badge } from 'antd'
+import { Badge, Space } from 'antd'
 import { copy } from '@/utils/utils'
-function tableConfig(): any {
+import { CopyOutlined } from '@ant-design/icons'
+function tableConfig(tableIdClick: any): any {
     return [
         {
             title: 'ID',
@@ -18,7 +19,10 @@ function tableConfig(): any {
             align: 'center',
             width: 90,
             render: (a: string) => {
-                return <a onClick={() => { copy(a) }}>{a}</a>
+                return <Space>
+                    <a onClick={() => copy(a)} style={{ color: '#00bcd4' }}><CopyOutlined /></a>
+                    <a onClick={() => tableIdClick({ activeKey: '1', parma: { accountId: a } })}>{a}</a>
+                </Space>
             }
         },
         {

+ 28 - 7
src/pages/launchSystemNew/adq/campaign/tableConfig.tsx

@@ -1,5 +1,7 @@
 import { CampaignTypeEnum, ConfiguredStatusEnum, PromotedObjectType, SpeedMode } from '@/services/launchAdq/enum'
-import { Badge, Switch } from 'antd'
+import { copy } from '@/utils/utils'
+import { CopyOutlined } from '@ant-design/icons'
+import { Badge, Space, Switch } from 'antd'
 import React from 'react'
 
 function tableConfig(
@@ -36,10 +38,14 @@ function tableConfig(
             align: 'center',
             width: 90,
             fixed: 'left',
+            ellipsis: true,
             render: (a: string) => {
-                return <a onClick={() => {
-                    tableIdClick({ activeKey: '1', parma: { accountId: a } })
-                }}>{a}</a>
+                return <Space>
+                    <a onClick={() => copy(a)} style={{ color: '#00bcd4' }}><CopyOutlined /></a>
+                    <a onClick={() => {
+                        tableIdClick({ activeKey: '1', parma: { accountId: a } })
+                    }}>{a}</a>
+                </Space>
             }
         },
         {
@@ -49,10 +55,14 @@ function tableConfig(
             align: 'center',
             width: 100,
             fixed: 'left',
+            ellipsis: true,
             render: (a: string) => {
-                return <a onClick={() => {
-                    tableIdClick({ activeKey: '2', parma: { campaignId: a } })
-                }}>{a}</a>
+                return <Space>
+                    <a onClick={() => copy(a)} style={{ color: '#00bcd4' }}><CopyOutlined /></a>
+                    <a onClick={() => {
+                        tableIdClick({ activeKey: '2', parma: { campaignId: a } })
+                    }}>{a}</a>
+                </Space>
             }
         },
         {
@@ -135,6 +145,17 @@ function tableConfig(
                 return <Badge status={a === 'AD_STATUS_NORMAL' ? "processing" : "error"} text={ConfiguredStatusEnum[a]} />
             }
         },
+        {
+            title: '操作',
+            dataIndex: 'cz',
+            key: 'cz',
+            width: 65,
+            align: 'center',
+            fixed: 'right',
+            render: (a: any, b: any) => {
+                return <a style={{ color: '#1890ff' }} onClick={() => window.open(`https://ad.qq.com/atlas/${b?.accountId}/admanage/adgroup?campaignid=${b?.campaignId}&query={%22operation_status%22:[%22CALCULATE_STATUS_EXCLUDE_DEL%22],%22system_status%22:[]}`)} target="_blank">腾讯计划</a>
+            }
+        },
     ]
 }
 export default tableConfig

+ 29 - 14
src/pages/launchSystemNew/adq/creative/tableConfig.tsx

@@ -1,4 +1,7 @@
 import { AdcreativeTemplateEnum, LinkPageNameTypeEnum, LinkPageTypeEnum, PromotedObjectType } from '@/services/launchAdq/enum'
+import { copy } from '@/utils/utils'
+import { CopyOutlined } from '@ant-design/icons'
+import { Space } from 'antd'
 import React from 'react'
 function tableConfig(tableIdClick: (props: {
     activeKey: string,
@@ -17,11 +20,15 @@ function tableConfig(tableIdClick: (props: {
             dataIndex: 'accountId',
             key: 'accountId',
             align: 'center',
-            width: 90,
+            width: 100,
+            ellipsis: true,
             render: (a: string) => {
-                return <a onClick={() => {
-                    tableIdClick({ activeKey: '1', parma: { accountId: a } })
-                }}>{a}</a>
+                return <Space>
+                    <a onClick={() => copy(a)} style={{ color: '#00bcd4' }}><CopyOutlined /></a>
+                    <a onClick={() => {
+                        tableIdClick({ activeKey: '1', parma: { accountId: a } })
+                    }}>{a}</a>
+                </Space>
             }
         },
         {
@@ -29,11 +36,15 @@ function tableConfig(tableIdClick: (props: {
             dataIndex: 'adcreativeId',
             key: 'adcreativeId',
             align: 'center',
-            width: 100,
+            width: 120,
+            ellipsis: true,
             render: (a: string) => {
-                return <a onClick={() => {
-                    tableIdClick({ activeKey: '4', parma: { adcreativeId: a } })
-                }}>{a}</a>
+                return <Space>
+                    <a onClick={() => copy(a)} style={{ color: '#00bcd4' }}><CopyOutlined /></a>
+                    <a onClick={() => {
+                        tableIdClick({ activeKey: '4', parma: { adcreativeId: a } })
+                    }}>{a}</a>
+                </Space>
             }
         },
         {
@@ -41,11 +52,15 @@ function tableConfig(tableIdClick: (props: {
             dataIndex: 'campaignId',
             key: 'campaignId',
             align: 'center',
-            width: 100,
+            width: 120,
+            ellipsis: true,
             render: (a: string) => {
-                return <a onClick={() => {
-                    tableIdClick({ activeKey: '2', parma: { campaignId: a } })
-                }}>{a}</a>
+                return <Space>
+                    <a onClick={() => copy(a)} style={{ color: '#00bcd4' }}><CopyOutlined /></a>
+                    <a onClick={() => {
+                        tableIdClick({ activeKey: '2', parma: { campaignId: a } })
+                    }}>{a}</a>
+                </Space>
             }
         },
         // {
@@ -228,7 +243,7 @@ function tableConfig(tableIdClick: (props: {
             dataIndex: 'adcreativeTemplateId',
             key: 'adcreativeTemplateId',
             align: 'center',
-            render:(a: string | number)=>{
+            render: (a: string | number) => {
                 return AdcreativeTemplateEnum[a]
             }
         },
@@ -303,7 +318,7 @@ function tableConfig(tableIdClick: (props: {
             dataIndex: 'createdTime',
             key: 'createdTime',
             align: 'center',
-            width:150
+            width: 150
         },
     ]
 }

+ 4 - 0
src/pages/launchSystemNew/adq/index.less

@@ -25,4 +25,8 @@
             z-index: 10;
         }
     }
+}
+
+.padding2 {
+    padding: 2px 5px !important;
 }

+ 8 - 2
src/pages/launchSystemNew/adq/landingPage/tableConfig.tsx

@@ -1,7 +1,8 @@
 import {  PageStatusEnum, PageTypeEnum, SourceTypeEnum } from '@/services/launchAdq/enum'
 import React from 'react'
-import { Badge } from 'antd'
+import { Badge, Space } from 'antd'
 import { copy } from '@/utils/utils'
+import { CopyOutlined } from '@ant-design/icons'
 function tableConfig(tableIdClick: any): any {
     return [
         {
@@ -10,8 +11,12 @@ function tableConfig(tableIdClick: any): any {
             key: 'accountId',
             align: 'center',
             width:100,
+            ellipsis: true,
             render:(a:string)=>{
-                return <a onClick={() => tableIdClick({ activeKey: '1', parma: { accountId: a } })}>{a}</a>
+                return <Space>
+                <a onClick={() => copy(a)} style={{ color: '#00bcd4' }}><CopyOutlined /></a>
+                <a onClick={() => tableIdClick({ activeKey: '1', parma: { accountId: a } })}>{a}</a>
+                </Space>
             }
         },
         {
@@ -20,6 +25,7 @@ function tableConfig(tableIdClick: any): any {
             key: 'pageId',
             align: 'center',
             width:100,
+            ellipsis: true,
             render:(a:string)=>{
                 return <a onClick={() => copy(a)}>{a}</a>
             }

+ 28 - 18
src/pages/launchSystemNew/adq/log/tableConfig.tsx

@@ -1,5 +1,6 @@
 import { copy } from "@/utils/utils"
-import { Badge } from "antd"
+import { CopyOutlined } from "@ant-design/icons"
+import { Badge, Space } from "antd"
 import React from "react"
 
 
@@ -20,13 +21,16 @@ function tableConfig(tableIdClick: (props: {
             dataIndex: 'accountId',
             key: 'accountId',
             align: 'center',
-            width: 70,
+            width: 100,
             fixed: 'left',
             ellipsis: true,
             render: (a: string) => {
-                return <a onClick={() => {
-                    tableIdClick({ activeKey: '1', parma: { accountId: a } })
-                }}>{a}</a>
+                return <Space>
+                    <a onClick={() => copy(a)} style={{ color: '#00bcd4' }}><CopyOutlined /></a>
+                    <a onClick={() => {
+                        tableIdClick({ activeKey: '1', parma: { accountId: a } })
+                    }}>{a}</a>
+                </Space>
             }
         },
         {
@@ -34,13 +38,16 @@ function tableConfig(tableIdClick: (props: {
             dataIndex: 'adgroupId',
             key: 'adgroupId',
             align: 'center',
-            width: 85,
+            width: 120,
             fixed: 'left',
             ellipsis: true,
             render: (a: string) => {
-                return <a onClick={() => {
-                    tableIdClick({ activeKey: '3', parma: { adgroupId: a } })
-                }}>{a}</a>
+                return <Space>
+                    <a onClick={() => copy(a)} style={{ color: '#00bcd4' }}><CopyOutlined /></a>
+                    <a onClick={() => {
+                        tableIdClick({ activeKey: '3', parma: { adgroupId: a } })
+                    }}>{a}</a>
+                </Space>
             }
         },
         {
@@ -48,13 +55,16 @@ function tableConfig(tableIdClick: (props: {
             dataIndex: 'campaignId',
             key: 'campaignId',
             align: 'center',
-            width: 85,
+            width: 120,
             fixed: 'left',
             ellipsis: true,
             render: (a: string) => {
-                return <a onClick={() => {
-                    tableIdClick({ activeKey: '2', parma: { campaignId: a } })
-                }}>{a}</a>
+                return <Space>
+                    <a onClick={() => copy(a)} style={{ color: '#00bcd4' }}><CopyOutlined /></a>
+                    <a onClick={() => {
+                        tableIdClick({ activeKey: '2', parma: { campaignId: a } })
+                    }}>{a}</a>
+                </Space>
             }
         },
         {
@@ -118,11 +128,11 @@ function tableConfig(tableIdClick: (props: {
             key: 'status',
             width: 70,
             align: 'center',
-            render: (a:any) => {
-                let obj={
-                    '成功':'success',
-                    '失败':'error',
-                    '执行中':'warning'
+            render: (a: any) => {
+                let obj = {
+                    '成功': 'success',
+                    '失败': 'error',
+                    '执行中': 'warning'
                 }
                 return <Badge status={obj[a]} text={a} />
             }

+ 9 - 3
src/pages/launchSystemNew/adq/targeting/tableConfig.tsx

@@ -1,7 +1,8 @@
 import { TargetingSourceTypeEnum, } from '@/services/launchAdq/enum'
 import React from 'react'
-import { Badge, Tooltip } from 'antd'
+import { Badge, Space, Tooltip } from 'antd'
 import { copy } from '@/utils/utils'
+import { CopyOutlined } from '@ant-design/icons'
 function tableConfig(tableIdClick: any): any {
     return [
         {
@@ -9,9 +10,13 @@ function tableConfig(tableIdClick: any): any {
             dataIndex: 'accountId',
             key: 'accountId',
             align: 'center',
-            width: 80,
+            width: 100,
+            ellipsis: true,
             render: (a: string) => {
-                return <a onClick={() => tableIdClick({ activeKey: '1', parma: { accountId: a } })}>{a}</a>
+                return <Space>
+                    <a onClick={() => copy(a)} style={{ color: '#00bcd4' }}><CopyOutlined /></a>
+                    <a onClick={() => tableIdClick({ activeKey: '1', parma: { accountId: a } })}>{a}</a>
+                </Space>
             }
         },
         {
@@ -20,6 +25,7 @@ function tableConfig(tableIdClick: any): any {
             key: 'targetingId',
             align: 'center',
             width: 100,
+            ellipsis: true,
             render: (a: string) => {
                 return <a onClick={() => copy(a)}>{a}</a>
             }

Някои файлове не бяха показани, защото твърде много файлове са промени