Browse Source

预约时间选择优化

360view
bianyaqi 2 years ago
parent
commit
f3bc29942e
  1. 43
      src/page-subspecialty/views/modules/nurseManagement/reservation/schedule/addPatientOrder.vue
  2. 4
      src/page-subspecialty/views/modules/nurseManagement/reservation/schedule/doctor-schedule.vue
  3. 11
      src/page-subspecialty/views/modules/nurseManagement/reservation/schedule/number-detail-manage.vue

43
src/page-subspecialty/views/modules/nurseManagement/reservation/schedule/addPatientOrder.vue

@ -82,13 +82,14 @@
</el-col> </el-col>
<el-col class="line" style="text-align: center" :span="2">-</el-col> <el-col class="line" style="text-align: center" :span="2">-</el-col>
<el-col :span="11"> <el-col :span="11">
<el-time-select
v-model="form.date2"
:picker-options="{...timeRange}"
value-format="HH:mm:ss"
placeholder="选择时间"
style="width: 100%;"
/>
<el-form-item prop="date2">
<el-time-picker
v-model="form.date2"
value-format="HH:mm:ss"
placeholder="选择时间"
style="width: 100%;"
/>
</el-form-item>
</el-col> </el-col>
</el-form-item> </el-form-item>
</el-form> </el-form>
@ -118,9 +119,6 @@ export default {
isEdit: { isEdit: {
type: Boolean, type: Boolean,
default: false default: false
},
isPm: {
type: Boolean
} }
}, },
data() { data() {
@ -136,7 +134,6 @@ export default {
eyeType: '', eyeType: '',
pupilDilate: '', pupilDilate: '',
pupilShrink: '', pupilShrink: '',
date: '',
date1: '', date1: '',
date2: '' date2: ''
}, },
@ -147,23 +144,15 @@ export default {
} }
}, },
computed: { computed: {
timeRange() {
return this.isPm ? {
start: '12:00',
step: '00:15',
end: '21:30'
} : {
start: '07:30',
step: '00:15',
end: '12:00'
}
},
dataRule() { dataRule() {
return { return {
patientId: [ patientId: [
{ required: true, message: '请选择患者' } { required: true, message: '请选择患者' }
], ],
date: [
date1: [
{ required: true, message: '请选择日期' }
],
date2: [
{ required: true, message: '请选择时间' } { required: true, message: '请选择时间' }
] ]
} }
@ -180,8 +169,9 @@ export default {
this.form.pupilShrink = this.patientDetail.pupilShrink this.form.pupilShrink = this.patientDetail.pupilShrink
this.form.remark = this.patientDetail.remark this.form.remark = this.patientDetail.remark
this.form.yzOpen = this.patientDetail.yzOpen this.form.yzOpen = this.patientDetail.yzOpen
this.form.date = this.patientDetail.appointDate
this.form.date1 = this.patientDetail.appointDate.split(' ')[0] this.form.date1 = this.patientDetail.appointDate.split(' ')[0]
this.form.date2 = this.patientDetail.appointDate.split(' ')[1].substring(0, 5)
this.form.date2 = this.patientDetail.appointDate.split(' ')[1]
this.patientInfo = this.patientDetail this.patientInfo = this.patientDetail
} }
}, },
@ -218,7 +208,7 @@ export default {
return false return false
} }
const params = { const params = {
appointDate: `${this.form.date1} ${this.form.date2}:00`,
appointDate: `${this.form.date1} ${this.form.date2}`,
patientName: this.patientInfo.patientName, patientName: this.patientInfo.patientName,
jzNumber: this.patientInfo.jzNumber, jzNumber: this.patientInfo.jzNumber,
appointSource: this.patientInfo.source, appointSource: this.patientInfo.source,
@ -234,7 +224,7 @@ export default {
}) })
} else { } else {
const params = { const params = {
appointDate: `${this.form.date1} ${this.form.date2}:00`,
appointDate: `${this.form.date1} ${this.form.date2}`,
doctorId: this.form.doctorId, doctorId: this.form.doctorId,
doctorName: this.form.doctorName, doctorName: this.form.doctorName,
patientId: this.form.patientId, patientId: this.form.patientId,
@ -293,3 +283,4 @@ input{
} }
} }
</style> </style>

4
src/page-subspecialty/views/modules/nurseManagement/reservation/schedule/doctor-schedule.vue

@ -573,8 +573,6 @@ export default {
this.$nextTick(() => { this.$nextTick(() => {
this.$refs.addScheduleRef.dataForm.title = '预约医生' this.$refs.addScheduleRef.dataForm.title = '预约医生'
this.$refs.addScheduleRef.dataForm.doctorName = item.doctorName this.$refs.addScheduleRef.dataForm.doctorName = item.doctorName
// this.$refs.addScheduleRef.dataForm.doctorCode = item.doctorCode
// this.$refs.addScheduleRef.dataForm.operaName = item.expertise
this.$refs.addScheduleRef.dataForm.operaTime = flag === 'morning' ? weekInfoItem.date + ' 07:30:00' : weekInfoItem.date + ' 14:00:00' this.$refs.addScheduleRef.dataForm.operaTime = flag === 'morning' ? weekInfoItem.date + ' 07:30:00' : weekInfoItem.date + ' 14:00:00'
this.$refs.addScheduleRef.params = item this.$refs.addScheduleRef.params = item
this.$refs.addScheduleRef.init() this.$refs.addScheduleRef.init()
@ -607,8 +605,6 @@ export default {
this.$refs.numberManageRef.projectName = item.itemName this.$refs.numberManageRef.projectName = item.itemName
this.$refs.numberManageRef.weekName = weekInfoItem.weekName this.$refs.numberManageRef.weekName = weekInfoItem.weekName
this.$refs.numberManageRef.morOrAft = morOrAft this.$refs.numberManageRef.morOrAft = morOrAft
// this.$refs.numberManageRef.dataForm.doctorCode = item.doctorCode
// this.$refs.numberManageRef.dataForm.operaDate = weekInfoItem.date
this.$refs.numberManageRef.init() this.$refs.numberManageRef.init()
}) })
}, },

11
src/page-subspecialty/views/modules/nurseManagement/reservation/schedule/number-detail-manage.vue

@ -27,7 +27,6 @@
<add-patient-order <add-patient-order
v-if="addPatientVisible" v-if="addPatientVisible"
ref="addPatientOrder" ref="addPatientOrder"
:is-pm="isPm"
:project="curProject" :project="curProject"
:patient-detail="curPatient" :patient-detail="curPatient"
:title="addTitle" :title="addTitle"
@ -59,7 +58,6 @@ export default {
visible: false, visible: false,
addPatientVisible: false, addPatientVisible: false,
dateInfo: '', dateInfo: '',
isPm: false,
isEdit: false, isEdit: false,
projectName: '', projectName: '',
curProject: '', curProject: '',
@ -68,15 +66,6 @@ export default {
addTitle: '' addTitle: ''
} }
}, },
watch: {
dateInfo(value) {
if (value.includes('下午')) {
this.isPm = true
} else {
this.isPm = false
}
}
},
methods: { methods: {
init() { init() {
this.visible = true this.visible = true

Loading…
Cancel
Save