Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
江名洋
/
linkwe-scrm
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 e5fc15c5
authored
Nov 26, 2021
by
xinla
Browse Files
Options
Browse Files
Tag
Download
Plain Diff
Merge remote-tracking branch 'origin/front_end_1.5' into front_end_dev_2.0
2 parents
7a28842e
6b97dc24
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
58 additions
and
59 deletions
linkwe-ui/src/api/conversation/content.js
linkwe-ui/src/views/conversation/content/component/chatListClass.vue
linkwe-ui/src/views/conversation/content/component/chatListClassTab.vue
linkwe-ui/src/views/conversation/content/customer.vue
linkwe-ui/src/views/conversation/content/employee.vue
linkwe-ui/src/api/conversation/content.js
View file @
e5fc15c
import
request
from
'@/utils/request'
import
request
from
'@/utils/request'
// 外部联系人 会话列表
// 外部联系人 会话列表
const
getExternalChatList
=
fromId
=>
{
export
const
getExternalChatList
=
fromId
=>
{
return
request
({
return
request
({
url
:
'/chat/msg/selectExternalChatList/'
+
fromId
,
url
:
'/chat/msg/selectExternalChatList/'
+
fromId
,
method
:
'get'
method
:
'get'
...
@@ -9,7 +9,7 @@ const getExternalChatList = fromId => {
...
@@ -9,7 +9,7 @@ const getExternalChatList = fromId => {
}
}
// 单聊 会话列表
// 单聊 会话列表
const
selectAloneChatList
=
params
=>
{
export
const
selectAloneChatList
=
params
=>
{
return
request
({
return
request
({
url
:
'/chat/msg/selectAloneChatList'
,
url
:
'/chat/msg/selectAloneChatList'
,
method
:
'get'
,
method
:
'get'
,
...
@@ -18,21 +18,21 @@ const selectAloneChatList = params => {
...
@@ -18,21 +18,21 @@ const selectAloneChatList = params => {
}
}
// 内部联系人列表
// 内部联系人列表
const
getInternalChatList
=
fromId
=>
{
export
const
getInternalChatList
=
fromId
=>
{
return
request
({
return
request
({
url
:
'/chat/msg/selectInternalChatList/'
+
fromId
,
url
:
'/chat/msg/selectInternalChatList/'
+
fromId
,
method
:
'get'
method
:
'get'
})
})
}
}
const
getGroupChatList
=
fromId
=>
{
export
const
getGroupChatList
=
fromId
=>
{
return
request
({
return
request
({
url
:
'/chat/msg/selectGroupChatList/'
+
fromId
,
url
:
'/chat/msg/selectGroupChatList/'
+
fromId
,
method
:
'get'
method
:
'get'
})
})
}
}
// const chatList = (params) => {
//
export
const chatList = (params) => {
// return request({
// return request({
// url: '/chat/msg/list',
// url: '/chat/msg/list',
// method: 'get',
// method: 'get',
...
@@ -40,6 +40,19 @@ const getGroupChatList = fromId => {
...
@@ -40,6 +40,19 @@ const getGroupChatList = fromId => {
// })
// })
// }
// }
export
const
indexTable
=
()
=>
{
return
request
({
url
:
'/wecom/page/getCorpBasicData'
,
method
:
'get'
})
}
export
const
indexEchart
=
()
=>
{
return
request
({
url
:
'/wecom/page/getCorpRealTimeData'
,
method
:
'get'
})
}
// 全文检索 会话列表
// 全文检索 会话列表
export
const
getChatList
=
params
=>
{
export
const
getChatList
=
params
=>
{
return
request
({
return
request
({
...
@@ -58,14 +71,3 @@ export const exportList = params => {
...
@@ -58,14 +71,3 @@ export const exportList = params => {
// responseType: 'blob'
// responseType: 'blob'
})
})
}
}
//
export
const
content
=
{
getExternalChatList
,
selectAloneChatList
,
getInternalChatList
,
getGroupChatList
,
// chatList,
getChatList
}
export
default
content
linkwe-ui/src/views/conversation/content/component/chatListClass.vue
View file @
e5fc15c
...
@@ -6,16 +6,8 @@
...
@@ -6,16 +6,8 @@
<span
class=
"fr download"
@
click=
"exportList()"
>
下载会话
</span>
<span
class=
"fr download"
@
click=
"exportList()"
>
下载会话
</span>
</div>
</div>
</div>
</div>
<el-tabs
<el-tabs
v-model=
"activeTab"
@
tab-click=
"v => opened.includes(v.name) || opened.push(v.name)"
>
v-model=
"activeTab"
<el-tab-pane
v-for=
"(item, index) of list"
:key=
"index"
:label=
"item.label"
:name=
"item.type"
>
@
tab-click=
"(v) => opened.includes(v.name) || opened.push(v.name)"
>
<el-tab-pane
v-for=
"(item, index) of list"
:key=
"index"
:label=
"item.label"
:name=
"item.type"
>
<chatListClassTab
<chatListClassTab
v-if=
"opened.includes(item.type)"
v-if=
"opened.includes(item.type)"
:queryChat=
"queryChat"
:queryChat=
"queryChat"
...
@@ -28,7 +20,7 @@
...
@@ -28,7 +20,7 @@
<
script
>
<
script
>
import
chatListClassTab
from
'./chatListClassTab.vue'
import
chatListClassTab
from
'./chatListClassTab.vue'
import
api
from
'@/api/conversation/content.js'
import
*
as
api
from
'@/api/conversation/content.js'
export
default
{
export
default
{
components
:
{
chatListClassTab
},
components
:
{
chatListClassTab
},
props
:
{
props
:
{
...
@@ -81,10 +73,12 @@ export default {
...
@@ -81,10 +73,12 @@ export default {
.
then
(()
=>
{
.
then
(()
=>
{
return
api
.
exportList
(
this
.
queryChat
)
return
api
.
exportList
(
this
.
queryChat
)
})
})
.
then
(
(
response
)
=>
{
.
then
(
response
=>
{
this
.
download
(
response
.
msg
)
this
.
download
(
response
.
msg
)
})
})
.
catch
(
function
()
{})
.
catch
(
function
(
err
)
{
console
.
log
(
err
)
})
}
}
}
}
}
}
...
...
linkwe-ui/src/views/conversation/content/component/chatListClassTab.vue
View file @
e5fc15c
...
@@ -101,7 +101,7 @@
...
@@ -101,7 +101,7 @@
<
script
>
<
script
>
import
chatList
from
'./chatList.vue'
import
chatList
from
'./chatList.vue'
import
api
from
'@/api/conversation/content.js'
import
*
as
api
from
'@/api/conversation/content.js'
import
Voice
from
'@/components/Voice'
import
Voice
from
'@/components/Voice'
export
default
{
export
default
{
name
:
''
,
name
:
''
,
...
...
linkwe-ui/src/views/conversation/content/customer.vue
View file @
e5fc15c
...
@@ -32,25 +32,15 @@
...
@@ -32,25 +32,15 @@
<span
style=
"line-height:40px"
>
{{
item
.
name
}}
</span>
<span
style=
"line-height:40px"
>
{{
item
.
name
}}
</span>
</el-col>
</el-col>
<el-col
:span=
"10"
class=
"ar"
>
<el-col
:span=
"10"
class=
"ar"
>
<span
<span
:style=
"
{ color: item.type === 1 ? '#4bde03' : '#f9a90b' }"
:style=
"
{ color: item.type === 1 ? '#4bde03' : '#f9a90b' }"
>
{{
{
1
:
'@微信'
,
2
:
'@企业微信'
}
[
item
.
type
]
}}
>
{{
{
1
:
'@微信'
,
2
:
'@企业微信'
}
[
item
.
type
]
}}
<
/span
>
<
/span
>
<
i
<
i
:
class
=
"
[
'el-icon-s-custom'
,
{
1
:
'man'
,
2
:
'woman'
}
[
item
.
gender
]]
"></i>
:
class
=
"
[
'el-icon-s-custom'
,
{
1
:
'man'
,
2
:
'woman'
}
[
item
.
gender
]
]
"
></i>
</el-col>
</el-col>
</el-row>
</el-row>
<div class="
ac
mt10
mb15
"
>
<div class="
ac
mt10
mb15
"
>
{{
{{
customerList
.
length
!=
customerTotal
?
'下拉加载更多'
:
'看到底了~'
}}
customerList
.
length
!=
customerTotal
?
'下拉加载更多'
:
'看到底了~'
}}
<
/div
>
<
/div
>
<
/template
>
<
/template
>
<
el
-
empty
v
-
else
:
image
-
size
=
"100"
><
/el-empty
>
<
el
-
empty
v
-
else
:
image
-
size
=
"100"
><
/el-empty
>
...
@@ -93,10 +83,7 @@
...
@@ -93,10 +83,7 @@
<
el
-
empty
v
-
else
:
image
-
size
=
"100"
description
=
"请选择客户"
><
/el-empty
>
<
el
-
empty
v
-
else
:
image
-
size
=
"100"
description
=
"请选择客户"
><
/el-empty
>
<
/el-col
>
<
/el-col
>
<
el
-
col
:
span
=
"12"
>
<
el
-
col
:
span
=
"12"
>
<
chatListClass
<
chatListClass
v
-
show
=
"queryChat.receiveName"
:
queryChat
=
"queryChat"
><
/chatListClass
>
v
-
show
=
"queryChat.receiveName"
:
queryChat
=
"queryChat"
><
/chatListClass
>
<
el
-
empty
<
el
-
empty
v
-
if
=
"!queryChat.receiveName"
v
-
if
=
"!queryChat.receiveName"
...
@@ -111,7 +98,7 @@
...
@@ -111,7 +98,7 @@
import
chatListClass
from
'./component/chatListClass.vue'
import
chatListClass
from
'./component/chatListClass.vue'
import
userList
from
'./component/userList.vue'
import
userList
from
'./component/userList.vue'
import
grouplist
from
'./component/groupList.vue'
import
grouplist
from
'./component/groupList.vue'
import
api
from
'@/api/conversation/content.js'
import
*
as
api
from
'@/api/conversation/content.js'
import
*
as
apiCustomer
from
'@/api/customer/index'
import
*
as
apiCustomer
from
'@/api/customer/index'
export
default
{
export
default
{
components
:
{
components
:
{
...
@@ -183,7 +170,7 @@ export default {
...
@@ -183,7 +170,7 @@ export default {
this
.
loading
=
false
this
.
loading
=
false
this
.
personList
=
data
this
.
personList
=
data
}
)
}
)
.
catch
(
(
err
)
=>
{
.
catch
(
err
=>
{
this
.
loading
=
false
this
.
loading
=
false
}
)
}
)
}
else
{
}
else
{
...
@@ -193,7 +180,7 @@ export default {
...
@@ -193,7 +180,7 @@ export default {
this
.
loading
=
false
this
.
loading
=
false
this
.
personList
=
data
this
.
personList
=
data
}
)
}
)
.
catch
(
(
err
)
=>
{
.
catch
(
err
=>
{
this
.
loading
=
false
this
.
loading
=
false
}
)
}
)
}
}
...
@@ -205,7 +192,7 @@ export default {
...
@@ -205,7 +192,7 @@ export default {
this
.
customerList
=
[]
this
.
customerList
=
[]
}
}
page
&&
(
this
.
customerQuery
.
pageNum
=
page
)
page
&&
(
this
.
customerQuery
.
pageNum
=
page
)
apiCustomer
.
getList
(
this
.
customerQuery
).
then
(
(
res
)
=>
{
apiCustomer
.
getList
(
this
.
customerQuery
).
then
(
res
=>
{
this
.
customerList
.
push
(...
res
.
rows
)
this
.
customerList
.
push
(...
res
.
rows
)
this
.
customerTotal
=
~~
res
.
total
this
.
customerTotal
=
~~
res
.
total
this
.
customerQuery
.
pageNum
++
this
.
customerQuery
.
pageNum
++
...
...
linkwe-ui/src/views/conversation/content/employee.vue
View file @
e5fc15c
...
@@ -34,10 +34,22 @@
...
@@ -34,10 +34,22 @@
<div
class=
"name pd15"
>
{{
talkName
}}
</div>
<div
class=
"name pd15"
>
{{
talkName
}}
</div>
<el-tabs
v-model=
"activeName"
@
tab-click=
"tabClick(true)"
>
<el-tabs
v-model=
"activeName"
@
tab-click=
"tabClick(true)"
>
<el-tab-pane
label=
"内部联系人"
name=
"0"
>
<el-tab-pane
label=
"内部联系人"
name=
"0"
>
<userList
v-if=
"activeName == 0"
:personList=
"personList"
:loading=
"loading"
@
chatFn=
"chatFn"
>
</userList>
<userList
v-if=
"activeName == 0"
:personList=
"personList"
:loading=
"loading"
@
chatFn=
"chatFn"
>
</userList>
</el-tab-pane>
</el-tab-pane>
<el-tab-pane
label=
"外部联系人"
name=
"1"
>
<el-tab-pane
label=
"外部联系人"
name=
"1"
>
<userList
v-if=
"activeName == 1"
:personList=
"personList"
:loading=
"loading"
@
chatFn=
"chatFn"
>
</userList>
<userList
v-if=
"activeName == 1"
:personList=
"personList"
:loading=
"loading"
@
chatFn=
"chatFn"
>
</userList>
</el-tab-pane>
</el-tab-pane>
<el-tab-pane
label=
"群聊"
name=
"2"
>
<el-tab-pane
label=
"群聊"
name=
"2"
>
<grouplist
<grouplist
...
@@ -57,7 +69,11 @@
...
@@ -57,7 +69,11 @@
<el-col
:span=
"12"
>
<el-col
:span=
"12"
>
<chatListClass
v-show=
"queryChat.receiveName"
:queryChat=
"queryChat"
></chatListClass>
<chatListClass
v-show=
"queryChat.receiveName"
:queryChat=
"queryChat"
></chatListClass>
<el-empty
v-if=
"!queryChat.receiveName"
description=
"请选择联系人"
:image-size=
"100"
></el-empty>
<el-empty
v-if=
"!queryChat.receiveName"
description=
"请选择联系人"
:image-size=
"100"
></el-empty>
</el-col>
</el-col>
</el-row>
</el-row>
</div>
</div>
...
@@ -67,7 +83,7 @@ import chatListClass from './component/chatListClass.vue'
...
@@ -67,7 +83,7 @@ import chatListClass from './component/chatListClass.vue'
import
userList
from
'./component/userList.vue'
import
userList
from
'./component/userList.vue'
import
grouplist
from
'./component/groupList.vue'
import
grouplist
from
'./component/groupList.vue'
import
*
as
apiOrg
from
'@/api/organization'
import
*
as
apiOrg
from
'@/api/organization'
import
api
from
'@/api/conversation/content.js'
import
*
as
api
from
'@/api/conversation/content.js'
export
default
{
export
default
{
components
:
{
components
:
{
...
@@ -141,7 +157,7 @@ export default {
...
@@ -141,7 +157,7 @@ export default {
this
.
loading
=
false
this
.
loading
=
false
this
.
personList
=
data
this
.
personList
=
data
})
})
.
catch
(
(
err
)
=>
{
.
catch
(
err
=>
{
this
.
loading
=
false
this
.
loading
=
false
})
})
}
else
if
(
this
.
activeName
==
1
)
{
}
else
if
(
this
.
activeName
==
1
)
{
...
@@ -151,7 +167,7 @@ export default {
...
@@ -151,7 +167,7 @@ export default {
this
.
loading
=
false
this
.
loading
=
false
this
.
personList
=
data
this
.
personList
=
data
})
})
.
catch
(
(
err
)
=>
{
.
catch
(
err
=>
{
this
.
loading
=
false
this
.
loading
=
false
})
})
}
else
{
}
else
{
...
@@ -161,7 +177,7 @@ export default {
...
@@ -161,7 +177,7 @@ export default {
this
.
loading
=
false
this
.
loading
=
false
this
.
personList
=
data
this
.
personList
=
data
})
})
.
catch
(
(
err
)
=>
{
.
catch
(
err
=>
{
this
.
loading
=
false
this
.
loading
=
false
})
})
}
}
...
@@ -196,7 +212,7 @@ export default {
...
@@ -196,7 +212,7 @@ export default {
// data.children.push(...rows)
// data.children.push(...rows)
let
arr
=
node
.
data
.
children
?
node
.
data
.
children
.
concat
(
rows
||
[])
:
rows
||
[]
let
arr
=
node
.
data
.
children
?
node
.
data
.
children
.
concat
(
rows
||
[])
:
rows
||
[]
arr
.
forEach
(
(
element
)
=>
{
arr
.
forEach
(
element
=>
{
element
.
isLeaf
=
!!
element
.
userId
element
.
isLeaf
=
!!
element
.
userId
})
})
resolve
(
arr
)
resolve
(
arr
)
...
...
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