|
@@ -121,6 +121,9 @@
|
|
}
|
|
}
|
|
|
|
|
|
}
|
|
}
|
|
|
|
+ .zidingyirenqun{
|
|
|
|
+ width: 60%;
|
|
|
|
+ }
|
|
}
|
|
}
|
|
.rightBox{
|
|
.rightBox{
|
|
position: fixed;
|
|
position: fixed;
|
|
@@ -495,7 +498,7 @@
|
|
</a-radio-group>
|
|
</a-radio-group>
|
|
<span class="tishi"><a-icon type="exclamation-circle" class="tubiao" />精选流量包仅支持穿山甲、穿山甲-精选游戏广告位</span>
|
|
<span class="tishi"><a-icon type="exclamation-circle" class="tubiao" />精选流量包仅支持穿山甲、穿山甲-精选游戏广告位</span>
|
|
</a-form-item>
|
|
</a-form-item>
|
|
- <a-form-item label="自定义人群" :label-col="labelCol" :wrapper-col="wrapperCol">
|
|
|
|
|
|
+ <a-form-item label="自定义人群" :label-col="labelCol" :wrapper-col="wrapperCol" v-if="accountInfo.value!=undefined">
|
|
<a-radio-group v-model="customCrowd" button-style="solid">
|
|
<a-radio-group v-model="customCrowd" button-style="solid">
|
|
<a-radio-button value="NONE">不限</a-radio-button>
|
|
<a-radio-button value="NONE">不限</a-radio-button>
|
|
<a-radio-button value="CUSTOMt_CROWED">自定义人群</a-radio-button>
|
|
<a-radio-button value="CUSTOMt_CROWED">自定义人群</a-radio-button>
|
|
@@ -508,17 +511,78 @@
|
|
<a-radio-button value="ALL">同时定向排除</a-radio-button>
|
|
<a-radio-button value="ALL">同时定向排除</a-radio-button>
|
|
</a-radio-group>
|
|
</a-radio-group>
|
|
<div class="zidingyirenqun" v-if="customCrowd=='CUSTOMt_CROWED'">
|
|
<div class="zidingyirenqun" v-if="customCrowd=='CUSTOMt_CROWED'">
|
|
- <a-input placeholder="请输入人群包名称或者ID" v-model="dxInputValue" v-if="directLogic!='ALL'" style="width:50%">
|
|
|
|
|
|
+ <!-- <a-input placeholder="请输入人群包名称或者ID" v-model="dxInputValue" v-if="directLogic!='ALL'" style="width:50%;margin:15px 0">
|
|
<a-icon type="search" slot="addonAfter"/>
|
|
<a-icon type="search" slot="addonAfter"/>
|
|
- </a-input>
|
|
|
|
|
|
+ </a-input> -->
|
|
<div class="dingxiang" v-if="directLogic=='RETARGETING_INCLUDE'">
|
|
<div class="dingxiang" v-if="directLogic=='RETARGETING_INCLUDE'">
|
|
-
|
|
|
|
|
|
+ <a-table
|
|
|
|
+ :columns="retargetColumns"
|
|
|
|
+ :row-key="record => record.key"
|
|
|
|
+ :data-source="retargetData"
|
|
|
|
+ :loading="loading"
|
|
|
|
+ style="width:60%;margin:15px 0"
|
|
|
|
+ :pagination='false'
|
|
|
|
+ @change="retargetTableChange"
|
|
|
|
+ bordered
|
|
|
|
+ :scroll="{ y: 250 }"
|
|
|
|
+ :row-selection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
|
|
|
|
+ >
|
|
|
|
+ <template slot="name" slot-scope="name,records"> {{ name }}({{records.key}}) </template>
|
|
|
|
+ </a-table>
|
|
</div>
|
|
</div>
|
|
<div class="paichu" v-if="directLogic=='RETARGETING_EXCLUDE'">
|
|
<div class="paichu" v-if="directLogic=='RETARGETING_EXCLUDE'">
|
|
-
|
|
|
|
|
|
+ <a-table
|
|
|
|
+ :columns="retargetColumns"
|
|
|
|
+ :row-key="record => record.key"
|
|
|
|
+ :data-source="retargetData"
|
|
|
|
+ :loading="loading"
|
|
|
|
+ style="width:60%;margin:15px 0"
|
|
|
|
+ :pagination='false'
|
|
|
|
+ @change="retargetTableChange"
|
|
|
|
+ :scroll="{ y: 250 }"
|
|
|
|
+ :row-selection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
|
|
|
|
+ bordered
|
|
|
|
+ >
|
|
|
|
+ <template slot="name" slot-scope="name,records"> {{ name }}({{records.key}}) </template>
|
|
|
|
+ </a-table>
|
|
</div>
|
|
</div>
|
|
- <div class="dingxiang_paichu" v-if="directLogic=='ALL'">
|
|
|
|
-
|
|
|
|
|
|
+ <div class="dingxiang_paichu" v-if="directLogic=='ALL'" style="width:60%">
|
|
|
|
+ <a-tabs default-active-key="1" @change="retargetTabChange" >
|
|
|
|
+ <a-tab-pane key="1" tab="定向池">
|
|
|
|
+ <a-table
|
|
|
|
+ :columns="retargetColumns"
|
|
|
|
+ :row-key="record => record.key"
|
|
|
|
+ :data-source="retargetDataAll"
|
|
|
|
+ :loading="loading"
|
|
|
|
+ style="width:100%;margin:15px 0"
|
|
|
|
+ :pagination='false'
|
|
|
|
+ @change="retargetTableChange"
|
|
|
|
+ :scroll="{ y: 250 }"
|
|
|
|
+ :row-selection="rowSelection"
|
|
|
|
+ bordered
|
|
|
|
+ >
|
|
|
|
+ <template slot="name" slot-scope="name,records"> {{ name }}({{records.key}}) </template>
|
|
|
|
+ </a-table>
|
|
|
|
+ </a-tab-pane>
|
|
|
|
+ <a-tab-pane key="2" tab="排除池" >
|
|
|
|
+ <a-table
|
|
|
|
+ :columns="retargetColumns"
|
|
|
|
+ :row-key="record => record.key"
|
|
|
|
+ :data-source="retargetDataAll"
|
|
|
|
+ :loading="loading"
|
|
|
|
+ style="width:100%;margin:15px 0"
|
|
|
|
+ :pagination='false'
|
|
|
|
+ @change="retargetTableChange"
|
|
|
|
+ :scroll="{ y: 250 }"
|
|
|
|
+ :row-selection="rowSelection2"
|
|
|
|
+ bordered
|
|
|
|
+ >
|
|
|
|
+ <template slot="name" slot-scope="name,records"> {{ name }}({{records.key}}) </template>
|
|
|
|
+ </a-table>
|
|
|
|
+ </a-tab-pane>
|
|
|
|
+
|
|
|
|
+ </a-tabs>
|
|
|
|
+
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</a-form-item>
|
|
</a-form-item>
|
|
@@ -1009,6 +1073,26 @@ let autoExtendOptions=[
|
|
},
|
|
},
|
|
]
|
|
]
|
|
|
|
|
|
|
|
+let retargetColumns=[
|
|
|
|
+ {
|
|
|
|
+ title: '人群包',
|
|
|
|
+ dataIndex: 'name',
|
|
|
|
+ sorter: true,
|
|
|
|
+ width: '80%',
|
|
|
|
+ scopedSlots: { customRender: 'name' },
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ title: '属性',
|
|
|
|
+ dataIndex: 'tag',
|
|
|
|
+ filters: [
|
|
|
|
+ { text: '自定义', value: 'male' },
|
|
|
|
+ { text: '系统推荐', value: 'female' },
|
|
|
|
+ { text: '第三方', value: 'femal' },
|
|
|
|
+ ],
|
|
|
|
+ width: '20%',
|
|
|
|
+ },
|
|
|
|
+
|
|
|
|
+]
|
|
export default {
|
|
export default {
|
|
props:{
|
|
props:{
|
|
isNewPlan:{
|
|
isNewPlan:{
|
|
@@ -1153,6 +1237,17 @@ export default {
|
|
},
|
|
},
|
|
data() {
|
|
data() {
|
|
return {
|
|
return {
|
|
|
|
+ selectedRowKeys:[],
|
|
|
|
+ incluedSelectedRowKeys:[],
|
|
|
|
+ excludeSelectedRowKeys:[],
|
|
|
|
+
|
|
|
|
+ accountInfo:{},//账户信息
|
|
|
|
+ // 自定义人群参数
|
|
|
|
+ retargetColumns,
|
|
|
|
+ retargetData:[],
|
|
|
|
+ retargetDataAll:[],
|
|
|
|
+ loading:false,
|
|
|
|
+
|
|
showDirectedPackage:true,
|
|
showDirectedPackage:true,
|
|
title:'新建定向包',
|
|
title:'新建定向包',
|
|
labelCol: { span: 6 },
|
|
labelCol: { span: 6 },
|
|
@@ -1256,11 +1351,91 @@ export default {
|
|
|
|
|
|
}
|
|
}
|
|
},
|
|
},
|
|
|
|
+ computed: {
|
|
|
|
+ hasSelected() {
|
|
|
|
+ return this.selectedRowKeys.length > 0;
|
|
|
|
+ },
|
|
|
|
+ rowSelection() {
|
|
|
|
+ return {
|
|
|
|
+ // selectedRowKeys: this.incluedSelectedRowKeys,
|
|
|
|
+ onChange: (selectedRowKeys, selectedRows) => {
|
|
|
|
+ console.log(`selectedRowKeys: ${selectedRowKeys}`, 'selectedRows: ', selectedRows);
|
|
|
|
+ this.incluedSelectedRowKeys = selectedRowKeys;
|
|
|
|
+
|
|
|
|
+ },
|
|
|
|
+ getCheckboxProps: record => ({
|
|
|
|
+ props: {
|
|
|
|
+ disabled: this.excludeSelectedRowKeys.indexOf(record.key)>-1, // Column configuration not to be checked
|
|
|
|
+ name: record.name,
|
|
|
|
+ },
|
|
|
|
+ }),
|
|
|
|
+ };
|
|
|
|
+ },
|
|
|
|
+ rowSelection2() {
|
|
|
|
+ return {
|
|
|
|
+ // selectedRowKeys: this.excludeSelectedRowKeys,
|
|
|
|
+ onChange: (selectedRowKeys, selectedRows) => {
|
|
|
|
+ console.log(`selectedRowKeys: ${selectedRowKeys}`, 'selectedRows: ', selectedRows);
|
|
|
|
+ // this.selectedRowKeys = selectedRowKeys;
|
|
|
|
+ this.excludeSelectedRowKeys = selectedRowKeys;
|
|
|
|
+ },
|
|
|
|
+ getCheckboxProps: record => ({
|
|
|
|
+ props: {
|
|
|
|
+ disabled: this.incluedSelectedRowKeys.indexOf(record.key)>-1, // Column configuration not to be checked
|
|
|
|
+ name: record.name,
|
|
|
|
+ },
|
|
|
|
+ }),
|
|
|
|
+ };
|
|
|
|
+ },
|
|
|
|
+ },
|
|
methods: {
|
|
methods: {
|
|
//获取表单的某一个属性值
|
|
//获取表单的某一个属性值
|
|
getFormData(className) {
|
|
getFormData(className) {
|
|
return this.form.getFieldValue(className)
|
|
return this.form.getFieldValue(className)
|
|
},
|
|
},
|
|
|
|
+ // 自定义人群的--同时定向排除tab切换事件
|
|
|
|
+ retargetTabChange(tabkey){
|
|
|
|
+ console.log(tabkey)
|
|
|
|
+ this.retargetDataAll=[];
|
|
|
|
+ this.loading=true;
|
|
|
|
+ if(this.accountInfo.value){
|
|
|
|
+ getAction('/ctop/audience/list',{
|
|
|
|
+ accountId:this.accountInfo.value
|
|
|
|
+ }).then((res)=>{
|
|
|
|
+ console.log(res)
|
|
|
|
+ this.loading=false;
|
|
|
|
+ if(res.success){
|
|
|
|
+ res.data.forEach((item)=>{
|
|
|
|
+ item.key=item.custom_audience_id
|
|
|
|
+ })
|
|
|
|
+ // this.retargetData=res.data;
|
|
|
|
+ this.retargetDataAll=res.data;
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ }
|
|
|
|
+ // if(tabkey==1){
|
|
|
|
+
|
|
|
|
+ // }
|
|
|
|
+ // }else{
|
|
|
|
+
|
|
|
|
+ // }
|
|
|
|
+ },
|
|
|
|
+ onSelectChange(selectedRowKeys) {
|
|
|
|
+ console.log('selectedRowKeys changed: ', selectedRowKeys);
|
|
|
|
+ this.selectedRowKeys = selectedRowKeys;
|
|
|
|
+ },
|
|
|
|
+ // 自定义人群的改变
|
|
|
|
+ retargetTableChange(pagination, filters, sorter){
|
|
|
|
+ console.log(pagination);
|
|
|
|
+ },
|
|
|
|
+ // 自定义人群下的 定向排除
|
|
|
|
+ directLogicChange(val){
|
|
|
|
+ this.dxInputValue=undefined;
|
|
|
|
+ this.selectedRowKeys = [];
|
|
|
|
+ },
|
|
|
|
+
|
|
|
|
+ // 只能放量改变
|
|
zhinengChange(e){
|
|
zhinengChange(e){
|
|
console.log(e.target.value,this.getFormData('autoExtendEnabled'));
|
|
console.log(e.target.value,this.getFormData('autoExtendEnabled'));
|
|
// this.form.setFieldsValue({
|
|
// this.form.setFieldsValue({
|
|
@@ -1462,10 +1637,7 @@ export default {
|
|
// console.log(this.platform)
|
|
// console.log(this.platform)
|
|
},
|
|
},
|
|
|
|
|
|
- // 自定义人群下的 定向排除
|
|
|
|
- directLogicChange(val){
|
|
|
|
- this.dxInputValue=undefined
|
|
|
|
- },
|
|
|
|
|
|
+
|
|
tijiaozhi(){
|
|
tijiaozhi(){
|
|
this.getValuehandle();
|
|
this.getValuehandle();
|
|
this.showDirectedPackage=!this.showDirectedPackage;
|
|
this.showDirectedPackage=!this.showDirectedPackage;
|
|
@@ -1477,8 +1649,16 @@ export default {
|
|
if(this.launchPrice=='custom'){
|
|
if(this.launchPrice=='custom'){
|
|
formData['launchPrice']=this.launchPriceArr
|
|
formData['launchPrice']=this.launchPriceArr
|
|
}
|
|
}
|
|
|
|
+ if(this.directLogic=='RETARGETING_INCLUDE'){
|
|
|
|
+ formData['retargetingTags']=this.selectedRowKeys;
|
|
|
|
+ }else if(this.directLogic=='RETARGETING_EXCLUDE'){
|
|
|
|
+ formData['retargetingTagsExclude']=this.selectedRowKeys;
|
|
|
|
+ }else if(this.directLogic=='ALL'){
|
|
|
|
+ formData['retargetingTags']=this.incluedSelectedRowKeys;
|
|
|
|
+ formData['retargetingTagsExclude']=this.excludeSelectedRowKeys;
|
|
|
|
+ }
|
|
if(!this.regionValue!='NONE'){
|
|
if(!this.regionValue!='NONE'){
|
|
- console.log('需要处理地域的值');
|
|
|
|
|
|
+ // console.log('需要处理地域的值');
|
|
formData['city']=this.city
|
|
formData['city']=this.city
|
|
}
|
|
}
|
|
let userinfo=localStorage.getItem('pro__Login_Userinfo')
|
|
let userinfo=localStorage.getItem('pro__Login_Userinfo')
|
|
@@ -1612,6 +1792,27 @@ export default {
|
|
})
|
|
})
|
|
}
|
|
}
|
|
})
|
|
})
|
|
|
|
+ let accountInfo = localStorage.getItem('accountInfo')
|
|
|
|
+ console.log(accountInfo)
|
|
|
|
+ if (accountInfo!=null) {
|
|
|
|
+ this.accountInfo = JSON.parse(accountInfo)
|
|
|
|
+ if(this.accountInfo.value){
|
|
|
|
+ getAction('/ctop/audience/list',{
|
|
|
|
+ accountId:this.accountInfo.value
|
|
|
|
+ }).then((res)=>{
|
|
|
|
+ console.log(res)
|
|
|
|
+ if(res.success){
|
|
|
|
+ res.data.forEach((item)=>{
|
|
|
|
+ item.key=item.custom_audience_id
|
|
|
|
+ })
|
|
|
|
+ this.retargetData=res.data;
|
|
|
|
+ this.retargetDataAll=res.data;
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ console.log(this.accountInfo)
|
|
|
|
|
|
this.platformArr=JSON.parse(JSON.stringify(platformArr))
|
|
this.platformArr=JSON.parse(JSON.stringify(platformArr))
|
|
// this.platformArr = [...platformArr]
|
|
// this.platformArr = [...platformArr]
|