|
|
@ -1,18 +1,21 @@ |
|
|
<template> |
|
|
<template> |
|
|
|
|
|
<div> |
|
|
|
|
|
<!--组件主体--> |
|
|
<div style="display: flex"> |
|
|
<div style="display: flex"> |
|
|
<div :style="'width:' + (window.pageWidth - 200 - 145) + 'px;'" @contextmenu.prevent="onContextmenu"> |
|
|
<div :style="'width:' + (window.pageWidth - 200 - 145) + 'px;'" @contextmenu.prevent="onContextmenu"> |
|
|
<div> |
|
|
<div> |
|
|
<el-table @body-scrolling="load" :data="patientRegister.prList" border |
|
|
|
|
|
:height="window.pageHeight < 600 ? 248 : Math.floor(((window.pageHeight - 250) * 2) / 3)" highlight-current-row |
|
|
|
|
|
@row-click="rowClick" size="small" row-key="id" @selection-change="handleSelectionChange" |
|
|
|
|
|
@cell-contextmenu="onCellRightClick" ref="info" id="info" :row-class-name="handleRowClassName"> |
|
|
|
|
|
|
|
|
<el-table @body-scrolling="load" :data="tableData" border |
|
|
|
|
|
:height="window.pageHeight < 600 ? 248 : Math.floor(((window.pageHeight - 250) * 2) / 3)" |
|
|
|
|
|
highlight-current-row @row-click="rowClick" size="small" row-key="id" |
|
|
|
|
|
@selection-change="handleSelectionChange" @cell-contextmenu="onCellRightClick" ref="info" id="info" |
|
|
|
|
|
:row-class-name="handleRowClassName"> |
|
|
<!-- 取消勾选,改为选中 |
|
|
<!-- 取消勾选,改为选中 |
|
|
<el-table-column type="selection" width="40" show-overflow-tooltip/> |
|
|
<el-table-column type="selection" width="40" show-overflow-tooltip/> |
|
|
:height="window.pageHeight < 600 ? 202 : Math.floor(((window.pageHeight - 302) * 2) / 3)" |
|
|
:height="window.pageHeight < 600 ? 202 : Math.floor(((window.pageHeight - 302) * 2) / 3)" |
|
|
--> |
|
|
--> |
|
|
<el-table-column v-for="(item, index) in headerCols" :key="`col_${index}`" :min-width="dropCol[index].minWidth" |
|
|
|
|
|
:align="dropCol[index].align" :label="item.label" :prop="dropCol[index].prop" |
|
|
|
|
|
:sortable="dropCol[index].prop == 'sn' ? false : true"> |
|
|
|
|
|
|
|
|
<el-table-column v-for="(item, index) in headerCols" :key="`col_${index}`" |
|
|
|
|
|
:min-width="dropCol[index].minWidth" :align="dropCol[index].align" :label="item.label" |
|
|
|
|
|
:prop="dropCol[index].prop" :sortable="dropCol[index].prop == 'sn' ? false : true"> |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
|
<div v-if="dropCol[index].prop == 'sn'"> |
|
|
<div v-if="dropCol[index].prop == 'sn'"> |
|
|
{{ scope.$index + 1 }} |
|
|
{{ scope.$index + 1 }} |
|
|
@ -98,7 +101,8 @@ |
|
|
<div style="display: flex;justify-content:space-between;"> |
|
|
<div style="display: flex;justify-content:space-between;"> |
|
|
<div></div> |
|
|
<div></div> |
|
|
<div> |
|
|
<div> |
|
|
<span style="font-size:12px;">共:{{ loadOpts.totalCount }} 条记录,当前显示:{{ patientRegister.prList.length }} 条。</span> |
|
|
|
|
|
|
|
|
<span style="font-size:12px;">共:{{ loadOpts.totalCount }} 条记录,当前显示:{{ tableData.length }} |
|
|
|
|
|
条。</span> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
@ -154,17 +158,20 @@ |
|
|
</div> |
|
|
</div> |
|
|
<!-- |
|
|
<!-- |
|
|
<div class="listBtn"> |
|
|
<div class="listBtn"> |
|
|
<el-button type="" class="btnClass commonbutton" @click="rowSelected(patientRegister.prList)">选中</el-button> |
|
|
|
|
|
|
|
|
<el-button type="" class="btnClass commonbutton" @click="rowSelected(tableData)">选中</el-button> |
|
|
</div> |
|
|
</div> |
|
|
--> |
|
|
--> |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
<!--组件弹窗--> |
|
|
|
|
|
<div> |
|
|
<!-- 体检人员登记 :title="patientRegister.patientRegisterRd.id ? '体检人员--编辑' : '体检人员--新增'" --> |
|
|
<!-- 体检人员登记 :title="patientRegister.patientRegisterRd.id ? '体检人员--编辑' : '体检人员--新增'" --> |
|
|
<el-dialog :title="dataTransOpts.tableS.patient_register.id ? '体检人员--编辑' : '体检人员--新增'" :visible.sync="dialogVisible" |
|
|
|
|
|
:close-on-click-modal="false" fullscreen @close="closeDialogPR"> |
|
|
|
|
|
|
|
|
<el-dialog :title="dataTransOpts.tableS.patient_register.id ? '体检人员--编辑' : '体检人员--新增'" |
|
|
|
|
|
:visible.sync="dialogWin.PatientRegisterEdit" :close-on-click-modal="false" fullscreen |
|
|
|
|
|
@close="close_dialogWin_PatientRegisterEdit"> |
|
|
<!-- :formInitData="patientRegister.patientRegisterRd" --> |
|
|
<!-- :formInitData="patientRegister.patientRegisterRd" --> |
|
|
<PatientRegisterEdit :isDoctor="'0'" :patientRegisterId="patientRegister.patientRegisterRd.id" |
|
|
<PatientRegisterEdit :isDoctor="'0'" :patientRegisterId="patientRegister.patientRegisterRd.id" |
|
|
:editTimes="editTimes" :refreshRegister="refreshRegister" /> |
|
|
|
|
|
|
|
|
:editTimes="editTimes" :refreshRegister="refreshRegister" :refFuncSetData="refFuncSetData"/> |
|
|
</el-dialog> |
|
|
</el-dialog> |
|
|
|
|
|
|
|
|
<!-- 拍照 --> |
|
|
<!-- 拍照 --> |
|
|
@ -173,11 +180,6 @@ |
|
|
<Camera :id="patientRegister.patientRegisterId" /> |
|
|
<Camera :id="patientRegister.patientRegisterId" /> |
|
|
</el-dialog> |
|
|
</el-dialog> |
|
|
|
|
|
|
|
|
<!-- 指引单 --> |
|
|
|
|
|
<el-dialog title="指引单" :visible.sync="dialogGuide" width="400" height="800" :append-to-body="true" |
|
|
|
|
|
:close-on-click-modal="false"> |
|
|
|
|
|
<div>{{ guideMsg }}</div> |
|
|
|
|
|
</el-dialog> |
|
|
|
|
|
|
|
|
|
|
|
<!-- 批量调整分组 --> |
|
|
<!-- 批量调整分组 --> |
|
|
<el-dialog title="批量调整分组" :visible.sync="dialogWin.PatientRegisterEditGroupBatch" width="600px" height="800px" |
|
|
<el-dialog title="批量调整分组" :visible.sync="dialogWin.PatientRegisterEditGroupBatch" width="600px" height="800px" |
|
|
@ -198,6 +200,7 @@ |
|
|
<ElProgressOCX /> |
|
|
<ElProgressOCX /> |
|
|
</el-dialog> |
|
|
</el-dialog> |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
</div> |
|
|
</template> |
|
|
</template> |
|
|
<script> |
|
|
<script> |
|
|
import moment from "moment"; |
|
|
import moment from "moment"; |
|
|
@ -243,11 +246,12 @@ export default { |
|
|
startPoint: -1, // 多选起点 -1 表示选择 |
|
|
startPoint: -1, // 多选起点 -1 表示选择 |
|
|
endPoint: -1, // 多选终点 -1 表示未选择 |
|
|
endPoint: -1, // 多选终点 -1 表示未选择 |
|
|
|
|
|
|
|
|
|
|
|
tableData: [], //表格数据 |
|
|
|
|
|
tableDataCurrentRow: {}, // 当前被选中的行 |
|
|
|
|
|
|
|
|
multipleSelection: [], //选中的数据列表 |
|
|
multipleSelection: [], //选中的数据列表 |
|
|
dialogVisible: false, |
|
|
|
|
|
|
|
|
|
|
|
dialogCamera: false, |
|
|
dialogCamera: false, |
|
|
dialogGuide: false, |
|
|
|
|
|
guideMsg: "guideMsg", |
|
|
|
|
|
tabChoosed: "1", |
|
|
tabChoosed: "1", |
|
|
formInitData: {}, //体检登记初始表单数据 |
|
|
formInitData: {}, //体检登记初始表单数据 |
|
|
editTimes: 0, |
|
|
editTimes: 0, |
|
|
@ -354,12 +358,17 @@ export default { |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
// 行选择 |
|
|
rowSelected(rows) { |
|
|
rowSelected(rows) { |
|
|
rows.forEach((e) => { |
|
|
rows.forEach((e) => { |
|
|
this.$refs["info"].toggleRowSelection(e, true); |
|
|
this.$refs["info"].toggleRowSelection(e, true); |
|
|
}); |
|
|
}); |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
refFuncSetData(item, v) { |
|
|
|
|
|
setData(this, item, v) |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
// 打印指引单(isPreview) |
|
|
// 打印指引单(isPreview) |
|
|
async guidePrint(ReportCode, isPreview) { |
|
|
async guidePrint(ReportCode, isPreview) { |
|
|
if (!this.$peisAPI) { |
|
|
if (!this.$peisAPI) { |
|
|
@ -381,7 +390,7 @@ export default { |
|
|
|
|
|
|
|
|
//选中(取消勾选)start ------------------------- |
|
|
//选中(取消勾选)start ------------------------- |
|
|
this.multipleSelection = [] |
|
|
this.multipleSelection = [] |
|
|
this.patientRegister.prList.forEach(e => { |
|
|
|
|
|
|
|
|
this.tableData.forEach(e => { |
|
|
if (e.choosed) { |
|
|
if (e.choosed) { |
|
|
this.multipleSelection.push(deepCopy(e)) |
|
|
this.multipleSelection.push(deepCopy(e)) |
|
|
} |
|
|
} |
|
|
@ -435,15 +444,15 @@ export default { |
|
|
if (JSON.parse(resPeisAPI).code < 0) continue |
|
|
if (JSON.parse(resPeisAPI).code < 0) continue |
|
|
resPrintTimes = postapi("api/app/patientregister/updatepatientregisterguideprinttimesmany", [this.multipleSelection[i].id]); |
|
|
resPrintTimes = postapi("api/app/patientregister/updatepatientregisterguideprinttimesmany", [this.multipleSelection[i].id]); |
|
|
if (resPrintTimes.code == -1) continue |
|
|
if (resPrintTimes.code == -1) continue |
|
|
lfind = arrayExistObj(this.patientRegister.prList, "id", this.multipleSelection[i].id); |
|
|
|
|
|
|
|
|
lfind = arrayExistObj(this.tableData, "id", this.multipleSelection[i].id); |
|
|
if (lfind > -1) { |
|
|
if (lfind > -1) { |
|
|
if (this.patientRegister.prList[lfind].guidePrintTimes) { |
|
|
|
|
|
this.patientRegister.prList[lfind].guidePrintTimes = |
|
|
|
|
|
|
|
|
if (this.tableData[lfind].guidePrintTimes) { |
|
|
|
|
|
this.tableData[lfind].guidePrintTimes = |
|
|
Number( |
|
|
Number( |
|
|
this.patientRegister.prList[lfind].guidePrintTimes |
|
|
|
|
|
|
|
|
this.tableData[lfind].guidePrintTimes |
|
|
) + 1; |
|
|
) + 1; |
|
|
} else { |
|
|
} else { |
|
|
this.patientRegister.prList[lfind].guidePrintTimes = 1; |
|
|
|
|
|
|
|
|
this.tableData[lfind].guidePrintTimes = 1; |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} catch (error) { |
|
|
} catch (error) { |
|
|
@ -466,7 +475,7 @@ export default { |
|
|
}); |
|
|
}); |
|
|
// 取消全选 |
|
|
// 取消全选 |
|
|
if (!rows.length) { |
|
|
if (!rows.length) { |
|
|
this.patientRegister.prList.forEach((item) => { |
|
|
|
|
|
|
|
|
this.tableData.forEach((item) => { |
|
|
item.highLightBg = ""; |
|
|
item.highLightBg = ""; |
|
|
}); |
|
|
}); |
|
|
} |
|
|
} |
|
|
@ -483,32 +492,32 @@ export default { |
|
|
|
|
|
|
|
|
//点击体检次数行 |
|
|
//点击体检次数行 |
|
|
rowClick(row) { |
|
|
rowClick(row) { |
|
|
//console.log("this.patientRegister.prList",this.window,this.patientRegister.prList); |
|
|
|
|
|
|
|
|
//console.log("this.tableData",this.window,this.tableData); |
|
|
|
|
|
|
|
|
// 按住了shift键 |
|
|
// 按住了shift键 |
|
|
if (this.window.shift) { |
|
|
if (this.window.shift) { |
|
|
//清除所有选择 |
|
|
//清除所有选择 |
|
|
this.patientRegister.prList.forEach((e, index) => { |
|
|
|
|
|
|
|
|
this.tableData.forEach((e, index) => { |
|
|
e.choosed = false; |
|
|
e.choosed = false; |
|
|
e.index = index; |
|
|
e.index = index; |
|
|
}); |
|
|
}); |
|
|
|
|
|
|
|
|
if (this.startPoint == -1) { |
|
|
if (this.startPoint == -1) { |
|
|
this.patientRegister.prList[row.index].choosed = true; |
|
|
|
|
|
|
|
|
this.tableData[row.index].choosed = true; |
|
|
this.startPoint = row.index; |
|
|
this.startPoint = row.index; |
|
|
} else { |
|
|
} else { |
|
|
if (this.startPoint > row.index) { |
|
|
if (this.startPoint > row.index) { |
|
|
for (let i = row.index; i <= this.startPoint; i++) { |
|
|
for (let i = row.index; i <= this.startPoint; i++) { |
|
|
this.patientRegister.prList[i].choosed = true; |
|
|
|
|
|
|
|
|
this.tableData[i].choosed = true; |
|
|
} |
|
|
} |
|
|
} else if (this.startPoint <= row.index) { |
|
|
} else if (this.startPoint <= row.index) { |
|
|
for (let i = this.startPoint; i <= row.index; i++) { |
|
|
for (let i = this.startPoint; i <= row.index; i++) { |
|
|
this.patientRegister.prList[i].choosed = true; |
|
|
|
|
|
|
|
|
this.tableData[i].choosed = true; |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} else if (this.window.ctrl) { // 按住了ctrl 键 |
|
|
} else if (this.window.ctrl) { // 按住了ctrl 键 |
|
|
this.patientRegister.prList[row.index].choosed = true; |
|
|
|
|
|
|
|
|
this.tableData[row.index].choosed = true; |
|
|
if (this.startPoint == -1) { |
|
|
if (this.startPoint == -1) { |
|
|
this.startPoint = row.index; |
|
|
this.startPoint = row.index; |
|
|
} |
|
|
} |
|
|
@ -516,22 +525,22 @@ export default { |
|
|
// 未按住了ctrl 、shift 键 |
|
|
// 未按住了ctrl 、shift 键 |
|
|
//清除所有选择 |
|
|
//清除所有选择 |
|
|
console.log("清除所有选择"); |
|
|
console.log("清除所有选择"); |
|
|
this.patientRegister.prList.forEach((e, index) => { |
|
|
|
|
|
|
|
|
this.tableData.forEach((e, index) => { |
|
|
e.choosed = false; |
|
|
e.choosed = false; |
|
|
e.index = index; |
|
|
e.index = index; |
|
|
}); |
|
|
}); |
|
|
console.log(this.patientRegister.prList, row.index); |
|
|
|
|
|
console.log(this.patientRegister.prList[row.index].choosed); |
|
|
|
|
|
|
|
|
console.log(this.tableData, row.index); |
|
|
|
|
|
console.log(this.tableData[row.index].choosed); |
|
|
|
|
|
|
|
|
this.patientRegister.prList[row.index].choosed = true; |
|
|
|
|
|
|
|
|
this.tableData[row.index].choosed = true; |
|
|
this.startPoint = row.index; |
|
|
this.startPoint = row.index; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
//选中了多个点编辑时,排序最前的作为当前选中的 |
|
|
//选中了多个点编辑时,排序最前的作为当前选中的 |
|
|
console.log('row.index <= this.startPoint', row.index, this.startPoint) |
|
|
console.log('row.index <= this.startPoint', row.index, this.startPoint) |
|
|
let lfind = -1 |
|
|
let lfind = -1 |
|
|
for (let i = 0; i < this.patientRegister.prList.length; i++) { |
|
|
|
|
|
if (this.patientRegister.prList[i].choosed) { |
|
|
|
|
|
|
|
|
for (let i = 0; i < this.tableData.length; i++) { |
|
|
|
|
|
if (this.tableData[i].choosed) { |
|
|
lfind = i |
|
|
lfind = i |
|
|
break |
|
|
break |
|
|
} |
|
|
} |
|
|
@ -539,21 +548,22 @@ export default { |
|
|
|
|
|
|
|
|
if (lfind > -1) { |
|
|
if (lfind > -1) { |
|
|
// 弹出编辑框,只有在编辑框显示时,才去触发获取数据 |
|
|
// 弹出编辑框,只有在编辑框显示时,才去触发获取数据 |
|
|
this.dataTransOpts.tableS.patient_register.id = this.patientRegister.prList[lfind].id |
|
|
|
|
|
// this.getCustomerOrgGroup(this.patientRegister.prList[lfind].customerOrgParentId); |
|
|
|
|
|
|
|
|
this.dataTransOpts.tableS.patient_register.id = this.tableData[lfind].id |
|
|
|
|
|
this.tableDataCurrentRow = deepCopy(this.tableData[lfind]) |
|
|
|
|
|
// this.getCustomerOrgGroup(this.tableData[lfind].customerOrgParentId); |
|
|
setTimeout(() => { |
|
|
setTimeout(() => { |
|
|
this.dataTransOpts.refresh.register_asbitem.M++ //触发所选组合项目刷新 |
|
|
this.dataTransOpts.refresh.register_asbitem.M++ //触发所选组合项目刷新 |
|
|
}, 20); |
|
|
|
|
|
|
|
|
}, 10); |
|
|
|
|
|
|
|
|
// 旧的方式 |
|
|
// 旧的方式 |
|
|
// if(this.patientRegister.patientRegisterRd.id != this.patientRegister.prList[lfind].id){ |
|
|
|
|
|
// this.setForm(this.patientRegister.prList[lfind]) |
|
|
|
|
|
// // this.patientRegister.query.customerOrgParentId = this.patientRegister.prList[lfind].customerOrgParentId; |
|
|
|
|
|
|
|
|
// if(this.patientRegister.patientRegisterRd.id != this.tableData[lfind].id){ |
|
|
|
|
|
// this.setForm(this.tableData[lfind]) |
|
|
|
|
|
// // this.patientRegister.query.customerOrgParentId = this.tableData[lfind].customerOrgParentId; |
|
|
// this.patientRegister.customerOrgGroupChange = 0; //控制体检列表记录切换时,0 无需触发更换分组操作 |
|
|
// this.patientRegister.customerOrgGroupChange = 0; //控制体检列表记录切换时,0 无需触发更换分组操作 |
|
|
// this.patientRegister.medicalPackageChange = 0; //控制体检列表记录切换时,0 无需触发更换套餐操作 |
|
|
// this.patientRegister.medicalPackageChange = 0; //控制体检列表记录切换时,0 无需触发更换套餐操作 |
|
|
// // this.getCustomerOrgGroup(this.patientRegister.prList[lfind].customerOrgParentId); |
|
|
|
|
|
|
|
|
// // this.getCustomerOrgGroup(this.tableData[lfind].customerOrgParentId); |
|
|
// this.dict.asbItem = [...this.dict.asbItemAll]; |
|
|
// this.dict.asbItem = [...this.dict.asbItemAll]; |
|
|
// this.getPatientRegisterAbs(this.patientRegister.prList[lfind].id); |
|
|
|
|
|
|
|
|
// this.getPatientRegisterAbs(this.tableData[lfind].id); |
|
|
// } |
|
|
// } |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@ -576,12 +586,12 @@ export default { |
|
|
// this.setForm(this.patientRegister.patientRegisterRdInit) |
|
|
// this.setForm(this.patientRegister.patientRegisterRdInit) |
|
|
// this.patientRegister.patientRegisterAbs = []; |
|
|
// this.patientRegister.patientRegisterAbs = []; |
|
|
// this.patientRegister.patientRegisterRd.id = '' |
|
|
// this.patientRegister.patientRegisterRd.id = '' |
|
|
// this.dialogVisible = true; |
|
|
|
|
|
|
|
|
// this.dialogWin.PatientRegisterEdit = true; |
|
|
// this.editTimes++; //触发表单窗口,数据更新 |
|
|
// this.editTimes++; //触发表单窗口,数据更新 |
|
|
// this.getPatientRegisterAbs(); |
|
|
// this.getPatientRegisterAbs(); |
|
|
|
|
|
|
|
|
this.dataTransOpts.tableS.patient_register.id = '' |
|
|
this.dataTransOpts.tableS.patient_register.id = '' |
|
|
this.dialogVisible = true; |
|
|
|
|
|
|
|
|
this.dialogWin.PatientRegisterEdit = true; |
|
|
setTimeout(() => { |
|
|
setTimeout(() => { |
|
|
// 触发数据刷新 |
|
|
// 触发数据刷新 |
|
|
this.dataTransOpts.refresh.patient_register.S++ //触发人员信息刷新 |
|
|
this.dataTransOpts.refresh.patient_register.S++ //触发人员信息刷新 |
|
|
@ -602,7 +612,7 @@ export default { |
|
|
let patientRegisterIds = [] |
|
|
let patientRegisterIds = [] |
|
|
//取消勾选,换成选择的方式 start |
|
|
//取消勾选,换成选择的方式 start |
|
|
this.multipleSelection = []; |
|
|
this.multipleSelection = []; |
|
|
this.patientRegister.prList.forEach((e) => { |
|
|
|
|
|
|
|
|
this.tableData.forEach((e) => { |
|
|
if (e.choosed && e.completeFlag == '0') { |
|
|
if (e.choosed && e.completeFlag == '0') { |
|
|
this.multipleSelection.push(e); |
|
|
this.multipleSelection.push(e); |
|
|
patientRegisterIds.push(e.id) |
|
|
patientRegisterIds.push(e.id) |
|
|
@ -621,8 +631,8 @@ export default { |
|
|
if (res.code != -1) { |
|
|
if (res.code != -1) { |
|
|
console.log('操作成功!') |
|
|
console.log('操作成功!') |
|
|
patientRegisterIds.forEach(e => { |
|
|
patientRegisterIds.forEach(e => { |
|
|
let lfind = arrayExistObj(this.patientRegister.prList, 'id', e) |
|
|
|
|
|
if (lfind > -1) this.patientRegister.prList[lfind].completeFlag = completeFlag |
|
|
|
|
|
|
|
|
let lfind = arrayExistObj(this.tableData, 'id', e) |
|
|
|
|
|
if (lfind > -1) this.tableData[lfind].completeFlag = completeFlag |
|
|
}); |
|
|
}); |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
|
@ -638,8 +648,8 @@ export default { |
|
|
this.$message.warning("请选择要操作的记录"); |
|
|
this.$message.warning("请选择要操作的记录"); |
|
|
return; |
|
|
return; |
|
|
} |
|
|
} |
|
|
//console.log(this.patientRegister.patientRegisterRd,this.patientRegister.prList) |
|
|
|
|
|
this.dialogVisible = true; |
|
|
|
|
|
|
|
|
//console.log(this.patientRegister.patientRegisterRd,this.tableData) |
|
|
|
|
|
this.dialogWin.PatientRegisterEdit = true; |
|
|
// 触发数据刷新 |
|
|
// 触发数据刷新 |
|
|
this.dataTransOpts.refresh.patient_register.S++ //触发人员信息刷新(会同时刷新组合项目) |
|
|
this.dataTransOpts.refresh.patient_register.S++ //触发人员信息刷新(会同时刷新组合项目) |
|
|
this.dataTransOpts.plus.clearPatientRegisterQuery++ //触发清空人员登记界面的查询条件 |
|
|
this.dataTransOpts.plus.clearPatientRegisterQuery++ //触发清空人员登记界面的查询条件 |
|
|
@ -647,29 +657,29 @@ export default { |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
//新增或编辑后选中记录 |
|
|
//新增或编辑后选中记录 |
|
|
async closeDialogPR() { |
|
|
|
|
|
|
|
|
async close_dialogWin_PatientRegisterEdit() { |
|
|
// 如果 dataTransOpts.tableS.patient_register.id 为空(未增加),则不做处理 |
|
|
// 如果 dataTransOpts.tableS.patient_register.id 为空(未增加),则不做处理 |
|
|
if (!this.dataTransOpts.tableS.patient_register.id) return |
|
|
|
|
|
|
|
|
let id = this.dataTransOpts.tableS.patient_register.id |
|
|
|
|
|
if (!id){ |
|
|
|
|
|
id = this.tableDataCurrentRow.id |
|
|
|
|
|
} |
|
|
|
|
|
if(!id) return |
|
|
|
|
|
this.dataTransOpts.tableS.patient_register.id = id |
|
|
|
|
|
|
|
|
// 刷新列表(并选中当前新增或编辑的行记录) |
|
|
|
|
|
this.patientRegister.prList.forEach(e => { |
|
|
|
|
|
e.choosed = false |
|
|
|
|
|
}) |
|
|
|
|
|
let res = await postapi(`/api/app/patientregister/getinfoorpatient?PatientRegisterId=${this.dataTransOpts.tableS.patient_register.id}`) |
|
|
|
|
|
if (res.code != 1) return |
|
|
|
|
|
|
|
|
// let res = await postapi(`/api/app/patientregister/getinfoorpatient?PatientRegisterId=${this.dataTransOpts.tableS.patient_register.id}`) |
|
|
|
|
|
// if (res.code != 1) return |
|
|
|
|
|
|
|
|
this.patientRegister.prList.forEach(e => { |
|
|
|
|
|
e.choosed = false |
|
|
|
|
|
}); |
|
|
|
|
|
let lfind = arrayExistObj(this.patientRegister.prList, 'id', this.dataTransOpts.tableS.patient_register.id) |
|
|
|
|
|
|
|
|
// this.tableData.forEach(e => { |
|
|
|
|
|
// e.choosed = false |
|
|
|
|
|
// }); |
|
|
|
|
|
let lfind = arrayExistObj(this.tableData, 'id', this.dataTransOpts.tableS.patient_register.id) |
|
|
if (lfind > -1) { |
|
|
if (lfind > -1) { |
|
|
objCopy(res.data, this.patientRegister.prList[lfind]) |
|
|
|
|
|
this.patientRegister.prList[lfind].choosed = true |
|
|
|
|
|
|
|
|
objCopy(this.tableDataCurrentRow,this.tableData[lfind]) |
|
|
} else { |
|
|
} else { |
|
|
lfind = this.patientRegister.prList.length |
|
|
|
|
|
this.patientRegister.prList.push(res.data) |
|
|
|
|
|
this.patientRegister.prList[lfind].index = lfind |
|
|
|
|
|
this.patientRegister.prList[lfind].choosed = true |
|
|
|
|
|
|
|
|
lfind = this.tableData.length |
|
|
|
|
|
this.tableDataCurrentRow.index = lfind |
|
|
|
|
|
this.tableDataCurrentRow.choosed = true |
|
|
|
|
|
this.tableData.push(this.tableDataCurrentRow) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
// 刷新 register_asbitem 表记录 |
|
|
// 刷新 register_asbitem 表记录 |
|
|
@ -678,10 +688,10 @@ export default { |
|
|
// setTimeout(() => { |
|
|
// setTimeout(() => { |
|
|
// this.$refs['info'].setCurrentRow(currentRow) |
|
|
// this.$refs['info'].setCurrentRow(currentRow) |
|
|
// this.setForm(currentRow) |
|
|
// this.setForm(currentRow) |
|
|
// // this.patientRegister.query.customerOrgParentId = this.patientRegister.prList[lfind].customerOrgParentId; |
|
|
|
|
|
|
|
|
// // this.patientRegister.query.customerOrgParentId = this.tableData[lfind].customerOrgParentId; |
|
|
// this.patientRegister.customerOrgGroupChange = 0; //控制体检列表记录切换时,0 无需触发更换分组操作 |
|
|
// this.patientRegister.customerOrgGroupChange = 0; //控制体检列表记录切换时,0 无需触发更换分组操作 |
|
|
// this.patientRegister.medicalPackageChange = 0; //控制体检列表记录切换时,0 无需触发更换套餐操作 |
|
|
// this.patientRegister.medicalPackageChange = 0; //控制体检列表记录切换时,0 无需触发更换套餐操作 |
|
|
// // this.getCustomerOrgGroup(this.patientRegister.prList[lfind].customerOrgParentId); |
|
|
|
|
|
|
|
|
// // this.getCustomerOrgGroup(this.tableData[lfind].customerOrgParentId); |
|
|
// this.dict.asbItem = [...this.dict.asbItemAll]; |
|
|
// this.dict.asbItem = [...this.dict.asbItemAll]; |
|
|
// this.getPatientRegisterAbs(currentRow.id); |
|
|
// this.getPatientRegisterAbs(currentRow.id); |
|
|
// }, 100) |
|
|
// }, 100) |
|
|
@ -703,7 +713,7 @@ export default { |
|
|
|
|
|
|
|
|
//选中(取消勾选)start ------------------------- |
|
|
//选中(取消勾选)start ------------------------- |
|
|
this.multipleSelection = [] |
|
|
this.multipleSelection = [] |
|
|
this.patientRegister.prList.forEach(e => { |
|
|
|
|
|
|
|
|
this.tableData.forEach(e => { |
|
|
if (e.choosed) { |
|
|
if (e.choosed) { |
|
|
this.multipleSelection.push(deepCopy(e)) |
|
|
this.multipleSelection.push(deepCopy(e)) |
|
|
} |
|
|
} |
|
|
@ -734,7 +744,7 @@ export default { |
|
|
.then((res) => { |
|
|
.then((res) => { |
|
|
if (res.code != -1) { |
|
|
if (res.code != -1) { |
|
|
console.log("操作成功"); |
|
|
console.log("操作成功"); |
|
|
arrayReduce(this.patientRegister.prList, this.multipleSelection, 'id=id') |
|
|
|
|
|
|
|
|
arrayReduce(this.tableData, this.multipleSelection, 'id=id') |
|
|
this.setForm(this.patientRegister.patientRegisterRdInit) |
|
|
this.setForm(this.patientRegister.patientRegisterRdInit) |
|
|
this.getPatientRegisterAbs(); |
|
|
this.getPatientRegisterAbs(); |
|
|
} |
|
|
} |
|
|
@ -843,13 +853,13 @@ export default { |
|
|
let oldCount = 0 |
|
|
let oldCount = 0 |
|
|
|
|
|
|
|
|
if (body.skipCount == 0) { //查询 |
|
|
if (body.skipCount == 0) { //查询 |
|
|
this.patientRegister.prList = []; |
|
|
|
|
|
|
|
|
this.tableData = []; |
|
|
} else { |
|
|
} else { |
|
|
// 懒加载 ,原数据集不用清空 |
|
|
// 懒加载 ,原数据集不用清空 |
|
|
oldCount = this.patientRegister.prList.length |
|
|
|
|
|
|
|
|
oldCount = this.tableData.length |
|
|
} |
|
|
} |
|
|
curLoad.forEach((e, index) => { |
|
|
curLoad.forEach((e, index) => { |
|
|
this.patientRegister.prList.push(Object.assign({ index: Number(oldCount) + Number(index), choosed: false }, e)) |
|
|
|
|
|
|
|
|
this.tableData.push(Object.assign({ index: Number(oldCount) + Number(index), choosed: false }, e)) |
|
|
}) |
|
|
}) |
|
|
|
|
|
|
|
|
//如果 有选中 记录,则刷新其对应的组合项目 |
|
|
//如果 有选中 记录,则刷新其对应的组合项目 |
|
|
@ -954,7 +964,7 @@ export default { |
|
|
} |
|
|
} |
|
|
//取消勾选,换成选择的方式 start |
|
|
//取消勾选,换成选择的方式 start |
|
|
this.multipleSelection = []; |
|
|
this.multipleSelection = []; |
|
|
this.patientRegister.prList.forEach((e) => { |
|
|
|
|
|
|
|
|
this.tableData.forEach((e) => { |
|
|
if (e.choosed) this.multipleSelection.push(e); |
|
|
if (e.choosed) this.multipleSelection.push(e); |
|
|
}); |
|
|
}); |
|
|
//取消勾选,换成选择的方式 end |
|
|
//取消勾选,换成选择的方式 end |
|
|
@ -977,7 +987,7 @@ export default { |
|
|
} |
|
|
} |
|
|
//取消勾选,换成选择的方式 start |
|
|
//取消勾选,换成选择的方式 start |
|
|
this.multipleSelection = []; |
|
|
this.multipleSelection = []; |
|
|
this.patientRegister.prList.forEach((e) => { |
|
|
|
|
|
|
|
|
this.tableData.forEach((e) => { |
|
|
if (e.choosed) this.multipleSelection.push(e); |
|
|
if (e.choosed) this.multipleSelection.push(e); |
|
|
}); |
|
|
}); |
|
|
//取消勾选,换成选择的方式 end |
|
|
//取消勾选,换成选择的方式 end |
|
|
@ -1269,7 +1279,7 @@ export default { |
|
|
//console.log('watch:patientRegister.query.customerOrgId:',newVal,oldVal) |
|
|
//console.log('watch:patientRegister.query.customerOrgId:',newVal,oldVal) |
|
|
// 单位变化时,清除当前列表信息 |
|
|
// 单位变化时,清除当前列表信息 |
|
|
if (newVal && newVal != oldVal) { |
|
|
if (newVal && newVal != oldVal) { |
|
|
this.patientRegister.prList = [] |
|
|
|
|
|
|
|
|
this.tableData = [] |
|
|
this.dataTransOpts.tableM.register_asbitem = [] |
|
|
this.dataTransOpts.tableM.register_asbitem = [] |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|