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.

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