sign_weigh_models.go 8.1KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  1. package models
  2. type SignWeighRecord struct {
  3. ID int64 `gorm:"column:id" json:"id"`
  4. OrgID int64 `gorm:"column:org_id" json:"-"`
  5. PatientID int64 `gorm:"column:patient_id" json:"patient_id"`
  6. ClothesWeight float64 `gorm:"column:clothes_weight" json:"clothes_weight"`
  7. WeighBefore float64 `gorm:"column:weigh_before" json:"weigh_before"`
  8. TemperatureBefore float64 `gorm:"column:temperature_before" json:"temperature_before"`
  9. PulseRateBefore float64 `gorm:"column:pulse_rate_before" json:"pulse_rate_before"`
  10. RespiratoryRateBefore float64 `gorm:"column:respiratory_rate_before" json:"respiratory_rate_before"`
  11. DBPBefore float64 `gorm:"column:dbp_before" json:"dbp_before"`
  12. SBPBefore float64 `gorm:"column:sbp_before" json:"sbp_before"`
  13. WeighAfter float64 `gorm:"column:weigh_after" json:"weigh_after"`
  14. TemperatureAfter float64 `gorm:"column:temperature_after" json:"temperature_after"`
  15. PulseRateAfter float64 `gorm:"column:pulse_rate_after" json:"pulse_rate_after"`
  16. RespiratoryRateAfter float64 `gorm:"column:respiratory_rate_after" json:"respiratory_rate_after"`
  17. DBPAfter float64 `gorm:"column:dbp_after" json:"dbp_after"`
  18. SBPAfter float64 `gorm:"column:sbp_after" json:"sbp_after"`
  19. Status int8 `gorm:"column:status" json:"-"`
  20. CreateTime int64 `gorm:"column:ctime" json:"-"`
  21. ModifyTime int64 `gorm:"column:mtime" json:"-"`
  22. }
  23. func (SignWeighRecord) TableName() string {
  24. return "xt_sign_weigh"
  25. }
  26. type SigninAndWeigh struct {
  27. ID int64 `gorm:"column:id" json:"id" form:"id"`
  28. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  29. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  30. RecordDate int64 `gorm:"column:record_date" json:"record_date" form:"record_date"`
  31. SignTime int64 `gorm:"column:sign_time" json:"sign_time" form:"sign_time"`
  32. WeighTime int64 `gorm:"column:weigh_time" json:"weigh_time" form:"weigh_time"`
  33. WeighBeforeTime int64 `gorm:"column:weigh_before_time" json:"weigh_before_time" form:"weigh_before_time"`
  34. DryWeight float64 `gorm:"column:dry_weight" json:"dry_weight" form:"dry_weight"`
  35. ClothingWeight float64 `gorm:"column:clothing_weight" json:"clothing_weight" form:"clothing_weight"`
  36. WeightBefore float64 `gorm:"column:weight_before" json:"weight_before" form:"weight_before"`
  37. WeighingBefore float64 `gorm:"column:weighing_before" json:"weighing_before" form:"weighing_before"`
  38. TargetDewatering float64 `gorm:"column:target_dewatering" json:"target_dewatering" form:"target_dewatering"`
  39. TemperatureBefore float64 `gorm:"column:temperature_before" json:"temperature_before" form:"temperature_before"`
  40. PulseFrequencyBefore float64 `gorm:"column:pulse_frequency_before" json:"pulse_frequency_before" form:"pulse_frequency_before"`
  41. BreathingRateBefore float64 `gorm:"column:breathing_rate_before" json:"breathing_rate_before" form:"breathing_rate_before"`
  42. SystolicBloodPressureBefore float64 `gorm:"column:systolic_blood_pressure_before" json:"systolic_blood_pressure_before" form:"systolic_blood_pressure_before"`
  43. DiastolicBloodPressureBefore float64 `gorm:"column:diastolic_blood_pressure_before" json:"diastolic_blood_pressure_before" form:"diastolic_blood_pressure_before"`
  44. WeightAfter float64 `gorm:"column:weight_after" json:"weight_after" form:"weight_after"`
  45. WeighingAfter float64 `gorm:"column:weighing_after" json:"weighing_after" form:"weighing_after"`
  46. WeightLoss float64 `gorm:"column:weight_loss" json:"weight_loss" form:"weight_loss"`
  47. TemperatureAfter float64 `gorm:"column:temperature_after" json:"temperature_after" form:"temperature_after"`
  48. PulseFrequencyAfter float64 `gorm:"column:pulse_frequency_after" json:"pulse_frequency_after" form:"pulse_frequency_after"`
  49. BreathingRateAfter float64 `gorm:"column:breathing_rate_after" json:"breathing_rate_after" form:"breathing_rate_after"`
  50. SystolicBloodPressureAfter float64 `gorm:"column:systolic_blood_pressure_after" json:"systolic_blood_pressure_after" form:"systolic_blood_pressure_after"`
  51. DiastolicBloodPressureAfter float64 `gorm:"column:diastolic_blood_pressure_after" json:"diastolic_blood_pressure_after" form:"diastolic_blood_pressure_after"`
  52. Status int64 `gorm:"column:status" json:"status" form:"status"`
  53. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  54. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  55. }
  56. func (SigninAndWeigh) TableName() string {
  57. return "xt_signin_and_weigh"
  58. }
  59. type SignPatients struct {
  60. Patients
  61. Schedule Schedule `json:"schedule" gorm:"foreignkey:PatientId"`
  62. SignWeight SignWeight `json:"signin" gorm:"foreignkey:PatientId"`
  63. DialysisOrder DialysisOrder `json:"dialysis_order" gorm:"foreignkey:PatientId"`
  64. PredialysisEvaluation PredialysisEvaluation `json:"predialysisevaluation" gorm:"foreignkey:PatientId"`
  65. }
  66. func (SignPatients) TableName() string {
  67. return "xt_patients"
  68. }
  69. type SignWeight struct {
  70. ID int64 `gorm:"column:id" json:"id" form:"id"`
  71. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  72. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  73. SignTime int64 `gorm:"column:sign_time" json:"sign_time" form:"sign_time"`
  74. RecordDate int64 `gorm:"column:record_date" json:"record_date" form:"record_date"`
  75. WeightBefore float64 `gorm:"column:weightbefore" json:"weightbefore" form:"weightbefore"`
  76. DryWeightBefore float64 `gorm:"column:dry_weight_before" json:"dry_weight_before" form:"dry_weight_before"`
  77. TemperatureBefore float64 `gorm:"column:temperature_before" json:"temperature_before" form:"temperature_before"`
  78. PulseFrequencyBefore float64 `gorm:"column:pulse_frequency_before" json:"pulse_frequency_before" form:"pulse_frequency_before"`
  79. BreathingRateBefore float64 `gorm:"column:breathing_rate_before" json:"breathing_rate_before" form:"breathing_rate_before"`
  80. SystolicBloodPressureBefore float64 `gorm:"column:systolic_blood_pressure_before" json:"systolic_blood_pressure_before" form:"systolic_blood_pressure_before"`
  81. DiastolicBloodPressureBefore float64 `gorm:"column:diastolic_blood_pressure_before" json:"diastolic_blood_pressure_before" form:"diastolic_blood_pressure_before"`
  82. WeightAfter float64 `gorm:"column:weightafter" json:"weightafter" form:"weightafter"`
  83. TemperatureAfter float64 `gorm:"column:temperature_after" json:"temperature_after" form:"temperature_after"`
  84. PulseFrequencyAfter float64 `gorm:"column:pulse_frequency_after" json:"pulse_frequency_after" form:"pulse_frequency_after"`
  85. BreathingRateAfter float64 `gorm:"column:breathing_rate_after" json:"breathing_rate_after" form:"breathing_rate_after"`
  86. SystolicBloodPressureAfter float64 `gorm:"column:systolic_blood_pressure_after" json:"systolic_blood_pressure_after" form:"systolic_blood_pressure_after"`
  87. DiastolicBloodPressureAfter float64 `gorm:"column:diastolic_blood_pressure_after" json:"diastolic_blood_pressure_after" form:"diastolic_blood_pressure_after"`
  88. Status int64 `gorm:"column:status" json:"status" form:"status"`
  89. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  90. WeighBeforeTime int64 `gorm:"column:weigh_before_time" json:"weigh_before_time" form:"weigh_before_time"`
  91. WeighTime int64 `gorm:"column:weigh_time" json:"weigh_time" form:"weigh_time"`
  92. }
  93. func (SignWeight) TableName() string {
  94. return "xt_sign_weight"
  95. }