monitor_models.go 14KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170
  1. package models
  2. type VMMonitorDialysisSchedule struct {
  3. ID int64 `gorm:"column:id" json:"id"`
  4. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id"`
  5. PartitionId int64 `gorm:"column:partition_id" json:"partition_id"`
  6. BedId int64 `gorm:"column:bed_id" json:"bed_id"`
  7. PatientId int64 `gorm:"column:patient_id" json:"patient_id"`
  8. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date"`
  9. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type"`
  10. ModeId int64 `gorm:"column:mode_id" json:"mode_id"`
  11. Status int64 `gorm:"column:status" json:"status"`
  12. MonitorPatients MonitorPatients `gorm:"ForeignKey:PatientId" json:"patient"`
  13. DeviceNumber DeviceNumber `gorm:"ForeignKey:BedId" json:"device_number"`
  14. DeviceZone DeviceZone `gorm:"ForeignKey:PartitionId" json:"device_zone"`
  15. TreatmentMode TreatmentMode `gorm:"ForeignKey:ModeId" json:"treatment_mode"`
  16. DialysisOrder MonitorDialysisOrder `gorm:"ForeignKey:PatientId;AssociationForeignKey:PatientId" json:"dialysis_order"`
  17. Prescription DialysisPrescription `gorm:"ForeignKey:PatientId;AssociationForeignKey:PatientId" json:"prescription"`
  18. AssessmentBeforeDislysis PredialysisEvaluation `gorm:"ForeignKey:PatientId;AssociationForeignKey:PatientId" json:"assessment_before_dislysis"`
  19. AssessmentAfterDislysis AssessmentAfterDislysis `gorm:"ForeignKey:PatientId;AssociationForeignKey:PatientId" json:"assessment_after_dislysis"`
  20. MonitoringRecord []MonitoringRecord `gorm:"ForeignKey:PatientId;AssociationForeignKey:PatientId" json:"monitoring_record"`
  21. }
  22. func (VMMonitorDialysisSchedule) TableName() string {
  23. return "xt_schedule"
  24. }
  25. type MonitorDialysisSchedule struct {
  26. ID int64 `gorm:"column:id" json:"id"`
  27. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id"`
  28. PartitionId int64 `gorm:"column:partition_id" json:"partition_id"`
  29. BedId int64 `gorm:"column:bed_id" json:"bed_id"`
  30. PatientId int64 `gorm:"column:patient_id" json:"patient_id"`
  31. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date"`
  32. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type"`
  33. ModeId int64 `gorm:"column:mode_id" json:"mode_id"`
  34. Status int64 `gorm:"column:status" json:"status"`
  35. MonitorPatients MonitorPatients `gorm:"ForeignKey:PatientId" json:"patient"`
  36. DeviceNumber DeviceNumber `gorm:"ForeignKey:BedId" json:"device_number"`
  37. DeviceZone DeviceZone `gorm:"ForeignKey:PartitionId" json:"device_zone"`
  38. TreatmentMode TreatmentMode `gorm:"ForeignKey:ModeId" json:"treatment_mode"`
  39. DialysisOrder MonitorDialysisOrder `gorm:"ForeignKey:DialysisDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId" json:"dialysis_order"`
  40. Prescription DialysisPrescription `gorm:"ForeignKey:RecordDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId" json:"prescription"`
  41. AssessmentBeforeDislysis PredialysisEvaluation `gorm:"ForeignKey:AssessmentDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId" json:"assessment_before_dislysis"`
  42. AssessmentAfterDislysis AssessmentAfterDislysis `gorm:"ForeignKey:AssessmentDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId" json:"assessment_after_dislysis"`
  43. MonitoringRecord []MonitoringRecord `gorm:"ForeignKey:MonitoringDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId" json:"monitoring_record"`
  44. }
  45. func (MonitorDialysisSchedule) TableName() string {
  46. return "xt_schedule"
  47. }
  48. type MonitorPatients struct {
  49. ID int64 `gorm:"column:id" json:"id" form:"id"`
  50. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  51. UserId int64 `gorm:"column:user_id" json:"user_id" form:"user_id"`
  52. Avatar string `gorm:"column:avatar" json:"avatar" form:"avatar"`
  53. PatientType int64 `gorm:"column:patient_type" json:"patient_type" form:"patient_type"`
  54. DialysisNo string `gorm:"column:dialysis_no" json:"dialysis_no" form:"dialysis_no"`
  55. AdmissionNumber string `gorm:"column:admission_number" json:"admission_number" form:"admission_number"`
  56. Source int64 `gorm:"column:source" json:"source" form:"source"`
  57. Lapseto int64 `gorm:"column:lapseto" json:"lapseto" form:"lapseto"`
  58. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  59. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  60. Name string `gorm:"column:name" json:"name" form:"name"`
  61. Alias string `gorm:"column:alias" json:"alias" form:"alias"`
  62. Gender int64 `gorm:"column:gender" json:"gender" form:"gender"`
  63. Nation string `gorm:"column:nation" json:"nation" form:"nation"`
  64. NativePlace string `gorm:"column:native_place" json:"native_place" form:"native_place"`
  65. MaritalStatus int64 `gorm:"column:marital_status" json:"marital_status" form:"marital_status"`
  66. IdCardNo string `gorm:"column:id_card_no" json:"id_card_no" form:"id_card_no"`
  67. Birthday int64 `gorm:"column:birthday" json:"birthday" form:"birthday"`
  68. ReimbursementWayId int64 `gorm:"column:reimbursement_way_id" json:"reimbursement_way_id" form:"reimbursement_way_id"`
  69. HealthCareType int64 `gorm:"column:health_care_type" json:"health_care_type" form:"health_care_type"`
  70. HealthCareNo string `gorm:"column:health_care_no" json:"health_care_no" form:"health_care_no"`
  71. HealthCareDueDate int64 `gorm:"column:health_care_due_date" json:"health_care_due_date" form:"health_care_due_date"`
  72. Height int64 `gorm:"column:height" json:"height" form:"height"`
  73. BloodType int64 `gorm:"column:blood_type" json:"blood_type" form:"blood_type"`
  74. Rh int64 `gorm:"column:rh" json:"rh" form:"rh"`
  75. HealthCareDueAlertDate int64 `gorm:"column:health_care_due_alert_date" json:"health_care_due_alert_date" form:"health_care_due_alert_date"`
  76. EducationLevel int64 `gorm:"column:education_level" json:"education_level" form:"education_level"`
  77. Profession int64 `gorm:"column:profession" json:"profession" form:"profession"`
  78. Phone string `gorm:"column:phone" json:"phone" form:"phone"`
  79. HomeTelephone string `gorm:"column:home_telephone" json:"home_telephone" form:"home_telephone"`
  80. RelativePhone string `gorm:"column:relative_phone" json:"relative_phone" form:"relative_phone"`
  81. RelativeRelations string `gorm:"column:relative_relations" json:"relative_relations" form:"relative_relations"`
  82. HomeAddress string `gorm:"column:home_address" json:"home_address" form:"home_address"`
  83. WorkUnit string `gorm:"column:work_unit" json:"work_unit" form:"work_unit"`
  84. UnitAddress string `gorm:"column:unit_address" json:"unit_address" form:"unit_address"`
  85. Children int64 `gorm:"column:children" json:"children" form:"children"`
  86. ReceivingDate int64 `gorm:"column:receiving_date" json:"receiving_date" form:"receiving_date"`
  87. IsHospitalFirstDialysis int64 `gorm:"column:is_hospital_first_dialysis" json:"is_hospital_first_dialysis" form:"is_hospital_first_dialysis"`
  88. FirstDialysisDate int64 `gorm:"column:first_dialysis_date" json:"first_dialysis_date" form:"first_dialysis_date"`
  89. FirstDialysisHospital string `gorm:"column:first_dialysis_hospital" json:"first_dialysis_hospital" form:"first_dialysis_hospital"`
  90. PredialysisCondition string `gorm:"column:predialysis_condition" json:"predialysis_condition" form:"predialysis_condition"`
  91. PreHospitalDialysisFrequency string `gorm:"column:pre_hospital_dialysis_frequency" json:"pre_hospital_dialysis_frequency" form:"pre_hospital_dialysis_frequency"`
  92. PreHospitalDialysisTimes int64 `gorm:"column:pre_hospital_dialysis_times" json:"pre_hospital_dialysis_times" form:"pre_hospital_dialysis_times"`
  93. HospitalFirstDialysisDate int64 `gorm:"column:hospital_first_dialysis_date" json:"hospital_first_dialysis_date" form:"hospital_first_dialysis_date"`
  94. InductionPeriod int64 `gorm:"column:induction_period" json:"induction_period" form:"induction_period"`
  95. InitialDialysis int64 `gorm:"column:initial_dialysis" json:"initial_dialysis" form:"initial_dialysis"`
  96. TotalDialysis int64 `gorm:"column:total_dialysis" json:"total_dialysis" form:"total_dialysis"`
  97. AttendingDoctorId int64 `gorm:"column:attending_doctor_id" json:"attending_doctor_id" form:"attending_doctor_id"`
  98. HeadNurseId int64 `gorm:"column:head_nurse_id" json:"head_nurse_id" form:"head_nurse_id"`
  99. Evaluate string `gorm:"column:evaluate" json:"evaluate" form:"evaluate"`
  100. Diagnose string `gorm:"column:diagnose" json:"diagnose" form:"diagnose"`
  101. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  102. RegistrarsId int64 `gorm:"column:registrars_id" json:"registrars_id" form:"registrars_id"`
  103. Registrars string `gorm:"column:registrars" json:"registrars" form:"registrars"`
  104. QrCode string `gorm:"column:qr_code" json:"qr_code" form:"qr_code"`
  105. BindingState int64 `gorm:"column:binding_state" json:"binding_state" form:"binding_state"`
  106. PatientComplains string `gorm:"column:patient_complains" json:"patient_complains"` // 主诉
  107. PresentHistory string `gorm:"column:present_history" json:"present_history"` // 现病史
  108. PastHistory string `gorm:"column:past_history" json:"past_history"` // 既往史
  109. Temperature float64 `gorm:"column:temperature" json:"temperature"` // 体格检查-体温
  110. Pulse int64 `gorm:"column:pulse" json:"pulse"` // 体格检查-脉搏
  111. Respiratory int64 `gorm:"column:respiratory" json:"respiratory"` // 体格检查-呼吸频率
  112. SBP int64 `gorm:"column:sbp" json:"sbp"` // 体格检查-收缩压
  113. DBP int64 `gorm:"column:dbp" json:"dbp"` // 体格检查-舒张压
  114. Status int64 `gorm:"column:status" json:"status" form:"status"`
  115. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  116. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  117. Age int64 `gorm:"column:age" json:"age"`
  118. IsOpenRemind int64 `gorm:"column:is_open_remind" json:"is_open_remind"`
  119. DialysisAge int64 `gorm:"column:dialysis_age" json:"dialysis_age" form:"dialysis_age"`
  120. ExpenseKind int64 `gorm:"column:expense_kind" json:"expense_kind" form:"expense_kind"`
  121. TellPhone string `gorm:"column:tell_phone" json:"tell_phone" form:"tell_phone"`
  122. FirstTreatmentDate int64 `gorm:"column:first_treatment_date" json:"first_treatment_date" form:"first_treatment_date"`
  123. ContactName string `gorm:"column:contact_name" json:"contact_name" form:"contact_name"`
  124. UserSysBeforeCount int64 `gorm:"column:user_sys_before_count" json:"user_sys_before_count" form:"user_sys_before_count"`
  125. SchRemark string `gorm:"column:sch_remark" json:"sch_remark" form:"sch_remark"`
  126. }
  127. func (MonitorPatients) TableName() string {
  128. return "xt_patients"
  129. }
  130. type MonitorDialysisOrder struct {
  131. ID int64 `gorm:"column:id" json:"id"`
  132. DialysisDate int64 `gorm:"column:dialysis_date" json:"dialysis_date"`
  133. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id"`
  134. PatientId int64 `gorm:"column:patient_id" json:"patient_id"`
  135. PrescriptionId int64 `gorm:"column:prescription_id" json:"prescription_id"`
  136. Stage int64 `gorm:"column:stage" json:"stage"`
  137. Remark string `gorm:"column:remark" json:"remark"`
  138. BedID int64 `gorm:"column:bed_id" json:"bed_id"`
  139. StartNurse int64 `gorm:"column:start_nurse" json:"start_nurse"`
  140. FinishNurse int64 `gorm:"column:finish_nurse" json:"finish_nurse"`
  141. Status int64 `gorm:"column:status" json:"status"`
  142. CreatedTime int64 `gorm:"column:created_time" json:"created_time"`
  143. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time"`
  144. StartTime int64 `gorm:"column:start_time" json:"start_time"`
  145. EndTime int64 `gorm:"column:end_time" json:"end_time"`
  146. DeviceNumber DeviceNumber `gorm:"ForeignKey:BedId" json:"device_number"`
  147. PunctureNurse int64 `gorm:"column:puncture_nurse" json:"puncture_nurse"`
  148. Creator int64 `gorm:"column:creator" json:"creator"`
  149. Modifier int64 `gorm:"column:modifier" json:"modifier"`
  150. FinishCreator int64 `gorm:"column:finish_creator" json:"finish_creator"`
  151. FinishModifier int64 `gorm:"column:finish_modifier" json:"finish_modifier"`
  152. SchedualType int64 `gorm:"column:schedual_type" json:"schedual_type"`
  153. WashpipeNurse int64 `gorm:"column:washpipe_nurse" json:"washpipe_nurse" form:"washpipe_nurse"`
  154. }
  155. func (MonitorDialysisOrder) TableName() string {
  156. return "xt_dialysis_order"
  157. }