Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-activity-center
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 52257343
authored
Jul 11, 2023
by
王志慧
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
喜报配置
1 parent
0ede34d7
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
37 additions
and
36 deletions
src/api/modules/clewOrder.js
src/views/bulletin/addClewConfig.vue
src/views/bulletin/components/clewOrder/index.vue
src/views/bulletin/components/dialogs/clewWordDialog.vue
src/api/modules/clewOrder.js
View file @
5225734
...
...
@@ -35,6 +35,15 @@ const updateClueReportConfig = params => {
returnAll
:
true
})
}
export
default
{
getMerchantList
,
getClueReportList
,
updateClueReportConfig
}
// 根据ID获取线索喜报配置信息
const
getClueDetailById
=
params
=>
{
params
.
method
=
`scrm.api.shopmall.clueReportConfig.getById`
return
http
({
url
,
method
:
'post'
,
data
:
params
,
sign
:
true
,
returnAll
:
true
})
}
export
default
{
getMerchantList
,
getClueReportList
,
updateClueReportConfig
,
getClueDetailById
}
src/views/bulletin/addClewConfig.vue
View file @
5225734
...
...
@@ -8,7 +8,7 @@
<div
class=
"config-wrap gl-form-page"
>
<el-form
ref=
"battleRef"
:model=
"config"
label-width=
"154px"
:rules=
"rules"
>
<el-form-item
label=
"门店信息:"
prop=
"merchantId"
>
<el-button
type=
"default"
class=
"el-icon-plus"
@
click=
"handleRelateStoreClose"
>
选择门店
</el-button>
<el-button
type=
"default"
class=
"el-icon-plus"
@
click=
"handleRelateStoreClose"
:disabled=
"id!=''"
>
选择门店
</el-button>
<div
class=
"merchantNameLabel"
v-if=
"config.merchantName"
>
<p>
所属门店
</p>
<div
class=
"merchantName ellipsis-1"
>
{{
config
.
merchantName
}}
</div>
...
...
@@ -87,10 +87,10 @@ export default {
},
data
()
{
return
{
id
:
this
.
$route
.
query
.
id
?
this
.
$route
.
query
.
id
:
''
,
selectGroupName
:
[],
isDialogVisible
:
false
,
relateStoreVisible
:
false
,
// 选择门店
paramsData
:
this
.
$route
.
query
,
dialogComponent
:
''
,
merchantList
:
[],
automaticData
:
[],
...
...
@@ -113,7 +113,7 @@ export default {
},
rules
:
{
merchantId
:
[{
required
:
true
,
message
:
'请选择门店信息'
,
trigger
:
'change'
}],
groupMerchantId
:
[{
required
:
true
,
message
:
'请选择所属企业'
,
trigger
:
'change'
}]
,
groupMerchantId
:
{
required
:
true
,
message
:
'请选择所属企业'
,
trigger
:
[
'blur'
,
'change'
],
type
:
'number'
}
,
staffId
:
[{
required
:
true
,
message
:
'请选择推送人'
,
trigger
:
'change'
}]
},
groupCofListInput
:
{
...
...
@@ -149,10 +149,9 @@ export default {
}
},
mounted
()
{
let
{
data
}
=
this
.
paramsData
this
.
getMerchantList
(
data
)
this
.
getMerchantList
()
this
.
getDepartmentTree
()
if
(
data
)
this
.
handlebattleOn
(
data
)
if
(
this
.
id
)
this
.
getClueDetailById
(
)
},
methods
:
{
// 选择门店
...
...
@@ -193,10 +192,9 @@ export default {
getMerchantList
(
sign
)
{
this
.
$apis
.
battle
.
getMerchantList
({}).
then
(
res
=>
{
this
.
merchantList
=
res
if
(
!
sign
)
{
if
(
!
this
.
id
)
{
this
.
config
.
groupMerchantId
=
res
[
0
]?.
merchantId
this
.
config
.
groupMerchantName
=
res
[
0
]?.
merchantName
console
.
log
(
this
.
config
)
}
})
},
...
...
@@ -208,26 +206,22 @@ export default {
this
.
hideSelect
()
this
.
config
.
automaticName
=
data
.
name
this
.
config
.
staffId
=
data
.
staffId
this
.
idBefEncryption
=
data
.
idBefEncryption
this
.
idBefEncryption
=
data
.
idBefEncryption
?
data
.
idBefEncryption
:
'1688855154413617'
this
.
$refs
.
battleRef
.
clearValidate
(
'staffId'
)
this
.
$apis
.
battle
.
activityreportWorktool
({
cloudId
:
1688855154413617
}).
then
(
res
=>
{
this
.
$apis
.
battle
.
activityreportWorktool
({
cloudId
:
this
.
idBefEncryption
}).
then
(
res
=>
{
this
.
selectGroupName
=
res
.
data
.
result
||
[]
this
.
groupCofListInput
=
{
clewWordReportValue
:
[{
name
:
''
}]
}
})
},
//编辑回显
handlebattleOn
(
data
,
sign
)
{
this
.
config
=
{
staffId
:
''
,
automaticName
:
''
}
getClueDetailById
()
{
this
.
groupCofListInput
=
{
// xiReportValue: [],
clewWordReportValue
:
[]
}
this
.
battleVisible
=
true
// 编辑
if
(
sign
)
{
this
.
$apis
.
clewOrder
.
getClueDetailById
({
id
:
this
.
id
}).
then
(
res
=>
{
let
data
=
res
.
data
// 编辑
this
.
config
.
staffId
=
data
.
staffId
this
.
config
.
automaticName
=
data
.
staffName
this
.
config
.
merchantId
=
data
.
merchantId
...
...
@@ -236,7 +230,8 @@ export default {
this
.
config
.
groupMerchantName
=
data
.
groupMerchantName
this
.
config
.
content
=
data
.
content
data
.
groupConfigList
.
forEach
(
item
=>
{
let
groupHideAttr
=
this
.
groupToType
.
find
(
k
=>
k
.
type
==
item
.
actionReportType
)?.
attr
// let groupHideAttr = this.groupToType.find(k => k.type == item.actionReportType)?.attr
let
groupHideAttr
=
'clewWordReport'
if
(
!
groupHideAttr
)
return
if
(
item
.
groupId
)
{
if
(
item
.
groupId
.
split
(
'_R:'
)[
1
]
&&
item
.
groupId
.
split
(
'_R:'
)[
1
]
==
item
.
groupName
)
{
...
...
@@ -262,16 +257,12 @@ export default {
this
.
$apis
.
battle
.
activityreportWorktool
({
cloudId
:
this
.
idBefEncryption
}).
then
(
res
=>
{
this
.
selectGroupName
=
res
.
data
.
result
||
[]
})
}
else
{
this
.
groupCofListInput
=
{
clewWordReportValue
:
[{
name
:
''
}]
}
}
this
.
getDepartmentTree
()
this
.
getDepartmentTree
()
})
},
//所属企业
handleMerchatChange
(
val
)
{
console
.
log
(
val
)
this
.
getDepartmentTree
()
this
.
merchantList
.
forEach
(
item
=>
{
item
.
merchantId
==
val
?
(
this
.
config
.
groupMerchantName
=
item
.
merchantName
)
:
''
...
...
@@ -364,13 +355,15 @@ export default {
groupConfigList
:
[],
content
:
this
.
config
.
content
}
if
(
this
.
id
)
params
.
id
=
this
.
id
Object
.
keys
(
this
.
groupCofList
).
map
(
item
=>
{
if
(
this
.
groupCofList
[
item
].
length
)
{
this
.
groupCofList
[
item
].
forEach
(
k
=>
{
params
.
groupConfigList
.
push
({
groupId
:
k
.
groupId
,
groupName
:
k
.
roomName
,
groupMerchantId
:
this
.
config
.
groupMerchantId
groupMerchantId
:
this
.
config
.
groupMerchantId
,
groupMerchantName
:
this
.
config
.
groupMerchantName
})
})
}
else
if
(
this
.
groupCofListInput
[
item
+
'Value'
].
length
)
{
...
...
@@ -378,7 +371,8 @@ export default {
params
.
groupConfigList
.
push
({
groupId
:
this
.
idBefEncryption
+
'_R:'
+
k
.
name
,
groupName
:
k
.
name
,
groupMerchantId
:
this
.
config
.
groupMerchantId
groupMerchantId
:
this
.
config
.
groupMerchantId
,
groupMerchantName
:
this
.
config
.
groupMerchantName
})
})
}
...
...
src/views/bulletin/components/clewOrder/index.vue
View file @
5225734
This diff is collapsed.
Click to expand it.
src/views/bulletin/components/dialogs/clewWordDialog.vue
View file @
5225734
...
...
@@ -80,12 +80,10 @@ export default {
}
}
},
watch
:
{
content
(
val
)
{
this
.
$nextTick
(()
=>
{
this
.
$refs
.
verbalRef
&&
this
.
$refs
.
verbalRef
.
update
(
val
)
created
()
{
this
.
$nextTick
(()
=>
{
this
.
$refs
.
verbalRef
&&
this
.
$refs
.
verbalRef
.
update
(
this
.
content
)
})
}
},
methods
:
{
handlebattleConfirm
()
{
...
...
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