pengjun 4 months ago
parent
commit
0d7ecc59f5
  1. 211
      src/components/customerOrg/customerOrgGroupAsbitem.vue
  2. 4
      src/components/doctorCheck/RegisterCheckEdit.vue
  3. 6
      src/components/patientRegister/patientRegisterQuery.vue
  4. 1
      src/store/index.js
  5. 2
      src/views/doctorCheck/doctorCheck.vue

211
src/components/customerOrg/customerOrgGroupAsbitem.vue

@ -104,7 +104,8 @@
<el-button class="commonbutton" @click="btnCopyGroupAsbitem">复制</el-button>
</div>
<div style="margin-top: 10px;">
<el-button class="commonbutton" @click="btnPastGroupAsbitem" :disabled="dataTransOpts.copyGroupAsbitem.length == 0 ? true:false" >粘贴</el-button>
<el-button class="commonbutton" @click="btnPastGroupAsbitem"
:disabled="dataTransOpts.copyGroupAsbitem.length == 0 ? true : false">粘贴</el-button>
</div>
<div v-show="checkPagePriv(pagePriv.privs, '保存')" style="margin-top: 10px;">
<el-button class="commonbutton" @click="btnSave">保存</el-button>
@ -172,9 +173,9 @@
<div style="display: flex">
<div>
<span>体检单位</span>
<el-select v-model="customerOrgId" placeholder="请选择体检单位" :filter-method="filterMethodOrg" default-first-option
clearable filterable @clear="customerOrgDisp = deepCopy(customerOrgAll)" style="margin-left: 10px"
@change="changeCustomerOrg" size="small">
<el-select v-model="customerOrgId" placeholder="请选择体检单位" :filter-method="filterMethodOrg"
default-first-option clearable filterable @clear="customerOrgDisp = deepCopy(customerOrgAll)"
style="margin-left: 10px" @change="changeCustomerOrg" size="small">
<el-option v-for="item in customerOrgDisp" :key="item.id" :label="item.displayName" :value="item.id">
{{ item.displayName }}
</el-option>
@ -222,7 +223,7 @@
: ""
}}
</template>
</el-table-column>
</el-table-column>
</el-table>
<div style="display: flex;justify-content: space-between;margin-top: 10px;">
<div></div>
@ -239,10 +240,10 @@
import moment from 'moment';
import { mapState } from "vuex";
import { getapi, postapi, putapi } from "@/api/api";
import { getPagePriv, checkPagePriv, arrayExistObj, tcdate, arrayFilter, arrayReduce, deepCopy, objCopy,dddw } from "../../utlis/proFunc";
import { getPagePriv, checkPagePriv, arrayExistObj, tcdate, arrayFilter, arrayReduce, deepCopy, objCopy, dddw } from "../../utlis/proFunc";
export default {
props: ['customerOrgGroup', 'curOrgGroups','customerOrgAll','curOrgRegister','curOrgRegisterList','refreshMoney'],
props: ['customerOrgGroup', 'curOrgGroups', 'customerOrgAll', 'curOrgRegister', 'curOrgRegisterList', 'refreshMoney'],
data() {
return {
pagePriv: {
@ -268,10 +269,10 @@ export default {
customerOrgGroups: [], //
curGroupId: '', //ID
groupAsbitems: [], //
customerOrgId:'', // ID
customerOrgDisp:[], //
customerOrgRegisterList:[], //
customerOrgRegister:{}, //
customerOrgId: '', // ID
customerOrgDisp: [], //
customerOrgRegisterList: [], //
customerOrgRegister: {}, //
dialogVisible: false,
@ -283,6 +284,8 @@ export default {
addrulst: [], //Id
price: "", //
title: 1,
hc_warn_mode: '1', //0-1-2-
};
},
computed: {
@ -301,7 +304,7 @@ export default {
created() {
//
let userPriv = window.sessionStorage.getItem('userPriv')
if (userPriv) this.pagePriv.privs = deepCopy(getPagePriv(this.pagePriv.routeUrlorPageName))
@ -309,9 +312,9 @@ export default {
this.dictInit()
},
mounted() {
this.getCustomerOrgGroupAsbitems(this.customerOrgGroup.id);
},
updated() {
@ -415,7 +418,7 @@ export default {
this.getCustomerOrgGroup(v.id);
},
//
getCustomerOrgGroup(customerOrgRegisterId) {
// this.isDrag = false;
@ -465,7 +468,7 @@ export default {
},
// //
refAsbItemByChoosed() {
refAsbItemByChoosed() {
//
arrayReduce(this.dict.asbItem, [...this.customerOrgGroupAsbitems], "id=asbitemId");
arrayReduce(this.dict.asbItemQuick, [...this.customerOrgGroupAsbitems], "id=asbitemId");
@ -549,16 +552,33 @@ export default {
arrayReduce(asbItemChoosed, this.customerOrgGroupAsbitems, "id=asbitemId")
for (let i = asbItemChoosed.length - 1; i > - 1; i--) {
if (this.customerOrgGroup.forSexId == 'A') break //
if (asbItemChoosed[i].forSexId == 'A' || asbItemChoosed[i].forSexId == 'U') continue
if (asbItemChoosed[i].forSexId != this.customerOrgGroup.forSexId) {
message.push(asbItemChoosed[i].displayName) //.warning(`${asbItemChoosed[i].displayName}`)
checked = false
asbItemChoosed.splice(i, 1)
//
if (this.customerOrgGroup.forSexId == 'A' && this.customerOrgGroup.maritalStatusId == 'A') {
break;
} else {
if (this.customerOrgGroup.forSexId != 'A'){
if (!(asbItemChoosed[i].forSexId == 'A' || asbItemChoosed[i].forSexId == 'U')) {
if (asbItemChoosed[i].forSexId != this.customerOrgGroup.forSexId) {
message.push(asbItemChoosed[i].displayName) //.warning(`${asbItemChoosed[i].displayName}`)
checked = false
asbItemChoosed.splice(i, 1)
}
}
}
//
if (!(checked || asbItemChoosed[i].maritalStatusId == 'A' || asbItemChoosed[i].maritalStatusId == 'U')) {
if (asbItemChoosed[i].maritalStatusId != this.customerOrgGroup.maritalStatusId) {
message.push(asbItemChoosed[i].displayName) //.warning(`${asbItemChoosed[i].displayName}`)
checked = false
asbItemChoosed.splice(i, 1)
}
}
}
}
//console.log(222,checked)
if (!checked) this.$message.warning(`所选项目【${JSON.stringify(message)}】不适合当前人员性别`)
if (!checked) this.$message.warning(`所选项目【${JSON.stringify(message)}】不适合当前人员性别或婚姻状态`)
for (let i = 0; i < asbItemChoosed.length; i++) {
let pojo = {
@ -702,7 +722,7 @@ export default {
lfind = arrayExistObj(this.customerOrgGroupAsbitems, 'asbitemId', absForDel[i].asbitemId)
if (lfind > -1) this.customerOrgGroupAsbitems.splice(lfind, 1)
lfind = arrayExistObj(this.dict.asbItemAll,'id',absForDel[i].asbitemId)
lfind = arrayExistObj(this.dict.asbItemAll, 'id', absForDel[i].asbitemId)
if (lfind > -1) this.dict.asbItem.push(this.dict.asbItemAll[lfind])
absForDel.splice(i, 1)
@ -710,7 +730,7 @@ export default {
}
if(Array.isArray(this.itemTypeIds) && this.itemTypeIds.length > 0 ) this.changeItemTypeIds(this.itemTypeIds)
if (Array.isArray(this.itemTypeIds) && this.itemTypeIds.length > 0) this.changeItemTypeIds(this.itemTypeIds)
// //
this.refAsbItemByChoosed()
@ -984,19 +1004,10 @@ export default {
})
let group = deepCopy(this.customerOrgGroup);
postapi('/api/app/customerorggroupdetail/createcustomerorggroupdetailmany', body
)
// .then(res => {
// if(res.code != -1){
// delete group.id;
// delete group.customerOrgId;
// delete group.isComplete;
// group.price = this.groupPrice
// // console.log('this.customerOrgGroup',this.customerOrgGroup)
// // console.log('group',group)
// return putapi(`/api/app/customer-org-group/${this.customerOrgGroup.id}`, group)
// }
// })
this.checkAsbItemHC()
.then(() => {
return postapi('/api/app/customerorggroupdetail/createcustomerorggroupdetailmany', body)
})
.then(res => {
if (res && res.code != -1) {
console.log("操作成功");
@ -1042,36 +1053,126 @@ export default {
},
// /
btnCopyGroupAsbitem(){
if(this.customerOrgGroupAsbitems.length == 0){
this.$message.warning({showClose:true,message:'没有可复制的项目,请先选择分组'})
btnCopyGroupAsbitem() {
if (this.customerOrgGroupAsbitems.length == 0) {
this.$message.warning({ showClose: true, message: '没有可复制的项目,请先选择分组' })
return
}
this.dataTransOpts.copyGroupAsbitem = deepCopy(this.customerOrgGroupAsbitems)
this.$message.success({showClose:true,message:'操作成功!'})
this.$message.success({ showClose: true, message: '操作成功!' })
},
// /
btnPastGroupAsbitem(){
let lfind = -1
btnPastGroupAsbitem() {
let lfind = -1, lfind2 = -1
this.dataTransOpts.copyGroupAsbitem.forEach(e => {
lfind = arrayExistObj(this.customerOrgGroupAsbitems,'asbitemId',e.asbitemId)
if(lfind == -1){
let pojo = Object.assign({},e,{id:Date.now(),})
this.customerOrgGroupAsbitems.push(pojo)
lfind = arrayExistObj(this.customerOrgGroupAsbitems, 'asbitemId', e.asbitemId)
if (lfind == -1) {
lfind2 = arrayExistObj(this.dict.asbItemAll, 'id', e.asbitemId)
if (lfind2 > -1) {
let pojo = Object.assign({}, e, { id: Date.now(), })
if (this.customerOrgGroup.forSexId == 'A' && this.customerOrgGroup.maritalStatusId == 'A') {
this.customerOrgGroupAsbitems.push(pojo)
} else {
let pasteAble = true //
if (this.customerOrgGroup.forSexId != 'A'){
if (!(this.dict.asbItemAll[lfind2].forSexId == 'A' || this.dict.asbItemAll[lfind2].forSexId == 'U')) {
if (this.dict.asbItemAll[lfind2].forSexId != this.customerOrgGroup.forSexId) {
this.$message.warning({showClose:true,message:`${this.dict.asbItemAll[lfind2].displayName} 不适合当前性别`})
pasteAble = false
}
}
}
//
if (!(checked || this.dict.asbItemAll[lfind2].maritalStatusId == 'A' || this.dict.asbItemAll[lfind2].maritalStatusId == 'U')) {
if (this.dict.asbItemAll[lfind2].maritalStatusId != this.customerOrgGroup.maritalStatusId) {
this.$message.warning({showClose:true,message:`${this.dict.asbItemAll[lfind2].displayName} 不适合当前婚姻状态`})
pasteAble = false
}
}
if(pasteAble) this.customerOrgGroupAsbitems.push(pojo)
}
}
}
});
this.dataTransOpts.copyGroupAsbitem = []
this.refAsbItemByChoosed()
this.$message.success({showClose:true,message:'操作成功!'})
}
this.$message.success({ showClose: true, message: '操作成功!' })
},
//
checkAsbItemHC() {
return new Promise((resolve, reject) => {
let asbitemIds = []
//console.log('this.dataTransOpts.tableM.register_check_asbitem',this.dataTransOpts.tableM.register_check_asbitem)
this.customerOrgGroupAsbitems.forEach(e => {
asbitemIds.push(e.asbitemId)
});
let message = ''
if (asbitemIds.length == 0) {
resolve()
} else {
postapi('/api/app/AsbitemMutualExclusion/GetAsbitemIsMutualExclusion', { asbitemIds })
.then(res => {
if (res.code > -1) {
if (res?.data?.message) message = res.data.message
}
})
.finally(() => {
if (message) {
switch (this.hc_warn_mode) {
case '1': ''
this.$confirm(`${message} 是否继续?`, "提示", {
confirmButtonText: "是",
cancelButtonText: " 否 ",
type: "warning",
})
.then(() => {
resolve()
})
.catch((err) => {
reject(message)
// if (err == "cancel") {
// console.log("");
// }
});
break;
case '2':
this.$message.error({ showClose: true, message })
reject(message)
break;
default:
this.$message.warning({ showClose: true, message })
resolve()
break;
}
} else {
resolve()
}
})
}
})
},
},
//
watch: {
//
"dataTransOpts.tableS.customer_org_group.id": {
handler(newVal, oldVal) {
if (newVal != oldVal) {
if (!(Array.isArray(this.itemTypeIds) && this.itemTypeIds.length > 0)) {
this.dict.asbItem = []
}
}
}
},
// ID
"dataTransOpts.refresh.customer_org_group_detail.M": {
// immediate:true,
@ -1082,13 +1183,13 @@ export default {
},
//
"groupVisble":{
"groupVisble": {
handler(newVal, oldVal) {
if(newVal){
console.log('customerOrgGroup',this.customerOrgGroup,this.customerOrgAll,this.curOrgRegisterList)
if (newVal) {
console.log('customerOrgGroup', this.customerOrgGroup, this.customerOrgAll, this.curOrgRegisterList)
this.customerOrgDisp = deepCopy(this.customerOrgAll)
this.customerOrgRegisterList = deepCopy(this.curOrgRegisterList)
this.customerOrgRegister = deepCopy(this.curOrgRegister)
this.customerOrgRegister = deepCopy(this.curOrgRegister)
this.customerOrgId = this.customerOrgGroup.customerOrgId
this.customerOrgGroups = deepCopy(this.curOrgGroups)
}

4
src/components/doctorCheck/RegisterCheckEdit.vue

@ -20,13 +20,13 @@
<div>
<span class="query">审核医生</span>
<el-select v-model="doctorCheck.RegisterCheckEdit.auditorUserId" filterable clearable placeholder="请选择"
style="width: 80px" size="small" disabled>
style="width: 80px" size="small" :disabled="doctorCheck.RegisterCheckEdit.isAudit == 'Y' ? true:false">
<el-option v-for="item in users" :key="item.id" :label="item.surname" :value="item.id" />
</el-select>
</div>
<div>
<span class="query">审核日期</span>
<el-date-picker v-model="doctorCheck.RegisterCheckEdit.auditTime" type="datetime" style="width: 90px" size="small" disabled/>
<el-date-picker v-model="doctorCheck.RegisterCheckEdit.auditTime" type="datetime" style="width: 90px" size="small" :disabled="doctorCheck.RegisterCheckEdit.isAudit == 'Y' ? true:false" />
</div>
<div>
<el-select v-model="doctorCheck.RegisterCheckEdit.isAudit" style="width: 60px" size="small" disabled>

6
src/components/patientRegister/patientRegisterQuery.vue

@ -194,6 +194,12 @@ export default {
this.patientRegister.query.sex = ''
this.patientRegister.query.phone = ''
this.patientRegister.query.idCardNo = ''
this.patientRegister.query.medicalTypeIds = null
this.patientRegister.query.completeFlags = null
this.patientRegister.query.personnelTypeIds = null
this.patientRegister.query.isRecoverGuide = null
},
init(customerOrgId) {

1
src/store/index.js

@ -213,6 +213,7 @@ export default new Vuex.Store({
patientName: '', //姓名
sex: '', //性别
idCardNo: '', //身份证号
phone:'', // 手机号
isReportPrint:'', // 报告是否打印
isSeries: 'N',
isSmsComplete: "N",

2
src/views/doctorCheck/doctorCheck.vue

@ -835,6 +835,8 @@ export default {
//auditorUserId: "3fa85f64-5717-4562-b3fc-2c963f66afa6",
//auditTime: "string"
}
if(this.doctorCheck.RegisterCheckEdit.auditorUserId) body.auditorUserId = this.doctorCheck.RegisterCheckEdit.auditorUserId
console.log(`/api/app/registercheck/updateauditordoctor`, body)
postapi(`/api/app/registercheck/updateauditordoctor`, body)

Loading…
Cancel
Save