Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
bims
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
孙海亮
bims
Commits
6ba1d797
Commit
6ba1d797
authored
Jan 05, 2022
by
yanglilong
Browse files
Options
Browse Files
Download
Plain Diff
'修改'
parents
0327141a
21e2ac2a
Changes
15
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
1540 additions
and
135 deletions
+1540
-135
base.js
src/api/apis_moudles/base.js
+7
-2
customer.js
src/api/apis_moudles/customer.js
+3
-0
welfare.js
src/api/apis_moudles/welfare.js
+4
-1
base.js
src/api/funcs_modules/base.js
+39
-3
customer.js
src/api/funcs_modules/customer.js
+22
-2
welfare.js
src/api/funcs_modules/welfare.js
+11
-3
reset.less
src/assets/style/reset.less
+76
-15
index.js
src/components/Antd/index.js
+23
-17
icon.vue
src/components/Icon/icon.vue
+1
-5
welfare.js
src/router/modules/welfare.js
+1
-1
index.vue
src/views/customer/edit/index.vue
+390
-21
index.vue
src/views/customer/info/index.vue
+98
-57
index.vue
src/views/welfare/components/benefits/index.vue
+108
-0
index.vue
src/views/welfare/components/coverages/index.vue
+322
-0
index.vue
src/views/welfare/index.vue
+435
-8
No files found.
src/api/apis_moudles/base.js
View file @
6ba1d797
// 基础api
// 基础api
export
default
{
export
default
{
getUserInfo
:
`/getUserInfo`
,
// getUserInfo: `/getUserInfo`,
corporateCodeList
:
"
/backstage/auth/corporateList
"
,
payorCodeList
:
"
/backstage/auth/payorListNopage
"
,
corporateCodeList
:
"
/backstage/auth/corporateList
"
,
// 根据payorCode查询
planCodeList
:
"
/backstage/auth/planList
"
,
// 根据corporCode查询
uploadImg
:
"
/common/upload
"
,
specialtyList
:
"
/backstage/auth/specialtyList
"
,
coverageCode
:
"
/backstage/auth/coverageMasterList
"
,
};
};
src/api/apis_moudles/customer.js
View file @
6ba1d797
// 客户管理api
// 客户管理api
export
default
{
export
default
{
getCustomerList
:
"
/backstage/auth/patientList
"
,
getCustomerList
:
"
/backstage/auth/patientList
"
,
updateCustomList
:
"
/backstage/auth/updatePatientPolicy
"
,
createCustomer
:
"
/backstage/auth/createPatient
"
,
customerDetail
:
"
/backstage/auth/patientDetail
"
,
};
};
src/api/apis_moudles/welfare.js
View file @
6ba1d797
// 福利管理api
// 福利管理api
export
default
{};
export
default
{
benefitType
:
"
/backstage/auth/benefitMasterList
"
,
coverageList
:
"
/backstage/auth/coverageList
"
,
};
src/api/funcs_modules/base.js
View file @
6ba1d797
...
@@ -8,10 +8,46 @@ const GETUSERINFO = (params) => {
...
@@ -8,10 +8,46 @@ const GETUSERINFO = (params) => {
params
,
params
,
});
});
};
};
// get corporate Code
const
GETCORPORATECODE
=
(
data
)
=>
{
// 保险公司下拉数据
const
GETPAYORCODE
=
(
data
)
=>
{
return
req
.
post
(
apis
.
payorCodeList
,
{
data
,
});
};
// get corporate Code 根据保险公司获取客户公司
const
GETCORPORATECODEBYPAYOR
=
(
data
)
=>
{
return
req
.
post
(
apis
.
corporateCodeList
,
data
);
return
req
.
post
(
apis
.
corporateCodeList
,
data
);
};
};
// get plan Code 根据客户公司获取保险计划
const
GETPLANCODEBYCORP
=
(
data
)
=>
{
return
req
.
post
(
apis
.
planCodeList
,
data
);
};
// 科室信息
const
GETSPECIALTYLIST
=
(
data
)
=>
{
return
req
.
post
(
apis
.
specialtyList
,
data
);
};
// 上传图片
const
UPLOADIMG
=
(
data
)
=>
{
return
req
.
post
(
apis
.
uploadImg
,
data
);
};
// 责任累类型列表
const
GETCOVERAGECODE
=
(
data
)
=>
{
return
req
.
post
(
apis
.
coverageCode
,
data
);
};
// 对象数组
// 对象数组
export
default
{
GETUSERINFO
,
GETCORPORATECODE
};
export
default
{
GETUSERINFO
,
GETPAYORCODE
,
GETCORPORATECODEBYPAYOR
,
GETPLANCODEBYCORP
,
GETSPECIALTYLIST
,
UPLOADIMG
,
GETCOVERAGECODE
,
};
src/api/funcs_modules/customer.js
View file @
6ba1d797
...
@@ -2,9 +2,29 @@
...
@@ -2,9 +2,29 @@
import
apis
from
"
../apis_moudles/
"
;
import
apis
from
"
../apis_moudles/
"
;
import
req
from
"
../request
"
;
import
req
from
"
../request
"
;
//
对象数组
//
get custom list
const
GETCUSTOMERLIST
=
function
(
data
)
{
const
GETCUSTOMERLIST
=
function
(
data
)
{
return
req
.
post
(
apis
.
getCustomerList
,
data
);
return
req
.
post
(
apis
.
getCustomerList
,
data
);
};
};
export
default
{
GETCUSTOMERLIST
};
// get custom detail
const
GETCUSTOMERDETAIL
=
function
(
data
)
{
return
req
.
post
(
apis
.
customerDetail
,
data
);
};
// add or update custom data
const
UPDATECUSTOMDATA
=
function
(
data
)
{
return
req
.
post
(
apis
.
updateCustomList
,
data
);
};
// 创建新用户
const
CREATENEWCUSTOMER
=
function
(
data
)
{
return
req
.
post
(
apis
.
createCustomer
,
data
);
};
export
default
{
GETCUSTOMERLIST
,
GETCUSTOMERDETAIL
,
UPDATECUSTOMDATA
,
CREATENEWCUSTOMER
,
};
src/api/funcs_modules/welfare.js
View file @
6ba1d797
// 福利管理函数库
// 福利管理函数库
// import apis from "../apis_moudles/index";
import
apis
from
"
../apis_moudles/welfare.js
"
;
// import req from "../request";
import
req
from
"
../request
"
;
const
GETBENEGITTYPE
=
()
=>
{
return
req
.
post
(
apis
.
benefitType
);
};
const
GETCOVERAGELIST
=
(
data
)
=>
{
return
req
.
post
(
apis
.
coverageList
,
data
);
};
// 对象数组
// 对象数组
export
default
{};
export
default
{
GETBENEGITTYPE
,
GETCOVERAGELIST
};
src/assets/style/reset.less
View file @
6ba1d797
...
@@ -170,6 +170,13 @@ select {
...
@@ -170,6 +170,13 @@ select {
vertical-align: middle;
vertical-align: middle;
}
}
.success.ant-btn-link {
color: #4cd964;
}
.danger.ant-btn-link {
color: #ff3b30;
}
// 菜单默认样式及激活样式重置
// 菜单默认样式及激活样式重置
.menu {
.menu {
.icon-class {
.icon-class {
...
@@ -244,6 +251,17 @@ select {
...
@@ -244,6 +251,17 @@ select {
// .fs(21);
// .fs(21);
.pa(0, 8, 0, 8)
.pa(0, 8, 0, 8)
}
}
// 编辑的时候字体颜色修改
.ant-input,
.ant-select{
width: 100%;
color: #2B63FF;
}
// 操作栏fixed状态 层级太高会遮住展开的内容
.ant-table-expanded-row{
position: relative;
z-index: 2;
}
}
}
.ant-btn-primary{
.ant-btn-primary{
background-color: #2B63FF;
background-color: #2B63FF;
...
@@ -267,21 +285,64 @@ select {
...
@@ -267,21 +285,64 @@ select {
}
}
}
}
.custom-info {
.ant-pagination {
.ant-pagination-item-active {
.ant-pagination-item-active {
.fs(16);
.fs(16);
border: none;
border: none;
// vertical-align: baseline;
// vertical-align: baseline;
}
.ant-pagination-item-link {
.fs(16);
.lh(22);
.pa(7, 15, 7, 15);
display: inline-block;
background-color: #f8fafb;
border: none;
}
.ant-pagination-item:not(.ant-pagination-item-active) {
display: none;
}
.current-page {
color: #4d7cfe;
}
.size-change {
.w(107);
.mg-l(40);
background-color: #f8fafb;
border: none;
}
}
.ant-radio-group{
.ant-radio-button-wrapper{
.pa(8, 17, 8, 17);
.lh(20);
vertical-align: bottom;
border: none;
border-radius: 4px;
background-color: #F8FAFB;
&:before{
content: none;
}
}
.ant-pagination-item-link {
&:hover{
.fs(16);
color: #2B63FF;
.lh(22);
.pa(7, 15, 7, 15);
display: inline-block;
background-color: #f8fafb;
border: none;
}
}
.ant-pagination-item:not(.ant-pagination-item-active) {
}
display: none;
.ant-radio-button-wrapper-checked{
border: none;
color: #2B63FF;
background-color: #F1F5FF;
&:before{
content: none;
}
}
}
&:hover{
\ No newline at end of file
border: none;
background-color: #F1F5FF;
color: #2B63FF;
}
}
}
.text-r{
text-align: right;
}
\ No newline at end of file
src/components/Antd/index.js
View file @
6ba1d797
import
Vue
from
"
vue
"
;
import
Vue
from
"
vue
"
;
import
{
import
{
Button
,
Input
,
Select
,
DatePicker
,
notification
,
menu
,
dropdown
,
FormModel
,
Row
,
Row
,
Col
,
Col
,
menu
,
dropdown
,
Table
,
Table
,
InputNumber
,
message
,
message
,
pagination
,
pagination
,
FormModel
,
Select
,
DatePicker
,
Input
,
InputNumber
,
Radio
,
upload
,
Button
,
notification
,
popconfirm
,
popconfirm
,
Modal
Modal
modal
,
}
from
"
ant-design-vue
"
;
}
from
"
ant-design-vue
"
;
export
default
()
=>
{
export
default
()
=>
{
let
els
=
[
let
els
=
[
Button
,
Row
,
Input
,
Col
,
notification
,
menu
,
menu
,
dropdown
,
dropdown
,
Table
,
message
,
pagination
,
FormModel
,
FormModel
,
Row
,
Col
,
Select
,
Select
,
DatePicker
,
DatePicker
,
Table
,
Input
,
InputNumber
,
InputNumber
,
message
,
Radio
,
pagination
,
upload
,
Button
,
notification
,
popconfirm
,
popconfirm
,
Modal
Modal
modal
,
];
];
// 注册
// 注册
els
.
forEach
((
item
)
=>
{
els
.
forEach
((
item
)
=>
{
...
...
src/components/Icon/icon.vue
View file @
6ba1d797
<
template
>
<
template
>
<div
<div
class=
"icon-class"
:style=
"`font-size:$
{size}px`" @click="clickEvent">
class=
"icon-class"
:style=
"`font-size:$
{size}px`"
@click.stop="clickEvent"
>
<svg
class=
"icon"
aria-hidden=
"true"
>
<svg
class=
"icon"
aria-hidden=
"true"
>
<use
:xlink:href=
"iconName"
/>
<use
:xlink:href=
"iconName"
/>
</svg>
</svg>
...
...
src/router/modules/welfare.js
View file @
6ba1d797
// 福利管理路由表,分包名称:welfare
// 福利管理路由表,分包名称:welfare
export
default
{
export
default
{
path
:
"
/welfare
"
,
path
:
"
/welfare
"
,
name
:
"
W
elfare
"
,
name
:
"
w
elfare
"
,
component
:
()
=>
{
component
:
()
=>
{
return
import
(
/* webpackChunkName: "Welfare" */
"
@/views/welfare
"
);
return
import
(
/* webpackChunkName: "Welfare" */
"
@/views/welfare
"
);
},
},
...
...
src/views/customer/edit/index.vue
View file @
6ba1d797
This diff is collapsed.
Click to expand it.
src/views/customer/info/index.vue
View file @
6ba1d797
...
@@ -3,12 +3,12 @@
...
@@ -3,12 +3,12 @@
<!-- form -->
<!-- form -->
<a-form-model
ref=
"form"
layout=
"vertical"
:model=
"form"
>
<a-form-model
ref=
"form"
layout=
"vertical"
:model=
"form"
>
<a-row
:gutter=
"30"
>
<a-row
:gutter=
"30"
>
<a-col
:xl=
"
5
"
:lg=
"6"
:sm=
"12"
>
<a-col
:xl=
"
6
"
:lg=
"6"
:sm=
"12"
>
<a-form-model-item
label=
"病历号码"
>
<a-form-model-item
label=
"病历号码"
>
<a-input
v-model=
"form.mrnNo"
placeholder=
"请输入病历号"
></a-input>
<a-input
v-model=
"form.mrnNo"
placeholder=
"请输入病历号"
></a-input>
</a-form-model-item>
</a-form-model-item>
</a-col>
</a-col>
<a-col
:xl=
"
5
"
:lg=
"6"
:sm=
"12"
>
<a-col
:xl=
"
6
"
:lg=
"6"
:sm=
"12"
>
<a-form-model-item
label=
"客户姓名"
>
<a-form-model-item
label=
"客户姓名"
>
<a-input
<a-input
v-model=
"form.patientName"
v-model=
"form.patientName"
...
@@ -24,16 +24,20 @@
...
@@ -24,16 +24,20 @@
></a-date-picker>
></a-date-picker>
</a-form-model-item>
</a-form-model-item>
</a-col>
</a-col>
<a-col
:xl=
"
4
"
:lg=
"6"
:sm=
"12"
>
<a-col
:xl=
"
5
"
:lg=
"6"
:sm=
"12"
>
<a-form-model-item
label=
"保险公司"
>
<a-form-model-item
label=
"保险公司"
>
<a-select
v-model=
"form.payorId"
placeholder=
"请选择保险公司"
>
<a-select
v-model=
"form.payorId"
placeholder=
"请选择保险公司"
>
<a-select-option
v-for=
"item in companyCode"
:key=
"item.corpCode"
>
<a-select-option
v-for=
"item in companyCode"
:key=
"item.corpCode"
:value=
"item.id"
>
{{
item
.
longName
}}
{{
item
.
longName
}}
</a-select-option>
</a-select-option>
</a-select>
</a-select>
</a-form-model-item>
</a-form-model-item>
</a-col>
</a-col>
<a-col
:xl=
"
5
"
:lg=
"6"
:sm=
"12"
>
<a-col
:xl=
"
6
"
:lg=
"6"
:sm=
"12"
>
<a-form-model-item
label=
"保单号码"
>
<a-form-model-item
label=
"保单号码"
>
<a-input
<a-input
v-model=
"form.policyNo"
v-model=
"form.policyNo"
...
@@ -41,13 +45,13 @@
...
@@ -41,13 +45,13 @@
></a-input>
></a-input>
</a-form-model-item>
</a-form-model-item>
</a-col>
</a-col>
<a-col
:xl=
"
24
"
:lg=
"18"
:sm=
"12"
class=
"none-label"
>
<a-col
:xl=
"
18
"
:lg=
"18"
:sm=
"12"
class=
"none-label"
>
<a-form-model-item
label=
"button"
>
<a-form-model-item
label=
"button"
>
<a-button
type=
"primary"
<a-button
type=
"primary"
@
click=
"addNewCustom"
><Icon
name=
"ssiadd"
size=
"14"
/>
新建客户信息
</a-button
><Icon
name=
"ssiadd"
:
size=
"14"
/>
新建客户信息
</a-button
>
>
<a-button
class=
"mar-left10"
type=
"primary"
@
click=
"handlerSearch"
>
<a-button
class=
"mar-left10"
type=
"primary"
@
click=
"handlerSearch"
>
<Icon
name=
"ssisearch_active"
size=
"14"
/>
查询
<Icon
name=
"ssisearch_active"
:
size=
"14"
/>
查询
</a-button>
</a-button>
</a-form-model-item>
</a-form-model-item>
</a-col>
</a-col>
...
@@ -61,10 +65,19 @@
...
@@ -61,10 +65,19 @@
row-key=
"mrnNo"
row-key=
"mrnNo"
:scroll=
"
{ x: true }"
:scroll=
"
{ x: true }"
:pagination="pagination"
:pagination="pagination"
:customRow="handlerRowClick"
@change="onChange"
@change="onChange"
>
>
<template
slot=
"operation"
slot-scope=
""
>
<template
slot=
"operation"
slot-scope=
"record"
>
<a-button
type=
"link"
>
修改
</a-button>
<a-button
v-if=
"record.isEdit"
type=
"link"
@
click.stop=
"saveChange(record)"
>
保存
</a-button
>
<a-button
v-else
type=
"link"
@
click.stop=
"changeDataStatus(record)"
>
修改
</a-button
>
<a-button
type=
"link"
class=
"success"
>
新增
</a-button>
<a-button
type=
"link"
class=
"success"
>
新增
</a-button>
<a-popconfirm
<a-popconfirm
title=
"你确定要关闭吗?"
title=
"你确定要关闭吗?"
...
@@ -83,29 +96,34 @@
...
@@ -83,29 +96,34 @@
export
default
{
export
default
{
data
()
{
data
()
{
const
columns
=
[
const
columns
=
[
{
title
:
"
病历号
"
,
dataIndex
:
"
mrnNo
"
,
ellipsis
:
true
,
width
:
180
},
{
{
title
:
"
客户姓名
"
,
title
:
"
病历号
"
,
dataIndex
:
"
patientName
"
,
dataIndex
:
"
mrnNo
"
,
ellipsis
:
true
,
width
:
120
,
},
{
title
:
"
出生日期
"
,
dataIndex
:
"
birthday
"
,
ellipsis
:
true
,
width
:
180
},
{
title
:
"
性别
"
,
dataIndex
:
"
sex
"
,
ellipsis
:
true
,
width
:
80
},
{
title
:
"
保险公司
"
,
dataIndex
:
"
payorName
"
,
ellipsis
:
true
,
width
:
180
},
{
title
:
"
保单号码
"
,
dataIndex
:
"
policyNo
"
,
ellipsis
:
true
,
width
:
190
},
{
title
:
"
保险有效日期
"
,
dataIndex
:
"
startDate
"
,
ellipsis
:
true
,
width
:
180
,
width
:
180
,
customRender
:
(
val
,
row
)
=>
{
if
(
row
.
isEdit
)
{
return
<
a
-
input
v
-
model
=
{
row
.
mrnNo
}
><
/a-input>
;
}
return
val
;
},
},
},
{
{
title
:
"
保险终止日期
"
,
title
:
"
客户姓名
"
,
dataIndex
:
"
endDate
"
,
dataIndex
:
"
patientName
"
,
ellipsis
:
true
,
width
:
120
,
width
:
180
,
customRender
:
(
val
,
row
)
=>
{
if
(
row
.
isEdit
)
{
return
<
a
-
input
v
-
model
=
{
row
.
patientName
}
><
/a-input>
;
}
return
val
;
},
},
},
{
title
:
"
出生日期
"
,
dataIndex
:
"
birthday
"
,
width
:
180
},
{
title
:
"
性别
"
,
dataIndex
:
"
sex
"
,
width
:
80
},
{
title
:
"
保险公司
"
,
dataIndex
:
"
payorName
"
,
width
:
180
},
{
title
:
"
保单号码
"
,
dataIndex
:
"
policyNo
"
,
width
:
190
},
{
title
:
"
保险有效日期
"
,
dataIndex
:
"
startDate
"
,
width
:
180
},
{
title
:
"
保险终止日期
"
,
dataIndex
:
"
endDate
"
,
width
:
180
},
{
{
title
:
"
操作
"
,
title
:
"
操作
"
,
key
:
"
operation
"
,
key
:
"
operation
"
,
...
@@ -129,13 +147,10 @@ export default {
...
@@ -129,13 +147,10 @@ export default {
},
},
created
()
{
created
()
{
this
.
_getCustomerList
();
this
.
_getCustomerList
();
this
.
_get
Corporate
Code
();
this
.
_get
Payor
Code
();
},
},
computed
:
{
computed
:
{
pagination
()
{
pagination
()
{
// if (!this.pager || !this.dataList.length) {
// return false;
// }
const
{
pageNum
,
pageSize
}
=
this
.
pager
;
const
{
pageNum
,
pageSize
}
=
this
.
pager
;
const
pages
=
Math
.
ceil
(
this
.
total
/
pageSize
);
const
pages
=
Math
.
ceil
(
this
.
total
/
pageSize
);
return
{
return
{
...
@@ -155,8 +170,6 @@ export default {
...
@@ -155,8 +170,6 @@ export default {
if
(
current
!==
pageNum
)
{
if
(
current
!==
pageNum
)
{
return
undefined
;
return
undefined
;
}
}
// originalElement.children = undefined;
// originalElement.text = `${current} / ${pages}`;
return
(
return
(
<
p
>
<
p
>
<
span
class
=
"
current-page
"
>
{
current
}
<
/span> /
{
pages
}
<
span
class
=
"
current-page
"
>
{
current
}
<
/span> /
{
pages
}
...
@@ -178,11 +191,54 @@ export default {
...
@@ -178,11 +191,54 @@ export default {
}
}
return
originalElement
;
return
originalElement
;
},
},
onChange
:
(
pager
)
=>
this
.
onChange
(
pager
),
};
};
},
},
},
},
methods
:
{
methods
:
{
handlerRowClick
(
record
)
{
const
{
id
,
patientPolicyId
}
=
record
;
return
{
style
:
{
color
:
record
.
isEdit
?
"
#2B63FF
"
:
"
#252631
"
,
},
on
:
{
click
:
()
=>
{
if
(
record
.
isEdit
)
{
return
true
;
}
this
.
$router
.
push
({
name
:
"
welfare
"
,
query
:
{
id
,
patientPolicyId
},
});
},
},
};
},
// 修改按钮
changeDataStatus
(
record
)
{
this
.
$set
(
record
,
"
isEdit
"
,
true
);
},
saveChange
(
record
)
{
record
.
isEdit
=
undefined
;
record
.
isNew
=
undefined
;
},
// customDeal(columns) {
// return columns.map((item) => {
// return {
// ...item,
// ellipsis: true,
// customRender: (text, record, index) => {
// const data = item.customRender
// ? item.customRender(text, record, index)
// : text;
// if (record.isEdit) {
// return "";
// }
// return data;
// },
// };
// });
// },
onChange
(
pager
)
{
onChange
(
pager
)
{
const
{
current
}
=
pager
;
const
{
current
}
=
pager
;
// console.log(pager);
// console.log(pager);
...
@@ -212,12 +268,12 @@ export default {
...
@@ -212,12 +268,12 @@ export default {
deleteData
()
{
deleteData
()
{
this
.
$message
.
success
(
"
删除成功
"
);
this
.
$message
.
success
(
"
删除成功
"
);
},
},
_getCorporateCode
()
{
// 新建客户信息
const
params
=
{
addNewCustom
()
{
longName
:
""
,
this
.
$router
.
push
(
"
/customer/edit
"
);
payorId
:
0
,
}
,
};
_getPayorCode
()
{
this
.
$apis
.
GET
CORPORATECODE
(
params
).
then
((
res
)
=>
{
this
.
$apis
.
GET
PAYORCODE
({}
).
then
((
res
)
=>
{
this
.
companyCode
=
res
.
content
||
[];
this
.
companyCode
=
res
.
content
||
[];
});
});
},
},
...
@@ -241,22 +297,7 @@ export default {
...
@@ -241,22 +297,7 @@ export default {
opacity: 0;
opacity: 0;
}
}
}
}
.current-page {
color: #4d7cfe;
}
.size-change {
.w(107);
.mg-l(40);
background-color: #f8fafb;
border: none;
}
.ant-btn .icon-class {
.ant-btn .icon-class {
.mg-r(10);
.mg-r(10);
}
}
.success.ant-btn-link {
color: #4cd964;
}
.danger.ant-btn-link {
color: #ff3b30;
}
</
style
>
</
style
>
src/views/welfare/components/benefits/index.vue
0 → 100644
View file @
6ba1d797
<
template
>
<div
class=
"benefits"
>
<div>
<div
class=
"text-r"
>
<a-button
type=
"danger"
class=
"save-btn"
>
<Icon
name=
"ssiadd"
:size=
"14"
/>
新增
</a-button>
<a-table
:pagination=
"false"
:columns=
"considtionColumns"
:data-source=
"conditionData"
>
<template
slot=
"operation"
slot-scope=
"text, record"
>
<a-button
v-if=
"record.isEdit"
type=
"link"
>
保存
</a-button>
<a-button
v-else
type=
"link"
>
修改
</a-button>
<a-button
type=
"link"
class=
"success"
>
新增
</a-button>
<a-popconfirm
title=
"你确定要关闭吗?"
ok-text=
"确定"
cancel-text=
"取消"
>
<a-button
type=
"link"
class=
"danger"
>
删除
</a-button>
</a-popconfirm>
</
template
>
</a-table>
</div>
</div>
<div>
<div
class=
"text-r"
>
<a-button
type=
"danger"
class=
"save-btn"
>
<Icon
name=
"ssiadd"
:size=
"14"
/>
新增
</a-button>
<a-table
:pagination=
"false"
:columns=
"benefitColumns"
:data-source=
"benefitData"
>
<
template
slot=
"operation"
slot-scope=
"text, record"
>
<a-button
v-if=
"record.isEdit"
type=
"link"
>
保存
</a-button>
<a-button
v-else
type=
"link"
>
修改
</a-button>
<a-button
type=
"link"
class=
"success"
>
新增
</a-button>
<a-popconfirm
title=
"你确定要关闭吗?"
ok-text=
"确定"
cancel-text=
"取消"
>
<a-button
type=
"link"
class=
"danger"
>
删除
</a-button>
</a-popconfirm>
</
template
>
</a-table>
</div>
</div>
</div>
</template>
<
script
>
export
default
{
props
:
{
coverageForm
:
{
type
:
Object
,
required
:
true
,
},
},
data
()
{
const
considtionColumns
=
[
{
title
:
"
限额
"
,
dataIndex
:
"
index
"
},
{
title
:
"
操作
"
,
key
:
"
operation
"
,
width
:
"
175px
"
,
fixed
:
"
right
"
,
scopedSlots
:
{
customRender
:
"
operation
"
},
},
];
const
benefitColumns
=
[
{
title
:
"
责任列表
"
,
dataIndex
:
"
index
"
},
{
title
:
"
操作
"
,
key
:
"
operation
"
,
width
:
"
175px
"
,
fixed
:
"
right
"
,
scopedSlots
:
{
customRender
:
"
operation
"
},
},
];
return
{
considtionColumns
,
benefitColumns
,
conditionData
:
[{
index
:
"
900
"
}],
benefitData
:
[{
index
:
"
测试
"
}],
};
},
methods
:
{},
};
</
script
>
<
style
lang=
"less"
scoped
>
.benefits {
.pa(0, 20, 10, 20);
background-color: #fff;
.save-btn {
.mg-t(20);
.mg-b(10);
.icon-class {
.mg-r(10);
}
}
}
</
style
>
src/views/welfare/components/coverages/index.vue
0 → 100644
View file @
6ba1d797
<
template
>
<div>
<!-- 分类 -->
<div
class=
"classify clearfix"
>
<a-button
:type=
"!type ? 'primary' : ''"
>
全部
</a-button>
<a-button
:type=
"item.code === type ? 'primary' : ''"
v-for=
"item in welfareType"
:key=
"item.code"
>
{{
item
.
name
}}
</a-button>
<div
class=
"save-btn"
>
<a-button
type=
"danger"
@
click=
"addNew"
>
<Icon
name=
"ssiadd"
:size=
"14"
/>
新增
</a-button>
<a-button
type=
"primary"
>
<Icon
name=
"ssidownload"
:size=
"14"
/>
保存
</a-button>
</div>
</div>
<!-- table -->
<a-table
:columns=
"columns"
:data-source=
"dataList"
row-key=
"coverageCode"
:scroll=
"
{ x: true }"
:pagination="pagination"
:expanded-row-keys.sync="expandedRowKeys"
@change="onWelfareChange"
@expand="handleExpand"
>
<template
slot=
"operation"
slot-scope=
"text, record, index"
>
<a-button
v-if=
"record.isEdit"
type=
"link"
@
click.stop=
"saveEditData(record)"
>
保存
</a-button>
<a-button
v-else
type=
"link"
@
click.stop=
"editData(record, index)"
>
修改
</a-button>
<a-button
type=
"link"
class=
"success"
>
新增
</a-button>
<a-popconfirm
title=
"你确定要关闭吗?"
ok-text=
"确定"
cancel-text=
"取消"
@
confirm=
"deleteData(record, index)"
>
<a-button
type=
"link"
class=
"danger"
>
删除
</a-button>
</a-popconfirm>
</
template
>
<
template
slot=
"expandedRowRender"
slot-scope=
"record"
>
<benefits
:coverageForm=
"record"
/>
</
template
>
</a-table>
</div>
</template>
<
script
>
import
benefits
from
"
../benefits
"
;
export
default
{
props
:
{
coverageForm
:
{
type
:
Object
,
required
:
true
,
},
},
components
:
{
benefits
,
},
data
()
{
const
columns
=
[
{
title
:
"
责任项目
"
,
dataIndex
:
"
coverageCode
"
,
width
:
180
,
customRender
:
(
val
,
row
)
=>
{
if
(
row
.
isEdit
)
{
return
(
<
a
-
select
v
-
model
=
{
row
.
coverageCode
}
placeholder
=
"
请选择责任项目
"
show
-
search
allow
-
clear
v
-
on
:
filterOption
=
{
this
.
filterCode
}
>
{
this
.
coverageCode
.
map
((
item
)
=>
{
return
(
<
a
-
select
-
option
value
=
{
item
.
coverageCode
}
>
{
item
.
coverageDesc
}
<
/a-select-option
>
);
})}
<
/a-select
>
);
}
return
val
;
},
},
{
title
:
"
责任项目列表
"
,
dataIndex
:
"
patientName
"
,
width
:
120
},
{
title
:
"
是否直付
"
,
dataIndex
:
"
isdirect
"
,
width
:
180
,
customRender
:
(
val
,
row
)
=>
{
if
(
row
.
isEdit
)
{
return
(
<
a
-
radio
-
group
v
-
model
=
{
row
.
isdirect
}
default
-
value
=
{
row
.
isdirect
}
button
-
style
=
"
solid
"
>
<
a
-
radio
-
button
value
=
"
Y
"
>
是
<
/a-radio-button
>
<
a
-
radio
-
button
class
=
"
mar-left10
"
value
=
"
N
"
>
否
<
/a-radio-button
>
<
/a-radio-group
>
);
}
return
val
;
},
},
{
title
:
"
单位
"
,
dataIndex
:
"
sex
"
,
width
:
80
},
{
title
:
"
年限额
"
,
dataIndex
:
"
payorName
"
,
width
:
180
},
{
title
:
"
剩余额度(¥)
"
,
dataIndex
:
"
policyNo
"
,
width
:
190
},
{
title
:
"
次限额(¥)
"
,
dataIndex
:
"
startDate
"
,
width
:
180
},
// { title: "次免赔额(¥)", dataIndex: "endDate", width: 180 },
// { title: "自付比例", dataIndex: "endDate", width: 180 },
// { title: "备注", dataIndex: "endDate", width: 180 },
{
title
:
"
操作
"
,
key
:
"
operation
"
,
width
:
"
175px
"
,
fixed
:
"
right
"
,
scopedSlots
:
{
customRender
:
"
operation
"
},
},
];
return
{
columns
,
dataList
:
[{
coverageCode
:
22
}],
expandedRowKeys
:
[],
type
:
""
,
welfareType
:
[],
pager
:
{
pageNum
:
1
,
pageSize
:
10
,
},
total
:
0
,
coverageCode
:
[],
};
},
watch
:
{
coverageForm
:
{
deep
:
true
,
handler
:
function
()
{
this
.
type
=
""
;
this
.
_getCoverageList
();
},
},
},
mounted
()
{
this
.
_getSpecialtyCode
();
// this._getCoverageList();
},
computed
:
{
pagination
()
{
return
this
.
initPageConfig
(
{
...
this
.
pager
,
total
:
this
.
total
},
this
.
onWelfareSizeChange
);
},
},
methods
:
{
addNew
()
{
const
item
=
{
isEdit
:
true
,
isNew
:
true
};
this
.
pager
.
pageSize
++
;
this
.
_getCoverageCode
();
// 获取责任项目码表
this
.
dataList
.
unshift
(
item
);
},
editData
(
record
)
{
this
.
_getCoverageCode
();
// 获取责任项目码表
const
{
coverageCode
}
=
record
;
const
index
=
this
.
expandedRowKeys
.
indexOf
(
coverageCode
);
if
(
index
>
-
1
)
{
this
.
expandedRowKeys
.
splice
(
index
,
1
);
}
this
.
$set
(
record
,
"
isEdit
"
,
true
);
},
saveEditData
(
record
)
{
record
.
isEdit
=
undefined
;
},
deleteData
(
record
,
index
)
{
if
(
record
.
isNew
)
{
this
.
dataList
.
splice
(
index
,
1
);
return
true
;
}
this
.
dataList
.
splice
(
index
,
1
);
},
initPageConfig
(
pager
,
sizeChange
)
{
const
{
pageNum
,
pageSize
,
total
}
=
pager
;
const
pages
=
Math
.
ceil
(
total
/
pageSize
);
return
{
current
:
pageNum
,
pageSize
,
size
:
"
large
"
,
position
:
"
bottom
"
,
align
:
"
right
"
,
total
:
this
.
total
,
hideOnSinglePage
:
false
,
itemRender
:
(
current
,
type
,
originalElement
)
=>
{
if
(
type
===
"
prev
"
)
{
originalElement
.
children
=
undefined
;
originalElement
.
text
=
"
上一页
"
;
}
if
(
type
===
"
page
"
)
{
if
(
current
!==
pageNum
)
{
return
undefined
;
}
return
(
<
p
>
<
span
class
=
"
current-page
"
>
{
current
}
<
/span> /
{
pages
}
<
/p
>
);
}
if
(
type
===
"
next
"
)
{
originalElement
.
children
=
undefined
;
originalElement
.
text
=
"
下一页
"
;
return
(
<
div
>
{
originalElement
}
<
a
-
input
-
number
onblur
=
{
sizeChange
}
class
=
"
size-change
"
><
/a-input-number
>
<
/div
>
);
}
return
originalElement
;
},
};
},
onWelfareChange
(
pager
)
{
const
{
current
}
=
pager
;
// console.log(pager);
this
.
pager
.
pageNum
=
current
;
// this._getCustomerList();
},
onWelfareSizeChange
(
e
)
{
e
&&
e
.
stopPropagation
();
const
val
=
e
.
target
.
value
*
1
;
if
(
!
val
||
val
<
0
)
{
return
false
;
}
this
.
pager
.
pageSize
=
val
;
},
// 选择框筛选
filterCode
(
input
,
option
)
{
return
(
option
.
componentOptions
.
children
[
0
].
text
.
toLowerCase
()
.
indexOf
(
input
.
toLowerCase
())
>=
0
);
},
handleExpand
(
expended
,
record
)
{
console
.
log
(
expended
);
if
(
record
.
isEdit
&&
expended
)
{
console
.
log
(
this
.
expandedRowKeys
);
return
false
;
}
},
_getSpecialtyCode
()
{
this
.
$apis
.
GETSPECIALTYLIST
().
then
((
res
)
=>
{
this
.
welfareType
=
res
.
content
||
[];
});
},
_getCoverageList
()
{
const
{
corpCode
,
payorCode
,
planCode
}
=
this
.
coverageForm
;
this
.
$apis
.
GETCOVERAGELIST
({
corpCode
,
payorCode
,
planCode
,
specialtyCode
:
this
.
type
,
})
.
then
((
res
)
=>
{
this
.
dataList
=
res
.
content
||
[];
});
},
_getCoverageCode
()
{
if
(
this
.
coverageCode
&&
this
.
coverageCode
.
length
)
{
return
true
;
}
this
.
$apis
.
GETCOVERAGECODE
().
then
((
res
)
=>
{
this
.
coverageCode
=
res
.
content
||
[];
});
},
},
};
</
script
>
<
style
lang=
"less"
scoped
>
.none-label {
text-align: right;
}
.classify {
.pa(10, 20, 10, 20);
.mg-t(30);
.mg-b(10);
background-color: #f8fafb;
.ant-btn:not(:first-child) {
.mg-l(30);
}
.save-btn {
float: right;
}
}
.icon-class {
.mg-r(10);
}
</
style
>
src/views/welfare/index.vue
View file @
6ba1d797
This diff is collapsed.
Click to expand it.
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