Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
pet-business-web
Project
Project
Details
Activity
Releases
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
刘怀志
pet-business-web
Commits
3ad8dd56
Commit
3ad8dd56
authored
Jun 07, 2023
by
小费同学阿
💬
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加lint代码校验
parent
9912f3fe
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
1484 additions
and
18 deletions
+1484
-18
register.js
src/api/business/register.js
+44
-0
index.js
src/router/index.js
+51
-12
registration-detail.vue
...ice-management/registration-queue/registration-detail.vue
+769
-0
registration-queue.vue
...vice-management/registration-queue/registration-queue.vue
+620
-6
No files found.
src/api/business/register.js
0 → 100644
View file @
3ad8dd56
import
request
from
'@/utils/request'
// 查询挂号列表
export
function
listRegister
(
query
)
{
return
request
({
url
:
'/business/register/list'
,
method
:
'get'
,
params
:
query
})
}
// 查询挂号详细
export
function
getRegister
(
id
)
{
return
request
({
url
:
'/business/register/'
+
id
,
method
:
'get'
})
}
// 新增挂号
export
function
addRegister
(
data
)
{
return
request
({
url
:
'/business/register'
,
method
:
'post'
,
data
:
data
})
}
// 修改挂号
export
function
updateRegister
(
data
)
{
return
request
({
url
:
'/business/register'
,
method
:
'put'
,
data
:
data
})
}
// 删除挂号
export
function
delRegister
(
id
)
{
return
request
({
url
:
'/business/register/'
+
id
,
method
:
'delete'
})
}
src/router/index.js
View file @
3ad8dd56
...
...
@@ -199,6 +199,51 @@ export const constantRoutes = [
}
]
},
// 文章
{
path
:
'/article-management'
,
component
:
Layout
,
hidden
:
true
,
permissions
:
[
'*:*:*'
],
children
:
[
{
path
:
'index'
,
props
:
true
,
component
:
()
=>
import
(
'@/views/article-management/article-management'
),
name
:
'Article-management'
,
meta
:
{
title
:
'文章管理'
,
icon
:
'component'
}
},
// 文章编辑路由
{
path
:
'article-edit/:id'
,
props
:
true
,
component
:
()
=>
import
(
'@/views/article-management/article-edit'
),
name
:
'Article-edit'
,
meta
:
{
title
:
'文章编辑'
,
icon
:
'component'
}
},
// 文章详情路由
{
path
:
'article-detail/:id'
,
component
:
()
=>
import
(
'@/views/article-management/article-detail'
),
name
:
'ArticleDetail'
,
props
:
true
,
meta
:
{
title
:
'文章详情'
,
icon
:
'component'
}
},
// 文章添加路由
{
path
:
'article-insert'
,
component
:
()
=>
import
(
'@/views/article-management/article-insert'
),
name
:
'ArticleInsert'
,
props
:
true
,
meta
:
{
title
:
'新增文章'
,
activeMenu
:
'/article-management'
}
}
]
},
// 业务管理
{
path
:
'/service-management'
,
...
...
@@ -210,26 +255,20 @@ export const constantRoutes = [
{
path
:
'registration-queue'
,
props
:
true
,
permissions
:
[
'*:*:*'
],
component
:
()
=>
import
(
'@/views/service-management/registration-queue/registration-queue'
),
name
:
'RegistrationQueue'
,
meta
:
{
title
:
'挂号管理'
,
icon
:
'dashboard'
,
activeMenu
:
'/service-management/registration-queue'
title
:
'挂号管理'
,
icon
:
'component'
}
},
// 挂号
新增
// 挂号
详情路由
{
path
:
'registration-add'
,
path
:
'registration-detail/:id'
,
component
:
()
=>
import
(
'@/views/service-management/registration-queue/registration-detail'
),
name
:
'RegistrationDetail'
,
props
:
true
,
permissions
:
[
'*:*:*'
],
component
:
()
=>
import
(
'@/views/service-management/registration-queue/registration-add'
),
name
:
'RegistrationAdd'
,
meta
:
{
title
:
'新增挂号'
,
icon
:
'dashboard'
,
activeMenu
:
'/service-management/registration-add'
title
:
'挂号详情'
,
icon
:
'component'
}
}
]
...
...
src/views/service-management/registration-queue/registration-detail.vue
0 → 100644
View file @
3ad8dd56
<
template
>
<div
style=
"background-color: #FFFFFF;"
>
<!-- 宠物详情页-->
<div
class=
"pet-detail"
>
<!-- 头部标题-->
<div
style=
"padding-top:32px;text-align: center;"
>
<span
style=
"font-size: 24px;
font-family: Microsoft YaHei-Bold, Microsoft YaHei,serif;
font-weight: bold;
color: #333333;"
>
详情
</span>
</div>
<!-- 整体卡片内页面的样式--边距-->
<div
style=
"padding: 20px 20px 20px 20px;"
>
<!--宠物头像-->
<div
style=
"display: flex"
>
<!-- 1-- 宠物基本信息的页面--标签头 -->
<div
class=
"tip-green"
/>
<div
style=
"padding-left: 13px;font-size: 16px;font-family: Microsoft YaHei-Bold, Microsoft YaHei,serif;font-weight: bold;color: #333333;"
>
宠物头像
</div>
</div>
<!-- 1-- 宠物基本信息的页面--内部信息 -->
<div
class=
"base-msg"
>
<div>
<!--宠物图片-->
<div
class=
"petPicture"
style=
"padding-bottom: 40px;"
>
<ImagePreview
:height=
"150"
:src=
"baseURL+petInfo.petPicture"
:width=
"150"
/>
</div>
</div>
</div>
<!--基本信息-->
<div
style=
"display: flex"
>
<!-- 1-- 宠物基本信息的页面--标签头 -->
<div
class=
"tip-green"
/>
<div
style=
"padding-left: 13px;font-size: 16px;font-family: Microsoft YaHei-Bold, Microsoft YaHei,serif;font-weight: bold;color: #333333;"
>
宠物信息
</div>
</div>
<el-form
ref=
"form"
:model=
"petOwners"
label-width=
"110px"
>
<!-- 1-- 宠物基本信息的页面--内部信息 -->
<div
class=
"base-msg"
>
<div>
<!--基础信息右边的信息-->
<div
class=
"base-inner"
>
<!--宠物昵称-->
<el-row>
<el-col
:span=
"8"
>
<el-form-item
label=
"宠物昵称"
>
<span
class=
"content-style"
>
{{
petInfo
.
petNickname
}}
</span>
</el-form-item>
</el-col>
<el-col
:span=
"8"
>
<!--宠物ID-->
<el-form-item
label=
"宠物ID"
>
<span
class=
"content-style"
>
{{
petInfo
.
petsId
}}
</span>
</el-form-item>
</el-col>
<el-col
:span=
"8"
>
<!--宠物品种-->
<el-form-item
label=
"宠物品种"
>
<span
class=
"content-style"
>
{{
options
[
petInfo
.
petBreed
.
substring
(
0
,
1
)].
children
.
find
(({
value
}
)
=>
value
===
petInfo
.
petBreed
.
substring
(
1
))
&&
options
[
petInfo
.
petBreed
.
substring
(
0
,
1
)].
children
.
find
(({
value
}
)
=>
value
===
petInfo
.
petBreed
.
substring
(
1
)).
label
}}
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
/el-row
>
<
el
-
row
>
<
el
-
col
:
span
=
"8"
>
<!--
宠物性别
-->
<
el
-
form
-
item
label
=
"宠物性别"
>
<!--
<
dict
-
tag
:
options
=
"dict.type.pet_sex"
:
value
=
"petInfo.petSex"
/>-->
<
i
v
-
if
=
"petInfo.petSex === '0'"
class
=
"el-icon-male"
/>
<
i
v
-
else
-
if
=
"petInfo.petSex === '1'"
class
=
"el-icon-female"
/>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<!--
宠物年龄
-->
<
el
-
form
-
item
label
=
"宠物年龄"
>
<
span
class
=
"content-style"
>
{{
petInfo
.
petAge
}}
岁
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<!--
宠物体重
-->
<
el
-
form
-
item
label
=
"宠物体重"
>
<
span
class
=
"content-style"
>
{{
petInfo
.
petWeight
}}
kg
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
/el-row
>
<
el
-
row
>
<
el
-
col
:
span
=
"8"
>
<!--
宠物毛色
-->
<
el
-
form
-
item
label
=
"宠物毛色"
>
<
span
class
=
"content-style"
>
{{
petInfo
.
petColor
}}
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<!--
创建时间
-->
<
el
-
form
-
item
label
=
"创建时间"
>
<
span
class
=
"content-style"
>
{{
parseTime
(
petInfo
.
createTime
,
'{y
}
/{m
}
/{d
}
'
)
}}
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<!--
生存状态
-->
<
el
-
form
-
item
label
=
"生存状态"
>
<
dict
-
tag
:
options
=
"dict.type.exist_state"
:
value
=
"petInfo.existState"
class
=
"content-style"
/>
<
/el-form-item
>
<
/el-col
>
<
/el-row
>
<
el
-
row
>
<
el
-
col
:
span
=
"8"
>
<!--
绝育情况
-->
<
el
-
form
-
item
label
=
"绝育情况"
>
<
dict
-
tag
:
options
=
"dict.type.sterilization_status"
:
value
=
"petInfo.sterilizationStatus"
class
=
"content-style"
/>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<!--
疫苗情况
-->
<
el
-
form
-
item
label
=
"疫苗情况"
>
<
dict
-
tag
:
options
=
"dict.type.vaccine_situation"
:
value
=
"petInfo.vaccineSituation"
class
=
"content-style"
/>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<!--
疫苗情况
-->
<
el
-
form
-
item
label
=
"是否绑定"
>
<
div
class
=
"content-style"
>
已购保险
<
/div
>
<
/el-form-item
>
<
/el-col
>
<
/el-row
>
<
/div
>
<
/div
>
<
/div
>
<
/el-form
>
<!--
主人信息
-->
<
div
style
=
"display: flex"
>
<
div
class
=
"tip-green"
/>
<
div
style
=
"padding-left: 13px;font-size: 16px;font-family: Microsoft YaHei-Bold, Microsoft YaHei,serif;font-weight: bold;color: #333333;"
>
宠主信息
<
/div
>
<
/div
>
<!--
3
--
主人信息的页面
--
内部信息
-->
<
el
-
form
ref
=
"form"
:
model
=
"petOwners"
label
-
width
=
"110px"
>
<
div
class
=
"ownerMsg-inner"
>
<
el
-
row
>
<
el
-
col
:
span
=
"8"
>
<
el
-
form
-
item
label
=
"宠主姓名"
>
<
span
class
=
"content-style"
>
{{
petOwners
.
nickname
}}
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<
el
-
form
-
item
label
=
"手机号"
>
<
span
class
=
"content-style"
>
{{
petOwners
.
phonenumber
}}
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<
el
-
form
-
item
label
=
"用户ID"
>
<
span
class
=
"content-style"
>
{{
petOwners
.
ownersId
}}
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
/el-row
>
<
el
-
row
>
<
el
-
col
:
span
=
"8"
>
<
el
-
form
-
item
label
=
"创建时间"
>
<
span
class
=
"content-style"
>
{{
parseTime
(
petOwners
.
createTime
,
'{y
}
/{m
}
/{d
}
'
)
}}
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<
el
-
form
-
item
label
=
"会员等级"
>
<
span
v
-
if
=
"checkRole(['pt-admin'])"
class
=
"content-style"
>-<
/span
>
<
span
v
-
else
>
{{
selectDictLabel
(
membershipLevelList
,
hosipitalPownersForm
[
0
].
membershipLevel
)
}}
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<
el
-
form
-
item
label
=
"会员卡余额"
>
<
span
v
-
if
=
"checkRole(['pt-admin'])"
class
=
"content-style"
>-<
/span><spa
n
v
-
else
class
=
"content-style"
>
{{
hosipitalPownersForm
[
0
].
cardBalance
}}
元
<
/span></
el
-
form
-
item
>
<
/el-col
>
<
/el-row
>
<
el
-
row
>
<
el
-
col
:
span
=
"8"
>
<
el
-
form
-
item
label
=
"状态"
>
<
span
v
-
if
=
"checkRole(['pt-admin'])"
class
=
"content-style"
>-<
/span><spa
n
v
-
else
><
dict
-
tag
:
options
=
"statusList"
:
value
=
"petOwners.hosipitalPownersForm.status"
/><
/span
>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<
el
-
form
-
item
label
=
"绑定宠物数量"
><
span
class
=
"content-style"
>
{{
petsList
.
length
}}
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
/el-row
>
<
/div
>
<
/el-form
>
<!--
进度信息
-->
<
div
style
=
"display: flex"
>
<
div
class
=
"tip-green"
/>
<
div
style
=
"padding-left: 13px;font-size: 16px;font-family: Microsoft YaHei-Bold, Microsoft YaHei,serif;font-weight: bold;color: #333333;"
>
进度信息
<
/div
>
<
/div
>
<
div
style
=
"padding-top: 50px;padding-bottom: 50px;"
>
<
el
-
steps
:
active
=
"2"
align
-
center
>
<
el
-
step
description
=
"2023-05-05 13:05"
title
=
"现场挂号"
/>
<
el
-
step
description
=
"暂未诊断"
title
=
"录入诊断信息"
/>
<
el
-
step
description
=
"暂未生成"
title
=
"生成病历"
/>
<
el
-
step
description
=
"暂未开具"
title
=
"开具处方单"
/>
<
/el-steps
>
<
/div
>
<!--
挂号信息
-->
<
div
style
=
"display: flex"
>
<!--
1
--
挂号信息的页面
--
标签头
-->
<
div
class
=
"tip-green"
/>
<
div
style
=
"padding-left: 13px;font-size: 16px;font-family: Microsoft YaHei-Bold, Microsoft YaHei,serif;font-weight: bold;color: #333333;"
>
挂号信息
<
/div
>
<
/div
>
<
el
-
form
ref
=
"form"
:
model
=
"petOwners"
label
-
width
=
"110px"
>
<!--
1
--
挂号信息的页面
--
内部信息
-->
<
div
class
=
"base-msg"
>
<
div
>
<!--
基础信息右边的信息
-->
<
div
class
=
"base-inner"
>
<!--
挂号方式
-->
<
el
-
row
>
<
el
-
col
:
span
=
"8"
>
<
el
-
form
-
item
label
=
"挂号方式"
>
<
span
class
=
"content-style"
>
{{
petInfo
.
petNickname
}}
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<!--
挂号时间
-->
<
el
-
form
-
item
label
=
"挂号时间"
>
<
span
class
=
"content-style"
>
{{
petInfo
.
petsId
}}
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<!--
是否首诊
-->
<
el
-
form
-
item
label
=
"是否首诊"
>
<
span
class
=
"content-style"
>
{{
petInfo
.
petsId
}}
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
/el-row
>
<
el
-
row
>
<
el
-
col
:
span
=
"8"
>
<!--
就诊日期
-->
<
el
-
form
-
item
label
=
"就诊日期"
>
<
span
class
=
"content-style"
>
{{
parseTime
(
petInfo
.
createTime
,
'{y
}
/{m
}
/{d
}
'
)
}}
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<!--
就诊时段
-->
<
el
-
form
-
item
label
=
"就诊时段"
>
<
span
class
=
"content-style"
>
{{
petInfo
.
petAge
}}
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<!--
门诊诊查费
-->
<
el
-
form
-
item
label
=
"门诊诊查费"
>
<
span
class
=
"content-style"
>
{{
petInfo
.
petWeight
}}
元
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
/el-row
>
<
el
-
row
>
<
el
-
col
:
span
=
"8"
>
<!--
缴费状态
-->
<
el
-
form
-
item
label
=
"缴费状态"
>
<
dict
-
tag
:
options
=
"dict.type.exist_state"
:
value
=
"petInfo.existState"
class
=
"content-style"
/>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<!--
缴费时间
-->
<
el
-
form
-
item
label
=
"缴费时间"
>
<
span
class
=
"content-style"
>
{{
parseTime
(
petInfo
.
createTime
,
'{y
}
/{m
}
/{d
}
'
)
}}
<
/span
>
<
/el-form-item
>
<
/el-col
>
<
/el-row
>
<
/div
>
<
/div
>
<
/div
>
<
/el-form
>
<!--
进度信息
-->
<
div
style
=
"display: flex"
>
<
div
class
=
"tip-green"
/>
<
div
style
=
"padding-left: 13px;font-size: 16px;font-family: Microsoft YaHei-Bold, Microsoft YaHei,serif;font-weight: bold;color: #333333;"
>
进度信息
<
/div
>
<
/div
>
<
div
style
=
"margin-bottom: 50px;"
>
<
div
class
=
"card-style"
>
<
el
-
card
v
-
for
=
"o in 4"
:
key
=
"o"
class
=
"boxside-card"
style
=
" margin: 20px 46px 0 0 ; height: fit-content;"
>
<
div
style
=
"padding: 5%;"
>
<!--
卡片上半部分
-->
<
div
style
=
"display: flex; height: fit-content;"
>
<!--
上
--
左半部分
-->
<
div
>
<
el
-
image
fit
=
"cover"
src
=
"http://114.67.241.140:8090/profile/upload/2023/05/10/dog1_20230510063813A013.png"
style
=
"width: 64px;
height: 80px;
background: #EEEEEE;
border-radius: 2px 2px 2px 2px;"
/>
<
/div
>
<!--
上
--
右半部分
-->
<
div
style
=
"padding: 0 5% 0 5%; padding-top: 10px; "
>
<
div
style
=
" font-size: 16px;
font-family: Microsoft YaHei-Bold, Microsoft YaHei;
font-weight: bold;
color: #5FB54B;"
>
徐燕君
<
/div
>
<
div
style
=
"display: flex; margin-top: 18px;"
>
<
div
style
=
" font-size: 14px;
font-family: Microsoft YaHei-Regular, Microsoft YaHei;
font-weight: 400;
color: #666666;"
>
高级兽医师
<
/div
>
<
div
style
=
"font-size: 14px;
font-family: Microsoft YaHei-Regular, Microsoft YaHei;
font-weight: 400;
color: #666666;"
>|
<
/div
>
<
div
style
=
" font-size: 14px;
font-family: Microsoft YaHei-Regular, Microsoft YaHei;
font-weight: 400;
color: #666666;"
>
宠物外科
<
/div
>
<
/div
>
<
/div
>
<
/div
>
<!--
分割线
-->
<
el
-
divider
style
=
"border-color: #48D1CC"
/>
<!--
卡片中间部分
-->
<
div
>
<
el
-
image
v
-
for
=
" o in 2"
:
key
=
"o"
fit
=
"cover"
src
=
"http://114.67.241.140:8090/profile/upload/2023/05/10/dog1_20230510063813A013.png"
style
=
"width: 32px;
height: 32px;
background: #EEEEEE;
margin-right: 12px;
margin-bottom: 15px;
border-radius: 2px 2px 2px 2px;"
/>
<
/div
>
<!--
卡片下半部分
-->
<
div
class
=
"card-style"
>
<
div
class
=
"inner-style"
>
<
div
style
=
"font-size: 14px;
font-family: Microsoft YaHei-Regular, Microsoft YaHei;
font-weight: 400;
color: #666666;"
>
当日已接挂号
<
/div
>
<
div
style
=
"font-size: 16px;
font-family: Microsoft YaHei-Bold, Microsoft YaHei;
font-weight: bold;
color: #333333;margin-top: 15px;"
>
14
<
/div
>
<
/div
>
<
div
class
=
"inner-style"
>
<
div
style
=
"font-size: 14px;
font-family: Microsoft YaHei-Regular, Microsoft YaHei;
font-weight: 400;
color: #666666;"
>
当日时段已接
<
/div
>
<
div
style
=
"font-size: 16px;
font-family: Microsoft YaHei-Bold, Microsoft YaHei;
font-weight: bold;
color: #333333;margin-top: 15px;"
>
2
<
/div
>
<
/div
>
<
div
class
=
"inner-style"
>
<
div
style
=
"font-size: 14px;
font-family: Microsoft YaHei-Regular, Microsoft YaHei;
font-weight: 400;
color: #666666;"
>
时段剩余号量
<
/div
>
<
div
style
=
"font-size: 16px;
font-family: Microsoft YaHei-Bold, Microsoft YaHei;
font-weight: bold;
color: #DB4747;margin-top: 15px;"
>
0
<
/div
>
<
/div
>
<
/div
>
<
/div
>
<!--
底部菜单
-->
<
div
style
=
"background: #F4F4F4;"
>
<
div
class
=
"card-style"
style
=
"
height: 36px;
border-radius: 0px 0px 3px 3px;"
>
<
div
>
<
el
-
button
icon
=
"el-icon-document-copy"
style
=
"font-size: 12px;
font-family: Microsoft YaHei-Regular, Microsoft YaHei;
font-weight: 400;
color: #5FB54B;"
type
=
"text"
>
详情
<
/el-button
>
<
/div
>
<
div
>
<
el
-
button
icon
=
"el-icon-phone-outline"
type
=
"text"
>
挂号
<
/el-button
>
<
/div
>
<
div
>
<
el
-
button
icon
=
"el-icon-date"
type
=
"text"
>
加号
<
/el-button
>
<
/div
>
<
/div
>
<
/div
>
<
/el-card
>
<
/div
>
<
/div
>
<!--
底部返回按钮
-->
<
el
-
button
class
=
"queryBtn"
icon
=
"el-icon-back"
@
click
=
"goBack"
>
返
回
<
/el-button
>
<
/div
>
<
/div
>
<
/div
>
<
/template
>
<
script
>
// 导入获取宠物信息的接口
import
{
getPets
,
listAllPets
}
from
'@/api/business/pets'
import
{
getOwners
}
from
'@/api/business/petowners'
import
{
checkRole
}
from
'@/utils/permission'
import
{
parseTime
,
selectDictLabel
}
from
'@/utils/ruoyi'
export
default
{
name
:
'RegistrationDetail'
,
// 数据字典
dicts
:
[
'pet_sex'
,
'vaccine_situation'
,
'exist_state'
,
'sterilization_status'
,
'cat_breed'
,
'dog_breed'
,
'other_breed'
],
data
()
{
return
{
// 各医院会员卡信息
hosipitalPownersForm
:
[{
}
],
// 状态下拉框
statusList
:
[{
label
:
'全部'
,
value
:
''
}
,
{
label
:
'已启用'
,
value
:
'0'
}
,
{
label
:
'已禁用'
,
value
:
'1'
}
],
// 会员等级下拉框
membershipLevelList
:
[
{
label
:
'一级会员'
,
value
:
'1'
}
,
{
label
:
'二级会员'
,
value
:
'2'
}
,
{
label
:
'三级会员'
,
value
:
'3'
}
,
{
label
:
'四级会员'
,
value
:
'4'
}
,
{
label
:
'五级会员'
,
value
:
'5'
}
],
// 品种数据字典
options
:
[{
value
:
'0'
,
label
:
'猫'
,
children
:
[]
}
,
{
value
:
'1'
,
label
:
'狗'
,
children
:
[]
}
,
{
value
:
'2'
,
label
:
'其它'
,
children
:
[]
}
],
// 图片访问
baseURL
:
process
.
env
.
VUE_APP_TEST_API
,
// 宠物信息
petInfo
:
{
petBreed
:
'11'
}
,
// 宠物主信息
petOwners
:
{
hosipitalPownersForm
:
{
}
}
,
// 总条数
total
:
0
,
// 宠物表格数据
petsList
:
[],
// 保险信息假数据
petProtect
:
[{
protectName
:
'人兽保险'
,
type
:
'意外保险'
,
date
:
'3年'
}
,
{
protectName
:
'平安保险'
,
type
:
'人身保险'
,
date
:
'3年'
}
]
}
}
,
created
()
{
/** 获取宠物信息 */
this
.
getInfo
(
this
.
$route
.
params
.
id
)
/** 获取宠物主信息 */
this
.
getPetOwners
(
this
.
$route
.
params
.
petOwnersId
)
/** 获取宠物数量信息 */
this
.
getPetsInfo
(
this
.
$route
.
params
.
petOwnersId
)
}
,
methods
:
{
parseTime
,
selectDictLabel
,
checkRole
,
// 获取宠物数量信息
getPetsInfo
(
id
)
{
listAllPets
({
petOwnersId
:
id
}
).
then
(
response
=>
{
console
.
log
(
'这是一些个关于宠物数量的信息:'
,
response
)
this
.
petsList
=
response
.
data
}
)
}
,
// 获取宠物主人信息
getPetOwners
(
id
)
{
getOwners
(
id
).
then
(
response
=>
{
console
.
log
(
'这是一些个关于宠物主的信息:'
,
response
)
this
.
petOwners
=
{
nickname
:
response
.
data
[
0
].
nickname
,
userId
:
response
.
data
[
0
].
userId
,
ownersId
:
response
.
data
[
0
].
ownersId
,
phonenumber
:
response
.
data
[
0
].
phonenumber
,
createTime
:
response
.
data
[
0
].
createTime
,
hosipitalPownersForm
:
response
.
data
[
0
].
hosipitalPownersForm
}
console
.
log
(
'这是一些个关于宠物主赋值的信息:'
,
this
.
petOwners
)
this
.
hosipitalPownersForm
=
[]
for
(
const
petOwner
of
response
.
data
)
{
this
.
hosipitalPownersForm
.
push
({
hospitalName
:
petOwner
.
hospitalName
,
...
petOwner
.
hosipitalPownersForm
}
)
}
console
.
log
(
'会员卡的信息在这:'
,
this
.
hosipitalPownersForm
)
}
)
}
,
/**
* 字典获取完成的回调
*/
onDictReady
()
{
this
.
setPetBreed
()
}
,
/**
* 设置宠物品种信息
*/
setPetBreed
()
{
this
.
options
[
0
].
children
=
this
.
dict
.
type
.
cat_breed
this
.
options
[
1
].
children
=
this
.
dict
.
type
.
dog_breed
this
.
options
[
2
].
children
=
this
.
dict
.
type
.
other_breed
}
,
/** 返回跳转列表页 */
goBack
()
{
// this.$router.back()
this
.
$router
.
push
({
path
:
'/service-management/registration-queue/registration-queue'
}
)
}
,
/** 获取宠物信息(传参传宠物表id)*/
getInfo
(
id
)
{
getPets
(
id
).
then
(
response
=>
{
this
.
petInfo
=
response
.
data
}
)
}
}
}
<
/script
>
<
style
lang
=
"scss"
scoped
>
//整个页面整体布局
.
pet
-
detail
{
//最外层嵌套卡片的样式
.
box
-
card
{
margin
:
20
px
20
px
20
px
20
px
;
}
// 宠物图片
.
petPicture
{
display
:
inline
-
block
;
width
:
150
px
;
height
:
150
px
;
padding
-
left
:
28
px
;
}
//头像尺寸
::
v
-
deep
.
el
-
card__body
{
padding
:
0
!
important
;
//height:150px;
}
//1--基本信息--模块内信息整体样式
.
base
-
msg
{
//display: grid !important;
//grid-template-columns: repeat(2, auto);
color
:
#
666666
;
margin
-
top
:
20
px
;
margin
-
bottom
:
20
px
;
//margin-left: 5%;
//margin-right: 5%;
//基础信息右边的信息样式
.
base
-
inner
{
//display: grid !important;
//grid-template-columns: repeat(3, auto);
//与头像左边距
//padding-left: 10%;
}
}
//2--宠物保险--模块内信息整体样式
.
pet
-
insurance
{
margin
:
35
px
1
%
20
px
;
}
//3--主人信息--模块内信息整体样式
.
ownerMsg
-
inner
{
color
:
#
666666
;
//display: grid !important;
//grid-template-columns: repeat(2, auto);
margin
-
top
:
20
px
;
margin
-
bottom
:
20
px
;
//margin-right: 5%;
}
//模块tip样式--绿色
.
tip
-
green
{
width
:
3
px
;
height
:
24
px
;
background
:
#
5
FB54B
;
border
-
radius
:
10
px
10
px
10
px
10
px
;
}
//模块tip样式--橙色
.
tip
-
orange
{
height
:
30
px
;
border
-
left
:
5
px
solid
#
fc8135
;
}
//模块tip样式--蓝色
.
tip
-
blue
{
height
:
30
px
;
border
-
left
:
5
px
solid
#
69
bdff
;
}
//模块tip样式--黄色
.
tip
-
yellow
{
height
:
30
px
;
border
-
left
:
5
px
solid
#
f3ff00
;
}
//所有表格内容选中后的样式-all
::
v
-
deep
.
el
-
table
--
enable
-
row
-
hover
.
el
-
table__body
tr
:
hover
>
td
.
el
-
table__cell
{
background
-
color
:
#
F6FCF5
!
important
;
}
}
//宠物性别样式
::
v
-
deep
.
el
-
icon
-
male
{
margin
-
top
:
3
px
;
margin
-
left
:
3
px
;
}
//详情页label文字样式设置(穿透)
::
v
-
deep
.
el
-
form
-
item__label
{
font
-
size
:
14
px
;
font
-
family
:
Microsoft
YaHei
-
Regular
,
Microsoft
YaHei
;
font
-
weight
:
400
;
color
:
#
707070
;
}
//详情页表单内容文字样式
.
content
-
style
{
font
-
size
:
14
px
;
font
-
family
:
Microsoft
YaHei
-
Regular
,
Microsoft
YaHei
;
font
-
weight
:
400
;
height
:
auto
;
color
:
#
333333
;
}
.
card
-
style
{
height
:
fit
-
content
;
display
:
grid
;
grid
-
template
-
columns
:
repeat
(
3
,
33
%
);
justify
-
self
:
center
;
align
-
self
:
center
;
}
.
inner
-
style
{
display
:
flex
;
align
-
items
:
center
;
flex
-
direction
:
column
;
}
.
boxside
-
card
{
width
:
487
px
;
height
:
303
px
;
background
:
#
FFFFFF
;
opacity
:
1
;
border
:
1
px
solid
#
E5E5E5
;
}
<
/style
>
src/views/service-management/registration-queue/registration-queue.vue
View file @
3ad8dd56
<
template
>
<div>
挂号队列
</div>
<!-- 背景颜色-->
<div
style=
"background-color: #FFFFFF;"
>
<div
class=
"app-container"
>
<el-form
v-show=
"showSearch"
ref=
"queryForm"
:inline=
"true"
:model=
"queryParams"
label-width=
"68px"
size=
"small"
>
<el-form-item
prop=
"petNickname"
>
<el-input
v-model=
"queryParams.petNickname"
clearable
placeholder=
"请输入宠物昵称/宠主姓名"
@
keyup
.
enter
.
native=
"handleQuery"
/>
</el-form-item>
<el-form-item
prop=
"departmentId"
>
<el-select
v-model=
"queryParams.departmentId"
clearable
placeholder=
"挂号方式"
>
<el-option
v-for=
"item in registerTypeList"
:key=
"item.value"
:label=
"item.label"
:value=
"item.value"
/>
</el-select>
</el-form-item>
<el-form-item
prop=
"departmentId"
>
<el-select
v-model=
"queryParams.departmentId"
clearable
placeholder=
"所属科室"
>
<el-option
v-for=
"item in departmentList"
:key=
"item.value"
:label=
"item.label"
:value=
"item.value"
/>
</el-select>
</el-form-item>
<el-form-item
prop=
"departmentId"
>
<el-select
v-model=
"queryParams.doctorName"
clearable
placeholder=
"医生姓名"
>
<el-option
v-for=
"item in doctorNameList"
:key=
"item.value"
:label=
"item.label"
:value=
"item.value"
/>
</el-select>
</el-form-item>
<el-form-item
prop=
"visitDate"
>
<el-date-picker
v-model=
"queryParams.visitDate"
clearable
placeholder=
"请选择就诊日期"
type=
"date"
value-format=
"yyyy-MM-dd"
/>
</el-form-item>
<el-form-item
prop=
"sort"
>
<el-select
v-model=
"queryParams.params.sort"
clearable
placeholder=
"请选择排序方式"
>
<el-option
v-for=
"item in sortList"
:key=
"item.value"
:label=
"item.label"
:value=
"item.value"
/>
</el-select>
</el-form-item>
</el-form>
<el-row
:gutter=
"10"
class=
"mb8"
>
<el-col
:span=
"1.5"
>
<el-button
v-hasPermi=
"['business:register:add']"
class=
"fourWordsBtn"
icon=
"el-icon-circle-plus-outline"
size=
"mini"
@
click=
"handleAdd"
>
新增挂号
</el-button>
</el-col>
<!--选择全部-->
<el-button
v-hasPermi=
"['business:register:export']"
class=
"fourWordsBtn"
icon=
"el-icon-right"
size=
"mini"
@
click=
"selectAll"
>
选择全部
</el-button>
<!--反向选择-->
<el-button
v-hasPermi=
"['business:register:export']"
class=
"fourWordsBtn"
icon=
"el-icon-back"
size=
"mini"
@
click=
"reverseSelect"
>
反向选择
</el-button>
<!--批量导出-->
<el-button
v-hasPermi=
"['business:register:export']"
class=
"fourWordsBtn"
icon=
"el-icon-upload2"
size=
"mini"
@
click=
"handleExport"
>
批量导出
</el-button>
<el-button
class=
"queryBtn"
icon=
"el-icon-search"
size=
"mini"
@
click=
"handleQuery"
>
查询
</el-button>
<el-button
class=
"resetBtn"
icon=
"el-icon-refresh"
size=
"mini"
@
click=
"resetQuery"
>
重置
</el-button>
</el-row>
<el-table
v-loading=
"loading"
:data=
"registerList"
@
selection-change=
"handleSelectionChange"
>
<el-table-column
align=
"center"
type=
"selection"
width=
"55"
/>
<el-table-column
align=
"center"
label=
"序号"
min-width=
"55"
show-overflow-tooltip
prop=
"index"
/>
<el-table-column
align=
"center"
label=
"挂号方式"
min-width=
"70"
show-overflow-tooltip
prop=
"type"
/>
<el-table-column
align=
"center"
label=
"宠物昵称"
min-width=
"70"
show-overflow-tooltip
prop=
"petNickname"
/>
<el-table-column
align=
"center"
label=
"宠物保险"
min-width=
"70"
show-overflow-tooltip
prop=
"insure"
/>
<el-table-column
align=
"center"
label=
"宠主姓名"
min-width=
"70"
show-overflow-tooltip
prop=
"petSex"
/>
<el-table-column
align=
"center"
label=
"联系方式"
min-width=
"70"
show-overflow-tooltip
prop=
"petAge"
/>
<el-table-column
align=
"center"
label=
"挂号时间"
min-width=
"80"
show-overflow-tooltip
prop=
"payTime"
>
<template
slot-scope=
"scope"
>
<span>
{{
parseTime
(
scope
.
row
.
payTime
,
'{y
}
/{m
}
/{d
}
'
)
}}
<
/span
>
<
/template
>
<
/el-table-column
>
<
el
-
table
-
column
align
=
"center"
label
=
"预约兽医"
min
-
width
=
"60"
show
-
overflow
-
tooltip
prop
=
"doctorName"
/>
<
el
-
table
-
column
align
=
"center"
label
=
"所属科室"
min
-
width
=
"70"
show
-
overflow
-
tooltip
prop
=
"departmentName"
/>
<
el
-
table
-
column
align
=
"center"
label
=
"就诊方式"
min
-
width
=
"70"
show
-
overflow
-
tooltip
prop
=
"visitWay"
/>
<
el
-
table
-
column
align
=
"center"
label
=
"是否首诊"
min
-
width
=
"70"
show
-
overflow
-
tooltip
prop
=
"firstVisit"
/>
<
el
-
table
-
column
align
=
"center"
label
=
"就诊时间"
min
-
width
=
"80"
show
-
overflow
-
tooltip
prop
=
"visitDate"
>
<
template
slot
-
scope
=
"scope"
>
<
span
>
{{
parseTime
(
scope
.
row
.
visitDate
,
'{y
}
/{m
}
/{d
}
'
)
}}
<
/span
>
<
/template
>
<
/el-table-column
>
<
el
-
table
-
column
align
=
"center"
label
=
"缴费状态"
min
-
width
=
"70"
show
-
overflow
-
tooltip
prop
=
"payStatus"
/>
<
el
-
table
-
column
align
=
"center"
class
-
name
=
"small-padding fixed-width"
min
-
width
=
"180"
label
=
"操作"
>
<
template
slot
-
scope
=
"scope"
>
<
el
-
button
icon
=
"el-icon-document"
plain
size
=
"mini"
style
=
"width: 50px; border-radius: 6px 6px 6px 6px;border: 1px solid rgb(95,181,75);"
type
=
"success"
@
click
=
"handleDetail(scope.row)"
>
详情
<
/el-button
>
<
el
-
button
v
-
hasPermi
=
"['business:register:edit']"
icon
=
"el-icon-edit"
plain
size
=
"mini"
style
=
"width: 50px; border-radius: 6px 6px 6px 6px;border: 1px solid rgb(52,144,206);"
type
=
"primary"
@
click
=
"handleUpdate(scope.row)"
>
编辑
<
/el-button
>
<
el
-
button
icon
=
"el-icon-paperclip"
plain
size
=
"mini"
style
=
"width: 70px; border-radius: 6px 6px 6px 6px;border: 1px solid rgb(255,157,78);"
type
=
"warning"
>
录入诊断
<
/el-button
>
<
/template
>
<
/el-table-column
>
<
/el-table
>
<
pagination
v
-
show
=
"total>0"
:
limit
.
sync
=
"queryParams.pageSize"
:
page
.
sync
=
"queryParams.pageNum"
:
total
=
"total"
@
pagination
=
"getList"
/>
<!--
添加或修改挂号对话框
-->
<
el
-
dialog
:
title
=
"title"
:
visible
.
sync
=
"open"
append
-
to
-
body
width
=
"500px"
>
<
el
-
form
ref
=
"form"
:
model
=
"form"
:
rules
=
"rules"
label
-
width
=
"80px"
>
<
el
-
form
-
item
label
=
"宠物id(宠物表主键)"
prop
=
"petId"
>
<
el
-
input
v
-
model
=
"form.petId"
placeholder
=
"请输入宠物id(宠物表主键)"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"宠物昵称"
prop
=
"petNickname"
>
<
el
-
input
v
-
model
=
"form.petNickname"
placeholder
=
"请输入宠物昵称"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"宠物品种"
prop
=
"petBreed"
>
<
el
-
input
v
-
model
=
"form.petBreed"
placeholder
=
"请输入宠物品种"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"宠物年龄"
prop
=
"petAge"
>
<
el
-
input
v
-
model
=
"form.petAge"
placeholder
=
"请输入宠物年龄"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"宠物体重"
prop
=
"petWeight"
>
<
el
-
input
v
-
model
=
"form.petWeight"
placeholder
=
"请输入宠物体重"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"宠物毛色"
prop
=
"petColor"
>
<
el
-
input
v
-
model
=
"form.petColor"
placeholder
=
"请输入宠物毛色"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"疫苗情况(0:当年已接种,1:当年未接种)"
prop
=
"vaccineSituation"
>
<
el
-
input
v
-
model
=
"form.vaccineSituation"
placeholder
=
"请输入疫苗情况(0:当年已接种,1:当年未接种)"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"保险(0:未购保险,1:已购买保险)"
prop
=
"insure"
>
<
el
-
input
v
-
model
=
"form.insure"
placeholder
=
"请输入保险(0:未购保险,1:已购买保险)"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"进度"
prop
=
"checkSchedule"
>
<
el
-
input
v
-
model
=
"form.checkSchedule"
placeholder
=
"请输入进度"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"缴费金额"
prop
=
"payAmount"
>
<
el
-
input
v
-
model
=
"form.payAmount"
placeholder
=
"请输入缴费金额"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"缴费时间"
prop
=
"payTime"
>
<
el
-
date
-
picker
v
-
model
=
"form.payTime"
clearable
placeholder
=
"请选择缴费时间"
type
=
"date"
value
-
format
=
"yyyy-MM-dd"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"主治兽医的id"
prop
=
"doctorId"
>
<
el
-
input
v
-
model
=
"form.doctorId"
placeholder
=
"请输入主治兽医的id"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"主治兽医名称"
prop
=
"doctorName"
>
<
el
-
input
v
-
model
=
"form.doctorName"
placeholder
=
"请输入主治兽医名称"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"主治兽医的所属医院的部门id"
prop
=
"deptId"
>
<
el
-
input
v
-
model
=
"form.deptId"
placeholder
=
"请输入主治兽医的所属医院的部门id"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"主治兽医医院科室的部门id"
prop
=
"departmentId"
>
<
el
-
input
v
-
model
=
"form.departmentId"
placeholder
=
"请输入主治兽医医院科室的部门id"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"主治兽医医院科室名字"
prop
=
"departmentName"
>
<
el
-
input
v
-
model
=
"form.departmentName"
placeholder
=
"请输入主治兽医医院科室名字"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"兽医联系方式"
prop
=
"doctorPhone"
>
<
el
-
input
v
-
model
=
"form.doctorPhone"
placeholder
=
"请输入兽医联系方式"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"就诊方式(0:现场就诊)"
prop
=
"visitWay"
>
<
el
-
input
v
-
model
=
"form.visitWay"
placeholder
=
"请输入就诊方式(0:现场就诊)"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"是否首诊(0:是,1:否)"
prop
=
"firstVisit"
>
<
el
-
input
v
-
model
=
"form.firstVisit"
placeholder
=
"请输入是否首诊(0:是,1:否)"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"就诊日期"
prop
=
"visitDate"
>
<
el
-
date
-
picker
v
-
model
=
"form.visitDate"
clearable
placeholder
=
"请选择就诊日期"
type
=
"date"
value
-
format
=
"yyyy-MM-dd"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"就诊时间段"
prop
=
"visitTime"
>
<
el
-
input
v
-
model
=
"form.visitTime"
placeholder
=
"请输入就诊时间段"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"排班表id"
prop
=
"scheduleId"
>
<
el
-
input
v
-
model
=
"form.scheduleId"
placeholder
=
"请输入排班表id"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"最早就诊时间(就诊日期+就诊时间段开始时间排序用)"
prop
=
"visitFirstTime"
>
<
el
-
date
-
picker
v
-
model
=
"form.visitFirstTime"
clearable
placeholder
=
"请选择最早就诊时间(就诊日期+就诊时间段开始时间排序用)"
type
=
"date"
value
-
format
=
"yyyy-MM-dd"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"删除标志"
prop
=
"delFlag"
>
<
el
-
input
v
-
model
=
"form.delFlag"
placeholder
=
"请输入删除标志"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"备注"
prop
=
"remark"
>
<
el
-
input
v
-
model
=
"form.remark"
placeholder
=
"请输入备注"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"宠物主id(关联)"
prop
=
"petOwnersId"
>
<
el
-
input
v
-
model
=
"form.petOwnersId"
placeholder
=
"请输入宠物主id(关联)"
/>
<
/el-form-item
>
<
/el-form
>
<
div
slot
=
"footer"
class
=
"dialog-footer"
>
<
el
-
button
type
=
"primary"
@
click
=
"submitForm"
>
确
定
<
/el-button
>
<
el
-
button
@
click
=
"cancel"
>
取
消
<
/el-button
>
<
/div
>
<
/el-dialog
>
<
/div
>
<
/div
>
<
/template
>
<
script
>
import
{
listRegister
,
getRegister
,
delRegister
,
addRegister
,
updateRegister
}
from
'@/api/business/register'
import
{
listAllArticle
}
from
'@/api/business/article'
export
default
{
name
:
'RegistrationQueue'
}
</
script
>
name
:
'Register'
,
data
()
{
return
{
// 挂号方式下拉框字典写死
registerTypeList
:
[
{
label
:
'全部'
,
value
:
'0'
}
,
{
label
:
'现场挂号'
,
value
:
'1'
}
,
{
label
:
'预约挂号'
,
value
:
'2'
}
],
// 所属科室下拉框字典写死
departmentList
:
[
{
label
:
'全部'
,
value
:
'0'
}
,
{
label
:
'胸肺科'
,
value
:
'1'
}
,
{
label
:
'呼吸科'
,
value
:
'2'
}
,
{
label
:
'脑科'
,
value
:
'3'
}
],
// 所属科室下拉框字典写死
doctorNameList
:
[
{
label
:
'全部'
,
value
:
'0'
}
,
{
label
:
'李萍'
,
value
:
'1'
}
,
{
label
:
'张毅'
,
value
:
'2'
}
,
{
label
:
'赵萌萌'
,
value
:
'3'
}
],
// 排序方式下拉框字典写死
sortList
:
[
{
label
:
'按挂号时间倒序'
,
value
:
'1'
}
,
{
label
:
'按挂号时间正序'
,
value
:
'2'
}
,
{
label
:
'按就诊时间倒序'
,
value
:
'3'
}
,
{
label
:
'按就诊时间正序'
,
value
:
'4'
}
],
// 遮罩层
loading
:
true
,
// 选中数组
ids
:
[],
// 非单个禁用
single
:
true
,
// 非多个禁用
multiple
:
true
,
// 显示搜索条件
showSearch
:
true
,
// 总条数
total
:
0
,
// 挂号表格数据
registerList
:
[],
// 弹出层标题
title
:
''
,
// 是否显示弹出层
open
:
false
,
// 查询参数
queryParams
:
{
// 排序方式声明
params
:
{
sort
:
null
}
,
pageNum
:
1
,
pageSize
:
10
,
type
:
null
,
petId
:
null
,
petNickname
:
null
,
petBreed
:
null
,
petSex
:
null
,
petAge
:
null
,
petWeight
:
null
,
petColor
:
null
,
sterilizationStatus
:
null
,
vaccineSituation
:
null
,
insure
:
null
,
checkSchedule
:
null
,
payAmount
:
null
,
payType
:
null
,
payTime
:
null
,
doctorId
:
null
,
doctorName
:
null
,
deptId
:
null
,
departmentId
:
null
,
departmentName
:
null
,
doctorPhone
:
null
,
visitWay
:
null
,
firstVisit
:
null
,
visitDate
:
null
,
visitTime
:
null
,
scheduleId
:
null
,
visitFirstTime
:
null
,
payStatus
:
null
,
petOwnersId
:
null
}
,
// 表单参数
form
:
{
}
,
// 表单校验
rules
:
{
}
}
}
,
created
()
{
this
.
getList
()
}
,
methods
:
{
/** 查询挂号列表 */
getList
()
{
this
.
loading
=
true
listRegister
(
this
.
queryParams
).
then
(
response
=>
{
this
.
registerList
=
response
.
rows
this
.
total
=
response
.
total
this
.
loading
=
false
}
)
}
,
// 取消按钮
cancel
()
{
this
.
open
=
false
this
.
reset
()
}
,
// 表单重置
reset
()
{
this
.
form
=
{
id
:
null
,
type
:
null
,
petId
:
null
,
petNickname
:
null
,
petBreed
:
null
,
petSex
:
null
,
petAge
:
null
,
petWeight
:
null
,
petColor
:
null
,
sterilizationStatus
:
null
,
vaccineSituation
:
null
,
insure
:
null
,
checkSchedule
:
null
,
payAmount
:
null
,
payType
:
null
,
payTime
:
null
,
doctorId
:
null
,
doctorName
:
null
,
deptId
:
null
,
departmentId
:
null
,
departmentName
:
null
,
doctorPhone
:
null
,
visitWay
:
null
,
firstVisit
:
null
,
visitDate
:
null
,
visitTime
:
null
,
scheduleId
:
null
,
visitFirstTime
:
null
,
payStatus
:
null
,
delFlag
:
null
,
createBy
:
null
,
createTime
:
null
,
updateBy
:
null
,
updateTime
:
null
,
remark
:
null
,
petOwnersId
:
null
}
this
.
resetForm
(
'form'
)
}
,
/** 搜索按钮操作 */
handleQuery
()
{
this
.
queryParams
.
pageNum
=
1
this
.
getList
()
}
,
/** 重置按钮操作 */
resetQuery
()
{
this
.
resetForm
(
'queryForm'
)
this
.
handleQuery
()
}
,
/** 新增按钮操作 */
handleAdd
()
{
this
.
reset
()
this
.
open
=
true
this
.
title
=
'添加挂号'
}
,
/** 修改按钮操作 */
handleUpdate
(
row
)
{
this
.
reset
()
const
id
=
row
.
id
||
this
.
ids
getRegister
(
id
).
then
(
response
=>
{
this
.
form
=
response
.
data
this
.
open
=
true
this
.
title
=
'修改挂号'
}
)
}
,
/** 提交按钮 */
submitForm
()
{
this
.
$refs
[
'form'
].
validate
(
valid
=>
{
if
(
valid
)
{
if
(
this
.
form
.
id
!=
null
)
{
updateRegister
(
this
.
form
).
then
(
response
=>
{
this
.
$modal
.
msgSuccess
(
'修改成功'
)
this
.
open
=
false
this
.
getList
()
}
)
}
else
{
addRegister
(
this
.
form
).
then
(
response
=>
{
this
.
$modal
.
msgSuccess
(
'新增成功'
)
this
.
open
=
false
this
.
getList
()
}
)
}
}
}
)
}
,
/** 删除按钮操作 */
handleDelete
(
row
)
{
const
ids
=
row
.
id
||
this
.
ids
this
.
$modal
.
confirm
(
'是否确认删除挂号编号为"'
+
ids
+
'"的数据项?'
).
then
(
function
()
{
return
delRegister
(
ids
)
}
).
then
(()
=>
{
this
.
getList
()
this
.
$modal
.
msgSuccess
(
'删除成功'
)
}
).
catch
(()
=>
{
}
)
}
,
<
style
scoped
>
/**
* 全部选择
* @param selection 已选择内容
* @param all 是否永远进行全选操作
*/
async
selectAll
(
selection
=
[],
all
=
true
)
{
// 如果已经全选并且是非一直全选操作则清空选择
if
(
this
.
registerList
.
length
!==
selection
.
length
&&
!
all
)
{
this
.
effectTableSelect
([])
}
else
{
await
this
.
changeTableSelect
()
}
}
,
// 反向选择
reverseSelect
()
{
this
.
changeTableSelect
(
this
.
ids
)
}
,
/**
* 改变table选择项
* @param notIncludeIds 需要排除的id列表
*/
async
changeTableSelect
(
notIncludeIds
=
[])
{
// 获取反选的数据
const
{
data
}
=
await
listAllArticle
({
...
this
.
queryParams
,
params
:
{
notIncludeIds
,
sort
:
this
.
queryParams
.
params
.
sort
}
}
)
this
.
effectTableSelect
(
data
)
}
,
/**
* 控制table的选择项
* @param data
*/
effectTableSelect
(
data
=
[])
{
this
.
$refs
.
table
.
store
.
states
.
selection
=
data
this
.
$refs
.
table
.
store
.
updateSelectionByRowKey
()
this
.
$refs
.
table
.
store
.
updateAllSelected
()
this
.
$refs
.
table
.
$emit
(
'selection-change'
,
data
)
}
,
/** 功能按钮--导出按钮操作 */
handleExport
()
{
console
.
log
(
'queryParams'
,
this
.
queryParams
)
this
.
download
(
'business/register/export'
,
{
...
this
.
queryParams
,
params
:
{
sort
:
this
.
queryParams
.
params
.
sort
,
idList
:
this
.
ids
}
}
,
`register_${new Date().getTime()
}
.xlsx`
)
// 重置选择
.
then
(
_
=>
this
.
effectTableSelect
([]))
}
,
/** 列表区--多选框选中数据 */
handleSelectionChange
(
selection
)
{
this
.
ids
=
selection
.
map
(
item
=>
item
.
id
)
}
,
/** 详情按钮操作--跳转文章详情页 */
handleDetail
(
row
)
{
this
.
reset
()
// TODO: 请清除该行输出
console
.
log
(
`row`
,
row
)
this
.
$router
.
push
({
name
:
'RegistrationDetail'
,
params
:
{
id
:
row
.
id
}
}
)
}
</
style
>
}
}
<
/script
>
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