Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-marketing
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 731e1df3
authored
May 19, 2022
by
胡悦
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
群发接口联调
1 parent
310b7954
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
34 additions
and
46 deletions
src/views/customerTransform/addCustomer.vue
src/views/customerTransform/addCustomer.vue
View file @
731e1df
...
...
@@ -356,20 +356,6 @@ export default {
this
.
$refs
.
selectLabel
.
init
(
this
.
tagging
)
},
handleSubmit
()
{
// let arr = []
// this.tagging.forEach(item => {
// item.labelList.forEach(tag => {
// arr.push({
// groupId: parseInt(item.labelGroup.id),
// groupName: item.labelGroup.name,
// labelId: parseInt(tag.id),
// labelName: tag.name,
// groupType: item.labelType
// })
// })
// })
// this.taggingList = arr
// console.log(this.taggingList)
this
.
$refs
.
basicForm
.
validate
(
valid
=>
{
if
(
valid
)
{
this
.
attachmentShow
=
true
...
...
@@ -388,7 +374,7 @@ export default {
this
.
attachmentText
=
'请输入群发内容'
return
}
this
.
$refs
.
groupForm
.
validate
(
v
=>
{
this
.
$refs
.
groupForm
.
validate
(
async
(
v
)
=>
{
if
(
v
)
{
const
params
=
this
.
getSiftMembers
()
params
.
type
=
1
...
...
@@ -421,27 +407,37 @@ export default {
if
(
params
.
sendType
==
2
)
{
params
.
sendTimeStr
=
this
.
basicForm
.
sendTime
+
' '
+
this
.
basicForm
.
sendDate
}
this
.
addLoading
=
true
this
.
$apis
.
customerTransform
.
insert
(
params
).
then
(
res
=>
{
if
(
res
.
code
==
'-1'
)
{
this
.
$message
({
type
:
'error'
,
message
:
res
.
message
})
}
else
if
(
res
.
code
==
0
)
{
this
.
$message
({
type
:
'success'
,
message
:
'操作成功!'
})
}
else
{
this
.
$message
({
type
:
'error'
,
message
:
res
.
message
})
}
this
.
addLoading
=
false
this
.
$router
.
push
(
'/customerTransform/index'
)
})
const
countParams
=
this
.
getSiftMembers
()
const
count
=
await
this
.
$apis
.
customerTransform
.
customerCount
(
countParams
)
console
.
log
(
count
)
if
(
count
)
{
this
.
addLoading
=
true
this
.
$apis
.
customerTransform
.
insert
(
params
).
then
(
res
=>
{
if
(
res
.
code
==
'-1'
)
{
this
.
$message
({
type
:
'error'
,
message
:
res
.
message
})
}
else
if
(
res
.
code
==
0
)
{
this
.
$message
({
type
:
'success'
,
message
:
'操作成功!'
})
}
else
{
this
.
$message
({
type
:
'error'
,
message
:
res
.
message
})
}
this
.
addLoading
=
false
this
.
$router
.
push
(
'/customerTransform/index'
)
})
}
else
{
this
.
$message
({
type
:
'error'
,
message
:
'客户数不可为0!'
})
}
}
})
}
...
...
@@ -449,15 +445,6 @@ export default {
},
handleSelect
(
val
)
{
this
.
isUpdate
=
true
// const arr = []
// if (val.length != 0) {
// val.forEach(item => {
// if (item.labelList.length != 0) {
// item.labelList.map(i => arr.push(i))
// }
// // arr.push(item.labelList)
// })
// }
this
.
tagging
=
val
let
arr
=
[]
this
.
tagging
.
forEach
(
item
=>
{
...
...
@@ -532,7 +519,8 @@ export default {
// tagId: tagFlag ? this.tagging.map(item => item.id).join(',') : '',
// tagName: tagFlag ? this.tagging.map(item => item.name).join(',') : ''
// tagId: JSON.stringify(this.tagging)
labelList
:
this
.
taggingList
labelList
:
this
.
taggingList
,
combineType
:
2
}
}
if
(
this
.
basicForm
.
condition
.
date
)
{
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment