Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
glsx
/
dj-scrm-wx-work-attachment-customer
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 a81e69a9
authored
Mar 07, 2022
by
王志慧
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
commit
1 parent
49dd6588
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
11 additions
and
3 deletions
src/api/groupChat.js
src/config/env.development.js
src/config/index.js
src/views/customerGroup/index.vue
src/api/groupChat.js
View file @
a81e69a
// const url = 'http://192.168.1.64:8064/rop-scrm-entmicro/router'
// const url = 'http://192.168.1.64:8064/rop-scrm-entmicro/router'
// const url = 'http://scrm.dev.glsx.com.cn/rop-scrm-entmicro/router'
const
url
=
'/rop-scrm-entmicro/router'
const
url
=
'/rop-scrm-entmicro/router'
export
default
{
export
default
{
/**获取群聊列表 */
/**获取群聊列表 */
...
...
src/config/env.development.js
View file @
a81e69a
...
@@ -11,7 +11,7 @@ module.exports = {
...
@@ -11,7 +11,7 @@ module.exports = {
envVersion
:
"develop"
,
envVersion
:
"develop"
,
title
:
'嘀加企微管家'
,
title
:
'嘀加企微管家'
,
request
:
{
request
:
{
baseURL
:
'http
s
://scrm.dev.glsx.com.cn'
,
// 本地测试项目地址,
baseURL
:
'http://scrm.dev.glsx.com.cn'
,
// 本地测试项目地址,
// 设置超时时间
// 设置超时时间
timeout
:
180000
,
timeout
:
180000
,
// 携带凭证
// 携带凭证
...
...
src/config/index.js
View file @
a81e69a
...
@@ -10,7 +10,7 @@
...
@@ -10,7 +10,7 @@
let
config
=
require
(
'./conf.js'
)
let
config
=
require
(
'./conf.js'
)
let
timeout
=
30000
//超时时间
let
timeout
=
30000
//超时时间
export
const
fetchConfig
=
function
(
isEnv
=
true
)
{
export
const
fetchConfig
=
function
(
isEnv
=
true
)
{
if
(
isEnv
)
{
if
(
!
isEnv
)
{
let
{
request
}
=
config
let
{
request
}
=
config
Object
.
assign
(
request
,
{
timeout
})
Object
.
assign
(
request
,
{
timeout
})
return
Promise
.
resolve
(
config
)
return
Promise
.
resolve
(
config
)
...
...
src/views/customerGroup/index.vue
View file @
a81e69a
...
@@ -119,13 +119,19 @@ export default {
...
@@ -119,13 +119,19 @@ export default {
deactivated
()
{},
deactivated
()
{},
mounted
()
{
mounted
()
{
this
.
initData
()
this
.
initData
()
this
.
initWx
()
},
},
methods
:
{
methods
:
{
//初始化微信接口
initWx
()
{
wxConfig
.
init
([
'openEnterpriseChat'
,
'openExistedChatWithMsg'
]).
then
(()
=>
{})
},
// 创建群聊or进入群聊
// 创建群聊or进入群聊
addGroup
()
{
addGroup
()
{
console
.
log
(
this
.
addGroupParams
,
'-----'
)
console
.
log
(
this
.
addGroupParams
,
'-----'
)
if
(
this
.
addGroupParams
.
chatId
==
''
)
{
if
(
this
.
addGroupParams
.
chatId
==
''
)
{
wxConfig
.
openEnterpriseChat
(
this
.
addGroupParams
).
then
(
res
=>
{
wxConfig
.
openEnterpriseChat
(
this
.
addGroupParams
).
then
(
res
=>
{
console
.
log
(
res
,
'res'
)
this
.
insertParams
.
chatId
=
res
.
chatId
this
.
insertParams
.
chatId
=
res
.
chatId
this
.
insertParams
.
externalUserId
=
this
.
userId
this
.
insertParams
.
externalUserId
=
this
.
userId
this
.
insertParams
.
templateId
=
this
.
templateId
this
.
insertParams
.
templateId
=
this
.
templateId
...
@@ -238,7 +244,8 @@ export default {
...
@@ -238,7 +244,8 @@ export default {
let
externalUserId
=
id
let
externalUserId
=
id
this
.
addGroupParams
.
externalUserIds
.
push
(
id
)
this
.
addGroupParams
.
externalUserIds
.
push
(
id
)
this
.
getCustomerInfo
(
externalUserId
)
this
.
getCustomerInfo
(
externalUserId
)
}
else
{
}
else
{
wxConfig
.
init
([
'getCurExternalContact'
,
'openEnterpriseChat'
,
'openExistedChatWithMsg'
]).
then
(()
=>
{
wxConfig
.
init
([
'getCurExternalContact'
,
'openEnterpriseChat'
,
'openExistedChatWithMsg'
]).
then
(()
=>
{
//获取userId
//获取userId
wxConfig
wxConfig
...
...
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