pengjun 2 months ago
parent
commit
80efb56227
  1. 737
      src/components/patientRegister/PatientRegisterMedicalList.vue
  2. 8
      src/components/patientRegister/PatientRegisterRefuseList.vue
  3. 6
      src/router/index.js
  4. 150
      src/views/customerOrg/patientRegisterMedical.vue

737
src/components/patientRegister/PatientRegisterMedicalList.vue

@ -0,0 +1,737 @@
<template>
<div style="display: flex">
<div :style="'display: flex;width:' + (window.pageWidth - 110 - 10) + 'px;'">
<div
:style="'padding: 15px;background-color: #fff;border-radius: 8px;width:' + Math.floor((window.pageWidth - 110 - 50) / 2) + 'px;'">
<u-table :data="tableData" :height="window.pageHeight < 600 ? 350 : window.pageHeight - 245" row-key="id"
size="small" highlight-current-row ref="tableData" @row-click="rowClick" @table-body-scroll="scrollFull"
use-virtual :row-height="25">
<u-table-column type="index" width="50" label="序号" />
<u-table-column prop="completeFlag" label="体检进度" align="center">
<template slot-scope="scope">
<div :style="`color: ${setPrStatusColor(scope.row.isAudit, scope.row.completeFlag)}`">
{{ dddw(dict.completeFlag, "id", scope.row.completeFlag, "displayName") }}
</div>
</template>
</u-table-column>
<u-table-column prop="isLock" label="锁住" width="50">
<template slot-scope="scope">
<div>{{ scope.row.isLock == "Y" ? "是" : "否" }}</div>
</template>
</u-table-column>
<u-table-column prop="customerOrgParentName" label="单位" width="180">
<template slot-scope="scope">
<div>
{{ scope.row.customerOrgParentName ? scope.row.customerOrgParentName : scope.row.customerOrgName }}
</div>
</template>
</u-table-column>
<u-table-column prop="customerOrgName" label="部门" width="180">
<template slot-scope="scope">
<div>
{{ scope.row.customerOrgParentName ? scope.row.customerOrgName : "" }}
</div>
</template>
</u-table-column>
<u-table-column prop="patientName" label="姓名" />
<u-table-column prop="sexId" label="性别">
<template slot-scope="scope">
<div>
{{ dddw(dict.sex, "id", scope.row.sexId, "displayName") }}
</div>
</template>
</u-table-column>
<u-table-column prop="age" label="年龄" />
<u-table-column prop="patientRegisterNo" label="条码号" width="150" />
<u-table-column prop="patientNo" label="档案号" />
<u-table-column prop="medicalTimes" label="体检次数"></u-table-column>
<u-table-column label="分组/套餐" width="150">
<template slot-scope="scope">
<div v-if="scope.row.medicalPackageId !== dict.personOrgId &&
scope.row.customerOrgId === dict.personOrgId
">
{{ dddw(dict.medicalPackage, "id", scope.row.medicalPackageId, "displayName") }}
</div>
<div v-if="scope.row.medicalPackageId !== dict.personOrgId &&
scope.row.customerOrgId !== dict.personOrgId
">
{{ dddw(dict.customerOrgGroupAll, "id", scope.row.customerOrgGroupId, "displayName") }}
</div>
</template>
</u-table-column>
<u-table-column prop="nationId" label="民族">
<template slot-scope="scope">
<div>
{{ dddw(dict.nation, "id", scope.row.nationId, "displayName") }}
</div>
</template>
</u-table-column>
<u-table-column prop="idNo" label="身份证" width="150" />
<u-table-column prop="birthDate" label="出生日期" width="100">
<template slot-scope="scope">
<div v-if="scope.row.birthDate">
{{ lmoment(scope.row.birthDate, "yyyy-MM-DD") }}
</div>
</template>
</u-table-column>
<u-table-column prop="email" label="邮箱" width="100" />
<u-table-column prop="mobileTelephone" label="手机" width="100" />
<u-table-column prop="telephone" label="电话" width="100" />
<u-table-column prop="address" label="地址" width="300" />
<u-table-column prop="medicalCardNo" label="体检卡号" />
<u-table-column prop="jobCardNo" label="工卡号" />
<u-table-column prop="maritalStatusId" label="婚姻状况">
<template slot-scope="scope">
<div>
{{ dddw(dict.maritalStatus, "id", scope.row.maritalStatusId, "displayName") }}
</div>
</template>
</u-table-column>
<u-table-column prop="medicalTypeId" label="体检类别">
<template slot-scope="scope">
<div v-if="scope.row.medicalTypeId !== dict.personOrgId">
{{ dddw(dict.medicalType, "id", scope.row.medicalTypeId, "displayName") }}
</div>
</template>
</u-table-column>
<u-table-column prop="personnelTypeId" label="人员类别">
<template slot-scope="scope">
<div v-if="scope.row.personnelTypeId !== dict.personOrgId">
{{ dddw(dict.personnelType, "id", scope.row.personnelTypeId, "displayName") }}
</div>
</template>
</u-table-column>
<u-table-column prop="jobPost" label="职务" />
<u-table-column prop="jobTitle" label="职称" />
<u-table-column prop="salesman" label="介绍人" />
<u-table-column prop="isVip" label="是否VIP">
<template slot-scope="scope">
<div>{{ scope.row.isVip == "Y" ? "是" : "否" }}</div>
</template>
</u-table-column>
<u-table-column prop="creatorName" label="登记人" />
<u-table-column prop="creationTime" label="登记日期" width="100">
<template slot-scope="scope">
<div>{{ lmoment(scope.row.creationTime, "yyyy-MM-DD") }}</div>
</template>
</u-table-column>
<u-table-column prop="isUpload" label="是否上传">
<template slot-scope="scope">
<div>{{ scope.row.isUpload == "Y" ? "是" : "否" }}</div>
</template>
</u-table-column>
</u-table>
</div>
<div :style="'margin-left: 15px;width:' + Math.floor((window.pageWidth - 170) / 2) + 'px;'">
<div style="padding: 15px;background-color: #fff;border-radius: 8px;">
<u-table :data="registerCheckDatas" row-key="id"
:height="window.pageHeight < 600 ? 350 : window.pageHeight - 245" highlight-current-row size="small">
<u-table-column type="index" width="50" label="序号" align="center" />
<u-table-column prop="asbitemName" label="组合项目" min-width="200" />
<u-table-column prop="medicalCenterId" label="体检中心" min-width="200" align="center">
<template slot-scope="scope">
<el-select v-model="scope.row.medicalCenterId" placeholder="请选择" size="small" >
<el-option v-for="item in organizationUnitdata" :key="item.id" :label="item.displayName"
:value="item.id">
</el-option>
</el-select>
</template>
</u-table-column>
<!--
<u-table-column prop="lastModifierName" label="操作员" width="100" align="center" />
<u-table-column prop="lastModificationTime" label="操作时间" width="140" align="center">
<template slot-scope="scope">
<div>
{{
lmoment(scope.row.lastModificationTime, "yyyy-MM-DD HH:mm:ss")
}}
</div>
</template>
</u-table-column>
-->
</u-table>
</div>
</div>
</div>
<div style="margin-left: 10px;margin-top: 60px; width: 100px">
<div class="listBtn">
<el-button type="success" class="commonbutton" @click="updateMedical">确定</el-button>
</div>
</div>
</div>
</template>
<script>
import moment from "moment";
import { mapState, mapActions } from "vuex";
import { getapi, postapi, putapi, deletapi } from "@/api/api";
import { dddw, objCopy, arrayReduce, setCheckStatusColor, setPrStatusColor } from "@/utlis/proFunc";
import PatientRegisterEdit from "../../components/patientRegister/PatientRegisterEdit.vue";
import Camera from "../../components/patientRegister/Camera.vue";
import { UTable, UTableColumn } from "umy-ui";
export default {
components: {
PatientRegisterEdit,
Camera, UTable, UTableColumn
},
props: ["refQueryCondition"],
data() {
return {
tableData: [], //
registerCheckDatas: [], //
quick: {
id: "",
patientRegisterNo: "",
patientNo: "",
patientName: "",
},
patient_register_query_idno: 'Y', //
patient_register_query_name: 'N', //
patient_register_read_idno_upPhoto: 'N', //
LocalConfig: {
normal: {
maxResultCount: 100, //
},
},
loadOpts: {
totalCount: 0,
skipCount: 0,
maxResultCount: 100,
},
loadOptsInit: {},
};
},
created() {
try {
let LocalConfig = JSON.parse(window.localStorage.getItem("LocalConfig") || null)
if (LocalConfig?.normal?.maxResultCount) {
this.LocalConfig.normal.maxResultCount = LocalConfig.normal.maxResultCount
}
} catch (error) {
console.log('window.localStorage.getItem("LocalConfig")', error);
}
// console.log('this.LocalConfig',this.LocalConfig)
this.loadOpts.maxResultCount = Number(
this.LocalConfig.normal.maxResultCount || 100
);
this.loadOptsInit = Object.assign({}, this.loadOpts);
// --
postapi("/api/app/SysParmValue/GetSysParmValueBySysParmId",
{ sysParmId: "patient_register_query_idno" }
).then((res) => {
if (res.code > -1) {
this.patient_register_query_idno = res.data || "Y";
}
});
// --
postapi("/api/app/SysParmValue/GetSysParmValueBySysParmId",
{ sysParmId: "patient_register_query_name" }
).then((res) => {
if (res.code > -1) {
this.patient_register_query_name = res.data || "N";
}
});
// --
postapi("/api/app/SysParmValue/GetSysParmValueBySysParmId",
{ sysParmId: "patient_register_read_idno_upPhoto" }
).then((res) => {
if (res.code > -1) {
this.patient_register_read_idno_upPhoto = res.data || "N";
}
});
//
getapi("/api/app/organization-units/by-code-all").then((res) => {
if (res.code != -1) {
this.organizationUnitdata = res.data;
}
});
},
//
mounted() {
this.tableData = []
this.registerCheckDatas = []
},
computed: {
...mapState([
"window",
"dict",
"patientRegister",
"customerOrg"
]),
},
methods: {
...mapActions(["getCustomerOrgGroup", "getPatientRegisterAbs"]), dddw, setCheckStatusColor, setPrStatusColor,
rowClick(row) {
objCopy(row, this.quick);
this.registerCheckList(row.id);
},
//
onQueryByPatientRegisterNo() {
let patientRegisterNo = this.quick.patientRegisterNo;
let body = {
sType: 1,
patientRegisterNo
}
console.log('/api/app/patientregister/getpatientregisterorpatient', body)
postapi('/api/app/patientregister/getpatientregisterorpatient', body).then((res) => {
if (res.code != -1) {
if (res.data) {
objCopy(res.data, this.quick);
this.registerCheckList(res.data.id);
} else {
this.quick.patientNo = "";
this.quick.patientName = "";
}
}
});
},
//
onQueryByPatientNo() {
let patientNo = this.quick.patientNo;
let body = {
sType: 2,
patientNo
}
console.log(`/api/app/patientregister/getpatientregisterorpatient`, body)
postapi('/api/app/patientregister/getpatientregisterorpatient', body).then((res) => {
if (res.code != -1) {
if (res.data) {
objCopy(res.data, this.quick);
this.registerCheckList(res.data.id);
} else {
this.quick.patientRegisterNo = "";
this.quick.patientName = "";
}
}
});
},
//
registerCheckList(patientRegisterId) {
this.registerCheckDatas = []
if (!patientRegisterId) return
postapi('/api/app/RegisterCheckAsbitem/GetRegisterCheckAsbitemWithMedicalCenter', { patientRegisterId })
.then((res) => {
console.log("registerCheckList", res.data);
if (res.code != -1) {
this.registerCheckDatas = res.data;
}
})
.catch((err) => {
this.$message.error({ showClose: true, message: `操作失败,原因:${err}` });
});
},
// [
// {
// "registerCheckId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
// "completeFlag": "0"
// }
// ]
resuseCore(body) {
postapi(`/api/app/registercheck/updatecompletemany`, body)
.then((res) => {
if (res.code != -1) {
console.log("操作成功");
this.registerCheckList(this.quick.id);
}
})
;
},
//
resuseCheck(completeFlag) {
let resuseAsb = "",
finishAsb = "",
chargeAsb = "",
msg = "";
let ret = {
allowable: true,
msg: "",
};
if (!this.multipleSelection || this.multipleSelection.length < 1)
return { allowable: false, msg: "请选择组合项目,再进行此操作" };
for (let i = 0; i < this.multipleSelection.length; i++) {
if (this.multipleSelection[i].completeFlag == completeFlag) {
resuseAsb += "," + this.multipleSelection[i].asbitemName;
this.multipleSelection.splice(i, 1);
i--;
continue;
}
if (this.multipleSelection[i].completeFlag == "1") {
finishAsb += "," + this.multipleSelection[i].asbitemName;
this.multipleSelection.splice(i, 1);
i--;
continue;
}
//
// if (this.multipleSelection[i].isCharge == "Y") {
// chargeAsb += "" + this.multipleSelection[i].asbitemName;
// this.multipleSelection.splice(i, 1);
// i--;
// continue;
// }
}
// if (chargeAsb) {
// msg +=
// "\r\n" +
// chargeAsb.substring(1, chargeAsb.length) +
// "";
// }
if (finishAsb) {
msg +=
"\r\n已检组合项目:【" +
finishAsb.substring(1, finishAsb.length) +
"】";
}
if (msg) {
msg += "\r\n不可执行此操作!";
}
if (resuseAsb) {
msg +=
"\r\n组合项目:【" +
resuseAsb.substring(1, resuseAsb.length) +
`${completeFlag == "2" ? "已登记弃检" : "未登记弃检"
}无需再执行此操作`;
}
ret.msg = msg;
if (this.multipleSelection.length < 1) ret.allowable = false;
return ret;
},
//
updateMedical() {
if (this.registerCheckDatas.length == 0) return
//console.log('this.registerCheckDatas',this.registerCheckDatas)
postapi('/api/app/RegisterCheckAsbitem/HandRegisterCheckAsbitemMedicalCenter', this.registerCheckDatas)
.then(res => {
if (res.code > -1) this.$message.success({ showClose: true, message: '操作成功!' })
})
},
lmoment(date, forMat) {
return moment(new Date(date)).format(forMat);
},
//
async Query() {
//
this.tableDataCurrentRow = {}; //
if (
!(
this.patientRegister.query.isSeries == "Y" &&
this.patientRegister.query.patientRegisterNo
)
) {
this.tableData = [];
}
this.loadOpts = Object.assign(this.loadOpts, this.loadOptsInit);
await this.getPrList();
},
//
async load() {
this.loadOpts.skipCount++;
await this.getPrList();
this.lazyLoading = false
},
//
async getPrList() {
if (
this.loadOpts.skipCount != 0 &&
this.loadOpts.skipCount * this.loadOpts.maxResultCount >=
this.loadOpts.totalCount
)
return;
// console.log('getPrList', this.loadOpts)
let body = Object.assign({}, this.loadOpts)
let queryType = this.refQueryCondition.queryType
console.log('getPrList.this.refQueryCondition', this.refQueryCondition)
// ===================== Start ==========================
if (!queryType) {
// --
if (this.refQueryCondition.startDate && this.refQueryCondition.endDate) {
body.dateType = this.refQueryCondition.dateType;
body.startDate = this.refQueryCondition.startDate
body.endDate = this.refQueryCondition.endDate
if (body.startDate > body.endDate) {
this.$message.warning({
showClose: true,
message: "起始日期不能大于截止日期,数据校验不通过!",
});
return;
}
}
// --
if (this.refQueryCondition.customerOrgFlag) {
if (this.refQueryCondition.customerOrgId) body.customerOrgId = this.refQueryCondition.customerOrgId
//
try {
if (
this.refQueryCondition.customerOrgId &&
this.refQueryCondition.customerOrgId != this.dict.personOrgId &&
this.refQueryCondition.customerOrgRegister.id
) {
body.customerOrgRegisterId = this.refQueryCondition.customerOrgRegister.id;
if (this.refQueryCondition.customerOrgGroupIds) body.customerOrgGroupIds = this.refQueryCondition.customerOrgGroupIds
}
} catch (error) {
console.error(error);
}
}
//
if (this.refQueryCondition.phone) body.phone = this.refQueryCondition.phone
//
if (this.refQueryCondition.sexId) body.sexId = this.refQueryCondition.sexId
//
if (this.refQueryCondition.medicalTypeIds) body.medicalTypeIds = this.refQueryCondition.medicalTypeIds
//
if (this.refQueryCondition.completeFlags) body.completeFlags = this.refQueryCondition.completeFlags
//
if (this.refQueryCondition.personnelTypeIds) body.personnelTypeIds = this.refQueryCondition.personnelTypeIds
//
if (this.refQueryCondition.isRecoverGuide) body.isRecoverGuide = this.refQueryCondition.isRecoverGuide
//
if (this.refQueryCondition.patientRegisterNo) {
queryType = "patientRegisterNo"
} else if (this.refQueryCondition.pacsNo) {
queryType = "pacsNo"
} else if (this.refQueryCondition.lisNo) {
queryType = "lisNo"
} else if (this.refQueryCondition.patientNo) {
queryType = "patientNo"
} else if (this.refQueryCondition.idCardNo) {
queryType = "idCardNo"
} else if (this.refQueryCondition.patientName) {
queryType = "patientName"
}
}
// ===================== End ==========================
//
let photo = ''
switch (queryType) {
case 'patientName': //
if (this.refQueryCondition.patientName) {
body.patientName = this.refQueryCondition.patientName;
if (this.patient_register_query_name == 'Y') {
body = {
patientName: this.refQueryCondition.patientName,
skipCount: this.loadOpts.skipCount,
maxResultCount: this.loadOpts.maxResultCount,
};
}
}
break;
case 'idCardNo': //
if (this.refQueryCondition.idCardNo) {
body.idNo = this.refQueryCondition.idCardNo;
if (this.patient_register_query_idno == 'Y') {
body = {
idNo: this.refQueryCondition.idCardNo,
skipCount: this.loadOpts.skipCount,
maxResultCount: this.loadOpts.maxResultCount,
};
}
}
if (this.refQueryCondition.photo) photo = this.refQueryCondition.photo;
break;
case 'patientNo': //
if (this.refQueryCondition.patientNo)
body = {
patientNo: this.refQueryCondition.patientNo,
skipCount: this.loadOpts.skipCount,
maxResultCount: this.loadOpts.maxResultCount,
};
break;
case 'patientRegisterNo': //
if (this.refQueryCondition.patientRegisterNo)
body = {
patientRegisterNo: this.refQueryCondition.patientRegisterNo,
skipCount: this.loadOpts.skipCount,
maxResultCount: this.loadOpts.maxResultCount,
};
break;
case 'pacsNo': //
if (this.refQueryCondition.pacsNo)
body = {
pacsNo: this.refQueryCondition.pacsNo,
skipCount: this.loadOpts.skipCount,
maxResultCount: this.loadOpts.maxResultCount,
};
break;
case 'lisNo': //
if (this.refQueryCondition.lisNo)
body = {
lisNo: this.refQueryCondition.lisNo,
skipCount: this.loadOpts.skipCount,
maxResultCount: this.loadOpts.maxResultCount,
};
break;
default: //
break;
}
// /api/app/PatientRegister/GetPatientRegisterWithCharge
// /api/app/patientregister/getlistinfilter
postapi(
"/api/app/patientregister/getlistinfilter",
body
).then(async (res) => {
if (res.code > -1) {
//
this.loadOpts.totalCount = res.data.totalCount;
let curLoad = res.data.items;
// let oldCount = 0
//
// 1/
// 2()
curLoad.forEach((e) => {
// 1/
if (e.customerOrgId == this.dict.personOrgId) {
e.groupPack = e.medicalPackageId;
} else {
e.groupPack = e.customerOrgGroupId;
}
// 2()
if (this.patient_register_read_idno_upPhoto == "Y" && photo) {
if (!e.photo) {
savePeoplePhoto(e.id, photo);
}
}
});
// ()
// console.log("this.refQueryCondition", this.refQueryCondition.isSeries, this.refQueryCondition.patientRegisterNo);
if (this.refQueryCondition.isSeries == "Y" && this.refQueryCondition.patientRegisterNo) {
//
for (let index = curLoad.length - 1; index > -1; index--) {
const e = curLoad[index];
if (arrayExistObj(this.tableData, 'id', e.id) > -1) curLoad.splice(index, 1)
}
} else {
if (body.skipCount == 0) {
//
this.tableData = [];
}
}
this.tableData = this.tableData.concat(curLoad);
// else {
// // ,
// oldCount = this.tableData.length
// }
// curLoad.forEach((e, index) => {
// this.tableData.push(Object.assign({ index: Number(oldCount) + Number(index), choosed: false }, e))
// })
}
});
},
//
async scrollFull(scroll, event) {
if (!scroll.judgeFlse) return;
//
if (this.lazyLoading) return;
if (
(Number(this.loadOpts.skipCount) + 1) *
Number(this.loadOpts.maxResultCount) >=
Number(this.loadOpts.totalCount)
) {
return;
}
this.lazyLoading = true;
try {
await this.load();
} catch (e) {
console.error('scrollFull load error', e);
}
// this.dom = this.$refs['tableData'].bodyWrapper
// console.log('obj', this.dom)
// this.dom.addEventListener('scroll', async () => {
// // console.log('scrollTop',this.dom.scrollTop,'clientHeight',this.dom.clientHeight,'scrollHeight',this.dom.scrollHeight);
// if (this.dom.scrollTop + this.dom.clientHeight + 20 > this.dom.scrollHeight && !this.lazyLoading) {
// //
// //console.log('scrollTop', obj.scrollTop, 'clientHeight', obj.clientHeight, 'scrollHeight', obj.scrollHeight);
// if (Number(this.loadOpts.skipCount) * Number(this.loadOpts.maxResultCount) >= Number(this.loadOpts.totalCount)) {
// this.lazyLoading = false
// } else {
// this.lazyLoading = true
// this.load()
// // this.dom.scrollTop = this.dom.scrollTop - 100
// }
// }
// })
},
},
//
watch: {
//
"refQueryCondition.queryConditionTimes"(newVal, oldVal) {
if (newVal != oldVal) {
console.log('弃检--触发查询 refQueryCondition.queryConditionTimes', oldVal, newVal)
this.Query();
}
},
},
};
</script>
<style scoped>
.box {
display: flex;
}
.query {
margin-left: 10px;
}
.listBtn {
margin-top: 10px;
text-align: center;
}
.btnClass {
width: 100px;
}
</style>

