Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
P
pica-admin-consultation
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
Close sidebar
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
jingqi.liu
pica-admin-consultation
提交
643377fe
提交
643377fe
编写于
12月 02, 2021
作者:
xiaoping.di
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
大盘修改
上级
7de96d4e
变更
6
隐藏空白字符变更
内嵌
并排
正在显示
6 个修改的文件
包含
903 行增加
和
776 行删除
+903
-776
workbench.js
src/api/workbench.js
+39
-13
index.js
src/components/common/consultationCard/index.js
+320
-275
index.scss
src/components/common/consultationCard/index.scss
+294
-291
index.vue
src/components/common/consultationCard/index.vue
+67
-36
socket.js
src/store/modules/socket.js
+5
-0
workbench-new.vue
src/views/IM/diagnosis-admin/workbench-new.vue
+178
-161
未找到文件。
src/api/workbench.js
浏览文件 @
643377fe
import
request
from
'mn-template/plugins/http'
;
import
request
from
'mn-template/plugins/http'
;
export
const
conditionUpdate
=
async
(
data
)
=>
{
export
const
conditionUpdate
=
async
(
data
)
=>
{
return
request
({
return
request
({
url
:
'/diagnose/socket/condition/update'
,
url
:
'/diagnose/socket/condition/update'
,
data
:
data
,
data
:
data
,
method
:
'post'
,
method
:
'post'
,
});
});
};
};
export
const
conditionNewList
=
async
(
data
)
=>
{
// 轮循 获取卡边正常信息和异常信息
return
request
({
export
const
conditionNewList
=
async
(
data
)
=>
{
url
:
'/diagnose/admin/diagnose/operator/newList'
,
return
request
({
params
:
data
,
url
:
'/diagnose/admin/diagnose/operator/newList'
,
method
:
'get'
,
data
:
data
,
});
method
:
'post'
,
};
});
\ No newline at end of file
};
// 诊断建议
export
const
doctorAdviceList
=
async
(
data
)
=>
{
return
request
({
url
:
`/diagnose/admin/diagnose/doctorAdvice/list/
${
data
.
diagnoseLogId
}
`
,
method
:
'get'
,
});
};
// 手动呼叫
export
const
manualCall
=
async
(
data
)
=>
{
return
request
({
url
:
'/diagnose/admin/diagnose/manual/call'
,
data
:
data
,
method
:
'post'
,
});
};
// 查询当前上级医生下排队的信息
export
const
waitPersonNum
=
async
(
doctorId
)
=>
{
return
request
({
url
:
`/admin/diagnose/queueList/
${
doctorId
}
`
,
method
:
'post'
,
});
};
src/components/common/consultationCard/index.js
浏览文件 @
643377fe
import
{
teamDetail
,
callDirect
}
from
'@/api/diagnosis'
;
import
{
import
{
teamDetail
,
waitPersonNum
,
callDirect
,
doctorAdviceList
,
doctorAdviceList
,
manualCall
,
manualCall
,
}
from
'@/api/workbench.js'
;
}
from
'@/api/diagnosis'
;
import
{
createNamespacedHelpers
}
from
'vuex'
;
import
{
createNamespacedHelpers
}
from
'vuex'
;
const
{
mapState
}
=
createNamespacedHelpers
(
'main'
);
const
{
mapState
}
=
createNamespacedHelpers
(
'main'
);
export
default
{
export
default
{
props
:
{
props
:
{
item
:
{
item
:
{
type
:
Object
,
type
:
Object
,
default
:
()
=>
{
default
:
()
=>
{
return
{};
return
{};
},
},
},
},
},
data
()
{
orderType
:
{
return
{
// 订单类型
callImg
:
require
(
'@/assets/image/workbench/call.png'
),
type
:
String
,
infocallImg
:
require
(
'@/assets/image/workbench/calling.png'
),
default
:
''
,
callouting
:
require
(
'@/assets/image/workbench/remindalready.png'
),
offline
:
require
(
'@/assets/image/workbench/offline.png'
),
manuacall
:
require
(
'@/assets/image/workbench/maulcall.png'
),
manuacallIng
:
require
(
'@/assets/image/workbench/calling.gif'
),
timer
:
null
,
isChat
:
false
,
isUserChat
:
false
,
isDoctorChat
:
false
,
isCall
:
false
,
isManuacall
:
false
,
isManuacallType
:
false
,
accId
:
''
,
mockData
:
[{},
{},
{}],
isShowWait
:
false
,
};
},
},
computed
:
{
key
:
{
...
mapState
({
// 订单类型
showChat
:
(
state
)
=>
state
.
showChat
,
type
:
String
,
showAdvice
:
(
state
)
=>
state
.
showAdvice
,
default
:
''
,
}),
},
doctorCallStatus
()
{
},
switch
(
this
.
item
.
doctorCallStatus
)
{
data
()
{
return
{
callImg
:
require
(
'@/assets/image/workbench/call.png'
),
infocallImg
:
require
(
'@/assets/image/workbench/calling.png'
),
callouting
:
require
(
'@/assets/image/workbench/remindalready.png'
),
offline
:
require
(
'@/assets/image/workbench/offline.png'
),
manuacall
:
require
(
'@/assets/image/workbench/maulcall.png'
),
manuacallIng
:
require
(
'@/assets/image/workbench/calling.gif'
),
timer
:
null
,
isChat
:
false
,
isUserChat
:
false
,
isDoctorChat
:
false
,
isCall
:
false
,
isManuacall
:
false
,
isManuacallType
:
false
,
accId
:
''
,
waitPersonList
:
[],
isShowWait
:
false
,
};
},
computed
:
{
...
mapState
({
showChat
:
(
state
)
=>
state
.
showChat
,
showAdvice
:
(
state
)
=>
state
.
showAdvice
,
}),
doctorCallStatus
()
{
switch
(
this
.
item
.
doctorCallStatus
)
{
case
1
:
case
1
:
return
'未拨打'
;
return
'未拨打'
;
case
2
:
case
2
:
...
@@ -52,10 +62,10 @@ import {
...
@@ -52,10 +62,10 @@ import {
return
'已拨打完成'
;
return
'已拨打完成'
;
default
:
default
:
return
''
;
return
''
;
}
}
},
},
userCallStatus
()
{
userCallStatus
()
{
switch
(
this
.
item
.
userCallStatus
)
{
switch
(
this
.
item
.
userCallStatus
)
{
case
1
:
case
1
:
return
'未拨打'
;
return
'未拨打'
;
case
2
:
case
2
:
...
@@ -66,10 +76,10 @@ import {
...
@@ -66,10 +76,10 @@ import {
return
'已拨打完成'
;
return
'已拨打完成'
;
default
:
default
:
return
''
;
return
''
;
}
}
},
},
diagnoseType
()
{
diagnoseType
()
{
switch
(
this
.
item
.
diagnoseType
)
{
switch
(
this
.
item
.
diagnoseType
)
{
case
1
:
case
1
:
return
'语音问诊'
;
return
'语音问诊'
;
case
2
:
case
2
:
...
@@ -78,10 +88,10 @@ import {
...
@@ -78,10 +88,10 @@ import {
return
'图文问诊'
;
return
'图文问诊'
;
default
:
default
:
return
''
;
return
''
;
}
}
},
},
diagnoseTypeIcon
()
{
diagnoseTypeIcon
()
{
switch
(
this
.
item
.
diagnoseType
)
{
switch
(
this
.
item
.
diagnoseType
)
{
case
1
:
case
1
:
return
'voice'
;
return
'voice'
;
case
2
:
case
2
:
...
@@ -90,247 +100,277 @@ import {
...
@@ -90,247 +100,277 @@ import {
return
'photo'
;
return
'photo'
;
default
:
default
:
return
'photo'
;
return
'photo'
;
}
}
},
},
appointBeginTime
()
{
appointBeginTime
()
{
if
(
this
.
item
.
appointBeginTime
)
{
return
new
Date
(
this
.
item
.
appointBeginTime
).
format
(
'hh:mm'
);
return
new
Date
(
this
.
item
.
appointBeginTime
).
format
(
'hh:mm'
);
},
}
else
{
appointEndTime
()
{
return
''
;
}
},
appointEndTime
()
{
if
(
this
.
item
.
appointEndTime
)
{
return
new
Date
(
this
.
item
.
appointEndTime
).
format
(
'hh:mm'
);
return
new
Date
(
this
.
item
.
appointEndTime
).
format
(
'hh:mm'
);
},
}
else
{
userCallTime
()
{
return
''
;
return
new
Date
(
this
.
item
.
userCallTime
).
format
(
'hh:mm'
);
}
},
// 助诊呼叫状态
userCallKfStatus
()
{
return
this
.
item
.
userCallKfStatus
;
},
// 接诊呼叫状态
doctorCallKfStatus
()
{
return
this
.
item
.
doctorCallKfStatus
;
},
// 接诊 在线状态
doctorTrtcEntryStatus
()
{
return
this
.
item
.
doctorTrtcEntryStatus
;
},
// 助诊 在线状态
userTrtcEntryStatus
()
{
return
this
.
item
.
userTrtcEntryStatus
;
},
pastUserCallTime
()
{
if
(
this
.
item
.
userCallTime
)
{
return
this
.
formatDateData
(
this
.
item
.
userCallTime
);
}
else
{
return
null
;
}
},
doctorCallTime
()
{
return
new
Date
(
this
.
item
.
doctorCallTime
).
format
(
'hh:mm'
);
},
pastDoctorCallTime
()
{
if
(
this
.
item
.
doctorCallTime
)
{
return
this
.
formatDateData
(
this
.
item
.
doctorCallTime
);
}
else
{
return
null
;
}
},
nowtime
()
{
return
new
Date
().
getTime
()
-
this
.
item
.
appointBeginTime
;
},
},
},
watch
:
{
userCallTime
()
{
item
(
newVal
,
oldVal
)
{
return
new
Date
(
this
.
item
.
userCallTime
).
format
(
'hh:mm'
);
console
.
log
(
newVal
,
oldVal
,
'newVal, oldVal'
);
if
(
newVal
!==
oldVal
)
{
if
(
newVal
.
doctorTrtcEntryStatus
==
2
)
{
this
.
isDoctorChat
=
false
;
}
if
(
newVal
.
userTrtcEntryStatus
==
2
)
{
this
.
isUserChat
=
false
;
}
if
(
newVal
.
doctorCallStatus
!==
oldVal
.
doctorCallStatus
)
{
this
.
isManuacall
=
false
;
}
if
(
newVal
.
userCallStatus
!==
oldVal
.
userCallStatus
)
{
this
.
isManuacallType
=
false
;
}
}
},
},
},
created
()
{},
// 助诊呼叫状态
mounted
()
{
userCallKfStatus
()
{
if
(
this
.
item
.
returnStatus
==
1
||
this
.
item
.
returnStatus
==
3
)
{
return
this
.
item
.
userCallKfStatus
;
const
nowData
=
new
Date
().
getTime
();
},
const
timeleft
=
this
.
item
.
appointBeginTime
-
nowData
;
// 接诊呼叫状态
if
(
timeleft
<
120000
&&
nowData
<
this
.
item
.
appointEndTime
)
{
doctorCallKfStatus
()
{
clearInterval
(
this
.
timer
);
return
this
.
item
.
doctorCallKfStatus
;
this
.
down
();
},
}
else
{
// 接诊 在线状态
this
.
isCall
=
true
;
doctorTrtcEntryStatus
()
{
}
return
this
.
item
.
doctorTrtcEntryStatus
;
},
// 助诊 在线状态
userTrtcEntryStatus
()
{
return
this
.
item
.
userTrtcEntryStatus
;
},
pastUserCallTime
()
{
if
(
this
.
item
.
userCallTime
)
{
return
this
.
formatDateData
(
this
.
item
.
userCallTime
);
}
else
{
return
null
;
}
},
doctorCallTime
()
{
return
new
Date
(
this
.
item
.
doctorCallTime
).
format
(
'hh:mm'
);
},
pastDoctorCallTime
()
{
if
(
this
.
item
.
doctorCallTime
)
{
return
this
.
formatDateData
(
this
.
item
.
doctorCallTime
);
}
else
{
return
null
;
}
}
},
},
methods
:
{
nowtime
()
{
manualDialing
(
type
)
{
return
new
Date
().
getTime
()
-
this
.
item
.
appointBeginTime
;
if
(
this
.
doctorCallKfStatus
===
1
)
{
},
return
;
},
watch
:
{
item
(
newVal
,
oldVal
)
{
console
.
log
(
newVal
,
'newValnewValnewVal'
);
console
.
log
(
newVal
,
oldVal
,
'newVal, oldVal'
);
if
(
newVal
!==
oldVal
)
{
if
(
newVal
.
doctorTrtcEntryStatus
==
2
)
{
this
.
isDoctorChat
=
false
;
}
}
this
.
$confirm
(
'确认要电话通知该医生吗?'
,
'提示'
,
{
if
(
newVal
.
userTrtcEntryStatus
==
2
)
{
confirmButtonText
:
'电话通知'
,
this
.
isUserChat
=
false
;
cancelButtonText
:
'取消'
,
type
:
'warning'
,
})
.
then
(()
=>
{
let
userMobilePhone
=
''
;
let
userId
=
''
;
let
doctorId
=
''
;
let
doctorMobilePhone
=
''
;
if
(
type
===
1
)
{
userMobilePhone
=
null
;
userId
=
null
;
doctorId
=
this
.
item
.
doctorId
;
doctorMobilePhone
=
this
.
item
.
doctorMobile
;
}
else
{
userMobilePhone
=
this
.
item
.
userMobile
;
userId
=
this
.
item
.
userId
;
doctorId
=
null
;
doctorMobilePhone
=
null
;
}
const
params
=
{
diagnoseId
:
this
.
item
.
diagnoseLogId
,
doctorId
:
doctorId
,
doctorMobilePhone
:
doctorMobilePhone
,
userId
:
userId
,
userMobilePhone
:
userMobilePhone
,
};
manualCall
(
params
).
then
((
res
)
=>
{
if
(
res
.
code
===
'000000'
)
{
if
(
type
===
1
)
{
this
.
isManuacall
=
true
;
}
else
{
this
.
isManuacallType
=
true
;
}
}
});
})
.
catch
(()
=>
{
this
.
$message
({
type
:
'info'
,
message
:
'取消拨打电话'
,
});
});
},
formatDateData
(
time
)
{
const
now_data
=
new
Date
().
getTime
();
const
my_time
=
now_data
-
time
;
const
hours
=
my_time
/
1000
/
60
/
60
;
const
hoursRound
=
Math
.
floor
(
hours
);
const
minutes
=
my_time
/
1000
/
60
-
60
*
hoursRound
;
const
minutesRound
=
Math
.
floor
(
minutes
);
const
seconds
=
(
my_time
/
1000
-
60
*
60
*
hoursRound
-
60
*
minutesRound
).
toFixed
(
0
);
if
(
hoursRound
>
0
&&
minutesRound
>
0
)
{
return
hoursRound
+
'小时'
+
minutesRound
+
'分'
+
seconds
+
'秒'
;
}
}
if
(
hoursRound
==
0
&&
minutesRound
>
0
)
{
if
(
newVal
.
doctorCallStatus
!==
oldVal
.
doctorCallStatus
)
{
return
minutesRound
+
'分'
;
this
.
isManuacall
=
false
;
}
}
if
(
hoursRound
==
0
&&
minutesRound
==
0
)
{
if
(
newVal
.
userCallStatus
!==
oldVal
.
userCallStatus
)
{
return
seconds
+
'秒'
;
this
.
isManuacallType
=
false
;
}
}
},
}
down
()
{
},
this
.
timer
=
setInterval
(()
=>
{
key
(
newVal
,
oldVal
)
{
const
nowData
=
new
Date
().
getTime
();
console
.
log
(
newVal
,
oldVal
);
},
const
timeleft
=
this
.
item
.
appointBeginTime
-
nowData
;
},
if
(
timeleft
<
120000
&&
nowData
<
this
.
item
.
appointEndTime
)
{
created
()
{},
this
.
isCall
=
true
;
mounted
()
{
clearInterval
(
this
.
timer
);
if
(
this
.
item
.
returnStatus
==
1
||
this
.
item
.
returnStatus
==
3
)
{
const
nowData
=
new
Date
().
getTime
();
const
timeleft
=
this
.
item
.
appointBeginTime
-
nowData
;
if
(
timeleft
<
120000
&&
nowData
<
this
.
item
.
appointEndTime
)
{
clearInterval
(
this
.
timer
);
this
.
down
();
}
else
{
this
.
isCall
=
true
;
}
}
},
methods
:
{
manualDialing
(
type
)
{
if
(
this
.
doctorCallKfStatus
===
1
)
{
return
;
}
this
.
$confirm
(
'确认要电话通知该医生吗?'
,
'提示'
,
{
confirmButtonText
:
'电话通知'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
,
})
.
then
(()
=>
{
let
userMobilePhone
=
''
;
let
userId
=
''
;
let
doctorId
=
''
;
let
doctorMobilePhone
=
''
;
if
(
type
===
1
)
{
userMobilePhone
=
null
;
userId
=
null
;
doctorId
=
this
.
item
.
doctorId
;
doctorMobilePhone
=
this
.
item
.
doctorMobile
;
}
else
{
userMobilePhone
=
this
.
item
.
userMobile
;
userId
=
this
.
item
.
userId
;
doctorId
=
null
;
doctorMobilePhone
=
null
;
}
}
},
1000
);
},
getInfo
(
id
)
{
return
teamDetail
({
tid
:
this
.
item
.
imTeamId
,
})
.
then
((
res
)
=>
{
if
(
res
.
code
==
'000000'
)
{
const
{
memberList
}
=
res
.
data
;
console
.
log
(
'---memberList'
,
memberList
);
if
(
memberList
)
{
const
accId
=
memberList
.
filter
((
val
)
=>
{
return
val
.
id
==
id
;
});
return
accId
[
0
].
accId
;
}
}
})
.
catch
(()
=>
{});
},
// 主动呼叫 roletype 1:助诊医生 2:接诊医生
drivingCall
(
id
,
roletype
)
{
if
(
roletype
==
1
&&
this
.
isUserChat
)
{
return
false
;
}
if
(
roletype
==
2
&&
this
.
isDoctorChat
)
{
return
false
;
}
this
.
getInfo
(
id
).
then
((
res
)
=>
{
const
params
=
{
const
params
=
{
imAccId
:
res
,
diagnoseId
:
this
.
item
.
diagnoseLogId
,
imTeamId
:
this
.
item
.
imTeamId
,
doctorId
:
doctorId
,
liveRoomId
:
this
.
item
.
roomId
,
doctorMobilePhone
:
doctorMobilePhone
,
userId
:
userId
,
userMobilePhone
:
userMobilePhone
,
};
};
callDirect
(
params
).
then
((
res
)
=>
{
manualCall
(
params
).
then
((
res
)
=>
{
if
(
res
.
code
===
'000000'
)
{
if
(
res
.
code
===
'000000'
)
{
if
(
roletype
==
1
)
{
if
(
type
=
==
1
)
{
this
.
is
UserChat
=
true
;
this
.
is
Manuacall
=
true
;
}
else
{
}
else
{
this
.
is
DoctorChat
=
true
;
this
.
is
ManuacallType
=
true
;
}
}
}
else
{
this
.
$message
({
message
:
res
.
message
,
type
:
'warning'
,
});
}
}
});
});
});
})
},
.
catch
(()
=>
{
openChat
()
{
if
(
this
.
showChat
)
{
this
.
$message
({
message
:
'不可同时进入多个诊室,请先退出已进入的诊室,再试。'
,
type
:
'warning'
,
duration
:
1000
,
});
return
false
;
}
const
i
=
this
.
item
;
this
.
$store
.
dispatch
(
'main/gotoInquiry'
,
i
);
},
openAdvice
()
{
if
(
this
.
showAdvice
)
{
this
.
$message
({
this
.
$message
({
message
:
'不可同时打开多个诊断建议,请先退出已打开的诊断建议,再试。'
,
type
:
'info'
,
type
:
'warning'
,
message
:
'取消拨打电话'
,
duration
:
1000
,
});
});
return
false
;
});
},
formatDateData
(
time
)
{
const
now_data
=
new
Date
().
getTime
();
const
my_time
=
now_data
-
time
;
const
hours
=
my_time
/
1000
/
60
/
60
;
const
hoursRound
=
Math
.
floor
(
hours
);
const
minutes
=
my_time
/
1000
/
60
-
60
*
hoursRound
;
const
minutesRound
=
Math
.
floor
(
minutes
);
const
seconds
=
(
my_time
/
1000
-
60
*
60
*
hoursRound
-
60
*
minutesRound
).
toFixed
(
0
);
if
(
hoursRound
>
0
&&
minutesRound
>
0
)
{
return
hoursRound
+
'小时'
+
minutesRound
+
'分'
+
seconds
+
'秒'
;
}
if
(
hoursRound
==
0
&&
minutesRound
>
0
)
{
return
minutesRound
+
'分'
;
}
if
(
hoursRound
==
0
&&
minutesRound
==
0
)
{
return
seconds
+
'秒'
;
}
},
down
()
{
this
.
timer
=
setInterval
(()
=>
{
const
nowData
=
new
Date
().
getTime
();
const
timeleft
=
this
.
item
.
appointBeginTime
-
nowData
;
if
(
timeleft
<
120000
&&
nowData
<
this
.
item
.
appointEndTime
)
{
this
.
isCall
=
true
;
clearInterval
(
this
.
timer
);
}
}
// const i = 11;
},
1000
);
doctorAdviceList
({
},
diagnoseLogId
:
this
.
item
.
diagnoseLogId
,
getInfo
(
id
)
{
return
teamDetail
({
tid
:
this
.
item
.
imTeamId
,
})
.
then
((
res
)
=>
{
if
(
res
.
code
==
'000000'
)
{
const
{
memberList
}
=
res
.
data
;
console
.
log
(
'---memberList'
,
memberList
);
if
(
memberList
)
{
const
accId
=
memberList
.
filter
((
val
)
=>
{
return
val
.
id
==
id
;
});
return
accId
[
0
].
accId
;
}
}
})
.
catch
(()
=>
{});
},
// 主动呼叫 roletype 1:助诊医生 2:接诊医生
drivingCall
(
id
,
roletype
)
{
if
(
roletype
==
1
&&
this
.
isUserChat
)
{
return
false
;
}
if
(
roletype
==
2
&&
this
.
isDoctorChat
)
{
return
false
;
}
this
.
getInfo
(
id
).
then
((
res
)
=>
{
const
params
=
{
imAccId
:
res
,
imTeamId
:
this
.
item
.
imTeamId
,
liveRoomId
:
this
.
item
.
roomId
,
};
callDirect
(
params
).
then
((
res
)
=>
{
if
(
res
.
code
===
'000000'
)
{
if
(
roletype
==
1
)
{
this
.
isUserChat
=
true
;
}
else
{
this
.
isDoctorChat
=
true
;
}
}
else
{
this
.
$message
({
message
:
res
.
message
,
type
:
'warning'
,
});
}
});
});
},
openChat
()
{
if
(
this
.
showChat
)
{
this
.
$message
({
message
:
'不可同时进入多个诊室,请先退出已进入的诊室,再试。'
,
type
:
'warning'
,
duration
:
1000
,
});
return
false
;
}
const
i
=
this
.
item
;
this
.
$store
.
dispatch
(
'main/gotoInquiry'
,
i
);
},
openAdvice
()
{
if
(
this
.
showAdvice
)
{
this
.
$message
({
message
:
'不可同时打开多个诊断建议,请先退出已打开的诊断建议,再试。'
,
type
:
'warning'
,
duration
:
1000
,
});
return
false
;
}
// const i = 11;
doctorAdviceList
({
diagnoseLogId
:
this
.
item
.
diagnoseLogId
,
})
.
then
((
res
)
=>
{
if
(
res
.
code
==
'000000'
)
{
this
.
$store
.
commit
(
'main/updateShowAdvice'
,
true
);
this
.
$store
.
commit
(
'main/updateCurrentAdvice'
,
res
.
data
);
}
else
{
this
.
$message
({
message
:
res
.
message
,
type
:
'warning'
,
duration
:
1000
,
});
}
})
})
.
catch
((
err
)
=>
{
console
.
log
(
err
);
});
},
waitPersonFun
()
{
if
(
!
this
.
isShowWait
)
{
console
.
log
(
this
.
item
.
doctorId
,
'this.item.doctorId'
);
waitPersonNum
(
this
.
item
.
doctorId
)
.
then
((
res
)
=>
{
.
then
((
res
)
=>
{
if
(
res
.
code
==
'000000'
)
{
if
(
res
.
code
===
'000000'
)
{
this
.
$store
.
commit
(
'main/updateShowAdvice'
,
true
);
this
.
waitPersonList
=
res
.
data
||
[];
this
.
$store
.
commit
(
'main/updateCurrentAdvice'
,
res
.
data
);
}
else
{
}
else
{
this
.
$message
({
this
.
$message
({
message
:
res
.
message
,
message
:
res
.
message
,
...
@@ -338,13 +378,18 @@ import {
...
@@ -338,13 +378,18 @@ import {
duration
:
1000
,
duration
:
1000
,
});
});
}
}
this
.
isShowWait
=
!
this
.
isShowWait
;
})
})
.
catch
((
err
)
=>
{
.
catch
((
err
)
=>
{
console
.
log
(
err
);
console
.
log
(
err
);
this
.
isShowWait
=
!
this
.
isShowWait
;
this
.
$message
({
message
:
'服务查询失败'
,
type
:
'warning'
,
duration
:
1000
,
});
});
});
},
}
waitPersonFun
()
{
this
.
isShowWait
=
!
this
.
isShowWait
;
},
},
},
};
},
\ No newline at end of file
};
src/components/common/consultationCard/index.scss
浏览文件 @
643377fe
.inquiry-wrap
{
.inquiry-wrap
{
box-sizing
:
border-box
;
box-sizing
:
border-box
;
margin-bottom
:
10px
;
margin-bottom
:
10px
;
padding
:
20px
;
padding
:
20px
;
background
:
#ffffff
;
background
:
#ffffff
;
border-radius
:
18px
;
border-radius
:
18px
;
user-select
:
none
;
user-select
:
none
;
position
:
relative
;
position
:
relative
;
.line
{
.line
{
display
:
flex
;
display
:
flex
;
justify-content
:
space-between
;
justify-content
:
space-between
;
font-size
:
14px
;
font-size
:
14px
;
color
:
#999999
;
color
:
#999999
;
.left
{
.left
{
.time
{
.time
{
color
:
#ff5e57
;
color
:
#ff5e57
;
font-size
:
18px
;
margin-top
:
3px
;
}
}
.right
{
margin-left
:
23px
;
.orderno
{
display
:
flex
;
align-items
:
center
;
margin-top
:
3px
;
.num
{
font-size
:
18px
;
font-size
:
18px
;
margin-top
:
3px
;
color
:
#02120f
;
}
}
}
.copy
{
.right
{
font-size
:
12px
;
margin-left
:
23px
;
margin-left
:
16px
;
.orderno
{
padding
:
0
5px
;
display
:
flex
;
border
:
1px
solid
#d9d9d9
;
align-items
:
center
;
border-radius
:
15px
;
margin-top
:
3px
;
color
:
#212121
;
.num
{
font-size
:
18px
;
color
:
#02120f
;
}
.copy
{
font-size
:
12px
;
margin-left
:
16px
;
padding
:
0
5px
;
border
:
1px
solid
#d9d9d9
;
border-radius
:
15px
;
color
:
#212121
;
}
}
}
.grey
{
}
color
:
#6a7990
;
.grey
{
color
:
#6a7990
;
}
.org
{
color
:
#ff5e57
;
}
}
.superior-doctor
{
width
:
49%
;
display
:
flex
;
justify-content
:
flex-start
;
align-items
:
flex-start
;
.inquiry-user-img
{
display
:
flex
;
flex-direction
:
column
;
justify-content
:
center
;
position
:
relative
;
width
:
40px
;
height
:
40px
;
.offline
{
position
:
absolute
;
left
:
-4px
;
top
:
-4px
;
z-index
:
10
;
}
}
.org
{
.avatar
{
color
:
#ff5e57
;
position
:
absolute
;
left
:
0
;
top
:
0
;
background
:
#dddddd
;
border-radius
:
36px
;
display
:
flex
;
flex-direction
:
column
;
justify-content
:
center
;
}
}
}
}
.superior-doctor
{
.inquiry-user-info
{
width
:
49%
;
font-size
:
14px
;
display
:
flex
;
margin-left
:
6px
;
justify-content
:flex-start
;
.info-name-wrap
{
align-items
:
flex-start
;
display
:
flex
;
.inquiry-user-img
{
align-items
:
center
;
display
:
flex
;
flex-direction
:
column
;
justify-content
:
center
;
position
:
relative
;
width
:
40px
;
height
:
40px
;
.offline
{
position
:
absolute
;
left
:
-4px
;
top
:
-4px
;
z-index
:
10
;
}
.avatar
{
position
:
absolute
;
left
:
0
;
top
:
0
;
background
:
#dddddd
;
border-radius
:
36px
;
display
:
flex
;
flex-direction
:
column
;
justify-content
:
center
;
}
}
}
.inquiry-user-info
{
font-size
:
14px
;
margin-left
:
6px
;
.info-name-wrap
{
display
:
flex
;
align-items
:
center
;
}
.info-name
{
.info-name
{
display
:
inline-block
;
display
:
inline-block
;
max-width
:
85px
;
max-width
:
85px
;
overflow
:
hidden
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
text-overflow
:
ellipsis
;
white-space
:
nowrap
;
white-space
:
nowrap
;
font-size
:
18px
;
font-size
:
18px
;
color
:
#02120f
;
color
:
#02120f
;
font-weight
:
bold
;
font-weight
:
bold
;
}
}
.info-container
{
.info-container
{
align-items
:
center
;
flex-direction
:
row
;
height
:
auto
;
line-height
:
30px
;
line-height
:
25px
;
.info-phone
{
color
:
#6a7990
;
font-size
:
16px
;
}
.info-call-time
{
color
:
#ff5e57
;
}
.info-calling
{
width
:
15px
;
height
:
25px
;
display
:
flex
;
justify-content
:
center
;
align-items
:
center
;
align-items
:
center
;
flex-direction
:
row
;
img
{
height
:
auto
;
width
:
15px
;
line-height
:
30px
;
height
:
15px
;
line-height
:
25px
;
.info-phone
{
color
:
#6a7990
;
font-size
:
16px
;
}
.info-call-time
{
color
:
#ff5e57
;
}
.info-calling
{
width
:
15px
;
height
:
25px
;
display
:
flex
;
justify-content
:
center
;
align-items
:
center
;
img
{
width
:
15px
;
height
:
15px
;
}
}
}
}
}
}
}
.manual-call-status
{
}
.manual-call-status
{
display
:
flex
;
display
:
flex
;
.manual-dialing
{
.manual-dialing
{
margin-right
:
5px
;
margin-right
:
5px
;
cursor
:
pointer
;
cursor
:
pointer
;
img
{
img
{
width
:
27px
;
width
:
27px
;
height
:
48px
;
height
:
48px
;
}
}
}
}
.call-status
{
.call-status
{
// width: 45px;
// width: 45px;
// height: 46px;
// height: 46px;
img
{
img
{
cursor
:
pointer
;
cursor
:
pointer
;
width
:
27px
;
width
:
27px
;
height
:
48px
;
height
:
48px
;
}
}
}
}
}
}
}
.basic-doctor
{
}
width
:
49%
;
.basic-doctor
{
display
:flex
;
width
:
49%
;
justify-content
:flex-start
;
display
:
flex
;
.basic-user-img
,
.basic-user-info
{
justify-content
:
flex-start
;
padding-right
:
6px
;
.basic-user-img
,
.info-name-wrap
{
.basic-user-info
{
display
:fle
x
;
padding-right
:
6p
x
;
align-items
:center
;
.info-name-wrap
{
justify-content
:space-between
;
display
:
flex
;
.info-name
{
align-items
:
center
;
max-width
:
85px
;
justify-content
:
space-between
;
overflow
:
hidden
;
.info-name
{
text-overflow
:
ellipsis
;
max-width
:
85px
;
white-space
:
nowrap
;
overflow
:
hidden
;
font-size
:
18px
;
text-overflow
:
ellipsis
;
color
:
#02120f
;
white-space
:
nowrap
;
font-weight
:
bold
;
font-size
:
18px
;
}
color
:
#02120f
;
}
font-weight
:
bold
;
.info-container
{
}
align-items
:
center
;
}
flex-direction
:
row
;
.info-container
{
height
:
auto
;
align-items
:
center
;
line-height
:
30px
;
flex-direction
:
row
;
line-height
:
25px
;
height
:
auto
;
.info-phone
{
line-height
:
30px
;
color
:
#666
;
line-height
:
25px
;
font-size
:
16px
;
.info-phone
{
}
color
:
#666
;
.info-call-time
{
font-size
:
16px
;
color
:
#ff5e57
;
}
}
.info-call-time
{
.info-calling
{
color
:
#ff5e57
;
width
:
15px
;
}
height
:
25px
;
.info-calling
{
display
:
fle
x
;
width
:
15p
x
;
justify-content
:
center
;
height
:
25px
;
align-items
:
center
;
display
:
flex
;
img
{
justify-content
:
center
;
width
:
15px
;
align-items
:
center
;
height
:
15px
;
img
{
}
width
:
15px
;
}
height
:
15px
;
}
}
}
}
}
}
}
.no-info
{
}
.no-info
{
}
width
:
100%
;
.inquiry-user-status
{
height
:
auto
;
width
:
100%
;
color
:
#ff5e57
;
padding
:
4px
0
;
}
height
:
auto
;
.inquiry-user-status
{
overflow
:
hidden
;
width
:
100%
;
.status-cll-user-answer
{
padding
:
4px
0
;
background
:
rgba
(
255
,
94
,
87
,
0
.07
);
height
:
auto
;
border-radius
:
10px
;
overflow
:
hidden
;
border
:
1px
solid
rgba
(
255
,
94
,
87
,
0
.15
);
.status-cll-user-answer
{
padding
:
0
4px
;
background
:
rgba
(
255
,
94
,
87
,
0
.07
);
height
:
20px
;
border-radius
:
10px
;
font-size
:
14px
;
border
:
1px
solid
rgba
(
255
,
94
,
87
,
0
.15
);
font-family
:
PingFangSC-Regular
,
PingFang
SC
;
padding
:
0
4px
;
font-weight
:
400
;
height
:
20px
;
color
:
#ff5e57
;
font-size
:
14px
;
line-height
:
20px
;
font-family
:
PingFangSC-Regular
,
PingFang
SC
;
margin-right
:
6px
;
font-weight
:
400
;
}
color
:
#ff5e57
;
.status-cll-user-finish
{
line-height
:
20px
;
background
:
rgba
(
0
,
189
,
165
,
0
.07
);
margin-right
:
6px
;
border-radius
:
10px
;
border
:
1px
solid
rgba
(
0
,
189
,
165
,
0
.17
);
padding
:
0
4px
;
height
:
20px
;
font-size
:
14px
;
font-family
:
PingFangSC-Regular
,
PingFang
SC
;
font-weight
:
400
;
color
:
#0d9078
;
line-height
:
20px
;
margin-right
:
6px
;
}
}
}
.line-btn
{
.status-cll-user-finish
{
cursor
:
pointer
;
background
:
rgba
(
0
,
189
,
165
,
0
.07
);
position
:
relative
;
border-radius
:
10px
;
width
:
45%
;
border
:
1px
solid
rgba
(
0
,
189
,
165
,
0
.17
);
height
:
35px
;
padding
:
0
4px
;
background
:
rgba
(
68
,
146
,
132
,
0
.09
);
height
:
20px
;
border-radius
:
23px
;
text-align
:
center
;
line-height
:
35px
;
color
:
#0d9078
;
font-size
:
14px
;
font-size
:
14px
;
font-weight
:
bold
;
font-family
:
PingFangSC-Regular
,
PingFang
SC
;
.line-btn-tap
{
font-weight
:
400
;
position
:
absolute
;
color
:
#0d9078
;
top
:
-10px
;
line-height
:
20px
;
right
:
20px
;
margin-right
:
6px
;
width
:
48px
;
height
:
20px
;
background
:
#0d9078
;
border-radius
:
7px
7px
7px
0px
;
font-size
:
14px
;
color
:
#ffffff
;
line-height
:
20px
;
}
span
{
font-weight
:
bold
;
}
}
}
.line-btn-enter
{
}
.line-btn
{
cursor
:
pointer
;
position
:
relative
;
width
:
45%
;
height
:
35px
;
background
:
rgba
(
68
,
146
,
132
,
0
.09
);
border-radius
:
23px
;
text-align
:
center
;
line-height
:
35px
;
color
:
#0d9078
;
font-size
:
14px
;
font-weight
:
bold
;
.line-btn-tap
{
position
:
absolute
;
top
:
-10px
;
right
:
20px
;
width
:
48px
;
height
:
20px
;
background
:
#0d9078
;
background
:
#0d9078
;
color
:
#fff
;
border-radius
:
7px
7px
7px
0px
;
.call-box
{
font-size
:
14px
;
display
:
flex
;
color
:
#ffffff
;
align-items
:
center
;
line-height
:
20px
;
justify-content
:
center
;
text-align
:
center
;
img
{
margin-right
:
14px
;
}
}
}
.isManuacall
{
background
:
#ff5e57
;
}
}
.noIsCall
{
span
{
background
:
#0d9078
;
font-weight
:
bold
;
}
}
}
}
.mt30
{
.line-btn-enter
{
margin-top
:
30px
;
background
:
#0d9078
;
color
:
#fff
;
.call-box
{
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
text-align
:
center
;
img
{
margin-right
:
14px
;
}
}
}
}
.line-second
{
.isManuacall
{
margin-top
:
13px
;
background
:
#ff5e57
;
justify-content
:
flex-start
;
align-items
:
center
;
}
}
.
mt20
{
.
noIsCall
{
margin-top
:
20px
;
background
:
#0d9078
;
}
}
.line-position
{
}
position
:
absolute
;
.mt30
{
top
:
96%
;
margin-top
:
30px
;
left
:
0
;
}
width
:
100%
;
.line-second
{
height
:
auto
;
margin-top
:
13px
;
background
:
#fff
;
justify-content
:
flex-start
;
.wait
{
align-items
:
center
;
}
.mt20
{
margin-top
:
20px
;
}
.line-position
{
position
:
absolute
;
top
:
96%
;
left
:
0
;
width
:
100%
;
height
:
auto
;
background
:
#fff
;
.wait
{
display
:
flex
;
margin
:
0px
20px
;
font-size
:
14px
;
justify-content
:
space-between
;
border-bottom
:
1px
solid
#e9e9e9
;
.wait-info
{
display
:
flex
;
display
:
flex
;
margin
:
0px
20px
;
height
:
40px
;
font-size
:
14px
;
align-items
:
center
;
justify-content
:
space-between
;
.header
{
border-bottom
:
1px
solid
#e9e9e9
;
width
:
20px
;
.wait-info
{
height
:
20px
;
display
:
flex
;
img
{
height
:
40px
;
width
:
100%
;
align-items
:
center
;
height
:
auto
;
.header
{
width
:
20px
;
height
:
20px
;
img
{
width
:
100%
;
height
:
auto
;
}
}
.name
{
color
:
#02120f
;
padding-left
:
5px
;
line-height
:
16px
;
}
.connect
{
color
:
#ff5e57
;
margin-left
:
5px
;
}
.order
{
color
:
#999999
;
span
{
color
:
#212121
;
}
}
}
}
}
&
:last-of-type
{
.name
{
border-bottom
:
none
;
color
:
#02120f
;
padding-left
:
5px
;
line-height
:
16px
;
}
.connect
{
color
:
#ff5e57
;
margin-left
:
5px
;
}
.order
{
color
:
#999999
;
span
{
color
:
#212121
;
}
}
}
}
}
&
:last-of-type
{
border-bottom
:
none
;
}
}
}
.wait-person
{
}
width
:
300px
;
.wait-person
{
height
:
auto
;
width
:
300px
;
display
:
flex
;
height
:
auto
;
}
display
:
flex
;
}
}
\ No newline at end of file
}
src/components/common/consultationCard/index.vue
浏览文件 @
643377fe
<
template
>
<
template
>
<div
class=
"inquiry-wrap"
>
<div
class=
"inquiry-wrap"
>
<div
class=
"line"
>
<div
class=
"line"
>
<!--上级医生头信息 -->
<div
class=
"superior-doctor"
>
<div
class=
"superior-doctor"
>
<div
class=
"inquiry-user-img"
>
<div
class=
"inquiry-user-img"
>
<div
<div
...
@@ -31,19 +32,8 @@
...
@@ -31,19 +32,8 @@
<li
class=
"info-phone"
>
<li
class=
"info-phone"
>
{{
item
.
doctorMobile
}}
{{
item
.
doctorMobile
}}
</li>
</li>
<li
v-if=
"item.doctorCallTime"
class=
"info-call-time"
>
{{
pastDoctorCallTime
}}
前呼叫
</li>
<li
v-if=
"doctorCallKfStatus == 1"
class=
"info-calling"
>
正在呼叫
</li>
<li
class=
"inquiry-user-status"
>
<li
class=
"inquiry-user-status"
>
<!-- 只有-->
<span
<span
:class=
"
:class=
"
doctorCallStatus === '已拨打完成'
doctorCallStatus === '已拨打完成'
...
@@ -51,12 +41,21 @@
...
@@ -51,12 +41,21 @@
: 'status-cll-user-answer'
: 'status-cll-user-answer'
"
"
>
{{
doctorCallStatus
}}
</span>
>
{{
doctorCallStatus
}}
</span>
<span
v-if=
"doctorCallKfStatus == 1"
class=
"status-cll-user-answer"
>
正在呼叫
</span>
<span
v-else
class=
"status-cll-user-answer"
>
未呼叫
</span>
</li>
</li>
</ul>
</ul>
</div>
</div>
</div>
</div>
<!-- 助诊医生 -->
<!-- 助诊医生
头信息
-->
<div
<div
v-if=
"item.userId"
class=
"basic-doctor"
class=
"basic-doctor"
>
>
<ul
class=
"basic-user-img"
>
<ul
class=
"basic-user-img"
>
...
@@ -88,20 +87,11 @@
...
@@ -88,20 +87,11 @@
<div
class=
"info-phone"
>
<div
class=
"info-phone"
>
{{
item
.
userMobile
}}
{{
item
.
userMobile
}}
</div>
</div>
<div
v-if=
"item.userCallTime"
class=
"info-call-time"
>
{{
pastUserCallTime
}}
前呼叫
</div>
<div
<div
v-if=
"userCallKfStatus == 1"
v-if=
"userCallKfStatus == 1"
class=
"info-calling"
class=
"info-calling"
>
>
<img
呼叫中
:src=
"infocallImg"
alt=
""
>
</div>
</div>
</li>
</li>
<li
class=
"inquiry-user-status"
>
<li
class=
"inquiry-user-status"
>
...
@@ -115,36 +105,72 @@
...
@@ -115,36 +105,72 @@
</li>
</li>
</ul>
</ul>
</div>
</div>
<!-- 未开始接诊 或停止接诊-->
<!-- 未开始接诊 或停止接诊-->
<div
class=
"no-info"
/>
<div
v-else
class=
"no-info"
>
<div
v-if=
"item.acceptStatus == 4"
class=
"doctor-late"
>
未开始接诊
</div>
<div
v-if=
"item.acceptStatus == 1"
class=
"doctor-stop"
>
暂停接诊
</div>
</div>
</div>
</div>
<!-- 预约时间,复制单号 -->
<div
class=
"line line-second"
>
<div
class=
"line line-second"
>
<div
class=
"left"
>
<div
class=
"left"
>
<div>
预约时间
</div>
<div>
预约时间
</div>
<div
class=
"time"
>
<div
v-if=
"appointBeginTime && appointEndTime"
class=
"time"
>
<span>
{{
appointBeginTime
}}
</span>
-
<span>
{{
appointBeginTime
}}
</span>
-
<span>
{{
appointEndTime
}}
</span>
<span>
{{
appointEndTime
}}
</span>
</div>
</div>
<div
v-else
class=
"time"
>
无
</div>
</div>
</div>
<div
class=
"right"
>
<div
class=
"right"
>
<div>
问诊单号
</div>
<div>
问诊单号
</div>
<ul
class=
"orderno"
>
<ul
class=
"orderno"
>
<li
class=
"num"
>
<li
class=
"num"
>
{{
item
.
diagnoseLogId
}}
{{
item
.
diagnoseLogId
||
'空'
}}
</li>
</li>
<li
class=
"copy"
>
<li
v-if=
"item.diagnoseLogId"
class=
"copy"
@
click=
"copyDiagnoseLogId"
>
复制
复制
</li>
</li>
</ul>
</ul>
</div>
</div>
</div>
</div>
<!-- 当前排队 -->
<div
class=
"line mt30 line-last"
>
<div
class=
"line mt30 line-last"
>
<div
<div
class=
"line-btn"
class=
"line-btn"
@
click=
"waitPersonFun"
@
click=
"waitPersonFun"
>
>
<div>
当前排队5人
<i
class=
"el-icon-arrow-down el-icon--right"
/></div>
<div>
当前排队
{{
item
.
queueCount
||
'0'
}}
人
<i
class=
"el-icon-arrow-down el-icon--right"
/>
</div>
</div>
</div>
<div
<div
class=
"line-btn line-btn-enter"
class=
"line-btn line-btn-enter"
...
@@ -175,12 +201,14 @@
...
@@ -175,12 +201,14 @@
</div>
</div>
</div>
</div>
</div>
</div>
<!-- 排队详细 -->
<div
<div
v-if=
"isShowWait"
v-if=
"isShowWait"
class=
"line-position"
class=
"line-position"
>
>
<ul
<ul
v-for=
"(
ele, index) in mockData
"
v-for=
"(
item, index) in waitPersonList
"
:key=
"index"
:key=
"index"
class=
"wait"
class=
"wait"
>
>
...
@@ -188,19 +216,22 @@
...
@@ -188,19 +216,22 @@
<div
class=
"header"
>
<div
class=
"header"
>
<img
<img
:src=
"item.userImageUrl"
:src=
"item.userImageUrl"
alt=
""
alt=
"
headImg
"
>
>
</div>
</div>
<div
class=
"name"
>
<div
class=
"name"
>
name
{{
item
.
userName
}}
</div>
</div>
<div
class=
"connect"
>
<div
连接失败 2次
v-if=
"item.failCount"
class=
"connect"
>
连接失败
{{
item
.
failCount
}}
次
</div>
</div>
</li>
</li>
<li
class=
"wait-info"
>
<li
class=
"wait-info"
>
<div
class=
"order"
>
<div
class=
"order"
>
问诊单号
<span>
877654
</span>
问诊单号
<span>
{{
item
.
diagnoseLogId
||
'空'
}}
</span>
</div>
</div>
</li>
</li>
</ul>
</ul>
...
@@ -212,5 +243,5 @@
...
@@ -212,5 +243,5 @@
export
default
index
;
export
default
index
;
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
@import
"index"
;
@import
'index'
;
</
style
>
</
style
>
src/store/modules/socket.js
浏览文件 @
643377fe
...
@@ -55,6 +55,11 @@ const socket = {
...
@@ -55,6 +55,11 @@ const socket = {
}
}
});
});
socketClient
.
on
(
'diagnose_call_push_event'
,
(
socket
)
=>
{
socketClient
.
on
(
'diagnose_call_push_event'
,
(
socket
)
=>
{
console
.
log
(
socket
,
'socketsocket'
,
window
.
_VM
.
$store
.
state
.
main
.
soketQuest
);
const
l
=
window
.
_VM
.
$store
.
state
.
main
.
noticeList
;
const
l
=
window
.
_VM
.
$store
.
state
.
main
.
noticeList
;
if
(
l
.
length
>=
5
)
{
if
(
l
.
length
>=
5
)
{
l
.
shift
();
l
.
shift
();
...
...
src/views/IM/diagnosis-admin/workbench-new.vue
浏览文件 @
643377fe
...
@@ -5,18 +5,6 @@
...
@@ -5,18 +5,6 @@
我的工作台
我的工作台
</div>
</div>
<!-- 时间 -->
<!-- 时间 -->
<div
class=
"search-box"
>
<div
class=
"search-item"
>
<el-date-picker
v-model=
"searchParam.dateTime"
type=
"date"
size=
"small"
clear-icon=
"el-input-icon"
:clearable=
"false"
@
change=
"changeDatetime"
/>
</div>
</div>
<!-- tab栏 -->
<!-- tab栏 -->
<el-radio-group
<el-radio-group
v-model=
"tabPositionValue"
v-model=
"tabPositionValue"
...
@@ -25,8 +13,8 @@
...
@@ -25,8 +13,8 @@
>
>
<el-radio-button
<el-radio-button
v-for=
"(item, index) in currentCalListNew"
v-for=
"(item, index) in currentCalListNew"
:key=
"'
for
' + index"
:key=
"'
tab
' + index"
:label=
"item.
name
"
:label=
"item.
id
"
>
>
{{
item
.
name
}}
{{
item
.
name
}}
</el-radio-button>
</el-radio-button>
...
@@ -34,11 +22,11 @@
...
@@ -34,11 +22,11 @@
</div>
</div>
<div
class=
"workbench-content"
>
<div
class=
"workbench-content"
>
<div
<div
v-if=
"currentDiagList"
v-if=
"currentDiagList
.length
"
class=
"workbench-li-c"
class=
"workbench-li-c"
>
>
<div
<div
v-if=
"tabPositionValue == '
全部订单
'"
v-if=
"tabPositionValue == '
3
'"
class=
"grid-c"
class=
"grid-c"
>
>
<el-checkbox-group
<el-checkbox-group
...
@@ -66,10 +54,9 @@
...
@@ -66,10 +54,9 @@
class=
"workbench-li-c"
class=
"workbench-li-c"
>
>
<div
class=
"workbench-title"
>
<div
class=
"workbench-title"
>
<department
@
select-department=
"selectDepartment"
/>
<div
class=
"searh-input"
>
<div
class=
"searh-input"
>
<el-input
<el-input
v-model=
"
searchValu
e"
v-model=
"
orderOrNam
e"
placeholder=
"输入问诊单号/医生姓名"
placeholder=
"输入问诊单号/医生姓名"
class=
"input-with-select"
class=
"input-with-select"
@
change=
"getSerachValue"
@
change=
"getSerachValue"
...
@@ -77,25 +64,32 @@
...
@@ -77,25 +64,32 @@
<el-button
<el-button
slot=
"append"
slot=
"append"
class=
"search-botton"
class=
"search-botton"
@
click=
"getSe
r
Value"
@
click=
"getSe
arch
Value"
>
>
搜索
搜索
</el-button>
</el-button>
</el-input>
</el-input>
</div>
</div>
</div>
</div>
<!-- 1111 -->
<!-- 问诊状态内容 -->
<div
class=
"grid-c"
>
<div
v-if=
"isShowCardData"
class=
"grid-c"
>
<div
<div
v-for=
"(item, index) in currentDiagList"
v-for=
"(item, index) in currentDiagList"
:key=
"index"
:key=
"index"
class=
"workbench-li"
class=
"workbench-li"
>
>
<consultation-card
:item=
"item"
/>
{{
item
.
diagnoseLogId
}}
<!-- key 动态随机无意义 促发组件数据更新 -->
<consultation-card
:key=
"item.definitionRandom"
:item=
"item"
:order-type=
"tabPositionValue"
/>
</div>
</div>
</div>
</div>
<!-- 1111 -->
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -120,42 +114,29 @@
...
@@ -120,42 +114,29 @@
const
{
mapState
}
=
createNamespacedHelpers
(
'main'
);
const
{
mapState
}
=
createNamespacedHelpers
(
'main'
);
import
storejs
from
'storejs'
;
import
storejs
from
'storejs'
;
import
consultationCard
from
'@/components/common/consultationCard/index.vue'
;
import
consultationCard
from
'@/components/common/consultationCard/index.vue'
;
import
department
from
'@/components/common/department.vue'
;
import
{
conditionNewList
}
from
'@/api/workbench'
;
import
{
conditionUpdate
,
conditionNewList
}
from
'@/api/workbench'
;
export
default
{
export
default
{
components
:
{
components
:
{
consultationCard
,
consultationCard
,
department
,
},
},
data
()
{
data
()
{
const
s
=
storejs
.
get
(
'soketQuest'
);
const
t
=
s
?
s
.
returnStatus
:
1
;
const
d
=
s
?
s
.
dateTime
:
new
Date
().
format
(
'yyyy-MM-dd'
);
const
id
=
s
&&
s
.
operateUserId
?
s
.
operateUserId
:
this
.
isSuperAdmin
.
userID
;
return
{
return
{
departmentId
:
''
,
tabPosition
:
t
,
showChat
:
true
,
showChat
:
true
,
totalRows
:
0
,
isShowCardData
:
false
,
loading
:
false
,
loading
:
false
,
searchParam
:
{
dateTime
:
d
,
checkvalue
:
''
,
// 模拟值后去
operateUserId
:
id
,
returnStatus
:
1
,
pageSize
:
6
,
pageNo
:
1
,
},
currentCalListNew
:
[
currentCalListNew
:
[
{
{
id
:
1
,
id
:
3
,
name
:
'全部订单'
,
name
:
'全部订单'
,
},
},
{
{
id
:
1
,
id
:
1
,
name
:
'我的待处理'
,
name
:
'我的待处理'
,
},
},
{
id
:
2
,
name
:
'无需处理'
,
},
],
],
cityOptions
:
[
cityOptions
:
[
{
{
...
@@ -192,150 +173,184 @@
...
@@ -192,150 +173,184 @@
},
},
],
],
checkedValues
:
[],
checkedValues
:
[],
tabPositionValue
:
'全部订单'
,
tabPositionValue
:
'3'
,
searchValue
:
''
,
orderOrName
:
''
,
userInfo
:
null
,
userInfo
:
null
,
timer
:
null
timer
:
null
,
currentDiagList
:
[],
// 卡片列表数据
mockData
:
[
{
adviceStatus
:
2
,
appointBeginTime
:
'2021-12-02 18:00:00'
,
appointEndTime
:
'2021-12-02 19:00:00'
,
department
:
'心血管内科'
,
departmentId
:
16
,
diagnoseLogId
:
3825
,
diagnoseType
:
2
,
doctorCallKfStatus
:
2
,
doctorCallStatus
:
1
,
doctorCallTime
:
null
,
doctorId
:
1006276891
,
doctorImageUrl
:
'https://test-file.yunqueyi.com//image/png/2019/04/08/20190408101124702-0db0bcea.png'
,
doctorMobile
:
'13817741320'
,
doctorName
:
'金晖'
,
doctorTrtcEntryStatus
:
2
,
imStatus
:
1
,
imTeamId
:
'3942064849'
,
operateUserId
:
221
,
returnStatus
:
2
,
roomId
:
'520001199'
,
sort
:
null
,
status
:
null
,
userCallKfStatus
:
2
,
userCallStatus
:
1
,
userCallTime
:
null
,
userId
:
1006276934
,
userImageUrl
:
'https://test-file.yunqueyi.com//image/png/2019/04/08/20190408101124702-0db0bcea.png'
,
userMobile
:
'13817741327'
,
userName
:
'郑志猛'
,
userTrtcEntryStatus
:
2
,
},
{
adviceStatus
:
2
,
appointBeginTime
:
'2021-12-02 20:00:00'
,
appointEndTime
:
'2021-12-02 21:00:00'
,
department
:
'呼吸内科'
,
departmentId
:
12
,
diagnoseLogId
:
3824
,
diagnoseType
:
1
,
doctorCallKfStatus
:
2
,
doctorCallStatus
:
1
,
doctorCallTime
:
null
,
doctorId
:
1006276946
,
doctorImageUrl
:
'https://test-file.yunqueyi.com//image/png/2019/04/08/20190408101124702-0db0bcea.png'
,
doctorMobile
:
'15821297620'
,
doctorName
:
'朱建波'
,
doctorTrtcEntryStatus
:
2
,
imStatus
:
1
,
imTeamId
:
'3942066774'
,
operateUserId
:
221
,
returnStatus
:
2
,
roomId
:
'520001207'
,
sort
:
null
,
status
:
null
,
userCallKfStatus
:
2
,
userCallStatus
:
1
,
userCallTime
:
null
,
userId
:
1006276934
,
userImageUrl
:
'https://test-file.yunqueyi.com//image/png/2019/04/08/20190408101124702-0db0bcea.png'
,
userMobile
:
'13817741327'
,
userName
:
'郑志猛'
,
userTrtcEntryStatus
:
2
,
},
],
};
};
},
},
computed
:
{
computed
:
{
...
mapState
({
...
mapState
({
currentDiagList
:
(
state
)
=>
state
.
currentDiagList
,
// currentDiagList: (state) => state.currentDiagList,
// currentCalList: (state) => state.currentCalList,
soketQuest
:
(
state
)
=>
state
.
soketQuest
,
soketQuest
:
(
state
)
=>
state
.
soketQuest
,
isSuperAdmin
:
(
state
)
=>
state
.
isSuperAdmin
,
isSuperAdmin
:
(
state
)
=>
state
.
isSuperAdmin
,
}),
}),
},
},
watch
:
{
watch
:
{},
isSuperAdmin
(
newdata
,
olddata
)
{
if
(
newdata
!==
olddata
&&
newdata
.
userID
)
{
console
.
log
(
'-isSuperAdminisSuperAdmin'
,
newdata
);
const
s
=
storejs
.
get
(
'soketQuest'
);
const
d
=
s
?
s
.
dateTime
:
new
Date
().
format
(
'yyyy-MM-dd'
);
const
id
=
s
&&
s
.
operateUserId
?
s
.
operateUserId
:
this
.
isSuperAdmin
.
userID
;
const
p
=
{
dateTime
:
d
,
operateUserId
:
id
,
pageNo
:
s
?
s
.
pageNo
:
1
,
pageSize
:
s
?
s
.
pageSize
:
6
,
returnStatus
:
s
?
s
.
returnStatus
:
1
,
};
this
.
searchParam
=
p
;
const
r
=
s
?
s
.
returnStatus
:
1
;
this
.
tabPosition
=
r
;
this
.
$store
.
commit
(
'main/updateCurrentTabStatus'
,
r
);
this
.
inquirySearch
(
'clear'
);
}
},
},
created
()
{
created
()
{
console
.
log
(
'current
CalList---------------------'
,
this
.
currentCal
List
);
console
.
log
(
'current
DiagList---------------------'
,
this
.
currentDiag
List
);
},
},
mounted
()
{
mounted
()
{
const
s
=
storejs
.
get
(
'soketQuest'
);
const
s
=
storejs
.
get
(
'soketQuest'
);
const
t
=
s
?
s
.
returnStatus
:
1
;
this
.
tabPosition
=
t
;
this
.
$store
.
commit
(
'main/updateCurrentTabStatus'
,
t
);
const
d
=
s
?
s
.
dateTime
:
new
Date
().
format
(
'yyyy-MM-dd'
);
this
.
searchParam
.
dateTime
=
d
;
const
id
=
const
id
=
s
&&
s
.
operateUserId
?
s
.
operateUserId
:
this
.
isSuperAdmin
.
userID
;
s
&&
s
.
operateUserId
?
s
.
operateUserId
:
this
.
isSuperAdmin
.
userID
;
this
.
operateUserId
=
id
;
this
.
operateUserId
=
id
;
this
.
userInfo
=
storejs
.
get
(
'initSocketInfo'
);
this
.
userInfo
=
storejs
.
get
(
'initSocketInfo'
);
console
.
log
(
this
.
userInfo
.
userId
,
'userInfouserInfo'
);
console
.
log
(
this
.
userInfo
.
userId
,
'userInfouserInfo'
,
this
.
tabPositionValue
);
this
.
initCard
();
this
.
initCard
();
// this.timer = window.setInterval(() => {
const
that
=
this
;
// setTimeout(() => {
// if(this.tabPositionValue != 3) {
// this.initCard();
// 轮循
// }, 0);
this
.
timer
=
window
.
setInterval
(()
=>
{
// }, 5000);
setTimeout
(()
=>
{
// that.isShowCardData = false;
that
.
initCard
();
},
0
);
},
4000
);
// }
},
},
destroyed
()
{
destroyed
()
{
window
.
clearInterval
(
this
.
timer
);
window
.
clearInterval
(
this
.
timer
);
},
},
methods
:
{
methods
:
{
initCard
()
{
initCard
()
{
conditionNewList
({
bizType
:
1
,
userId
:
this
.
userInfo
.
userId
}).
then
(
res
=>
{
console
.
log
(
this
.
isShowCardData
);
if
(
res
.
code
===
'000000'
)
{
const
parms
=
{
bizType
:
this
.
tabPositionValue
,
// 1,异常的列表 2,不需要处理的列表
console
.
log
(
111
);
userId
:
this
.
userInfo
.
userId
||
this
.
operateUserId
,
// userId
}
else
{
condition
:
this
.
orderOrName
||
''
,
console
.
log
(
222
);
};
}
// this.currentDiagList = this.mockData;
});
conditionNewList
(
parms
)
.
then
((
res
)
=>
{
if
(
res
.
code
===
'000000'
)
{
this
.
handleData
(
res
.
data
);
}
else
{
this
.
$message
({
message
:
res
.
message
,
type
:
'warning'
,
duration
:
1000
,
});
}
})
.
catch
((
err
)
=>
{
console
.
log
(
err
);
// mock 数据
this
.
handleData
(
this
.
mockData
);
});
},
},
selectDepartment
(
val
)
{
handleData
(
data
)
{
this
.
departmentId
=
val
;
this
.
currentDiagList
=
[];
console
.
log
(
889910
,
val
);
data
.
forEach
((
item
,
index
)
=>
{
item
.
diagnoseLogId
=
'--'
+
Math
.
random
()
*
10
;
item
[
'definitionRandom'
]
=
Math
.
random
()
*
10
;
this
.
$set
(
this
.
currentDiagList
,
index
,
item
);
});
this
.
isShowCardData
=
true
;
// this.$nextTick(() => {
// });
},
},
getSerachValue
(
value
)
{
getSerachValue
(
value
)
{
this
.
searchValu
e
=
value
;
this
.
orderOrNam
e
=
value
;
},
},
handleCheckedCitiesChange
(
value
)
{
handleCheckedCitiesChange
(
value
)
{
console
.
log
(
value
,
'value11'
);
console
.
log
(
value
,
'value11'
);
},
},
getSerValue
()
{
getSearchValue
()
{
console
.
log
(
this
.
searchValue
,
'this.searchValue'
);
if
(
!
this
.
orderOrName
)
{
console
.
log
(
789
,
this
.
departmentId
);
return
this
.
$message
({
message
:
'医生名字或订单号不能为空'
,
type
:
'warning'
,
duration
:
1000
,
});
}
else
{
this
.
initCard
();
}
},
},
tabChange
(
val
)
{
tabChange
(
val
)
{
console
.
log
(
val
,
'val1111===='
);
console
.
log
(
val
,
'val1111===='
);
this
.
tabPositionValue
=
val
;
this
.
tabPositionValue
=
val
;
// const s = this.searchParam;
if
(
val
!=
3
)
{
// s.returnStatus = val;
this
.
initCard
();
// this.searchParam = s;
// s.pageNo = 1;
// this.$store.commit('main/updateCurrentTabStatus', val);
// this.inquirySearch('tab');
},
changeDatetime
(
val
)
{
const
s
=
this
.
searchParam
;
s
.
dateTime
=
val
.
format
(
'yyyy-MM-dd'
);
this
.
searchParam
=
s
;
s
.
pageNo
=
1
;
this
.
inquirySearch
(
'clear'
);
},
handleSizeChange
(
val
)
{
const
s
=
this
.
searchParam
;
s
.
pageSize
=
val
;
this
.
searchParam
=
s
;
this
.
inquirySearch
();
},
handleCurrentChange
(
val
)
{
const
s
=
this
.
searchParam
;
s
.
pageNo
=
val
;
this
.
searchParam
=
s
;
this
.
inquirySearch
();
},
inquirySearch
(
type
)
{
console
.
log
(
type
);
const
p
=
this
.
searchParam
;
if
(
type
==
'clear'
)
{
// this.$store.commit('main/clearRawCurrentCalList');
}
}
conditionUpdate
(
p
).
then
((
res
)
=>
{
if
(
res
.
code
==
'000000'
)
{
this
.
$store
.
commit
(
'main/updateSoketQuest'
,
p
);
if
(
type
==
'tab'
)
{
// const returnStatus = p.returnStatus;
// const RespList = res.data.list[0].recordResp.countRespList.filter(
// (val) => {
// return val.status == returnStatus;
// }
// );
// this.$store.commit('main/changeRawCurrentCalList', RespList[0]);
}
}
else
{
this
.
$message
({
message
:
res
.
message
,
type
:
'warning'
,
duration
:
1000
,
});
}
});
},
},
}
}
,
};
};
</
script
>
</
script
>
<
style
lang=
"scss"
>
<
style
lang=
"scss"
>
...
@@ -425,15 +440,17 @@
...
@@ -425,15 +440,17 @@
}
}
}
}
.workbench-content
{
.workbench-content
{
padding
:
0
2px
;
padding
:
0
2px
;
.workbench-title
{
.workbench-title
{
border-top
:
1px
solid
#F0F2F5
;
border-top
:
1px
solid
#f0f2f5
;
height
:
75px
;
height
:
75px
;
display
:flex
;
display
:
flex
;
line-height
:
75px
;
justify-content
:
flex-end
;
background
:
#fff
;
line-height
:
75px
;
margin-bottom
:
10px
;
background
:
#fff
;
margin-bottom
:
10px
;
.searh-input
{
.searh-input
{
margin-left
:
8px
;
.el-input
{
.el-input
{
width
:
364px
;
width
:
364px
;
.search-botton
{
.search-botton
{
...
@@ -451,7 +468,7 @@
...
@@ -451,7 +468,7 @@
grid-template-rows
:
auto
auto
auto
;
grid-template-rows
:
auto
auto
auto
;
//grid-template-columns: 32% 32% 32%;
//grid-template-columns: 32% 32% 32%;
//grid-row-gap: 2%;
//grid-row-gap: 2%;
grid-column-gap
:
10px
;
grid-column-gap
:
10px
;
padding
:
0px
7px
;
padding
:
0px
7px
;
.el-checkbox-group
{
.el-checkbox-group
{
.el-checkbox
{
.el-checkbox
{
...
...
写
预览
Markdown
格式
0%
请重试
or
附加一个文件
附加文件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录