new_monitor.go 5.1KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. package models
  2. type NewVMMonitorDialysisSchedule 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 VMMonitorPatients `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 VMMonitorDialysisOrder `gorm:"ForeignKey:PatientId;AssociationForeignKey:PatientId" json:"dialysis_order"`
  17. Prescription VMDialysisPrescription `gorm:"ForeignKey:PatientId;AssociationForeignKey:PatientId" json:"prescription"`
  18. AssessmentBeforeDislysis VMPredialysisEvaluation `gorm:"ForeignKey:PatientId;AssociationForeignKey:PatientId" json:"assessment_before_dislysis"`
  19. AssessmentAfterDislysis VMAssessmentAfterDislysis `gorm:"ForeignKey:PatientId;AssociationForeignKey:PatientId" json:"assessment_after_dislysis"`
  20. MonitoringRecord []VMMonitoringRecord `gorm:"ForeignKey:PatientId;AssociationForeignKey:PatientId" json:"monitoring_record"`
  21. }
  22. func (NewVMMonitorDialysisSchedule) TableName() string {
  23. return "xt_schedule"
  24. }
  25. type VMMonitorPatients struct {
  26. ID int64 `gorm:"column:id" json:"id" form:"id"`
  27. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  28. Name string `gorm:"column:name" json:"name" form:"name"`
  29. Status int64 `gorm:"column:status" json:"status" form:"status"`
  30. DialysisNo string `gorm:"column:dialysis_no" json:"dialysis_no" form:"dialysis_no"`
  31. }
  32. func (VMMonitorPatients) TableName() string {
  33. return "xt_patients"
  34. }
  35. type VMMonitorDialysisOrder struct {
  36. ID int64 `gorm:"column:id" json:"id"`
  37. DialysisDate int64 `gorm:"column:dialysis_date" json:"dialysis_date"`
  38. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id"`
  39. PatientId int64 `gorm:"column:patient_id" json:"patient_id"`
  40. BedID int64 `gorm:"column:bed_id" json:"bed_id"`
  41. Status int64 `gorm:"column:status" json:"status"`
  42. DeviceNumber DeviceNumber `gorm:"ForeignKey:BedId" json:"device_number"`
  43. }
  44. func (VMMonitorDialysisOrder) TableName() string {
  45. return "xt_dialysis_order"
  46. }
  47. type VMDialysisPrescription struct {
  48. ID int64 `gorm:"column:id" json:"id"`
  49. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id"`
  50. PatientId int64 `gorm:"column:patient_id" json:"patient_id"`
  51. Status int64 `gorm:"column:status" json:"status"`
  52. RecordDate int64 `gorm:"column:record_date" json:"record_date"`
  53. TargetUltrafiltration float64 `gorm:"column:target_ultrafiltration" json:"target_ultrafiltration"`
  54. }
  55. func (VMDialysisPrescription) TableName() string {
  56. return "xt_dialysis_prescription"
  57. }
  58. type VMPredialysisEvaluation struct {
  59. ID int64 `gorm:"column:id" json:"id"`
  60. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id"`
  61. PatientId int64 `gorm:"column:patient_id" json:"patient_id"`
  62. AssessmentDate int64 `gorm:"column:assessment_date" json:"assessment_date"`
  63. WeighingBefore float64 `gorm:"column:weighing_before" json:"weighing_before"`
  64. WeightBefore float64 `gorm:"column:weight_before" json:"weight_before"`
  65. Status int64 `gorm:"column:status" json:"status"`
  66. }
  67. func (VMPredialysisEvaluation) TableName() string {
  68. return "xt_assessment_before_dislysis"
  69. }
  70. type VMAssessmentAfterDislysis struct {
  71. ID int64 `gorm:"column:id" json:"id"`
  72. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id"`
  73. PatientId int64 `gorm:"column:patient_id" json:"patient_id"`
  74. AssessmentDate int64 `gorm:"column:assessment_date" json:"assessment_date"`
  75. WeightAfter float64 `gorm:"column:weight_after" json:"weight_after"`
  76. Status int64 `gorm:"column:status" json:"status"`
  77. }
  78. func (VMAssessmentAfterDislysis) TableName() string {
  79. return "xt_assessment_after_dislysis"
  80. }
  81. type VMMonitoringRecord struct {
  82. ID int64 `gorm:"column:id" json:"id"`
  83. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id"`
  84. PatientId int64 `gorm:"column:patient_id" json:"patient_id"`
  85. MonitoringDate int64 `gorm:"column:monitoring_date" json:"monitoring_date"`
  86. SystolicBloodPressure float64 `gorm:"column:systolic_blood_pressure" json:"systolic_blood_pressure"`
  87. DiastolicBloodPressure float64 `gorm:"column:diastolic_blood_pressure" json:"diastolic_blood_pressure"`
  88. Status int64 `gorm:"column:status" json:"status"`
  89. }
  90. func (VMMonitoringRecord) TableName() string {
  91. return "xt_monitoring_record"
  92. }