schedule_models.go 54KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737
  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 SchedulePatients 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 PatientListForFace `json:"patient" gorm:"foreignkey:ID;AssociationForeignKey:PatientId;"`
  91. }
  92. func (SchedulePatients) TableName() string {
  93. return "xt_schedule"
  94. }
  95. type PatientSchedule struct {
  96. Schedule
  97. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:PartitionId"`
  98. DeviceNumber DeviceNumber `json:"bed" gorm:"foreignkey:BedId"`
  99. Week int64 `gorm:"-" json:"week" form:"week"`
  100. TreatmentMode TreatmentMode `json:"mode" gorm:"foreignkey:ModeId"`
  101. }
  102. type Partition struct {
  103. DeviceZone
  104. Jihaos []DeviceNumber `json:"jihaos" gorm:"foreignkey:ZoneID"`
  105. }
  106. type Search_Schedule struct {
  107. ID int64 `gorm:"column:id" json:"id" form:"id"`
  108. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  109. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  110. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  111. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  112. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  113. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  114. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  115. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  116. Status int64 `gorm:"column:status" json:"status" form:"status"`
  117. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  118. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  119. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  120. Patient string `gorm:"-" json:"patient" form:"patient"`
  121. }
  122. func (Search_Schedule) TableName() string {
  123. return "xt_schedule"
  124. }
  125. type WeekSchedule struct {
  126. ID int64 `gorm:"column:id" json:"id" form:"id"`
  127. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  128. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  129. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  130. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  131. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  132. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  133. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  134. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  135. Status int64 `gorm:"column:status" json:"status" form:"status"`
  136. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  137. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  138. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  139. DialysisMachineName string `gorm:"column:dialysis_machine_name" json:"dialysis_machine_name" form:"dialysis_machine_name"`
  140. Patient string `gorm:"-" json:"patient" form:"patient"`
  141. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:ID;AssociationForeignKey:PartitionId;"`
  142. DeviceNumber DeviceNumber `json:"number" gorm:"foreignkey:ID;AssociationForeignKey:BedId;"`
  143. DialysisPrescription DialysisSolution `json:"prescription" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId"`
  144. DoctorAdvice []*DoctorAdvice `json:"doctoradvice" gorm:"foreignkey:AdviceDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  145. HisDoctorAdviceInfo []*HisDoctorAdviceInfo `json:"hisdoctoradviceinfo" gorm:"foreignkey:AdviceDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  146. Solution []*DialysisSolution `json:"solution" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId"`
  147. DialysisSolution DialysisSolution `json:"dialysissolution" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId"`
  148. XtAssessmentBeforeDislysis XtAssessmentBeforeDislysis `json:"assessmentbefor" gorm:"foreignkey:PatientId,AssessmentDate;AssociationForeignKey:PatientId,ScheduleDate"`
  149. }
  150. func (WeekSchedule) TableName() string {
  151. return "xt_schedule"
  152. }
  153. type ScheduleTemplate struct {
  154. ID int64 `gorm:"column:id" json:"id" form:"id"`
  155. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  156. TemplateId int64 `gorm:"column:template_id" json:"template_id" form:"template_id"`
  157. Status int64 `gorm:"column:status" json:"status" form:"status"`
  158. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  159. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  160. }
  161. func (ScheduleTemplate) TableName() string {
  162. return "xt_schedule_template"
  163. }
  164. type XtDataPrint struct {
  165. ID int64 `gorm:"column:id" json:"id" form:"id"`
  166. IsOpen int64 `gorm:"column:is_open" json:"is_open" form:"is_open"`
  167. Status int64 `gorm:"column:status" json:"status" form:"status"`
  168. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  169. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  170. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  171. }
  172. func (XtDataPrint) TableName() string {
  173. return "xt_data_print"
  174. }
  175. type VmSchedulesRemind struct {
  176. ID int64 `gorm:"column:id" json:"id" form:"id"`
  177. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  178. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  179. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  180. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  181. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  182. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  183. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  184. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  185. Status int64 `gorm:"column:status" json:"status" form:"status"`
  186. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  187. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  188. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  189. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:ID;AssociationForeignKey:PartitionId;"`
  190. DeviceNumber DeviceNumber `json:"number" gorm:"foreignkey:ID;AssociationForeignKey:BedId;"`
  191. DialysisOrder DialysisOrder `json:"order" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  192. XtPatients XtPatients `json:"patient" gorm:"foreignkey:ID;AssociationForeignKey:PatientId;"`
  193. DoctorAdvice []*DoctorAdvice `json:"doctoradvice" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  194. DialysisPrescription NewDialysisPrescription `json:"prescription" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  195. HisDoctorAdviceInfo []*HisDoctorAdviceInfo `json:"hisdoctoradviceinfo" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  196. DialysisSolution DialysisSolution `json:"dialysissolution" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId;"`
  197. XtAssessmentBeforeDislysis XtAssessmentBeforeDislysis `json:"assessmentbefor" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  198. LastAfterWeight AssessmentAfterDislysis `gorm:"ForeignKey:PatientID;AssociationForeignKey:PatientID" json:"lastafterweight"`
  199. XtDialysisOrderSix XtDialysisOrderSix `json:"dialysis_order" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  200. }
  201. func (VmSchedulesRemind) TableName() string {
  202. return "xt_schedule"
  203. }
  204. type WeekScheduleSix struct {
  205. ID int64 `gorm:"column:id" json:"id" form:"id"`
  206. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  207. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  208. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  209. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  210. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  211. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  212. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  213. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  214. Status int64 `gorm:"column:status" json:"status" form:"status"`
  215. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  216. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  217. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  218. IdCardNo string `gorm:"-" json:"id_card_no" form:"id_card_no"`
  219. Gender string `gorm:"-" json:"gender" form:"gender"`
  220. Phone string `gorm:"-" json:"phone" form:"phone"`
  221. DialysisNo string `gorm:"-" json:"dialysis_no" form:"dialysis_no"`
  222. Patient string `gorm:"-" json:"patient" form:"patient"`
  223. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:ID;AssociationForeignKey:PartitionId;"`
  224. DeviceNumber DeviceNumber `json:"number" gorm:"foreignkey:ID;AssociationForeignKey:BedId;"`
  225. DoctorAdvice []*DoctorAdvice `json:"doctoradvice" gorm:"foreignkey:AdviceDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  226. HisDoctorAdviceInfo []*HisDoctorAdviceInfo `json:"hisdoctoradviceinfo" gorm:"foreignkey:AdviceDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  227. DialysisSolution DialysisSolution `json:"dialysissolution" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId"`
  228. XtAssessmentBeforeDislysis XtAssessmentBeforeDislysis `json:"assessmentbefor" gorm:"foreignkey:PatientId,AssessmentDate;AssociationForeignKey:PatientId,ScheduleDate"`
  229. XtDialysisOrderSix XtDialysisOrderSix `json:"dialysis_order" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  230. DialysisPrescription NewDialysisPrescription `json:"prescription" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId"`
  231. }
  232. func (WeekScheduleSix) TableName() string {
  233. return "xt_schedule"
  234. }
  235. type BlodSchedule struct {
  236. ID int64 `gorm:"column:id" json:"id" form:"id"`
  237. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  238. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  239. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  240. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  241. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  242. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  243. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  244. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  245. Status int64 `gorm:"column:status" json:"status" form:"status"`
  246. VmBloodPatients VmBloodPatients `json:"patient" gorm:"foreignkey:ID;AssociationForeignKey:PatientId;"`
  247. BloodDialysisOrder BloodPatientDialysisOrder `json:"order" gorm:"foreignkey:DialysisDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  248. BloodDialysisPrescription BloodDialysisPrescription `json:"prescription" gorm:"foreignkey:RecordDate,PatientId;AssociationForeignKey:RecordDate,PatientId;"`
  249. }
  250. func (BlodSchedule) TableName() string {
  251. return "xt_schedule"
  252. }
  253. type BloodPatientDialysisOrder struct {
  254. ID int64 `gorm:"column:id" json:"id" form:"id"`
  255. DialysisDate int64 `gorm:"column:dialysis_date" json:"dialysis_date" form:"dialysis_date"`
  256. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  257. Stage int64 `gorm:"column:stage" json:"stage" form:"stage"`
  258. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  259. }
  260. func (BloodPatientDialysisOrder) TableName() string {
  261. return "xt_dialysis_order"
  262. }
  263. type BloodPatientDialysisPrescription struct {
  264. ID int64 `gorm:"column:id" json:"id" form:"id"`
  265. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  266. MachineType string `gorm:"column:machine_type" json:"machine_type" form:"machine_type"`
  267. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  268. DialysisDialyszers string `gorm:"column:dialysis_dialyszers" json:"dialysis_dialyszers" form:"dialysis_dialyszers"`
  269. DialysisIrrigation string `gorm:"column:dialysis_irrigation" json:"dialysis_irrigation" form:"dialysis_irrigation"`
  270. DialyzerPerfusionApparatus string `gorm:"column:dialyzer_perfusion_apparatus" json:"dialyzer_perfusion_apparatus" form:"dialyzer_perfusion_apparatus"`
  271. }
  272. func (BloodPatientDialysisPrescription) TableName() string {
  273. return "xt_dialysis_prescription"
  274. }
  275. type VmBloodPatients struct {
  276. ID int64 `gorm:"column:id" json:"id" form:"id"`
  277. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  278. Name string `gorm:"column:name" json:"name" form:"name"`
  279. }
  280. func (VmBloodPatients) TableName() string {
  281. return "xt_patients"
  282. }
  283. type VmBloodSchedule struct {
  284. ID int64 `gorm:"column:id" json:"id" form:"id"`
  285. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  286. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  287. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  288. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  289. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  290. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  291. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  292. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  293. Status int64 `gorm:"column:status" json:"status" form:"status"`
  294. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  295. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  296. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  297. DeviceNumber *NewMDeviceNumberVM `gorm:"ForeignKey:BedId" json:"device_number"`
  298. SchedualPatient *NewMSchedualPatientVMList `gorm:"ForeignKey:PatientId" json:"patient"`
  299. DialysisSolution DialysisSolution `gorm:"ForeignKey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId" json:"dialysis_solution"`
  300. DialysisPrescription DialysisPrescription `gorm:"ForeignKey:PatientId,RecordDate;AssociationForeignKey:PatientId,ScheduleDate" json:"dialysis_prescription"`
  301. XtAssessmentBeforeDislysis XtAssessmentBeforeDislysis `gorm:"ForeignKey:PatientId,AssessmentDate;AssociationForeignKey:PatientId,ScheduleDate" json:"assessment_befor_dislysis"`
  302. XtDoctorAdvice XtDoctorAdvice `gorm:"ForeignKey:PatientId,AdviceDate;AssociationForeignKey:PatientId,ScheduleDate" json:"xt_doctor_advice"`
  303. HisDoctorAdvice HisDoctorAdvice `gorm:"ForeignKey:PatientId,AdviceDate;AssociationForeignKey:PatientId,ScheduleDate" json:"his_doctor_advice"`
  304. ReceiveTreatmentAsses ReceiveTreatmentAsses `gorm:"ForeignKey:PatientId,RecordDate;AssociationForeignKey:PatientId,ScheduleDate" json:"xt_receive_treatment_asses"`
  305. XtAssessmentAfterDislysis XtAssessmentAfterDislysis `gorm:"ForeignKey:PatientId,AssessmentDate;AssociationForeignKey:PatientId,ScheduleDate" json:"xt_assesment_after_dislysis"`
  306. LastAfterWeight AssessmentAfterDislysis `gorm:"ForeignKey:PatientID;AssociationForeignKey:PatientID" json:"lastafterweight"`
  307. }
  308. func (VmBloodSchedule) TableName() string {
  309. return "xt_schedule"
  310. }
  311. type NewMDeviceNumberVM struct {
  312. DeviceNumber
  313. Zone *DeviceZone `gorm:"ForeignKey:ZoneID" json:"zone"`
  314. }
  315. func (NewMDeviceNumberVM) TableName() string {
  316. return "xt_device_number"
  317. }
  318. type NewMSchedualPatientVMList struct {
  319. ID int64 `gorm:"column:id" json:"id" form:"id"`
  320. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  321. UserId int64 `gorm:"column:user_id" json:"user_id" form:"user_id"`
  322. PatientType int64 `gorm:"column:patient_type" json:"patient_type" form:"patient_type"`
  323. DialysisNo string `gorm:"column:dialysis_no" json:"dialysis_no" form:"dialysis_no"`
  324. Avatar string `gorm:"column:avatar" json:"avatar" form:"avatar"`
  325. Gender int64 `gorm:"column:gender" json:"gender" form:"gender"`
  326. Birthday int64 `gorm:"column:birthday" json:"birthday" form:"birthday"`
  327. Age int64 `gorm:"column:age" json:"age"`
  328. Name string `gorm:"column:name" json:"name" form:"name"`
  329. IdCardNo string `gorm:"column:id_card_no" json:"id_card_no" form:"id_card_no"`
  330. UserSysBeforeCount int64 `gorm:"column:user_sys_before_count" json:"user_sys_before_count" form:"user_sys_before_count"`
  331. TrobleShoot int64 `gorm:"column:troble_shoot" json:"troble_shoot" form:"troble_shoot"`
  332. Status int64 `gorm:"column:status" json:"status" form:"status"`
  333. }
  334. func (NewMSchedualPatientVMList) TableName() string {
  335. return "xt_patients"
  336. }
  337. type VmBloodScheduleTwo struct {
  338. ID int64 `gorm:"column:id" json:"id" form:"id"`
  339. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  340. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  341. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  342. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  343. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  344. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  345. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  346. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  347. Status int64 `gorm:"column:status" json:"status" form:"status"`
  348. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  349. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  350. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  351. DeviceNumber *NewMDeviceNumberVM `gorm:"ForeignKey:BedId" json:"device_number"`
  352. SchedualPatient *NewMSchedualPatientVMList `gorm:"ForeignKey:PatientId" json:"patient"`
  353. HisPrescriptionTemplateSix HisPrescriptionTemplateSix `gorm:"ForeignKey:PatientId,Mode;AssociationForeignKey:PatientId,ModeId" json:"his_prescription_template"`
  354. }
  355. func (VmBloodScheduleTwo) TableName() string {
  356. return "xt_schedule"
  357. }
  358. type VmBloodScheduleThree struct {
  359. ID int64 `gorm:"column:id" json:"id" form:"id"`
  360. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  361. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  362. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  363. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  364. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  365. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  366. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  367. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  368. Status int64 `gorm:"column:status" json:"status" form:"status"`
  369. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  370. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  371. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  372. DeviceNumber *NewMDeviceNumberVM `gorm:"ForeignKey:BedId" json:"device_number"`
  373. SchedualPatient *NewMSchedualPatientVMList `gorm:"ForeignKey:PatientId" json:"patient"`
  374. HisPrescriptionTemplateSix HisPrescriptionTemplateSix `gorm:"ForeignKey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId" json:"his_prescription_template"`
  375. }
  376. func (VmBloodScheduleThree) TableName() string {
  377. return "xt_schedule"
  378. }
  379. type HisPrescriptionTemplateSix struct {
  380. ID int64 `gorm:"column:id" json:"id" form:"id"`
  381. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  382. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  383. Type int64 `gorm:"column:type" json:"type" form:"type"`
  384. Status int64 `gorm:"column:status" json:"status" form:"status"`
  385. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  386. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  387. Name string `gorm:"column:name" json:"name" form:"name"`
  388. Mode int64 `gorm:"column:mode" json:"mode" form:"mode"`
  389. HisPrescriptionInfoTemplateSix []*HisPrescriptionInfoTemplateSix `gorm:"ForeignKey:PTemplateId;AssociationForeignKey:ID" json:"his_prescription_info"`
  390. }
  391. func (HisPrescriptionTemplateSix) TableName() string {
  392. return "his_prescription_template"
  393. }
  394. type HisPrescriptionInfoTemplateSix struct {
  395. ID int64 `gorm:"column:id" json:"id" form:"id"`
  396. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  397. RecordDate int64 `gorm:"column:record_date" json:"record_date" form:"record_date"`
  398. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  399. Status int64 `gorm:"column:status" json:"status" form:"status"`
  400. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  401. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  402. Type int64 `gorm:"column:type" json:"type" form:"type"`
  403. Creator int64 `gorm:"column:creator" json:"creator" form:"creator"`
  404. Modifier int64 `gorm:"column:modifier" json:"modifier" form:"modifier"`
  405. PType int64 `gorm:"column:p_type" json:"p_type" form:"p_type"`
  406. PTemplateId int64 `gorm:"column:p_template_id" json:"p_template_id" form:"p_template_id"`
  407. HisPrescriptionProjectTemplateSeven []*HisPrescriptionProjectTemplateSeven `gorm:"ForeignKey:PrescriptionId;AssociationForeignKey:ID" json:"project"`
  408. HisPrescriptionAdviceTemplate []*HisPrescriptionAdviceTemplate `gorm:"ForeignKey:PrescriptionId;AssociationForeignKey:ID" json:"his_advice"`
  409. MedType string `gorm:"column:med_type" json:"med_type" form:"med_type"`
  410. }
  411. func (HisPrescriptionInfoTemplateSix) TableName() string {
  412. return "his_prescription_info_template"
  413. }
  414. type HisPrescriptionProjectTemplateSeven struct {
  415. ID int64 `gorm:"column:id" json:"id" form:"id"`
  416. ProjectId int64 `gorm:"column:project_id" json:"project_id" form:"project_id"`
  417. Price float64 `gorm:"column:price" json:"price" form:"price"`
  418. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  419. Status int64 `gorm:"column:status" json:"status" form:"status"`
  420. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  421. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  422. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  423. HisPatientId int64 `gorm:"column:his_patient_id" json:"his_patient_id" form:"his_patient_id"`
  424. RecordDate int64 `gorm:"column:record_date" json:"record_date" form:"record_date"`
  425. Count string `gorm:"column:count" json:"count" form:"count"`
  426. FeedetlSn string `gorm:"column:feedetl_sn" json:"feedetl_sn" form:"feedetl_sn"`
  427. MedListCodg string `gorm:"column:med_list_codg" json:"med_list_codg" form:"med_list_codg"`
  428. SingleDose string `gorm:"column:single_dose" json:"single_dose" form:"single_dose"`
  429. DeliveryWay string `gorm:"column:delivery_way" json:"delivery_way" form:"delivery_way"`
  430. ExecutionFrequency string `gorm:"column:execution_frequency" json:"execution_frequency" form:"execution_frequency"`
  431. Day string `gorm:"column:day" json:"day" form:"day"`
  432. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  433. Unit string `gorm:"column:unit" json:"unit" form:"unit"`
  434. Type int64 `gorm:"column:type" json:"type" form:"type"`
  435. PrescriptionId int64 `gorm:"column:prescription_id" json:"prescription_id" form:"prescription_id"`
  436. GoodInfo GoodInfoNight `gorm:"ForeignKey:ID;AssociationForeignKey:ProjectId" json:"good_info"`
  437. FrequencyType int64 `gorm:"column:frequency_type" json:"frequency_type" form:"frequency_type"`
  438. DayCount int64 `gorm:"column:day_count" json:"day_count" form:"day_count"`
  439. WeekDay string `gorm:"column:week_day" json:"week_day" form:"week_day"`
  440. }
  441. func (HisPrescriptionProjectTemplateSeven) TableName() string {
  442. return "his_prescription_project_template"
  443. }
  444. type GoodInfoNight struct {
  445. ID int64 `gorm:"column:id" json:"id" form:"id"`
  446. GoodName string `gorm:"column:good_name" json:"good_name" form:"good_name"`
  447. SpecificationName string `gorm:"column:specification_name" json:"specification_name" form:"specification_name"`
  448. GoodTypeId int64 `gorm:"column:good_type_id" json:"good_type_id" form:"good_type_id"`
  449. }
  450. func (GoodInfoNight) TableName() string {
  451. return "xt_good_information"
  452. }
  453. type ScheduleTwenty struct {
  454. ID int64 `gorm:"column:id" json:"id" form:"id"`
  455. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  456. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  457. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  458. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  459. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  460. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  461. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  462. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  463. Status int64 `gorm:"column:status" json:"status" form:"status"`
  464. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  465. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  466. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  467. Patient string `gorm:"-" json:"patient" form:"patient"`
  468. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:ID;AssociationForeignKey:PartitionId;"`
  469. DeviceNumber DeviceNumber `json:"number" gorm:"foreignkey:ID;AssociationForeignKey:BedId;"`
  470. TreatmentMode TreatmentMode `json:"mode" gorm:"foreignkey:ModeId"`
  471. DialysisOrderTwenty DialysisOrderTwenty `json:"order" gorm:"foreignkey:DialysisDate,PatientId;AssociationForeignKey:ScheduleDate,PatientId;"`
  472. }
  473. func (ScheduleTwenty) TableName() string {
  474. return "xt_schedule"
  475. }
  476. type ScheduleTwentyOne struct {
  477. ID int64 `gorm:"column:id" json:"id" form:"id"`
  478. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  479. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  480. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  481. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  482. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  483. Status int64 `gorm:"column:status" json:"status" form:"status"`
  484. }
  485. func (ScheduleTwentyOne) TableName() string {
  486. return "xt_schedule"
  487. }
  488. type VmBloodScheduleOne struct {
  489. ID int64 `gorm:"column:id" json:"id" form:"id"`
  490. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  491. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  492. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  493. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  494. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  495. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  496. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  497. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  498. Status int64 `gorm:"column:status" json:"status" form:"status"`
  499. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  500. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  501. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  502. DeviceNumber *NewMDeviceNumberVM `gorm:"ForeignKey:BedId" json:"device_number"`
  503. SchedualPatient *NewMSchedualPatientVMList `gorm:"ForeignKey:PatientId" json:"patient"`
  504. XtDoctorAdvice []*XtDoctorAdvice `gorm:"ForeignKey:PatientId,AdviceDate;AssociationForeignKey:PatientId,ScheduleDate" json:"xt_doctor_advice"`
  505. HisDoctorAdvice []*HisDoctorAdviceFourty `gorm:"ForeignKey:PatientId,AdviceDate;AssociationForeignKey:PatientId,ScheduleDate" json:"his_doctor_advice"`
  506. }
  507. func (VmBloodScheduleOne) TableName() string {
  508. return "xt_schedule"
  509. }
  510. type VmNewSchedulesRemind struct {
  511. ID int64 `gorm:"column:id" json:"id" form:"id"`
  512. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  513. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  514. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  515. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  516. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  517. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  518. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  519. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  520. Status int64 `gorm:"column:status" json:"status" form:"status"`
  521. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  522. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  523. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  524. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:ID;AssociationForeignKey:PartitionId;"`
  525. DeviceNumber DeviceNumber `json:"number" gorm:"foreignkey:ID;AssociationForeignKey:BedId;"`
  526. DialysisOrder NewDialysisOrder `json:"order" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  527. XtPatients XtNewPatients `json:"patient" gorm:"foreignkey:ID;AssociationForeignKey:PatientId;"`
  528. DoctorAdvice []*DoctorAdvice `json:"doctoradvice" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  529. DialysisPrescription DialysisPrescription `json:"prescription" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  530. HisDoctorAdviceInfo []*HisDoctorAdviceInfo `json:"hisdoctoradviceinfo" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  531. DialysisSolution NewDialysisSolution `json:"dialysissolution" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId;"`
  532. XtAssessmentBeforeDislysis XtNewAssessmentBeforeDislysis `json:"assessmentbefor" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  533. LastAfterWeight NewAssessmentAfterDislysis `gorm:"ForeignKey:PatientID;AssociationForeignKey:PatientID" json:"lastafterweight"`
  534. XtDialysisOrderSix XtDialysisOrderSix `json:"dialysis_order" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  535. }
  536. func (VmNewSchedulesRemind) TableName() string {
  537. return "xt_schedule"
  538. }
  539. type WeekScheduleSeven struct {
  540. ID int64 `gorm:"column:id" json:"id" form:"id"`
  541. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  542. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  543. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  544. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  545. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  546. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  547. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  548. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  549. Status int64 `gorm:"column:status" json:"status" form:"status"`
  550. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  551. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  552. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  553. IdCardNo string `gorm:"-" json:"id_card_no" form:"id_card_no"`
  554. Gender string `gorm:"-" json:"gender" form:"gender"`
  555. Phone string `gorm:"-" json:"phone" form:"phone"`
  556. DialysisNo string `gorm:"-" json:"dialysis_no" form:"dialysis_no"`
  557. Patient string `gorm:"-" json:"patient" form:"patient"`
  558. DeviceZone DeviceZone `json:"zone" gorm:"foreignkey:ID;AssociationForeignKey:PartitionId;"`
  559. DeviceNumber DeviceNumber `json:"number" gorm:"foreignkey:ID;AssociationForeignKey:BedId;"`
  560. DialysisSolution DialysisSolution `json:"dialysissolution" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId"`
  561. XtAssessmentBeforeDislysis XtAssessmentBeforeDislysis `json:"assessmentbefor" gorm:"foreignkey:PatientId,AssessmentDate;AssociationForeignKey:PatientId,ScheduleDate"`
  562. XtDialysisOrderSix XtDialysisOrderSix `json:"dialysis_order" gorm:"foreignkey:PatientId;AssociationForeignKey:PatientId;"`
  563. DialysisPrescription NewDialysisPrescription `json:"prescription" gorm:"foreignkey:PatientId,ModeId;AssociationForeignKey:PatientId,ModeId"`
  564. }
  565. func (WeekScheduleSeven) TableName() string {
  566. return "xt_schedule"
  567. }
  568. type ScheduleNewPatients struct {
  569. ID int64 `gorm:"column:id" json:"id" form:"id"`
  570. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  571. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  572. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  573. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  574. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  575. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  576. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  577. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  578. Status int64 `gorm:"column:status" json:"status" form:"status"`
  579. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  580. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  581. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  582. DialysisMachineName string `gorm:"column:dialysis_machine_name" json:"dialysis_machine_name" form:"dialysis_machine_name"`
  583. }
  584. func (ScheduleNewPatients) TableName() string {
  585. return "xt_schedule"
  586. }
  587. type MySchedule struct {
  588. ID int64 `gorm:"column:id" json:"id" form:"id"`
  589. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  590. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  591. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  592. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  593. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  594. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  595. Status int64 `gorm:"column:status" json:"status" form:"status"`
  596. Count int64
  597. }
  598. func (MySchedule) TableName() string {
  599. return "xt_schedule"
  600. }
  601. type MyVmBloodSchedule struct {
  602. ID int64 `gorm:"column:id" json:"id" form:"id"`
  603. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  604. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  605. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  606. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  607. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  608. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  609. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  610. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  611. Status int64 `gorm:"column:status" json:"status" form:"status"`
  612. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  613. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  614. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  615. SchedualPatient *NewMSchedualPatientVMList `gorm:"ForeignKey:PatientId" json:"patient"`
  616. DialysisPrescription DialysisPrescription `gorm:"ForeignKey:PatientId,RecordDate;AssociationForeignKey:PatientId,ScheduleDate" json:"dialysis_prescription"`
  617. XtAssessmentAfterDislysis XtAssessmentAfterDislysis `gorm:"ForeignKey:PatientId,AssessmentDate;AssociationForeignKey:PatientId,ScheduleDate" json:"xt_assesment_after_dislysis"`
  618. MonitoringRecord MonitoringRecord `gorm:"ForeignKey:PatientId,MonitoringDate;AssociationForeignKey:PatientId,ScheduleDate" json:"monitor_record"`
  619. }
  620. func (MyVmBloodSchedule) TableName() string {
  621. return "xt_schedule"
  622. }
  623. type ScheduleConfig struct {
  624. ID int64 `gorm:"column:id" json:"id" form:"id"`
  625. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  626. IsShowMode int64 `gorm:"column:is_show_mode" json:"is_show_mode" form:"is_show_mode"`
  627. Status int64 `gorm:"column:status" json:"status" form:"status"`
  628. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  629. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  630. IsShowMachine int64 `gorm:"column:is_show_machine" json:"is_show_machine" form:"is_show_machine"`
  631. }
  632. func (ScheduleConfig) TableName() string {
  633. return "xt_schedule_config"
  634. }
  635. type VmLongBloodSchedule struct {
  636. ID int64 `gorm:"column:id" json:"id" form:"id"`
  637. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  638. PartitionId int64 `gorm:"column:partition_id" json:"partition_id" form:"partition_id"`
  639. BedId int64 `gorm:"column:bed_id" json:"bed_id" form:"bed_id"`
  640. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  641. ScheduleDate int64 `gorm:"column:schedule_date" json:"schedule_date" form:"schedule_date"`
  642. ScheduleType int64 `gorm:"column:schedule_type" json:"schedule_type" form:"schedule_type"`
  643. ScheduleWeek int64 `gorm:"column:schedule_week" json:"schedule_week" form:"schedule_week"`
  644. ModeId int64 `gorm:"column:mode_id" json:"mode_id" form:"mode_id"`
  645. Status int64 `gorm:"column:status" json:"status" form:"status"`
  646. CreatedTime int64 `gorm:"column:created_time" json:"created_time" form:"created_time"`
  647. UpdatedTime int64 `gorm:"column:updated_time" json:"updated_time" form:"updated_time"`
  648. IsExport int64 `gorm:"column:is_export" json:"is_export" form:"is_export"`
  649. DeviceNumber *NewMDeviceNumberVM `gorm:"ForeignKey:BedId" json:"device_number"`
  650. SchedualPatient *NewMSchedualPatientVMList `gorm:"ForeignKey:PatientId" json:"patient"`
  651. XtDoctorAdvice []*XtDoctorAdvice `gorm:"ForeignKey:PatientId;AssociationForeignKey:PatientId" json:"xt_doctor_advice"`
  652. HisDoctorAdvice []*HisDoctorAdviceFourty `gorm:"ForeignKey:PatientId,AdviceDate;AssociationForeignKey:PatientId,ScheduleDate" json:"his_doctor_advice"`
  653. }
  654. func (VmLongBloodSchedule) TableName() string {
  655. return "xt_schedule"
  656. }