|
@@ -899,6 +899,9 @@
|
899
|
899
|
|
900
|
900
|
|
901
|
901
|
<el-tab-pane label="使用登记" name="third">
|
|
902
|
+ <div class="userbutton">
|
|
903
|
+ <el-button @click="ToReminders">使用登记提醒配置</el-button>
|
|
904
|
+ </div>
|
902
|
905
|
<div v-show="UserShow">
|
903
|
906
|
<el-tabs v-model="activeNameThree" @tab-click="handleClick">
|
904
|
907
|
<el-tab-pane label="新增使用登记" name="first">
|
|
@@ -1896,6 +1899,8 @@
|
1896
|
1899
|
<!-- <edit-machine-form ref="editmachineform" :planid="planid" ></edit-machine-form> -->
|
1897
|
1900
|
<!-- 综合查询 -->
|
1898
|
1901
|
<multiple-form ref="multipleform" :equimentid="equimentid"></multiple-form>
|
|
1902
|
+ <!-- 使用登记提醒配置 -->
|
|
1903
|
+ <remander-form ref="remanderform"> </remander-form>
|
1899
|
1904
|
<!-- 编辑消毒计划 -->
|
1900
|
1905
|
<el-dialog title="编辑消毒计划" :visible.sync="dialogVisible" width="50%" center>
|
1901
|
1906
|
<el-form :model="machineform" ref="machineform">
|
|
@@ -2025,7 +2030,7 @@
|
2025
|
2030
|
import { getAllSubregion, getAllMachine, getMachineDetailById,
|
2026
|
2031
|
UpdateMachineInfo, getAllPlan, getAllPlanDetail, DeletePlans,
|
2027
|
2032
|
getAllEquimentName, EditPlanDetail, UpdatePlanInfo, SaveInformation, getPatientInfo,
|
2028
|
|
- ChangeClass, getAllOrganization, getUserRegister, SaveQualityControl, getOrgName, SaveRepair, SaveBacteria, SaveLincomycin, getAutoData, getAllEquitType, UpdateMacheineTwo, getTotalNumber, getTimeWarning, getAllpatient, UpdateMachineInfoTwo } from '@/api/manage'
|
|
2033
|
+ ChangeClass, getAllOrganization, getUserRegister, SaveQualityControl, getOrgName, SaveRepair, SaveBacteria, SaveLincomycin, getAutoData, getAllEquitType, UpdateMacheineTwo, getTotalNumber, getTimeWarning, getAllpatient, UpdateMachineInfoTwo, getPatientDetail } from '@/api/manage'
|
2029
|
2034
|
import { uParseTime } from '@/utils/tools'
|
2030
|
2035
|
import { getToken } from '@/api/qiniu'
|
2031
|
2036
|
import PlanForm from './components/PlanForm'
|
|
@@ -2034,6 +2039,7 @@
|
2034
|
2039
|
import UserForm from './components/UserForm'
|
2035
|
2040
|
import QualityForm from './components/QualityForm'
|
2036
|
2041
|
import RepairForm from './components/RepairForm'
|
|
2042
|
+ import RemanderForm from './components/RemanderForm'
|
2037
|
2043
|
import { parseTime } from '@/utils'
|
2038
|
2044
|
import { getFileExtension } from '@/utils/tools'
|
2039
|
2045
|
import { PostSearch } from '@/api/patient'
|
|
@@ -2048,7 +2054,8 @@ export default {
|
2048
|
2054
|
MultipleForm,
|
2049
|
2055
|
UserForm,
|
2050
|
2056
|
QualityForm,
|
2051
|
|
- RepairForm
|
|
2057
|
+ RepairForm,
|
|
2058
|
+ RemanderForm
|
2052
|
2059
|
},
|
2053
|
2060
|
data() {
|
2054
|
2061
|
return {
|
|
@@ -2621,7 +2628,7 @@ export default {
|
2621
|
2628
|
getMachineDetailById(id).then(response => {
|
2622
|
2629
|
if (response.data.state === 1) {
|
2623
|
2630
|
var addmacher = response.data.data.addmacher
|
2624
|
|
- // console.log('addmacher======', addmacher)
|
|
2631
|
+ // console.log('addmacher======', addmacher)
|
2625
|
2632
|
if (addmacher.device_type === 1) {
|
2626
|
2633
|
this.sShow = false
|
2627
|
2634
|
this.qShow = false
|
|
@@ -2892,7 +2899,7 @@ export default {
|
2892
|
2899
|
var disinfecction_modes = this.form.Disinfection_mode
|
2893
|
2900
|
var disinfecction_modess = parseInt(disinfecction_modes)
|
2894
|
2901
|
this.form.Disinfection_mode = disinfecction_modess
|
2895
|
|
-
|
|
2902
|
+
|
2896
|
2903
|
this.$refs[formName].validate(valid => {
|
2897
|
2904
|
if (valid) {
|
2898
|
2905
|
UpdateMachineInfoTwo(this.form).then(response => {
|
|
@@ -2955,6 +2962,9 @@ export default {
|
2955
|
2962
|
addPlan() {
|
2956
|
2963
|
this.$refs.planForm.open()
|
2957
|
2964
|
},
|
|
2965
|
+ ToReminders() {
|
|
2966
|
+ this.$refs.remanderform.open()
|
|
2967
|
+ },
|
2958
|
2968
|
changeCheck() {
|
2959
|
2969
|
this.$refs.multipleTableOne.clearSelection()
|
2960
|
2970
|
if (this.checkAllStatusOne) {
|
|
@@ -2986,7 +2996,7 @@ export default {
|
2986
|
2996
|
getAllPlan().then(response => {
|
2987
|
2997
|
if (response.data.state === 1) {
|
2988
|
2998
|
var plan = response.data.data.plan
|
2989
|
|
-
|
|
2999
|
+
|
2990
|
3000
|
for (let index = 0; index < plan.length; index++) {
|
2991
|
3001
|
if (plan[index].time === 1) {
|
2992
|
3002
|
plan[index].time = '周一'
|
|
@@ -3439,7 +3449,7 @@ export default {
|
3439
|
3449
|
ChangeClass(this.equimentid, id).then(response => {
|
3440
|
3450
|
if (response.data.state === 1) {
|
3441
|
3451
|
var patients = response.data.data.patients
|
3442
|
|
-
|
|
3452
|
+
|
3443
|
3453
|
if (patients.is_infectious === 0) {
|
3444
|
3454
|
this.userform.contagion = ''
|
3445
|
3455
|
}
|
|
@@ -3472,7 +3482,13 @@ export default {
|
3472
|
3482
|
}
|
3473
|
3483
|
})
|
3474
|
3484
|
},
|
3475
|
|
-
|
|
3485
|
+ updateTimes(time) {
|
|
3486
|
+ if (time < 0) {
|
|
3487
|
+ return ''
|
|
3488
|
+ } else {
|
|
3489
|
+ return uParseTime(time, '{y}-{m}-{d} {h}:{i}')
|
|
3490
|
+ }
|
|
3491
|
+ },
|
3476
|
3492
|
getTimes(time) {
|
3477
|
3493
|
return uParseTime(time, '{y}-{m}-{d} {h}:{i}')
|
3478
|
3494
|
},
|
|
@@ -3557,11 +3573,22 @@ export default {
|
3557
|
3573
|
this.userform.clean = 0
|
3558
|
3574
|
}
|
3559
|
3575
|
|
3560
|
|
- if (this.userform.starttime === '') {
|
3561
|
|
- this.userform.starttime = 0
|
|
3576
|
+ // eslint-disable-next-line eqeqeq
|
|
3577
|
+ if (this.userform.start_time == '') {
|
|
3578
|
+ this.userform.start_time = '0'
|
|
3579
|
+ }
|
|
3580
|
+ // eslint-disable-next-line eqeqeq
|
|
3581
|
+ if (this.userform.end_time == '') {
|
|
3582
|
+ this.userform.end_time = '0'
|
|
3583
|
+ }
|
|
3584
|
+
|
|
3585
|
+ // eslint-disable-next-line eqeqeq
|
|
3586
|
+ if (this.userform.starttime == '') {
|
|
3587
|
+ this.userform.starttime = '0'
|
3562
|
3588
|
}
|
3563
|
|
- if (this.userform.endtime === '') {
|
3564
|
|
- this.userform.endtime = 0
|
|
3589
|
+ // eslint-disable-next-line eqeqeq
|
|
3590
|
+ if (this.userform.endtime == '') {
|
|
3591
|
+ this.userform.endtime = '0'
|
3565
|
3592
|
}
|
3566
|
3593
|
|
3567
|
3594
|
if (this.userform.hyperfiltratio === '') {
|
|
@@ -3570,25 +3597,19 @@ export default {
|
3570
|
3597
|
var hyperfiltratio = this.userform.hyperfiltratio
|
3571
|
3598
|
var hyperfiltratios = parseInt(hyperfiltratio)
|
3572
|
3599
|
this.userform.hyperfiltratio = hyperfiltratios
|
3573
|
|
- // this.userform.starttime = this.getTimes(this.userform.starttime)
|
3574
|
|
- // this.userform.endtime = this.getTimes(this.userform.endtime)
|
3575
|
|
-
|
|
3600
|
+
|
3576
|
3601
|
if (this.userform.weight_loss === '') {
|
3577
|
3602
|
this.userform.weight_loss = 0
|
3578
|
3603
|
}
|
3579
|
3604
|
var weightloss = this.userform.weight_loss
|
3580
|
3605
|
var weidht = parseInt(weightloss)
|
3581
|
3606
|
this.userform.weight_loss = weidht
|
3582
|
|
-
|
3583
|
|
- if (this.userform.start_time === '') {
|
3584
|
|
- this.userform.start_time = '0'
|
3585
|
|
- }
|
3586
|
|
- if (this.userform.end_time === '') {
|
3587
|
|
- this.userform.end_time = '0'
|
3588
|
|
- }
|
|
3607
|
+
|
3589
|
3608
|
if (this.userform.user_total === '0') {
|
3590
|
3609
|
this.userform.user_total = 0
|
3591
|
3610
|
}
|
|
3611
|
+ console.log('上机时间', this.userform.start_time)
|
|
3612
|
+ console.log('下机时间', this.userform.end_time)
|
3592
|
3613
|
this.$refs[formName].validate((valid) => {
|
3593
|
3614
|
if (valid) {
|
3594
|
3615
|
SaveInformation(this.equimentid, this.userform).then(response => {
|
|
@@ -3596,6 +3617,10 @@ export default {
|
3596
|
3617
|
// eslint-disable-next-line no-unused-vars
|
3597
|
3618
|
var information = response.data.data.information
|
3598
|
3619
|
var infor = response.data.data.infor
|
|
3620
|
+ this.userform.start_time = ''
|
|
3621
|
+ this.userform.end_time = ''
|
|
3622
|
+ this.userform.starttime = ''
|
|
3623
|
+ this.userform.endtime = ''
|
3599
|
3624
|
this.$message.success('添加成功')
|
3600
|
3625
|
// this.$refs.child.getInformationData()
|
3601
|
3626
|
}
|
|
@@ -3642,7 +3667,7 @@ export default {
|
3642
|
3667
|
// console.log('role', role)
|
3643
|
3668
|
// eslint-disable-next-line eqeqeq
|
3644
|
3669
|
var dislysis = response.data.data.dislysis
|
3645
|
|
-
|
|
3670
|
+
|
3646
|
3671
|
this.userform.id = information.id
|
3647
|
3672
|
if (information.date == 0) {
|
3648
|
3673
|
this.userform.date = moment(new Date()).format('YYYY-MM-DD')
|
|
@@ -3658,9 +3683,10 @@ export default {
|
3658
|
3683
|
this.userform.patient_id = information.patient_id
|
3659
|
3684
|
this.userform.contagion = information.contagion
|
3660
|
3685
|
this.userform.dialysis_mode = information.dialysis_mode
|
3661
|
|
-
|
3662
|
|
- this.userform.start_time = uParseTime(information.start_time, '{y}-{m}-{d} {h}:{i}')
|
3663
|
|
- this.userform.end_time = uParseTime(information.end_time, '{y}-{m}-{d} {h}:{i}')
|
|
3686
|
+ this.userform.start_time = this.updateTimes(information.start_time)
|
|
3687
|
+ // this.userform.start_time = uParseTime(information.start_time, '{y}-{m}-{d} {h}:{i}')
|
|
3688
|
+ this.userform.end_time = this.updateTimes(information.end_time)
|
|
3689
|
+ // this.userform.end_time = uParseTime(information.end_time, '{y}-{m}-{d} {h}:{i}')
|
3664
|
3690
|
// this.userform.dialysis_time = information.dialysis_hour
|
3665
|
3691
|
// this.userform.hyperfiltratio = information.hyperfiltratio
|
3666
|
3692
|
// this.userform.weight_loss = information.weight_loss
|
|
@@ -3685,8 +3711,10 @@ export default {
|
3685
|
3711
|
this.userform.disinfectant = information.disinfection_status
|
3686
|
3712
|
this.userform.disinfection_residue = information.disinfection_residue
|
3687
|
3713
|
this.userform.longtime = information.long_time
|
3688
|
|
- this.userform.starttime = uParseTime(information.disinfec_startime, '{y}-{m}-{d} {h}:{i}')
|
3689
|
|
- this.userform.endtime = uParseTime(information.disinfec_endtime, '{y}-{m}-{d} {h}:{i}')
|
|
3714
|
+ this.userform.starttime = this.updateTimes(information.disinfec_startime)
|
|
3715
|
+ this.userform.endtime = this.updateTimes(information.disinfec_endtime)
|
|
3716
|
+ // this.userform.starttime = uParseTime(information.disinfec_startime, '{y}-{m}-{d} {h}:{i}')
|
|
3717
|
+ // this.userform.endtime = uParseTime(information.disinfec_endtime, '{y}-{m}-{d} {h}:{i}')
|
3690
|
3718
|
|
3691
|
3719
|
if (information.dialysis_checked === 1) {
|
3692
|
3720
|
this.userform.dialysis_checked = true
|
|
@@ -4005,6 +4033,26 @@ export default {
|
4005
|
4033
|
handleSelect(item) {
|
4006
|
4034
|
this.userform.patient_id = item.id
|
4007
|
4035
|
this.userform.patient_name = item.name
|
|
4036
|
+ // eslint-disable-next-line no-undef
|
|
4037
|
+ getPatientDetail(item.id).then(response => {
|
|
4038
|
+ // eslint-disable-next-line eqeqeq
|
|
4039
|
+ if (response.data.state == 1) {
|
|
4040
|
+ var patient = response.data.data.patient
|
|
4041
|
+ console.log('patient', patient)
|
|
4042
|
+ // eslint-disable-next-line no-undef
|
|
4043
|
+ if (patient.is_infectious === 0) {
|
|
4044
|
+ this.userform.contagion = ''
|
|
4045
|
+ }
|
|
4046
|
+ // eslint-disable-next-line no-undef
|
|
4047
|
+ if (patient.is_infectious === 1) {
|
|
4048
|
+ this.userform.contagion = '无'
|
|
4049
|
+ }
|
|
4050
|
+ // eslint-disable-next-line no-undef
|
|
4051
|
+ if (patient.is_infectious === 2) {
|
|
4052
|
+ this.userform.contagion = '有'
|
|
4053
|
+ }
|
|
4054
|
+ }
|
|
4055
|
+ })
|
4008
|
4056
|
},
|
4009
|
4057
|
getAllEquitType() {
|
4010
|
4058
|
getAllEquitType().then(response => {
|
|
@@ -4032,7 +4080,7 @@ export default {
|
4032
|
4080
|
getAllpatient().then(response => {
|
4033
|
4081
|
if (response.data.state === 1) {
|
4034
|
4082
|
var allpatient = response.data.data.allpatient
|
4035
|
|
-
|
|
4083
|
+
|
4036
|
4084
|
this.patientName = allpatient
|
4037
|
4085
|
}
|
4038
|
4086
|
})
|
|
@@ -4041,24 +4089,32 @@ export default {
|
4041
|
4089
|
getTimeWarning(id).then(response => {
|
4042
|
4090
|
if (response.data.state === 1) {
|
4043
|
4091
|
var information = response.data.data.information
|
4044
|
|
- var time = this.userform.date - information.date
|
|
4092
|
+ console.log(this.getTimestamp(this.userform.date))
|
|
4093
|
+ console.log(information.stime)
|
|
4094
|
+ var time = this.getTimestamp(this.userform.date) - information.stime
|
|
4095
|
+ console.log('时间', time)
|
4045
|
4096
|
if (time >= 2678400) {
|
4046
|
4097
|
this.warnShow = true
|
4047
|
4098
|
}
|
4048
|
4099
|
var deviceInformation = response.data.data.deviceInformation
|
4049
|
|
- var timetwo = this.userform.date - deviceInformation.date
|
|
4100
|
+
|
|
4101
|
+ var timetwo = this.getTimestamp(this.userform.date) - deviceInformation.stime
|
4050
|
4102
|
if (timetwo >= 2678400) {
|
4051
|
4103
|
this.warnShowTwo = true
|
4052
|
4104
|
}
|
4053
|
4105
|
var clean = response.data.data.clean
|
4054
|
|
- var timethree = this.userform.date - clean.date
|
|
4106
|
+ var timethree = this.getTimestamp(this.userform.date) - clean.stime
|
4055
|
4107
|
if (timethree >= 2678400) {
|
4056
|
4108
|
this.warnShowThree = true
|
4057
|
4109
|
}
|
4058
|
4110
|
}
|
4059
|
4111
|
})
|
4060
|
4112
|
},
|
|
4113
|
+ getTimestamp(time) { // 把时间日期转成时间戳
|
|
4114
|
+ return (new Date(time)).getTime() / 1000
|
|
4115
|
+ },
|
4061
|
4116
|
|
|
4117
|
+ // eslint-disable-next-line no-irregular-whitespace
|
4062
|
4118
|
// 通过自组建传值改变表格数据
|
4063
|
4119
|
getPlanData(data) {
|
4064
|
4120
|
if (data === 1) {
|
|
@@ -4129,6 +4185,10 @@ export default {
|
4129
|
4185
|
font-size: 14px;
|
4130
|
4186
|
}
|
4131
|
4187
|
|
|
4188
|
+ .userbutton{
|
|
4189
|
+ margin-left:985px;
|
|
4190
|
+ }
|
|
4191
|
+
|
4132
|
4192
|
</style>
|
4133
|
4193
|
<style lang="scss">
|
4134
|
4194
|
|