|
@@ -37,9 +37,20 @@
|
|
|
:wrapperCol="{ lg: { span: 10 }, sm: { span: 17 } }"
|
|
|
>
|
|
|
<div style="color:red">
|
|
|
- {{createCount}}
|
|
|
+ {{getData('unitType') == '4' ? createCount.ctmCount : createCount.pgdCount }}
|
|
|
</div>
|
|
|
</a-form-item>
|
|
|
+ <a-form-item
|
|
|
+ label="创意制作方式"
|
|
|
+ :labelCol="{ lg: { span: 7 }, sm: { span: 7 } }"
|
|
|
+ :wrapperCol="{ lg: { span: 10 }, sm: { span: 17 } }"
|
|
|
+ >
|
|
|
+ <a-radio-group buttonStyle="solid" v-decorator="['unitType', { initialValue: '4' }]" @change="changeUnitType">
|
|
|
+ <a-radio-button value="4">自定义</a-radio-button>
|
|
|
+ <a-radio-button value="7">程序化</a-radio-button>
|
|
|
+ </a-radio-group>
|
|
|
+ </a-form-item>
|
|
|
+
|
|
|
|
|
|
<a-form-item
|
|
|
label="目标应用"
|
|
@@ -593,6 +604,7 @@
|
|
|
label="创建类型"
|
|
|
:labelCol="{ lg: { span: 7 }, sm: { span: 7 } }"
|
|
|
:wrapperCol="{ lg: { span: 10 }, sm: { span: 17 } }"
|
|
|
+ v-if="getData('unitType')=='4'"
|
|
|
>
|
|
|
<a-radio-group
|
|
|
buttonStyle="solid"
|
|
@@ -604,18 +616,18 @@
|
|
|
</a-radio-group>
|
|
|
</a-form-item>
|
|
|
<a-form-item
|
|
|
- v-if="getData('createType')=='0'"
|
|
|
- label="封面数"
|
|
|
+ v-if="getData('unitType')=='7' || getData('createType')!='1'"
|
|
|
+ :label="getData('unitType')=='7'?'视频数':'封面数'"
|
|
|
:labelCol="{ lg: { span: 7 }, sm: { span: 7 } }"
|
|
|
:wrapperCol="{ lg: { span: 10 }, sm: { span: 17 } }"
|
|
|
>
|
|
|
<a-input-number
|
|
|
- :max="15"
|
|
|
- :min="1"
|
|
|
+ :max="getData('unitType')=='7'?10:15"
|
|
|
+ :min="getData('unitType')=='7'?3:1"
|
|
|
v-decorator="[
|
|
|
'imageCount',
|
|
|
{
|
|
|
- rules: [{ required: true, message: '封面数必填' }],
|
|
|
+ rules: [{ required: true, message: '数量必填必填' }],
|
|
|
initialValue: 5,
|
|
|
},
|
|
|
]"
|
|
@@ -629,7 +641,11 @@
|
|
|
:labelCol="{ lg: { span: 7 }, sm: { span: 7 } }"
|
|
|
:wrapperCol="{ lg: { span: 10 }, sm: { span: 17 } }"
|
|
|
>
|
|
|
- <a @click="getVideoList()">选择视频</a> {{ videoList.length + '/' + (getData('createType')=='0'?getData('createCount'):getData('createCount')*15) }}
|
|
|
+ <a @click="getVideoList()">选择视频</a>
|
|
|
+ {{ videoList.length + '/' + (getData('unitType')=='4'
|
|
|
+ ?(getData('createType')=='0'?
|
|
|
+ getData('createCount'):getData('createCount')*15)
|
|
|
+ :getData('createCount')*getData('imageCount')) }}
|
|
|
<br />
|
|
|
<div v-if="videoList.length > 0 && showVideo" style="display:flex;flex-wrap:wrap">
|
|
|
<span v-for="(item, index) of videoList" :key="index" style="position: relative" class="width-video">
|
|
@@ -645,39 +661,48 @@
|
|
|
>
|
|
|
<!-- v-model.trim="allForm.description" -->
|
|
|
<!-- @keyup="getData('description')?getData('description')=this.value.replace(/^ +| +$/g,'')" -->
|
|
|
- <a @click="showTitle()">推荐广告语</a>
|
|
|
- <div class="step4-else" style="display: inline-block; position: relative; border-radius: 4px; width: 100%; border: 1px solid #d9d9d9;">
|
|
|
- <a-textarea
|
|
|
- class="rending"
|
|
|
- placeholder="请输入广告语"
|
|
|
- v-decorator="['description',{ rules: [{ required: true, message: '广告语必填' }] }]"
|
|
|
- @keyup="getData('description')?form.setFieldsValue({
|
|
|
- description: getData('description').replace(/\s/g,'')
|
|
|
- }):null"
|
|
|
- @change="getData('description')?form.setFieldsValue({
|
|
|
- description: getData('description').replace(/\s/g,'')
|
|
|
- }):null"
|
|
|
- :autosize="{ minRows: 2, maxRows: 6 }"
|
|
|
- :max-length="30"
|
|
|
- ></a-textarea>
|
|
|
- <p
|
|
|
- style="
|
|
|
- font-size: 12px;
|
|
|
- color: #b6bbc7;
|
|
|
- letter-spacing: 0.3px;
|
|
|
- text-align: right;
|
|
|
- line-height: 20px;
|
|
|
- position: absolute;
|
|
|
- bottom: 0;
|
|
|
- right: 6px;
|
|
|
- width: 100%;
|
|
|
- margin-bottom: 0;
|
|
|
- "
|
|
|
- >
|
|
|
- {{ (getData('description')?getData('description').length:0) + '/30' }}
|
|
|
- </p>
|
|
|
+ <!-- <a @click="showTitle()">推荐广告语</a> -->
|
|
|
+ <div style="position:relative" v-for="(item, index) in descriptionList" :key="index">
|
|
|
+ <a-textarea
|
|
|
+ class="rending"
|
|
|
+ placeholder="请输入广告语"
|
|
|
+ @change="descriptionchange(item.value, index)"
|
|
|
+ v-model="item.value"
|
|
|
+ :autosize="{ minRows: 2, maxRows: 6 }"
|
|
|
+ :max-length="30"
|
|
|
+ style=" width: 80%;"
|
|
|
+ ></a-textarea>
|
|
|
+ <p
|
|
|
+ style="
|
|
|
+ font-size: 12px;
|
|
|
+ color: #b6bbc7;
|
|
|
+ letter-spacing: 0.3px;
|
|
|
+ text-align: right;
|
|
|
+ line-height: 30px;
|
|
|
+ position: absolute;
|
|
|
+ bottom: 0;
|
|
|
+ left: 0;
|
|
|
+ width: 80%;
|
|
|
+ margin-bottom: 0;
|
|
|
+ "
|
|
|
+ >
|
|
|
+ {{ item.value.length }}/30
|
|
|
+ <!-- {{ getFormData('description').length }}/30 -->
|
|
|
+ </p>
|
|
|
+ <div style="position:absolute;right:0;top:-10px">
|
|
|
+ <a-icon
|
|
|
+ type="plus"
|
|
|
+ @click="addDescription()"
|
|
|
+ style="margin-right:15px"
|
|
|
+ v-if="descriptionList.length < 10"
|
|
|
+ />
|
|
|
+ <a-icon
|
|
|
+ type="minus"
|
|
|
+ @click="removeDescription(index)"
|
|
|
+ v-if="descriptionList.length > 1"
|
|
|
+ />
|
|
|
+ </div>
|
|
|
</div>
|
|
|
- <br />
|
|
|
<a @click="cunTitle()">收藏</a>
|
|
|
<a @click="showCunTitle()" style="margin-left: 10px">收藏列表</a>
|
|
|
<!--
|
|
@@ -890,7 +915,7 @@
|
|
|
<a-col :span="8">
|
|
|
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol">
|
|
|
当前选择数量
|
|
|
- {{ sumContent + '/' + (getData('createType')=='0'?getData('createCount'):getData('createCount')*15) }}
|
|
|
+ {{ sumContent + '/' + (getData('unitType')=='4'?(getData('createType')=='0'?getData('createCount'):getData('createCount')*15):getData('createCount')*getData('imageCount') )}}
|
|
|
<a-button type="primary" @click="tongbu()" :loading="tongbuLoading" style="margin-left:10px" v-if="mediaDimension == 'a'">
|
|
|
刷新素材</a-button>
|
|
|
</a-form-item>
|
|
@@ -939,10 +964,13 @@
|
|
|
</video> -->
|
|
|
<a-checkbox
|
|
|
:value="item.photoId"
|
|
|
- style="width: 100%; position: absolute; z-index: 100; right: 0; top: 0"
|
|
|
+ style="width: 100%; position: absolute; z-index: 100; right: 0; top: 0; max-height: 80%;overflow: hidden;"
|
|
|
>
|
|
|
<img :src="item.coverUrl" alt="" style="width: 90%; margin-bottom: 30px" />
|
|
|
- <div>
|
|
|
+
|
|
|
+
|
|
|
+ </a-checkbox>
|
|
|
+ <div style="position: absolute; z-index: 100; bottom: 35px;width:100%;left:0">
|
|
|
<div style="width: 100%; text-align: center">
|
|
|
{{ item.statDate&&item.channelType == 0 ?
|
|
|
'内部 ' + item.statDate.split(' ')[0]:item.statDate&&item.channelType == 1 ?
|
|
@@ -950,9 +978,7 @@
|
|
|
'内部 ' + item.charge :'素造 ' + item.charge}}
|
|
|
</div>
|
|
|
</div>
|
|
|
-
|
|
|
- </a-checkbox>
|
|
|
- <a @click="matemalVideo(item, index)" style="position: absolute; z-index: 100; right: 56px; bottom: 5px"
|
|
|
+ <a @click="matemalVideo(item, index)" style="position: absolute; z-index: 100; right: 0; bottom: 5px;width:100%;text-align:center"
|
|
|
>查看视频</a
|
|
|
>
|
|
|
</li>
|
|
@@ -1236,6 +1262,7 @@ export default {
|
|
|
|
|
|
data() {
|
|
|
return {
|
|
|
+ descriptionList: [{value:''}],
|
|
|
showNumber:false,
|
|
|
md5Str:'',
|
|
|
photoId:'',
|
|
@@ -1441,6 +1468,17 @@ export default {
|
|
|
},
|
|
|
},
|
|
|
methods: {
|
|
|
+ descriptionchange(val, index) {
|
|
|
+ this.$nextTick(() => {
|
|
|
+ this.descriptionList[index].value = val.replace(/\s*/g, '').trim()
|
|
|
+ })
|
|
|
+ },
|
|
|
+ addDescription() {
|
|
|
+ this.descriptionList.push({ value: '' })
|
|
|
+ },
|
|
|
+ removeDescription(index) {
|
|
|
+ this.descriptionList.splice(index, 1)
|
|
|
+ },
|
|
|
searchVideo() {
|
|
|
let url = '/kuaishou/kuaiShouVideoGet/getBatchV2VideoList'
|
|
|
let params = {}
|
|
@@ -1451,6 +1489,7 @@ export default {
|
|
|
params.status = 0
|
|
|
params.photoId = this.photoId
|
|
|
params.photoName = this.photoName
|
|
|
+ params.materialType =this.creativeMaterialType
|
|
|
if(this.mediaDimension == 'a'){
|
|
|
url = '/kuaishou/kuaiShouVideoGet/getBatchV2VideoList'
|
|
|
// params.signatures = this.md5Str
|
|
@@ -1498,28 +1537,49 @@ export default {
|
|
|
},
|
|
|
okTitleCun(item) {
|
|
|
this.allForm.description = item.title
|
|
|
- this.form.setFieldsValue({
|
|
|
- description: item.title,
|
|
|
- })
|
|
|
+ // this.form.setFieldsValue({
|
|
|
+ // description: item.title,
|
|
|
+ // })
|
|
|
+
|
|
|
+
|
|
|
+ if (this.descriptionList[0].value == '') {
|
|
|
+ this.descriptionList = [{value:item.title}]
|
|
|
+ } else {
|
|
|
+ for (let index = 0; index < this.descriptionList.length; index++) {
|
|
|
+ if (this.descriptionList[index].value == '') {
|
|
|
+ this.descriptionList.splice(index, 1)
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if(this.descriptionList.length<=9){
|
|
|
+ this.descriptionList.push({value:item.title})
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
this.cunTitleVisible = false
|
|
|
this.cunTitleList = []
|
|
|
},
|
|
|
cunTitle() {
|
|
|
- if (this.getData('description') && this.getData('description') == '') {
|
|
|
- this.$message.error('请填写广告语后再进行收藏')
|
|
|
- } else {
|
|
|
- var params = {}
|
|
|
- params.accountId = localStorage.getItem('campaignAccountId')
|
|
|
- params.userId = this.userInfo().id
|
|
|
- params.title = this.getData('description')
|
|
|
- postAction('/kuaishou/kuaiShouTitleCollection/add', params).then((res) => {
|
|
|
- if (res.success) {
|
|
|
- this.$message.success('收藏成功')
|
|
|
- } else {
|
|
|
- this.$message.error(res.message)
|
|
|
- }
|
|
|
- })
|
|
|
+ let isNotComplete = this.descriptionList.findIndex(item => {
|
|
|
+ return item.value === ''
|
|
|
+ })
|
|
|
+ if (isNotComplete > -1) {
|
|
|
+ this.$message.error('广告语未填,不可收藏')
|
|
|
+ return
|
|
|
}
|
|
|
+ var params = {}
|
|
|
+ params.accountId = localStorage.getItem('campaignAccountId')
|
|
|
+ params.userId = this.userInfo().id
|
|
|
+ params.titles = this.descriptionList.map(item=>{
|
|
|
+ return item.value
|
|
|
+ })
|
|
|
+ postAction('/kuaishou/kuaiShouTitleCollection/addMore', params).then((res) => {
|
|
|
+ if (res.success) {
|
|
|
+ this.$message.success('收藏成功')
|
|
|
+ } else {
|
|
|
+ this.$message.error(res.message)
|
|
|
+ }
|
|
|
+ })
|
|
|
+
|
|
|
},
|
|
|
showCunTitle() {
|
|
|
this.cunTitleVisible = true
|
|
@@ -1540,9 +1600,18 @@ export default {
|
|
|
okTitle(item) {
|
|
|
this.allForm.description = item
|
|
|
this.$nextTick(() => {
|
|
|
- this.form.setFieldsValue({
|
|
|
- description: item,
|
|
|
- })
|
|
|
+ if (this.descriptionList[0].value == '') {
|
|
|
+ this.descriptionList = [{value:item}]
|
|
|
+ } else {
|
|
|
+ for (let index = 0; index < this.descriptionList.length; index++) {
|
|
|
+ if (this.descriptionList[index].value == '') {
|
|
|
+ this.descriptionList.splice(index, 1)
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if(this.descriptionList.length<=9){
|
|
|
+ this.descriptionList.push({value:item})
|
|
|
+ }
|
|
|
+ }
|
|
|
})
|
|
|
|
|
|
this.titleVisible = false
|
|
@@ -1847,26 +1916,39 @@ export default {
|
|
|
sum += this.checkVideoWai[i].length
|
|
|
}
|
|
|
this.sumContent = sum
|
|
|
- if (this.getData('createType') == '0') {
|
|
|
- if (sum > this.getData('createCount')) {
|
|
|
- this.$message.error('最多选择' + this.getData('createCount') + '个素材')
|
|
|
- this.checkVideo = []
|
|
|
- this.sumContent = this.sumContent - 10
|
|
|
-
|
|
|
- // if (this.active == 0) {
|
|
|
- this.checkVideoAll[this.ipagination.current - 1] = this.checkVideo
|
|
|
-
|
|
|
+ if(this.getData('unitType') == '4'){
|
|
|
+ if (this.getData('createType') == '0') {
|
|
|
+ if (sum > this.getData('createCount')) {
|
|
|
+ this.$message.error('最多选择' + this.getData('createCount') + '个素材')
|
|
|
+ this.checkVideo = []
|
|
|
+ this.sumContent = this.sumContent - 10
|
|
|
+
|
|
|
+ // if (this.active == 0) {
|
|
|
+ this.checkVideoAll[this.ipagination.current - 1] = this.checkVideo
|
|
|
+
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ if (sum > this.getData('createCount') * 15) {
|
|
|
+ this.$message.error('最多选择' + this.getData('createCount') * 15 + '个素材')
|
|
|
+ this.checkVideo = []
|
|
|
+ this.sumContent = this.sumContent - 15
|
|
|
+
|
|
|
+ // if (this.active == 0) {
|
|
|
+ this.checkVideoAll[this.ipagination.current - 1] = this.checkVideo
|
|
|
+ // } else if (this.active == 1) {
|
|
|
+ // this.checkVideoWai[this.ipagination.current - 1] = this.checkVideo
|
|
|
+ // }
|
|
|
+ }
|
|
|
}
|
|
|
- } else {
|
|
|
- if (sum > this.getData('createCount') * 15) {
|
|
|
- this.$message.error('最多选择' + this.getData('createCount') * 15 + '个素材')
|
|
|
+ }else{
|
|
|
+ if (sum > this.getData('createCount')*this.getData('imageCount')) {
|
|
|
+ this.$message.error('最多选择'+this.getData('createCount')*this.getData('imageCount')+'个素材')
|
|
|
this.checkVideo = []
|
|
|
- this.sumContent = this.sumContent - 15
|
|
|
-
|
|
|
+ this.sumContent-=10
|
|
|
// if (this.active == 0) {
|
|
|
this.checkVideoAll[this.ipagination.current - 1] = this.checkVideo
|
|
|
// } else if (this.active == 1) {
|
|
|
- // this.checkVideoWai[this.ipagination.current - 1] = this.checkVideo
|
|
|
+ // this.checkVideoWai[this.ipagination.current - 1] = this.checkVideo
|
|
|
// }
|
|
|
}
|
|
|
}
|
|
@@ -1892,21 +1974,33 @@ export default {
|
|
|
sum += this.checkVideoWai[i].length
|
|
|
}
|
|
|
this.sumContent = sum
|
|
|
-
|
|
|
- if (this.getData('createType') == '0') {
|
|
|
- if (sum > this.getData('createCount')) {
|
|
|
- this.$message.error('最多选择' + this.getData('createCount') + '个素材')
|
|
|
- this.checkVideo.pop()
|
|
|
- this.sumContent--
|
|
|
- // if (this.active == 0) {
|
|
|
- this.checkVideoAll[this.ipagination.current - 1] = this.checkVideo
|
|
|
- // } else if (this.active == 1) {
|
|
|
- // this.checkVideoWai[this.ipagination.current - 1] = this.checkVideo
|
|
|
- // }
|
|
|
+ if(this.getData('unitType') == '4'){
|
|
|
+ if (this.getData('createType') == '0') {
|
|
|
+ if (sum > this.getData('createCount')) {
|
|
|
+ this.$message.error('最多选择' + this.getData('createCount') + '个素材')
|
|
|
+ this.checkVideo.pop()
|
|
|
+ this.sumContent--
|
|
|
+ // if (this.active == 0) {
|
|
|
+ this.checkVideoAll[this.ipagination.current - 1] = this.checkVideo
|
|
|
+ // } else if (this.active == 1) {
|
|
|
+ // this.checkVideoWai[this.ipagination.current - 1] = this.checkVideo
|
|
|
+ // }
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ if (sum > this.getData('createCount') * 15) {
|
|
|
+ this.$message.error('最多选择' + this.getData('createCount') * 15 + '个素材')
|
|
|
+ this.checkVideo.pop()
|
|
|
+ this.sumContent--
|
|
|
+ // if (this.active == 0) {
|
|
|
+ this.checkVideoAll[this.ipagination.current - 1] = this.checkVideo
|
|
|
+ // } else if (this.active == 1) {
|
|
|
+ // this.checkVideoWai[this.ipagination.current - 1] = this.checkVideo
|
|
|
+ // }
|
|
|
+ }
|
|
|
}
|
|
|
- } else {
|
|
|
- if (sum > this.getData('createCount') * 15) {
|
|
|
- this.$message.error('最多选择' + this.getData('createCount') * 15 + '个素材')
|
|
|
+ }else{
|
|
|
+ if (sum > this.getData('createCount')*this.getData('imageCount')) {
|
|
|
+ this.$message.error('最多选择'+this.getData('createCount')*this.getData('imageCount')+'个素材')
|
|
|
this.checkVideo.pop()
|
|
|
this.sumContent--
|
|
|
// if (this.active == 0) {
|
|
@@ -1916,6 +2010,8 @@ export default {
|
|
|
// }
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
+
|
|
|
},
|
|
|
getVideoList() {
|
|
|
this.orderBy = 'time'
|
|
@@ -1939,7 +2035,8 @@ export default {
|
|
|
// })
|
|
|
},
|
|
|
getDataSource(page, pageSize) {
|
|
|
-
|
|
|
+ console.log(this.checkVideo, this.checkVideoAll)
|
|
|
+ this.checkVideo = this.checkVideoAll[page-1]
|
|
|
this.ipagination.current = page
|
|
|
this.searchVideo()
|
|
|
},
|
|
@@ -1983,13 +2080,17 @@ export default {
|
|
|
changeType() {
|
|
|
this.$nextTick(() => {
|
|
|
if (this.getData('creativeMaterialType') == '1') {
|
|
|
- this.form.setFieldsValue({
|
|
|
- name: '自定义创意_竖版视频',
|
|
|
- })
|
|
|
+ if(this.getData('unitType') == '4') {
|
|
|
+ this.form.setFieldsValue({creativeName:'自定义创意_竖版视频'})
|
|
|
+ }else{
|
|
|
+ this.form.setFieldsValue({creativeName:'程序化创意_竖版视频'})
|
|
|
+ }
|
|
|
} else {
|
|
|
- this.form.setFieldsValue({
|
|
|
- name: '自定义创意_横版视频',
|
|
|
- })
|
|
|
+ if(this.getData('unitType') == '4') {
|
|
|
+ this.form.setFieldsValue({creativeName:'自定义创意_横版视频'})
|
|
|
+ }else{
|
|
|
+ this.form.setFieldsValue({creativeName:'程序化创意_横版视频'})
|
|
|
+ }
|
|
|
}
|
|
|
})
|
|
|
},
|
|
@@ -2174,15 +2275,15 @@ export default {
|
|
|
return this.form.getFieldValue(className)
|
|
|
},
|
|
|
bidCheck(rule, value, callback) {
|
|
|
- if (value < 0.2 || value > this.maxBid) {
|
|
|
- callback('不得低于0.2元,不得高于项目最高出价' + this.maxBid + '元')
|
|
|
+ if (value < 0.2) {
|
|
|
+ callback('不得低于0.2元')
|
|
|
} else {
|
|
|
callback()
|
|
|
}
|
|
|
},
|
|
|
cpaBidCheck(rule, value, callback) {
|
|
|
- if (value < 1 || value > this.maxBid) {
|
|
|
- callback('不得低于1元,不得高于项目最高出价' + this.maxBid + '元')
|
|
|
+ if (value < 1) {
|
|
|
+ callback('不得低于1元')
|
|
|
} else {
|
|
|
callback()
|
|
|
}
|
|
@@ -2315,13 +2416,27 @@ export default {
|
|
|
e.preventDefault()
|
|
|
if (
|
|
|
this.checkVideo.length <
|
|
|
- (this.getData('createType') == '0' ? this.getData('createCount') : this.getData('createCount') * 15)
|
|
|
+ (this.getData('unitType')=='4'?this.getData('createType') == '0' ? this.getData('createCount') : this.getData('createCount') * 15:
|
|
|
+ this.getData('createCount')*this.getData('imageCount'))
|
|
|
) {
|
|
|
// this.$message.error('选择的素材不能小于创建条数')
|
|
|
+ this.getData('unitType')=='4'?
|
|
|
this.getData('createType') == '0'
|
|
|
? this.$message.error('选择的素材不能小于创建条数')
|
|
|
- : this.$message.error('选择的素材不能小于创建条数*15')
|
|
|
+ : this.$message.error('选择的素材不能小于创建条数*15'):
|
|
|
+ this.$message.error('选择的素材不能小于创建条数*'+this.getData('imageCount'))
|
|
|
} else {
|
|
|
+ let isNotComplete = this.descriptionList.findIndex(item => {
|
|
|
+ return item.value === ''
|
|
|
+ })
|
|
|
+ if (isNotComplete > -1) {
|
|
|
+ this.$message.error('广告语未填')
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if(this.getData('unitType')=='7'&&this.descriptionList.length<3){
|
|
|
+ this.$message.error('程序化创意广告语最少三条')
|
|
|
+ return
|
|
|
+ }
|
|
|
this.form.validateFieldsAndScroll((err, values) => {
|
|
|
if (!err) {
|
|
|
this.loading = true
|
|
@@ -2344,12 +2459,13 @@ export default {
|
|
|
creativeCategory: values.creativeCategory
|
|
|
? values.creativeCategory[values.creativeCategory.length - 1]
|
|
|
: null,
|
|
|
- unitType: '4',
|
|
|
+ unitType: values.unitType,
|
|
|
}
|
|
|
var params = {
|
|
|
userId: this.userInfo().id,
|
|
|
...json,
|
|
|
...groupArr[0],
|
|
|
+ description:JSON.stringify(this.descriptionList.map(item=>{return item.value})),
|
|
|
accountId: localStorage.getItem('campaignAccountId'),
|
|
|
campaignId: localStorage.getItem('campaignList'),
|
|
|
beginTime: moment(this.timeRange[0]).format('YYYY-MM-DD'),
|
|
@@ -2379,6 +2495,34 @@ export default {
|
|
|
onChange(value) {
|
|
|
// console.log(value)
|
|
|
},
|
|
|
+ changeUnitType(e){
|
|
|
+ this.sumContent = 0
|
|
|
+ this.videoList = []
|
|
|
+ this.checkVideo = []
|
|
|
+ this.checkVideoAll = []
|
|
|
+ this.ipagination.pageSize = 10
|
|
|
+ this.$nextTick(()=>{
|
|
|
+ if (this.getData('creativeMaterialType') == '1') {
|
|
|
+ if(this.getData('unitType') == '4') {
|
|
|
+ this.form.setFieldsValue({creativeName:'自定义创意_竖版视频'})
|
|
|
+ }else{
|
|
|
+ this.form.setFieldsValue({creativeName:'程序化创意_竖版视频'})
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ if(this.getData('unitType') == '4') {
|
|
|
+ this.form.setFieldsValue({creativeName:'自定义创意_横版视频'})
|
|
|
+ }else{
|
|
|
+ this.form.setFieldsValue({creativeName:'程序化创意_横版视频'})
|
|
|
+ }
|
|
|
+ }
|
|
|
+ // if(e.target.value == '4') {
|
|
|
+ // this.form.setFieldsValue({creativeName:'自定义创意_竖版视频'})
|
|
|
+ // }else{
|
|
|
+ // this.form.setFieldsValue({creativeName:'程序化创意_竖版视频'})
|
|
|
+ // }
|
|
|
+ })
|
|
|
+
|
|
|
+ },
|
|
|
handleChange(value) {
|
|
|
// this.$refs.population.getAppList(value)
|
|
|
this.getSiteList(value)
|
|
@@ -2574,7 +2718,10 @@ export default {
|
|
|
// this.checkVideo = [...new Set(n)]
|
|
|
},
|
|
|
time(n, o) {
|
|
|
- this.searchVideo()
|
|
|
+ if(this.visibleMatemal){
|
|
|
+ this.searchVideo()
|
|
|
+ }
|
|
|
+
|
|
|
// if (n.length > 0) {
|
|
|
// var params = {}
|
|
|
// params.accountId = localStorage.getItem('campaignAccountId')
|