year_main.go 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341
  1. package sb
  2. import (
  3. "database/sql/driver"
  4. "time"
  5. )
  6. type YearMain struct {
  7. ID uint `json:"id" gorm:"primary_key"`
  8. CreatedAt time.Time `json:"createdAt"`
  9. UpdatedAt time.Time `json:"updatedAt"`
  10. TableName string `json:"tableName"` // 主表表名
  11. KouStatus uint `json:"kouStatus"`
  12. SbStatus int `json:"sbStatus"`
  13. ComID uint `json:"comId"` //
  14. Period string `json:"period"` // 账期开始日期
  15. Status int8 `json:"status"` // 1 拉取可更改 2已生成报表可更改 3 已修改计算本年累计 不可更改了 3已提交申报不可更改
  16. InitStatus int8 `json:"init_status"`
  17. }
  18. type YearA101010 struct {
  19. ID uint `json:"id" gorm:"primary_key"`
  20. CreatedAt time.Time `json:"createdAt"`
  21. UpdatedAt time.Time `json:"updatedAt"`
  22. YearMainId uint `json:"yearMainId"`
  23. Type string `json:"type"`
  24. Project string `json:"project"`
  25. Amount string `json:"amount"`
  26. }
  27. type YearA100000Fb1 struct {
  28. Amount string `json:"amount"`
  29. Code string `json:"code"`
  30. CreatedAt time.Time `json:"createdAt"`
  31. Id int `json:"id"`
  32. IsCheck int `json:"isCheck"`
  33. Other string `json:"other"`
  34. Project string `json:"project"`
  35. Type string `json:"type"`
  36. UpdatedAt time.Time `json:"updatedAt"`
  37. YearMainId int `json:"yearMainId"`
  38. }
  39. type YearA100000Fb2 struct {
  40. Amount string `json:"amount"`
  41. Code string `json:"code"`
  42. CreatedAt time.Time `json:"createdAt"`
  43. Id int `json:"id"`
  44. IsCheck int `json:"isCheck"`
  45. Other string `json:"other"`
  46. Project string `json:"project"`
  47. Type string `json:"type"`
  48. UpdatedAt time.Time `json:"updatedAt"`
  49. YearMainId int `json:"yearMainId"`
  50. }
  51. type YearA102010 struct {
  52. ID uint `json:"id" gorm:"primary_key"`
  53. CreatedAt time.Time `json:"createdAt"`
  54. UpdatedAt time.Time `json:"updatedAt"`
  55. YearMainId uint `json:"yearMainId"`
  56. Type string `json:"type"`
  57. Project string `json:"project"`
  58. Amount string `json:"amount"`
  59. }
  60. type YearA104000 struct {
  61. ID uint `json:"id" gorm:"primary_key"`
  62. CreatedAt time.Time `json:"createdAt"`
  63. UpdatedAt time.Time `json:"updatedAt"`
  64. YearMainId uint `json:"yearMainId"`
  65. Type string `json:"type"`
  66. Project string `json:"project"`
  67. A1 string `json:"a1"`
  68. A2 string `json:"a2"`
  69. A3 string `json:"a3"`
  70. A4 string `json:"a4"`
  71. A5 string `json:"a5"`
  72. A6 string `json:"a6"`
  73. }
  74. type YearA105050 struct {
  75. ID uint `json:"id" gorm:"primary_key"`
  76. CreatedAt time.Time `json:"createdAt"`
  77. UpdatedAt time.Time `json:"updatedAt"`
  78. YearMainId uint `json:"yearMainId"`
  79. Type string `json:"type"`
  80. Project string `json:"project"`
  81. A1 string `json:"a1"`
  82. A2 string `json:"a2"`
  83. A3 string `json:"a3"`
  84. A4 string `json:"a4"`
  85. A5 string `json:"a5"`
  86. A6 string `json:"a6"`
  87. A7 string `json:"a7"`
  88. }
  89. type YearA105060 struct {
  90. ID uint `json:"id" gorm:"primary_key"`
  91. CreatedAt time.Time `json:"createdAt"`
  92. UpdatedAt time.Time `json:"updatedAt"`
  93. YearMainId uint `json:"yearMainId"`
  94. Type string `json:"type"`
  95. Project string `json:"project"`
  96. A1 string `json:"a1"`
  97. A2 string `json:"a2"`
  98. }
  99. type YearA105080 struct {
  100. ID uint `json:"id" gorm:"primary_key"`
  101. CreatedAt time.Time `json:"createdAt"`
  102. UpdatedAt time.Time `json:"updatedAt"`
  103. YearMainId uint `json:"yearMainId"`
  104. Type string `json:"type"`
  105. Project string `json:"project"`
  106. ProjectItem string `json:"projectItem"`
  107. A1 string `json:"a1"`
  108. A2 string `json:"a2"`
  109. A3 string `json:"a3"`
  110. A4 string `json:"a4"`
  111. A5 string `json:"a5"`
  112. A6 string `json:"a6"`
  113. A7 string `json:"a7"`
  114. A8 string `json:"a8"`
  115. A9 string `json:"a9"`
  116. }
  117. type YearA105000 struct {
  118. ID uint `json:"id" gorm:"primary_key"`
  119. CreatedAt time.Time `json:"createdAt"`
  120. UpdatedAt time.Time `json:"updatedAt"`
  121. YearMainId uint `json:"yearMainId"`
  122. Type string `json:"type"`
  123. Project string `json:"project"`
  124. A1 string `json:"a1"`
  125. A2 string `json:"a2"`
  126. A3 string `json:"a3"`
  127. A4 string `json:"a4"`
  128. }
  129. type YearA100000 struct {
  130. ID uint `json:"id" gorm:"primary_key"`
  131. CreatedAt time.Time `json:"createdAt"`
  132. UpdatedAt time.Time `json:"updatedAt"`
  133. YearMainId uint `json:"yearMainId"`
  134. Type string `json:"type"`
  135. Project string `json:"project"`
  136. ProjectItem string `json:"projectItem"`
  137. Amount string `json:"amount"`
  138. }
  139. type YearA107040 struct {
  140. ID uint `json:"id" gorm:"primary_key"`
  141. CreatedAt time.Time `json:"createdAt"`
  142. UpdatedAt time.Time `json:"updatedAt"`
  143. YearMainId uint `json:"yearMainId"`
  144. Type string `json:"type"`
  145. Project string `json:"project"`
  146. Amount string `json:"amount"`
  147. }
  148. type YearA106000 struct {
  149. ID uint `json:"id" gorm:"primary_key"`
  150. CreatedAt time.Time `json:"createdAt"`
  151. UpdatedAt time.Time `json:"updatedAt"`
  152. YearMainId uint `json:"yearMainId"`
  153. Type string `json:"type"`
  154. Project string `json:"project"`
  155. A1 string `json:"a1"`
  156. A2 string `json:"a2"`
  157. A3 string `json:"a3"`
  158. A4 string `json:"a4"`
  159. A5 string `json:"a5"`
  160. A6 string `json:"a6"`
  161. A7 string `json:"a7"`
  162. A8 string `json:"a8"`
  163. A9 string `json:"a9"`
  164. A10 string `json:"a10"`
  165. A11 string `json:"a11"`
  166. A12 string `json:"a12"`
  167. }
  168. type YearA106000Copy1 struct {
  169. ID uint `json:"id" gorm:"primary_key"`
  170. CreatedAt time.Time `json:"createdAt"`
  171. UpdatedAt time.Time `json:"updatedAt"`
  172. ComId uint `json:"comId"`
  173. Type string `json:"type"`
  174. Project string `json:"project"`
  175. A1 string `json:"a1"`
  176. A2 string `json:"a2"`
  177. A3 string `json:"a3"`
  178. A4 string `json:"a4"`
  179. A5 string `json:"a5"`
  180. A6 string `json:"a6"`
  181. A7 string `json:"a7"`
  182. A8 string `json:"a8"`
  183. A9 string `json:"a9"`
  184. A10 string `json:"a10"`
  185. A11 string `json:"a11"`
  186. A12 string `json:"a12"`
  187. Period string `json:"period"`
  188. }
  189. type YearSelect struct {
  190. ID uint `json:"id" gorm:"primary_key"`
  191. CreatedAt time.Time `json:"createdAt"`
  192. UpdatedAt time.Time `json:"updatedAt"`
  193. YearMainId uint `json:"yearMainId"`
  194. TableName string `json:"tableName"` // 主表表名
  195. Type string `json:"type"`
  196. Project string `json:"project"`
  197. Status int `json:"status"`
  198. Sort int `json:"sort"`
  199. Selects int `json:"selects"`
  200. }
  201. type YearA000000Gd struct {
  202. ID uint `json:"id" gorm:"primary_key"`
  203. CreatedAt time.Time `json:"createdAt"`
  204. UpdatedAt time.Time `json:"updatedAt"`
  205. YearMainId uint `json:"yearMainId"`
  206. GdName string `json:"gdName"`
  207. GdType string `json:"gdType"`
  208. GdNo string `json:"gdNo"`
  209. Bl float64 `json:"bl"`
  210. Amount float64 `json:"amount"`
  211. Country string `json:"country"`
  212. }
  213. type YearA000000Type string
  214. func (ct *YearA000000Type) Scan(value interface{}) error {
  215. *ct = YearA000000Type(value.([]byte))
  216. return nil
  217. }
  218. func (ct YearA000000Type) Value() (driver.Value, error) {
  219. return string(ct), nil
  220. }
  221. const (
  222. Y YearA000000Type = "Y"
  223. N YearA000000Type = "N"
  224. )
  225. type YearA000000 struct {
  226. ID uint `json:"id" gorm:"primary_key"`
  227. CreatedAt time.Time `json:"createdAt"`
  228. UpdatedAt time.Time `json:"updatedAt"`
  229. YearMainId uint `json:"yearMainId"`
  230. A101 string `json:"a101"`
  231. A102 float64 `json:"a102"`
  232. A103 float64 `json:"a103"`
  233. A104 int `json:"a104"`
  234. A105 string `json:"a105"`
  235. A106 string `json:"a106"`
  236. A107 string `json:"a107"`
  237. A108 string `json:"a108"`
  238. A109 string `json:"a109"`
  239. A110 string `json:"a110"`
  240. A201 string `json:"a201"`
  241. A202 string `json:"a202"`
  242. A2031 string `json:"a2031"`
  243. A20321 string `json:"a20321"`
  244. A20322 string `json:"a20322"`
  245. A204 string `json:"a204"`
  246. A205 string `json:"a205"`
  247. A206 string `json:"a206"`
  248. A207 string `json:"a207"`
  249. A208 string `json:"a208"`
  250. A209 string `json:"a209"`
  251. A21001 string `json:"a21001"`
  252. A21002 string `json:"a21002"`
  253. A21003 string `json:"a21003"`
  254. A21004 string `json:"a21004"`
  255. A210num01 string `json:"a210num01"`
  256. A210num02 string `json:"a210num02"`
  257. A21101 string `json:"a21101"`
  258. A21102 string `json:"a21102"`
  259. A21103 string `json:"a21103"`
  260. A21104 string `json:"a21104"`
  261. A212 string `json:"a212"`
  262. A213 string `json:"a213"`
  263. A214 string `json:"a214"`
  264. A215 string `json:"a215"`
  265. A216 string `json:"a216"`
  266. A217 string `json:"a217"`
  267. A218 string `json:"a218"`
  268. A219 string `json:"a219"`
  269. A220 string `json:"a220"`
  270. A221 string `json:"a221"`
  271. A222 string `json:"a222"`
  272. A223 string `json:"a223"`
  273. A224 string `json:"a224"`
  274. }
  275. type YearZcfz struct {
  276. ID uint `json:"id" gorm:"primary_key"`
  277. CreatedAt time.Time `json:"createdAt"`
  278. UpdatedAt time.Time `json:"updatedAt"`
  279. YearMainID uint `json:"yearMainID"` //
  280. Type float64 `json:"type"` // 对应资产负债表行次字段 不标准
  281. Zcxmmc string `json:"zcxmmc"` // 流动资产
  282. QmyeZc float64 `json:"qmyeZc"` // 期末余额
  283. NcyeZc float64 `json:"ncyeZc"` // 年初余额
  284. Qyxmmc string `json:"qyxmmc"` // 流动负债
  285. QmyeQy float64 `json:"qmyeQy"` // 期末余额
  286. NcyeQy float64 `json:"ncyeQy"` // 年初余额
  287. }
  288. type YearLrb struct {
  289. ID uint `json:"id" gorm:"primary_key"`
  290. CreatedAt time.Time `json:"createdAt"`
  291. UpdatedAt time.Time `json:"updatedAt"`
  292. YearMainID uint `json:"yearMainID"`
  293. Project string `json:"project"`
  294. Type float64 `json:"type"`
  295. YearTotal float64 `json:"yearTotal"`
  296. LastYearTotal float64 `json:"lastYearTotal"`
  297. }
  298. type YearXjllb struct {
  299. ID uint `json:"id" gorm:"primary_key"`
  300. CreatedAt time.Time `json:"createdAt"`
  301. UpdatedAt time.Time `json:"updatedAt"`
  302. YearMainID uint `json:"yearMainID"`
  303. Project string `json:"project"`
  304. Type float64 `json:"type"`
  305. YearTotal float64 `json:"yearTotal"`
  306. LastYearTotal float64 `json:"lastYearTotal"`
  307. }