Commit a3600bd5 authored by yanglilong's avatar yanglilong

'修改'

parent cc694ddf
...@@ -23,4 +23,19 @@ ...@@ -23,4 +23,19 @@
.burt-container{ .burt-container{
.pa(30, 36, 50, 39); .pa(30, 36, 50, 39);
} }
.none-label {
text-align: right;
.ant-form-item-label {
opacity: 0;
}
}
.ant-btn .icon-class {
.mg-r(10);
}
.success.ant-btn-link {
color: #4cd964;
}
.danger.ant-btn-link {
color: #ff3b30;
}
</style> </style>
...@@ -3,5 +3,11 @@ export default { ...@@ -3,5 +3,11 @@ export default {
providerDetail: "/backstage/auth/providerDetail", //医疗机构列表 providerDetail: "/backstage/auth/providerDetail", //医疗机构列表
doctorList: "/backstage/auth/doctorList", //医生列表 doctorList: "/backstage/auth/doctorList", //医生列表
doctorDelete: "/backstage/auth/doctorDelete", //删除医生 doctorDelete: "/backstage/auth/doctorDelete", //删除医生
doctorCreate: "/backstage/auth/doctorCreate", //新增医生
doctorUpdate: "/backstage/auth/doctorUpdate", //修改医生 doctorUpdate: "/backstage/auth/doctorUpdate", //修改医生
/*-------------保险公司-----------------*/
payorList: "/backstage/auth/payorList", //保险公司列表
payorUpdate: "/backstage/auth/payorUpdate", //保险公司修改
payorDelete: "/backstage/auth/payorDelete", //保险公司删除
}; };
...@@ -17,15 +17,39 @@ const DOCTORDELETE = (data) => { ...@@ -17,15 +17,39 @@ const DOCTORDELETE = (data) => {
return req.post(apis.doctorDelete, data); return req.post(apis.doctorDelete, data);
}; };
//新增医生
const DOCTORCREATE = (data) => {
return req.post(apis.doctorCreate, data);
};
//修改医生 //修改医生
const DOCTORUPDATE = (data) => { const DOCTORUPDATE = (data) => {
return req.post(apis.doctorUpdate, data); return req.post(apis.doctorUpdate, data);
}; };
/*-------------保险公司-----------------*/
//保险公司列表
const PAYORLIST = (data) => {
return req.post(apis.payorList, data);
};
//保险公司修改
const PAYORUPDATE = (data) => {
return req.post(apis.payorUpdate, data);
};
//保险公司删除
const PAYORDELETE = (data) => {
return req.post(apis.payorDelete, data);
};
// 对象数组 // 对象数组
export default { export default {
PROVIDERDETAIL, PROVIDERDETAIL,
DOCTORLIST, DOCTORLIST,
DOCTORDELETE, DOCTORDELETE,
DOCTORUPDATE DOCTORCREATE,
DOCTORUPDATE,
PAYORLIST,
PAYORUPDATE,
PAYORDELETE
}; };
<template>
<!--分页-->
<div class="flex my-pagination" v-if="pagination.total > pagination.pageSize">
<a-pagination
v-model="pagination.pageNum"
:total="pagination.total"
:page-size="pagination.pageSize"
:item-render="itemRender"
@change="pageChange"
/>
<a-input
v-model.trim="jumpPage"
class="jump-page"
type="number"
:min="0"
@blur="inputPageChange"
/>
</div>
</template>
<script>
export default {
props: {
//分页器
pagination: {
default: {},
},
},
data() {
return {
//跳转到第几页
jumpPage: "",
};
},
methods: {
//自定义分页
itemRender(current, type, originalElement) {
if (type === "prev") {
return <li class="page pre">上一页</li>;
} else if (type === "next") {
return <li class="page next">下一页</li>;
} else if (type === "page") {
//当前页面
if (current == this.pagination.pageNum) {
return (
<div class="cur-page page">
<span class="cur">{current}</span>/
<span class="total">
{Math.ceil(this.pagination.total / this.pagination.pageSize)}
</span>
</div>
);
} else {
return null;
}
} else if (type == "jump-prev") {
return null;
} else if (type == "jump-next") {
return null;
}
return originalElement;
},
//跳转页面
inputPageChange() {
this.jumpPage = parseInt(this.jumpPage);
let pages = Math.ceil(this.pagination.total / this.pagination.pageSize);
this.jumpPage = this.jumpPage < 0 ? 0 : this.jumpPage;
this.jumpPage = this.jumpPage > pages ? pages : this.jumpPage;
this.pagination.pageNum = this.jumpPage;
this.$emit("pageChange");
},
//改变分页
pageChange(pager) {
this.pagination.pageNum = pager;
this.$emit("pageChange");
},
},
};
</script>
<style lang="less" scoped>
.my-pagination {
justify-content: flex-end;
margin-top: 33px;
.page {
width: 80px;
height: 36px;
line-height: 36px;
background: #f8fafb;
font-weight: 400;
color: #252631;
&.cur-page {
background: transparent;
}
span {
font-size: 16px;
font-weight: 400;
&.cur {
color: #4d7cfe;
}
}
}
.jump-page {
width: 80px;
margin-left: 30px;
height: 36px;
text-align: center;
}
}
::v-deep .ant-pagination-jump-prev,
::v-deep .ant-pagination-jump-next {
display: none !important;
}
</style>
<template> <template>
<div class="index"> <div class="white_bg burt-container">
<!-- 保险公司信息 --> <div class="title-div">保险公司信息</div>
保险公司信息 <a-table
:columns="columns"
:data-source="dataList"
:scroll="{ x: 'max-content' }"
:pagination="false"
>
<div
v-for="col in columns"
:slot="col.dataIndex"
slot-scope="text, record, index"
:key="col.dataIndex"
>
<template v-if="col.dataIndex == 'operation'">
<a-button type="link" @click.stop="editEvt(record, index)">{{
record.edit ? "保存" : "修改"
}}</a-button>
<a-button type="link" class="success">新增</a-button>
<a-button type="link" class="danger" @click.stop="delRecord(index)"
>删除</a-button
>
</template>
<template v-else>
<a-input
v-if="record.edit"
placeholder="请输入"
v-model="record[col.dataIndex]"
/>
<span v-else>{{ text }}</span>
</template>
</div>
</a-table>
<!--分页-->
<BurtPagination :pagination="pagination" @pageChange="getData" />
</div> </div>
</template> </template>
<script> <script>
import BurtPagination from "@/components/CUSTOMER/pagation";
const columns = [
{
title: "序号",
dataIndex: "id",
width: 120,
},
{
title: "保险公司名称",
dataIndex: "longName",
ellipsis: true,
scopedSlots: { customRender: "longName" },
width: 130,
},
{
title: "医生英文名",
dataIndex: "englishName",
ellipsis: true,
scopedSlots: { customRender: "englishName" },
width: 105,
},
{
title: "联系电话",
dataIndex: "contactPhone",
ellipsis: true,
width: 125,
},
{
title: "联系地址",
dataIndex: "address",
ellipsis: true,
scopedSlots: { customRender: "address" },
width: 180,
},
{
title: "Protal链接",
dataIndex: "portalUrl",
ellipsis: true,
scopedSlots: { customRender: "portalUrl" },
width: 155,
},
{
title: "联系人",
dataIndex: "contactPerson",
ellipsis: true,
scopedSlots: { customRender: "contactPerson" },
width: 100,
},
{
title: "操作",
dataIndex: "operation",
scopedSlots: { customRender: "operation" },
fixed: "right",
width: "170px",
},
];
export default { export default {
data() { data() {
return {}; return {
columns,
pagination: {
pageNum: 1,
pageSize: 10,
total: 0,
},
dataList: [],
};
},
components: {
BurtPagination,
},
created() {
this.getData();
},
methods: {
//获取列表
getData() {
this.$apis
.PAYORLIST({
pageNum: this.pagination.pageNum,
pageSize: this.pagination.pageSize,
})
.then((res) => {
if (res.returnCode == "0000") {
let content = res.content || {};
this.pagination.total = content.total || 0;
this.dataList = (content.list || []).map((item) => {
return {
...item,
edit: false,
};
});
} else {
this.$message.error(res.returnMsg);
}
});
},
//编辑
editEvt(record, index) {
this.dataList.forEach((item, i) => {
if (index != i) {
item.edit = false;
}
});
record.edit = !record.edit;
//保存
if (!record.edit) {
this.$apis.PAYORUPDATE(record).then((res) => {
if (res.returnCode == "0000") {
this.$message.success("编辑成功");
} else {
this.$message.error(res.returnMsg);
}
});
}
},
//删除
delRecord(index) {
this.$modal.confirm({
title: "删除",
content: "确定删除该条记录?",
okText: "确定",
cancelText: "取消",
onOk: () => {
this.$apis
.PAYORDELETE({
id: this.dataList[index].id,
})
.then((res) => {
if (res.returnCode == "0000") {
this.$message.success("删除成功");
this.dataList.splice(index, 1);
} else {
this.$message.error(res.returnMsg);
}
});
},
});
},
}, },
computed: {},
watch: {},
methods: {},
}; };
</script> </script>
<style lang="less" scoped></style> <style lang="less" scoped>
.title-div {
line-height: 52px;
color: #252631;
font-weight: bold;
}
</style>
<template>
<div class="info-div">
<a-form-model ref="form" layout="vertical">
<a-row :gutter="30">
<a-col :lg="6" :sm="12">
<a-form-model-item label="保险公司名称">
<a-input v-model="detailObj.longName" placeholder="保险公司名称" />
</a-form-model-item>
</a-col>
<a-col :lg="6" :sm="12">
<a-form-model-item label="保险公司英文名称">
<a-input
v-model="detailObj.englishName"
placeholder="保险公司英文名称"
/>
</a-form-model-item>
</a-col>
<a-col :lg="6" :sm="12">
<a-form-model-item label="国家">
<a-input v-model="detailObj.englishName" placeholder="国家" />
</a-form-model-item>
</a-col>
</a-row>
<a-row :gutter="30">
<a-col :lg="3" :sm="12">
<a-form-model-item label="有效">
<a-select v-model="detailObj.payorId" placeholder="请选择">
<a-select-option value="1">待核销</a-select-option>
<a-select-option value="2">已核销</a-select-option>
</a-select>
</a-form-model-item>
</a-col>
<a-col :lg="9" :sm="12">
<a-row :gutter="30">
<a-col :lg="12" :sm="12">
<a-form-model-item label="合同起始日期">
<a-date-picker
v-model="detailObj.businessHours"
format="YYYY年MM月DD日"
placeholder="选择日期"
/>
</a-form-model-item>
</a-col>
<a-col :lg="12" :sm="12">
<a-form-model-item label="合同终止日期">
<a-date-picker
v-model="detailObj.businessHours"
format="YYYY年MM月DD日"
placeholder="选择日期"
/>
</a-form-model-item>
</a-col>
</a-row>
</a-col>
<a-col :lg="10" :sm="12">
<a-form-model-item label="保险公司地址">
<a-input v-model="detailObj.telNo1" placeholder="保险公司地址" />
</a-form-model-item>
</a-col>
<a-col :lg="6" :sm="12">
<a-form-model-item label="网络联系人">
<a-input v-model="detailObj.address" placeholder="请输入联系人" />
</a-form-model-item>
</a-col>
<a-col :lg="8" :sm="12">
<a-form-model-item label="理赔件邮寄地址">
<a-input
v-model="detailObj.englishAddr"
placeholder="理赔件邮寄地址"
/>
</a-form-model-item>
</a-col>
<a-col :lg="4" :sm="12">
<a-form-model-item label="保险公司联系电话">
<a-input
v-model="detailObj.englishAddr"
placeholder="保险公司联系电话"
/>
</a-form-model-item>
</a-col>
<a-col :lg="6" :sm="12">
<a-form-model-item label="客服电话">
<a-input v-model="detailObj.englishAddr" placeholder="客服电话" />
</a-form-model-item>
</a-col>
<a-col :lg="6" :sm="12">
<a-form-model-item label="预授权电话">
<a-input v-model="detailObj.englishAddr" placeholder="预授权电话" />
</a-form-model-item>
</a-col>
<a-col :lg="6" :sm="12">
<a-form-model-item label="保险公司邮件地址">
<a-input
v-model="detailObj.englishAddr"
placeholder="保险公司邮件地址"
/>
</a-form-model-item>
</a-col>
<a-col :lg="6" :sm="12">
<a-form-model-item label="客服邮件地址">
<a-input
v-model="detailObj.englishAddr"
placeholder="客服邮件地址"
/>
</a-form-model-item>
</a-col>
<a-col :lg="6" :sm="12">
<a-form-model-item label="预授权邮件地址">
<a-input
v-model="detailObj.englishAddr"
placeholder="预授权邮件地址"
/>
</a-form-model-item>
</a-col>
<a-col :lg="6" :sm="12">
<a-form-model-item label="理赔邮件地址">
<a-input
v-model="detailObj.englishAddr"
placeholder="理赔邮件地址"
/>
</a-form-model-item>
</a-col>
<a-col :lg="8" :sm="12">
<a-form-model-item label="保险公司Protal链接">
<a-input
v-model="detailObj.englishAddr"
placeholder="保险公司Protal链接"
/>
</a-form-model-item>
</a-col>
<a-col :lg="4" :sm="12">
<a-form-model-item label="登录名">
<a-input v-model="detailObj.englishAddr" placeholder="登录名" />
</a-form-model-item>
</a-col>
<a-col :lg="6" :sm="12">
<a-form-model-item label="密码">
<a-input v-model="detailObj.englishAddr" placeholder="密码" />
</a-form-model-item>
</a-col>
</a-row>
</a-form-model>
</div>
</template>
<script>
export default {
data() {},
methods: {
//获取详细信息
getDetail() {
return new Promise((resolve, reject) => {
this.$apis.DOCTORUPDATE().then((res) => {
if (res.returnCode == "0000") {
this.detailObj = res.content || {};
resolve();
} else {
this.$message.error(res.returnMsg);
reject();
}
});
});
},
},
};
</script>
...@@ -130,7 +130,7 @@ ...@@ -130,7 +130,7 @@
<a-table <a-table
:columns="columns" :columns="columns"
:data-source="dataList" :data-source="dataList"
:scroll="{ x: true }" :scroll="{ x: 'max-content' }"
:pagination="false" :pagination="false"
> >
<template slot="specialtyList" slot-scope="text, record"> <template slot="specialtyList" slot-scope="text, record">
...@@ -160,29 +160,12 @@ ...@@ -160,29 +160,12 @@
</template> </template>
</a-table> </a-table>
<!--分页--> <!--分页-->
<div <BurtPagination :pagination="pagination" @pageChange="getDoctorList" />
class="flex my-pagination"
v-if="pagination.total > pagination.pageSize"
>
<a-pagination
v-model="pagination.pageNum"
:total="pagination.total"
:page-size="pagination.pageSize"
:item-render="itemRender"
@change="pageChange"
/>
<a-input
v-model.trim="jumpPage"
class="jump-page"
type="number"
:min="0"
@blur="inputPageChange"
/>
</div>
</div> </div>
</template> </template>
<script> <script>
import BurtPagination from "@/components/CUSTOMER/pagation";
const columns = [ const columns = [
{ title: "序号", dataIndex: "id", ellipsis: true, width: 150 }, { title: "序号", dataIndex: "id", ellipsis: true, width: 150 },
{ title: "工号", dataIndex: "doctorCode", ellipsis: true, width: 95 }, { title: "工号", dataIndex: "doctorCode", ellipsis: true, width: 95 },
...@@ -224,63 +207,27 @@ export default { ...@@ -224,63 +207,27 @@ export default {
pagination: { pagination: {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
total: 100, total: 0,
}, },
jumpPage: "",
specialtyList: [], //科室列表 specialtyList: [], //科室列表
specialtyObj: {}, //科室对象 specialtyObj: {}, //科室对象
}; };
}, },
components: {
BurtPagination,
},
async created() { async created() {
this.getSpecialtyList(); this.getSpecialtyList();
await this.getDetail(); await this.getDetail();
this.getDoctorList(); this.getDoctorList();
}, },
methods: { methods: {
itemRender(current, type, originalElement) {
if (type === "prev") {
return <li class="page pre">上一页</li>;
} else if (type === "next") {
return <li class="page next">下一页</li>;
} else if (type === "page") {
//当前页面
if (current == this.pagination.pageNum) {
return (
<div class="cur-page page">
<span class="cur">{current}</span>/
<span class="total">
{Math.ceil(this.pagination.total / this.pagination.pageSize)}
</span>
</div>
);
} else {
return null;
}
} else if (type == "jump-prev") {
return null;
} else if (type == "jump-next") {
return null;
}
return originalElement;
},
filterSpecialty(val) { filterSpecialty(val) {
let txt = (val || []).map((item) => { let txt = (val || []).map((item) => {
return this.specialtyObj[item] || ""; return this.specialtyObj[item] || "";
}); });
return txt.join(","); return txt.join(",");
}, },
inputPageChange() {
this.jumpPage = parseInt(this.jumpPage);
let pages = Math.ceil(this.pagination.total / this.pagination.pageSize);
this.jumpPage = this.jumpPage < 0 ? 0 : this.jumpPage;
this.jumpPage = this.jumpPage > pages ? pages : this.jumpPage;
this.pagination.pageNum = this.jumpPage;
this.getDoctorList();
},
pageChange(pager) {
this.pagination.pageNum = pager;
this.getDoctorList();
},
handlerSearch() { handlerSearch() {
this.pagination.pageNum = 1; this.pagination.pageNum = 1;
this.getData(); this.getData();
...@@ -400,21 +347,6 @@ export default { ...@@ -400,21 +347,6 @@ export default {
.ant-form { .ant-form {
margin-top: 30px; margin-top: 30px;
} }
.none-label {
text-align: right;
.ant-form-item-label {
opacity: 0;
}
}
.ant-btn .icon-class {
.mg-r(10);
}
.success.ant-btn-link {
color: #4cd964;
}
.danger.ant-btn-link {
color: #ff3b30;
}
.title-div { .title-div {
line-height: 56px; line-height: 56px;
color: #252631; color: #252631;
...@@ -427,36 +359,4 @@ export default { ...@@ -427,36 +359,4 @@ export default {
padding-left: 20px; padding-left: 20px;
margin-bottom: 30px; margin-bottom: 30px;
} }
.my-pagination {
justify-content: flex-end;
margin-top: 33px;
.page {
width: 80px;
height: 36px;
line-height: 36px;
background: #f8fafb;
font-weight: 400;
color: #252631;
&.cur-page {
background: transparent;
}
span {
font-size: 16px;
font-weight: 400;
&.cur {
color: #4d7cfe;
}
}
}
.jump-page {
width: 80px;
margin-left: 30px;
height: 36px;
text-align: center;
}
}
::v-deep .ant-pagination-jump-prev,
::v-deep .ant-pagination-jump-next {
display: none !important;
}
</style> </style>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment