schedule_models.go 62KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839
  1. package models
  2. type VmSchedules struct {
  3. ID int64 `gorm:"column:id" json:"id" form:"id"`
  4. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  5. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  6. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  7. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  8. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  9. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  10. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  11. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  12. Status int64 `gorm:"column:status" json:"status" form:"status"`
  13. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  14. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  15. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  16. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:ID;AssociationForeignKey:PartitionId;"`
  17. DeviceNumber DeviceNumber `json:"number" gorm:"foreignkey:ID;AssociationForeignKey:BedId;"`
  18. DialysisOrder DialysisOrder `json:"order" gorm:"foreignkey:DialysisDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  19. XtPatients XtPatients `json:"patient" gorm:"foreignkey:ID;AssociationForeignKey:PatientId;"`
  20. DoctorAdvice []*DoctorAdvice `json:"doctoradvice" gorm:"foreignkey:AdviceDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  21. DialysisPrescription DialysisPrescription `json:"prescription" gorm:"foreignkey:RecordDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  22. HisDoctorAdviceInfo []*HisDoctorAdviceInfo `json:"hisdoctoradviceinfo" gorm:"foreignkey:AdviceDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  23. DialysisSolution []*DialysisSolution `json:"dialysissolution" gorm:"foreignkey:RecordDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  24. }
  25. func (VmSchedules) TableName() string {
  26. return "xt_schedule"
  27. }
  28. type Schedule struct {
  29. ID int64 `gorm:"column:id" json:"id" form:"id"`
  30. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  31. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  32. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  33. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  34. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  35. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  36. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  37. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  38. Status int64 `gorm:"column:status" json:"status" form:"status"`
  39. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  40. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  41. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  42. Patient string `gorm:"-" json:"patient" form:"patient"`
  43. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:ID;AssociationForeignKey:PartitionId;"`
  44. DeviceNumber DeviceNumber `json:"number" gorm:"foreignkey:ID;AssociationForeignKey:BedId;"`
  45. TreatmentMode TreatmentMode `json:"mode" gorm:"foreignkey:ModeId"`
  46. DialysisOrder DialysisOrder `json:"order" gorm:"foreignkey:DialysisDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  47. DialysisPrescription DialysisPrescription `json:"dialysis_prescription" gorm:"foreignkey:RecordDate,PatientId;AssociationForeignKey:RecordDate,PatientId;"`
  48. PatientInfectiousDiseases []InfectiousDiseases `json:"patient_contagions" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  49. DialysisMachineName string `gorm:"column:dialysis_machine_name" json:"dialysis_machine_name" form:"dialysis_machine_name"`
  50. }
  51. func (Schedule) TableName() string {
  52. return "xt_schedule"
  53. }
  54. type ScheduleTwo struct {
  55. ID int64 `gorm:"column:id" json:"id" form:"id"`
  56. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  57. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  58. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  59. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  60. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  61. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  62. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  63. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  64. Status int64 `gorm:"column:status" json:"status" form:"status"`
  65. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  66. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  67. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  68. Patient string `gorm:"-" json:"patient" form:"patient"`
  69. PatientInfectiousDiseases []InfectiousDiseases `json:"patient_contagions" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  70. DialysisMachineName string `gorm:"column:dialysis_machine_name" json:"dialysis_machine_name" form:"dialysis_machine_name"`
  71. DialysisSolution VmDialysisSolutionOne `json:"dialysissolution" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId;"`
  72. }
  73. func (ScheduleTwo) TableName() string {
  74. return "xt_schedule"
  75. }
  76. type ScheduleThree struct {
  77. ID int64 `gorm:"column:id" json:"id" form:"id"`
  78. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  79. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  80. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  81. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  82. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  83. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  84. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  85. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  86. Status int64 `gorm:"column:status" json:"status" form:"status"`
  87. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  88. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  89. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  90. Patient string `gorm:"-" json:"patient" form:"patient"`
  91. DialysisMachineName string `gorm:"column:dialysis_machine_name" json:"dialysis_machine_name" form:"dialysis_machine_name"`
  92. DialysisSolution VmDialysisSolutionOne `json:"dialysissolution" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId;"`
  93. SchedulePatientsOne SchedulePatientsOne `json:"next_schedule" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  94. DeviceNumber DeviceNumber `json:"number" gorm:"foreignkey:ID;AssociationForeignKey:BedId;"`
  95. }
  96. func (ScheduleThree) TableName() string {
  97. return "xt_schedule"
  98. }
  99. type SchedulePatientsOne struct {
  100. ID int64 `gorm:"column:id" json:"id" form:"id"`
  101. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  102. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  103. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  104. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  105. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  106. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  107. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  108. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  109. Status int64 `gorm:"column:status" json:"status" form:"status"`
  110. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  111. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  112. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  113. }
  114. func (SchedulePatientsOne) TableName() string {
  115. return "xt_schedule"
  116. }
  117. type SchedulePatients struct {
  118. ID int64 `gorm:"column:id" json:"id" form:"id"`
  119. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  120. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  121. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  122. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  123. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  124. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  125. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  126. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  127. Status int64 `gorm:"column:status" json:"status" form:"status"`
  128. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  129. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  130. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  131. Patient PatientListForFace `json:"patient" gorm:"foreignkey:ID;AssociationForeignKey:PatientId;"`
  132. }
  133. func (SchedulePatients) TableName() string {
  134. return "xt_schedule"
  135. }
  136. type XtTreatmentMode struct {
  137. ID int64 `gorm:"column:id" json:"id" form:"id"`
  138. Name string `gorm:"column:name" json:"name" form:"name"`
  139. DialysisDuration int64 `gorm:"column:dialysis_duration" json:"dialysis_duration" form:"dialysis_duration"`
  140. ReplacementWay int64 `gorm:"column:replacement_way" json:"replacement_way" form:"replacement_way"`
  141. HemodialysisMachine int64 `gorm:"column:hemodialysis_machine" json:"hemodialysis_machine" form:"hemodialysis_machine"`
  142. BloodFilter int64 `gorm:"column:blood_filter" json:"blood_filter" form:"blood_filter"`
  143. PerfusionApparatus int64 `gorm:"column:perfusion_apparatus" json:"perfusion_apparatus" form:"perfusion_apparatus"`
  144. BloodFlowVolume int64 `gorm:"column:blood_flow_volume" json:"blood_flow_volume" form:"blood_flow_volume"`
  145. DialysateFlow int64 `gorm:"column:dialysate_flow" json:"dialysate_flow" form:"dialysate_flow"`
  146. Kalium int64 `gorm:"column:kalium" json:"kalium" form:"kalium"`
  147. Sodium int64 `gorm:"column:sodium" json:"sodium" form:"sodium"`
  148. Calcium int64 `gorm:"column:calcium" json:"calcium" form:"calcium"`
  149. Bicarbonate int64 `gorm:"column:bicarbonate" json:"bicarbonate" form:"bicarbonate"`
  150. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  151. Status int64 `gorm:"column:status" json:"status" form:"status"`
  152. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  153. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  154. ModeID int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  155. }
  156. func (XtTreatmentMode) TableName() string {
  157. return "xt_treatment_mode"
  158. }
  159. type PatientSchedule struct {
  160. Schedule
  161. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:PartitionId"`
  162. DeviceNumber DeviceNumber `json:"bed" gorm:"foreignkey:BedId"`
  163. Week int64 `gorm:"-" json:"week" form:"week"`
  164. TreatmentMode TreatmentMode `json:"mode" gorm:"foreignkey:ModeId"`
  165. }
  166. type Partition struct {
  167. DeviceZone
  168. Jihaos []DeviceNumber `json:"jihaos" gorm:"foreignkey:ZoneID"`
  169. }
  170. type Search_Schedule struct {
  171. ID int64 `gorm:"column:id" json:"id" form:"id"`
  172. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  173. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  174. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  175. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  176. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  177. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  178. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  179. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  180. Status int64 `gorm:"column:status" json:"status" form:"status"`
  181. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  182. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  183. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  184. DialysisMachineName string `gorm:"column:dialysis_machine_name" json:"dialysis_machine_name" form:"dialysis_machine_name"`
  185. Patient string `gorm:"-" json:"patient" form:"patient"`
  186. }
  187. func (Search_Schedule) TableName() string {
  188. return "xt_schedule"
  189. }
  190. type WeekSchedule struct {
  191. ID int64 `gorm:"column:id" json:"id" form:"id"`
  192. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  193. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  194. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  195. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  196. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  197. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  198. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  199. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  200. Status int64 `gorm:"column:status" json:"status" form:"status"`
  201. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  202. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  203. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  204. DialysisMachineName string `gorm:"column:dialysis_machine_name" json:"dialysis_machine_name" form:"dialysis_machine_name"`
  205. Patient string `gorm:"-" json:"patient" form:"patient"`
  206. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:ID;AssociationForeignKey:PartitionId;"`
  207. DeviceNumber DeviceNumber `json:"number" gorm:"foreignkey:ID;AssociationForeignKey:BedId;"`
  208. DialysisPrescription DialysisSolution `json:"prescription" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId"`
  209. DoctorAdvice []*DoctorAdvice `json:"doctoradvice" gorm:"foreignkey:AdviceDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  210. HisDoctorAdviceInfo []*HisDoctorAdviceInfo `json:"hisdoctoradviceinfo" gorm:"foreignkey:AdviceDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  211. Solution []*DialysisSolution `json:"solution" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId"`
  212. DialysisSolution DialysisSolution `json:"dialysissolution" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId"`
  213. XtAssessmentBeforeDislysis XtAssessmentBeforeDislysis `json:"assessmentbefor" gorm:"foreignkey:PatientId,AssessmentDate;AssociationForeignKey:PatientId,ScheduleDate"`
  214. }
  215. func (WeekSchedule) TableName() string {
  216. return "xt_schedule"
  217. }
  218. type ScheduleTemplate struct {
  219. ID int64 `gorm:"column:id" json:"id" form:"id"`
  220. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  221. TemplateId int64 `gorm:"column:template_id" json:"template_id" form:"template_id"`
  222. Status int64 `gorm:"column:status" json:"status" form:"status"`
  223. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  224. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  225. }
  226. func (ScheduleTemplate) TableName() string {
  227. return "xt_schedule_template"
  228. }
  229. type XtDataPrint struct {
  230. ID int64 `gorm:"column:id" json:"id" form:"id"`
  231. IsOpen int64 `gorm:"column:is_open" json:"is_open" form:"is_open"`
  232. Status int64 `gorm:"column:status" json:"status" form:"status"`
  233. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  234. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  235. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  236. }
  237. func (XtDataPrint) TableName() string {
  238. return "xt_data_print"
  239. }
  240. type VmSchedulesRemind struct {
  241. ID int64 `gorm:"column:id" json:"id" form:"id"`
  242. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  243. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  244. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  245. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  246. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  247. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  248. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  249. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  250. Status int64 `gorm:"column:status" json:"status" form:"status"`
  251. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  252. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  253. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  254. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:ID;AssociationForeignKey:PartitionId;"`
  255. DeviceNumber DeviceNumber `json:"number" gorm:"foreignkey:ID;AssociationForeignKey:BedId;"`
  256. DialysisOrder DialysisOrder `json:"order" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  257. XtPatients XtPatients `json:"patient" gorm:"foreignkey:ID;AssociationForeignKey:PatientId;"`
  258. DoctorAdvice []*DoctorAdvice `json:"doctoradvice" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  259. DialysisPrescription NewDialysisPrescription `json:"prescription" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  260. HisDoctorAdviceInfo []*HisDoctorAdviceInfo `json:"hisdoctoradviceinfo" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  261. DialysisSolution DialysisSolution `json:"dialysissolution" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId;"`
  262. XtAssessmentBeforeDislysis XtAssessmentBeforeDislysis `json:"assessmentbefor" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  263. LastAfterWeight AssessmentAfterDislysis `gorm:"ForeignKey:PatientID;AssociationForeignKey:PatientID" json:"lastafterweight"`
  264. XtDialysisOrderSix XtDialysisOrderSix `json:"dialysis_order" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  265. HisPrescriptionTemplate HisPrescriptionTemplateSix `json:"his_prescription_template" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId;"`
  266. }
  267. func (VmSchedulesRemind) TableName() string {
  268. return "xt_schedule"
  269. }
  270. type WeekScheduleSix struct {
  271. ID int64 `gorm:"column:id" json:"id" form:"id"`
  272. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  273. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  274. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  275. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  276. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  277. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  278. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  279. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  280. Status int64 `gorm:"column:status" json:"status" form:"status"`
  281. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  282. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  283. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  284. IdCardNo string `gorm:"-" json:"id_card_no" form:"id_card_no"`
  285. Gender string `gorm:"-" json:"gender" form:"gender"`
  286. Phone string `gorm:"-" json:"phone" form:"phone"`
  287. DialysisNo string `gorm:"-" json:"dialysis_no" form:"dialysis_no"`
  288. Patient string `gorm:"-" json:"patient" form:"patient"`
  289. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:ID;AssociationForeignKey:PartitionId;"`
  290. DeviceNumber DeviceNumber `json:"number" gorm:"foreignkey:ID;AssociationForeignKey:BedId;"`
  291. DoctorAdvice []*DoctorAdvice `json:"doctoradvice" gorm:"foreignkey:AdviceDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  292. HisDoctorAdviceInfo []*HisDoctorAdviceInfo `json:"hisdoctoradviceinfo" gorm:"foreignkey:AdviceDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  293. DialysisSolution DialysisSolution `json:"dialysissolution" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId"`
  294. XtAssessmentBeforeDislysis XtAssessmentBeforeDislysis `json:"assessmentbefor" gorm:"foreignkey:PatientId,AssessmentDate;AssociationForeignKey:PatientId,ScheduleDate"`
  295. XtDialysisOrderSix XtDialysisOrderSix `json:"dialysis_order" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  296. DialysisPrescription NewDialysisPrescription `json:"prescription" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId"`
  297. HisPrescriptionTemplate HisPrescriptionTemplateSix `json:"his_prescription_template" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId;"`
  298. }
  299. func (WeekScheduleSix) TableName() string {
  300. return "xt_schedule"
  301. }
  302. type BlodSchedule struct {
  303. ID int64 `gorm:"column:id" json:"id" form:"id"`
  304. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  305. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  306. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  307. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  308. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  309. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  310. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  311. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  312. Status int64 `gorm:"column:status" json:"status" form:"status"`
  313. VmBloodPatients VmBloodPatients `json:"patient" gorm:"foreignkey:ID;AssociationForeignKey:PatientId;"`
  314. BloodDialysisOrder BloodPatientDialysisOrder `json:"order" gorm:"foreignkey:DialysisDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  315. BloodDialysisPrescription BloodDialysisPrescription `json:"prescription" gorm:"foreignkey:RecordDate,PatientId;AssociationForeignKey:RecordDate,PatientId;"`
  316. }
  317. func (BlodSchedule) TableName() string {
  318. return "xt_schedule"
  319. }
  320. type BloodPatientDialysisOrder struct {
  321. ID int64 `gorm:"column:id" json:"id" form:"id"`
  322. DialysisDate int64 `gorm:"column:dialysis_date" json:"dialysis_date" form:"dialysis_date"`
  323. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  324. Stage int64 `gorm:"column:stage" json:"stage" form:"stage"`
  325. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  326. }
  327. func (BloodPatientDialysisOrder) TableName() string {
  328. return "xt_dialysis_order"
  329. }
  330. type BloodPatientDialysisPrescription struct {
  331. ID int64 `gorm:"column:id" json:"id" form:"id"`
  332. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  333. MachineType string `gorm:"column:machine_type" json:"machine_type" form:"machine_type"`
  334. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  335. DialysisDialyszers string `gorm:"column:dialysis_dialyszers" json:"dialysis_dialyszers" form:"dialysis_dialyszers"`
  336. DialysisIrrigation string `gorm:"column:dialysis_irrigation" json:"dialysis_irrigation" form:"dialysis_irrigation"`
  337. DialyzerPerfusionApparatus string `gorm:"column:dialyzer_perfusion_apparatus" json:"dialyzer_perfusion_apparatus" form:"dialyzer_perfusion_apparatus"`
  338. }
  339. func (BloodPatientDialysisPrescription) TableName() string {
  340. return "xt_dialysis_prescription"
  341. }
  342. type VmBloodPatients struct {
  343. ID int64 `gorm:"column:id" json:"id" form:"id"`
  344. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  345. Name string `gorm:"column:name" json:"name" form:"name"`
  346. FirstLetter string `gorm:"column:first_letter" json:"first_letter" form:"first_letter"`
  347. }
  348. func (VmBloodPatients) TableName() string {
  349. return "xt_patients"
  350. }
  351. type VmBloodSchedule struct {
  352. ID int64 `gorm:"column:id" json:"id" form:"id"`
  353. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  354. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  355. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  356. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  357. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  358. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  359. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  360. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  361. Status int64 `gorm:"column:status" json:"status" form:"status"`
  362. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  363. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  364. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  365. DeviceNumber *NewMDeviceNumberVM `gorm:"ForeignKey:BedId" json:"device_number"`
  366. SchedualPatient *NewMSchedualPatientVMList `gorm:"ForeignKey:PatientId" json:"patient"`
  367. DialysisSolution DialysisSolution `gorm:"ForeignKey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId" json:"dialysis_solution"`
  368. DialysisPrescription DialysisPrescription `gorm:"ForeignKey:PatientId,RecordDate;AssociationForeignKey:PatientId,ScheduleDate" json:"dialysis_prescription"`
  369. XtAssessmentBeforeDislysis XtAssessmentBeforeDislysis `gorm:"ForeignKey:PatientId,AssessmentDate;AssociationForeignKey:PatientId,ScheduleDate" json:"assessment_befor_dislysis"`
  370. XtDoctorAdvice XtDoctorAdvice `gorm:"ForeignKey:PatientId,AdviceDate;AssociationForeignKey:PatientId,ScheduleDate" json:"xt_doctor_advice"`
  371. XtDoctorAdviceOne []*XtDoctorAdvice `gorm:"ForeignKey:PatientId,AdviceDate;AssociationForeignKey:PatientId,ScheduleDate" json:"advice"`
  372. HisDoctorAdvice []*HisDoctorAdvice `gorm:"ForeignKey:PatientId,AdviceDate;AssociationForeignKey:PatientId,ScheduleDate" json:"his_doctor_advice"`
  373. ReceiveTreatmentAsses ReceiveTreatmentAsses `gorm:"ForeignKey:PatientId,RecordDate;AssociationForeignKey:PatientId,ScheduleDate" json:"xt_receive_treatment_asses"`
  374. XtAssessmentAfterDislysis XtAssessmentAfterDislysis `gorm:"ForeignKey:PatientId,AssessmentDate;AssociationForeignKey:PatientId,ScheduleDate" json:"xt_assesment_after_dislysis"`
  375. LastAfterWeight AssessmentAfterDislysis `gorm:"ForeignKey:PatientID;AssociationForeignKey:PatientID" json:"lastafterweight"`
  376. DialysisMachineName string `gorm:"column:dialysis_machine_name" json:"dialysis_machine_name" form:"dialysis_machine_name"`
  377. LongDoctorAdvice []*XtDoctorAdvice `gorm:"ForeignKey:PatientId;AssociationForeignKey:PatientId" json:"long_doctor_advice"`
  378. }
  379. func (VmBloodSchedule) TableName() string {
  380. return "xt_schedule"
  381. }
  382. type NewMDeviceNumberVM struct {
  383. DeviceNumber
  384. Zone *DeviceZone `gorm:"ForeignKey:ZoneID" json:"zone"`
  385. }
  386. func (NewMDeviceNumberVM) TableName() string {
  387. return "xt_device_number"
  388. }
  389. type NewMSchedualPatientVMList struct {
  390. ID int64 `gorm:"column:id" json:"id" form:"id"`
  391. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  392. UserId int64 `gorm:"column:user_id" json:"user_id" form:"user_id"`
  393. PatientType int64 `gorm:"column:patient_type" json:"patient_type" form:"patient_type"`
  394. DialysisNo string `gorm:"column:dialysis_no" json:"dialysis_no" form:"dialysis_no"`
  395. Avatar string `gorm:"column:avatar" json:"avatar" form:"avatar"`
  396. Gender int64 `gorm:"column:gender" json:"gender" form:"gender"`
  397. Birthday int64 `gorm:"column:birthday" json:"birthday" form:"birthday"`
  398. Age int64 `gorm:"column:age" json:"age"`
  399. Name string `gorm:"column:name" json:"name" form:"name"`
  400. IdCardNo string `gorm:"column:id_card_no" json:"id_card_no" form:"id_card_no"`
  401. UserSysBeforeCount int64 `gorm:"column:user_sys_before_count" json:"user_sys_before_count" form:"user_sys_before_count"`
  402. TrobleShoot int64 `gorm:"column:troble_shoot" json:"troble_shoot" form:"troble_shoot"`
  403. Status int64 `gorm:"column:status" json:"status" form:"status"`
  404. AdmissionNumber string `gorm:"column:admission_number" json:"admission_number" form:"admission_number"`
  405. }
  406. func (NewMSchedualPatientVMList) TableName() string {
  407. return "xt_patients"
  408. }
  409. type VmBloodScheduleTwo struct {
  410. ID int64 `gorm:"column:id" json:"id" form:"id"`
  411. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  412. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  413. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  414. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  415. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  416. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  417. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  418. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  419. Status int64 `gorm:"column:status" json:"status" form:"status"`
  420. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  421. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  422. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  423. DeviceNumber *NewMDeviceNumberVM `gorm:"ForeignKey:BedId" json:"device_number"`
  424. SchedualPatient *NewMSchedualPatientVMList `gorm:"ForeignKey:PatientId" json:"patient"`
  425. HisPrescriptionTemplateSix HisPrescriptionTemplateSix `gorm:"ForeignKey:PatientId,Mode;AssociationForeignKey:PatientId,ModeId" json:"his_prescription_template"`
  426. HisPrescriptionProject []*HisPrescriptionProject `gorm:"ForeignKey:PatientId,schedule_date;AssociationForeignKey:PatientId,RecordDate" json:"his_prescription_project"`
  427. }
  428. func (VmBloodScheduleTwo) TableName() string {
  429. return "xt_schedule"
  430. }
  431. type VmBloodScheduleThree struct {
  432. ID int64 `gorm:"column:id" json:"id" form:"id"`
  433. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  434. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  435. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  436. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  437. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  438. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  439. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  440. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  441. Status int64 `gorm:"column:status" json:"status" form:"status"`
  442. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  443. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  444. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  445. DeviceNumber *NewMDeviceNumberVM `gorm:"ForeignKey:BedId" json:"device_number"`
  446. SchedualPatient *NewMSchedualPatientVMList `gorm:"ForeignKey:PatientId" json:"patient"`
  447. HisPrescriptionTemplateSix HisPrescriptionTemplateSix `gorm:"ForeignKey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId" json:"his_prescription_template"`
  448. }
  449. func (VmBloodScheduleThree) TableName() string {
  450. return "xt_schedule"
  451. }
  452. type HisPrescriptionTemplateSix struct {
  453. ID int64 `gorm:"column:id" json:"id" form:"id"`
  454. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  455. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  456. Type int64 `gorm:"column:type" json:"type" form:"type"`
  457. Status int64 `gorm:"column:status" json:"status" form:"status"`
  458. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  459. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  460. Name string `gorm:"column:name" json:"name" form:"name"`
  461. Mode int64 `gorm:"column:mode" json:"mode" form:"mode"`
  462. HisPrescriptionInfoTemplateSix []*HisPrescriptionInfoTemplateSix `gorm:"ForeignKey:PTemplateId;AssociationForeignKey:ID" json:"his_prescription_info"`
  463. }
  464. func (HisPrescriptionTemplateSix) TableName() string {
  465. return "his_prescription_template"
  466. }
  467. type HisPrescriptionInfoTemplateSix struct {
  468. ID int64 `gorm:"column:id" json:"id" form:"id"`
  469. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  470. RecordDate int64 `gorm:"column:record_date" json:"record_date" form:"record_date"`
  471. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  472. Status int64 `gorm:"column:status" json:"status" form:"status"`
  473. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  474. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  475. Type int64 `gorm:"column:type" json:"type" form:"type"`
  476. Creator int64 `gorm:"column:creator" json:"creator" form:"creator"`
  477. Modifier int64 `gorm:"column:modifier" json:"modifier" form:"modifier"`
  478. PType int64 `gorm:"column:p_type" json:"p_type" form:"p_type"`
  479. PTemplateId int64 `gorm:"column:p_template_id" json:"p_template_id" form:"p_template_id"`
  480. HisPrescriptionProjectTemplateSeven []*HisPrescriptionProjectTemplateSeven `gorm:"ForeignKey:PrescriptionId;AssociationForeignKey:ID" json:"project"`
  481. HisPrescriptionAdviceTemplate []*HisPrescriptionAdviceTemplate `gorm:"ForeignKey:PrescriptionId;AssociationForeignKey:ID" json:"his_advice"`
  482. MedType string `gorm:"column:med_type" json:"med_type" form:"med_type"`
  483. }
  484. func (HisPrescriptionInfoTemplateSix) TableName() string {
  485. return "his_prescription_info_template"
  486. }
  487. type HisPrescriptionProjectTemplateSeven struct {
  488. ID int64 `gorm:"column:id" json:"id" form:"id"`
  489. ProjectId int64 `gorm:"column:project_id" json:"project_id" form:"project_id"`
  490. Price float64 `gorm:"column:price" json:"price" form:"price"`
  491. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  492. Status int64 `gorm:"column:status" json:"status" form:"status"`
  493. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  494. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  495. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  496. HisPatientId int64 `gorm:"column:his_patient_id" json:"his_patient_id" form:"his_patient_id"`
  497. RecordDate int64 `gorm:"column:record_date" json:"record_date" form:"record_date"`
  498. Count string `gorm:"column:count" json:"count" form:"count"`
  499. FeedetlSn string `gorm:"column:feedetl_sn" json:"feedetl_sn" form:"feedetl_sn"`
  500. MedListCodg string `gorm:"column:med_list_codg" json:"med_list_codg" form:"med_list_codg"`
  501. SingleDose string `gorm:"column:single_dose" json:"single_dose" form:"single_dose"`
  502. DeliveryWay string `gorm:"column:delivery_way" json:"delivery_way" form:"delivery_way"`
  503. ExecutionFrequency string `gorm:"column:execution_frequency" json:"execution_frequency" form:"execution_frequency"`
  504. Day string `gorm:"column:day" json:"day" form:"day"`
  505. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  506. Unit string `gorm:"column:unit" json:"unit" form:"unit"`
  507. Type int64 `gorm:"column:type" json:"type" form:"type"`
  508. PrescriptionId int64 `gorm:"column:prescription_id" json:"prescription_id" form:"prescription_id"`
  509. GoodInfo GoodInfoNight `gorm:"ForeignKey:ID;AssociationForeignKey:ProjectId" json:"good_info"`
  510. FrequencyType int64 `gorm:"column:frequency_type" json:"frequency_type" form:"frequency_type"`
  511. DayCount int64 `gorm:"column:day_count" json:"day_count" form:"day_count"`
  512. WeekDay string `gorm:"column:week_day" json:"week_day" form:"week_day"`
  513. }
  514. func (HisPrescriptionProjectTemplateSeven) TableName() string {
  515. return "his_prescription_project_template"
  516. }
  517. type GoodInfoNight struct {
  518. ID int64 `gorm:"column:id" json:"id" form:"id"`
  519. GoodName string `gorm:"column:good_name" json:"good_name" form:"good_name"`
  520. SpecificationName string `gorm:"column:specification_name" json:"specification_name" form:"specification_name"`
  521. GoodTypeId int64 `gorm:"column:good_type_id" json:"good_type_id" form:"good_type_id"`
  522. PackingUnit string `gorm:"column:packing_unit" json:"packing_unit" form:"packing_unit"`
  523. }
  524. func (GoodInfoNight) TableName() string {
  525. return "xt_good_information"
  526. }
  527. type ScheduleTwenty struct {
  528. ID int64 `gorm:"column:id" json:"id" form:"id"`
  529. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  530. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  531. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  532. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  533. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  534. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  535. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  536. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  537. Status int64 `gorm:"column:status" json:"status" form:"status"`
  538. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  539. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  540. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  541. Patient string `gorm:"-" json:"patient" form:"patient"`
  542. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:ID;AssociationForeignKey:PartitionId;"`
  543. DeviceNumber DeviceNumber `json:"number" gorm:"foreignkey:ID;AssociationForeignKey:BedId;"`
  544. TreatmentMode TreatmentMode `json:"mode" gorm:"foreignkey:ModeId"`
  545. DialysisOrderTwenty DialysisOrderTwenty `json:"order" gorm:"foreignkey:DialysisDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  546. }
  547. func (ScheduleTwenty) TableName() string {
  548. return "xt_schedule"
  549. }
  550. type ScheduleTwentyOne struct {
  551. ID int64 `gorm:"column:id" json:"id" form:"id"`
  552. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  553. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  554. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  555. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  556. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  557. Status int64 `gorm:"column:status" json:"status" form:"status"`
  558. }
  559. func (ScheduleTwentyOne) TableName() string {
  560. return "xt_schedule"
  561. }
  562. type VmBloodScheduleOne struct {
  563. ID int64 `gorm:"column:id" json:"id" form:"id"`
  564. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  565. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  566. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  567. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  568. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  569. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  570. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  571. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  572. Status int64 `gorm:"column:status" json:"status" form:"status"`
  573. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  574. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  575. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  576. DeviceNumber *NewMDeviceNumberVM `gorm:"ForeignKey:BedId" json:"device_number"`
  577. SchedualPatient *NewMSchedualPatientVMList `gorm:"ForeignKey:PatientId" json:"patient"`
  578. XtDoctorAdvice []*XtDoctorAdvice `gorm:"ForeignKey:PatientId,AdviceDate;AssociationForeignKey:PatientId,ScheduleDate" json:"xt_doctor_advice"`
  579. HisDoctorAdvice []*HisDoctorAdviceFourty `gorm:"ForeignKey:PatientId,AdviceDate;AssociationForeignKey:PatientId,ScheduleDate" json:"his_doctor_advice"`
  580. }
  581. func (VmBloodScheduleOne) TableName() string {
  582. return "xt_schedule"
  583. }
  584. type VmBloodScheduleSix struct {
  585. ID int64 `gorm:"column:id" json:"id" form:"id"`
  586. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  587. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  588. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  589. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  590. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  591. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  592. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  593. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  594. Status int64 `gorm:"column:status" json:"status" form:"status"`
  595. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  596. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  597. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  598. DeviceNumber *NewMDeviceNumberVM `gorm:"ForeignKey:BedId" json:"device_number"`
  599. SchedualPatient *NewMSchedualPatientVMList `gorm:"ForeignKey:PatientId" json:"patient"`
  600. HisPrescriptionProject []*HisPrescriptionProjectFourty `gorm:"ForeignKey:PatientId,RecordDate;AssociationForeignKey:PatientId,RecordDate" json:"his_doctor_project"`
  601. }
  602. func (VmBloodScheduleSix) TableName() string {
  603. return "xt_schedule"
  604. }
  605. type VmNewSchedulesRemind struct {
  606. ID int64 `gorm:"column:id" json:"id" form:"id"`
  607. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  608. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  609. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  610. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  611. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  612. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  613. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  614. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  615. Status int64 `gorm:"column:status" json:"status" form:"status"`
  616. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  617. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  618. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  619. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:ID;AssociationForeignKey:PartitionId;"`
  620. DeviceNumber DeviceNumber `json:"number" gorm:"foreignkey:ID;AssociationForeignKey:BedId;"`
  621. DialysisOrder NewDialysisOrder `json:"order" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  622. XtPatients XtNewPatients `json:"patient" gorm:"foreignkey:ID;AssociationForeignKey:PatientId;"`
  623. DoctorAdvice []*DoctorAdvice `json:"doctoradvice" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  624. DialysisPrescription DialysisPrescription `json:"prescription" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  625. HisDoctorAdviceInfo []*HisDoctorAdviceInfo `json:"hisdoctoradviceinfo" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  626. DialysisSolution NewDialysisSolution `json:"dialysissolution" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId;"`
  627. XtAssessmentBeforeDislysis XtNewAssessmentBeforeDislysis `json:"assessmentbefor" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  628. LastAfterWeight NewAssessmentAfterDislysis `gorm:"ForeignKey:PatientID;AssociationForeignKey:PatientID" json:"lastafterweight"`
  629. XtDialysisOrderSix XtDialysisOrderSix `json:"dialysis_order" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  630. }
  631. func (VmNewSchedulesRemind) TableName() string {
  632. return "xt_schedule"
  633. }
  634. type WeekScheduleSeven struct {
  635. ID int64 `gorm:"column:id" json:"id" form:"id"`
  636. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  637. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  638. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  639. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  640. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  641. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  642. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  643. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  644. Status int64 `gorm:"column:status" json:"status" form:"status"`
  645. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  646. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  647. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  648. IdCardNo string `gorm:"-" json:"id_card_no" form:"id_card_no"`
  649. Gender string `gorm:"-" json:"gender" form:"gender"`
  650. Phone string `gorm:"-" json:"phone" form:"phone"`
  651. DialysisNo string `gorm:"-" json:"dialysis_no" form:"dialysis_no"`
  652. Patient string `gorm:"-" json:"patient" form:"patient"`
  653. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:ID;AssociationForeignKey:PartitionId;"`
  654. DeviceNumber DeviceNumber `json:"number" gorm:"foreignkey:ID;AssociationForeignKey:BedId;"`
  655. DialysisSolution DialysisSolution `json:"dialysissolution" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId"`
  656. XtAssessmentBeforeDislysis XtAssessmentBeforeDislysis `json:"assessmentbefor" gorm:"foreignkey:PatientId,AssessmentDate;AssociationForeignKey:PatientId,ScheduleDate"`
  657. XtDialysisOrderSix XtDialysisOrderSix `json:"dialysis_order" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  658. DialysisPrescription NewDialysisPrescription `json:"prescription" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId"`
  659. }
  660. func (WeekScheduleSeven) TableName() string {
  661. return "xt_schedule"
  662. }
  663. type ScheduleNewPatients struct {
  664. ID int64 `gorm:"column:id" json:"id" form:"id"`
  665. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  666. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  667. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  668. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  669. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  670. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  671. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  672. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  673. Status int64 `gorm:"column:status" json:"status" form:"status"`
  674. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  675. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  676. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  677. DialysisMachineName string `gorm:"column:dialysis_machine_name" json:"dialysis_machine_name" form:"dialysis_machine_name"`
  678. }
  679. func (ScheduleNewPatients) TableName() string {
  680. return "xt_schedule"
  681. }
  682. type MySchedule struct {
  683. ID int64 `gorm:"column:id" json:"id" form:"id"`
  684. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  685. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  686. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  687. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  688. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  689. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  690. Status int64 `gorm:"column:status" json:"status" form:"status"`
  691. Count int64
  692. }
  693. func (MySchedule) TableName() string {
  694. return "xt_schedule"
  695. }
  696. type MyVmBloodSchedule struct {
  697. ID int64 `gorm:"column:id" json:"id" form:"id"`
  698. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  699. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  700. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  701. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  702. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  703. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  704. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  705. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  706. Status int64 `gorm:"column:status" json:"status" form:"status"`
  707. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  708. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  709. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  710. SchedualPatient *NewMSchedualPatientVMList `gorm:"ForeignKey:PatientId" json:"patient"`
  711. DialysisPrescription DialysisPrescription `gorm:"ForeignKey:PatientId,RecordDate;AssociationForeignKey:PatientId,ScheduleDate" json:"dialysis_prescription"`
  712. XtAssessmentAfterDislysis XtAssessmentAfterDislysis `gorm:"ForeignKey:PatientId,AssessmentDate;AssociationForeignKey:PatientId,ScheduleDate" json:"xt_assesment_after_dislysis"`
  713. MonitoringRecord MonitoringRecord `gorm:"ForeignKey:PatientId,MonitoringDate;AssociationForeignKey:PatientId,ScheduleDate" json:"monitor_record"`
  714. }
  715. func (MyVmBloodSchedule) TableName() string {
  716. return "xt_schedule"
  717. }
  718. type ScheduleConfig struct {
  719. ID int64 `gorm:"column:id" json:"id" form:"id"`
  720. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  721. IsShowMode int64 `gorm:"column:is_show_mode" json:"is_show_mode" form:"is_show_mode"`
  722. Status int64 `gorm:"column:status" json:"status" form:"status"`
  723. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  724. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  725. IsShowMachine int64 `gorm:"column:is_show_machine" json:"is_show_machine" form:"is_show_machine"`
  726. }
  727. func (ScheduleConfig) TableName() string {
  728. return "xt_schedule_config"
  729. }
  730. type VmLongBloodSchedule struct {
  731. ID int64 `gorm:"column:id" json:"id" form:"id"`
  732. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  733. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  734. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  735. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  736. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  737. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  738. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  739. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  740. Status int64 `gorm:"column:status" json:"status" form:"status"`
  741. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  742. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  743. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  744. DeviceNumber *NewMDeviceNumberVM `gorm:"ForeignKey:BedId" json:"device_number"`
  745. SchedualPatient *NewMSchedualPatientVMList `gorm:"ForeignKey:PatientId" json:"patient"`
  746. XtDoctorAdvice []*XtDoctorAdvice `gorm:"ForeignKey:PatientId;AssociationForeignKey:PatientId" json:"xt_doctor_advice"`
  747. HisDoctorAdvice []*HisDoctorAdviceFourty `gorm:"ForeignKey:PatientId,AdviceDate;AssociationForeignKey:PatientId,ScheduleDate" json:"his_doctor_advice"`
  748. }
  749. func (VmLongBloodSchedule) TableName() string {
  750. return "xt_schedule"
  751. }