|
@@ -375,6 +375,7 @@ func (this *StaffScheduleApiController) UpdatePatientScheduleById() {
|
375
|
375
|
func (this *StaffScheduleApiController) UpdateDialysisPrescription() {
|
376
|
376
|
patient_id, _ := this.GetInt64("patient_id")
|
377
|
377
|
start_time, _ := this.GetInt64("start_time")
|
|
378
|
+ mode_id, _ := this.GetInt64("mode_id")
|
378
|
379
|
dialyzer_perfusion_apparatus := this.GetString("dialyzer_perfusion_apparatus")
|
379
|
380
|
//更改透析模式
|
380
|
381
|
_, errcode := service.GetDialyisSolution(patient_id, start_time)
|
|
@@ -388,8 +389,10 @@ func (this *StaffScheduleApiController) UpdateDialysisPrescription() {
|
388
|
389
|
Status: 1,
|
389
|
390
|
RecordDate: start_time,
|
390
|
391
|
CreatedTime: time.Now().Unix(),
|
|
392
|
+ ModeId: mode_id,
|
391
|
393
|
}
|
392
|
394
|
err := service.CreateDialysisPrescription(&prescription)
|
|
395
|
+
|
393
|
396
|
if err != nil {
|
394
|
397
|
this.ServeFailJsonSend(enums.ErrorCodeDataException, "添加设备失败")
|
395
|
398
|
return
|
|
@@ -401,8 +404,9 @@ func (this *StaffScheduleApiController) UpdateDialysisPrescription() {
|
401
|
404
|
prescription := models.DialysisPrescription{
|
402
|
405
|
DialyzerPerfusionApparatus: dialyzer_perfusion_apparatus,
|
403
|
406
|
DialysisDialyszers: dialyzer_perfusion_apparatus,
|
|
407
|
+ ModeId: mode_id,
|
404
|
408
|
}
|
405
|
|
- err := service.UpdateDialysisPrescriptionOne(prescription, patient_id, start_time)
|
|
409
|
+ err := service.UpdateDialysisPrescriptionOne(prescription, patient_id, start_time, mode_id)
|
406
|
410
|
if err != nil {
|
407
|
411
|
this.ServeFailJsonSend(enums.ErrorCodeDataException, "添加设备失败")
|
408
|
412
|
return
|