types.go 9.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352
  1. // Code generated by goctl. DO NOT EDIT.
  2. // goctl 1.10.1
  3. package types
  4. type AddMemberReq struct {
  5. ProductCode string `json:"productCode"`
  6. UserId int64 `json:"userId"`
  7. MemberType string `json:"memberType"`
  8. }
  9. type AdminLoginByCapReq struct {
  10. Username string `json:"username"`
  11. Password string `json:"password"`
  12. ManagementKey string `json:"managementKey"`
  13. CapToken string `json:"capToken"`
  14. }
  15. type AdminLoginReq struct {
  16. Username string `json:"username"`
  17. Password string `json:"password"`
  18. ManagementKey string `json:"managementKey"`
  19. CaptchaId string `json:"captchaId,optional"`
  20. CaptchaCode string `json:"captchaCode,optional"`
  21. }
  22. type BindPermsReq struct {
  23. RoleId int64 `json:"roleId"`
  24. PermIds []int64 `json:"permIds"`
  25. }
  26. type BindRolesReq struct {
  27. UserId int64 `json:"userId"`
  28. RoleIds []int64 `json:"roleIds"`
  29. }
  30. type CapEndpointResp struct {
  31. Data string `json:"data"`
  32. }
  33. type CaptchaInfo struct {
  34. Id string `json:"id"`
  35. Base64Image string `json:"base64image"`
  36. }
  37. type CaptchaReq struct {
  38. Width int `json:"width,optional"`
  39. Height int `json:"height,optional"`
  40. }
  41. type ChangePasswordReq struct {
  42. OldPassword string `json:"oldPassword"`
  43. NewPassword string `json:"newPassword"`
  44. }
  45. type CreateDeptReq struct {
  46. ParentId int64 `json:"parentId"`
  47. Name string `json:"name"`
  48. Sort int64 `json:"sort,optional"`
  49. DeptType string `json:"deptType,optional"`
  50. Remark string `json:"remark,optional"`
  51. }
  52. type CreateProductReq struct {
  53. Code string `json:"code"`
  54. Name string `json:"name"`
  55. Remark string `json:"remark,optional"`
  56. AdminDeptId int64 `json:"adminDeptId"`
  57. }
  58. type CreateProductResp struct {
  59. Id int64 `json:"id"`
  60. Code string `json:"code"`
  61. AppKey string `json:"appKey"`
  62. AdminUser string `json:"adminUser"`
  63. CredentialsTicket string `json:"credentialsTicket"`
  64. CredentialsExpiresAt int64 `json:"credentialsExpiresAt"`
  65. }
  66. type CreateRoleReq struct {
  67. ProductCode string `json:"productCode"`
  68. Name string `json:"name"`
  69. Remark string `json:"remark,optional"`
  70. PermsLevel int64 `json:"permsLevel"`
  71. }
  72. type CreateUserReq struct {
  73. Username string `json:"username"`
  74. Password string `json:"password"`
  75. Nickname string `json:"nickname,optional"`
  76. Email string `json:"email,optional"`
  77. Phone string `json:"phone,optional"`
  78. Remark string `json:"remark,optional"`
  79. DeptId int64 `json:"deptId,optional"`
  80. }
  81. type DeleteDeptReq struct {
  82. Id int64 `json:"id"`
  83. }
  84. type DeleteRoleReq struct {
  85. Id int64 `json:"id"`
  86. }
  87. type DeptItem struct {
  88. Id int64 `json:"id"`
  89. ParentId int64 `json:"parentId"`
  90. Name string `json:"name"`
  91. Path string `json:"path"`
  92. Sort int64 `json:"sort"`
  93. DeptType string `json:"deptType"`
  94. Remark string `json:"remark"`
  95. Status int64 `json:"status"`
  96. CreateTime int64 `json:"createTime"`
  97. Children []*DeptItem `json:"children"`
  98. }
  99. type FetchInitialCredentialsReq struct {
  100. Ticket string `json:"ticket"`
  101. }
  102. type FetchInitialCredentialsResp struct {
  103. AppKey string `json:"appKey"`
  104. AppSecret string `json:"appSecret"`
  105. AdminUser string `json:"adminUser"`
  106. AdminPassword string `json:"adminPassword"`
  107. }
  108. type IdResp struct {
  109. Id int64 `json:"id"`
  110. }
  111. type LoginByCapReq struct {
  112. Username string `json:"username"`
  113. Password string `json:"password"`
  114. ProductCode string `json:"productCode"`
  115. CapToken string `json:"capToken"`
  116. }
  117. type LoginReq struct {
  118. Username string `json:"username"`
  119. Password string `json:"password"`
  120. ProductCode string `json:"productCode"`
  121. CaptchaId string `json:"captchaId,optional"`
  122. CaptchaCode string `json:"captchaCode,optional"`
  123. }
  124. type LoginResp struct {
  125. AccessToken string `json:"accessToken"`
  126. RefreshToken string `json:"refreshToken"`
  127. Expires int64 `json:"expires"`
  128. UserInfo UserInfo `json:"userInfo"`
  129. }
  130. type MemberItem struct {
  131. Id int64 `json:"id"`
  132. ProductCode string `json:"productCode"`
  133. UserId int64 `json:"userId"`
  134. Username string `json:"username"`
  135. Nickname string `json:"nickname"`
  136. MemberType string `json:"memberType"`
  137. Status int64 `json:"status"`
  138. CreateTime int64 `json:"createTime"`
  139. }
  140. type MemberListReq struct {
  141. ProductCode string `json:"productCode"`
  142. Page int64 `json:"page,optional"`
  143. PageSize int64 `json:"pageSize,optional"`
  144. }
  145. type PageResp struct {
  146. Total int64 `json:"total"`
  147. List interface{} `json:"list"`
  148. }
  149. type PermItem struct {
  150. Id int64 `json:"id"`
  151. ProductCode string `json:"productCode"`
  152. Name string `json:"name"`
  153. Code string `json:"code"`
  154. Remark string `json:"remark"`
  155. Status int64 `json:"status"`
  156. CreateTime int64 `json:"createTime"`
  157. }
  158. type PermListReq struct {
  159. ProductCode string `json:"productCode"`
  160. Page int64 `json:"page,optional"`
  161. PageSize int64 `json:"pageSize,optional"`
  162. }
  163. type ProductDetailReq struct {
  164. Id int64 `json:"id"`
  165. }
  166. type ProductItem struct {
  167. Id int64 `json:"id"`
  168. Code string `json:"code"`
  169. Name string `json:"name"`
  170. AppKey string `json:"appKey"`
  171. Remark string `json:"remark"`
  172. Status int64 `json:"status"`
  173. CreateTime int64 `json:"createTime"`
  174. }
  175. type ProductListReq struct {
  176. Page int64 `json:"page,optional"`
  177. PageSize int64 `json:"pageSize,optional"`
  178. }
  179. type RefreshTokenReq struct {
  180. Authorization string `header:"Authorization"`
  181. ProductCode string `json:"productCode,optional"`
  182. }
  183. type RemoveMemberReq struct {
  184. Id int64 `json:"id"`
  185. }
  186. type RoleDetailReq struct {
  187. Id int64 `json:"id"`
  188. }
  189. type RoleItem struct {
  190. Id int64 `json:"id"`
  191. ProductCode string `json:"productCode"`
  192. Name string `json:"name"`
  193. Remark string `json:"remark"`
  194. Status int64 `json:"status"`
  195. PermsLevel int64 `json:"permsLevel"`
  196. PermIds []int64 `json:"permIds,omitempty"`
  197. CreateTime int64 `json:"createTime"`
  198. }
  199. type RoleListReq struct {
  200. ProductCode string `json:"productCode"`
  201. Page int64 `json:"page,optional"`
  202. PageSize int64 `json:"pageSize,optional"`
  203. }
  204. type SetPermsReq struct {
  205. UserId int64 `json:"userId"`
  206. Perms []UserPermItem `json:"perms"`
  207. }
  208. type SyncPermItem struct {
  209. Code string `json:"code"`
  210. Name string `json:"name"`
  211. Remark string `json:"remark,optional"`
  212. }
  213. type SyncPermsReq struct {
  214. AppKey string `json:"appKey"`
  215. AppSecret string `json:"appSecret"`
  216. Perms []SyncPermItem `json:"perms"`
  217. }
  218. type SyncPermsResp struct {
  219. Added int64 `json:"added"`
  220. Updated int64 `json:"updated"`
  221. Disabled int64 `json:"disabled"`
  222. }
  223. type UpdateDeptReq struct {
  224. Id int64 `json:"id"`
  225. Name string `json:"name"`
  226. Sort int64 `json:"sort,optional"`
  227. DeptType string `json:"deptType,optional"`
  228. Remark string `json:"remark,optional"`
  229. Status int64 `json:"status,optional"`
  230. }
  231. type UpdateMemberReq struct {
  232. Id int64 `json:"id"`
  233. MemberType *string `json:"memberType,optional"`
  234. Status *int64 `json:"status,optional"`
  235. }
  236. type UpdateProductReq struct {
  237. Id int64 `json:"id"`
  238. Name string `json:"name"`
  239. Remark string `json:"remark,optional"`
  240. Status int64 `json:"status,optional"`
  241. }
  242. type UpdateRoleReq struct {
  243. Id int64 `json:"id"`
  244. Name string `json:"name"`
  245. Remark string `json:"remark,optional"`
  246. PermsLevel int64 `json:"permsLevel"`
  247. Status int64 `json:"status,optional"`
  248. }
  249. type UpdateUserReq struct {
  250. Id int64 `json:"id"`
  251. Nickname *string `json:"nickname,optional"`
  252. Email *string `json:"email,optional"`
  253. Phone *string `json:"phone,optional"`
  254. Remark *string `json:"remark,optional"`
  255. DeptId *int64 `json:"deptId,optional"`
  256. Status int64 `json:"status,optional"`
  257. }
  258. type UpdateUserStatusReq struct {
  259. Id int64 `json:"id"`
  260. Status int64 `json:"status"`
  261. }
  262. type UserDetailReq struct {
  263. Id int64 `json:"id"`
  264. }
  265. type UserInfo struct {
  266. UserId int64 `json:"userId"`
  267. Username string `json:"username"`
  268. Nickname string `json:"nickname"`
  269. Avatar string `json:"avatar"`
  270. Email string `json:"email"`
  271. Phone string `json:"phone"`
  272. IsSuperAdmin int64 `json:"isSuperAdmin"`
  273. MustChangePassword int64 `json:"mustChangePassword"`
  274. MemberType string `json:"memberType"`
  275. Perms []string `json:"perms"`
  276. }
  277. type UserItem struct {
  278. Id int64 `json:"id"`
  279. Username string `json:"username"`
  280. Nickname string `json:"nickname"`
  281. Avatar string `json:"avatar"`
  282. Email string `json:"email"`
  283. Phone string `json:"phone"`
  284. Remark string `json:"remark"`
  285. DeptId int64 `json:"deptId"`
  286. Status int64 `json:"status"`
  287. MemberType string `json:"memberType,omitempty"`
  288. RoleIds []int64 `json:"roleIds,omitempty"`
  289. Perms []string `json:"perms,omitempty"`
  290. CreateTime int64 `json:"createTime"`
  291. }
  292. type UserListReq struct {
  293. ProductCode string `json:"productCode,optional"`
  294. Page int64 `json:"page,optional"`
  295. PageSize int64 `json:"pageSize,optional"`
  296. }
  297. type UserPermItem struct {
  298. PermId int64 `json:"permId"`
  299. Effect string `json:"effect"`
  300. }