Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
common-templete
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
汤强勇
common-templete
Commits
d579d4e1
Commit
d579d4e1
authored
Mar 27, 2019
by
liuying
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
微信短信授权
parent
606a0bd9
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
146 additions
and
98 deletions
+146
-98
dev.env.js
config/dev.env.js
+4
-2
index.js
config/index.js
+1
-4
prod.dev.env.js
config/prod.dev.env.js
+1
-1
index.vue
src/pages/marketingCenter/components/AddMessage/index.vue
+120
-88
index.vue
src/pages/marketingCenter/components/MarketingPush/index.vue
+19
-2
api.js
src/tool/api.js
+1
-1
No files found.
config/dev.env.js
View file @
d579d4e1
...
@@ -4,7 +4,9 @@ const prodEnv = require('./prod.env')
...
@@ -4,7 +4,9 @@ const prodEnv = require('./prod.env')
module
.
exports
=
merge
(
prodEnv
,
{
module
.
exports
=
merge
(
prodEnv
,
{
'NODE_ENV'
:
"'development'"
,
'NODE_ENV'
:
"'development'"
,
'host'
:
"'//localhost'"
,
// 'host': "'//localhost'",
'host'
:
"'http://testcenter.bigaka.net/crm'"
,
'project'
:
"'crm/vue'"
,
'project'
:
"'crm/vue'"
,
'requestUrl'
:
"'crm'"
'requestUrl'
:
"'crm'"
,
'reqUrl'
:
"'/wxcrm-web/'"
})
})
config/index.js
View file @
d579d4e1
...
@@ -13,15 +13,12 @@ module.exports = {
...
@@ -13,15 +13,12 @@ module.exports = {
`
,
`
,
css
:
`
css
:
`
<%@ include file="/WEB-INF/include/css.jsp"%>
<%@ include file="/WEB-INF/include/css.jsp"%>
<link rel="stylesheet" href="\${ctx }/vendors/bootstrap-multiselect-master/dist/css/bootstrap-multiselect.css">
<link rel="stylesheet" href="\${ctx}/css/apps/auto-marketing/filter.css?v=\${v}" />
`
,
`
,
menu
:
`
menu
:
`
<%@ include file="/WEB-INF/include/menu.jsp"%>
<%@ include file="/WEB-INF/include/menu.jsp"%>
`
,
`
,
footer
:
`
footer
:
`
<%@ include file="/WEB-INF/include/js.jsp"%>
<%@ include file="/WEB-INF/include/js.jsp"%>
<script type="text/javascript" src="\${ctx}/vendors/bootstrap-multiselect-master/dist/js/bootstrap-multiselect.js"></script>
`
`
},
},
dev
:
{
dev
:
{
...
@@ -30,7 +27,7 @@ module.exports = {
...
@@ -30,7 +27,7 @@ module.exports = {
assetsPublicPath
:
'/'
,
assetsPublicPath
:
'/'
,
proxyTable
:
{
proxyTable
:
{
'/api'
:
{
'/api'
:
{
target
:
'http://
wxapp.hotwind.net
'
,
// 接口的域名
target
:
'http://
testcenter.bigaka.net/crm
'
,
// 接口的域名
// secure: false, // 如果是https接口,需要配置这个参数
// secure: false, // 如果是https接口,需要配置这个参数
changeOrigin
:
true
,
// 如果接口跨域,需要进行这个参数配置
changeOrigin
:
true
,
// 如果接口跨域,需要进行这个参数配置
pathRewrite
:
{
pathRewrite
:
{
...
...
config/prod.dev.env.js
View file @
d579d4e1
module
.
exports
=
{
module
.
exports
=
{
"host"
:
"'//
wxapp.hotwind.net
'"
,
"host"
:
"'//
testcenter.bigaka.net/crm
'"
,
'project'
:
"'wxcrm-web/vue'"
,
'project'
:
"'wxcrm-web/vue'"
,
'requestUrl'
:
"'crm'"
'requestUrl'
:
"'crm'"
}
}
src/pages/marketingCenter/components/AddMessage/index.vue
View file @
d579d4e1
...
@@ -32,7 +32,7 @@
...
@@ -32,7 +32,7 @@
<img
src=
"@/assets/images/temp.png"
>
<img
src=
"@/assets/images/temp.png"
>
</span>
</span>
<p
class=
"icon-wechat-msg title-center"
>
营销模板消息
</p>
<p
class=
"icon-wechat-msg title-center"
>
营销模板消息
</p>
</div>
</div>
</div>
</div>
</el-col>
</el-col>
<el-col
:span=
"10"
class=
"button-right"
>
<el-col
:span=
"10"
class=
"button-right"
>
...
@@ -81,16 +81,16 @@
...
@@ -81,16 +81,16 @@
<el-button
type=
"primary"
@
click=
"dialogVisible = false"
>
确 定
</el-button>
<el-button
type=
"primary"
@
click=
"dialogVisible = false"
>
确 定
</el-button>
</span>
</span>
</el-dialog>
</el-dialog>
<el-dialog
<el-dialog
title=
"系统提示"
:visible
.
sync=
"dialogTemp"
width=
"500px"
:before-close=
"handleClose"
>
title=
"系统提示"
:visible
.
sync=
"dialogTemp"
width=
"500px"
:before-close=
"handleClose"
>
<div>
<div>
<div
style=
"float: left; width: 30px;"
><i
class=
"el-icon-warning"
style=
"font-size:20px"
></i></div>
<div
style=
"float: left; width: 30px;"
>
<i
class=
"el-icon-warning"
style=
"font-size:20px"
></i>
</div>
<div
style=
"width: 400px;float: left;"
>
<div
style=
"width: 400px;float: left;"
>
<p>
亲爱的舞象云用户,您好:
</p>
<p>
亲爱的舞象云用户,您好:
</p>
<p
style=
"text-indent:25px;margin-top: 20px;"
>
近期,在使用微信营销推送功能时,有部分用户反馈出现推送失败的情况。在舞象云团队紧急分析原因后,暂时定位在调用微信推送接口时,微信反馈接口数量调用达到上限,也就是一次操作数量及频次不能过多。在后续使用时,建议每次推送会员限制在1万以内,并尽量分开时段,不同时发起多次推送。给您带来的困扰,深表抱歉,我们将尽快确定解决方案,完成功能优化。
</p>
<p
style=
"text-indent:25px;margin-top: 20px;"
>
近期,在使用微信营销推送功能时,有部分用户反馈出现推送失败的情况。在舞象云团队紧急分析原因后,暂时定位在调用微信推送接口时,微信反馈接口数量调用达到上限,也就是一次操作数量及频次不能过多。在后续使用时,建议每次推送会员限制在1万以内,并尽量分开时段,不同时发起多次推送。给您带来的困扰,深表抱歉,我们将尽快确定解决方案,完成功能优化。
</p>
</div>
</div>
</div>
</div>
<span
slot=
"footer"
class=
"dialog-footer"
>
<span
slot=
"footer"
class=
"dialog-footer"
>
...
@@ -101,104 +101,136 @@
...
@@ -101,104 +101,136 @@
</div>
</div>
</
template
>
</
template
>
<
script
>
<
script
>
import
api
from
'@/tool/api'
import
api
from
"@/tool/api"
;
const
STATE_OK
=
200
import
config
from
"@/config"
;
const
STATE_OK
=
200
;
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
wechatAuth
:
''
,
wechatAuth
:
""
,
msgAuth
:
''
,
msgAuth
:
""
,
dialogVisible
:
false
,
dialogVisible
:
false
,
dialogTemp
:
false
dialogTemp
:
false
}
}
;
},
},
created
()
{
created
()
{
this
.
getAuth
()
this
.
getAuth
()
;
},
},
methods
:
{
methods
:
{
handleToOpen
(){
handleToOpen
()
{
this
.
dialogVisible
=
false
// this.dialogVisible = false;
window
.
open
(
platformCtx
+
'/message/marketingSms/list.do'
)
},
},
async
getAuth
()
{
async
getAuth
()
{
await
this
.
axios
.
get
(
api
.
getAuthState
).
then
(
res
=>
{
await
this
.
axios
.
get
(
api
.
getAuthState
).
then
(
res
=>
{
if
(
res
&&
res
.
status
===
STATE_OK
){
const
{
data
}
=
res
;
this
.
wechatAuth
=
res
.
data
.
authState
if
(
data
)
{
this
.
msgAuth
=
res
.
data
.
msgAuthState
this
.
wechatAuth
=
data
.
authState
;
}
this
.
msgAuth
=
data
.
msgAuthState
;
})
}
});
},
},
handleAddMaterial
()
{
handleAddMaterial
()
{
if
(
this
.
wechatAuth
===
1
)
{
if
(
this
.
wechatAuth
===
1
)
{
this
.
$router
.
push
(
'addmarketing'
)
this
.
$router
.
push
(
"addmarketing"
);
}
else
{
}
else
{
console
.
log
(
'未授权'
)
console
.
log
(
"未授权"
);
}
}
},
},
handleAddTemp
()
{
handleAddTemp
()
{
if
(
this
.
wechatAuth
===
1
)
{
if
(
this
.
wechatAuth
===
1
){
this
.
dialogTemp
=
true
;
this
.
dialogTemp
=
true
window
.
location
.
href
=
`http://testcenter.bigaka.net/crm/back/wechat/msg-mass/create?type=3`
;
window
.
location
.
href
=
`http://testcenter.bigaka.net/crm/back/wechat/msg-mass/create?type=3`
}
else
{
}
else
{
console
.
log
(
"未授权"
);
console
.
log
(
'未授权'
)
window
.
open
(
ctx
+
"/back/wechat/go-author"
);
window
.
open
(
ctx
+
'/back/wechat/go-author'
);
}
}
},
},
handleAddMessage
()
{
handleAddMessage
()
{
if
(
this
.
msgAuth
===
1
)
{
if
(
this
.
msgAuth
===
1
)
{
// this.$router.push('addmarketing')
// this.$router.push('addmarketing')
}
else
{
}
else
{
this
.
dialogVisible
=
true
this
.
dialogVisible
=
true
;
}
}
},
},
handleClose
(
done
)
{
handleClose
(
done
)
{
this
.
dialogVisible
=
false
this
.
dialogVisible
=
false
;
}
}
},
}
}
}
;
</
script
>
</
script
>
<
style
lang=
'stylus'
scoped
>
<
style
lang=
'stylus'
scoped
>
.marketing-button
.marketing-button
{
margin
8px
0
margin
:
8px
0
;
height
182px
height
:
182px
;
.button-left
,
.button-right
padding-left
5px
.button-left,
.button-right
{
background-color
#fff
padding-left
:
5px
;
height
180px
background-color
:
#fff
;
.left-title
height
:
180px
;
height
50px
line-height
50px
.left-title
{
.left-title-name
height
:
50px
;
img
line-height
:
50px
;
width
30px
height
30px
.left-title-name
{
.left-icon
img
{
height
140px
width
:
30px
;
.icon-left
height
:
30px
;
width
20
%
}
.icon-right
,
.icon-left
}
padding
20px
0
}
text-align
center
.icon-wechat
.left-icon
{
font-size
40px
height
:
140px
;
.icon-wechat-msg
font-size
14px
.icon-left
{
padding-top
10px
width
:
20%
;
.button-right
}
margin-left
10px
.right-marketing
.icon-right
,
.icon-left
{
padding
20px
0
padding
:
20px
0
;
text-align
center
text-align
:
center
;
img
width
64px
.icon-wechat
{
height
64px
font-size
:
40px
;
.icon-wechat
}
font-size
40px
.icon-wechat-msg
.icon-wechat-msg
{
font-size
14px
font-size
:
14px
;
padding-top
10px
padding-top
:
10px
;
.marketing-white
}
background-color
#fff
}
height
27px
}
}
.button-right
{
margin-left
:
10px
;
.right-marketing
{
padding
:
20px
0
;
text-align
:
center
;
img
{
width
:
64px
;
height
:
64px
;
}
.icon-wechat
{
font-size
:
40px
;
}
.icon-wechat-msg
{
font-size
:
14px
;
padding-top
:
10px
;
}
}
}
}
.marketing-white
{
background-color
:
#fff
;
height
:
27px
;
}
</
style
>
</
style
>
src/pages/marketingCenter/components/MarketingPush/index.vue
View file @
d579d4e1
...
@@ -32,7 +32,7 @@
...
@@ -32,7 +32,7 @@
</span>
</span>
<span>
微信触达域-公众号
</span>
<span>
微信触达域-公众号
</span>
<span>
<span>
<a
href=
"#
"
>
<a
:href =
"this.authUrl
"
>
立即授权
</a>
立即授权
</a>
</span>
</span>
</el-col>
</el-col>
...
@@ -42,7 +42,7 @@
...
@@ -42,7 +42,7 @@
</span>
</span>
<span>
移动触达域-短信
</span>
<span>
移动触达域-短信
</span>
<span>
<span>
<a
href=
"#
"
>
<a
:href=
"this.msgUrl
"
>
前往开通
</a>
前往开通
</a>
</span>
</span>
</el-col>
</el-col>
...
@@ -53,6 +53,23 @@
...
@@ -53,6 +53,23 @@
</div>
</div>
</div>
</div>
</
template
>
</
template
>
<
script
>
import
config
from
"@/config"
;
export
default
{
data
()
{
return
{
authUrl
:
""
,
msgUrl
:
""
}
},
created
()
{
this
.
authUrl
=
ctx
+
"/back/wechat/auth"
this
.
msgUrl
=
platformCtx
+
'/message/marketingSms/list.do'
}
}
</
script
>
<
style
lang=
'stylus'
scoped
>
<
style
lang=
'stylus'
scoped
>
.marketing-title
.marketing-title
height
177px
height
177px
...
...
src/tool/api.js
View file @
d579d4e1
...
@@ -2,7 +2,7 @@ import config from '@/config'
...
@@ -2,7 +2,7 @@ import config from '@/config'
export
default
{
export
default
{
getMenu
:
`
${
config
.
host
}
/crm/back/menu/getMenu`
,
getMenu
:
`
${
config
.
host
}
/crm/back/menu/getMenu`
,
getAuthState
:
'http://testcenter.bigaka.net/crm/back/wechat/msg-mass/marketingPushAuthState'
,
getAuthState
:
`
${
config
.
host
}
/back/marketing/push/auth-state`
,
// 营销中心
// 营销中心
getMaterialsList
:
'http://testcenter.bigaka.net/crm/back/wechat/msg-mass/materials-list'
,
// 获取图文素材列表
getMaterialsList
:
'http://testcenter.bigaka.net/crm/back/wechat/msg-mass/materials-list'
,
// 获取图文素材列表
getPushList
:
'http://testcenter.bigaka.net/crm/back/wechat/msg-mass/medialist'
,
// 获取图文推送列表
getPushList
:
'http://testcenter.bigaka.net/crm/back/wechat/msg-mass/medialist'
,
// 获取图文推送列表
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment