Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
FLIPPED-AURORA
gin-vue-admin
提交
95a016a7
G
gin-vue-admin
项目概览
FLIPPED-AURORA
/
gin-vue-admin
大约 1 年 前同步成功
通知
332
Star
18154
Fork
5505
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
gin-vue-admin
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
95a016a7
编写于
10月 18, 2020
作者:
Mr.奇淼(
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
删除注册页面 为注册接口修改为需要权限 防止业务漏洞
上级
5890780b
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
707 addition
and
158 deletion
+707
-158
server/api/v1/sys_user.go
server/api/v1/sys_user.go
+1
-1
server/docs/docs.go
server/docs/docs.go
+264
-56
server/docs/swagger.json
server/docs/swagger.json
+263
-55
server/docs/swagger.yaml
server/docs/swagger.yaml
+174
-41
server/gva/init_data/init_data.go
server/gva/init_data/init_data.go
+4
-4
server/router/sys_base.go
server/router/sys_base.go
+0
-1
server/router/sys_user.go
server/router/sys_user.go
+1
-0
未找到文件。
server/api/v1/sys_user.go
浏览文件 @
95a016a7
...
...
@@ -22,7 +22,7 @@ import (
// @Produce application/json
// @Param data body model.SysUser true "用户注册接口"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"注册成功"}"
// @Router /
base
/register [post]
// @Router /
user
/register [post]
func
Register
(
c
*
gin
.
Context
)
{
var
R
request
.
RegisterStruct
_
=
c
.
ShouldBindJSON
(
&
R
)
...
...
server/docs/docs.go
浏览文件 @
95a016a7
// GENERATED BY THE COMMAND ABOVE; DO NOT EDIT
// This file was generated by swaggo/swag at
// 2020-
08-31 21:50:05.0136259 +0800 CST m=+0.1933144
01
// 2020-
10-18 12:17:37.2292991 +0800 CST m=+0.2636098
01
package
docs
...
...
@@ -593,36 +593,6 @@ var doc = `{
}
}
},
"/base/register": {
"post": {
"produces": [
"application/json"
],
"tags": [
"Base"
],
"summary": "用户注册账号",
"parameters": [
{
"description": "用户注册接口",
"name": "data",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/model.SysUser"
}
}
],
"responses": {
"200": {
"description": "{\"success\":true,\"data\":{},\"msg\":\"注册成功\"}",
"schema": {
"type": "string"
}
}
}
}
},
"/casbin/UpdateCasbin": {
"post": {
"security": [
...
...
@@ -883,6 +853,30 @@ var doc = `{
}
}
},
"/email/emailTest": {
"post": {
"security": [
{
"ApiKeyAuth": []
}
],
"produces": [
"application/json"
],
"tags": [
"system"
],
"summary": "发送测试邮件",
"responses": {
"200": {
"description": "{\"success\":true,\"data\":{},\"msg\":\"返回成功\"}",
"schema": {
"type": "string"
}
}
}
}
},
"/fileUploadAndDownload/breakpointContinue": {
"post": {
"security": [
...
...
@@ -2161,6 +2155,30 @@ var doc = `{
}
}
},
"/system/getServerInfo": {
"post": {
"security": [
{
"ApiKeyAuth": []
}
],
"produces": [
"application/json"
],
"tags": [
"system"
],
"summary": "获取服务器信息",
"responses": {
"200": {
"description": "{\"success\":true,\"data\":{},\"msg\":\"获取成功\"}",
"schema": {
"type": "string"
}
}
}
}
},
"/system/getSystemConfig": {
"post": {
"security": [
...
...
@@ -2331,6 +2349,36 @@ var doc = `{
}
}
},
"/user/register": {
"post": {
"produces": [
"application/json"
],
"tags": [
"Base"
],
"summary": "用户注册账号",
"parameters": [
{
"description": "用户注册接口",
"name": "data",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/model.SysUser"
}
}
],
"responses": {
"200": {
"description": "{\"success\":true,\"data\":{},\"msg\":\"注册成功\"}",
"schema": {
"type": "string"
}
}
}
}
},
"/user/setUserAuthority": {
"post": {
"security": [
...
...
@@ -2369,6 +2417,44 @@ var doc = `{
}
}
},
"/user/setUserInfo": {
"put": {
"security": [
{
"ApiKeyAuth": []
}
],
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"SysUser"
],
"summary": "删除用户",
"parameters": [
{
"description": "删除用户",
"name": "data",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/model.SysUser"
}
}
],
"responses": {
"200": {
"description": "{\"success\":true,\"data\":{},\"msg\":\"修改成功\"}",
"schema": {
"type": "string"
}
}
}
}
},
"/workflow/createWorkFlow": {
"post": {
"produces": [
...
...
@@ -2423,6 +2509,32 @@ var doc = `{
}
}
},
"config.Email": {
"type": "object",
"properties": {
"from": {
"type": "string"
},
"host": {
"type": "string"
},
"isSSL": {
"type": "boolean"
},
"nickname": {
"type": "string"
},
"port": {
"type": "integer"
},
"secret": {
"type": "string"
},
"to": {
"type": "string"
}
}
},
"config.JWT": {
"type": "object",
"properties": {
...
...
@@ -2431,38 +2543,44 @@ var doc = `{
}
}
},
"config.Local
Upload
": {
"config.Local": {
"type": "object",
"properties": {
"avatarPath": {
"type": "string"
},
"filePath": {
"path": {
"type": "string"
},
"local": {
"type": "boolean"
}
}
},
"config.
Log
": {
"config.
Mysql
": {
"type": "object",
"properties": {
"file": {
"config": {
"type": "string"
},
"dbname": {
"type": "string"
},
"log
Fil
e": {
"log
Mod
e": {
"type": "boolean"
},
"prefix": {
"maxIdleConns": {
"type": "integer"
},
"maxOpenConns": {
"type": "integer"
},
"password": {
"type": "string"
},
"path": {
"type": "string"
},
"
stdout
": {
"
username
": {
"type": "string"
}
}
},
"config.
My
sql": {
"config.
Postgre
sql": {
"type": "object",
"properties": {
"config": {
...
...
@@ -2471,7 +2589,10 @@ var doc = `{
"dbname": {
"type": "string"
},
"logMode": {
"host": {
"type": "string"
},
"logger": {
"type": "boolean"
},
"maxIdleConns": {
...
...
@@ -2483,9 +2604,12 @@ var doc = `{
"password": {
"type": "string"
},
"p
ath
": {
"p
ort
": {
"type": "string"
},
"preferSimpleProtocol": {
"type": "boolean"
},
"username": {
"type": "string"
}
...
...
@@ -2505,6 +2629,15 @@ var doc = `{
},
"secretKey": {
"type": "string"
},
"useCdnDomains": {
"type": "boolean"
},
"useHttps": {
"type": "boolean"
},
"zone": {
"type": "string"
}
}
},
...
...
@@ -2533,22 +2666,28 @@ var doc = `{
"type": "object",
"$ref": "#/definitions/config.Casbin"
},
"
jwt
": {
"
email
": {
"type": "object",
"$ref": "#/definitions/config.
JWT
"
"$ref": "#/definitions/config.
Email
"
},
"
localUpload
": {
"
jwt
": {
"type": "object",
"$ref": "#/definitions/config.
LocalUpload
"
"$ref": "#/definitions/config.
JWT
"
},
"log": {
"local": {
"description": "oss",
"type": "object",
"$ref": "#/definitions/config.Lo
g
"
"$ref": "#/definitions/config.Lo
cal
"
},
"mysql": {
"description": "gorm",
"type": "object",
"$ref": "#/definitions/config.Mysql"
},
"postgresql": {
"type": "object",
"$ref": "#/definitions/config.Postgresql"
},
"qiniu": {
"type": "object",
"$ref": "#/definitions/config.Qiniu"
...
...
@@ -2561,21 +2700,52 @@ var doc = `{
"type": "object",
"$ref": "#/definitions/config.Sqlite"
},
"sqlserver": {
"type": "object",
"$ref": "#/definitions/config.Sqlserver"
},
"system": {
"type": "object",
"$ref": "#/definitions/config.System"
},
"zap": {
"type": "object",
"$ref": "#/definitions/config.Zap"
}
}
},
"config.Sqlite": {
"type": "object",
"properties": {
"config": {
"logger": {
"type": "boolean"
},
"maxIdleConns": {
"type": "integer"
},
"maxOpenConns": {
"type": "integer"
},
"path": {
"type": "string"
}
}
},
"config.Sqlserver": {
"type": "object",
"properties": {
"dbname": {
"type": "string"
},
"log
Mode
": {
"log
ger
": {
"type": "boolean"
},
"maxIdleConns": {
"type": "integer"
},
"maxOpenConns": {
"type": "integer"
},
"password": {
"type": "string"
},
...
...
@@ -2599,11 +2769,49 @@ var doc = `{
"env": {
"type": "string"
},
"needInitData": {
"type": "boolean"
},
"ossType": {
"type": "string"
},
"useMultipoint": {
"type": "boolean"
}
}
},
"config.Zap": {
"type": "object",
"properties": {
"director": {
"type": "string"
},
"encodeLevel": {
"type": "string"
},
"format": {
"type": "string"
},
"level": {
"type": "string"
},
"linkName": {
"type": "string"
},
"logInConsole": {
"type": "boolean"
},
"prefix": {
"type": "string"
},
"showLine": {
"type": "boolean"
},
"stacktraceKey": {
"type": "string"
}
}
},
"model.AutoCodeStruct": {
"type": "object",
"properties": {
...
...
@@ -2971,7 +3179,7 @@ var doc = `{
"description": "是否是完结流节点",
"type": "boolean"
},
"isSt
ra
t": {
"isSt
ar
t": {
"description": "是否是开始流节点",
"type": "boolean"
},
...
...
server/docs/swagger.json
浏览文件 @
95a016a7
...
...
@@ -576,36 +576,6 @@
}
}
},
"/base/register"
:
{
"post"
:
{
"produces"
:
[
"application/json"
],
"tags"
:
[
"Base"
],
"summary"
:
"用户注册账号"
,
"parameters"
:
[
{
"description"
:
"用户注册接口"
,
"name"
:
"data"
,
"in"
:
"body"
,
"required"
:
true
,
"schema"
:
{
"$ref"
:
"#/definitions/model.SysUser"
}
}
],
"responses"
:
{
"200"
:
{
"description"
:
"{
\"
success
\"
:true,
\"
data
\"
:{},
\"
msg
\"
:
\"
注册成功
\"
}"
,
"schema"
:
{
"type"
:
"string"
}
}
}
}
},
"/casbin/UpdateCasbin"
:
{
"post"
:
{
"security"
:
[
...
...
@@ -866,6 +836,30 @@
}
}
},
"/email/emailTest"
:
{
"post"
:
{
"security"
:
[
{
"ApiKeyAuth"
:
[]
}
],
"produces"
:
[
"application/json"
],
"tags"
:
[
"system"
],
"summary"
:
"发送测试邮件"
,
"responses"
:
{
"200"
:
{
"description"
:
"{
\"
success
\"
:true,
\"
data
\"
:{},
\"
msg
\"
:
\"
返回成功
\"
}"
,
"schema"
:
{
"type"
:
"string"
}
}
}
}
},
"/fileUploadAndDownload/breakpointContinue"
:
{
"post"
:
{
"security"
:
[
...
...
@@ -2144,6 +2138,30 @@
}
}
},
"/system/getServerInfo"
:
{
"post"
:
{
"security"
:
[
{
"ApiKeyAuth"
:
[]
}
],
"produces"
:
[
"application/json"
],
"tags"
:
[
"system"
],
"summary"
:
"获取服务器信息"
,
"responses"
:
{
"200"
:
{
"description"
:
"{
\"
success
\"
:true,
\"
data
\"
:{},
\"
msg
\"
:
\"
获取成功
\"
}"
,
"schema"
:
{
"type"
:
"string"
}
}
}
}
},
"/system/getSystemConfig"
:
{
"post"
:
{
"security"
:
[
...
...
@@ -2314,6 +2332,36 @@
}
}
},
"/user/register"
:
{
"post"
:
{
"produces"
:
[
"application/json"
],
"tags"
:
[
"Base"
],
"summary"
:
"用户注册账号"
,
"parameters"
:
[
{
"description"
:
"用户注册接口"
,
"name"
:
"data"
,
"in"
:
"body"
,
"required"
:
true
,
"schema"
:
{
"$ref"
:
"#/definitions/model.SysUser"
}
}
],
"responses"
:
{
"200"
:
{
"description"
:
"{
\"
success
\"
:true,
\"
data
\"
:{},
\"
msg
\"
:
\"
注册成功
\"
}"
,
"schema"
:
{
"type"
:
"string"
}
}
}
}
},
"/user/setUserAuthority"
:
{
"post"
:
{
"security"
:
[
...
...
@@ -2352,6 +2400,44 @@
}
}
},
"/user/setUserInfo"
:
{
"put"
:
{
"security"
:
[
{
"ApiKeyAuth"
:
[]
}
],
"consumes"
:
[
"application/json"
],
"produces"
:
[
"application/json"
],
"tags"
:
[
"SysUser"
],
"summary"
:
"删除用户"
,
"parameters"
:
[
{
"description"
:
"删除用户"
,
"name"
:
"data"
,
"in"
:
"body"
,
"required"
:
true
,
"schema"
:
{
"$ref"
:
"#/definitions/model.SysUser"
}
}
],
"responses"
:
{
"200"
:
{
"description"
:
"{
\"
success
\"
:true,
\"
data
\"
:{},
\"
msg
\"
:
\"
修改成功
\"
}"
,
"schema"
:
{
"type"
:
"string"
}
}
}
}
},
"/workflow/createWorkFlow"
:
{
"post"
:
{
"produces"
:
[
...
...
@@ -2406,6 +2492,32 @@
}
}
},
"config.Email"
:
{
"type"
:
"object"
,
"properties"
:
{
"from"
:
{
"type"
:
"string"
},
"host"
:
{
"type"
:
"string"
},
"isSSL"
:
{
"type"
:
"boolean"
},
"nickname"
:
{
"type"
:
"string"
},
"port"
:
{
"type"
:
"integer"
},
"secret"
:
{
"type"
:
"string"
},
"to"
:
{
"type"
:
"string"
}
}
},
"config.JWT"
:
{
"type"
:
"object"
,
"properties"
:
{
...
...
@@ -2414,38 +2526,44 @@
}
}
},
"config.Local
Upload
"
:
{
"config.Local"
:
{
"type"
:
"object"
,
"properties"
:
{
"avatarPath"
:
{
"type"
:
"string"
},
"filePath"
:
{
"path"
:
{
"type"
:
"string"
},
"local"
:
{
"type"
:
"boolean"
}
}
},
"config.
Log
"
:
{
"config.
Mysql
"
:
{
"type"
:
"object"
,
"properties"
:
{
"file"
:
{
"config"
:
{
"type"
:
"string"
},
"dbname"
:
{
"type"
:
"string"
},
"log
Fil
e"
:
{
"log
Mod
e"
:
{
"type"
:
"boolean"
},
"prefix"
:
{
"maxIdleConns"
:
{
"type"
:
"integer"
},
"maxOpenConns"
:
{
"type"
:
"integer"
},
"password"
:
{
"type"
:
"string"
},
"path"
:
{
"type"
:
"string"
},
"
stdout
"
:
{
"
username
"
:
{
"type"
:
"string"
}
}
},
"config.
My
sql"
:
{
"config.
Postgre
sql"
:
{
"type"
:
"object"
,
"properties"
:
{
"config"
:
{
...
...
@@ -2454,7 +2572,10 @@
"dbname"
:
{
"type"
:
"string"
},
"logMode"
:
{
"host"
:
{
"type"
:
"string"
},
"logger"
:
{
"type"
:
"boolean"
},
"maxIdleConns"
:
{
...
...
@@ -2466,9 +2587,12 @@
"password"
:
{
"type"
:
"string"
},
"p
ath
"
:
{
"p
ort
"
:
{
"type"
:
"string"
},
"preferSimpleProtocol"
:
{
"type"
:
"boolean"
},
"username"
:
{
"type"
:
"string"
}
...
...
@@ -2488,6 +2612,15 @@
},
"secretKey"
:
{
"type"
:
"string"
},
"useCdnDomains"
:
{
"type"
:
"boolean"
},
"useHttps"
:
{
"type"
:
"boolean"
},
"zone"
:
{
"type"
:
"string"
}
}
},
...
...
@@ -2516,22 +2649,28 @@
"type"
:
"object"
,
"$ref"
:
"#/definitions/config.Casbin"
},
"
jwt
"
:
{
"
email
"
:
{
"type"
:
"object"
,
"$ref"
:
"#/definitions/config.
JWT
"
"$ref"
:
"#/definitions/config.
Email
"
},
"
localUpload
"
:
{
"
jwt
"
:
{
"type"
:
"object"
,
"$ref"
:
"#/definitions/config.
LocalUpload
"
"$ref"
:
"#/definitions/config.
JWT
"
},
"log"
:
{
"local"
:
{
"description"
:
"oss"
,
"type"
:
"object"
,
"$ref"
:
"#/definitions/config.Lo
g
"
"$ref"
:
"#/definitions/config.Lo
cal
"
},
"mysql"
:
{
"description"
:
"gorm"
,
"type"
:
"object"
,
"$ref"
:
"#/definitions/config.Mysql"
},
"postgresql"
:
{
"type"
:
"object"
,
"$ref"
:
"#/definitions/config.Postgresql"
},
"qiniu"
:
{
"type"
:
"object"
,
"$ref"
:
"#/definitions/config.Qiniu"
...
...
@@ -2544,21 +2683,52 @@
"type"
:
"object"
,
"$ref"
:
"#/definitions/config.Sqlite"
},
"sqlserver"
:
{
"type"
:
"object"
,
"$ref"
:
"#/definitions/config.Sqlserver"
},
"system"
:
{
"type"
:
"object"
,
"$ref"
:
"#/definitions/config.System"
},
"zap"
:
{
"type"
:
"object"
,
"$ref"
:
"#/definitions/config.Zap"
}
}
},
"config.Sqlite"
:
{
"type"
:
"object"
,
"properties"
:
{
"config"
:
{
"logger"
:
{
"type"
:
"boolean"
},
"maxIdleConns"
:
{
"type"
:
"integer"
},
"maxOpenConns"
:
{
"type"
:
"integer"
},
"path"
:
{
"type"
:
"string"
}
}
},
"config.Sqlserver"
:
{
"type"
:
"object"
,
"properties"
:
{
"dbname"
:
{
"type"
:
"string"
},
"log
Mode
"
:
{
"log
ger
"
:
{
"type"
:
"boolean"
},
"maxIdleConns"
:
{
"type"
:
"integer"
},
"maxOpenConns"
:
{
"type"
:
"integer"
},
"password"
:
{
"type"
:
"string"
},
...
...
@@ -2582,11 +2752,49 @@
"env"
:
{
"type"
:
"string"
},
"needInitData"
:
{
"type"
:
"boolean"
},
"ossType"
:
{
"type"
:
"string"
},
"useMultipoint"
:
{
"type"
:
"boolean"
}
}
},
"config.Zap"
:
{
"type"
:
"object"
,
"properties"
:
{
"director"
:
{
"type"
:
"string"
},
"encodeLevel"
:
{
"type"
:
"string"
},
"format"
:
{
"type"
:
"string"
},
"level"
:
{
"type"
:
"string"
},
"linkName"
:
{
"type"
:
"string"
},
"logInConsole"
:
{
"type"
:
"boolean"
},
"prefix"
:
{
"type"
:
"string"
},
"showLine"
:
{
"type"
:
"boolean"
},
"stacktraceKey"
:
{
"type"
:
"string"
}
}
},
"model.AutoCodeStruct"
:
{
"type"
:
"object"
,
"properties"
:
{
...
...
@@ -2954,7 +3162,7 @@
"description"
:
"是否是完结流节点"
,
"type"
:
"boolean"
},
"isSt
ra
t"
:
{
"isSt
ar
t"
:
{
"description"
:
"是否是开始流节点"
,
"type"
:
"boolean"
},
...
...
server/docs/swagger.yaml
浏览文件 @
95a016a7
...
...
@@ -14,38 +14,61 @@ definitions:
modelPath
:
type
:
string
type
:
object
config.Email
:
properties
:
from
:
type
:
string
host
:
type
:
string
isSSL
:
type
:
boolean
nickname
:
type
:
string
port
:
type
:
integer
secret
:
type
:
string
to
:
type
:
string
type
:
object
config.JWT
:
properties
:
signingKey
:
type
:
string
type
:
object
config.Local
Upload
:
config.Local
:
properties
:
avatarPath
:
type
:
string
filePath
:
path
:
type
:
string
local
:
type
:
boolean
type
:
object
config.
Log
:
config.
Mysql
:
properties
:
file
:
config
:
type
:
string
logFile
:
dbname
:
type
:
string
logMode
:
type
:
boolean
prefix
:
maxIdleConns
:
type
:
integer
maxOpenConns
:
type
:
integer
password
:
type
:
string
path
:
type
:
string
stdout
:
username
:
type
:
string
type
:
object
config.
My
sql
:
config.
Postgre
sql
:
properties
:
config
:
type
:
string
dbname
:
type
:
string
logMode
:
host
:
type
:
string
logger
:
type
:
boolean
maxIdleConns
:
type
:
integer
...
...
@@ -53,8 +76,10 @@ definitions:
type
:
integer
password
:
type
:
string
p
ath
:
p
ort
:
type
:
string
preferSimpleProtocol
:
type
:
boolean
username
:
type
:
string
type
:
object
...
...
@@ -68,6 +93,12 @@ definitions:
type
:
string
secretKey
:
type
:
string
useCdnDomains
:
type
:
boolean
useHttps
:
type
:
boolean
zone
:
type
:
string
type
:
object
config.Redis
:
properties
:
...
...
@@ -86,17 +117,22 @@ definitions:
casbin
:
$ref
:
'
#/definitions/config.Casbin'
type
:
object
email
:
$ref
:
'
#/definitions/config.Email'
type
:
object
jwt
:
$ref
:
'
#/definitions/config.JWT'
type
:
object
localUpload
:
$ref
:
'
#/definitions/config.LocalUpload'
type
:
object
log
:
$ref
:
'
#/definitions/config.Log'
local
:
$ref
:
'
#/definitions/config.Local'
description
:
oss
type
:
object
mysql
:
$ref
:
'
#/definitions/config.Mysql'
description
:
gorm
type
:
object
postgresql
:
$ref
:
'
#/definitions/config.Postgresql'
type
:
object
qiniu
:
$ref
:
'
#/definitions/config.Qiniu'
...
...
@@ -107,16 +143,37 @@ definitions:
sqlite
:
$ref
:
'
#/definitions/config.Sqlite'
type
:
object
sqlserver
:
$ref
:
'
#/definitions/config.Sqlserver'
type
:
object
system
:
$ref
:
'
#/definitions/config.System'
type
:
object
zap
:
$ref
:
'
#/definitions/config.Zap'
type
:
object
type
:
object
config.Sqlite
:
properties
:
config
:
logger
:
type
:
boolean
maxIdleConns
:
type
:
integer
maxOpenConns
:
type
:
integer
path
:
type
:
string
logMode
:
type
:
object
config.Sqlserver
:
properties
:
dbname
:
type
:
string
logger
:
type
:
boolean
maxIdleConns
:
type
:
integer
maxOpenConns
:
type
:
integer
password
:
type
:
string
path
:
...
...
@@ -132,9 +189,34 @@ definitions:
type
:
string
env
:
type
:
string
needInitData
:
type
:
boolean
ossType
:
type
:
string
useMultipoint
:
type
:
boolean
type
:
object
config.Zap
:
properties
:
director
:
type
:
string
encodeLevel
:
type
:
string
format
:
type
:
string
level
:
type
:
string
linkName
:
type
:
string
logInConsole
:
type
:
boolean
prefix
:
type
:
string
showLine
:
type
:
boolean
stacktraceKey
:
type
:
string
type
:
object
model.AutoCodeStruct
:
properties
:
abbreviation
:
...
...
@@ -378,7 +460,7 @@ definitions:
isEnd
:
description
:
是否是完结流节点
type
:
boolean
isSt
ra
t
:
isSt
ar
t
:
description
:
是否是开始流节点
type
:
boolean
stepAuthorityID
:
...
...
@@ -919,25 +1001,6 @@ paths:
summary
:
用户登录
tags
:
-
Base
/base/register
:
post
:
parameters
:
-
description
:
用户注册接口
in
:
body
name
:
data
required
:
true
schema
:
$ref
:
'
#/definitions/model.SysUser'
produces
:
-
application/json
responses
:
"
200"
:
description
:
'
{"success":true,"data":{},"msg":"注册成功"}'
schema
:
type
:
string
summary
:
用户注册账号
tags
:
-
Base
/casbin/UpdateCasbin
:
post
:
consumes
:
...
...
@@ -1096,6 +1159,20 @@ paths:
summary
:
获取权限客户列表
tags
:
-
SysApi
/email/emailTest
:
post
:
produces
:
-
application/json
responses
:
"
200"
:
description
:
'
{"success":true,"data":{},"msg":"返回成功"}'
schema
:
type
:
string
security
:
-
ApiKeyAuth
:
[]
summary
:
发送测试邮件
tags
:
-
system
/fileUploadAndDownload/breakpointContinue
:
post
:
consumes
:
...
...
@@ -1870,6 +1947,20 @@ paths:
summary
:
设置配置文件内容
tags
:
-
system
/system/getServerInfo
:
post
:
produces
:
-
application/json
responses
:
"
200"
:
description
:
'
{"success":true,"data":{},"msg":"获取成功"}'
schema
:
type
:
string
security
:
-
ApiKeyAuth
:
[]
summary
:
获取服务器信息
tags
:
-
system
/system/getSystemConfig
:
post
:
produces
:
...
...
@@ -1972,6 +2063,25 @@ paths:
summary
:
分页获取用户列表
tags
:
-
SysUser
/user/register
:
post
:
parameters
:
-
description
:
用户注册接口
in
:
body
name
:
data
required
:
true
schema
:
$ref
:
'
#/definitions/model.SysUser'
produces
:
-
application/json
responses
:
"
200"
:
description
:
'
{"success":true,"data":{},"msg":"注册成功"}'
schema
:
type
:
string
summary
:
用户注册账号
tags
:
-
Base
/user/setUserAuthority
:
post
:
consumes
:
...
...
@@ -1995,6 +2105,29 @@ paths:
summary
:
设置用户权限
tags
:
-
SysUser
/user/setUserInfo
:
put
:
consumes
:
-
application/json
parameters
:
-
description
:
删除用户
in
:
body
name
:
data
required
:
true
schema
:
$ref
:
'
#/definitions/model.SysUser'
produces
:
-
application/json
responses
:
"
200"
:
description
:
'
{"success":true,"data":{},"msg":"修改成功"}'
schema
:
type
:
string
security
:
-
ApiKeyAuth
:
[]
summary
:
删除用户
tags
:
-
SysUser
/workflow/createWorkFlow
:
post
:
parameters
:
...
...
server/gva/init_data/init_data.go
浏览文件 @
95a016a7
...
...
@@ -24,7 +24,7 @@ func InitSysApi() (err error) {
tx
:=
global
.
GVA_DB
.
Begin
()
// 开始事务
insert
:=
[]
model
.
SysApi
{
{
gorm
.
Model
{
ID
:
1
,
CreatedAt
:
time
.
Now
(),
UpdatedAt
:
time
.
Now
()},
"/base/login"
,
"用户登录"
,
"base"
,
"POST"
},
{
gorm
.
Model
{
ID
:
2
,
CreatedAt
:
time
.
Now
(),
UpdatedAt
:
time
.
Now
()},
"/
base/register"
,
"用户注册"
,
"base
"
,
"POST"
},
{
gorm
.
Model
{
ID
:
2
,
CreatedAt
:
time
.
Now
(),
UpdatedAt
:
time
.
Now
()},
"/
user/register"
,
"用户注册"
,
"user
"
,
"POST"
},
{
gorm
.
Model
{
ID
:
3
,
CreatedAt
:
time
.
Now
(),
UpdatedAt
:
time
.
Now
()},
"/api/createApi"
,
"创建api"
,
"api"
,
"POST"
},
{
gorm
.
Model
{
ID
:
4
,
CreatedAt
:
time
.
Now
(),
UpdatedAt
:
time
.
Now
()},
"/api/getApiList"
,
"获取api列表"
,
"api"
,
"POST"
},
{
gorm
.
Model
{
ID
:
5
,
CreatedAt
:
time
.
Now
(),
UpdatedAt
:
time
.
Now
()},
"/api/getApiById"
,
"获取api详细信息"
,
"api"
,
"POST"
},
...
...
@@ -128,7 +128,7 @@ func InitCasbinModel() (err error) {
tx
:=
global
.
GVA_DB
.
Begin
()
// 开始事务
insert
:=
[]
model
.
CasbinModel
{
{
"p"
,
"888"
,
"/base/login"
,
"POST"
},
{
"p"
,
"888"
,
"/
base
/register"
,
"POST"
},
{
"p"
,
"888"
,
"/
user
/register"
,
"POST"
},
{
"p"
,
"888"
,
"/api/createApi"
,
"POST"
},
{
"p"
,
"888"
,
"/api/getApiList"
,
"POST"
},
{
"p"
,
"888"
,
"/api/getApiById"
,
"POST"
},
...
...
@@ -192,7 +192,7 @@ func InitCasbinModel() (err error) {
{
"p"
,
"888"
,
"/user/setUserInfo"
,
"PUT"
},
{
"p"
,
"888"
,
"/email/emailTest"
,
"POST"
},
{
"p"
,
"8881"
,
"/base/login"
,
"POST"
},
{
"p"
,
"8881"
,
"/
base
/register"
,
"POST"
},
{
"p"
,
"8881"
,
"/
user
/register"
,
"POST"
},
{
"p"
,
"8881"
,
"/api/createApi"
,
"POST"
},
{
"p"
,
"8881"
,
"/api/getApiList"
,
"POST"
},
{
"p"
,
"8881"
,
"/api/getApiById"
,
"POST"
},
...
...
@@ -229,7 +229,7 @@ func InitCasbinModel() (err error) {
{
"p"
,
"8881"
,
"/customer/customer"
,
"GET"
},
{
"p"
,
"8881"
,
"/customer/customerList"
,
"GET"
},
{
"p"
,
"9528"
,
"/base/login"
,
"POST"
},
{
"p"
,
"9528"
,
"/
base
/register"
,
"POST"
},
{
"p"
,
"9528"
,
"/
user
/register"
,
"POST"
},
{
"p"
,
"9528"
,
"/api/createApi"
,
"POST"
},
{
"p"
,
"9528"
,
"/api/getApiList"
,
"POST"
},
{
"p"
,
"9528"
,
"/api/getApiById"
,
"POST"
},
...
...
server/router/sys_base.go
浏览文件 @
95a016a7
...
...
@@ -8,7 +8,6 @@ import (
func
InitBaseRouter
(
Router
*
gin
.
RouterGroup
)
(
R
gin
.
IRoutes
)
{
BaseRouter
:=
Router
.
Group
(
"base"
)
{
BaseRouter
.
POST
(
"register"
,
v1
.
Register
)
BaseRouter
.
POST
(
"login"
,
v1
.
Login
)
BaseRouter
.
POST
(
"captcha"
,
v1
.
Captcha
)
}
...
...
server/router/sys_user.go
浏览文件 @
95a016a7
...
...
@@ -12,6 +12,7 @@ func InitUserRouter(Router *gin.RouterGroup) {
Use
(
middleware
.
CasbinHandler
())
.
Use
(
middleware
.
OperationRecord
())
{
UserRouter
.
POST
(
"register"
,
v1
.
Register
)
UserRouter
.
POST
(
"changePassword"
,
v1
.
ChangePassword
)
// 修改密码
UserRouter
.
POST
(
"getUserList"
,
v1
.
GetUserList
)
// 分页获取用户列表
UserRouter
.
POST
(
"setUserAuthority"
,
v1
.
SetUserAuthority
)
// 设置用户权限
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录