drug_stock.go 62KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735
  1. package models
  2. type DrugWarehouse struct {
  3. ID int64 `gorm:"column:id" json:"id" form:"id"`
  4. WarehousingOrder string `gorm:"column:warehousing_order" json:"warehousing_order" form:"warehousing_order"`
  5. OperationTime int64 `gorm:"column:operation_time" json:"operation_time" form:"operation_time"`
  6. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  7. Creater int64 `gorm:"column:creater" json:"creater" form:"creater"`
  8. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  9. Modifier int64 `gorm:"column:modifier" json:"modifier" form:"modifier"`
  10. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  11. Status int64 `gorm:"column:status" json:"status" form:"status"`
  12. WarehousingTime int64 `gorm:"column:warehousing_time" json:"warehousing_time" form:"warehousing_time"`
  13. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  14. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  15. Type int64 `gorm:"column:type" json:"type" form:"type"`
  16. SupplyWarehouseId int64 `gorm:"column:supply_warehouse_id" json:"supply_warehouse_id" form:"supply_warehouse_id"`
  17. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  18. SecondWarehouseId int64 `gorm:"column:second_warehouse_id" json:"second_warehouse_id" form:"second_warehouse_id"`
  19. IsSys int64 `gorm:"column:is_sys" json:"is_sys" form:"is_sys"`
  20. IsCheck int64 `gorm:"column:is_check" json:"is_check" form:"is_check"`
  21. Checker int64 `gorm:"column:checker" json:"checker" form:"checker"`
  22. }
  23. func (DrugWarehouse) TableName() string {
  24. return "xt_drug_warehouse"
  25. }
  26. type DrugWarehouseInfoSix struct {
  27. ID int64 `gorm:"column:id" json:"id" form:"id"`
  28. WarehousingId int64 `gorm:"column:warehousing_id" json:"warehousing_id" form:"warehousing_id"`
  29. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  30. Number string `gorm:"column:number" json:"number" form:"number"`
  31. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  32. ExpiryDate int64 `gorm:"column:expiry_date" json:"expiry_date" form:"expiry_date"`
  33. WarehousingCount int64 `gorm:"column:warehousing_count" json:"warehousing_count" form:"warehousing_count"`
  34. Price float64 `gorm:"column:price" json:"price" form:"price"`
  35. TotalPrice float64 `gorm:"column:total_price" json:"total_price" form:"total_price"`
  36. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  37. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  38. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  39. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  40. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  41. Status int64 `gorm:"column:status" json:"status" form:"status"`
  42. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  43. IsReturn int64 `gorm:"column:is_return" json:"is_return" form:"is_return"`
  44. WarehousingOrder string `gorm:"column:warehousing_order" json:"warehousing_order" form:"warehousing_order"`
  45. Type int64 `gorm:"column:type" json:"type" form:"type"`
  46. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  47. RetailTotalPrice float64 `gorm:"column:retail_total_price" json:"retail_total_price" form:"retail_total_price"`
  48. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  49. MaxUnit string `gorm:"column:max_unit" json:"max_unit" form:"max_unit"`
  50. MinUnit string `gorm:"column:min_unit" json:"min_unit" form:"min_unit"`
  51. StockMaxNumber int64 `gorm:"column:stock_max_number" json:"stock_max_number" form:"stock_max_number"`
  52. StockMinNumber int64 `gorm:"column:stock_min_number" json:"stock_min_number" form:"stock_min_number"`
  53. MinNumber int64 `json:"min_number"`
  54. }
  55. type DrugWarehouseInfo struct {
  56. ID int64 `gorm:"column:id" json:"id" form:"id"`
  57. WarehousingId int64 `gorm:"column:warehousing_id" json:"warehousing_id" form:"warehousing_id"`
  58. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  59. Number string `gorm:"column:number" json:"number" form:"number"`
  60. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  61. ExpiryDate int64 `gorm:"column:expiry_date" json:"expiry_date" form:"expiry_date"`
  62. WarehousingCount int64 `gorm:"column:warehousing_count" json:"warehousing_count" form:"warehousing_count"`
  63. Price float64 `gorm:"column:price" json:"price" form:"price"`
  64. TotalPrice float64 `gorm:"column:total_price" json:"total_price" form:"total_price"`
  65. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  66. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  67. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  68. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  69. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  70. Status int64 `gorm:"column:status" json:"status" form:"status"`
  71. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  72. IsReturn int64 `gorm:"column:is_return" json:"is_return" form:"is_return"`
  73. WarehousingOrder string `gorm:"column:warehousing_order" json:"warehousing_order" form:"warehousing_order"`
  74. Type int64 `gorm:"column:type" json:"type" form:"type"`
  75. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  76. RetailTotalPrice float64 `gorm:"column:retail_total_price" json:"retail_total_price" form:"retail_total_price"`
  77. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  78. MaxUnit string `gorm:"column:max_unit" json:"max_unit" form:"max_unit"`
  79. MinUnit string `gorm:"column:min_unit" json:"min_unit" form:"min_unit"`
  80. StockMaxNumber int64 `gorm:"column:stock_max_number" json:"stock_max_number" form:"stock_max_number"`
  81. StockMinNumber int64 `gorm:"column:stock_min_number" json:"stock_min_number" form:"stock_min_number"`
  82. WarehousingInfoId int64 `gorm:"column:warehousing_info_id" json:"warehousing_info_id" form:"warehousing_info_id"`
  83. SupplyWarehouseId int64 `gorm:"column:supply_warehouse_id" json:"supply_warehouse_id" form:"supply_warehouse_id"`
  84. SupplyWarehouseDetailInfo int64 `gorm:"column:supply_warehouse_detail_info" json:"supply_warehouse_detail_info" form:"supply_warehouse_detail_info"`
  85. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  86. SecondWarehouseInfoId int64 `gorm:"column:second_warehouse_info_id" json:"second_warehouse_info_id" form:"second_warehouse_info_id"`
  87. IsCheck int64 `gorm:"column:is_check" json:"is_check" form:"is_check"`
  88. }
  89. func (DrugWarehouseInfo) TableName() string {
  90. return "xt_drug_warehouse_info"
  91. }
  92. type DrugWarehouseInfoTen struct {
  93. StockMaxNumber int64 `gorm:"column:stock_max_number" json:"stock_max_number" form:"stock_max_number"`
  94. StockMinNumber int64 `gorm:"column:stock_min_number" json:"stock_min_number" form:"stock_min_number"`
  95. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  96. IsCheck int64 `gorm:"column:is_check" json:"is_check" form:"is_check"`
  97. Status int64 `gorm:"column:status" json:"status" form:"status"`
  98. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  99. }
  100. func (DrugWarehouseInfoTen) TableName() string {
  101. return "xt_drug_warehouse_info"
  102. }
  103. type DrugWarehouseInfoSeven struct {
  104. StockMaxNumber int64 `gorm:"column:stock_max_number" json:"stock_max_number" form:"stock_max_number"`
  105. StockMinNumber int64 `gorm:"column:stock_min_number" json:"stock_min_number" form:"stock_min_number"`
  106. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  107. IsCheck int64 `gorm:"column:is_check" json:"is_check" form:"is_check"`
  108. }
  109. func (DrugWarehouseInfoSeven) TableName() string {
  110. return "xt_drug_warehouse_info"
  111. }
  112. type DrugWarehouseOut struct {
  113. ID int64 `gorm:"column:id" json:"id" form:"id"`
  114. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  115. OperationTime int64 `gorm:"column:operation_time" json:"operation_time" form:"operation_time"`
  116. Creater int64 `gorm:"column:creater" json:"creater" form:"creater"`
  117. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  118. Modifier int64 `gorm:"column:modifier" json:"modifier" form:"modifier"`
  119. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  120. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  121. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  122. Status int64 `gorm:"column:status" json:"status" form:"status"`
  123. WarehouseOutTime int64 `gorm:"column:warehouse_out_time" json:"warehouse_out_time" form:"warehouse_out_time"`
  124. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  125. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  126. Type int64 `gorm:"column:type" json:"type" form:"type"`
  127. IsSys int64 `gorm:"column:is_sys" json:"is_sys" form:"is_sys"`
  128. Manufacturers *Manufacturer `gorm:"ForeignKey:Manufacturer;AssociationForeignKey:ID" json:"manufacturers"`
  129. Dealers *Dealer `gorm:"ForeignKey:Dealer;AssociationForeignKey:ID" json:"dealers"`
  130. SupplyCancelOutId int64 `gorm:"column:supply_cancel_out_id" json:"supply_cancel_out_id" form:"supply_cancel_out_id"`
  131. SupplyWarehouseId int64 `gorm:"column:supply_warehouse_id" json:"supply_warehouse_id" form:"supply_warehouse_id"`
  132. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  133. SecondWarehouseId int64 `gorm:"column:second_warehouse_id" json:"second_warehouse_id" form:"second_warehouse_id"`
  134. IsCheck int64 `gorm:"column:is_check" json:"is_check" form:"is_check"`
  135. OrderId int64 `gorm:"column:order_id" json:"order_id" form:"order_id"`
  136. }
  137. func (DrugWarehouseOut) TableName() string {
  138. return "xt_drug_warehouse_out"
  139. }
  140. type DrugWarehouseOutInfo struct {
  141. ID int64 `gorm:"column:id" json:"id" form:"id"`
  142. WarehouseOutId int64 `gorm:"column:warehouse_out_id" json:"warehouse_out_id" form:"warehouse_out_id"`
  143. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  144. WarehousingOutTarget int64 `gorm:"column:warehousing_out_target" json:"warehousing_out_target" form:"warehousing_out_target"`
  145. Count int64 `gorm:"column:count" json:"count" form:"count"`
  146. CountUnit string `gorm:"column:count_unit" json:"count_unit" form:"count_unit"`
  147. Price float64 `gorm:"column:price" json:"price" form:"price"`
  148. TotalPrice float64 `gorm:"column:total_price" json:"total_price" form:"total_price"`
  149. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  150. ExpiryDate int64 `gorm:"column:expiry_date" json:"expiry_date" form:"expiry_date"`
  151. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  152. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  153. Status int64 `gorm:"column:status" json:"status" form:"status"`
  154. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  155. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  156. IsCancel int64 `gorm:"column:is_cancel" json:"is_cancel" form:"is_cancel"`
  157. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  158. Type int64 `gorm:"column:type" json:"type" form:"type"`
  159. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  160. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  161. IsSys int64 `gorm:"column:is_sys" json:"is_sys" form:"is_sys"`
  162. SysRecordTime int64 `gorm:"column:sys_record_time" json:"sys_record_time" form:"sys_record_time"`
  163. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  164. RetailTotalPrice float64 `gorm:"column:retail_total_price" json:"retail_total_price" form:"retail_total_price"`
  165. Number string `gorm:"column:number" json:"number" form:"number"`
  166. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  167. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  168. WarehouseInfoId int64 `gorm:"column:warehouse_info_id" json:"warehouse_info_id" form:"warehouse_info_id"`
  169. AdviceId int64 `gorm:"column:advice_id" json:"advice_id" form:"advice_id"`
  170. SupplyCancelOutId int64 `gorm:"column:supply_cancel_out_id" json:"supply_cancel_out_id" form:"supply_cancel_out_id"`
  171. SupplyWarehouseId int64 `gorm:"column:supply_warehouse_id" json:"supply_warehouse_id" form:"supply_warehouse_id"`
  172. IsSource int64 `gorm:"column:is_source" json:"is_source" form:"is_source"`
  173. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  174. SecondWarehouseInfoId int64 `gorm:"column:second_warehouse_info_id" json:"second_warehouse_info_id" form:"second_warehouse_info_id"`
  175. AdminUserId int64 `gorm:"column:admin_user_id" json:"admin_user_id" form:"admin_user_id"`
  176. LastPrice float64 `gorm:"column:last_price" json:"last_price" form:"last_price"`
  177. StockCount string `gorm:"column:stock_count" json:"stock_count" form:"stock_count"`
  178. PharmacyId int64 `gorm:"column:pharmacy_id" json:"pharmacy_id" form:"pharmacy_id"`
  179. IsCheck int64 `gorm:"column:is_check" json:"is_check" form:"is_check"`
  180. BaseDrugLib BaseDrugLib `gorm:"ForeignKey:ID;AssociationForeignKey:DrugId"json:"drug" `
  181. OverCount int64 `gorm:"column:over_count" json:"over_count" form:"over_count"`
  182. OrderId int64 `gorm:"column:order_id" json:"order_id" form:"order_id"`
  183. }
  184. func (DrugWarehouseOutInfo) TableName() string {
  185. return "xt_drug_warehouse_out_info"
  186. }
  187. type DrugSalesReturn struct {
  188. ID int64 `gorm:"column:id" json:"id" form:"id"`
  189. OrderNumber string `gorm:"column:order_number" json:"order_number" form:"order_number"`
  190. OperaTime int64 `gorm:"column:opera_time" json:"opera_time" form:"opera_time"`
  191. Total int64 `gorm:"column:total" json:"total" form:"total"`
  192. Creater int64 `gorm:"column:creater" json:"creater" form:"creater"`
  193. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  194. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  195. Status int64 `gorm:"column:status" json:"status" form:"status"`
  196. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  197. ReturnTime int64 `gorm:"column:return_time" json:"return_time" form:"return_time"`
  198. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  199. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  200. Type int64 `gorm:"column:type" json:"type" form:"type"`
  201. Manufacturers *Manufacturer `gorm:"ForeignKey:Manufacturer;AssociationForeignKey:ID" json:"manufacturers"`
  202. Dealers *Dealer `gorm:"ForeignKey:Dealer;AssociationForeignKey:ID" json:"dealers"`
  203. }
  204. func (DrugSalesReturn) TableName() string {
  205. return "xt_drug_sales_return"
  206. }
  207. type DrugSalesReturnInfo struct {
  208. ID int64 `gorm:"column:id" json:"id" form:"id"`
  209. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  210. SalesReturnId int64 `gorm:"column:sales_return_id" json:"sales_return_id" form:"sales_return_id"`
  211. Count int64 `gorm:"column:count" json:"count" form:"count"`
  212. Price float64 `gorm:"column:price" json:"price" form:"price"`
  213. Total float64 `gorm:"column:total" json:"total" form:"total"`
  214. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  215. ExpiryDate int64 `gorm:"column:expiry_date" json:"expiry_date" form:"expiry_date"`
  216. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  217. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  218. Status int64 `gorm:"column:status" json:"status" form:"status"`
  219. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  220. OrderNumber string `gorm:"column:order_number" json:"order_number" form:"order_number"`
  221. Type int64 `gorm:"column:type" json:"type" form:"type"`
  222. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  223. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  224. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  225. RetailTotalPrice float64 `gorm:"column:retail_total_price" json:"retail_total_price" form:"retail_total_price"`
  226. Number string `gorm:"column:number" json:"number" form:"number"`
  227. }
  228. func (DrugSalesReturnInfo) TableName() string {
  229. return "xt_drug_sales_return_info"
  230. }
  231. type DrugCancelStock struct {
  232. ID int64 `gorm:"column:id" json:"id" form:"id"`
  233. OrderNumber string `gorm:"column:order_number" json:"order_number" form:"order_number"`
  234. OperaTime int64 `gorm:"column:opera_time" json:"opera_time" form:"opera_time"`
  235. Total int64 `gorm:"column:total" json:"total" form:"total"`
  236. Creater int64 `gorm:"column:creater" json:"creater" form:"creater"`
  237. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  238. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  239. Status int64 `gorm:"column:status" json:"status" form:"status"`
  240. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  241. ReturnTime int64 `gorm:"column:return_time" json:"return_time" form:"return_time"`
  242. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  243. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  244. Type int64 `gorm:"column:type" json:"type" form:"type"`
  245. Manufacturers *Manufacturer `gorm:"ForeignKey:Manufacturer;AssociationForeignKey:ID" json:"manufacturers"`
  246. Dealers *Dealer `gorm:"ForeignKey:Dealer;AssociationForeignKey:ID" json:"dealers"`
  247. DrugCancelStockInfo []*DrugCancelStockInfo `gorm:"ForeignKey:CancelStockId;AssociationForeignKey:ID" json:"drugCancelStockInfo"`
  248. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  249. IsCheck int64 `gorm:"column:is_check" json:"is_check" form:"is_check"`
  250. OrderId int64 `gorm:"column:order_id" json:"order_id" form:"order_id"`
  251. }
  252. func (DrugCancelStock) TableName() string {
  253. return "xt_drug_cancel_stock"
  254. }
  255. type DrugCancelStockInfo struct {
  256. ID int64 `gorm:"column:id" json:"id" form:"id"`
  257. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  258. CancelStockId int64 `gorm:"column:cancel_stock_id" json:"cancel_stock_id" form:"cancel_stock_id"`
  259. Count int64 `gorm:"column:count" json:"count" form:"count"`
  260. Price float64 `gorm:"column:price" json:"price" form:"price"`
  261. Total float64 `gorm:"column:total" json:"total" form:"total"`
  262. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  263. ExpiryDate int64 `gorm:"column:expiry_date" json:"expiry_date" form:"expiry_date"`
  264. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  265. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  266. Status int64 `gorm:"column:status" json:"status" form:"status"`
  267. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  268. OrderNumber string `gorm:"column:order_number" json:"order_number" form:"order_number"`
  269. Type int64 `gorm:"column:type" json:"type" form:"type"`
  270. Dealer string `gorm:"column:dealer" json:"dealer" form:"dealer"`
  271. Manufacturer string `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  272. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  273. RetailTotalPrice float64 `gorm:"column:retail_total_price" json:"retail_total_price" form:"retail_total_price"`
  274. Number string `gorm:"column:number" json:"number" form:"number"`
  275. RegisterAccount string `gorm:"column:register_account" json:"register_account" form:"register_account"`
  276. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  277. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  278. MaxUnit string `gorm:"column:max_unit" json:"max_unit" form:"max_unit"`
  279. BaseDrugLib BaseDrugLib `gorm:"ForeignKey:ID;AssociationForeignKey:DrugId" `
  280. BatchNumberId int64 `gorm:"column:batch_number_id" json:"batch_number_id" form:"batch_number_id"`
  281. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  282. IsCheck int64 `gorm:"column:is_check" json:"is_check" form:"is_check"`
  283. DrugWarehouseInfo []*DrugWarehouseInfo `gorm:"ForeignKey:DrugId;AssociationForeignKey:DrugId"json:"drug_warehouse_info" `
  284. OrderId int64 `gorm:"column:order_id" json:"order_id" form:"order_id"`
  285. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  286. }
  287. func (DrugCancelStockInfo) TableName() string {
  288. return "xt_drug_cancel_stock_info"
  289. }
  290. type DrugAutomaticReduceDetail struct {
  291. ID int64 `gorm:"column:id" json:"id" form:"id"`
  292. WarehouseOutId int64 `gorm:"column:warehouse_out_id" json:"warehouse_out_id" form:"warehouse_out_id"`
  293. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  294. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  295. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  296. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  297. Status int64 `gorm:"column:status" json:"status" form:"status"`
  298. RecordTime int64 `gorm:"column:record_time" json:"record_time" form:"record_time"`
  299. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  300. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  301. Count int64 `gorm:"column:count" json:"count" form:"count"`
  302. CountUnit string `gorm:"column:count_unit" json:"count_unit" form:"count_unit"`
  303. WarehouseInfoId int64 `gorm:"column:warehouse_info_id" json:"warehouse_info_id" form:"warehouse_info_id"`
  304. AdviceId int64 `gorm:"column:advice_id" json:"advice_id" form:"advice_id"`
  305. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  306. }
  307. func (DrugAutomaticReduceDetail) TableName() string {
  308. return "xt_drug_automatic_reduce_detail"
  309. }
  310. type VmDrugAutomaticReduceDetail struct {
  311. ID int64 `gorm:"column:id" json:"id" form:"id"`
  312. WarehouseOutId int64 `gorm:"column:warehouse_out_id" json:"warehouse_out_id" form:"warehouse_out_id"`
  313. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  314. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  315. RecordTime int64 `gorm:"column:record_time" json:"record_time" form:"record_time"`
  316. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  317. Total int64
  318. }
  319. type VmDrugWarehouseInfo struct {
  320. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  321. Count int64 `gorm:"column:count" json:"count" form:"count"`
  322. MaxUnit string `gorm:"column:max_unit" json:"max_unit" form:"max_unit"`
  323. MinUnit string `gorm:"column:min_unit" json:"min_unit" form:"min_unit"`
  324. CountUnit string `gorm:"column:count_unit" json:"count_unit" form:"count_unit"`
  325. StockMinNumber int64 `gorm:"column:stock_min_number" json:"stock_min_number" form:"stock_min_number"`
  326. StockMaxNumber int64 `gorm:"column:stock_max_number" json:"stock_max_number" form:"stock_max_number"`
  327. MinNumber int64 `gorm:"column:min_number" json:"min_number" form:"min_number"`
  328. SupplyWarehouseId int64 `gorm:"column:supply_warehouse_id" json:"supply_warehouse_id" form:"supply_warehouse_id"`
  329. SupplyWarehouseDetailInfo int64 `gorm:"column:supply_warehouse_detail_info" json:"supply_warehouse_detail_info" form:"supply_warehouse_detail_info"`
  330. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  331. IsCheck int64 `gorm:"column:is_check" json:"is_check" form:"is_check"`
  332. }
  333. type StDrugWarehouseOutInfo struct {
  334. ID int64 `gorm:"column:id" json:"id" form:"id"`
  335. WarehouseOutId int64 `gorm:"column:warehouse_out_id" json:"warehouse_out_id" form:"warehouse_out_id"`
  336. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  337. WarehousingOutTarget int64 `gorm:"column:warehousing_out_target" json:"warehousing_out_target" form:"warehousing_out_target"`
  338. Count int64 `gorm:"column:count" json:"count" form:"count"`
  339. CountUnit string `gorm:"column:count_unit" json:"count_unit" form:"count_unit"`
  340. Price float64 `gorm:"column:price" json:"price" form:"price"`
  341. TotalPrice float64 `gorm:"column:total_price" json:"total_price" form:"total_price"`
  342. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  343. ExpiryDate int64 `gorm:"column:expiry_date" json:"expiry_date" form:"expiry_date"`
  344. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  345. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  346. Status int64 `gorm:"column:status" json:"status" form:"status"`
  347. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  348. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  349. IsCancel int64 `gorm:"column:is_cancel" json:"is_cancel" form:"is_cancel"`
  350. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  351. Type int64 `gorm:"column:type" json:"type" form:"type"`
  352. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  353. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  354. IsSys int64 `gorm:"column:is_sys" json:"is_sys" form:"is_sys"`
  355. SysRecordTime int64 `gorm:"column:sys_record_time" json:"sys_record_time" form:"sys_record_time"`
  356. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  357. RetailTotalPrice float64 `gorm:"column:retail_total_price" json:"retail_total_price" form:"retail_total_price"`
  358. Number string `gorm:"column:number" json:"number" form:"number"`
  359. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  360. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  361. DrugName string `json:"drug_name"`
  362. DrugType int64 `json:"drug_type"`
  363. MaxUnit string `json:"max_unit"`
  364. MinUnit string `json:"min_unit"`
  365. MinNumber int64 `json:"min_number"`
  366. MinPrice float64 `json:"min_price"`
  367. Dose string `json:"dose"`
  368. DoseUnit string `json:"dose_unit"`
  369. LastPrice string `json:"last_price"`
  370. PackingUnit string `json:"packing_unit"`
  371. Dosage int64 `json:"dosage"`
  372. ExpireDate int64 `json:"expire_date"`
  373. ConsumableType int64 `gorm:"column:consumable_type" json:"consumable_type" form:"consumable_type"`
  374. }
  375. type DrugFlow struct {
  376. ID int64 `gorm:"column:id" json:"id" form:"id"`
  377. WarehousingId int64 `gorm:"column:warehousing_id" json:"warehousing_id" form:"warehousing_id"`
  378. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  379. Number string `gorm:"column:number" json:"number" form:"number"`
  380. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  381. Count int64 `gorm:"column:count" json:"count" form:"count"`
  382. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  383. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  384. SystemTime int64 `gorm:"column:system_time" json:"system_time" form:"system_time"`
  385. ConsumableType int64 `gorm:"column:consumable_type" json:"consumable_type" form:"consumable_type"`
  386. IsSys int64 `gorm:"column:is_sys" json:"is_sys" form:"is_sys"`
  387. WarehousingOrder string `gorm:"column:warehousing_order" json:"warehousing_order" form:"warehousing_order"`
  388. WarehouseOutId int64 `gorm:"column:warehouse_out_id" json:"warehouse_out_id" form:"warehouse_out_id"`
  389. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  390. IsEdit int64 `gorm:"column:is_edit" json:"is_edit" form:"is_edit"`
  391. CancelStockId int64 `gorm:"column:cancel_stock_id" json:"cancel_stock_id" form:"cancel_stock_id"`
  392. CancelOrderNumber string `gorm:"column:cancel_order_number" json:"cancel_order_number" form:"cancel_order_number"`
  393. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  394. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  395. Creator int64 `gorm:"column:creator" json:"creator" form:"creator"`
  396. UpdateCreator int64 `gorm:"column:update_creator" json:"update_creator" form:"update_creator"`
  397. Status int64 `gorm:"column:status" json:"status" form:"status"`
  398. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  399. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  400. Price float64 `gorm:"column:price" json:"price" form:"price"`
  401. WarehousingDetailId int64 `gorm:"column:warehousing_detail_id" json:"warehousing_detail_id" form:"warehousing_detail_id"`
  402. WarehouseOutDetailId int64 `gorm:"column:warehouse_out_detail_id" json:"warehouse_out_detail_id" form:"warehouse_out_detail_id"`
  403. CancelOutDetailId int64 `gorm:"column:cancel_out_detail_id" json:"cancel_out_detail_id" form:"cancel_out_detail_id"`
  404. ExpireDate int64 `gorm:"column:expire_date" json:"expire_date" form:"expire_date"`
  405. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  406. MaxUnit string `gorm:"column:max_unit" json:"max_unit" form:"max_unit"`
  407. MinUnit string `gorm:"column:min_unit" json:"min_unit" form:"min_unit"`
  408. StockMaxNumber int64 `gorm:"column:stock_max_number" json:"stock_max_number" form:"stock_max_number"`
  409. StockMinNumber int64 `gorm:"column:stock_min_number" json:"stock_min_number" form:"stock_min_number"`
  410. LastStockMaxNumber int64 `gorm:"column:last_stock_max_number" json:"last_stock_max_number" form:"last_stock_max_number"`
  411. LastStockMinNumber int64 `gorm:"column:last_stock_min_number" json:"last_stock_min_number" form:"last_stock_min_number"`
  412. DrugWarehouseInfo []*DrugWarehouseInfo `gorm:"ForeignKey:DrugId;AssociationForeignKey:DrugId" `
  413. BaseDrugLib BaseDrugLib `gorm:"ForeignKey:ID;AssociationForeignKey:DrugId" `
  414. AdviceId int64 `gorm:"column:advice_id" json:"advice_id" form:"advice_id"`
  415. SupplyWarehouseId int64 `gorm:"column:supply_warehouse_id" json:"supply_warehouse_id" form:"supply_warehouse_id"`
  416. SupplyCancelOutId int64 `gorm:"column:supply_cancel_out_id" json:"supply_cancel_out_id" form:"supply_cancel_out_id"`
  417. SupplyWarehouseDetailInfo int64 `gorm:"column:supply_warehouse_detail_info" json:"supply_warehouse_detail_info" form:"supply_warehouse_detail_info"`
  418. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  419. SecondWarehouseInfoId int64 `gorm:"column:second_warehouse_info_id" json:"second_warehouse_info_id" form:"second_warehouse_info_id"`
  420. AdminUserId int64 `gorm:"column:admin_user_id" json:"admin_user_id" form:"admin_user_id"`
  421. LastPrice float64 `gorm:"column:last_price" json:"last_price" form:"last_price"`
  422. StockCount string `gorm:"column:stock_count" json:"stock_count" form:"stock_count"`
  423. PharmacyId int64 `gorm:"column:pharmacy_id" json:"pharmacy_id" form:"pharmacy_id"`
  424. DrugWarehouseInfoOne DrugWarehouseInfo `gorm:"ForeignKey:ID;AssociationForeignKey:WarehousingDetailId"json:"xt_drug_warehouse_info" `
  425. IsRead int64 `gorm:"column:is_read" json:"is_read" form:"is_read"`
  426. IsCheck int64 `gorm:"column:is_check" json:"is_check" form:"is_check"`
  427. OverCount int64 `gorm:"column:over_count" json:"over_count" form:"over_count"`
  428. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  429. XtDrugWarehouseOutInfo XtDrugWarehouseOutInfo `gorm:"ForeignKey:ID;AssociationForeignKey:WarehouseOutDetailId"json:"xt_drug_warehouse_out_info" `
  430. OrderId int64 `gorm:"column:order_id" json:"order_id" form:"order_id"`
  431. FlushOverCount int64 `gorm:"column:flush_over_count" json:"flush_over_count" form:"flush_over_count"`
  432. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  433. }
  434. func (DrugFlow) TableName() string {
  435. return "xt_drug_flow"
  436. }
  437. type DrugWarehouseOutTwenty struct {
  438. ID int64 `gorm:"column:id" json:"id" form:"id"`
  439. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  440. OperationTime int64 `gorm:"column:operation_time" json:"operation_time" form:"operation_time"`
  441. Creater int64 `gorm:"column:creater" json:"creater" form:"creater"`
  442. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  443. Modifier int64 `gorm:"column:modifier" json:"modifier" form:"modifier"`
  444. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  445. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  446. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  447. Status int64 `gorm:"column:status" json:"status" form:"status"`
  448. WarehouseOutTime int64 `gorm:"column:warehouse_out_time" json:"warehouse_out_time" form:"warehouse_out_time"`
  449. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  450. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  451. Type int64 `gorm:"column:type" json:"type" form:"type"`
  452. IsSys int64 `gorm:"column:is_sys" json:"is_sys" form:"is_sys"`
  453. SupplyCancelOutId int64 `gorm:"column:supply_cancel_out_id" json:"supply_cancel_out_id" form:"supply_cancel_out_id"`
  454. SupplyWarehouseId int64 `gorm:"column:supply_warehouse_id" json:"supply_warehouse_id" form:"supply_warehouse_id"`
  455. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  456. SecondWarehouseId int64 `gorm:"column:second_warehouse_id" json:"second_warehouse_id" form:"second_warehouse_id"`
  457. BaseDrugLib BaseDrugLib `gorm:"ForeignKey:ID;AssociationForeignKey:DrugId"json:"drug" `
  458. DrugWarehouseOutInfoTenty []*DrugWarehouseOutInfoTenty `gorm:"ForeignKey:WarehouseOutId;AssociationForeignKey:ID"json:"xt_drug_warehouse_out_info" `
  459. }
  460. func (DrugWarehouseOutTwenty) TableName() string {
  461. return "xt_drug_warehouse_out"
  462. }
  463. type DrugWarehouseOutInfoTenty struct {
  464. ID int64 `gorm:"column:id" json:"id" form:"id"`
  465. WarehouseOutId int64 `gorm:"column:warehouse_out_id" json:"warehouse_out_id" form:"warehouse_out_id"`
  466. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  467. WarehousingOutTarget int64 `gorm:"column:warehousing_out_target" json:"warehousing_out_target" form:"warehousing_out_target"`
  468. Count int64 `gorm:"column:count" json:"count" form:"count"`
  469. CountUnit string `gorm:"column:count_unit" json:"count_unit" form:"count_unit"`
  470. Price float64 `gorm:"column:price" json:"price" form:"price"`
  471. TotalPrice float64 `gorm:"column:total_price" json:"total_price" form:"total_price"`
  472. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  473. ExpiryDate int64 `gorm:"column:expiry_date" json:"expiry_date" form:"expiry_date"`
  474. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  475. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  476. Status int64 `gorm:"column:status" json:"status" form:"status"`
  477. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  478. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  479. IsCancel int64 `gorm:"column:is_cancel" json:"is_cancel" form:"is_cancel"`
  480. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  481. Type int64 `gorm:"column:type" json:"type" form:"type"`
  482. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  483. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  484. IsSys int64 `gorm:"column:is_sys" json:"is_sys" form:"is_sys"`
  485. SysRecordTime int64 `gorm:"column:sys_record_time" json:"sys_record_time" form:"sys_record_time"`
  486. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  487. RetailTotalPrice float64 `gorm:"column:retail_total_price" json:"retail_total_price" form:"retail_total_price"`
  488. Number string `gorm:"column:number" json:"number" form:"number"`
  489. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  490. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  491. WarehouseInfoId int64 `gorm:"column:warehouse_info_id" json:"warehouse_info_id" form:"warehouse_info_id"`
  492. AdviceId int64 `gorm:"column:advice_id" json:"advice_id" form:"advice_id"`
  493. SupplyCancelOutId int64 `gorm:"column:supply_cancel_out_id" json:"supply_cancel_out_id" form:"supply_cancel_out_id"`
  494. SupplyWarehouseId int64 `gorm:"column:supply_warehouse_id" json:"supply_warehouse_id" form:"supply_warehouse_id"`
  495. IsSource int64 `gorm:"column:is_source" json:"is_source" form:"is_source"`
  496. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  497. SecondWarehouseInfoId int64 `gorm:"column:second_warehouse_info_id" json:"second_warehouse_info_id" form:"second_warehouse_info_id"`
  498. AdminUserId int64 `gorm:"column:admin_user_id" json:"admin_user_id" form:"admin_user_id"`
  499. LastPrice float64 `gorm:"column:last_price" json:"last_price" form:"last_price"`
  500. StockCount string `gorm:"column:stock_count" json:"stock_count" form:"stock_count"`
  501. PharmacyId int64 `gorm:"column:pharmacy_id" json:"pharmacy_id" form:"pharmacy_id"`
  502. BaseDrugLib BaseDrugLib `gorm:"ForeignKey:ID;AssociationForeignKey:DrugId"json:"drug" `
  503. DrugWarehouseInfo XtDrugWarehouseInfo `gorm:"ForeignKey:ID;AssociationForeignKey:WarehouseInfoId"json:"drug_warehouse_info" `
  504. }
  505. func (DrugWarehouseOutInfoTenty) TableName() string {
  506. return "xt_drug_warehouse_out_info"
  507. }
  508. type DrugWarehouseInfoTwenty struct {
  509. ID int64 `gorm:"column:id" json:"id" form:"id"`
  510. WarehousingId int64 `gorm:"column:warehousing_id" json:"warehousing_id" form:"warehousing_id"`
  511. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  512. Number string `gorm:"column:number" json:"number" form:"number"`
  513. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  514. ExpiryDate int64 `gorm:"column:expiry_date" json:"expiry_date" form:"expiry_date"`
  515. WarehousingCount int64 `gorm:"column:warehousing_count" json:"warehousing_count" form:"warehousing_count"`
  516. Price float64 `gorm:"column:price" json:"price" form:"price"`
  517. TotalPrice float64 `gorm:"column:total_price" json:"total_price" form:"total_price"`
  518. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  519. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  520. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  521. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  522. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  523. Status int64 `gorm:"column:status" json:"status" form:"status"`
  524. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  525. IsReturn int64 `gorm:"column:is_return" json:"is_return" form:"is_return"`
  526. WarehousingOrder string `gorm:"column:warehousing_order" json:"warehousing_order" form:"warehousing_order"`
  527. Type int64 `gorm:"column:type" json:"type" form:"type"`
  528. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  529. RetailTotalPrice float64 `gorm:"column:retail_total_price" json:"retail_total_price" form:"retail_total_price"`
  530. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  531. MaxUnit string `gorm:"column:max_unit" json:"max_unit" form:"max_unit"`
  532. MinUnit string `gorm:"column:min_unit" json:"min_unit" form:"min_unit"`
  533. StockMaxNumber int64 `gorm:"column:stock_max_number" json:"stock_max_number" form:"stock_max_number"`
  534. StockMinNumber int64 `gorm:"column:stock_min_number" json:"stock_min_number" form:"stock_min_number"`
  535. WarehousingInfoId int64 `gorm:"column:warehousing_info_id" json:"warehousing_info_id" form:"warehousing_info_id"`
  536. SupplyWarehouseId int64 `gorm:"column:supply_warehouse_id" json:"supply_warehouse_id" form:"supply_warehouse_id"`
  537. SupplyWarehouseDetailInfo int64 `gorm:"column:supply_warehouse_detail_info" json:"supply_warehouse_detail_info" form:"supply_warehouse_detail_info"`
  538. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  539. SecondWarehouseInfoId int64 `gorm:"column:second_warehouse_info_id" json:"second_warehouse_info_id" form:"second_warehouse_info_id"`
  540. IsCheck int64 `gorm:"column:is_check" json:"is_check" form:"is_check"`
  541. BaseDrugLib BaseDrugLib `gorm:"ForeignKey:ID;AssociationForeignKey:DrugId"json:"drug" `
  542. DrugWarehouseOutInfoTenty []*DrugWarehouseOutInfoTenty `gorm:"ForeignKey:WarehouseOutId;AssociationForeignKey:ID"json:"xt_drug_warehouse_out_info" `
  543. }
  544. func (DrugWarehouseInfoTwenty) TableName() string {
  545. return "xt_drug_warehouse_info"
  546. }
  547. type XtDrugWarehouseFlushInfo struct {
  548. ID int64 `gorm:"column:id" json:"id" form:"id"`
  549. DrugMaxNumber int64 `gorm:"column:drug_max_number" json:"drug_max_number" form:"drug_max_number"`
  550. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  551. WarehouseOutId int64 `gorm:"column:warehouse_out_id" json:"warehouse_out_id" form:"warehouse_out_id"`
  552. Type int64 `gorm:"column:type" json:"type" form:"type"`
  553. SystemTime int64 `gorm:"column:system_time" json:"system_time" form:"system_time"`
  554. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  555. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  556. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  557. BatchNumberId int64 `gorm:"column:batch_number_id" json:"batch_number_id" form:"batch_number_id"`
  558. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  559. Count int64 `gorm:"column:count" json:"count" form:"count"`
  560. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  561. Creater int64 `gorm:"column:creater" json:"creater" form:"creater"`
  562. DrugMinNumber int64 `gorm:"column:drug_min_number" json:"drug_min_number" form:"drug_min_number"`
  563. Unit string `gorm:"column:unit" json:"unit" form:"unit"`
  564. AdviceId int64 `gorm:"column:advice_id" json:"advice_id" form:"advice_id"`
  565. Status int64 `gorm:"column:status" json:"status" form:"status"`
  566. WarehouseOutDetailId int64 `gorm:"column:warehouse_out_detail_id" json:"warehouse_out_detail_id" form:"warehouse_out_detail_id"`
  567. }
  568. func (XtDrugWarehouseFlushInfo) TableName() string {
  569. return "xt_drug_warehouse_flush_info"
  570. }
  571. type DrugFlowNight struct {
  572. ID int64 `gorm:"column:id" json:"id" form:"id"`
  573. WarehousingId int64 `gorm:"column:warehousing_id" json:"warehousing_id" form:"warehousing_id"`
  574. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  575. Number string `gorm:"column:number" json:"number" form:"number"`
  576. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  577. Count int64 `gorm:"column:count" json:"count" form:"count"`
  578. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  579. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  580. SystemTime int64 `gorm:"column:system_time" json:"system_time" form:"system_time"`
  581. ConsumableType int64 `gorm:"column:consumable_type" json:"consumable_type" form:"consumable_type"`
  582. IsSys int64 `gorm:"column:is_sys" json:"is_sys" form:"is_sys"`
  583. WarehousingOrder string `gorm:"column:warehousing_order" json:"warehousing_order" form:"warehousing_order"`
  584. WarehouseOutId int64 `gorm:"column:warehouse_out_id" json:"warehouse_out_id" form:"warehouse_out_id"`
  585. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  586. IsEdit int64 `gorm:"column:is_edit" json:"is_edit" form:"is_edit"`
  587. CancelStockId int64 `gorm:"column:cancel_stock_id" json:"cancel_stock_id" form:"cancel_stock_id"`
  588. CancelOrderNumber string `gorm:"column:cancel_order_number" json:"cancel_order_number" form:"cancel_order_number"`
  589. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  590. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  591. Creator int64 `gorm:"column:creator" json:"creator" form:"creator"`
  592. UpdateCreator int64 `gorm:"column:update_creator" json:"update_creator" form:"update_creator"`
  593. Status int64 `gorm:"column:status" json:"status" form:"status"`
  594. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  595. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  596. Price float64 `gorm:"column:price" json:"price" form:"price"`
  597. WarehousingDetailId int64 `gorm:"column:warehousing_detail_id" json:"warehousing_detail_id" form:"warehousing_detail_id"`
  598. WarehouseOutDetailId int64 `gorm:"column:warehouse_out_detail_id" json:"warehouse_out_detail_id" form:"warehouse_out_detail_id"`
  599. CancelOutDetailId int64 `gorm:"column:cancel_out_detail_id" json:"cancel_out_detail_id" form:"cancel_out_detail_id"`
  600. ExpireDate int64 `gorm:"column:expire_date" json:"expire_date" form:"expire_date"`
  601. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  602. MaxUnit string `gorm:"column:max_unit" json:"max_unit" form:"max_unit"`
  603. MinUnit string `gorm:"column:min_unit" json:"min_unit" form:"min_unit"`
  604. StockMaxNumber int64 `gorm:"column:stock_max_number" json:"stock_max_number" form:"stock_max_number"`
  605. StockMinNumber int64 `gorm:"column:stock_min_number" json:"stock_min_number" form:"stock_min_number"`
  606. LastStockMaxNumber int64 `gorm:"column:last_stock_max_number" json:"last_stock_max_number" form:"last_stock_max_number"`
  607. LastStockMinNumber int64 `gorm:"column:last_stock_min_number" json:"last_stock_min_number" form:"last_stock_min_number"`
  608. BaseDrugLibSeven BaseDrugLibSeven `gorm:"ForeignKey:ID;AssociationForeignKey:DrugId" `
  609. AdviceId int64 `gorm:"column:advice_id" json:"advice_id" form:"advice_id"`
  610. SupplyWarehouseId int64 `gorm:"column:supply_warehouse_id" json:"supply_warehouse_id" form:"supply_warehouse_id"`
  611. SupplyCancelOutId int64 `gorm:"column:supply_cancel_out_id" json:"supply_cancel_out_id" form:"supply_cancel_out_id"`
  612. SupplyWarehouseDetailInfo int64 `gorm:"column:supply_warehouse_detail_info" json:"supply_warehouse_detail_info" form:"supply_warehouse_detail_info"`
  613. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  614. SecondWarehouseInfoId int64 `gorm:"column:second_warehouse_info_id" json:"second_warehouse_info_id" form:"second_warehouse_info_id"`
  615. AdminUserId int64 `gorm:"column:admin_user_id" json:"admin_user_id" form:"admin_user_id"`
  616. LastPrice float64 `gorm:"column:last_price" json:"last_price" form:"last_price"`
  617. StockCount string `gorm:"column:stock_count" json:"stock_count" form:"stock_count"`
  618. PharmacyId int64 `gorm:"column:pharmacy_id" json:"pharmacy_id" form:"pharmacy_id"`
  619. DrugWarehouseInfoOne DrugWarehouseInfo `gorm:"ForeignKey:ID;AssociationForeignKey:WarehousingDetailId"json:"xt_drug_warehouse_info" `
  620. IsRead int64 `gorm:"column:is_read" json:"is_read" form:"is_read"`
  621. IsCheck int64 `gorm:"column:is_check" json:"is_check" form:"is_check"`
  622. OverCount int64 `gorm:"column:over_count" json:"over_count" form:"over_count"`
  623. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  624. OrderId int64 `gorm:"column:order_id" json:"order_id" form:"order_id"`
  625. }
  626. func (DrugFlowNight) TableName() string {
  627. return "xt_drug_flow"
  628. }
  629. type DrugWarehouseOutInfoNight struct {
  630. ID int64 `gorm:"column:id" json:"id" form:"id"`
  631. WarehouseOutId int64 `gorm:"column:warehouse_out_id" json:"warehouse_out_id" form:"warehouse_out_id"`
  632. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  633. WarehousingOutTarget int64 `gorm:"column:warehousing_out_target" json:"warehousing_out_target" form:"warehousing_out_target"`
  634. Count int64 `gorm:"column:count" json:"count" form:"count"`
  635. CountUnit string `gorm:"column:count_unit" json:"count_unit" form:"count_unit"`
  636. Price float64 `gorm:"column:price" json:"price" form:"price"`
  637. TotalPrice float64 `gorm:"column:total_price" json:"total_price" form:"total_price"`
  638. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  639. ExpiryDate int64 `gorm:"column:expiry_date" json:"expiry_date" form:"expiry_date"`
  640. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  641. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  642. Status int64 `gorm:"column:status" json:"status" form:"status"`
  643. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  644. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  645. IsCancel int64 `gorm:"column:is_cancel" json:"is_cancel" form:"is_cancel"`
  646. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  647. Type int64 `gorm:"column:type" json:"type" form:"type"`
  648. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  649. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  650. IsSys int64 `gorm:"column:is_sys" json:"is_sys" form:"is_sys"`
  651. SysRecordTime int64 `gorm:"column:sys_record_time" json:"sys_record_time" form:"sys_record_time"`
  652. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  653. RetailTotalPrice float64 `gorm:"column:retail_total_price" json:"retail_total_price" form:"retail_total_price"`
  654. Number string `gorm:"column:number" json:"number" form:"number"`
  655. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  656. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  657. WarehouseInfoId int64 `gorm:"column:warehouse_info_id" json:"warehouse_info_id" form:"warehouse_info_id"`
  658. AdviceId int64 `gorm:"column:advice_id" json:"advice_id" form:"advice_id"`
  659. SupplyCancelOutId int64 `gorm:"column:supply_cancel_out_id" json:"supply_cancel_out_id" form:"supply_cancel_out_id"`
  660. SupplyWarehouseId int64 `gorm:"column:supply_warehouse_id" json:"supply_warehouse_id" form:"supply_warehouse_id"`
  661. IsSource int64 `gorm:"column:is_source" json:"is_source" form:"is_source"`
  662. StorehouseId int64 `gorm:"column:storehouse_id" json:"storehouse_id" form:"storehouse_id"`
  663. SecondWarehouseInfoId int64 `gorm:"column:second_warehouse_info_id" json:"second_warehouse_info_id" form:"second_warehouse_info_id"`
  664. AdminUserId int64 `gorm:"column:admin_user_id" json:"admin_user_id" form:"admin_user_id"`
  665. LastPrice float64 `gorm:"column:last_price" json:"last_price" form:"last_price"`
  666. StockCount string `gorm:"column:stock_count" json:"stock_count" form:"stock_count"`
  667. PharmacyId int64 `gorm:"column:pharmacy_id" json:"pharmacy_id" form:"pharmacy_id"`
  668. IsCheck int64 `gorm:"column:is_check" json:"is_check" form:"is_check"`
  669. Drug BaseDrugLibSeven `gorm:"ForeignKey:ID;AssociationForeignKey:DrugId"json:"drug" `
  670. OverCount int64 `gorm:"column:over_count" json:"over_count" form:"over_count"`
  671. OrderId int64 `gorm:"column:order_id" json:"order_id" form:"order_id"`
  672. }
  673. func (DrugWarehouseOutInfoNight) TableName() string {
  674. return "xt_drug_warehouse_out_info"
  675. }
  676. type XtDrugError struct {
  677. ID int64 `gorm:"column:id" json:"id" form:"id"`
  678. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  679. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  680. RecordDate int64 `gorm:"column:record_date" json:"record_date" form:"record_date"`
  681. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  682. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  683. Status int64 `gorm:"column:status" json:"status" form:"status"`
  684. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  685. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  686. Prescribingnumber float64 `gorm:"column:prescribingnumber" json:"prescribingnumber" form:"prescribingnumber"`
  687. PrescribingNumberUnit string `gorm:"column:prescribing_number_unit" json:"prescribing_number_unit" form:"prescribing_number_unit"`
  688. SumCount int64 `gorm:"column:sum_count" json:"sum_count" form:"sum_count"`
  689. }
  690. func (XtDrugError) TableName() string {
  691. return "xt_drug_error"
  692. }