Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-outbound
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 3c768ce3
authored
Dec 08, 2022
by
前端
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
commit
1 parent
21cb0401
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
49 additions
and
7 deletions
src/api/modules/marketing.js
src/views/marketing/add.vue
src/views/marketing/client.vue
src/views/marketing/details.vue
src/views/marketing/index.vue
src/api/modules/marketing.js
View file @
3c768ce
...
@@ -30,8 +30,7 @@ const findAllCustomerByPage = params => {
...
@@ -30,8 +30,7 @@ const findAllCustomerByPage = params => {
url
,
url
,
method
:
'POST'
,
method
:
'POST'
,
data
:
params
,
data
:
params
,
sign
:
true
,
sign
:
true
returnAll
:
true
})
})
}
}
// 查询短信营销
// 查询短信营销
...
...
src/views/marketing/add.vue
View file @
3c768ce
...
@@ -33,7 +33,7 @@
...
@@ -33,7 +33,7 @@
</div>
</div>
<input
type=
"file"
style=
"opacity: 0"
ref=
"file"
accept=
"*"
@
change=
"uploadFile"
/>
<input
type=
"file"
style=
"opacity: 0"
ref=
"file"
accept=
"*"
@
change=
"uploadFile"
/>
</div>
</div>
<el-popover
placement=
"bottom"
width=
"45
2
"
trigger=
"hover"
>
<el-popover
placement=
"bottom"
width=
"45
5
"
trigger=
"hover"
>
<img
src=
"@/images/table.png"
class=
"preview"
/>
<img
src=
"@/images/table.png"
class=
"preview"
/>
<span
slot=
"reference"
class=
"download-url"
>
模板预览
</span>
<span
slot=
"reference"
class=
"download-url"
>
模板预览
</span>
</el-popover>
</el-popover>
...
@@ -192,7 +192,6 @@ export default {
...
@@ -192,7 +192,6 @@ export default {
this
.
$refs
.
file
.
value
=
''
this
.
$refs
.
file
.
value
=
''
},
},
handleSave
()
{
handleSave
()
{
this
.
loading
=
true
this
.
isUplaod
=
false
this
.
isUplaod
=
false
this
.
isTime
=
false
this
.
isTime
=
false
this
.
isLink
=
false
this
.
isLink
=
false
...
@@ -229,6 +228,7 @@ export default {
...
@@ -229,6 +228,7 @@ export default {
sendTime
:
this
.
addForm
.
date1
+
' '
+
this
.
addForm
.
date2
,
sendTime
:
this
.
addForm
.
date1
+
' '
+
this
.
addForm
.
date2
,
exportName
:
this
.
importName
exportName
:
this
.
importName
}
}
this
.
loading
=
true
this
.
$apis
.
marketing
.
createMessageInfo
(
params
).
then
(
res
=>
{
this
.
$apis
.
marketing
.
createMessageInfo
(
params
).
then
(
res
=>
{
if
(
res
.
code
==
0
)
{
if
(
res
.
code
==
0
)
{
this
.
loading
=
false
this
.
loading
=
false
...
...
src/views/marketing/client.vue
View file @
3c768ce
...
@@ -59,7 +59,7 @@ export default {
...
@@ -59,7 +59,7 @@ export default {
],
],
getListApi
:
this
.
$apis
.
marketing
.
findAllCustomerByPage
,
getListApi
:
this
.
$apis
.
marketing
.
findAllCustomerByPage
,
tableParams
:
{
tableParams
:
{
listName
:
'data
.data
'
,
listName
:
'data'
,
tableOption
:
true
,
tableOption
:
true
,
tableColumns
:
[
tableColumns
:
[
{
{
...
...
src/views/marketing/details.vue
View file @
3c768ce
...
@@ -9,7 +9,7 @@
...
@@ -9,7 +9,7 @@
<div
class=
"flex-top line-text"
:key=
"index"
>
<div
class=
"flex-top line-text"
:key=
"index"
>
<div
class=
"type-text"
>
{{
item
.
text
}}
</div>
<div
class=
"type-text"
>
{{
item
.
text
}}
</div>
<tempalte
v-if=
"item.key == 'exportName'"
>
<tempalte
v-if=
"item.key == 'exportName'"
>
<a
class=
"type-value exportName"
:href=
"detailData.exportUrl
"
>
{{
detailData
[
item
.
key
]
}}
</a>
<a
class=
"type-value exportName"
@
click=
"download(detailData)
"
>
{{
detailData
[
item
.
key
]
}}
</a>
</tempalte>
</tempalte>
<div
v-else
class=
"type-value"
>
{{
detailData
[
item
.
key
]
?
detailData
[
item
.
key
]
:
'--'
}}
</div>
<div
v-else
class=
"type-value"
>
{{
detailData
[
item
.
key
]
?
detailData
[
item
.
key
]
:
'--'
}}
</div>
</div>
</div>
...
@@ -83,6 +83,48 @@ export default {
...
@@ -83,6 +83,48 @@ export default {
this
.
congifDetails
()
this
.
congifDetails
()
},
},
methods
:
{
methods
:
{
download
(
data
)
{
this
.
getBlob
(
data
.
exportUrl
).
then
(
blob
=>
{
this
.
saveAs
(
blob
,
data
.
exportName
)
})
},
getBlob
(
url
)
{
return
new
Promise
(
resolve
=>
{
const
xhr
=
new
XMLHttpRequest
()
xhr
.
open
(
'GET'
,
url
,
true
)
xhr
.
responseType
=
'blob'
xhr
.
onload
=
()
=>
{
if
(
xhr
.
status
===
200
)
{
resolve
(
xhr
.
response
)
}
}
xhr
.
send
()
})
},
saveAs
(
blob
,
filename
)
{
if
(
window
.
navigator
.
msSaveOrOpenBlob
)
{
navigator
.
msSaveBlob
(
blob
,
filename
)
}
else
{
const
link
=
document
.
createElement
(
'a'
)
const
body
=
document
.
querySelector
(
'body'
)
let
binaryData
=
[]
binaryData
.
push
(
blob
)
link
.
href
=
window
.
URL
.
createObjectURL
(
new
Blob
(
binaryData
))
link
.
download
=
filename
// fix Firefox
link
.
style
.
display
=
'none'
body
.
appendChild
(
link
)
link
.
click
()
body
.
removeChild
(
link
)
window
.
URL
.
revokeObjectURL
(
link
.
href
)
}
},
congifDetails
()
{
congifDetails
()
{
let
params
=
{
let
params
=
{
id
:
this
.
id
id
:
this
.
id
...
@@ -134,6 +176,7 @@ export default {
...
@@ -134,6 +176,7 @@ export default {
.exportName
{
.exportName
{
text-decoration
:
underline
;
text-decoration
:
underline
;
color
:
#5850ff
;
color
:
#5850ff
;
cursor
:
pointer
;
}
}
}
}
.form-image
{
.form-image
{
...
...
src/views/marketing/index.vue
View file @
3c768ce
...
@@ -50,7 +50,7 @@ export default {
...
@@ -50,7 +50,7 @@ export default {
type
:
'select'
,
type
:
'select'
,
optionList
:
[
optionList
:
[
{
text
:
'全部'
,
id
:
''
},
{
text
:
'全部'
,
id
:
''
},
{
text
:
'待
发送
'
,
id
:
1
},
{
text
:
'待
处理
'
,
id
:
1
},
{
text
:
'已完成'
,
id
:
2
}
{
text
:
'已完成'
,
id
:
2
}
],
],
optionId
:
'id'
,
optionId
:
'id'
,
...
...
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