|
@@ -30,6 +30,9 @@ function tablePlanConfig(
|
|
|
width: 40,
|
|
|
fixed: 'left',
|
|
|
render: (a: string, b: any) => {
|
|
|
+ if (b?.account_id === '总计') {
|
|
|
+ return '--'
|
|
|
+ }
|
|
|
return <SwitchStatus configuredStatus={a} isDeleted={b?.is_deleted} adgroupId={b?.adgroup_id} onChange={onChange} />
|
|
|
}
|
|
|
},
|
|
@@ -53,6 +56,12 @@ function tablePlanConfig(
|
|
|
align: 'center',
|
|
|
width: 80,
|
|
|
ellipsis: true,
|
|
|
+ render(value, record) {
|
|
|
+ if (record?.account_id === '总计') {
|
|
|
+ return '--'
|
|
|
+ }
|
|
|
+ return value
|
|
|
+ },
|
|
|
},
|
|
|
{
|
|
|
title: '本地备注',
|
|
@@ -61,6 +70,12 @@ function tablePlanConfig(
|
|
|
align: 'center',
|
|
|
width: 80,
|
|
|
ellipsis: true,
|
|
|
+ render(value, record) {
|
|
|
+ if (record?.account_id === '总计') {
|
|
|
+ return '--'
|
|
|
+ }
|
|
|
+ return value
|
|
|
+ },
|
|
|
},
|
|
|
{
|
|
|
title: '广告ID',
|
|
@@ -70,6 +85,9 @@ function tablePlanConfig(
|
|
|
width: 100,
|
|
|
ellipsis: true,
|
|
|
render: (a: string, b: any) => {
|
|
|
+ if (b?.account_id === '总计') {
|
|
|
+ return '--'
|
|
|
+ }
|
|
|
return <Space>
|
|
|
<a onClick={() => copy(a)} >{a}</a>
|
|
|
</Space>
|
|
@@ -83,6 +101,7 @@ function tablePlanConfig(
|
|
|
width: 100,
|
|
|
ellipsis: true,
|
|
|
render: (a: string, b: any) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return <Space >
|
|
|
<a onClick={() => copy(a)} >{a}</a>
|
|
|
</Space>
|
|
@@ -94,7 +113,11 @@ function tablePlanConfig(
|
|
|
key: 'put_user_name',
|
|
|
align: 'center',
|
|
|
width: 70,
|
|
|
- ellipsis: true
|
|
|
+ ellipsis: true,
|
|
|
+ render(value, record) {
|
|
|
+ if (record?.account_id === '总计') return '--';
|
|
|
+ return value
|
|
|
+ },
|
|
|
},
|
|
|
{
|
|
|
title: '广告名称',
|
|
@@ -103,6 +126,7 @@ function tablePlanConfig(
|
|
|
width: 280,
|
|
|
ellipsis: true,
|
|
|
render: (a: string, b: any) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return <InputUpdate title={a} dataIndex={'adgroup_name'} record={b} handleSave={handleSave} />
|
|
|
}
|
|
|
},
|
|
@@ -113,7 +137,8 @@ function tablePlanConfig(
|
|
|
align: 'center',
|
|
|
width: 75,
|
|
|
ellipsis: true,
|
|
|
- render: (a: string | number) => {
|
|
|
+ render: (a: string | number, b) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return PromotedObjectType[a]
|
|
|
}
|
|
|
},
|
|
@@ -125,7 +150,8 @@ function tablePlanConfig(
|
|
|
width: 150,
|
|
|
ellipsis: true,
|
|
|
sorter: true,
|
|
|
- render: (a: string, b: { end_date: string }) => {
|
|
|
+ render: (a: string, b: { end_date: string, account_id: any }) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return b?.end_date && b?.end_date !== '1970-01-01' ? a + '~' + b.end_date : a + '~' + '长期投放'
|
|
|
}
|
|
|
},
|
|
@@ -135,7 +161,8 @@ function tablePlanConfig(
|
|
|
key: 'time_series',
|
|
|
align: 'center',
|
|
|
width: 55,
|
|
|
- render: (a: string, b: { endDate: string }) => {
|
|
|
+ render: (a: string, b: { endDate: string, account_id: string }) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return <TimeSeriesLook timeSeries={a} />
|
|
|
}
|
|
|
},
|
|
@@ -145,6 +172,10 @@ function tablePlanConfig(
|
|
|
key: 'first_day_begin_time',
|
|
|
align: 'center',
|
|
|
width: 70,
|
|
|
+ render(value, record) {
|
|
|
+ if (record?.account_id === '总计') return '--';
|
|
|
+ return value
|
|
|
+ },
|
|
|
},
|
|
|
{
|
|
|
title: '出价',
|
|
@@ -153,7 +184,8 @@ function tablePlanConfig(
|
|
|
width: 140,
|
|
|
ellipsis: true,
|
|
|
sorter: true,
|
|
|
- render: (a: string, b: { bid_mode: string, optimization_goal: string }) => {
|
|
|
+ render: (a: string, b: { bid_mode: string, optimization_goal: string, account_id: any }) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return `${b?.bid_mode ? BidModeEnum[b?.bid_mode] : ''} ${a}元/${b?.bid_mode === 'BID_MODE_CPM' ? '千次曝光' : b?.bid_mode === 'BID_MODE_CPC' ? '点击' : OptimizationGoalEnum[b?.optimization_goal]}`
|
|
|
}
|
|
|
},
|
|
@@ -164,7 +196,8 @@ function tablePlanConfig(
|
|
|
width: 70,
|
|
|
align: 'center',
|
|
|
ellipsis: true,
|
|
|
- render: (a: string, b: { deep_conversion_spec_json: any }) => {
|
|
|
+ render: (a: string, b: { deep_conversion_spec_json: any, account_id: any }) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
if (b?.deep_conversion_spec_json) {
|
|
|
return JSON.parse(b?.deep_conversion_spec_json)?.deepConversionWorthSpec?.expectedRoi || '--'
|
|
|
} else {
|
|
@@ -180,7 +213,8 @@ function tablePlanConfig(
|
|
|
align: 'center',
|
|
|
width: 80,
|
|
|
ellipsis: true,
|
|
|
- render: (a: string) => {
|
|
|
+ render: (a: string, b) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return a === 'SMART_BID_TYPE_CUSTOM' ? '手动出价' : '自动出价'
|
|
|
}
|
|
|
},
|
|
@@ -191,7 +225,8 @@ function tablePlanConfig(
|
|
|
align: 'center',
|
|
|
width: 70,
|
|
|
ellipsis: true,
|
|
|
- render: (a: string) => {
|
|
|
+ render: (a: string, b) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return BidStrategyEnum[a]
|
|
|
}
|
|
|
},
|
|
@@ -203,6 +238,7 @@ function tablePlanConfig(
|
|
|
width: 70,
|
|
|
sorter: true,
|
|
|
render: (a: string, b: any) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return <InputUpdate title={a} isNum={true} dataIndex={'daily_budget'} record={b} handleSave={handleSaveDaily} />
|
|
|
}
|
|
|
},
|
|
@@ -213,6 +249,7 @@ function tablePlanConfig(
|
|
|
align: 'center',
|
|
|
width: 80,
|
|
|
render: (a: any, b: any) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return a ? '开' : '关'
|
|
|
}
|
|
|
},
|
|
@@ -223,6 +260,10 @@ function tablePlanConfig(
|
|
|
align: 'center',
|
|
|
width: 140,
|
|
|
ellipsis: true,
|
|
|
+ render(value, record) {
|
|
|
+ if (record?.account_id === '总计') return '--';
|
|
|
+ return value
|
|
|
+ },
|
|
|
},
|
|
|
{
|
|
|
title: '是否已删除',
|
|
@@ -231,6 +272,7 @@ function tablePlanConfig(
|
|
|
align: 'center',
|
|
|
width: 60,
|
|
|
render: (a: any, b: any) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return <Badge status={!a ? "processing" : "error"} text={a ? '是' : '否'} />
|
|
|
}
|
|
|
},
|
|
@@ -242,6 +284,7 @@ function tablePlanConfig(
|
|
|
width: 70,
|
|
|
ellipsis: true,
|
|
|
render: (a: string, b: any) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return b?.rejectMessageList?.filter((str: any) => str)?.length > 0 ? <Popover
|
|
|
style={{ width: 500 }}
|
|
|
overlayStyle={{ width: 500, fontSize: 12 }}
|
|
@@ -261,6 +304,7 @@ function tablePlanConfig(
|
|
|
width: 70,
|
|
|
align: 'center',
|
|
|
render: (a: any, b: any) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return <Box b={b?.creative_preivew} />
|
|
|
}
|
|
|
},
|
|
@@ -271,7 +315,8 @@ function tablePlanConfig(
|
|
|
align: 'center',
|
|
|
width: 100,
|
|
|
ellipsis: true,
|
|
|
- render(value, record, index) {
|
|
|
+ render(value, b) {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return value || '--'
|
|
|
},
|
|
|
},
|
|
@@ -283,6 +328,7 @@ function tablePlanConfig(
|
|
|
width: 80,
|
|
|
className: 'padding2',
|
|
|
render: (a: any, b: any) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return <div style={{ display: 'flex', justifyContent: 'center', alignItems: 'center', lineHeight: 'normal', fontSize: 14 }}>
|
|
|
<RocketSvg /> <a onClick={() => details(b)} style={{ marginLeft: 10 }}>详情</a>
|
|
|
</div>
|
|
@@ -295,6 +341,7 @@ function tablePlanConfig(
|
|
|
width: 130,
|
|
|
align: 'center',
|
|
|
render: (a: any, b: any) => {
|
|
|
+ if (b?.account_id === '总计') return '--';
|
|
|
return <Space>
|
|
|
<Dropdown overlay={<Menu>
|
|
|
<Menu.Item><a onClick={() => log(b)}>告警日志</a></Menu.Item>
|
|
@@ -310,15 +357,6 @@ function tablePlanConfig(
|
|
|
]
|
|
|
|
|
|
let adDataArr: ColumnsType<any> = [
|
|
|
- {
|
|
|
- title: '数据更新时间',
|
|
|
- dataIndex: 'create_time',
|
|
|
- key: 'create_time',
|
|
|
- align: 'center',
|
|
|
- width: 120,
|
|
|
- sorter: true,
|
|
|
- ellipsis: true
|
|
|
- },
|
|
|
{
|
|
|
title: '消耗',
|
|
|
dataIndex: 'cost_total',
|