stock_template.go 8.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226
  1. package dto
  2. import (
  3. "Medical_ERP/common/dto"
  4. common "Medical_ERP/common/model"
  5. )
  6. // StockTemplateInInsertReq 增使用的结构体
  7. type StockTemplateInInsertReq struct {
  8. Id int `json:"id" comment:"id" swaggerignore:"true"`
  9. MedicineInfo map[string]interface{} `json:"medicineInfo"` // 药品信息
  10. Quantity int `json:"quantity" ` // 数量
  11. UnitPrice float32 `json:"unitPrice"` // 购入单价
  12. Operator string `json:"operator"` // 经办人
  13. ForwardingUnit string `json:"forwardingUnit"` // 发货单位
  14. Date string `json:"date"` // 入库日期
  15. Img string `json:"img"` // 药品图片
  16. common.ControlBy `swaggerignore:"true"`
  17. }
  18. // GetId 获取数据对应的ID
  19. func (s *StockTemplateInInsertReq) GetId() interface{} {
  20. return s.Id
  21. }
  22. // StockTemplateInEditReq 增使用的结构体
  23. type StockTemplateInEditReq struct {
  24. Id int `json:"id"` // 入库id
  25. MedicineInfo map[string]interface{} `json:"medicineInfo"` // 药品信息
  26. Quantity int `json:"quantity" ` // 数量
  27. UnitPrice float32 `json:"unit_Price"` // 购入单价
  28. Operator string `json:"operator"` // 经办人
  29. ForwardingUnit string `json:"forwarding_unit"` // 发货单位
  30. Date string `json:"date"` // 入库日期
  31. common.ControlBy `swaggerignore:"true"`
  32. }
  33. // GetId 获取数据对应的ID
  34. func (s *StockTemplateInEditReq) GetId() interface{} {
  35. return s.Id
  36. }
  37. // StockTemplateInDeleteReq 增使用的结构体
  38. type StockTemplateInDeleteReq struct {
  39. Id int `json:"id"` // 入库id
  40. common.ControlBy `swaggerignore:"true"`
  41. }
  42. // GetId 获取数据对应的ID
  43. func (s *StockTemplateInDeleteReq) GetId() interface{} {
  44. return s.Id
  45. }
  46. // BatchStockTemplateInInsertReq 增使用的结构体
  47. type BatchStockTemplateInInsertReq struct {
  48. StockInList []struct {
  49. Id int `json:"id" comment:"id" swaggerignore:"true"`
  50. MedicineInfo map[string]interface{} `json:"medicineInfo"` // 药品信息
  51. Quantity int `json:"quantity"` // 数量
  52. UnitPrice float32 `json:"unitPrice"` // 购入单价
  53. Operator string `json:"operator"` // 经办人
  54. ForwardingUnit string `json:"forwardingUnit"` // 发货单位
  55. Date string `json:"date" valid:"MinSize(1)"` // 入库日期
  56. Qrcode string `json:"Qrcode"` // 追溯码
  57. } `json:"stockInList"`
  58. common.ControlBy `swaggerignore:"true"`
  59. }
  60. // BatchStockTemplateOutInsertReq 增使用的结构体
  61. type BatchStockTemplateOutInsertReq struct {
  62. StockOutList []struct {
  63. Id int `json:"id" comment:"id" swaggerignore:"true"`
  64. MedicineInfo map[string]interface{} `json:"medicineInfo"` // 药品信息
  65. Quantity int `json:"quantity"` // 数量
  66. //UnitPrice float32 `json:"unitPrice"` // 销售单价
  67. Operator string `json:"operator"` // 经办人
  68. ReceivingUnit string `json:"receivingUnit"` // 收货单位
  69. Date string `json:"date" valid:"MinSize(1)"` // 出库日期
  70. Qrcode string `json:"Qrcode"` // 追溯码
  71. } `json:"stockOutList"`
  72. common.ControlBy `swaggerignore:"true"`
  73. }
  74. // StockTemplateInInsertReq 增使用的结构体
  75. type StockTemplateOutInsertReq struct {
  76. Id int `json:"id" comment:"id" swaggerignore:"true"`
  77. MedicineInfo map[string]interface{} `json:"medicineInfo"` // 药品信息
  78. Quantity int `json:"quantity" alias:"数量" valid:"Required;Min(1)"` // 数量
  79. //UnitPrice float32 `json:"unitPrice"` // 购入单价
  80. Operator string `json:"operator"` // 经办人
  81. ReceivingUnit string `json:"receivingUnit"` // 收货单位
  82. Date string `json:"date"` // 出库日期
  83. common.ControlBy `swaggerignore:"true"`
  84. }
  85. // GetId 获取数据对应的ID
  86. func (s *StockTemplateOutInsertReq) GetId() interface{} {
  87. return s.Id
  88. }
  89. // StockTemplateOutEditReq 增使用的结构体
  90. type StockTemplateOutEditReq struct {
  91. Id int `json:"id" comment:"id"`
  92. MedicineInfo map[string]interface{} `json:"medicineInfo"` // 药品信息
  93. Quantity int `json:"quantity" alias:"数量" valid:"Required;Min(1)"` // 数量
  94. //UnitPrice float32 `json:"unit_price"` // 购入单价
  95. Operator string `json:"operator"` // 经办人
  96. ReceivingUnit string `json:"receiving_unit"` // 收货单位
  97. Date string `json:"date"` // 出库日期
  98. common.ControlBy `swaggerignore:"true"`
  99. }
  100. // GetId 获取数据对应的ID
  101. func (s *StockTemplateOutEditReq) GetId() interface{} {
  102. return s.Id
  103. }
  104. // StockTemplateOutDeleteReq 增使用的结构体
  105. type StockTemplateOutDeleteReq struct {
  106. Id int `json:"id"`
  107. common.ControlBy `swaggerignore:"true"`
  108. }
  109. // GetId 获取数据对应的ID
  110. func (s *StockTemplateOutDeleteReq) GetId() interface{} {
  111. return s.Id
  112. }
  113. // StockTemplateInPageReq 列表或者搜索使用结构体
  114. type StockTemplateInPageReq struct {
  115. dto.Pagination `search:"-"`
  116. ProductID int `json:"productId"` // 药品名称id
  117. EnterpriseID int `json:"enterpriseId"` // 生产企业id
  118. StartDate string `json:"startDate"` // 入库开始时间
  119. EndDate string `json:"endDate"` // 入库结束时间
  120. BatchNumber string `json:"batchNumber"` // 批号
  121. ForwardingUnit string `json:"forwardingUnit"` // 发货单位
  122. }
  123. // StockTemplateOutPageReq 列表或者搜索使用结构体
  124. type StockTemplateOutPageReq struct {
  125. dto.Pagination `search:"-"`
  126. ProductID int `json:"productId"` // 药品名称id
  127. EnterpriseID int `json:"enterpriseId"` // 生产企业id
  128. StartDate string `json:"startDate"` // 出库开始时间
  129. EndDate string `json:"endDate"` // 出库结束时间
  130. BatchNumber string `json:"batchNumber"` // 批号
  131. ReceivingUnit string `json:"receivingUnit"` // 收货单位
  132. }
  133. // StockTemplateInventoryPageReq 列表或者搜索使用结构体
  134. type StockTemplateInventoryPageReq struct {
  135. dto.Pagination `search:"-"`
  136. ProductID int `json:"productId"` // 药品名称id
  137. EnterpriseID int `json:"enterpriseId"` // 生产企业id
  138. StartDate string `json:"startDate"` // 出/入库开始时间
  139. EndDate string `json:"endDate"` // 出/入库结束时间
  140. BatchNumber string `json:"batchNumber"` // 批号
  141. SendReceiveUnit string `json:"SendReceiveUnit"` // 收发单位
  142. }
  143. // StockTemplateInventoryEditReq 列表或者搜索使用结构体
  144. type StockTemplateInventoryEditReq struct {
  145. Id int `json:"id"`
  146. }
  147. // StockTemplateInventoryExcelReq 列表或者搜索使用结构体
  148. type StockTemplateInventoryExcelReq struct {
  149. ProductID int `json:"productId" alias:"品名" valid:"Required;Min(1)"` // 药品名称id
  150. EnterpriseID int `json:"enterpriseId" alias:"生产企业" valid:"Required;Min(1)"` // 生产企业id
  151. SpecId int `json:"specId" alias:"规格" valid:"Required;Min(1)"` // 规格id
  152. BatchNumber string `json:"batchNumber" alias:"批号" valid:"Required;MinSize(1)"` // 批号
  153. StartDate string `json:"startDate"` // 出/入库开始时间
  154. EndDate string `json:"endDate"` // 出/入库结束时间
  155. Type string `json:"type"` // 类型 excel pdf
  156. }
  157. // TransportRecordWordReq 列表或者搜索使用结构体
  158. type TransportRecordWordReq struct {
  159. Date string `json:"date"` // 出库时间
  160. ReceivingUnit string `json:"receivingUnit"` // 收货单位
  161. ProductID int `json:"productId"` // 药品名称id
  162. Type string `json:"type"` // 类型
  163. DeptID string `json:"deptId" swaggerignore:"true"` // 部门id
  164. }
  165. // StockStatListReq 列表或者搜索使用结构体
  166. type StockStatListReq struct {
  167. dto.Pagination `search:"-"`
  168. ProductID int `json:"productId"` // 药品名称id
  169. EnterpriseID int `json:"enterpriseId"` // 生产企业id
  170. StartDate string `json:"startDate"` // 失效日期开始时间
  171. EndDate string `json:"endDate"` // 失效日期结束时间
  172. BatchNumber string `json:"batchNumber"` // 批号
  173. }
  174. // StockStatReq 列表或者搜索使用结构体
  175. type StockStatReq struct {
  176. ProductID int `json:"productId"` // 药品名称id
  177. SpecID int `json:"specId"` // 规格id
  178. }
  179. type StockUnitListReq struct {
  180. Name string
  181. Type int //1-入库 2-出库 3-库存
  182. }
  183. type StockOperatorListReq struct {
  184. Name string
  185. }
  186. type GetBarCodeInfoReq struct {
  187. Code string `json:"code"`
  188. }