8
src/components/patientRegister/PatientRegisterRefuseList.vue

@ -140,7 +140,7 @@
</div>
</div>
<div style="padding: 15px;background-color: #fff;border-radius: 8px;">
<u-table :data="doctorCheck.RegisterCheckList"
<u-table :data="registerCheckDatas"
:height="window.pageHeight < 600 ? 310 : window.pageHeight - 291" highlight-current-row size="small"
@selection-change="handleSelectionChange">
<u-table-column type="selection" width="40" align="center" />
@ -193,6 +193,7 @@ export default {
data() {
return {
tableData: [], //
registerCheckDatas:[],
multipleSelection: [], //
quick: {
id: "",
@ -268,7 +269,7 @@ export default {
//
mounted() {
this.tableData = []
this.doctorCheck.RegisterCheckList = []
this.registerCheckDatas = []
},
computed: {
...mapState([
@ -276,7 +277,6 @@ export default {
"dict",
"patientRegister",
"customerOrg",
"doctorCheck",
]),
},
methods: {
@ -335,7 +335,7 @@ export default {
.then((res) => {
console.log("registerCheckList", res.data);
if (res.code != -1) {
this.doctorCheck.RegisterCheckList = res.data;
this.registerCheckDatas = res.data;
}
})
.catch((err) => {

6
src/router/index.js

@ -476,6 +476,12 @@ const routes = [{
component: () =>
import ("../views/customerOrg/patientRegisterRefuse.vue"),
},
{
path: "/patientRegisterMedical",
name: "体检中心调整",
component: () =>
import ("../views/customerOrg/patientRegisterMedical.vue"),
},
{
path: "/charge",
name: "体检收费",

150
src/views/customerOrg/patientRegisterMedical.vue

@ -0,0 +1,150 @@
<template>
<div>
<div>
<div class="middlebox">
<div class="contenttitle">
体检登记 /
<span class="contenttitleBold">体检中心调整</span>
</div>
</div>
<div style=" width: 100%;margin-top:7px">
<!-- 查询条件 -->
<PatientRegisterQuery orgEnable="Y" @triggerQuery="triggerQuery" />
<!-- 人员列表信息 -->
<PatientRegisterMedicalList :refQueryCondition="queryCondition" />
</div>
</div>
</div>
</template>
<script>
import { mapState, mapActions } from "vuex";
import { getapi, postapi, putapi, deletapi } from "@/api/api";
import { tcdate } from "../../utlis/proFunc";
import PatientRegisterQuery from "../../components/patientRegister/patientRegisterQuery.vue";
import PatientRegisterMedicalList from "../../components/patientRegister/PatientRegisterMedicalList.vue";
export default {
components: {
PatientRegisterQuery,
PatientRegisterMedicalList,
},
data() {
return {
tabChoosed: "1",
//
queryCondition: {
queryConditionTimes: 0
},
};
},
created() {
// console.log("this.$route.query", this.$route.query)
if (this.$route.query.patient_register) {
this.dataTransOpts.tableS.patient_register = this.$route.query.patient_register
} else {
this.dataTransOpts.tableS.patient_register = { id: '', patientRegisterNo: '' }
}
},
//
mounted() {
this.dictInit();
},
computed: {
...mapState(["window", "dataTransOpts", "dict", "patientRegister", "customerOrg"]),
},
methods: {
...mapActions(["getCustomerOrgGroup"]),
//
dictInit() {
//
getapi("/api/app/sex").then((res) => {
if (res.code == 1) {
this.dict.sex = res.data;
}
});
//
getapi("/api/app/for-sex").then((res) => {
if (res.code == 1) {
this.dict.forSex = res.data;
}
});
//
getapi("/api/app/organization-units/organization-unit-by-is-peis").then(
(res) => {
if (res.code == 1) {
this.dict.organization = res.data;
}
}
);
//
getapi("/api/app/medical-type/in-filter").then((res) => {
if (res.code == 1) {
this.dict.medicalType = res.data;
}
});
//
getapi("/api/app/personnel-type/in-filter").then((res) => {
if (res.code == 1) {
this.dict.personnelType = res.data;
}
});
//
getapi("/api/app/MaritalStatus/GetMaritalStatusList").then((res) => {
if (res.code == 1) {
this.dict.maritalStatus = res.data;
}
});
postapi("/api/app/asbitem/GetBasicList", { isFilterActive: 'Y' }).then((res) => {
if (res.code == 1) {
this.dict.asbItemAll = res.data;
}
});
console.log("dict", this.dict);
},
//
triggerQuery(queryCondition) {
//console.log('.triggerQuery1', queryCondition)
this.queryCondition = Object.assign(this.queryCondition, queryCondition, { queryConditionTimes: Number(this.queryCondition.queryConditionTimes) + 1 })
//console.log('.triggerQuery2', this.queryCondition)
},
},
//()
watch: {
//1
"patientRegister.query.CustomerOrgParentId"(newVal, oldVal) {
console.log(
"watch patientRegister.query.CustomerOrgParentId newVal:",
newVal,
" oldVal:",
oldVal
);
if (newVal != oldVal && newVal !== this.dict.personOrgId) {
this.getCustomerOrgGroup(newVal);
}
},
},
};
</script>
<style scoped>
@import '../../assets/css/global_card.css';
</style>
Loading…
Cancel
Save