|
@@ -55,6 +55,14 @@
|
55
|
55
|
</div>
|
56
|
56
|
|
57
|
57
|
<div class="btnArea">
|
|
58
|
+ <span class="">
|
|
59
|
+ <template v-for="item in basicInfoData.outerConfig">
|
|
60
|
+ <el-button plain class="rMar10 outerButton" v-if="item.enabled">
|
|
61
|
+ <el-icon :class="['outerIcon', !item.value || item.value == '' || 'outerIconActive']"><CircleCheck v-if="!item.value || item.value == ''" /><SuccessFilled v-else/></el-icon>
|
|
62
|
+ {{item.name}}
|
|
63
|
+ </el-button>
|
|
64
|
+ </template>
|
|
65
|
+ </span>
|
58
|
66
|
<span class="lMarauto">
|
59
|
67
|
<el-button type="primary">批量预览广告</el-button>
|
60
|
68
|
<el-button type="primary" class="lMar10">保存策略组</el-button>
|
|
@@ -66,9 +74,10 @@
|
66
|
74
|
<!--规则配置-->
|
67
|
75
|
<RuleConfig ref="RuleConfigRef"></RuleConfig>
|
68
|
76
|
|
69
|
|
-<!-- 广告基本信息 -->
|
70
|
|
-<BasicInfo :visible="basicInfoData.visible" :dataFillBack="basicInfoData.fillBack" @close="basicInfoClose"></BasicInfo>
|
71
|
|
-
|
|
77
|
+ <!-- 广告基本信息 -->
|
|
78
|
+ <BasicInfo :visible="basicInfoData.visible" :dataFillBack="basicInfoData.fillBack" @close="basicInfoClose"></BasicInfo>
|
|
79
|
+ <!-- 扩量种子人群 -->
|
|
80
|
+ <ExpandPopulation :visible="basicInfoData.outerConfig.expandPopulation.visible"></ExpandPopulation>
|
72
|
81
|
</template>
|
73
|
82
|
<script setup lang="ts">
|
74
|
83
|
import {getCurrentInstance, nextTick, onMounted, reactive, ref, provide, computed,toRef} from "vue";
|
|
@@ -76,11 +85,11 @@ import {adqParam, reactiveTableAndAny} from "@/api/ApiModel";
|
76
|
85
|
import Select from '@/components/capsulationMoudle/_select.vue'
|
77
|
86
|
import DirectPacketExhibition from '@/components/businessMoudle/batchGdt/configArea/directPacket/echoIndex.vue'
|
78
|
87
|
import RuleConfig from '@/components/businessMoudle/batchGdt/configArea/ruleConfig/index.vue'
|
79
|
|
-import basicInfo from "./basicInfo/index.vue";
|
80
|
88
|
import {Api} from "@/api/api";
|
81
|
89
|
import {ElMessage} from "element-plus";
|
82
|
90
|
import {deepCopy} from "@/common/common";
|
83
|
91
|
import BasicInfo from "./basicInfo/index.vue";
|
|
92
|
+import ExpandPopulation from './basicInfo/expandPopulation.vue'
|
84
|
93
|
import { getAdPresets } from './basicInfo/ts/basicApi'
|
85
|
94
|
import { FillBackData } from './basicInfo/ts/fillBack'
|
86
|
95
|
|
|
@@ -110,7 +119,6 @@ const pageInfo = reactive<reactiveTableAndAny>({
|
110
|
119
|
})
|
111
|
120
|
|
112
|
121
|
|
113
|
|
-
|
114
|
122
|
//获取账号列表
|
115
|
123
|
const get_account_list = async () => {
|
116
|
124
|
const paramsModel = reactive<adqParam>({
|
|
@@ -136,11 +144,20 @@ const accEvent = () => {
|
136
|
144
|
})
|
137
|
145
|
}
|
138
|
146
|
|
139
|
|
-//打开广告基本信息
|
|
147
|
+//广告基本信息
|
140
|
148
|
const basicInfoData = reactive({
|
141
|
149
|
visible:false,
|
142
|
150
|
copywriting:[],
|
143
|
|
- fillBack: {}
|
|
151
|
+ fillBack: {},
|
|
152
|
+ outerConfig: { //外层配置
|
|
153
|
+ expandPopulation: {
|
|
154
|
+ enabled: false, //是否需要配置
|
|
155
|
+ visible:false,
|
|
156
|
+ name: '扩量种子人群(选填)',
|
|
157
|
+ value: '',
|
|
158
|
+ }
|
|
159
|
+
|
|
160
|
+ }
|
144
|
161
|
})
|
145
|
162
|
|
146
|
163
|
//打开规则配置
|
|
@@ -208,13 +225,15 @@ onMounted(()=>{
|
208
|
225
|
const basicInfoClose = (obj) => {
|
209
|
226
|
if(obj?.type=='update'){
|
210
|
227
|
basicInfoData.copywriting = obj.copywriting
|
211
|
|
- console.log(obj.copywriting)
|
|
228
|
+ console.log(obj)
|
|
229
|
+ getButtonBasicOuter(obj.params)
|
212
|
230
|
}
|
213
|
231
|
basicInfoData.visible = false
|
214
|
232
|
}
|
215
|
233
|
/**广告预存信息获取 */
|
216
|
234
|
const getAdPresetsInfo = () => {
|
217
|
235
|
getAdPresets({'promoted_object_type': 'PROMOTED_OBJECT_TYPE_LEAD_AD'}).then((res)=>{
|
|
236
|
+ getButtonBasicOuter(res)
|
218
|
237
|
FillBackData({data: res, type: 'api', cb: (data: {params: any,copywriting: []}) => {
|
219
|
238
|
if (data.copywriting && Array.isArray(data.copywriting) && data.copywriting.length > 0) {
|
220
|
239
|
basicInfoData.copywriting = data.copywriting
|
|
@@ -224,7 +243,12 @@ const getAdPresetsInfo = () => {
|
224
|
243
|
}})
|
225
|
244
|
})
|
226
|
245
|
}
|
227
|
|
-
|
|
246
|
+/**广告信息外部配置获取 */
|
|
247
|
+const getButtonBasicOuter = (res) => {
|
|
248
|
+ if(res?.expand_enabled == 1) { // 扩量种子人群
|
|
249
|
+ basicInfoData.outerConfig.expandPopulation.enabled = true;
|
|
250
|
+ }
|
|
251
|
+}
|
228
|
252
|
|
229
|
253
|
|
230
|
254
|
//传值
|
|
@@ -314,4 +338,23 @@ provide('accountIds',toRef(pageInfo,'accIdsList'))
|
314
|
338
|
.c-515a6e{
|
315
|
339
|
color: #515a6e;
|
316
|
340
|
}
|
|
341
|
+.outerButton{
|
|
342
|
+ &:hover{
|
|
343
|
+ .outerIcon{
|
|
344
|
+ color: #3173FF
|
|
345
|
+ }
|
|
346
|
+ .outerIconActive{
|
|
347
|
+ color: #00b697;
|
|
348
|
+ }
|
|
349
|
+ }
|
|
350
|
+
|
|
351
|
+}
|
|
352
|
+.outerIcon{
|
|
353
|
+ color: #888;
|
|
354
|
+ margin: 0 10px;
|
|
355
|
+ font-size: 16px;
|
|
356
|
+}
|
|
357
|
+.outerIconActive{
|
|
358
|
+ color: #00b697;
|
|
359
|
+}
|
317
|
360
|
</style>
|