drug_stock.go 26KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366
  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. }
  17. func (DrugWarehouse) TableName() string {
  18. return "xt_drug_warehouse"
  19. }
  20. type DrugWarehouseInfoSix struct {
  21. ID int64 `gorm:"column:id" json:"id" form:"id"`
  22. WarehousingId int64 `gorm:"column:warehousing_id" json:"warehousing_id" form:"warehousing_id"`
  23. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  24. Number string `gorm:"column:number" json:"number" form:"number"`
  25. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  26. ExpiryDate int64 `gorm:"column:expiry_date" json:"expiry_date" form:"expiry_date"`
  27. WarehousingCount int64 `gorm:"column:warehousing_count" json:"warehousing_count" form:"warehousing_count"`
  28. Price float64 `gorm:"column:price" json:"price" form:"price"`
  29. TotalPrice float64 `gorm:"column:total_price" json:"total_price" form:"total_price"`
  30. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  31. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  32. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  33. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  34. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  35. Status int64 `gorm:"column:status" json:"status" form:"status"`
  36. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  37. IsReturn int64 `gorm:"column:is_return" json:"is_return" form:"is_return"`
  38. WarehousingOrder string `gorm:"column:warehousing_order" json:"warehousing_order" form:"warehousing_order"`
  39. Type int64 `gorm:"column:type" json:"type" form:"type"`
  40. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  41. RetailTotalPrice float64 `gorm:"column:retail_total_price" json:"retail_total_price" form:"retail_total_price"`
  42. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  43. MaxUnit string `gorm:"column:max_unit" json:"max_unit" form:"max_unit"`
  44. MinUnit string `gorm:"column:min_unit" json:"min_unit" form:"min_unit"`
  45. StockMaxNumber int64 `gorm:"column:stock_max_number" json:"stock_max_number" form:"stock_max_number"`
  46. StockMinNumber int64 `gorm:"column:stock_min_number" json:"stock_min_number" form:"stock_min_number"`
  47. MinNumber int64 `json:"min_number"`
  48. }
  49. type DrugWarehouseInfo struct {
  50. ID int64 `gorm:"column:id" json:"id" form:"id"`
  51. WarehousingId int64 `gorm:"column:warehousing_id" json:"warehousing_id" form:"warehousing_id"`
  52. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  53. Number string `gorm:"column:number" json:"number" form:"number"`
  54. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  55. ExpiryDate int64 `gorm:"column:expiry_date" json:"expiry_date" form:"expiry_date"`
  56. WarehousingCount int64 `gorm:"column:warehousing_count" json:"warehousing_count" form:"warehousing_count"`
  57. Price float64 `gorm:"column:price" json:"price" form:"price"`
  58. TotalPrice float64 `gorm:"column:total_price" json:"total_price" form:"total_price"`
  59. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  60. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  61. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  62. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  63. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  64. Status int64 `gorm:"column:status" json:"status" form:"status"`
  65. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  66. IsReturn int64 `gorm:"column:is_return" json:"is_return" form:"is_return"`
  67. WarehousingOrder string `gorm:"column:warehousing_order" json:"warehousing_order" form:"warehousing_order"`
  68. Type int64 `gorm:"column:type" json:"type" form:"type"`
  69. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  70. RetailTotalPrice float64 `gorm:"column:retail_total_price" json:"retail_total_price" form:"retail_total_price"`
  71. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  72. MaxUnit string `gorm:"column:max_unit" json:"max_unit" form:"max_unit"`
  73. MinUnit string `gorm:"column:min_unit" json:"min_unit" form:"min_unit"`
  74. StockMaxNumber int64 `gorm:"column:stock_max_number" json:"stock_max_number" form:"stock_max_number"`
  75. StockMinNumber int64 `gorm:"column:stock_min_number" json:"stock_min_number" form:"stock_min_number"`
  76. }
  77. func (DrugWarehouseInfo) TableName() string {
  78. return "xt_drug_warehouse_info"
  79. }
  80. type DrugWarehouseOut struct {
  81. ID int64 `gorm:"column:id" json:"id" form:"id"`
  82. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  83. OperationTime int64 `gorm:"column:operation_time" json:"operation_time" form:"operation_time"`
  84. Creater int64 `gorm:"column:creater" json:"creater" form:"creater"`
  85. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  86. Modifier int64 `gorm:"column:modifier" json:"modifier" form:"modifier"`
  87. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  88. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  89. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  90. Status int64 `gorm:"column:status" json:"status" form:"status"`
  91. WarehouseOutTime int64 `gorm:"column:warehouse_out_time" json:"warehouse_out_time" form:"warehouse_out_time"`
  92. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  93. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  94. Type int64 `gorm:"column:type" json:"type" form:"type"`
  95. IsSys int64 `gorm:"column:is_sys" json:"is_sys" form:"is_sys"`
  96. Manufacturers *Manufacturer `gorm:"ForeignKey:Manufacturer;AssociationForeignKey:ID" json:"manufacturers"`
  97. Dealers *Dealer `gorm:"ForeignKey:Dealer;AssociationForeignKey:ID" json:"dealers"`
  98. }
  99. func (DrugWarehouseOut) TableName() string {
  100. return "xt_drug_warehouse_out"
  101. }
  102. type DrugWarehouseOutInfo struct {
  103. ID int64 `gorm:"column:id" json:"id" form:"id"`
  104. WarehouseOutId int64 `gorm:"column:warehouse_out_id" json:"warehouse_out_id" form:"warehouse_out_id"`
  105. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  106. WarehousingOutTarget int64 `gorm:"column:warehousing_out_target" json:"warehousing_out_target" form:"warehousing_out_target"`
  107. Count int64 `gorm:"column:count" json:"count" form:"count"`
  108. CountUnit string `gorm:"column:count_unit" json:"count_unit" form:"count_unit"`
  109. Price float64 `gorm:"column:price" json:"price" form:"price"`
  110. TotalPrice float64 `gorm:"column:total_price" json:"total_price" form:"total_price"`
  111. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  112. ExpiryDate int64 `gorm:"column:expiry_date" json:"expiry_date" form:"expiry_date"`
  113. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  114. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  115. Status int64 `gorm:"column:status" json:"status" form:"status"`
  116. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  117. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  118. IsCancel int64 `gorm:"column:is_cancel" json:"is_cancel" form:"is_cancel"`
  119. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  120. Type int64 `gorm:"column:type" json:"type" form:"type"`
  121. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  122. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  123. IsSys int64 `gorm:"column:is_sys" json:"is_sys" form:"is_sys"`
  124. SysRecordTime int64 `gorm:"column:sys_record_time" json:"sys_record_time" form:"sys_record_time"`
  125. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  126. RetailTotalPrice float64 `gorm:"column:retail_total_price" json:"retail_total_price" form:"retail_total_price"`
  127. Number string `gorm:"column:number" json:"number" form:"number"`
  128. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  129. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  130. WarehouseInfoId int64 `gorm:"column:warehouse_info_id" json:"warehouse_info_id" form:"warehouse_info_id"`
  131. }
  132. func (DrugWarehouseOutInfo) TableName() string {
  133. return "xt_drug_warehouse_out_info"
  134. }
  135. type DrugSalesReturn struct {
  136. ID int64 `gorm:"column:id" json:"id" form:"id"`
  137. OrderNumber string `gorm:"column:order_number" json:"order_number" form:"order_number"`
  138. OperaTime int64 `gorm:"column:opera_time" json:"opera_time" form:"opera_time"`
  139. Total int64 `gorm:"column:total" json:"total" form:"total"`
  140. Creater int64 `gorm:"column:creater" json:"creater" form:"creater"`
  141. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  142. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  143. Status int64 `gorm:"column:status" json:"status" form:"status"`
  144. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  145. ReturnTime int64 `gorm:"column:return_time" json:"return_time" form:"return_time"`
  146. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  147. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  148. Type int64 `gorm:"column:type" json:"type" form:"type"`
  149. Manufacturers *Manufacturer `gorm:"ForeignKey:Manufacturer;AssociationForeignKey:ID" json:"manufacturers"`
  150. Dealers *Dealer `gorm:"ForeignKey:Dealer;AssociationForeignKey:ID" json:"dealers"`
  151. }
  152. func (DrugSalesReturn) TableName() string {
  153. return "xt_drug_sales_return"
  154. }
  155. type DrugSalesReturnInfo struct {
  156. ID int64 `gorm:"column:id" json:"id" form:"id"`
  157. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  158. SalesReturnId int64 `gorm:"column:sales_return_id" json:"sales_return_id" form:"sales_return_id"`
  159. Count int64 `gorm:"column:count" json:"count" form:"count"`
  160. Price float64 `gorm:"column:price" json:"price" form:"price"`
  161. Total float64 `gorm:"column:total" json:"total" form:"total"`
  162. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  163. ExpiryDate int64 `gorm:"column:expiry_date" json:"expiry_date" form:"expiry_date"`
  164. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  165. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  166. Status int64 `gorm:"column:status" json:"status" form:"status"`
  167. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  168. OrderNumber string `gorm:"column:order_number" json:"order_number" form:"order_number"`
  169. Type int64 `gorm:"column:type" json:"type" form:"type"`
  170. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  171. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  172. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  173. RetailTotalPrice float64 `gorm:"column:retail_total_price" json:"retail_total_price" form:"retail_total_price"`
  174. Number string `gorm:"column:number" json:"number" form:"number"`
  175. }
  176. func (DrugSalesReturnInfo) TableName() string {
  177. return "xt_drug_sales_return_info"
  178. }
  179. type DrugCancelStock struct {
  180. ID int64 `gorm:"column:id" json:"id" form:"id"`
  181. OrderNumber string `gorm:"column:order_number" json:"order_number" form:"order_number"`
  182. OperaTime int64 `gorm:"column:opera_time" json:"opera_time" form:"opera_time"`
  183. Total int64 `gorm:"column:total" json:"total" form:"total"`
  184. Creater int64 `gorm:"column:creater" json:"creater" form:"creater"`
  185. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  186. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  187. Status int64 `gorm:"column:status" json:"status" form:"status"`
  188. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  189. ReturnTime int64 `gorm:"column:return_time" json:"return_time" form:"return_time"`
  190. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  191. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  192. Type int64 `gorm:"column:type" json:"type" form:"type"`
  193. Manufacturers *Manufacturer `gorm:"ForeignKey:Manufacturer;AssociationForeignKey:ID" json:"manufacturers"`
  194. Dealers *Dealer `gorm:"ForeignKey:Dealer;AssociationForeignKey:ID" json:"dealers"`
  195. DrugCancelStockInfo []*DrugCancelStockInfo `gorm:"ForeignKey:CancelStockId;AssociationForeignKey:ID" json:"drugCancelStockInfo"`
  196. }
  197. func (DrugCancelStock) TableName() string {
  198. return "xt_drug_cancel_stock"
  199. }
  200. type DrugCancelStockInfo struct {
  201. ID int64 `gorm:"column:id" json:"id" form:"id"`
  202. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  203. CancelStockId int64 `gorm:"column:cancel_stock_id" json:"cancel_stock_id" form:"cancel_stock_id"`
  204. Count int64 `gorm:"column:count" json:"count" form:"count"`
  205. Price float64 `gorm:"column:price" json:"price" form:"price"`
  206. Total float64 `gorm:"column:total" json:"total" form:"total"`
  207. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  208. ExpiryDate int64 `gorm:"column:expiry_date" json:"expiry_date" form:"expiry_date"`
  209. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  210. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  211. Status int64 `gorm:"column:status" json:"status" form:"status"`
  212. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  213. OrderNumber string `gorm:"column:order_number" json:"order_number" form:"order_number"`
  214. Type int64 `gorm:"column:type" json:"type" form:"type"`
  215. Dealer string `gorm:"column:dealer" json:"dealer" form:"dealer"`
  216. Manufacturer string `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  217. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  218. RetailTotalPrice float64 `gorm:"column:retail_total_price" json:"retail_total_price" form:"retail_total_price"`
  219. Number string `gorm:"column:number" json:"number" form:"number"`
  220. RegisterAccount string `gorm:"column:register_account" json:"register_account" form:"register_account"`
  221. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  222. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  223. MaxUnit string `gorm:"column:max_unit" json:"max_unit" form:"max_unit"`
  224. BaseDrugLib BaseDrugLib `gorm:"ForeignKey:ID;AssociationForeignKey:DrugId" `
  225. BatchNumberId int64 `gorm:"column:batch_number_id" json:"batch_number_id" form:"batch_number_id"`
  226. }
  227. func (DrugCancelStockInfo) TableName() string {
  228. return "xt_drug_cancel_stock_info"
  229. }
  230. type DrugAutomaticReduceDetail struct {
  231. ID int64 `gorm:"column:id" json:"id" form:"id"`
  232. WarehouseOutId int64 `gorm:"column:warehouse_out_id" json:"warehouse_out_id" form:"warehouse_out_id"`
  233. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  234. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  235. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  236. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  237. Status int64 `gorm:"column:status" json:"status" form:"status"`
  238. RecordTime int64 `gorm:"column:record_time" json:"record_time" form:"record_time"`
  239. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  240. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  241. Count int64 `gorm:"column:count" json:"count" form:"count"`
  242. CountUnit string `gorm:"column:count_unit" json:"count_unit" form:"count_unit"`
  243. }
  244. func (DrugAutomaticReduceDetail) TableName() string {
  245. return "xt_drug_automatic_reduce_detail"
  246. }
  247. type VmDrugAutomaticReduceDetail struct {
  248. ID int64 `gorm:"column:id" json:"id" form:"id"`
  249. WarehouseOutId int64 `gorm:"column:warehouse_out_id" json:"warehouse_out_id" form:"warehouse_out_id"`
  250. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  251. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  252. RecordTime int64 `gorm:"column:record_time" json:"record_time" form:"record_time"`
  253. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  254. Total int64
  255. }
  256. type VmDrugWarehouseInfo struct {
  257. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  258. Count int64 `gorm:"column:count" json:"count" form:"count"`
  259. MaxUnit string `gorm:"column:max_unit" json:"max_unit" form:"max_unit"`
  260. MinUnit string `gorm:"column:min_unit" json:"min_unit" form:"min_unit"`
  261. CountUnit string `gorm:"column:count_unit" json:"count_unit" form:"count_unit"`
  262. StockMinNumber int64 `gorm:"column:stock_min_number" json:"stock_min_number" form:"stock_min_number"`
  263. StockMaxNumber int64 `gorm:"column:stock_max_number" json:"stock_max_number" form:"stock_max_number"`
  264. }
  265. type StDrugWarehouseOutInfo struct {
  266. ID int64 `gorm:"column:id" json:"id" form:"id"`
  267. WarehouseOutId int64 `gorm:"column:warehouse_out_id" json:"warehouse_out_id" form:"warehouse_out_id"`
  268. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  269. WarehousingOutTarget int64 `gorm:"column:warehousing_out_target" json:"warehousing_out_target" form:"warehousing_out_target"`
  270. Count int64 `gorm:"column:count" json:"count" form:"count"`
  271. CountUnit string `gorm:"column:count_unit" json:"count_unit" form:"count_unit"`
  272. Price float64 `gorm:"column:price" json:"price" form:"price"`
  273. TotalPrice float64 `gorm:"column:total_price" json:"total_price" form:"total_price"`
  274. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  275. ExpiryDate int64 `gorm:"column:expiry_date" json:"expiry_date" form:"expiry_date"`
  276. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  277. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  278. Status int64 `gorm:"column:status" json:"status" form:"status"`
  279. OrgId int64 `gorm:"column:org_id" json:"org_id" form:"org_id"`
  280. Remark string `gorm:"column:remark" json:"remark" form:"remark"`
  281. IsCancel int64 `gorm:"column:is_cancel" json:"is_cancel" form:"is_cancel"`
  282. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  283. Type int64 `gorm:"column:type" json:"type" form:"type"`
  284. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  285. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  286. IsSys int64 `gorm:"column:is_sys" json:"is_sys" form:"is_sys"`
  287. SysRecordTime int64 `gorm:"column:sys_record_time" json:"sys_record_time" form:"sys_record_time"`
  288. RetailPrice float64 `gorm:"column:retail_price" json:"retail_price" form:"retail_price"`
  289. RetailTotalPrice float64 `gorm:"column:retail_total_price" json:"retail_total_price" form:"retail_total_price"`
  290. Number string `gorm:"column:number" json:"number" form:"number"`
  291. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  292. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  293. DrugName string `json:"drug_name"`
  294. DrugType int64 `json:"drug_type"`
  295. MaxUnit string `json:"max_unit"`
  296. MinUnit string `json:"min_unit"`
  297. MinNumber int64 `json:"min_number"`
  298. MinPrice float64 `json:"min_price"`
  299. Dose float64 `json:"dose"`
  300. DoseUnit string `json:"dose_unit"`
  301. LastPrice string `json:"last_price"`
  302. PackingUnit string `json:"packing_unit"`
  303. Dosage int64 `json:"dosage"`
  304. }
  305. type DrugFlow struct {
  306. ID int64 `gorm:"column:id" json:"id" form:"id"`
  307. WarehousingId int64 `gorm:"column:warehousing_id" json:"warehousing_id" form:"warehousing_id"`
  308. DrugId int64 `gorm:"column:drug_id" json:"drug_id" form:"drug_id"`
  309. Number string `gorm:"column:number" json:"number" form:"number"`
  310. BatchNumber string `gorm:"column:batch_number" json:"batch_number" form:"batch_number"`
  311. Count int64 `gorm:"column:count" json:"count" form:"count"`
  312. UserOrgId int64 `gorm:"column:user_org_id" json:"user_org_id" form:"user_org_id"`
  313. PatientId int64 `gorm:"column:patient_id" json:"patient_id" form:"patient_id"`
  314. SystemTime int64 `gorm:"column:system_time" json:"system_time" form:"system_time"`
  315. ConsumableType int64 `gorm:"column:consumable_type" json:"consumable_type" form:"consumable_type"`
  316. IsSys int64 `gorm:"column:is_sys" json:"is_sys" form:"is_sys"`
  317. WarehousingOrder string `gorm:"column:warehousing_order" json:"warehousing_order" form:"warehousing_order"`
  318. WarehouseOutId int64 `gorm:"column:warehouse_out_id" json:"warehouse_out_id" form:"warehouse_out_id"`
  319. WarehouseOutOrderNumber string `gorm:"column:warehouse_out_order_number" json:"warehouse_out_order_number" form:"warehouse_out_order_number"`
  320. IsEdit int64 `gorm:"column:is_edit" json:"is_edit" form:"is_edit"`
  321. CancelStockId int64 `gorm:"column:cancel_stock_id" json:"cancel_stock_id" form:"cancel_stock_id"`
  322. CancelOrderNumber string `gorm:"column:cancel_order_number" json:"cancel_order_number" form:"cancel_order_number"`
  323. Manufacturer int64 `gorm:"column:manufacturer" json:"manufacturer" form:"manufacturer"`
  324. Dealer int64 `gorm:"column:dealer" json:"dealer" form:"dealer"`
  325. Creator int64 `gorm:"column:creator" json:"creator" form:"creator"`
  326. UpdateCreator int64 `gorm:"column:update_creator" json:"update_creator" form:"update_creator"`
  327. Status int64 `gorm:"column:status" json:"status" form:"status"`
  328. Ctime int64 `gorm:"column:ctime" json:"ctime" form:"ctime"`
  329. Mtime int64 `gorm:"column:mtime" json:"mtime" form:"mtime"`
  330. Price float64 `gorm:"column:price" json:"price" form:"price"`
  331. WarehousingDetailId int64 `gorm:"column:warehousing_detail_id" json:"warehousing_detail_id" form:"warehousing_detail_id"`
  332. WarehouseOutDetailId int64 `gorm:"column:warehouse_out_detail_id" json:"warehouse_out_detail_id" form:"warehouse_out_detail_id"`
  333. CancelOutDetailId int64 `gorm:"column:cancel_out_detail_id" json:"cancel_out_detail_id" form:"cancel_out_detail_id"`
  334. ExpireDate int64 `gorm:"column:expire_date" json:"expire_date" form:"expire_date"`
  335. ProductDate int64 `gorm:"column:product_date" json:"product_date" form:"product_date"`
  336. MaxUnit string `gorm:"column:max_unit" json:"max_unit" form:"max_unit"`
  337. MinUnit string `gorm:"column:min_unit" json:"min_unit" form:"min_unit"`
  338. }
  339. func (DrugFlow) TableName() string {
  340. return "xt_drug_flow"
  341. }