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.

1357 lines
42 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
  1. {
  2. "swagger": "2.0",
  3. "info": {
  4. "description": "This is a sample Server pets",
  5. "title": "Swagger Example API",
  6. "contact": {},
  7. "license": {},
  8. "version": "0.0.1"
  9. },
  10. "basePath": "/",
  11. "paths": {
  12. "/api/createApi": {
  13. "post": {
  14. "security": [
  15. {
  16. "ApiKeyAuth": []
  17. }
  18. ],
  19. "consumes": [
  20. "application/json"
  21. ],
  22. "produces": [
  23. "application/json"
  24. ],
  25. "tags": [
  26. "Api"
  27. ],
  28. "summary": "创建基础api",
  29. "parameters": [
  30. {
  31. "description": "创建api",
  32. "name": "data",
  33. "in": "body",
  34. "required": true,
  35. "schema": {
  36. "type": "object",
  37. "$ref": "#/definitions/api.CreateApiParams"
  38. }
  39. }
  40. ],
  41. "responses": {
  42. "200": {
  43. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  44. "schema": {
  45. "type": "string"
  46. }
  47. }
  48. }
  49. }
  50. },
  51. "/api/deleteApi": {
  52. "post": {
  53. "security": [
  54. {
  55. "ApiKeyAuth": []
  56. }
  57. ],
  58. "consumes": [
  59. "application/json"
  60. ],
  61. "produces": [
  62. "application/json"
  63. ],
  64. "tags": [
  65. "Api"
  66. ],
  67. "summary": "删除指定api",
  68. "parameters": [
  69. {
  70. "description": "删除api",
  71. "name": "data",
  72. "in": "body",
  73. "required": true,
  74. "schema": {
  75. "type": "object",
  76. "$ref": "#/definitions/dbModel.Api"
  77. }
  78. }
  79. ],
  80. "responses": {
  81. "200": {
  82. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  83. "schema": {
  84. "type": "string"
  85. }
  86. }
  87. }
  88. }
  89. },
  90. "/api/getAllApis": {
  91. "post": {
  92. "security": [
  93. {
  94. "ApiKeyAuth": []
  95. }
  96. ],
  97. "consumes": [
  98. "application/json"
  99. ],
  100. "produces": [
  101. "application/json"
  102. ],
  103. "tags": [
  104. "Api"
  105. ],
  106. "summary": "获取所有的Api 不分页",
  107. "responses": {
  108. "200": {
  109. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  110. "schema": {
  111. "type": "string"
  112. }
  113. }
  114. }
  115. }
  116. },
  117. "/api/getApiById": {
  118. "post": {
  119. "security": [
  120. {
  121. "ApiKeyAuth": []
  122. }
  123. ],
  124. "consumes": [
  125. "application/json"
  126. ],
  127. "produces": [
  128. "application/json"
  129. ],
  130. "tags": [
  131. "Api"
  132. ],
  133. "summary": "根据id获取api",
  134. "parameters": [
  135. {
  136. "description": "分页获取用户列表",
  137. "name": "data",
  138. "in": "body",
  139. "required": true,
  140. "schema": {
  141. "type": "object",
  142. "$ref": "#/definitions/modelInterface.PageInfo"
  143. }
  144. }
  145. ],
  146. "responses": {
  147. "200": {
  148. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  149. "schema": {
  150. "type": "string"
  151. }
  152. }
  153. }
  154. }
  155. },
  156. "/api/getApiList": {
  157. "post": {
  158. "security": [
  159. {
  160. "ApiKeyAuth": []
  161. }
  162. ],
  163. "consumes": [
  164. "application/json"
  165. ],
  166. "produces": [
  167. "application/json"
  168. ],
  169. "tags": [
  170. "Api"
  171. ],
  172. "summary": "分页获取API列表",
  173. "parameters": [
  174. {
  175. "description": "分页获取API列表",
  176. "name": "data",
  177. "in": "body",
  178. "required": true,
  179. "schema": {
  180. "type": "object",
  181. "$ref": "#/definitions/modelInterface.PageInfo"
  182. }
  183. }
  184. ],
  185. "responses": {
  186. "200": {
  187. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  188. "schema": {
  189. "type": "string"
  190. }
  191. }
  192. }
  193. }
  194. },
  195. "/api/setAuthAndApi": {
  196. "post": {
  197. "security": [
  198. {
  199. "ApiKeyAuth": []
  200. }
  201. ],
  202. "consumes": [
  203. "application/json"
  204. ],
  205. "produces": [
  206. "application/json"
  207. ],
  208. "tags": [
  209. "Api"
  210. ],
  211. "summary": "创建api和角色关系",
  212. "parameters": [
  213. {
  214. "description": "创建api和角色关系",
  215. "name": "data",
  216. "in": "body",
  217. "required": true,
  218. "schema": {
  219. "type": "object",
  220. "$ref": "#/definitions/api.AuthAndPathIn"
  221. }
  222. }
  223. ],
  224. "responses": {
  225. "200": {
  226. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  227. "schema": {
  228. "type": "string"
  229. }
  230. }
  231. }
  232. }
  233. },
  234. "/api/updataApi": {
  235. "post": {
  236. "security": [
  237. {
  238. "ApiKeyAuth": []
  239. }
  240. ],
  241. "consumes": [
  242. "application/json"
  243. ],
  244. "produces": [
  245. "application/json"
  246. ],
  247. "tags": [
  248. "Api"
  249. ],
  250. "summary": "创建基础api",
  251. "parameters": [
  252. {
  253. "description": "创建api",
  254. "name": "data",
  255. "in": "body",
  256. "required": true,
  257. "schema": {
  258. "type": "object",
  259. "$ref": "#/definitions/api.CreateApiParams"
  260. }
  261. }
  262. ],
  263. "responses": {
  264. "200": {
  265. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  266. "schema": {
  267. "type": "string"
  268. }
  269. }
  270. }
  271. }
  272. },
  273. "/authority/createAuthority": {
  274. "post": {
  275. "security": [
  276. {
  277. "ApiKeyAuth": []
  278. }
  279. ],
  280. "consumes": [
  281. "application/json"
  282. ],
  283. "produces": [
  284. "application/json"
  285. ],
  286. "tags": [
  287. "authority"
  288. ],
  289. "summary": "创建角色",
  290. "parameters": [
  291. {
  292. "description": "创建角色",
  293. "name": "data",
  294. "in": "body",
  295. "required": true,
  296. "schema": {
  297. "type": "object",
  298. "$ref": "#/definitions/api.CreateAuthorityPatams"
  299. }
  300. }
  301. ],
  302. "responses": {
  303. "200": {
  304. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  305. "schema": {
  306. "type": "string"
  307. }
  308. }
  309. }
  310. }
  311. },
  312. "/authority/deleteAuthority": {
  313. "post": {
  314. "security": [
  315. {
  316. "ApiKeyAuth": []
  317. }
  318. ],
  319. "consumes": [
  320. "application/json"
  321. ],
  322. "produces": [
  323. "application/json"
  324. ],
  325. "tags": [
  326. "authority"
  327. ],
  328. "summary": "删除角色",
  329. "parameters": [
  330. {
  331. "description": "删除角色",
  332. "name": "data",
  333. "in": "body",
  334. "required": true,
  335. "schema": {
  336. "type": "object",
  337. "$ref": "#/definitions/api.DeleteAuthorityPatams"
  338. }
  339. }
  340. ],
  341. "responses": {
  342. "200": {
  343. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  344. "schema": {
  345. "type": "string"
  346. }
  347. }
  348. }
  349. }
  350. },
  351. "/authority/getAuthAndApi": {
  352. "post": {
  353. "security": [
  354. {
  355. "ApiKeyAuth": []
  356. }
  357. ],
  358. "consumes": [
  359. "application/json"
  360. ],
  361. "produces": [
  362. "application/json"
  363. ],
  364. "tags": [
  365. "authority"
  366. ],
  367. "summary": "获取本角色所有有权限的apiId",
  368. "parameters": [
  369. {
  370. "description": "获取本角色所有有权限的apiId",
  371. "name": "data",
  372. "in": "body",
  373. "required": true,
  374. "schema": {
  375. "type": "object",
  376. "$ref": "#/definitions/api.GetAuthorityId"
  377. }
  378. }
  379. ],
  380. "responses": {
  381. "200": {
  382. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  383. "schema": {
  384. "type": "string"
  385. }
  386. }
  387. }
  388. }
  389. },
  390. "/authority/getAuthorityList": {
  391. "post": {
  392. "security": [
  393. {
  394. "ApiKeyAuth": []
  395. }
  396. ],
  397. "consumes": [
  398. "application/json"
  399. ],
  400. "produces": [
  401. "application/json"
  402. ],
  403. "tags": [
  404. "authority"
  405. ],
  406. "summary": "分页获取角色列表",
  407. "parameters": [
  408. {
  409. "description": "分页获取用户列表",
  410. "name": "data",
  411. "in": "body",
  412. "required": true,
  413. "schema": {
  414. "type": "object",
  415. "$ref": "#/definitions/modelInterface.PageInfo"
  416. }
  417. }
  418. ],
  419. "responses": {
  420. "200": {
  421. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  422. "schema": {
  423. "type": "string"
  424. }
  425. }
  426. }
  427. }
  428. },
  429. "/base/login": {
  430. "post": {
  431. "produces": [
  432. "application/json"
  433. ],
  434. "tags": [
  435. "Base"
  436. ],
  437. "summary": "用户登录",
  438. "parameters": [
  439. {
  440. "description": "用户登录接口",
  441. "name": "data",
  442. "in": "body",
  443. "required": true,
  444. "schema": {
  445. "type": "object",
  446. "$ref": "#/definitions/api.RegistAndLoginStuct"
  447. }
  448. }
  449. ],
  450. "responses": {
  451. "200": {
  452. "description": "{\"success\":true,\"data\":{},\"msg\":\"登陆成功\"}",
  453. "schema": {
  454. "type": "string"
  455. }
  456. }
  457. }
  458. }
  459. },
  460. "/base/regist": {
  461. "post": {
  462. "produces": [
  463. "application/json"
  464. ],
  465. "tags": [
  466. "Base"
  467. ],
  468. "summary": "用户注册账号",
  469. "parameters": [
  470. {
  471. "description": "用户注册接口",
  472. "name": "data",
  473. "in": "body",
  474. "required": true,
  475. "schema": {
  476. "type": "object",
  477. "$ref": "#/definitions/api.RegistAndLoginStuct"
  478. }
  479. }
  480. ],
  481. "responses": {
  482. "200": {
  483. "description": "{\"success\":true,\"data\":{},\"msg\":\"注册成功\"}",
  484. "schema": {
  485. "type": "string"
  486. }
  487. }
  488. }
  489. }
  490. },
  491. "/fileUploadAndDownload/deleteFile": {
  492. "post": {
  493. "security": [
  494. {
  495. "ApiKeyAuth": []
  496. }
  497. ],
  498. "produces": [
  499. "application/json"
  500. ],
  501. "tags": [
  502. "FileUploadAndDownload"
  503. ],
  504. "summary": "删除文件",
  505. "parameters": [
  506. {
  507. "description": "传入文件里面id即可",
  508. "name": "data",
  509. "in": "body",
  510. "required": true,
  511. "schema": {
  512. "type": "object",
  513. "$ref": "#/definitions/dbModel.FileUploadAndDownload"
  514. }
  515. }
  516. ],
  517. "responses": {
  518. "200": {
  519. "description": "{\"success\":true,\"data\":{},\"msg\":\"返回成功\"}",
  520. "schema": {
  521. "type": "string"
  522. }
  523. }
  524. }
  525. }
  526. },
  527. "/fileUploadAndDownload/getFileList": {
  528. "post": {
  529. "security": [
  530. {
  531. "ApiKeyAuth": []
  532. }
  533. ],
  534. "consumes": [
  535. "application/json"
  536. ],
  537. "produces": [
  538. "application/json"
  539. ],
  540. "tags": [
  541. "FileUploadAndDownload"
  542. ],
  543. "summary": "分页文件列表",
  544. "parameters": [
  545. {
  546. "description": "分页获取文件户列表",
  547. "name": "data",
  548. "in": "body",
  549. "required": true,
  550. "schema": {
  551. "type": "object",
  552. "$ref": "#/definitions/modelInterface.PageInfo"
  553. }
  554. }
  555. ],
  556. "responses": {
  557. "200": {
  558. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  559. "schema": {
  560. "type": "string"
  561. }
  562. }
  563. }
  564. }
  565. },
  566. "/fileUploadAndDownload/upload": {
  567. "post": {
  568. "security": [
  569. {
  570. "ApiKeyAuth": []
  571. }
  572. ],
  573. "consumes": [
  574. "multipart/form-data"
  575. ],
  576. "produces": [
  577. "application/json"
  578. ],
  579. "tags": [
  580. "FileUploadAndDownload"
  581. ],
  582. "summary": "上传文件示例",
  583. "parameters": [
  584. {
  585. "type": "file",
  586. "description": "上传文件示例",
  587. "name": "file",
  588. "in": "formData",
  589. "required": true
  590. }
  591. ],
  592. "responses": {
  593. "200": {
  594. "description": "{\"success\":true,\"data\":{},\"msg\":\"上传成功\"}",
  595. "schema": {
  596. "type": "string"
  597. }
  598. }
  599. }
  600. }
  601. },
  602. "/menu/addBaseMenu": {
  603. "post": {
  604. "security": [
  605. {
  606. "ApiKeyAuth": []
  607. }
  608. ],
  609. "consumes": [
  610. "application/json"
  611. ],
  612. "produces": [
  613. "application/json"
  614. ],
  615. "tags": [
  616. "menu"
  617. ],
  618. "summary": "新增菜单",
  619. "parameters": [
  620. {
  621. "description": "新增菜单",
  622. "name": "data",
  623. "in": "body",
  624. "required": true,
  625. "schema": {
  626. "type": "object",
  627. "$ref": "#/definitions/dbModel.BaseMenu"
  628. }
  629. }
  630. ],
  631. "responses": {
  632. "200": {
  633. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  634. "schema": {
  635. "type": "string"
  636. }
  637. }
  638. }
  639. }
  640. },
  641. "/menu/addMenuAuthority": {
  642. "post": {
  643. "security": [
  644. {
  645. "ApiKeyAuth": []
  646. }
  647. ],
  648. "consumes": [
  649. "application/json"
  650. ],
  651. "produces": [
  652. "application/json"
  653. ],
  654. "tags": [
  655. "authorityAndMenu"
  656. ],
  657. "summary": "获取指定角色menu",
  658. "parameters": [
  659. {
  660. "description": "增加menu和角色关联关系",
  661. "name": "data",
  662. "in": "body",
  663. "required": true,
  664. "schema": {
  665. "type": "object",
  666. "$ref": "#/definitions/api.AuthorityIdInfo"
  667. }
  668. }
  669. ],
  670. "responses": {
  671. "200": {
  672. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  673. "schema": {
  674. "type": "string"
  675. }
  676. }
  677. }
  678. }
  679. },
  680. "/menu/deleteBaseMenu": {
  681. "post": {
  682. "security": [
  683. {
  684. "ApiKeyAuth": []
  685. }
  686. ],
  687. "consumes": [
  688. "application/json"
  689. ],
  690. "produces": [
  691. "application/json"
  692. ],
  693. "tags": [
  694. "menu"
  695. ],
  696. "summary": "删除菜单",
  697. "parameters": [
  698. {
  699. "description": "删除菜单",
  700. "name": "data",
  701. "in": "body",
  702. "required": true,
  703. "schema": {
  704. "type": "object",
  705. "$ref": "#/definitions/api.IdInfo"
  706. }
  707. }
  708. ],
  709. "responses": {
  710. "200": {
  711. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  712. "schema": {
  713. "type": "string"
  714. }
  715. }
  716. }
  717. }
  718. },
  719. "/menu/getBaseMenuById": {
  720. "post": {
  721. "security": [
  722. {
  723. "ApiKeyAuth": []
  724. }
  725. ],
  726. "consumes": [
  727. "application/json"
  728. ],
  729. "produces": [
  730. "application/json"
  731. ],
  732. "tags": [
  733. "menu"
  734. ],
  735. "summary": "根据id获取菜单",
  736. "parameters": [
  737. {
  738. "description": "根据id获取菜单",
  739. "name": "data",
  740. "in": "body",
  741. "required": true,
  742. "schema": {
  743. "type": "object",
  744. "$ref": "#/definitions/api.GetById"
  745. }
  746. }
  747. ],
  748. "responses": {
  749. "200": {
  750. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  751. "schema": {
  752. "type": "string"
  753. }
  754. }
  755. }
  756. }
  757. },
  758. "/menu/getBaseMenuTree": {
  759. "post": {
  760. "security": [
  761. {
  762. "ApiKeyAuth": []
  763. }
  764. ],
  765. "produces": [
  766. "application/json"
  767. ],
  768. "tags": [
  769. "authorityAndMenu"
  770. ],
  771. "summary": "获取用户动态路由",
  772. "parameters": [
  773. {
  774. "description": "可以什么都不填",
  775. "name": "data",
  776. "in": "body",
  777. "required": true,
  778. "schema": {
  779. "type": "object",
  780. "$ref": "#/definitions/api.RegistAndLoginStuct"
  781. }
  782. }
  783. ],
  784. "responses": {
  785. "200": {
  786. "description": "{\"success\":true,\"data\":{},\"msg\":\"返回成功\"}",
  787. "schema": {
  788. "type": "string"
  789. }
  790. }
  791. }
  792. }
  793. },
  794. "/menu/getMenu": {
  795. "post": {
  796. "security": [
  797. {
  798. "ApiKeyAuth": []
  799. }
  800. ],
  801. "produces": [
  802. "application/json"
  803. ],
  804. "tags": [
  805. "authorityAndMenu"
  806. ],
  807. "summary": "获取用户动态路由",
  808. "parameters": [
  809. {
  810. "description": "可以什么都不填",
  811. "name": "data",
  812. "in": "body",
  813. "required": true,
  814. "schema": {
  815. "type": "object",
  816. "$ref": "#/definitions/api.RegistAndLoginStuct"
  817. }
  818. }
  819. ],
  820. "responses": {
  821. "200": {
  822. "description": "{\"success\":true,\"data\":{},\"msg\":\"返回成功\"}",
  823. "schema": {
  824. "type": "string"
  825. }
  826. }
  827. }
  828. }
  829. },
  830. "/menu/getMenuList": {
  831. "post": {
  832. "security": [
  833. {
  834. "ApiKeyAuth": []
  835. }
  836. ],
  837. "consumes": [
  838. "application/json"
  839. ],
  840. "produces": [
  841. "application/json"
  842. ],
  843. "tags": [
  844. "menu"
  845. ],
  846. "summary": "分页获取基础menu列表",
  847. "parameters": [
  848. {
  849. "description": "分页获取基础menu列表",
  850. "name": "data",
  851. "in": "body",
  852. "required": true,
  853. "schema": {
  854. "type": "object",
  855. "$ref": "#/definitions/modelInterface.PageInfo"
  856. }
  857. }
  858. ],
  859. "responses": {
  860. "200": {
  861. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  862. "schema": {
  863. "type": "string"
  864. }
  865. }
  866. }
  867. }
  868. },
  869. "/menu/updataBaseMen": {
  870. "post": {
  871. "security": [
  872. {
  873. "ApiKeyAuth": []
  874. }
  875. ],
  876. "consumes": [
  877. "application/json"
  878. ],
  879. "produces": [
  880. "application/json"
  881. ],
  882. "tags": [
  883. "menu"
  884. ],
  885. "summary": "更新菜单",
  886. "parameters": [
  887. {
  888. "description": "更新菜单",
  889. "name": "data",
  890. "in": "body",
  891. "required": true,
  892. "schema": {
  893. "type": "object",
  894. "$ref": "#/definitions/dbModel.BaseMenu"
  895. }
  896. }
  897. ],
  898. "responses": {
  899. "200": {
  900. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  901. "schema": {
  902. "type": "string"
  903. }
  904. }
  905. }
  906. }
  907. },
  908. "/user/changePassword": {
  909. "post": {
  910. "security": [
  911. {
  912. "ApiKeyAuth": []
  913. }
  914. ],
  915. "produces": [
  916. "application/json"
  917. ],
  918. "tags": [
  919. "User"
  920. ],
  921. "summary": "用户修改密码",
  922. "parameters": [
  923. {
  924. "description": "用户修改密码",
  925. "name": "data",
  926. "in": "body",
  927. "required": true,
  928. "schema": {
  929. "type": "object",
  930. "$ref": "#/definitions/api.ChangePasswordStutrc"
  931. }
  932. }
  933. ],
  934. "responses": {
  935. "200": {
  936. "description": "{\"success\":true,\"data\":{},\"msg\":\"修改成功\"}",
  937. "schema": {
  938. "type": "string"
  939. }
  940. }
  941. }
  942. }
  943. },
  944. "/user/getUserList": {
  945. "post": {
  946. "security": [
  947. {
  948. "ApiKeyAuth": []
  949. }
  950. ],
  951. "consumes": [
  952. "application/json"
  953. ],
  954. "produces": [
  955. "application/json"
  956. ],
  957. "tags": [
  958. "User"
  959. ],
  960. "summary": "分页获取用户列表",
  961. "parameters": [
  962. {
  963. "description": "分页获取用户列表",
  964. "name": "data",
  965. "in": "body",
  966. "required": true,
  967. "schema": {
  968. "type": "object",
  969. "$ref": "#/definitions/modelInterface.PageInfo"
  970. }
  971. }
  972. ],
  973. "responses": {
  974. "200": {
  975. "description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
  976. "schema": {
  977. "type": "string"
  978. }
  979. }
  980. }
  981. }
  982. },
  983. "/user/setUserAuthority": {
  984. "post": {
  985. "security": [
  986. {
  987. "ApiKeyAuth": []
  988. }
  989. ],
  990. "consumes": [
  991. "application/json"
  992. ],
  993. "produces": [
  994. "application/json"
  995. ],
  996. "tags": [
  997. "User"
  998. ],
  999. "summary": "设置用户权限",
  1000. "parameters": [
  1001. {
  1002. "description": "设置用户权限",
  1003. "name": "data",
  1004. "in": "body",
  1005. "required": true,
  1006. "schema": {
  1007. "type": "object",
  1008. "$ref": "#/definitions/api.SetUserAuth"
  1009. }
  1010. }
  1011. ],
  1012. "responses": {
  1013. "200": {
  1014. "description": "{\"success\":true,\"data\":{},\"msg\":\"修改成功\"}",
  1015. "schema": {
  1016. "type": "string"
  1017. }
  1018. }
  1019. }
  1020. }
  1021. },
  1022. "/user/uploadHeaderImg": {
  1023. "post": {
  1024. "security": [
  1025. {
  1026. "ApiKeyAuth": []
  1027. }
  1028. ],
  1029. "consumes": [
  1030. "multipart/form-data"
  1031. ],
  1032. "produces": [
  1033. "application/json"
  1034. ],
  1035. "tags": [
  1036. "User"
  1037. ],
  1038. "summary": "用户上传头像",
  1039. "parameters": [
  1040. {
  1041. "type": "file",
  1042. "description": "用户上传头像",
  1043. "name": "headerImg",
  1044. "in": "formData",
  1045. "required": true
  1046. },
  1047. {
  1048. "type": "string",
  1049. "description": "用户上传头像",
  1050. "name": "username",
  1051. "in": "formData",
  1052. "required": true
  1053. }
  1054. ],
  1055. "responses": {
  1056. "200": {
  1057. "description": "{\"success\":true,\"data\":{},\"msg\":\"上传成功\"}",
  1058. "schema": {
  1059. "type": "string"
  1060. }
  1061. }
  1062. }
  1063. }
  1064. },
  1065. "/workflow/createWorkFlow": {
  1066. "post": {
  1067. "produces": [
  1068. "application/json"
  1069. ],
  1070. "tags": [
  1071. "workflow"
  1072. ],
  1073. "summary": "注册工作流",
  1074. "parameters": [
  1075. {
  1076. "description": "注册工作流接口",
  1077. "name": "data",
  1078. "in": "body",
  1079. "required": true,
  1080. "schema": {
  1081. "type": "object",
  1082. "$ref": "#/definitions/dbModel.Workflow"
  1083. }
  1084. }
  1085. ],
  1086. "responses": {
  1087. "200": {
  1088. "description": "{\"success\":true,\"data\":{},\"msg\":\"注册成功\"}",
  1089. "schema": {
  1090. "type": "string"
  1091. }
  1092. }
  1093. }
  1094. }
  1095. }
  1096. },
  1097. "definitions": {
  1098. "api.AddMenuAuthorityInfo": {
  1099. "type": "object",
  1100. "properties": {
  1101. "authorityId": {
  1102. "type": "string"
  1103. },
  1104. "menus": {
  1105. "type": "array",
  1106. "items": {
  1107. "$ref": "#/definitions/dbModel.BaseMenu"
  1108. }
  1109. }
  1110. }
  1111. },
  1112. "api.AuthAndPathIn": {
  1113. "type": "object",
  1114. "properties": {
  1115. "apiIds": {
  1116. "type": "array",
  1117. "items": {
  1118. "type": "integer"
  1119. }
  1120. },
  1121. "authorityId": {
  1122. "type": "string"
  1123. }
  1124. }
  1125. },
  1126. "api.AuthorityIdInfo": {
  1127. "type": "object",
  1128. "properties": {
  1129. "authorityId": {
  1130. "type": "string"
  1131. }
  1132. }
  1133. },
  1134. "api.ChangePasswordStutrc": {
  1135. "type": "object",
  1136. "properties": {
  1137. "newPassword": {
  1138. "type": "string"
  1139. },
  1140. "password": {
  1141. "type": "string"
  1142. },
  1143. "username": {
  1144. "type": "string"
  1145. }
  1146. }
  1147. },
  1148. "api.CreateApiParams": {
  1149. "type": "object",
  1150. "properties": {
  1151. "description": {
  1152. "type": "string"
  1153. },
  1154. "path": {
  1155. "type": "string"
  1156. }
  1157. }
  1158. },
  1159. "api.CreateAuthorityPatams": {
  1160. "type": "object",
  1161. "properties": {
  1162. "authorityId": {
  1163. "type": "string"
  1164. },
  1165. "authorityName": {
  1166. "type": "string"
  1167. }
  1168. }
  1169. },
  1170. "api.DeleteAuthorityPatams": {
  1171. "type": "object",
  1172. "properties": {
  1173. "authorityId": {
  1174. "type": "integer"
  1175. }
  1176. }
  1177. },
  1178. "api.GetAuthorityId": {
  1179. "type": "object",
  1180. "properties": {
  1181. "authorityId": {
  1182. "type": "string"
  1183. }
  1184. }
  1185. },
  1186. "api.GetById": {
  1187. "type": "object",
  1188. "properties": {
  1189. "id": {
  1190. "type": "number"
  1191. }
  1192. }
  1193. },
  1194. "api.IdInfo": {
  1195. "type": "object",
  1196. "properties": {
  1197. "id": {
  1198. "type": "number"
  1199. }
  1200. }
  1201. },
  1202. "api.RegistAndLoginStuct": {
  1203. "type": "object",
  1204. "properties": {
  1205. "password": {
  1206. "type": "string"
  1207. },
  1208. "username": {
  1209. "type": "string"
  1210. }
  1211. }
  1212. },
  1213. "api.SetUserAuth": {
  1214. "type": "object",
  1215. "properties": {
  1216. "authorityId": {
  1217. "type": "string"
  1218. },
  1219. "uuid": {
  1220. "type": "string"
  1221. }
  1222. }
  1223. },
  1224. "dbModel.Api": {
  1225. "type": "object",
  1226. "properties": {
  1227. "description": {
  1228. "type": "string"
  1229. },
  1230. "group": {
  1231. "type": "string"
  1232. },
  1233. "path": {
  1234. "type": "string"
  1235. }
  1236. }
  1237. },
  1238. "dbModel.BaseMenu": {
  1239. "type": "object",
  1240. "properties": {
  1241. "children": {
  1242. "type": "array",
  1243. "items": {
  1244. "$ref": "#/definitions/dbModel.BaseMenu"
  1245. }
  1246. },
  1247. "component": {
  1248. "type": "string"
  1249. },
  1250. "hidden": {
  1251. "type": "boolean"
  1252. },
  1253. "icon": {
  1254. "type": "string"
  1255. },
  1256. "name": {
  1257. "type": "string"
  1258. },
  1259. "nickName": {
  1260. "type": "string"
  1261. },
  1262. "parentId": {
  1263. "type": "string"
  1264. },
  1265. "path": {
  1266. "type": "string"
  1267. },
  1268. "title": {
  1269. "type": "string"
  1270. }
  1271. }
  1272. },
  1273. "dbModel.FileUploadAndDownload": {
  1274. "type": "object",
  1275. "properties": {
  1276. "key": {
  1277. "type": "string"
  1278. },
  1279. "name": {
  1280. "type": "string"
  1281. },
  1282. "tag": {
  1283. "type": "string"
  1284. },
  1285. "url": {
  1286. "type": "string"
  1287. }
  1288. }
  1289. },
  1290. "dbModel.Workflow": {
  1291. "type": "object",
  1292. "properties": {
  1293. "workflowDescription": {
  1294. "description": "工作流描述",
  1295. "type": "string"
  1296. },
  1297. "workflowName": {
  1298. "description": "工作流英文id",
  1299. "type": "string"
  1300. },
  1301. "workflowNickName": {
  1302. "description": "工作流名称",
  1303. "type": "string"
  1304. },
  1305. "workflowStep": {
  1306. "description": "工作流步骤",
  1307. "type": "array",
  1308. "items": {
  1309. "$ref": "#/definitions/dbModel.WorkflowStepInfo"
  1310. }
  1311. }
  1312. }
  1313. },
  1314. "dbModel.WorkflowStepInfo": {
  1315. "type": "object",
  1316. "properties": {
  1317. "isEnd": {
  1318. "description": "是否是完结流节点",
  1319. "type": "boolean"
  1320. },
  1321. "isStrat": {
  1322. "description": "是否是开始流节点",
  1323. "type": "boolean"
  1324. },
  1325. "stepAuthorityID": {
  1326. "description": "操作者级别id",
  1327. "type": "string"
  1328. },
  1329. "stepName": {
  1330. "description": "工作流名称",
  1331. "type": "string"
  1332. },
  1333. "stepNo": {
  1334. "description": "步骤id (第几步)",
  1335. "type": "number"
  1336. }
  1337. }
  1338. },
  1339. "modelInterface.PageInfo": {
  1340. "type": "object",
  1341. "properties": {
  1342. "page": {
  1343. "type": "integer"
  1344. },
  1345. "pageSize": {
  1346. "type": "integer"
  1347. }
  1348. }
  1349. }
  1350. },
  1351. "securityDefinitions": {
  1352. "ApiKeyAuth": {
  1353. "type": "apiKey",
  1354. "name": "x-token",
  1355. "in": "header"
  1356. }
  1357. }
  1358. }