Przeglądaj źródła

feat: 转化归因新链路

zhengxy 7 miesięcy temu
rodzic
commit
3de3d2ffce

+ 13 - 12
src/components/businessMoudle/batchGdt3/configArea/basicInfo/index.vue

@@ -141,16 +141,16 @@
141 141
         <template
142 142
           v-if="(form.bid_mode == 'BID_MODE_OCPM' || form.bid_mode == 'BID_MODE_OCPC') && form.conversion_tracking_enabled == 1">
143 143
           <!-- 上报方式 -->
144
-          <MyRadio :info="scheduleBidInfo.conversion_tracking_report_type"
145
-            :fillBack="props.dataFillBack['conversion_tracking_report_type']"
146
-            @change="(val) => { onChangeKey({ val: val['conversion_tracking_report_type'], key: 'conversion_tracking_report_type' }) }">
144
+          <MyRadio :info="scheduleBidInfo.access_type"
145
+            :fillBack="props.dataFillBack['access_type']"
146
+            @change="(val) => { onChangeKey({ val: val['access_type'], key: 'access_type' }) }">
147 147
           </MyRadio>
148 148
           <!-- 归因方式 -->
149
-          <MyRadio :info="scheduleBidInfo.conversion_tracking_way" :fillBack="form.conversion_tracking_way"
149
+          <MyRadio :info="scheduleBidInfo.claim_type" :fillBack="form.claim_type"
150 150
             @change="radioChange"></MyRadio>
151 151
           <!-- 转化场景 -->
152
-          <MyRadio v-if="form.conversion_tracking_report_type == 1" :info="scheduleBidInfo.conversion_tracking_scene"
153
-            @change="radioChange" :fillBack="props.dataFillBack['conversion_tracking_scene']"></MyRadio>
152
+          <MyRadio v-if="form.access_type == 'ACCESS_TYPE_API'" :info="scheduleBidInfo.conversion_scene"
153
+            @change="radioChange" :fillBack="props.dataFillBack['conversion_scene']"></MyRadio>
154 154
         </template>
155 155
         <!-- 优化目标 -->
156 156
         <MySelect v-if="form.bid_mode == 'BID_MODE_OCPM' || form.bid_mode == 'BID_MODE_OCPC'" :goalType="1"
@@ -329,7 +329,7 @@
329 329
 </template>
330 330
 <script setup lang="ts">
331 331
 import { ref, reactive, watch, onBeforeMount, computed, nextTick } from 'vue'
332
-import { basicInfoJson, scheduleBid, conversion_tracking_way, short_play_pay_type } from './ts/information'
332
+import { basicInfoJson, scheduleBid, claim_type, short_play_pay_type } from './ts/information'
333 333
 import { specificPositionAll, expand_targeting, unbreakable_targeting } from './ts/other'
334 334
 import { scene, wechatScene, positionMapping, search_expand_targeting_switch } from './ts/scene'
335 335
 import { FillBackData } from './ts/fillBack'
@@ -690,13 +690,13 @@ const onChangeKey = ({ val, key }) => {
690 690
       scheduleBidInfo.daily_budget_radio.data.list[0].disabled = false;
691 691
       scheduleBidInfo.daily_budget_radio.data.list[0].note = '';
692 692
     }
