Просмотр исходного кода

财务,头条自动投放已上线

朱鑫波 3 лет назад
Родитель
Сommit
1803e0f127

+ 2 - 2
src/utils/request.js

@@ -21,9 +21,9 @@ else if (process.env.NODE_ENV === 'debug') {
 else if (process.env.NODE_ENV === 'production') {
 	// axios.defaults.baseURL = 'http://apipre.tjyourong.com.cn/jeecg-boot'; // 预生产
 	// axios.defaults.baseURL = 'http://gateway.tjyourong.com.cn/jeecg-boot';//测试
-	// axios.defaults.baseURL = 'http://api.tjyourong.com.cn/jeecg-boot'; // 生产环境
+	axios.defaults.baseURL = 'http://api.tjyourong.com.cn/jeecg-boot'; // 生产环境
 	// axios.defaults.baseURL = 'http://gateway.tjyourong.com.cn/jeecg-boot'; // 测试环境
-	axios.defaults.baseURL = 'http://192.168.0.195:9999/jeecg-boot'; // 测试环境
+	// axios.defaults.baseURL = 'http://192.168.0.195:9999/jeecg-boot'; // 测试环境
 
 }
 const service = axios.create({

+ 2 - 2
src/views/modules/account-config/account-config-server.js

@@ -3,8 +3,8 @@
  * @author jiayufei
  */
 
-// export const urlAcount = 'http://118.24.244.213:8808'; // 线上
+export const urlAcount = 'http://118.24.244.213:8808'; // 线上
 // export const urlAcount = 'http://apipre.tjyourong.com.cn'; // 预生产
 // export const urlAcount = 'http://192.168.1.43:8808'; // 子安
-export const urlAcount = 'http://139.186.165.84:8808'; // 测试
+// export const urlAcount = 'http://139.186.165.84:8808'; // 测试
 // export const urlAcount = 'http://192.168.1.8:8080'; // 学超

+ 302 - 76
src/views/modules/account-config/components/configuration-modal.vue

@@ -191,7 +191,7 @@
                             @change="handleAdDownLoadType"
                         >
                             <a-radio-button value="DOWNLOAD_URL">下载链接</a-radio-button>
-                            <a-radio-button value="EXTERNAL_URL">落地页</a-radio-button>
+                            <a-radio-button value="EXTERNAL_URL" :disabled="platformLoadingType == 'APP_IOS'">落地页</a-radio-button>
                         </a-radio-group>
                     </a-form-model-item>
                     <div v-if="configForm.adDownloadType === 'EXTERNAL_URL'">
@@ -205,7 +205,7 @@
                             />
                         </a-form-model-item>
                     </div>
-                    <a-form-model-item v-if="configForm.adDownloadType === 'DOWNLOAD_URL'" label="优先应用商店下载">
+                    <a-form-model-item v-if="configForm.adDownloadType === 'DOWNLOAD_URL'&&platformLoadingType != 'APP_IOS'" label="优先应用商店下载">
                         <a-radio-group
                             v-model="configForm.adDownloadMode"
                             button-style="solid"
@@ -340,7 +340,7 @@
                     </a-form-model-item>
                 </div>
                 <div class="separate-module-con">
-                    <a-tabs v-model="configForm.adDirectionalFlag">
+                    <a-tabs v-model="configForm.adDirectionalFlag" @change="changeAdDirection">
                         <a-tab-pane key="add" tab="新建定向">
                             <p class="rock-title">用户定向</p>
                             <a-form-model-item label="地域">
@@ -497,7 +497,7 @@
                                 >
                                 </radio-check>
                             </a-form-model-item>
-                            <a-form-model-item v-if="configForm.adDownloadUrl" label="安卓版本">
+                            <a-form-model-item v-if="configForm.adDownloadUrl&&configForm.adPlatform == 'ANDROID'" label="安卓版本">
                                 <a-radio-group v-model="configForm.adAndroidVersion" button-style="solid" @change="handleAndroidVersion">
                                     <a-radio-button value="NONE">不限</a-radio-button>
                                     <a-radio-button value="a">自定义</a-radio-button>
@@ -797,7 +797,7 @@
                         </a-form-model-item>
                     </div>
                 </div>
-                <div class="separate-module-con">
+                <!-- <div class="separate-module-con">
                     <p class="rock-title">第三方检测链接</p>
                     <a-form-model-item label="点击监测">
                         <a-input
@@ -807,7 +807,7 @@
                             allow-clear
                         />
                     </a-form-model-item>
-                </div>
+                </div> -->
                 <div class="separate-module-con">
                     <p class="rock-title">创意信息</p>
                     <a-form-model-item v-if="!configForm.adUnionVideoType" label="使用抖音号投放">
@@ -818,8 +818,9 @@
                     </a-form-model-item>
                     <a-form-model-item label="创意方式">
                         <a-radio-group v-model="configForm.creativeMaterialMode" button-style="solid">
+                             <!-- :disabled="modalTitle === 'edit' || originalityStatus" -->
                             <a-radio-button value="STATIC_ASSEMBLE" :disabled="modalTitle === 'edit'">程序化创意</a-radio-button>
-                            <a-radio-button value="NONE" :disabled="modalTitle === 'edit' || originalityStatus">自定义创意</a-radio-button>
+                            <a-radio-button value="NONE" disabled>自定义创意</a-radio-button>
                         </a-radio-group>
                     </a-form-model-item>
                     <div v-if="configForm.adUnionVideoType === 'REWARDED_VIDEO'">
@@ -1855,7 +1856,7 @@ export default {
                     packageName: this.configForm.adPackage,
                     promotionContent: this.configForm.adDownloadType
                 };
-                this.handleGetOptimizationObjective(paramsData);
+                // this.handleGetOptimizationObjective(paramsData);
             }
         },
         NewAountId(newVal, oldVal) {
@@ -1863,14 +1864,14 @@ export default {
                 const paramsData = {
                     advancedCreativeType: 'ATTACHED_CREATIVE_NONE',
                     advertiserId: this.configForm.accountId,
-                    appType: 'APP_ANDROID',
+                    appType: this.platformLoadingType,
                     deliveryRange: 'DEFAULT',
                     externalUrl: this.configForm.adExternalUrl,
                     landingType: this.configForm.campaignLandingType,
                     packageName: this.configForm.adPackage,
                     promotionContent: this.configForm.adDownloadType
                 };
-                this.handleGetOptimizationObjective(paramsData);
+                // this.handleGetOptimizationObjective(paramsData);
             }
             if (newVal && this.platformLoadingType) {
                 this.handleGetChengZiSite();
@@ -1911,13 +1912,122 @@ export default {
     methods: {
         ...mapGetters(['nickname', 'avatar', 'userInfo']),
         moment,
+        changeAdDirection() {
+            this.configForm.adDistrict = 'NONE';
+            this.listArr = [];
+            this.configForm.adLocationType = 'HOME'
+            this.configForm.adGender = 'NONE'
+            this.configForm.adSelectAge = ['NONE']
+            this.configForm.adInterestActionMode = 'UNLIMITED'
+            this.configForm.customPerson = 'NONE'
+            this.configForm.adRetargetingTagsType = '1'
+            this.configForm.updateGetingInclude = []
+            this.configForm.updateGetingExclude = []
+            this.directionalData = []
+            this.configForm.adSuperiorPopularityType = 'NONE'
+            // this.configForm.adPlatform = 'NONE'
+            this.configForm.adDeviceSelectType = ['NONE']
+            this.configForm.adAndroidVersion = 'NONE'
+            this.configForm.androidChangeValue = '9.0'
+            this.configForm.adSelectAc = ['NONE']
+            this.configForm.adHideIfExists = '0'
+            this.configForm.adHideIfConverted = 'NO_EXCLUDE'
+            this.configForm.adConvertedTimeDuration = 'ONE_MONTH'
+            this.configForm.adAutoExtendEnabled = '0'
+
+            this.configForm.adAudiencePackageId = undefined
+            this.packageMessageDetail = [];
+            if(this.configForm.adDirectionalFlag != 'add'){
+                this.handleGetAdAudiencePackage();
+            }
+
+        },
         handleSelectValue(data) {
             this.configForm.accountId = data.id;
+            // this.$refs['ruleForm'].resetFields();
+
+
+            this.configForm.adDistrict = 'NONE';
+            this.listArr = [];
+            this.configForm.adLocationType = 'HOME'
+            this.configForm.adGender = 'NONE'
+            this.configForm.adSelectAge = ['NONE']
+            this.configForm.adInterestActionMode = 'UNLIMITED'
+            this.configForm.customPerson = 'NONE'
+            this.configForm.adRetargetingTagsType = ''
+            this.configForm.updateGetingInclude = []
+            this.configForm.updateGetingExclude = []
+            this.directionalData = []
+            this.configForm.adSuperiorPopularityType = 'NONE'
+            // this.configForm.adPlatform = 'NONE'
+            this.configForm.adDeviceSelectType = ['NONE']
+            this.configForm.adAndroidVersion = 'NONE'
+            this.configForm.androidChangeValue = '9.0'
+            this.configForm.adSelectAc = ['NONE']
+            this.configForm.adHideIfExists = '0'
+            this.configForm.adHideIfConverted = 'NO_EXCLUDE'
+            this.configForm.adConvertedTimeDuration = 'ONE_MONTH'
+            this.configForm.adAutoExtendEnabled = '0'
+
+            this.configForm.adAudiencePackageId = undefined
+
+            this.configForm.adDirectionalFlag = 'add'
+
+            // this.configForm.adConvertType = undefined;
+            // this.configForm.adConvertId = undefined;
+            // this.toolConvertList = [];
+            // this.optimizationOption = [];
+            // this.handleGetAdAudiencePackage();
+
+
             this.configForm.adConvertType = undefined;
             this.configForm.adConvertId = undefined;
+            this.packageMessageDetail = [];
             this.toolConvertList = [];
             this.optimizationOption = [];
-            this.handleGetAdAudiencePackage();
+            this.handleClearlist();
+
+            if (this.configForm.customPerson === 'a' && this.configForm.adRetargetingTagsType === '1') {
+                this.$refs.direct.selectRightData = [];
+                this.$refs.direct.tableSelectIds = [];
+            }
+            else if (this.configForm.customPerson === 'a' && this.configForm.adRetargetingTagsType === '2') {
+                this.$refs.exclude.selectRightData = [];
+                this.$refs.exclude.tableSelectIds = [];
+            }
+            else if (this.configForm.customPerson === 'a' && this.configForm.adRetargetingTagsType === '3') {
+                this.$refs.twoway.tableSelectDirectIds = [];
+                this.$refs.twoway.tableSelectDirectData = [];
+                this.$refs.twoway.tableSelectExcludeIds = [];
+                this.$refs.twoway.tableSelectExcludeData = [];
+            }
+            
+            if (this.platformLoadingType!='') {
+                let paramsData = {};
+                if (this.configForm.adDownloadType === 'DOWNLOAD_URL') {
+                    paramsData = {
+                        advancedCreativeType: 'ATTACHED_CREATIVE_NONE',
+                        advertiserId: this.configForm.accountId,
+                        appType: this.platformLoadingType,
+                        deliveryRange: 'DEFAULT',
+                        externalUrl: this.configForm.adExternalUrl,
+                        landingType: this.configForm.campaignLandingType,
+                        packageName: this.configForm.adPackage,
+                        promotionContent: this.configForm.adDownloadType
+                    };
+                }
+                else if (this.configForm.adDownloadType === 'EXTERNAL_URL') {
+                    paramsData = {
+                        advancedCreativeType: 'ATTACHED_CREATIVE_NONE',
+                        advertiserId: this.configForm.accountId,
+                        deliveryRange: 'DEFAULT',
+                        externalUrl: this.configForm.adExternalUrl,
+                        landingType: this.configForm.campaignLandingType,
+                        promotionContent: this.configForm.adDownloadType
+                    };
+                }
+                this.handleGetOptimizationObjective(paramsData);
+            }
         },
         handleAdDistrict(e) {
             const defaultValue = e.target.value;
@@ -1980,7 +2090,7 @@ export default {
                     // this.configForm.creativeEnablePersonalAction = '';
                     this.configForm.adAudiencePackageId = undefined;
                     this.packageMessageDetail = [];
-                    this.handleGetAdAudiencePackage();
+                    // this.handleGetAdAudiencePackage();
                 }
             }
             else {
@@ -1989,7 +2099,7 @@ export default {
                 this.configForm.adUnionVideoType = '';
                 this.configForm.adAudiencePackageId = undefined;
                 this.packageMessageDetail = [];
-                this.handleGetAdAudiencePackage();
+                // this.handleGetAdAudiencePackage();
             }
         },
         handleGetChengZiSite() {
@@ -2207,7 +2317,8 @@ export default {
         },
         handleGetAdAudiencePackage() {
             const params = {
-                accountId: this.configForm.accountId
+                accountId: this.configForm.accountId,
+                landingType: this.platformLoadingType
             };
             getAction(urlAcount + '/bytedance-api/advertiser/aiBytedanceAdvertiserStrategy/getAdAudiencePackage', params)
                 .then(result => {
@@ -2389,6 +2500,34 @@ export default {
                     console.log(error, 'eeee');
                 });
         },
+        editPackage(){
+            var that = this
+            return new Promise(function (resolve, reject) {
+                const params = {
+                    urlPath: that.configForm.adDownloadUrl
+                };
+                getAction(urlAcount + '/bytedance-api/advertiser/aiBytedanceAdvertiserStrategy/getPackageNameByUrl', params)
+                    .then(result => {
+                        if (result.code === 0) {
+                            // this.configForm.adPackage = result.result.package || '';
+                            // this.platformLoadingType = result.result.platform || '';
+                            // if (result.result.platform && result.result.platform === 'APP_ANDROID') {
+                            //     this.configForm.adPlatform = 'ANDROID';
+                            // }
+                            // else if (result.result.platform && result.result.platform === 'APP_IOS') {
+                            //     this.configForm.adPlatform = 'IOS';
+                            // }
+                            resolve(result.result.platform)
+                        }
+                        else {
+                            reject('调用失败')
+                        }
+                    })
+                    .catch(error => {
+                        console.log(error, 'eeee');
+                    });
+            })
+        },
         handleAndroidVersion(e) {
             if (e.target.value === 'NONE') {
                 this.configForm.androidChangeValue = '';
@@ -2460,6 +2599,21 @@ export default {
                 // this.$refs.ruleForm.clearValidate(['adDownloadUrl']);
                 // this.$refs.ruleForm.clearValidate(['adPackage']);
             }
+            if(this.configForm.adDownloadUrl) {
+                this.handleGetPackage();
+                const paramsData = {
+                    advancedCreativeType: 'ATTACHED_CREATIVE_NONE',
+                    advertiserId: this.configForm.accountId,
+                    appType: this.platformLoadingType,
+                    deliveryRange: 'DEFAULT',
+                    externalUrl: this.configForm.adExternalUrl,
+                    landingType: this.configForm.campaignLandingType,
+                    packageName: this.configForm.adPackage,
+                    promotionContent: this.configForm.adDownloadType
+                };
+                this.handleGetOptimizationObjective(paramsData);
+            }
+            
         },
         handleCampaignCnt(e) {
             const finallyResult = e * this.configForm.campaignAdCnt;
@@ -2480,8 +2634,12 @@ export default {
             }
         },
         handleConvertChange(e) {
-            const convertTitle = this.optimizationOption.filter(item => item.convert_id === e);
-            this.configForm.creativeActionTrackUrl = convertTitle[0].action_track_url;
+            // postAction(urlAcount + `/bytedance-api/advertiser/aiBytedanceAdvertiserStrategy/readToolConvertInfo?accountId=${this.configForm.accountId}&convertId=${this.configForm.adConvertId}`)
+            // .then(res=>{
+            //     if(res.success){
+            //         this.configForm.creativeActionTrackUrl = res.result.action_track_url;
+            //     }
+            // })
         },
         handleGetDetailList() {
             const routeQuery = JSON.parse(localStorage.getItem('queryList'));
@@ -2490,69 +2648,108 @@ export default {
                     if (result.code === 0) {
                         const detailData = result.result;
                         this.configForm.accountId = detailData.accountId;
-                        let paramsData = {};
-                        if (detailData.adDownloadType === 'DOWNLOAD_URL') {
-                            paramsData = {
-                                advancedCreativeType: 'ATTACHED_CREATIVE_NONE',
-                                advertiserId: detailData.accountId,
-                                appType: 'APP_ANDROID',
-                                deliveryRange: 'DEFAULT',
-                                externalUrl: detailData.adExternalUrl,
-                                landingType: detailData.campaignLandingType,
-                                packageName: detailData.adPackage,
-                                promotionContent: detailData.adDownloadType
-                            };
-                        }
-                        else if (detailData.adDownloadType === 'EXTERNAL_URL') {
-                            paramsData = {
-                                advancedCreativeType: 'ATTACHED_CREATIVE_NONE',
-                                advertiserId: detailData.accountId,
-                                deliveryRange: 'DEFAULT',
-                                externalUrl: detailData.adExternalUrl,
-                                landingType: detailData.campaignLandingType,
-                                promotionContent: detailData.adDownloadType
-                            };
-                        }
-                        postAction(urlAcount + '/bytedance-api/advertiser/aiBytedanceAdvertiserStrategy/getToolConvert', paramsData).then(result => {
-                            if (result.code === 0) {
-                                const updateResult = result.result.filter(item => item.external_actions.length > 0);
-                                this.configForm.adConvertType = updateResult[0].convert_type;
-                                this.optimizationOption = updateResult[0].external_actions;
-                                setTimeout(() => {
-                                    this.configForm.adConvertId = detailData.adConvertId;
-                                    this.spinning = false;
-                                }, 2000);
-                            }
-                            else {
-                                this.$message.error(result.message);
-                            }
-                        }).catch(error => {
-                            console.log(error, 'eeee');
-                        });
-                        if (detailData.adAudiencePackageId) {
-                            getAction(urlAcount + '/bytedance-api/advertiser/aiBytedanceAdvertiserStrategy/getAdAudiencePackage', {accountId: detailData.accountId})
-                                .then(result => {
-                                    if (result.code === 0) {
-                                        this.$nextTick(()=>{
-                                            let checkboxChangeValueList = detailData.creativeInventoryType ? detailData.creativeInventoryType.split(',') : [];
-                                            if (checkboxChangeValueList.length === 1 && checkboxChangeValueList[0] === 'INVENTORY_UNION_SLOT') {
-                                                this.selectiveList = result.result.filter(item => item.delivery_range === 'UNION');
+                        setTimeout(() => {
+                            this.configForm.adConvertId = detailData.adConvertId;
+                            this.spinning = false;
+                        }, 200);
+                        
+                       
+                        this.configForm.adDownloadUrl = detailData.adDownloadUrl || '';
+                        this.handleGetPackage()
+                        this.$nextTick(()=>{
+                            this.editPackage().then(res=>{
+                                if (detailData.adAudiencePackageId&&res!='') {
+                                    this.$nextTick(()=>{
+                                        getAction(urlAcount + '/bytedance-api/advertiser/aiBytedanceAdvertiserStrategy/getAdAudiencePackage', {accountId: detailData.accountId,landingType: res})
+                                        .then(result => {
+                                            if (result.code === 0) {
+                                                this.$nextTick(()=>{
+                                                    let checkboxChangeValueList = detailData.creativeInventoryType ? detailData.creativeInventoryType.split(',') : [];
+                                                    if (checkboxChangeValueList.length === 1 && checkboxChangeValueList[0] === 'INVENTORY_UNION_SLOT') {
+                                                        this.selectiveList = result.result.filter(item => item.delivery_range === 'UNION');
+                                                    }
+                                                    else {
+                                                        this.selectiveList = result.result || [];
+                                                    }
+                                                    this.configForm.adAudiencePackageId = Number(detailData.adAudiencePackageId);
+                                                    this.handleSelectiveOrientation(Number(detailData.adAudiencePackageId));
+                                                })
                                             }
                                             else {
-                                                this.selectiveList = result.result || [];
+                                                this.$message.error(result.message);
+                                            }
+                                        })
+                                        .catch(error => {
+                                            console.log(error, 'eeee');
+                                        });
+                                    })
+
+                                }
+                                let paramsData = {};
+                                if (detailData.adDownloadType === 'DOWNLOAD_URL') {
+                                    paramsData = {
+                                        advancedCreativeType: 'ATTACHED_CREATIVE_NONE',
+                                        advertiserId: detailData.accountId,
+                                        appType: res,
+                                        deliveryRange: 'DEFAULT',
+                                        externalUrl: detailData.adExternalUrl,
+                                        landingType: detailData.campaignLandingType,
+                                        packageName: detailData.adPackage,
+                                        promotionContent: detailData.adDownloadType
+                                    };
+                                }
+                                else if (detailData.adDownloadType === 'EXTERNAL_URL') {
+                                    paramsData = {
+                                        advancedCreativeType: 'ATTACHED_CREATIVE_NONE',
+                                        advertiserId: detailData.accountId,
+                                        deliveryRange: 'DEFAULT',
+                                        externalUrl: detailData.adExternalUrl,
+                                        landingType: detailData.campaignLandingType,
+                                        promotionContent: detailData.adDownloadType
+                                    };
+                                }
+
+                                postAction(urlAcount + '/bytedance-api/advertiser/aiBytedanceAdvertiserStrategy/getToolConvert', paramsData).then(result => {
+                                    if (result.code === 0) {
+                                        // const updateResult = result.result.filter(item => item.external_actions.length > 0);
+                                        this.$nextTick(()=>{
+                                            var updateResult = []
+                                            for (let i = 0; i < result.result[0].converts.length; i++) {
+                                                if(result.result[0].converts[i].external_actions){
+                                                    for (let j = 0; j < result.result[0].converts[i].external_actions.length; j++) {
+                                                        if(result.result[0].converts[i].external_actions[j].convert_id == detailData.adConvertId){
+                                                            updateResult.push(result.result[0].converts[i])
+                                                        }
+                                                        
+                                                    }
+                                                }
+                                                
+                                                
                                             }
-                                            this.configForm.adAudiencePackageId = Number(detailData.adAudiencePackageId);
-                                            this.handleSelectiveOrientation(Number(detailData.adAudiencePackageId));
+                                            this.configForm.adConvertType = updateResult[0].convert_type;
+                                            this.optimizationOption = updateResult[0].external_actions;
+
+                                        
                                         })
+                                    
                                     }
                                     else {
                                         this.$message.error(result.message);
                                     }
-                                })
-                                .catch(error => {
+                                }).catch(error => {
                                     console.log(error, 'eeee');
                                 });
-                        }
+                            })
+
+                        })
+                        postAction(urlAcount + `/bytedance-api/advertiser/aiBytedanceAdvertiserStrategy/readToolConvertInfo?accountId=${detailData.accountId}&convertId=${detailData.adConvertId}`)
+                        .then(res=>{
+                            if(res.success){
+                                this.configForm.creativeActionTrackUrl = res.result.action_track_url;
+                            }
+                        })
+
+                                                                    
                         this.configForm.dpLinkStartIndex = detailData.dpLinkStartIndex;
                         this.configForm.dpLinkEndIndex = detailData.dpLinkEndIndex;
                         this.configForm.accountBudgetMode = detailData.accountBudgetMode;
@@ -2580,12 +2777,12 @@ export default {
                         this.configForm.adPlatform = detailData.adPlatform;
                         this.configForm.adExternalUrl = detailData.adExternalUrl || '';
                         this.configForm.adOpenUrl = detailData.adOpenUrl || '';
-                        this.configForm.adDownloadUrl = detailData.adDownloadUrl || '';
+                     
                         this.configForm.adPackage = detailData.adPackage || '';
                         this.configForm.adConvertType = detailData.adConvertType || '';
                         this.configForm.adDistrict = detailData.adDistrict || 'NONE';
                         this.configForm.adAppType = detailData.adAppType;
-                        this.handleGetPackage()
+                        // this.handleGetPackage()
                         getAction(urlAcount + '/bytedance-api/advertiser/aiBytedanceAdvertiserStrategy/getChengZiSite', {accountId: detailData.accountId}).then(result => {
                             if (result.code === 0) {
                                 const defaultResult = result.result;
@@ -2672,7 +2869,7 @@ export default {
                         this.configForm.launchDateRange[1] = detailData.adEndTime;
                         this.configForm.adPricing = detailData.adPricing;
                         this.configForm.adCpaBid = detailData.adCpaBid;
-                        this.configForm.creativeActionTrackUrl = detailData.creativeActionTrackUrl;
+                        
                         this.configForm.creativeMaterialMode = detailData.creativeMaterialMode;
 
                         this.configForm.creativeProductDescription = detailData.creativeProductDescription;
@@ -2810,10 +3007,10 @@ export default {
         handleGetOptimizationObjective(paramsData) {
             postAction(urlAcount + '/bytedance-api/advertiser/aiBytedanceAdvertiserStrategy/getToolConvert', paramsData).then(result => {
                 if (result.code === 0) {
-                    this.toolConvertList = result.result;
-                    if (this.configForm.adConvertType) {
-                        this.handleConvertTypeChange(this.configForm.adConvertType);
-                    }
+                    this.toolConvertList = result.result[0].converts;
+                    // if (this.configForm.adConvertType) {
+                    //     this.handleConvertTypeChange(this.configForm.adConvertType);
+                    // }
                 }
                 else {
                     this.$message.error(result.message);
@@ -2919,6 +3116,30 @@ export default {
             const defaultValue = e.target.value;
             if (defaultValue) {
                 this.handleGetPackage();
+                let paramsData = {};
+                if (this.configForm.adDownloadType === 'DOWNLOAD_URL') {
+                    paramsData = {
+                        advancedCreativeType: 'ATTACHED_CREATIVE_NONE',
+                        advertiserId: this.configForm.accountId,
+                        appType: 'APP_ANDROID',
+                        deliveryRange: 'DEFAULT',
+                        externalUrl: this.configForm.adExternalUrl,
+                        landingType: this.configForm.campaignLandingType,
+                        packageName: this.configForm.adPackage,
+                        promotionContent: this.configForm.adDownloadType
+                    };
+                }
+                else if (this.configForm.adDownloadType === 'EXTERNAL_URL') {
+                    paramsData = {
+                        advancedCreativeType: 'ATTACHED_CREATIVE_NONE',
+                        advertiserId: this.configForm.accountId,
+                        deliveryRange: 'DEFAULT',
+                        externalUrl: this.configForm.adExternalUrl,
+                        landingType: this.configForm.campaignLandingType,
+                        promotionContent: this.configForm.adDownloadType
+                    };
+                }
+                this.handleGetOptimizationObjective(paramsData)
             }
             else {
                 this.platformLoadingType = '';
@@ -3086,6 +3307,11 @@ export default {
                     return;
                 }
             }
+            else {
+                this.listArr = []
+                this.configForm.adSelectCity = []
+                paramsFormData.adSelectCity = []
+            }
             // if (paramsFormData.checkboxChangeValue.length === 1 && paramsFormData.checkboxChangeValue[0] === 'INVENTORY_UNION_SLOT') {
             //     paramsFormData.adDeliveryRange = 'UNION';
             //     paramsFormData.creativeDownloadStatus = null;

+ 3 - 2
src/views/modules/settlement-information/settlement-information.vue

@@ -579,11 +579,12 @@ export default {
             this.handleGetAllAdverList(e.target.value);
         },
         handleGetDownLoadAllNum() {
-            const {advertiserId, productId, mediaId, uploadYears} = this.settlementModalForm;
+            const {advertiserId, productId, mediaId, uploadYears, projectId} = this.settlementModalForm;
             const paramsData = {
                 advertiserId,
                 productId,
                 mediaId,
+                projectId,
                 uploadYears: uploadYears ? moment(uploadYears).format('YYYY-MM') : ''
             };
             postAction(urlAcount + '/finance/settLementFileController/getAccountNumAndImgNum', paramsData).then(result => {
@@ -811,7 +812,7 @@ export default {
                         else {
                             this.handleSettlementModalnCancel();
                             this.$message.success('正在下载结算单,请稍后...', 4);
-                            window.location.href = `${urlAcount}${urlData}?advertiserId=${advertiserId}&productId=${productId}&mediaId=${mediaId}&uploadYears=${paramsData.uploadYears}&userId=${this.userInfo().id}`;
+                            window.location.href = `${urlAcount}${urlData}?advertiserId=${advertiserId}&projectId=${projectId}&productId=${productId}&mediaId=${mediaId}&uploadYears=${paramsData.uploadYears}&userId=${this.userInfo().id}`;
                         }
                     }).catch(error => {
                         console.log(error, 'eeee');