You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

913 lines
21 KiB

5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
  1. basePath: /
  2. definitions:
  3. api.AddMenuAuthorityInfo:
  4. properties:
  5. authorityId:
  6. type: string
  7. menus:
  8. items:
  9. $ref: '#/definitions/sysModel.SysBaseMenu'
  10. type: array
  11. type: object
  12. api.AuthorityIdInfo:
  13. properties:
  14. authorityId:
  15. type: string
  16. type: object
  17. api.ChangePasswordStutrc:
  18. properties:
  19. newPassword:
  20. type: string
  21. password:
  22. type: string
  23. username:
  24. type: string
  25. type: object
  26. api.CreateApiParams:
  27. properties:
  28. description:
  29. type: string
  30. path:
  31. type: string
  32. type: object
  33. api.CreateAuthorityParams:
  34. properties:
  35. authorityId:
  36. type: string
  37. authorityName:
  38. type: string
  39. type: object
  40. api.DeleteAuthorityPatams:
  41. properties:
  42. authorityId:
  43. type: integer
  44. type: object
  45. api.GetById:
  46. properties:
  47. id:
  48. type: number
  49. type: object
  50. api.IdInfo:
  51. properties:
  52. id:
  53. type: number
  54. type: object
  55. api.RegistAndLoginStuct:
  56. properties:
  57. password:
  58. type: string
  59. username:
  60. type: string
  61. type: object
  62. api.SetUserAuth:
  63. properties:
  64. authorityId:
  65. type: string
  66. uuid:
  67. type: string
  68. type: object
  69. dbModel.ExaFileUploadAndDownload:
  70. properties:
  71. key:
  72. type: string
  73. name:
  74. type: string
  75. tag:
  76. type: string
  77. url:
  78. type: string
  79. type: object
  80. modelInterface.PageInfo:
  81. properties:
  82. page:
  83. type: integer
  84. pageSize:
  85. type: integer
  86. type: object
  87. sysModel.SysApi:
  88. properties:
  89. description:
  90. type: string
  91. group:
  92. type: string
  93. path:
  94. type: string
  95. type: object
  96. sysModel.SysAuthority:
  97. properties:
  98. authorityId:
  99. type: string
  100. authorityName:
  101. type: string
  102. children:
  103. items:
  104. $ref: '#/definitions/sysModel.SysAuthority'
  105. type: array
  106. dataAuthorityId:
  107. items:
  108. $ref: '#/definitions/sysModel.SysAuthority'
  109. type: array
  110. parentId:
  111. type: string
  112. type: object
  113. sysModel.SysBaseMenu:
  114. properties:
  115. children:
  116. items:
  117. $ref: '#/definitions/sysModel.SysBaseMenu'
  118. type: array
  119. component:
  120. type: string
  121. hidden:
  122. type: boolean
  123. icon:
  124. type: string
  125. name:
  126. type: string
  127. nickName:
  128. type: string
  129. parentId:
  130. type: string
  131. path:
  132. type: string
  133. sort:
  134. type: string
  135. title:
  136. type: string
  137. type: object
  138. sysModel.SysUser:
  139. properties:
  140. authority:
  141. $ref: '#/definitions/sysModel.SysAuthority'
  142. type: object
  143. authorityId:
  144. type: string
  145. headerImg:
  146. type: string
  147. nickName:
  148. type: string
  149. userName:
  150. type: string
  151. uuid:
  152. type: string
  153. type: object
  154. sysModel.SysWorkflow:
  155. properties:
  156. workflowDescription:
  157. description: 工作流描述
  158. type: string
  159. workflowName:
  160. description: 工作流英文id
  161. type: string
  162. workflowNickName:
  163. description: 工作流名称
  164. type: string
  165. workflowStep:
  166. description: 工作流步骤
  167. items:
  168. $ref: '#/definitions/sysModel.SysWorkflowStepInfo'
  169. type: array
  170. type: object
  171. sysModel.SysWorkflowStepInfo:
  172. properties:
  173. isEnd:
  174. description: 是否是完结流节点
  175. type: boolean
  176. isStrat:
  177. description: 是否是开始流节点
  178. type: boolean
  179. stepAuthorityID:
  180. description: 操作者级别id
  181. type: string
  182. stepName:
  183. description: 工作流名称
  184. type: string
  185. stepNo:
  186. description: 步骤id (第几步)
  187. type: number
  188. workflowID:
  189. description: 所属工作流ID
  190. type: integer
  191. type: object
  192. info:
  193. contact: {}
  194. description: This is a sample Server pets
  195. license: {}
  196. title: Swagger Example API
  197. version: 0.0.1
  198. paths:
  199. /api/createApi:
  200. post:
  201. consumes:
  202. - application/json
  203. parameters:
  204. - description: 创建api
  205. in: body
  206. name: data
  207. required: true
  208. schema:
  209. $ref: '#/definitions/api.CreateApiParams'
  210. type: object
  211. produces:
  212. - application/json
  213. responses:
  214. "200":
  215. description: '{"success":true,"data":{},"msg":"获取成功"}'
  216. schema:
  217. type: string
  218. security:
  219. - ApiKeyAuth: []
  220. summary: 创建基础api
  221. tags:
  222. - SysApi
  223. /api/deleteApi:
  224. post:
  225. consumes:
  226. - application/json
  227. parameters:
  228. - description: 删除api
  229. in: body
  230. name: data
  231. required: true
  232. schema:
  233. $ref: '#/definitions/sysModel.SysApi'
  234. type: object
  235. produces:
  236. - application/json
  237. responses:
  238. "200":
  239. description: '{"success":true,"data":{},"msg":"获取成功"}'
  240. schema:
  241. type: string
  242. security:
  243. - ApiKeyAuth: []
  244. summary: 删除指定api
  245. tags:
  246. - SysApi
  247. /api/getAllApis:
  248. post:
  249. consumes:
  250. - application/json
  251. produces:
  252. - application/json
  253. responses:
  254. "200":
  255. description: '{"success":true,"data":{},"msg":"获取成功"}'
  256. schema:
  257. type: string
  258. security:
  259. - ApiKeyAuth: []
  260. summary: 获取所有的Api 不分页
  261. tags:
  262. - SysApi
  263. /api/getApiById:
  264. post:
  265. consumes:
  266. - application/json
  267. parameters:
  268. - description: 分页获取用户列表
  269. in: body
  270. name: data
  271. required: true
  272. schema:
  273. $ref: '#/definitions/modelInterface.PageInfo'
  274. type: object
  275. produces:
  276. - application/json
  277. responses:
  278. "200":
  279. description: '{"success":true,"data":{},"msg":"获取成功"}'
  280. schema:
  281. type: string
  282. security:
  283. - ApiKeyAuth: []
  284. summary: 根据id获取api
  285. tags:
  286. - SysApi
  287. /api/getApiList:
  288. post:
  289. consumes:
  290. - application/json
  291. parameters:
  292. - description: 分页获取API列表
  293. in: body
  294. name: data
  295. required: true
  296. schema:
  297. $ref: '#/definitions/modelInterface.PageInfo'
  298. type: object
  299. produces:
  300. - application/json
  301. responses:
  302. "200":
  303. description: '{"success":true,"data":{},"msg":"获取成功"}'
  304. schema:
  305. type: string
  306. security:
  307. - ApiKeyAuth: []
  308. summary: 分页获取API列表
  309. tags:
  310. - SysApi
  311. /api/updataApi:
  312. post:
  313. consumes:
  314. - application/json
  315. parameters:
  316. - description: 创建api
  317. in: body
  318. name: data
  319. required: true
  320. schema:
  321. $ref: '#/definitions/api.CreateApiParams'
  322. type: object
  323. produces:
  324. - application/json
  325. responses:
  326. "200":
  327. description: '{"success":true,"data":{},"msg":"获取成功"}'
  328. schema:
  329. type: string
  330. security:
  331. - ApiKeyAuth: []
  332. summary: 创建基础api
  333. tags:
  334. - SysApi
  335. /authority/createAuthority:
  336. post:
  337. consumes:
  338. - application/json
  339. parameters:
  340. - description: 创建角色
  341. in: body
  342. name: data
  343. required: true
  344. schema:
  345. $ref: '#/definitions/api.CreateAuthorityParams'
  346. type: object
  347. produces:
  348. - application/json
  349. responses:
  350. "200":
  351. description: '{"success":true,"data":{},"msg":"获取成功"}'
  352. schema:
  353. type: string
  354. security:
  355. - ApiKeyAuth: []
  356. summary: 创建角色
  357. tags:
  358. - authority
  359. /authority/deleteAuthority:
  360. post:
  361. consumes:
  362. - application/json
  363. parameters:
  364. - description: 删除角色
  365. in: body
  366. name: data
  367. required: true
  368. schema:
  369. $ref: '#/definitions/api.DeleteAuthorityPatams'
  370. type: object
  371. produces:
  372. - application/json
  373. responses:
  374. "200":
  375. description: '{"success":true,"data":{},"msg":"获取成功"}'
  376. schema:
  377. type: string
  378. security:
  379. - ApiKeyAuth: []
  380. summary: 删除角色
  381. tags:
  382. - authority
  383. /authority/getAuthorityList:
  384. post:
  385. consumes:
  386. - application/json
  387. parameters:
  388. - description: 分页获取用户列表
  389. in: body
  390. name: data
  391. required: true
  392. schema:
  393. $ref: '#/definitions/modelInterface.PageInfo'
  394. type: object
  395. produces:
  396. - application/json
  397. responses:
  398. "200":
  399. description: '{"success":true,"data":{},"msg":"获取成功"}'
  400. schema:
  401. type: string
  402. security:
  403. - ApiKeyAuth: []
  404. summary: 分页获取角色列表
  405. tags:
  406. - authority
  407. /authority/setDataAuthority:
  408. post:
  409. consumes:
  410. - application/json
  411. parameters:
  412. - description: 设置角色资源权限
  413. in: body
  414. name: data
  415. required: true
  416. schema:
  417. $ref: '#/definitions/sysModel.SysAuthority'
  418. type: object
  419. produces:
  420. - application/json
  421. responses:
  422. "200":
  423. description: '{"success":true,"data":{},"msg":"设置成功"}'
  424. schema:
  425. type: string
  426. security:
  427. - ApiKeyAuth: []
  428. summary: 设置角色资源权限
  429. tags:
  430. - authority
  431. /base/login:
  432. post:
  433. parameters:
  434. - description: 用户登录接口
  435. in: body
  436. name: data
  437. required: true
  438. schema:
  439. $ref: '#/definitions/api.RegistAndLoginStuct'
  440. type: object
  441. produces:
  442. - application/json
  443. responses:
  444. "200":
  445. description: '{"success":true,"data":{},"msg":"登陆成功"}'
  446. schema:
  447. type: string
  448. summary: 用户登录
  449. tags:
  450. - Base
  451. /base/regist:
  452. post:
  453. parameters:
  454. - description: 用户注册接口
  455. in: body
  456. name: data
  457. required: true
  458. schema:
  459. $ref: '#/definitions/sysModel.SysUser'
  460. type: object
  461. produces:
  462. - application/json
  463. responses:
  464. "200":
  465. description: '{"success":true,"data":{},"msg":"注册成功"}'
  466. schema:
  467. type: string
  468. summary: 用户注册账号
  469. tags:
  470. - Base
  471. /casbin/casbinPUpdata:
  472. post:
  473. consumes:
  474. - application/json
  475. parameters:
  476. - description: 更改角色api权限
  477. in: body
  478. name: data
  479. required: true
  480. schema:
  481. $ref: '#/definitions/api.CreateAuthorityParams'
  482. type: object
  483. produces:
  484. - application/json
  485. responses:
  486. "200":
  487. description: '{"success":true,"data":{},"msg":"获取成功"}'
  488. schema:
  489. type: string
  490. security:
  491. - ApiKeyAuth: []
  492. summary: 更改角色api权限
  493. tags:
  494. - casbin
  495. /casbin/getPolicyPathByAuthorityId:
  496. post:
  497. consumes:
  498. - application/json
  499. parameters:
  500. - description: 获取权限列表
  501. in: body
  502. name: data
  503. required: true
  504. schema:
  505. $ref: '#/definitions/api.CreateAuthorityParams'
  506. type: object
  507. produces:
  508. - application/json
  509. responses:
  510. "200":
  511. description: '{"success":true,"data":{},"msg":"获取成功"}'
  512. schema:
  513. type: string
  514. security:
  515. - ApiKeyAuth: []
  516. summary: 获取权限列表
  517. tags:
  518. - casbin
  519. /fileUploadAndDownload/deleteFile:
  520. post:
  521. parameters:
  522. - description: 传入文件里面id即可
  523. in: body
  524. name: data
  525. required: true
  526. schema:
  527. $ref: '#/definitions/dbModel.ExaFileUploadAndDownload'
  528. type: object
  529. produces:
  530. - application/json
  531. responses:
  532. "200":
  533. description: '{"success":true,"data":{},"msg":"返回成功"}'
  534. schema:
  535. type: string
  536. security:
  537. - ApiKeyAuth: []
  538. summary: 删除文件
  539. tags:
  540. - ExaFileUploadAndDownload
  541. /fileUploadAndDownload/getFileList:
  542. post:
  543. consumes:
  544. - application/json
  545. parameters:
  546. - description: 分页获取文件户列表
  547. in: body
  548. name: data
  549. required: true
  550. schema:
  551. $ref: '#/definitions/modelInterface.PageInfo'
  552. type: object
  553. produces:
  554. - application/json
  555. responses:
  556. "200":
  557. description: '{"success":true,"data":{},"msg":"获取成功"}'
  558. schema:
  559. type: string
  560. security:
  561. - ApiKeyAuth: []
  562. summary: 分页文件列表
  563. tags:
  564. - ExaFileUploadAndDownload
  565. /fileUploadAndDownload/upload:
  566. post:
  567. consumes:
  568. - multipart/form-data
  569. parameters:
  570. - description: 上传文件示例
  571. in: formData
  572. name: file
  573. required: true
  574. type: file
  575. produces:
  576. - application/json
  577. responses:
  578. "200":
  579. description: '{"success":true,"data":{},"msg":"上传成功"}'
  580. schema:
  581. type: string
  582. security:
  583. - ApiKeyAuth: []
  584. summary: 上传文件示例
  585. tags:
  586. - ExaFileUploadAndDownload
  587. /jwt/jsonInBlacklist:
  588. post:
  589. consumes:
  590. - application/json
  591. produces:
  592. - application/json
  593. responses:
  594. "200":
  595. description: '{"success":true,"data":{},"msg":"拉黑成功"}'
  596. schema:
  597. type: string
  598. security:
  599. - ApiKeyAuth: []
  600. summary: jwt加入黑名单
  601. tags:
  602. - jwt
  603. /menu/addBaseMenu:
  604. post:
  605. consumes:
  606. - application/json
  607. parameters:
  608. - description: 新增菜单
  609. in: body
  610. name: data
  611. required: true
  612. schema:
  613. $ref: '#/definitions/sysModel.SysBaseMenu'
  614. type: object
  615. produces:
  616. - application/json
  617. responses:
  618. "200":
  619. description: '{"success":true,"data":{},"msg":"获取成功"}'
  620. schema:
  621. type: string
  622. security:
  623. - ApiKeyAuth: []
  624. summary: 新增菜单
  625. tags:
  626. - menu
  627. /menu/addMenuAuthority:
  628. post:
  629. consumes:
  630. - application/json
  631. parameters:
  632. - description: 增加menu和角色关联关系
  633. in: body
  634. name: data
  635. required: true
  636. schema:
  637. $ref: '#/definitions/api.AuthorityIdInfo'
  638. type: object
  639. produces:
  640. - application/json
  641. responses:
  642. "200":
  643. description: '{"success":true,"data":{},"msg":"获取成功"}'
  644. schema:
  645. type: string
  646. security:
  647. - ApiKeyAuth: []
  648. summary: 获取指定角色menu
  649. tags:
  650. - authorityAndMenu
  651. /menu/deleteBaseMenu:
  652. post:
  653. consumes:
  654. - application/json
  655. parameters:
  656. - description: 删除菜单
  657. in: body
  658. name: data
  659. required: true
  660. schema:
  661. $ref: '#/definitions/api.IdInfo'
  662. type: object
  663. produces:
  664. - application/json
  665. responses:
  666. "200":
  667. description: '{"success":true,"data":{},"msg":"获取成功"}'
  668. schema:
  669. type: string
  670. security:
  671. - ApiKeyAuth: []
  672. summary: 删除菜单
  673. tags:
  674. - menu
  675. /menu/getBaseMenuById:
  676. post:
  677. consumes:
  678. - application/json
  679. parameters:
  680. - description: 根据id获取菜单
  681. in: body
  682. name: data
  683. required: true
  684. schema:
  685. $ref: '#/definitions/api.GetById'
  686. type: object
  687. produces:
  688. - application/json
  689. responses:
  690. "200":
  691. description: '{"success":true,"data":{},"msg":"获取成功"}'
  692. schema:
  693. type: string
  694. security:
  695. - ApiKeyAuth: []
  696. summary: 根据id获取菜单
  697. tags:
  698. - menu
  699. /menu/getBaseMenuTree:
  700. post:
  701. parameters:
  702. - description: 可以什么都不填
  703. in: body
  704. name: data
  705. required: true
  706. schema:
  707. $ref: '#/definitions/api.RegistAndLoginStuct'
  708. type: object
  709. produces:
  710. - application/json
  711. responses:
  712. "200":
  713. description: '{"success":true,"data":{},"msg":"返回成功"}'
  714. schema:
  715. type: string
  716. security:
  717. - ApiKeyAuth: []
  718. summary: 获取用户动态路由
  719. tags:
  720. - authorityAndMenu
  721. /menu/getMenu:
  722. post:
  723. parameters:
  724. - description: 可以什么都不填
  725. in: body
  726. name: data
  727. required: true
  728. schema:
  729. $ref: '#/definitions/api.RegistAndLoginStuct'
  730. type: object
  731. produces:
  732. - application/json
  733. responses:
  734. "200":
  735. description: '{"success":true,"data":{},"msg":"返回成功"}'
  736. schema:
  737. type: string
  738. security:
  739. - ApiKeyAuth: []
  740. summary: 获取用户动态路由
  741. tags:
  742. - authorityAndMenu
  743. /menu/getMenuList:
  744. post:
  745. consumes:
  746. - application/json
  747. parameters:
  748. - description: 分页获取基础menu列表
  749. in: body
  750. name: data
  751. required: true
  752. schema:
  753. $ref: '#/definitions/modelInterface.PageInfo'
  754. type: object
  755. produces:
  756. - application/json
  757. responses:
  758. "200":
  759. description: '{"success":true,"data":{},"msg":"获取成功"}'
  760. schema:
  761. type: string
  762. security:
  763. - ApiKeyAuth: []
  764. summary: 分页获取基础menu列表
  765. tags:
  766. - menu
  767. /menu/updataBaseMen:
  768. post:
  769. consumes:
  770. - application/json
  771. parameters:
  772. - description: 更新菜单
  773. in: body
  774. name: data
  775. required: true
  776. schema:
  777. $ref: '#/definitions/sysModel.SysBaseMenu'
  778. type: object
  779. produces:
  780. - application/json
  781. responses:
  782. "200":
  783. description: '{"success":true,"data":{},"msg":"获取成功"}'
  784. schema:
  785. type: string
  786. security:
  787. - ApiKeyAuth: []
  788. summary: 更新菜单
  789. tags:
  790. - menu
  791. /user/changePassword:
  792. post:
  793. parameters:
  794. - description: 用户修改密码
  795. in: body
  796. name: data
  797. required: true
  798. schema:
  799. $ref: '#/definitions/api.ChangePasswordStutrc'
  800. type: object
  801. produces:
  802. - application/json
  803. responses:
  804. "200":
  805. description: '{"success":true,"data":{},"msg":"修改成功"}'
  806. schema:
  807. type: string
  808. security:
  809. - ApiKeyAuth: []
  810. summary: 用户修改密码
  811. tags:
  812. - SysUser
  813. /user/getUserList:
  814. post:
  815. consumes:
  816. - application/json
  817. parameters:
  818. - description: 分页获取用户列表
  819. in: body
  820. name: data
  821. required: true
  822. schema:
  823. $ref: '#/definitions/modelInterface.PageInfo'
  824. type: object
  825. produces:
  826. - application/json
  827. responses:
  828. "200":
  829. description: '{"success":true,"data":{},"msg":"获取成功"}'
  830. schema:
  831. type: string
  832. security:
  833. - ApiKeyAuth: []
  834. summary: 分页获取用户列表
  835. tags:
  836. - SysUser
  837. /user/setUserAuthority:
  838. post:
  839. consumes:
  840. - application/json
  841. parameters:
  842. - description: 设置用户权限
  843. in: body
  844. name: data
  845. required: true
  846. schema:
  847. $ref: '#/definitions/api.SetUserAuth'
  848. type: object
  849. produces:
  850. - application/json
  851. responses:
  852. "200":
  853. description: '{"success":true,"data":{},"msg":"修改成功"}'
  854. schema:
  855. type: string
  856. security:
  857. - ApiKeyAuth: []
  858. summary: 设置用户权限
  859. tags:
  860. - SysUser
  861. /user/uploadHeaderImg:
  862. post:
  863. consumes:
  864. - multipart/form-data
  865. parameters:
  866. - description: 用户上传头像
  867. in: formData
  868. name: headerImg
  869. required: true
  870. type: file
  871. - description: 用户上传头像
  872. in: formData
  873. name: username
  874. required: true
  875. type: string
  876. produces:
  877. - application/json
  878. responses:
  879. "200":
  880. description: '{"success":true,"data":{},"msg":"上传成功"}'
  881. schema:
  882. type: string
  883. security:
  884. - ApiKeyAuth: []
  885. summary: 用户上传头像
  886. tags:
  887. - SysUser
  888. /workflow/createWorkFlow:
  889. post:
  890. parameters:
  891. - description: 注册工作流接口
  892. in: body
  893. name: data
  894. required: true
  895. schema:
  896. $ref: '#/definitions/sysModel.SysWorkflow'
  897. type: object
  898. produces:
  899. - application/json
  900. responses:
  901. "200":
  902. description: '{"success":true,"data":{},"msg":"注册成功"}'
  903. schema:
  904. type: string
  905. summary: 注册工作流
  906. tags:
  907. - workflow
  908. securityDefinitions:
  909. ApiKeyAuth:
  910. in: header
  911. name: x-token
  912. type: apiKey
  913. swagger: "2.0"