693
-  } else if (key == 'conversion_tracking_report_type') { //上报方式
693
+  } else if (key == 'access_type') { //上报方式
694 694
     form[key] = val;
695
-    if (form['conversion_tracking_report_type'] == '2') {
696
-      scheduleBidInfo.conversion_tracking_way.data.list = [conversion_tracking_way[0]]
697
-      form.conversion_tracking_way = conversion_tracking_way[0].value
695
+    if (form['access_type'] == 'ACCESS_TYPE_JS') {
696
+      scheduleBidInfo.claim_type.data.list = [claim_type[0]]
697
+      form.claim_type = claim_type[0].value
698 698
     } else {
699
-      scheduleBidInfo.conversion_tracking_way.data.list = conversion_tracking_way
699
+      scheduleBidInfo.claim_type.data.list = claim_type
700 700
     }
701 701
   } else if (key == 'smart_bid_type') { //出价类型
702 702
     form[key] = val;
@@ -873,6 +873,7 @@ watch([
873 873
   () => form.attribution_type, // 1 全网 2精准
874 874
   () => form.conversion_tracking_enabled //0 关闭 1开启
875 875
 ], (newValue, oldValue) => {
876
+  console.log('attribution_type & conversion_tracking_enabled newValue => ', newValue)
876 877
   if (newValue[0] == 2) {
877 878
     form.conversion_tracking_enabled = '0'
878 879
     scheduleBidInfo.conversion_tracking_enabled.data.list[1].disabled = true

+ 16 - 4
src/components/businessMoudle/batchGdt3/configArea/basicInfo/ts/fillBack.ts

@@ -173,9 +173,9 @@ export const FillBackData = ({ data, type, updateScene = {}, cb, ruleConfigObj,
173 173
         params['bid_site'] = data.bid_site
174 174
         params['bid_site_details'] = data.bid_site_details
175 175
         params['conversion_tracking_enabled'] = data.conversion_tracking_enabled
176
-        params['conversion_tracking_report_type'] = data.conversion_tracking_enabled == 1 ? data.conversion_tracking_report_type : ''
177
-        params['conversion_tracking_way'] = data.conversion_tracking_enabled == 1 ? data.conversion_tracking_way : ''
178
-        params['conversion_tracking_scene'] = data.conversion_tracking_enabled == 1 ? data.conversion_tracking_scene : ''
176
+        params['access_type'] = data.conversion_tracking_enabled == 1 ? data.access_type : ''
177
+        params['claim_type'] = data.conversion_tracking_enabled == 1 ? data.claim_type : ''
178
+        params['conversion_scene'] = data.conversion_tracking_enabled == 1 ? data.conversion_scene : ''
179 179
         params['auto_acquisition_enabled'] = data.auto_acquisition_enabled
180 180
         params['auto_acquisition_amount'] = data.auto_acquisition_amount
181 181
         params['optimization_goal'] = data.optimization_goal
@@ -345,7 +345,8 @@ export const FillBackData = ({ data, type, updateScene = {}, cb, ruleConfigObj,
345 345
     }
346 346
 
347 347
     /**S 对应展示文案 */
348
-    console.log('对应展示文案 data => ', data)
348
+    console.log('对应展示文案 data => ', JSON.parse(JSON.stringify(data)))
349
+    console.log('对应展示文案 params => ', JSON.parse(JSON.stringify(params)))
349 350
     copywriting.push(`营销目的:${data.marketing_goal == 'MARKETING_GOAL_PRODUCT_SALES' ? '商品销售' : ''}`)
350 351
     copywriting.push(`推广产品:${data.marketing_target_type == 'MARKETING_TARGET_TYPE_SHORT_DRAMA' ? '短剧' : ''}`)
351 352
     copywriting.push(`短剧售卖策略:${data.sell_strategy_enable == '1' ? (data.short_play_pay_type == 'SHORT_PLAY_PAY_TYPE_FREE_PLAY' ? '免费' : (data.short_play_pay_type == 'SHORT_PLAY_PAY_TYPE_CHARGE_PLAY' ? '付费' : '')) : '不开启'}`)
@@ -408,6 +409,17 @@ export const FillBackData = ({ data, type, updateScene = {}, cb, ruleConfigObj,
408 409
       }
409 410
       copywriting.push(`投放场景:${bid_scene_writ}`)
410 411
 
412
+
413
+      copywriting.push(`转化归因新链路:${data.conversion_tracking_enabled == 1 ? '开启' : '关闭'}`)
414
+      if (data.conversion_tracking_enabled == 1) {
415
+        copywriting.push(`上报方式:${scheduleBid.access_type.data.list.filter((v: any) => { return v.value == data.access_type })[0]?.label}`)
416
+        copywriting.push(`归因方式:${scheduleBid.claim_type.data.list.filter((v: any) => { return v.value == data.claim_type })[0]?.label}`)
417
+        if (data.access_type === 'ACCESS_TYPE_API') {
418
+          copywriting.push(`转化场景:${scheduleBid.conversion_scene.data.list.filter((v: any) => { return v.value == data.conversion_scene })[0]?.label}`)
419
+        }
420
+      }
421
+
422
+
411 423
       data.optimization_goal_name ? copywriting.push(`优化目标:${data.optimization_goal_name}`) : ''
412 424
       if (data.forward_link_assist_enabled == 1) {
413 425
         copywriting.push(`助攻行为:${data.forward_link_assist_name}`)

Plik diff jest za duży
+ 23 - 23
src/components/businessMoudle/batchGdt3/configArea/basicInfo/ts/information.ts


+ 3 - 3
src/components/businessMoudle/batchGdt3/configArea/ts/mock.ts

@@ -3894,9 +3894,9 @@ export const mockEvent = () => {
3894 3894
         "bid_scene": "BID_SCENE_UNKNOWN",
3895 3895
         "bid_site": "0",
3896 3896
         "conversion_tracking_enabled": "0",
3897
-        "conversion_tracking_report_type": "",
3898
-        "conversion_tracking_way": "",
3899
-        "conversion_tracking_scene": "",
3897
+        "access_type": "",
3898
+        "claim_type": "",
3899
+        "conversion_scene": "",
3900 3900
         "auto_acquisition_enabled": "0",
3901 3901
         "optimization_goal": "OPTIMIZATIONGOAL_RESERVATION_CHECK",
3902 3902
         "forward_link_assist_enabled": "0",