index.tsx 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547
  1. import { useAjax } from '@/Hook/useAjax'
  2. import { AdStatusEnum, PromotedObjectType } from '@/services/launchAdq/enum'
  3. import { Col, Row, Input, Select, message, Space, Button, Popconfirm, Switch, notification, Modal, Tooltip, Typography, Tag, Popover, Checkbox } from 'antd'
  4. import React, { useEffect, useCallback, useState } from 'react'
  5. import TableData from '../../components/TableData'
  6. import tableConfig from './tableConfig'
  7. import { putAdqAdgroupsSync, getAdqAdgroupsList, delListAdqAdgroupsApi, newEditAdqAdgroupsDataApi, editAdqAdgroupsDataApi, putAdqAdgroupsSyncBatch, putModifyCustomAudienceApi } from '@/services/launchAdq/adq'
  8. import { CopyOutlined, DeleteOutlined, FieldTimeOutlined, PauseCircleOutlined, PlayCircleOutlined, SyncOutlined, TransactionOutlined } from '@ant-design/icons'
  9. import UpdateAd from './updateAd'
  10. import Copy from './copy'
  11. import PlanDetail from '@/pages/adMonitor/adMonitorList/components/planDetail'
  12. import { txAdConfig } from '../config'
  13. import Log from '../log'
  14. import EarlyWarning from '@/components/EarlyWarning'
  15. import SetEarlyWarning from '@/components/EarlyWarning/setEarlyWarning'
  16. import CrowdPackModal from '../../components/crowdPackModal'
  17. type Props = {
  18. accountId?: string,
  19. adAccountId?: string,
  20. userId: string,
  21. Ts?: any,
  22. queryParmas?: {
  23. accountId?: string,//账户ID
  24. campaignId?: string,//计划ID
  25. adgroupId?: string,//广告ID
  26. adcreativeId?: string,//创意ID
  27. pageId?: string,//落地页ID
  28. targetingId?: string,//定向ID}
  29. },
  30. tableIdClick?: (props: {
  31. activeKey: string, parma: {
  32. accountId?: string,//账户ID
  33. campaignId?: string,//计划ID
  34. adgroupId?: string,//广告ID
  35. adcreativeId?: string,//创意ID
  36. pageId?: string,//落地页ID
  37. targetingId?: string,//定向ID
  38. }
  39. }) => void
  40. }
  41. const Ad: React.FC<Props> = (props) => {
  42. /***********************/
  43. let { accountId, adAccountId, userId, tableIdClick, queryParmas, Ts } = props
  44. const [selectedRows, setSelectedRows] = useState<any[]>([])
  45. const [update, setUpdate] = useState<{ visible: boolean, title: string }>({ visible: false, title: '' })
  46. const [model, setModel] = useState(true)
  47. const [copyData, setCopyData] = useState<{ visible: boolean }>({ visible: false })
  48. const [detailShow, setDetailShow] = useState<boolean>(false)
  49. const [detailData, setDetailData] = useState<any>({})
  50. const [czjlShow, setCzjlShow] = useState(false)
  51. const [cpVisible, setCpVisible] = useState(false)
  52. const [isClearSelect, setIsClearSelect] = useState(true)
  53. const [accountCreateLogs, setAccountCreateLogs] = useState<{ adAccountId: number, id: number, customAudienceList?: any[], excludedCustomAudienceList?: any[] }[]>([])
  54. const [queryFrom, set_queryFrom] = useState<{
  55. pageNum: number;
  56. pageSize: number;
  57. accountIdList?: any[];
  58. adgroupName?: string;
  59. adgroupIdList?: any[];
  60. promotedObjectType?: string;
  61. isDeleted?: boolean
  62. campaignIdList?: any[]
  63. statusList?: any[],
  64. memoList?: any[]
  65. remarkList?: any[]
  66. }>({ pageNum: 1, pageSize: 20 })
  67. const listAjax = useAjax((params) => getAdqAdgroupsList(params), { formatResult: true })
  68. const syncAjax = useAjax((adAccountId) => putAdqAdgroupsSync(adAccountId))
  69. const delListAdqAdgroups = useAjax((params) => delListAdqAdgroupsApi(params))
  70. const editAdqAdgroupsData = useAjax((params) => newEditAdqAdgroupsDataApi(params))
  71. const editAdqAdgroups = useAjax((params) => editAdqAdgroupsDataApi(params))
  72. const putModifyCustomAudience = useAjax((params) => putModifyCustomAudienceApi(params))
  73. const putAdqAdgroupsSyncBatchApi = useAjax((params) => putAdqAdgroupsSyncBatch(params))
  74. /************************/
  75. useEffect(() => {
  76. // let { accountId, campaignId, adgroupId, ...obj } = queryParmas
  77. // let new_queryParmas = {
  78. // ...obj,
  79. // accountIdList: accountId ? [accountId] : [],
  80. // campaignIdList: campaignId ? [campaignId] : [],
  81. // adgroupIdList: adgroupId ? [adgroupId] : []
  82. // }
  83. getList({ pageNum: 1, pageSize: 20 })
  84. }, [accountId, userId, queryParmas])
  85. // 获取列表
  86. const getList = useCallback((params: {
  87. pageNum: number;
  88. pageSize: number;
  89. accountIdList?: any[];
  90. adgroupName?: string;
  91. adgroupIdList?: any[];
  92. promotedObjectType?: string;
  93. isDeleted?: boolean
  94. campaignIdList?: any[]
  95. statusList?: any[],
  96. memoList?: any[]
  97. remarkList?: any[]
  98. }) => {
  99. listAjax.run({ ...params, userId })
  100. }, [userId, listAjax])
  101. // 同步
  102. const sync = useCallback(() => {
  103. // if (selectedRows?.length === 0) {
  104. // message.error('请先勾选要同步的广点通账号!')
  105. // return
  106. // }
  107. let arr = [...new Set(selectedRows?.map(item => item.accountId))]
  108. syncAjax.run({ accountIdList: arr }).then(res => {
  109. res && listAjax.refresh()
  110. res ? message.success('同步成功!') : message.error('同步失败!')
  111. })
  112. }, [listAjax, selectedRows])
  113. /** 删除 */
  114. const deleteHandle = (type: 0 | 1, adgroupId?: number) => {
  115. delListAdqAdgroups.run({ adgroupIds: type === 1 ? selectedRows.map(item => item.adgroupId) : [adgroupId] }).then(res => {
  116. message.success('删除成功')
  117. setSelectedRows([])
  118. listAjax.refresh()
  119. })
  120. }
  121. /** 修改排期出价 */
  122. const editScheduling = () => {
  123. setUpdate({ visible: true, title: '批量修改' })
  124. }
  125. /** 修改排期出价 */
  126. const editDeepConversion = () => {
  127. setUpdate({ visible: true, title: '批量修改深度优化' })
  128. }
  129. // 单个启停
  130. const onChange = () => {
  131. listAjax.refresh()
  132. setSelectedRows([])
  133. }
  134. // 批量启停
  135. const adStatus = (type: 'play' | 'suspend') => {
  136. let params: any = {}
  137. if (type === 'play') {
  138. params.configuredStatus = 'AD_STATUS_NORMAL'
  139. params.adgroupIds = selectedRows.filter((item: { configuredStatus: string, adgroupId: number }) => item.configuredStatus === 'AD_STATUS_SUSPEND').map(item => item.adgroupId)
  140. } else {
  141. params.configuredStatus = 'AD_STATUS_SUSPEND'
  142. params.adgroupIds = selectedRows.filter((item: { configuredStatus: string, adgroupId: number }) => item.configuredStatus === 'AD_STATUS_NORMAL').map(item => item.adgroupId)
  143. }
  144. if (params.adgroupIds.length === 0) {
  145. message.warn(`所以账号都是${type === 'play' ? '启动' : '暂停'}状态,无需${type === 'play' ? '启动' : '暂停'}操作`)
  146. return
  147. }
  148. editAdqAdgroupsData.run(params).then(res => {
  149. message.success(`${type === 'play' ? '启动' : '暂停'}成功: ${res.success},失败: ${res.fail}`)//
  150. if (res?.fail) {
  151. notification.error({
  152. message: `${type === 'play' ? '启动' : '暂停'}失败`,
  153. description: `成功: ${res.success},修改失败${res.fail}条,失败的请到任务列表查看`,
  154. duration: 0
  155. });
  156. }
  157. listAjax.refresh()
  158. setSelectedRows([])
  159. })
  160. }
  161. //同步广告
  162. const syncAd = useCallback(() => {
  163. putAdqAdgroupsSyncBatchApi.run({ adgroupIds: selectedRows?.map(item => item.adgroupId) }).then(res => {
  164. if (res) {
  165. message.success('同步成功!')
  166. listAjax.refresh()
  167. }
  168. })
  169. }, [selectedRows])
  170. // 批量复制
  171. const copyHandle = () => {
  172. setCopyData({ visible: true })
  173. }
  174. const handleSave = (row: any) => {
  175. const hide = message.loading(`广告“${row.adgroupId}”广告名称修改成<${row.adgroupName}>,修改中`, 0, () => {
  176. message.success('修改成功');
  177. });
  178. editAdqAdgroups.run({ adgroupIds: [row.adgroupId], adgroupName: row.adgroupName }).then(res => {
  179. message.success('修改广告名称成功')
  180. listAjax.refresh()
  181. hide()
  182. })
  183. }
  184. const handleSaveDaily = (row: any) => {
  185. console.log('row--->', row)
  186. const hide = message.loading(`广告“${row.adgroupId}”广告预算修改成<${row.dailyBudget}元>,修改中`, 0, () => {
  187. message.success('修改成功');
  188. });
  189. editAdqAdgroups.run({ adgroupIds: [row.adgroupId], dailyBudget: row.dailyBudget * 100 }).then(res => {
  190. message.success('修改广告预算成功')
  191. listAjax.refresh()
  192. hide()
  193. })
  194. }
  195. const details = (data: any) => {
  196. setDetailData(data)
  197. setDetailShow(true)
  198. }
  199. // 设置人群包
  200. const setRqb = () => {
  201. const { accountId } = selectedRows[0]
  202. setAccountCreateLogs([{ id: accountId, adAccountId: accountId }])
  203. setCpVisible(true)
  204. }
  205. // 确认提交人群包
  206. const handleRqb = (value: any[]) => {
  207. if ((value[0]?.customAudienceList && value[0]?.customAudienceList?.length > 0) || (value[0]?.excludedCustomAudienceList && value[0]?.excludedCustomAudienceList?.length > 0)) {
  208. let { adAccountId, customAudienceList = [], excludedCustomAudienceList = [] } = value[0]
  209. let adgroupIds = selectedRows.map((item: { adgroupId: number }) => item.adgroupId)
  210. let customAudienceIds = customAudienceList.map((item: { id: number }) => item.id)
  211. let excludedCustomAudienceIds = excludedCustomAudienceList.map((item: { id: number }) => item.id)
  212. const hide = message.loading('正在修改。。。', 0)
  213. setAccountCreateLogs([])
  214. setCpVisible(false)
  215. let params: any = { adAccountId, adgroupIds };
  216. if (excludedCustomAudienceIds.length > 0) {
  217. params['excludedCustomAudienceIds'] = excludedCustomAudienceIds
  218. }
  219. if (customAudienceIds?.length > 0) {
  220. params['customAudienceIds'] = customAudienceIds
  221. }
  222. putModifyCustomAudience.run(params).then(res => {
  223. hide()
  224. setSelectedRows([])
  225. message.success('修改成功,请到腾讯广告平台查看')
  226. }).catch(err => hide())
  227. } else {
  228. message.error('请选择用户群')
  229. }
  230. }
  231. return <div>
  232. {/* 修改广告 */}
  233. {update.visible && <UpdateAd
  234. {...update}
  235. selectedRows={selectedRows}
  236. onChange={() => {
  237. setUpdate({ visible: false, title: '' })
  238. listAjax.refresh()
  239. setSelectedRows([])
  240. }}
  241. onClose={() => { setUpdate({ visible: false, title: '' }) }}
  242. />}
  243. {/* 复制广告 */}
  244. {copyData.visible && <Copy selectedRows={selectedRows} {...copyData} onClose={() => setCopyData({ visible: false })} onChange={() => { setCopyData({ visible: false }); listAjax.refresh(); setSelectedRows([]) }} />}
  245. <Row gutter={[6, 6]} align='middle' style={{ marginBottom: 15 }}>
  246. <Col>
  247. {Ts && Ts()}
  248. </Col>
  249. <Col>
  250. <Input
  251. placeholder='广告账号'
  252. allowClear
  253. style={{ width: 120 }}
  254. onChange={(e) => {
  255. let value = e.target.value
  256. let arr: any = []
  257. if (value) {
  258. value = value.replace(/[,,\s]/g, ',')
  259. arr = value.split(',').filter((a: any) => a)
  260. }
  261. set_queryFrom({ ...queryFrom, accountIdList: arr })
  262. }}
  263. />
  264. </Col>
  265. <Col>
  266. <Input
  267. placeholder='广告名称'
  268. allowClear
  269. style={{ width: 120 }}
  270. onChange={(e) => {
  271. let value = e.target.value
  272. set_queryFrom({ ...queryFrom, adgroupName: value })
  273. }}
  274. />
  275. </Col>
  276. <Col>
  277. <Input
  278. placeholder='广告ID'
  279. allowClear
  280. style={{ width: 120 }}
  281. onChange={(e) => {
  282. let value = e.target.value
  283. let arr: any = []
  284. if (value) {
  285. value = value.replace(/[,,\s]/g, ',')
  286. arr = value.split(',').filter((a: any) => a)
  287. }
  288. set_queryFrom({ ...queryFrom, adgroupIdList: arr })
  289. }}
  290. />
  291. </Col>
  292. <Col>
  293. <Input
  294. placeholder='计划ID'
  295. allowClear
  296. style={{ width: 120 }}
  297. onChange={(e) => {
  298. let value = e.target.value
  299. let arr: any = []
  300. if (value) {
  301. value = value.replace(/[,,\s]/g, ',')
  302. arr = value.split(',').filter((a: any) => a)
  303. }
  304. set_queryFrom({ ...queryFrom, campaignIdList: arr })
  305. }}
  306. />
  307. </Col>
  308. <Col>
  309. <Select
  310. placeholder='推广目标选择'
  311. style={{ width: 120 }}
  312. showSearch
  313. filterOption={(input: any, option: any) =>
  314. (option!.children as unknown as string).toLowerCase().includes(input.toLowerCase())
  315. }
  316. allowClear
  317. onChange={(value: any) => {
  318. set_queryFrom({ ...queryFrom, promotedObjectType: value })
  319. }}
  320. >
  321. {Object.keys(PromotedObjectType).map(key => {
  322. return <Select.Option value={key} key={key}>{PromotedObjectType[key]}</Select.Option>
  323. })}
  324. </Select>
  325. </Col>
  326. <Col>
  327. <Select
  328. placeholder='是否已删除'
  329. style={{ width: 120 }}
  330. showSearch
  331. filterOption={(input: any, option: any) =>
  332. (option!.children as unknown as string).toLowerCase().includes(input.toLowerCase())
  333. }
  334. allowClear
  335. onChange={(value: any) => {
  336. set_queryFrom({ ...queryFrom, isDeleted: value })
  337. }}
  338. >
  339. <Select.Option value={true}>已删除</Select.Option>
  340. <Select.Option value={false}>未删除</Select.Option>
  341. </Select>
  342. </Col>
  343. <Col>
  344. <Select
  345. placeholder='广告状态'
  346. mode="multiple"
  347. style={{ width: 120 }}
  348. showSearch
  349. filterOption={(input: any, option: any) =>
  350. (option!.children as unknown as string).toLowerCase().includes(input.toLowerCase())
  351. }
  352. allowClear
  353. onChange={(value: any) => {
  354. set_queryFrom({ ...queryFrom, statusList: value })
  355. }}
  356. >
  357. {
  358. Object.keys(AdStatusEnum).map(key => {
  359. return <Select.Option value={key} key={key}>{AdStatusEnum[key]}</Select.Option>
  360. })
  361. }
  362. </Select>
  363. </Col>
  364. <Col>
  365. <Input
  366. placeholder='腾讯备注'
  367. allowClear
  368. style={{ width: 120 }}
  369. onChange={(e) => {
  370. let value = e.target.value
  371. let arr: any = []
  372. if (value) {
  373. value = value.replace(/[,,\s]/g, ',')
  374. arr = value.split(',').filter((a: any) => a)
  375. }
  376. set_queryFrom({ ...queryFrom, memoList: arr })
  377. }}
  378. />
  379. </Col>
  380. <Col>
  381. <Input
  382. placeholder='本地备注'
  383. allowClear
  384. style={{ width: 120 }}
  385. onChange={(e) => {
  386. let value = e.target.value
  387. let arr: any = []
  388. if (value) {
  389. value = value.replace(/[,,\s]/g, ',')
  390. arr = value.split(',').filter((a: any) => a)
  391. }
  392. set_queryFrom({ ...queryFrom, remarkList: arr })
  393. }}
  394. />
  395. </Col>
  396. <Col>
  397. <Space>
  398. <Button type='primary' onClick={() => {
  399. if (isClearSelect) {
  400. setSelectedRows([])
  401. }
  402. getList({ ...queryFrom, pageNum: 1 })
  403. }}>搜索</Button>
  404. <Checkbox checked={isClearSelect} onChange={(e) => setIsClearSelect(e.target.checked)}>搜索清空已选</Checkbox>
  405. {selectedRows?.length > 0 && <Button type='link' style={{ padding: 0, color: 'red' }} onClick={() => {
  406. setSelectedRows([])
  407. }}>清空已选</Button>}
  408. </Space>
  409. </Col>
  410. </Row>
  411. <TableData
  412. isCard={false}
  413. columns={() => tableConfig(onChange, details, handleSave, handleSaveDaily)}
  414. ajax={listAjax}
  415. syncAjax={sync}
  416. fixed={{ left: 2, right: 4 }}
  417. dataSource={listAjax?.data?.data?.records}
  418. loading={listAjax?.loading || syncAjax?.loading}
  419. scroll={{ y: 560 }}
  420. total={listAjax?.data?.data?.total}
  421. page={listAjax?.data?.data?.current}
  422. pageSize={listAjax?.data?.data?.size}
  423. myKey={'adgroupId'}
  424. gutter={[0, 10]}
  425. config={txAdConfig}
  426. configName="腾讯广告"
  427. leftChild={<Space direction='vertical'>
  428. <Row gutter={[10, 10]} align='middle'>
  429. <Col>
  430. <Switch checkedChildren="普通" unCheckedChildren="ROI" checked={model} onChange={(checked) => { setModel(checked); setSelectedRows([]) }} style={model ? {} : { background: '#67c23a' }} />
  431. </Col>
  432. {model ? <>
  433. <Col><Button type='primary' style={{ background: '#1890ff' }} icon={<FieldTimeOutlined />} disabled={selectedRows.length === 0} onClick={editScheduling}>修改排期出价名称</Button></Col>
  434. <Col><Button type='primary' style={{ background: '#1890ff' }} icon={<CopyOutlined />} disabled={selectedRows.length === 0} onClick={copyHandle}>复制</Button></Col>
  435. <Col><Button type='primary' style={{ background: '#67c23a', borderColor: '#67c23a' }} loading={editAdqAdgroupsData.loading} icon={<PlayCircleOutlined />} disabled={selectedRows.length === 0} onClick={() => adStatus('play')}>启动</Button></Col>
  436. <Col><Button type='primary' style={{ background: '#e6a23c', borderColor: '#e6a23c' }} loading={editAdqAdgroupsData.loading} icon={<PauseCircleOutlined />} disabled={selectedRows.length === 0} onClick={() => adStatus('suspend')}>暂停</Button></Col>
  437. <Col><Tooltip title="2023/4/20 16:20:00刷新页面后平台创建的广告可修改,或者其它平台使用定向包创建广告可用">
  438. <Button type='primary' loading={putModifyCustomAudience.loading} disabled={selectedRows.length > 0 ? !selectedRows.every((item: { accountId: number }) => item.accountId === selectedRows[0].accountId) : true} onClick={() => setRqb()}>修改人群包</Button>
  439. </Tooltip></Col>
  440. <Col><Button type='primary' style={{ background: '#00bcd4', borderColor: '#00bcd4' }} loading={putAdqAdgroupsSyncBatchApi.loading} icon={<SyncOutlined />} disabled={selectedRows.length === 0} onClick={syncAd}>同步广告</Button></Col>
  441. <Col><SetEarlyWarning selectedRows={selectedRows} onChange={() => listAjax.refresh()} /></Col>
  442. <Col>
  443. <Popconfirm
  444. title="确定删除?"
  445. onConfirm={() => deleteHandle(1)}
  446. okText="是"
  447. cancelText="否"
  448. disabled={selectedRows.length === 0}
  449. >
  450. <Button danger type='primary' loading={delListAdqAdgroups.loading} icon={<DeleteOutlined />} disabled={selectedRows.length === 0}>删除</Button>
  451. </Popconfirm>
  452. </Col>
  453. </> : <Col><Button type='primary' icon={<TransactionOutlined />} disabled={selectedRows.length === 0} onClick={editDeepConversion}>修改深度优化ROI</Button></Col>}
  454. <Col>
  455. <Button type='dashed' onClick={() => { setCzjlShow(true) }}>操作记录</Button>
  456. </Col>
  457. <Col>
  458. <EarlyWarning />
  459. </Col>
  460. </Row>
  461. </Space>}
  462. rowSelection={{
  463. selectedRowKeys: selectedRows.map(item => item.adgroupId.toString()),
  464. getCheckboxProps: (record: any) => ({
  465. disabled: model ?
  466. record.status === 'STATUS_DELETED' :
  467. record.status === 'STATUS_DELETED' ||
  468. !(!model &&
  469. record?.promotedObjectType === 'PROMOTED_OBJECT_TYPE_WECHAT_OFFICIAL_ACCOUNT' &&
  470. record?.optimizationGoal === 'OPTIMIZATIONGOAL_FOLLOW' &&
  471. record?.deepConversionSpec?.deepConversionWorthSpec?.goal === 'GOAL_1DAY_PURCHASE_ROAS'
  472. )
  473. }),
  474. onSelect: (record: { adgroupId: number, mpName: string }, selected: boolean) => {
  475. if (selected) {
  476. selectedRows.push({ ...record })
  477. setSelectedRows([...selectedRows])
  478. } else {
  479. let newSelectAccData = selectedRows.filter((item: { adgroupId: number }) => item.adgroupId !== record.adgroupId)
  480. setSelectedRows([...newSelectAccData])
  481. }
  482. },
  483. onSelectAll: (selected: boolean, selectedRowss: { adgroupId: number }[], changeRows: { adgroupId: number }[]) => {
  484. if (selected) {
  485. let newSelectAccData = [...selectedRows]
  486. changeRows.forEach((item: { adgroupId: number }) => {
  487. let index = newSelectAccData.findIndex((ite: { adgroupId: number }) => ite.adgroupId === item.adgroupId)
  488. if (index === -1) {
  489. newSelectAccData.push({ ...item })
  490. }
  491. })
  492. setSelectedRows([...newSelectAccData])
  493. } else {
  494. let newSelectAccData = selectedRows.filter((item: { adgroupId: number }) => {
  495. let index = changeRows.findIndex((ite: { adgroupId: number }) => ite.adgroupId === item.adgroupId)
  496. if (index !== -1) {
  497. return false
  498. } else {
  499. return true
  500. }
  501. })
  502. setSelectedRows([...newSelectAccData])
  503. }
  504. }
  505. }}
  506. onChange={(props: any) => {
  507. let { sortData, pagination } = props
  508. let { current, pageSize } = pagination
  509. // console.log(pagination)
  510. // console.log({...queryFrom, pageNum: current, pageSize })
  511. set_queryFrom({ ...queryFrom, pageNum: current, pageSize })
  512. getList({ ...queryFrom, pageNum: current, pageSize })
  513. }}
  514. />
  515. {detailShow && <PlanDetail visible={detailShow} onClose={() => { setDetailShow(false) }} data={detailData} />}
  516. {czjlShow && <Modal
  517. visible={czjlShow}
  518. onCancel={() => { setCzjlShow(false) }}
  519. onOk={() => { setCzjlShow(false) }}
  520. width={1200}
  521. footer={null}
  522. title={"广告操作记录"}
  523. >
  524. <Log {...props} />
  525. </Modal>}
  526. {cpVisible && <CrowdPackModal visible={cpVisible} data={accountCreateLogs} onClose={() => setCpVisible(false)} onChange={(e) => { handleRqb(e) }} />}
  527. </div>
  528. }
  529. export default Ad