diff --git a/README.md b/README.md index 3a755e1..87609ff 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@

- goframe + goframe vue @@ -68,7 +68,7 @@ 15. 代码生成:支持自动化生成前后端代码。CURD关联表、树表、消息队列、定时任务一键生成等。 16. 插件应用:支持一键生成插件模板,每个插件之间开发隔离,拥有独立多应用入口、独立配置。完美支持多人协同开发、插件插拔不会对原系统产生影响等。 17. 服务监控:监视当前系统CPU、内存、磁盘、网络、堆栈等相关信息。 -18. 附件管理:文件图片上传,支持本地、阿里云oss、腾讯云cos、ucloud对象存储、七牛云对象存储等多种上传驱动,后台一键切换配置,并集成了文件选择器。 +18. 附件管理:文件图片上传,支持本地、阿里云oss、腾讯云cos、ucloud对象存储、七牛云对象存储、minio等多种上传驱动,后台一键切换配置,并集成了文件选择器。 19. TCP服务:基于gtcp的服务应用,支持长连接、断线重连、服务认证、路由分发、RPC消息、拦截器和数据绑定等。简化和规范了服务器开发流程。 20. 消息队列:同时兼容 kafka、redis、rocketmq、磁盘队列,一键配置切换到场景适用的MQ。 21. 通知公告:采用websocket实时推送在线用户最新通知、公告、私信消息。 diff --git a/docs/guide-zh-CN/start-deploy.md b/docs/guide-zh-CN/start-deploy.md index bc45833..9b4877d 100644 --- a/docs/guide-zh-CN/start-deploy.md +++ b/docs/guide-zh-CN/start-deploy.md @@ -31,7 +31,7 @@ gfcli: - 以下方式任选其一即可 -1、 make一键编译 (linux或mac环境推荐) +1、 make一键编译 (确认已安装`make环境`) ```shell cd server && make build ``` @@ -46,16 +46,27 @@ cd ../web && yarn build # 切换到web项目下, echo "y" | gf build # 编译hotgo服务端 # 不出意外你已经编译好了hotgo可执行文件! -``` +``` -3、分服务编译 +3、分端编译 (多人开发时推荐) +```shell +# 编译服务端 +cd server # 切换到服务端目录下 +rm -rf ./resource/public/admin/ # 删除之前的web资源,如果开发环境没有这个目录可以忽略此步骤 +echo "y" | gf build # 编译hotgo服务端 -待写。 +# 编译web端 +cd web +yarn build + +# web端编译完成后,将web/dist/*中的文件上传到`server`端线上运行目录:/resource/public/admin即可 +# 至此,web端和server端都可以独立覆盖更新 +``` ### 修改生产配置文件 - 配置文件:server/manifest/config/config.yaml -> 如关闭代码生成功能、修改数据库地址、缓存驱动、队列驱动、日志路径等 +> 如关闭debug、mode设为生产环境、修改数据库地址、缓存驱动、队列驱动、日志路径等 diff --git a/docs/guide-zh-CN/start-issue.md b/docs/guide-zh-CN/start-issue.md index 1298bb4..8f6e272 100644 --- a/docs/guide-zh-CN/start-issue.md +++ b/docs/guide-zh-CN/start-issue.md @@ -13,6 +13,9 @@ 线上或非本地运行时,请到 系统设置 -> 配置管理 -> 基本设置 -> 找到网站域名和websocket地址,改成你自己实际的地址,保存刷新页面即可 +#### 2、web页面菜单切换后页面出现白屏 + +请参考:https://github.com/jekip/naive-ui-admin/issues/183 ### 二、数据库相关 @@ -29,7 +32,17 @@ > 报错信息:panic: possible config files "config" or "config.toml/yaml/yml/json/ini/xml/properties" not found in resource manager or following system searching paths: -这是因为系统没有找到配置文件,将配置文件 `manifest/config/config.yaml.bak` 复制后改为`manifest/config/config.yaml` +系统没有找到配置文件,将配置文件 `manifest/config/config.yaml.bak` 复制后改为`manifest/config/config.yaml` + + +#### 2、net.DialTimeout failed with network + +> 报错信息:connect to 127.0.0.1:8099 error: net.DialTimeout failed with network "tcp", address "127.0.0.1:8099", timeout "10s": dial tcp + +- http服务没有启动或正在启动 +- 通过一键启动所有服务运行时属正常情况,多服务启动时存在先后顺序问题,`tcpClient`比`tcpServer`先启动完成导致的,等`tcpServer`启动完成后会自动重连 + + 详细请参考 - [系统安装](start-installation.md) diff --git a/docs/guide-zh-CN/start-update-log.md b/docs/guide-zh-CN/start-update-log.md index 506e74e..05044a8 100644 --- a/docs/guide-zh-CN/start-update-log.md +++ b/docs/guide-zh-CN/start-update-log.md @@ -11,6 +11,26 @@ > 如果升级(覆盖)代码后打开会出现 sql 报错, 请检查更新的数据库格式或自行调整 +### v2.11.5 +updated 2023.11.25 + +- 增加`minio`上传驱动支持 +- 增加定时任务调度日志,增加同方法多任务支持 +- 增加gf运行模式控制,生产环境时隐藏开发相关菜单 +- 增加树形表格新增/修改自动维护上下级关系通用处理 +- 增加树形表格使用例子 +- 优化:gf版本升级到v2.5.7 +- 优化`websocket`默认路径配置 +- 优化预处理中间件错误码跟随 +- 优化插件静态目录为可选项 +- 修复升级gf版本后服务日志记录内容为空问题 +- 修复角色权限选择数据重复问题 +- 修复服务日志无日志内容问题 +- 修复用户批量删除可以删除超管问题 +- 修复代码生成时偶尔找不到主键索引问题 +- 修复树形选项组件在`BasicForm`无法使用问题 +- 修复表格批量删除重复传参问题 +- 修复文件缓存`GetOrSet`和`GetOrSetFunc`缓存过期不刷新问题 ### v2.9.8 updated 2023.10.21 @@ -19,8 +39,6 @@ updated 2023.10.21 - 优化:优化代码生成表单滑动 - 优化:优化字典列表编辑生效时机 - 修复:修复日期组件默认值无效问题 -- 修复:修复配置参数`exceptLogin`命名 - ### v2.9.3 updated 2023.10.08 diff --git a/docs/guide-zh-CN/sys-cron.md b/docs/guide-zh-CN/sys-cron.md index 10835d7..8f5695d 100644 --- a/docs/guide-zh-CN/sys-cron.md +++ b/docs/guide-zh-CN/sys-cron.md @@ -17,8 +17,8 @@ type Cron interface { // GetName 获取任务名称 GetName() string - // Execute 执行一次任务 - Execute(ctx context.Context) + // Execute 执行任务 + Execute(ctx context.Context, parser *Parser) (err error) } ``` @@ -54,11 +54,10 @@ func (c *cTest) GetName() string { } // Execute 执行任务 -func (c *cTest) Execute(ctx context.Context) { - cron.Logger().Infof(ctx, "cron test Execute:%v", time.Now()) +func (c *cTest) Execute(ctx context.Context, parser *cron.Parser) (err error) { + parser.Logger.Infof(ctx, "cron test Execute:%v", time.Now()) // 记录任务调度日志 + return } - - ``` 继续在后台系统设置-定时任务-添加任务,填写的任务名称需要和上面的名称保持一致,再进行简单的策略配置以后,一个后台可控的定时任务就添加好了! diff --git a/server/.gitignore b/server/.gitignore index c3d01b4..4fbb0ad 100644 --- a/server/.gitignore +++ b/server/.gitignore @@ -26,6 +26,7 @@ storage/cert/ssl/server.key storage/cert/pay/alipay/ storage/cert/pay/wxpay/ temp/ +logs/ main.exe main.exe~ *.exe diff --git a/server/addons/hgexample/README.MD b/server/addons/hgexample/README.MD index ae0adeb..5d34f22 100644 --- a/server/addons/hgexample/README.MD +++ b/server/addons/hgexample/README.MD @@ -12,7 +12,7 @@ ### 安装 -1、安装 HotGo (2.1.4及以上) +1、安装 HotGo (2.11.4及以上) 项目介绍:https://github.com/bufanyun/hotgo diff --git a/server/addons/hgexample/api/admin/treetable/treetable.go b/server/addons/hgexample/api/admin/treetable/treetable.go new file mode 100644 index 0000000..93ebc3d --- /dev/null +++ b/server/addons/hgexample/api/admin/treetable/treetable.go @@ -0,0 +1,92 @@ +// Package treetable +// @Link https://github.com/bufanyun/hotgo +// @Copyright Copyright (c) 2023 HotGo CLI +// @Author Ms <133814250@qq.com> +// @License https://github.com/bufanyun/hotgo/blob/master/LICENSE +package treetable + +import ( + "github.com/gogf/gf/v2/frame/g" + "hotgo/addons/hgexample/model/input/sysin" + "hotgo/internal/model/input/form" +) + +// ListReq 查询列表 +type ListReq struct { + g.Meta `path:"/treeTable/list" method:"get" tags:"表格" summary:"获取表格列表"` + sysin.TreeTableListInp +} + +type ListRes struct { + form.PageRes + List []*sysin.TreeTableListModel `json:"list" dc:"数据列表"` +} + +// ExportReq 导出列表 +type ExportReq struct { + g.Meta `path:"/treeTable/export" method:"get" tags:"表格" summary:"导出表格列表"` + sysin.TableListInp +} + +type ExportRes struct{} + +// ViewReq 获取信息 +type ViewReq struct { + g.Meta `path:"/treeTable/view" method:"get" tags:"表格" summary:"获取指定信息"` + sysin.TableViewInp +} + +type ViewRes struct { + *sysin.TableViewModel +} + +// EditReq 修改/新增 +type EditReq struct { + g.Meta `path:"/treeTable/edit" method:"post" tags:"表格" summary:"修改/新增表格"` + sysin.TableEditInp +} + +type EditRes struct{} + +// DeleteReq 删除 +type DeleteReq struct { + g.Meta `path:"/treeTable/delete" method:"post" tags:"表格" summary:"删除表格"` + sysin.TableDeleteInp +} + +type DeleteRes struct{} + +// MaxSortReq 最大排序 +type MaxSortReq struct { + g.Meta `path:"/treeTable/maxSort" method:"get" tags:"表格" summary:"表格最大排序"` + sysin.TableMaxSortInp +} + +type MaxSortRes struct { + *sysin.TableMaxSortModel +} + +// StatusReq 更新状态 +type StatusReq struct { + g.Meta `path:"/treeTable/status" method:"post" tags:"表格" summary:"更新表格状态"` + sysin.TableStatusInp +} + +type StatusRes struct{} + +// SwitchReq 更新开关状态 +type SwitchReq struct { + g.Meta `path:"/treeTable/switch" method:"post" tags:"表格" summary:"更新表格状态"` + sysin.TableSwitchInp +} + +type SwitchRes struct{} + +// SelectReq 树形选项 +type SelectReq struct { + g.Meta `path:"/treeTable/select" method:"get" tags:"表格" summary:"树形选项"` +} + +type SelectRes struct { + List []*sysin.TableTree `json:"list" dc:"数据列表"` +} diff --git a/server/addons/hgexample/controller/admin/sys/tree_table.go b/server/addons/hgexample/controller/admin/sys/tree_table.go new file mode 100644 index 0000000..0d2dd86 --- /dev/null +++ b/server/addons/hgexample/controller/admin/sys/tree_table.go @@ -0,0 +1,92 @@ +// Package sys +// @Link https://github.com/bufanyun/hotgo +// @Copyright Copyright (c) 2023 HotGo CLI +// @Author Ms <133814250@qq.com> +// @License https://github.com/bufanyun/hotgo/blob/master/LICENSE +package sys + +import ( + "context" + "hotgo/addons/hgexample/api/admin/treetable" + "hotgo/addons/hgexample/service" +) + +var ( + TreeTable = cTreeTable{} +) + +type cTreeTable struct{} + +// List 查看列表 +func (c *cTreeTable) List(ctx context.Context, req *treetable.ListReq) (res *treetable.ListRes, err error) { + list, totalCount, err := service.SysTreeTable().List(ctx, &req.TreeTableListInp) + if err != nil { + return + } + + res = new(treetable.ListRes) + res.List = list + res.PageRes.Pack(req, totalCount) + return +} + +// Export 导出列表 +func (c *cTreeTable) Export(ctx context.Context, req *treetable.ExportReq) (res *treetable.ExportRes, err error) { + err = service.SysTable().Export(ctx, &req.TableListInp) + return +} + +// Edit 更新 +func (c *cTreeTable) Edit(ctx context.Context, req *treetable.EditReq) (res *treetable.EditRes, err error) { + err = service.SysTreeTable().Edit(ctx, &req.TableEditInp) + return +} + +// MaxSort 最大排序 +func (c *cTreeTable) MaxSort(ctx context.Context, req *treetable.MaxSortReq) (res *treetable.MaxSortRes, err error) { + data, err := service.SysTable().MaxSort(ctx, &req.TableMaxSortInp) + if err != nil { + return + } + + res = new(treetable.MaxSortRes) + res.TableMaxSortModel = data + return +} + +// View 获取指定信息 +func (c *cTreeTable) View(ctx context.Context, req *treetable.ViewReq) (res *treetable.ViewRes, err error) { + data, err := service.SysTable().View(ctx, &req.TableViewInp) + if err != nil { + return + } + + res = new(treetable.ViewRes) + res.TableViewModel = data + return +} + +// Delete 删除 +func (c *cTreeTable) Delete(ctx context.Context, req *treetable.DeleteReq) (res *treetable.DeleteRes, err error) { + err = service.SysTreeTable().Delete(ctx, &req.TableDeleteInp) + return +} + +// Status 更新状态 +func (c *cTreeTable) Status(ctx context.Context, req *treetable.StatusReq) (res *treetable.StatusRes, err error) { + err = service.SysTable().Status(ctx, &req.TableStatusInp) + return +} + +// Switch 更新开关状态 +func (c *cTreeTable) Switch(ctx context.Context, req *treetable.SwitchReq) (res *treetable.SwitchRes, err error) { + err = service.SysTable().Switch(ctx, &req.TableSwitchInp) + return +} + +// Select 树形选项 +func (c *cTreeTable) Select(ctx context.Context, _ *treetable.SelectReq) (res *treetable.SelectRes, err error) { + res = new(treetable.SelectRes) + res.List, err = service.SysTreeTable().Select(ctx) + return +} diff --git a/server/addons/hgexample/logic/logic.go b/server/addons/hgexample/logic/logic.go index cc557f4..bd978f2 100644 --- a/server/addons/hgexample/logic/logic.go +++ b/server/addons/hgexample/logic/logic.go @@ -1,5 +1,5 @@ // ========================================================================== -// Code generated by GoFrame CLI tool. DO NOT EDIT. +// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT. // ========================================================================== package logic diff --git a/server/addons/hgexample/logic/sys/tree_table.go b/server/addons/hgexample/logic/sys/tree_table.go new file mode 100644 index 0000000..b2f417b --- /dev/null +++ b/server/addons/hgexample/logic/sys/tree_table.go @@ -0,0 +1,186 @@ +// Package sys +// @Link https://github.com/bufanyun/hotgo +// @Copyright Copyright (c) 2023 HotGo CLI +// @Author Ms <133814250@qq.com> +// @License https://github.com/bufanyun/hotgo/blob/master/LICENSE +package sys + +import ( + "context" + "fmt" + "github.com/gogf/gf/v2/database/gdb" + "github.com/gogf/gf/v2/errors/gerror" + "github.com/gogf/gf/v2/frame/g" + "hotgo/addons/hgexample/model/input/sysin" + "hotgo/addons/hgexample/service" + "hotgo/internal/consts" + "hotgo/internal/dao" + "hotgo/internal/library/contexts" + "hotgo/internal/library/hgorm" + "hotgo/internal/library/hgorm/handler" + "hotgo/internal/model/entity" +) + +type sSysTreeTable struct{} + +func NewSysTreeTable() *sSysTreeTable { + return &sSysTreeTable{} +} + +func init() { + service.RegisterSysTreeTable(NewSysTreeTable()) +} + +// Model Orm模型 +func (s *sSysTreeTable) Model(ctx context.Context, option ...*handler.Option) *gdb.Model { + return handler.Model(dao.AddonHgexampleTable.Ctx(ctx), option...) +} + +// List 获取列表 +func (s *sSysTreeTable) List(ctx context.Context, in *sysin.TreeTableListInp) (list []*sysin.TreeTableListModel, totalCount int, err error) { + mod := s.Model(ctx) + cols := dao.AddonHgexampleTable.Columns() + + if in.Title != "" { + mod = mod.WhereLike(cols.Title, "%"+in.Title+"%") + } + + if in.Content != "" { + mod = mod.WhereLike(cols.Content, "%"+in.Content+"%") + } + + if in.Status > 0 { + mod = mod.Where(cols.Status, in.Status) + } + + if in.Switch > 0 { + mod = mod.Where(cols.Switch, in.Switch) + } + + if in.Pid > 0 { + mod = mod.Where(cols.Pid, in.Pid) + } + + if len(in.Price) > 0 { + if in.Price[0] > 0 && in.Price[1] > 0 { + mod = mod.WhereBetween(cols.Price, in.Price[0], in.Price[1]) + } else if in.Price[0] > 0 && in.Price[1] == 0 { + mod = mod.WhereGTE(cols.Price, in.Price[0]) + } else if in.Price[0] == 0 && in.Price[1] > 0 { + mod = mod.WhereLTE(cols.Price, in.Price[1]) + } + } + + if in.ActivityAt != nil { + mod = mod.Where(cols.ActivityAt, in.ActivityAt) + } + + if len(in.CreatedAt) == 2 { + mod = mod.WhereBetween(cols.CreatedAt, in.CreatedAt[0], in.CreatedAt[1]) + } + + if !in.Flag.IsNil() { + mod = mod.Where(fmt.Sprintf(`JSON_CONTAINS(%s,'%v')`, cols.Flag, in.Flag)) + } + + if !in.Hobby.IsNil() { + mod = mod.Where(fmt.Sprintf(`JSON_CONTAINS(%s,'%v')`, cols.Hobby, in.Hobby)) + } + + totalCount, err = mod.Clone().Count(1) + if err != nil { + err = gerror.Wrap(err, "获取表格数据行失败,请稍后重试!") + return + } + + if totalCount == 0 { + return + } + + if err = mod.Fields(sysin.TableListModel{}).Page(in.Page, in.PerPage).Handler(handler.Sorter(in)).Scan(&list); err != nil { + err = gerror.Wrap(err, "获取表格列表失败,请稍后重试!") + return + } + return +} + +// Edit 修改/新增 +func (s *sSysTreeTable) Edit(ctx context.Context, in *sysin.TableEditInp) (err error) { + cols := dao.AddonHgexampleTable.Columns() + if err = hgorm.IsUnique(ctx, &dao.AddonHgexampleTable, g.Map{cols.Qq: in.Qq}, "QQ号码已存在,请换一个", in.Id); err != nil { + return + } + + return g.DB().Transaction(ctx, func(ctx context.Context, tx gdb.TX) (err error) { + in.Pid, in.Level, in.Tree, err = hgorm.AutoUpdateTree(ctx, &dao.AddonHgexampleTable, in.Id, in.Pid) + if err != nil { + return err + } + + if in.Id > 0 { + in.UpdatedBy = contexts.GetUserId(ctx) + if _, err = s.Model(ctx).WherePri(in.Id).Data(in).Update(); err != nil { + err = gerror.Wrap(err, "修改表格失败,请稍后重试!") + return err + } + } else { + in.CreatedBy = contexts.GetUserId(ctx) + if _, err = s.Model(ctx, &handler.Option{FilterAuth: false}).Data(in).Insert(); err != nil { + err = gerror.Wrap(err, "新增表格失败,请稍后重试!") + return err + } + } + return + }) +} + +// Delete 删除 +func (s *sSysTreeTable) Delete(ctx context.Context, in *sysin.TableDeleteInp) (err error) { + count, err := dao.AdminMenu.Ctx(ctx).Where("pid", in.Id).Count() + if err != nil { + err = gerror.Wrap(err, consts.ErrorORM) + return err + } + if count > 0 { + return gerror.New("请先删除该表格下的所有下级!") + } + + if _, err = s.Model(ctx).WherePri(in.Id).Delete(); err != nil { + err = gerror.Wrap(err, "删除表格失败,请稍后重试!") + return + } + return +} + +// Select 关系树选项列表 +func (s *sSysTreeTable) Select(ctx context.Context) (list []*sysin.TableTree, err error) { + var models []*entity.AddonHgexampleTable + if err = dao.AddonHgexampleTable.Ctx(ctx).Order("pid asc,id asc,sort asc").Scan(&models); err != nil { + err = gerror.Wrap(err, "获取关系树选项列表失败!") + return + } + + list = s.treeList(0, models) + return +} + +// treeList 树状列表 +func (s *sSysTreeTable) treeList(pid int64, nodes []*entity.AddonHgexampleTable) (list []*sysin.TableTree) { + list = make([]*sysin.TableTree, 0) + for _, v := range nodes { + if v.Pid == pid { + item := new(sysin.TableTree) + item.AddonHgexampleTable = *v + item.Label = v.Title + item.Value = v.Id + item.Key = v.Id + + child := s.treeList(v.Id, nodes) + if len(child) > 0 { + item.Children = child + } + list = append(list, item) + } + } + return +} diff --git a/server/addons/hgexample/model/input/sysin/tree_table.go b/server/addons/hgexample/model/input/sysin/tree_table.go new file mode 100644 index 0000000..02702c4 --- /dev/null +++ b/server/addons/hgexample/model/input/sysin/tree_table.go @@ -0,0 +1,47 @@ +// Package sysin +// @Link https://github.com/bufanyun/hotgo +// @Copyright Copyright (c) 2023 HotGo CLI +// @Author Ms <133814250@qq.com> +// @License https://github.com/bufanyun/hotgo/blob/master/LICENSE +package sysin + +import ( + "github.com/gogf/gf/v2/encoding/gjson" + "github.com/gogf/gf/v2/os/gtime" + "hotgo/internal/model/entity" + "hotgo/internal/model/input/form" +) + +// TreeTableListInp 获取列表 +type TreeTableListInp struct { + form.PageReq + form.Sorters + Id int64 `json:"id" description:""` + Flag *gjson.Json `json:"flag" description:"标签"` + Title string `json:"title" description:"标题"` + Content string `json:"content" description:"内容"` + Price []float64 `json:"price" description:"价格"` + ActivityAt *gtime.Time `json:"activityAt" description:"活动时间"` + Switch int `json:"switch" description:"开关"` + Hobby *gjson.Json `json:"hobby" description:"爱好"` + Status int `json:"status" description:"状态"` + CreatedAt []*gtime.Time `json:"createdAt" description:"创建时间"` + Pid int64 `json:"pid" description:"上级ID"` +} + +type TreeTableListModel struct { + entity.AddonHgexampleTable + TableCategoryName string `json:"TableCategoryName" description:"分类名称"` + TableCategoryDescription string `json:"TableCategoryDescription" description:"分类描述"` + TableCategoryRemark string `json:"TableCategoryRemark" description:"分类备注"` + SysProvincesTitle string `json:"sysProvincesTitle" description:""` +} + +// TableTree 树 +type TableTree struct { + entity.AddonHgexampleTable + Key int64 `json:"key" dc:"key"` + Label string `json:"label" dc:"标签"` + Value int64 `json:"value" dc:"键值"` + Children []*TableTree `json:"children"` +} diff --git a/server/addons/hgexample/resource/public/default b/server/addons/hgexample/resource/public/default index 52e122c..06d8da4 100644 --- a/server/addons/hgexample/resource/public/default +++ b/server/addons/hgexample/resource/public/default @@ -1 +1 @@ -Hello!这是创建插件 [功能案例] 时默认生成的一个静态目录文件,用于测试,当你看到这个提示时,说明已经联调成功啦! +Hello!这是创建插件 [功能案例] 时默认生成的一个静态目录文件,用于测试,当你看到这个提示时,说明已经联调成功啦! diff --git a/server/addons/hgexample/router/admin.go b/server/addons/hgexample/router/admin.go index 66620d9..33ae705 100644 --- a/server/addons/hgexample/router/admin.go +++ b/server/addons/hgexample/router/admin.go @@ -26,6 +26,7 @@ func Admin(ctx context.Context, group *ghttp.RouterGroup) { group.Bind( sys.Config, sys.Table, + sys.TreeTable, ) }) diff --git a/server/addons/hgexample/service/sys.go b/server/addons/hgexample/service/sys.go index b26e867..b0eb4c7 100644 --- a/server/addons/hgexample/service/sys.go +++ b/server/addons/hgexample/service/sys.go @@ -1,5 +1,5 @@ // ================================================================================ -// Code generated by GoFrame CLI tool. DO NOT EDIT. +// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT. // You can delete these comments if you wish manually maintain this interface file. // ================================================================================ @@ -16,30 +16,56 @@ import ( type ( ISysConfig interface { + // GetBasic 获取基础配置 GetBasic(ctx context.Context) (conf *model.BasicConfig, err error) + // GetConfigByGroup 获取指定分组配置 GetConfigByGroup(ctx context.Context, in *sysin.GetConfigInp) (res *sysin.GetConfigModel, err error) + // UpdateConfigByGroup 更新指定分组的配置 UpdateConfigByGroup(ctx context.Context, in *sysin.UpdateConfigInp) error } ISysIndex interface { + // Test 测试 Test(ctx context.Context, in *sysin.IndexTestInp) (res *sysin.IndexTestModel, err error) } ISysTable interface { + // Model Orm模型 Model(ctx context.Context, option ...*handler.Option) *gdb.Model + // List 获取列表 List(ctx context.Context, in *sysin.TableListInp) (list []*sysin.TableListModel, totalCount int, err error) + // Export 导出 Export(ctx context.Context, in *sysin.TableListInp) (err error) + // Edit 修改/新增 Edit(ctx context.Context, in *sysin.TableEditInp) (err error) + // Delete 删除 Delete(ctx context.Context, in *sysin.TableDeleteInp) (err error) + // Status 更新状态 Status(ctx context.Context, in *sysin.TableStatusInp) (err error) + // Switch 更新开关状态 Switch(ctx context.Context, in *sysin.TableSwitchInp) (err error) + // MaxSort 最大排序 MaxSort(ctx context.Context, in *sysin.TableMaxSortInp) (res *sysin.TableMaxSortModel, err error) + // View 获取指定信息 View(ctx context.Context, in *sysin.TableViewInp) (res *sysin.TableViewModel, err error) } + ISysTreeTable interface { + // Model Orm模型 + Model(ctx context.Context, option ...*handler.Option) *gdb.Model + // List 获取列表 + List(ctx context.Context, in *sysin.TreeTableListInp) (list []*sysin.TreeTableListModel, totalCount int, err error) + // Edit 修改/新增 + Edit(ctx context.Context, in *sysin.TableEditInp) (err error) + // Delete 删除 + Delete(ctx context.Context, in *sysin.TableDeleteInp) (err error) + // Select 关系树选项列表 + Select(ctx context.Context) (list []*sysin.TableTree, err error) + } ) var ( - localSysConfig ISysConfig - localSysIndex ISysIndex - localSysTable ISysTable + localSysConfig ISysConfig + localSysIndex ISysIndex + localSysTable ISysTable + localSysTreeTable ISysTreeTable ) func SysConfig() ISysConfig { @@ -74,3 +100,14 @@ func SysTable() ISysTable { func RegisterSysTable(i ISysTable) { localSysTable = i } + +func SysTreeTable() ISysTreeTable { + if localSysTreeTable == nil { + panic("implement not found for interface ISysTreeTable, forgot register?") + } + return localSysTreeTable +} + +func RegisterSysTreeTable(i ISysTreeTable) { + localSysTreeTable = i +} diff --git a/server/api/admin/common/site.go b/server/api/admin/common/site.go index e5d3a48..63eabd7 100644 --- a/server/api/admin/common/site.go +++ b/server/api/admin/common/site.go @@ -67,6 +67,7 @@ type SiteConfigRes struct { Version string `json:"version" dc:"系统版本"` WsAddr string `json:"wsAddr" dc:"客户端websocket地址"` Domain string `json:"domain" dc:"对外域名"` + Mode string `json:"mode" dc:"运行模式"` } // SiteLoginConfigReq 获取登录配置 diff --git a/server/api/admin/cron/cron.go b/server/api/admin/cron/cron.go index 1721566..87f7267 100644 --- a/server/api/admin/cron/cron.go +++ b/server/api/admin/cron/cron.go @@ -81,3 +81,13 @@ type OnlineExecReq struct { type OnlineExecRes struct { *sysin.OnlineExecModel } + +// DispatchLogReq 调度日志 +type DispatchLogReq struct { + g.Meta `path:"/cron/dispatchLog" method:"post" tags:"定时任务" summary:"调度日志"` + sysin.DispatchLogInp +} + +type DispatchLogRes struct { + *sysin.DispatchLogModel +} diff --git a/server/api/admin/curddemo/curddemo.go b/server/api/admin/curddemo/curddemo.go index ceb989c..69ec5d5 100644 --- a/server/api/admin/curddemo/curddemo.go +++ b/server/api/admin/curddemo/curddemo.go @@ -3,7 +3,7 @@ // @Copyright Copyright (c) 2023 HotGo CLI // @Author Ms <133814250@qq.com> // @License https://github.com/bufanyun/hotgo/blob/master/LICENSE -// @AutoGenerate Version 2.9.3 +// @AutoGenerate Version 2.11.5 package curddemo import ( diff --git a/server/api/servmsg/cron.go b/server/api/servmsg/cron.go index f5ed466..ab3eafa 100644 --- a/server/api/servmsg/cron.go +++ b/server/api/servmsg/cron.go @@ -45,3 +45,13 @@ type CronOnlineExecReq struct { type CronOnlineExecRes struct { tcp.ServerRes } + +// CronDispatchLogReq 调度日志 +type CronDispatchLogReq struct { + *sysin.DispatchLogInp +} + +type CronDispatchLogRes struct { + tcp.ServerRes + *sysin.DispatchLogModel +} diff --git a/server/go.mod b/server/go.mod index 5a0810d..2f82680 100644 --- a/server/go.mod +++ b/server/go.mod @@ -13,13 +13,14 @@ require ( github.com/casbin/casbin/v2 v2.55.0 github.com/forgoer/openssl v1.4.0 github.com/go-pay/gopay v1.5.91 - github.com/gogf/gf/contrib/drivers/mysql/v2 v2.5.5 - github.com/gogf/gf/contrib/nosql/redis/v2 v2.5.5 - github.com/gogf/gf/contrib/trace/jaeger/v2 v2.5.5 - github.com/gogf/gf/v2 v2.5.5 + github.com/gogf/gf/contrib/drivers/mysql/v2 v2.5.7 + github.com/gogf/gf/contrib/nosql/redis/v2 v2.5.7 + github.com/gogf/gf/contrib/trace/jaeger/v2 v2.5.7 + github.com/gogf/gf/v2 v2.5.7 github.com/golang-jwt/jwt/v5 v5.0.0 - github.com/gorilla/websocket v1.5.0 + github.com/gorilla/websocket v1.5.1 github.com/kayon/iploc v0.0.0-20200312105652-bda3e968a794 + github.com/minio/minio-go/v7 v7.0.63 github.com/minio/selfupdate v0.6.0 github.com/mojocn/base64Captcha v1.3.5 github.com/olekukonko/tablewriter v0.0.5 @@ -28,10 +29,10 @@ require ( github.com/silenceper/wechat/v2 v2.1.4 github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.633 github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/sms v1.0.633 - github.com/tencentyun/cos-go-sdk-v5 v0.7.41 + github.com/tencentyun/cos-go-sdk-v5 v0.7.45 github.com/ufilesdk-dev/ufile-gosdk v1.0.3 github.com/xuri/excelize/v2 v2.6.0 - go.opentelemetry.io/otel v1.19.0 + go.opentelemetry.io/otel v1.21.0 golang.org/x/mod v0.9.0 golang.org/x/tools v0.7.0 gopkg.in/yaml.v3 v3.0.1 @@ -54,14 +55,15 @@ require ( github.com/clbanning/mxj/v2 v2.7.0 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f // indirect + github.com/dustin/go-humanize v1.0.1 // indirect github.com/eapache/go-resiliency v1.2.0 // indirect github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21 // indirect github.com/eapache/queue v1.1.0 // indirect github.com/emirpasic/gods v1.12.0 // indirect - github.com/fatih/color v1.15.0 // indirect + github.com/fatih/color v1.16.0 // indirect github.com/fatih/structs v1.1.0 // indirect - github.com/fsnotify/fsnotify v1.6.0 // indirect - github.com/go-logr/logr v1.2.4 // indirect + github.com/fsnotify/fsnotify v1.7.0 // indirect + github.com/go-logr/logr v1.3.0 // indirect github.com/go-logr/stdr v1.2.2 // indirect github.com/go-ole/go-ole v1.2.6 // indirect github.com/go-redis/redis/v8 v8.11.5 // indirect @@ -72,7 +74,7 @@ require ( github.com/google/btree v1.1.2 // indirect github.com/google/go-querystring v1.0.0 // indirect github.com/google/uuid v1.3.0 // indirect - github.com/grokify/html-strip-tags-go v0.0.1 // indirect + github.com/grokify/html-strip-tags-go v0.1.0 // indirect github.com/hashicorp/errwrap v1.0.0 // indirect github.com/hashicorp/go-multierror v1.1.1 // indirect github.com/hashicorp/go-uuid v1.0.2 // indirect @@ -82,27 +84,31 @@ require ( github.com/jcmturner/gokrb5/v8 v8.4.2 // indirect github.com/jcmturner/rpc/v2 v2.0.3 // indirect github.com/json-iterator/go v1.1.12 // indirect - github.com/klauspost/compress v1.15.6 // indirect + github.com/klauspost/compress v1.17.2 // indirect + github.com/klauspost/cpuid/v2 v2.2.5 // indirect github.com/lufia/plan9stats v0.0.0-20211012122336-39d0f177ccd0 // indirect github.com/magiconair/properties v1.8.7 // indirect github.com/mattn/go-colorable v0.1.13 // indirect github.com/mattn/go-isatty v0.0.20 // indirect github.com/mattn/go-runewidth v0.0.15 // indirect + github.com/minio/md5-simd v1.1.2 // indirect + github.com/minio/sha256-simd v1.0.1 // indirect github.com/mitchellh/mapstructure v1.4.3 // indirect github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/modern-go/reflect2 v1.0.2 // indirect github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826 // indirect github.com/mozillazg/go-httpheader v0.2.1 // indirect - github.com/pierrec/lz4/v4 v4.1.14 // indirect + github.com/pierrec/lz4/v4 v4.1.18 // indirect github.com/pkg/errors v0.9.1 // indirect github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c // indirect github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect - github.com/redis/go-redis/v9 v9.2.1 // indirect + github.com/redis/go-redis/v9 v9.3.0 // indirect github.com/richardlehane/mscfb v1.0.4 // indirect github.com/richardlehane/msoleps v1.0.1 // indirect github.com/rivo/uniseg v0.4.4 // indirect + github.com/rs/xid v1.5.0 // indirect github.com/shoenig/go-m1cpu v0.1.4 // indirect - github.com/sirupsen/logrus v1.9.0 // indirect + github.com/sirupsen/logrus v1.9.3 // indirect github.com/spf13/cast v1.4.1 // indirect github.com/tidwall/gjson v1.14.1 // indirect github.com/tidwall/match v1.1.1 // indirect @@ -114,17 +120,17 @@ require ( github.com/xuri/nfp v0.0.0-20220409054826-5e722a1d9e22 // indirect github.com/yusufpapurcu/wmi v1.2.2 // indirect go.opentelemetry.io/otel/exporters/jaeger v1.17.0 // indirect - go.opentelemetry.io/otel/metric v1.19.0 // indirect - go.opentelemetry.io/otel/sdk v1.19.0 // indirect - go.opentelemetry.io/otel/trace v1.19.0 // indirect + go.opentelemetry.io/otel/metric v1.21.0 // indirect + go.opentelemetry.io/otel/sdk v1.21.0 // indirect + go.opentelemetry.io/otel/trace v1.21.0 // indirect go.uber.org/atomic v1.7.0 // indirect - golang.org/x/crypto v0.14.0 // indirect + golang.org/x/crypto v0.15.0 // indirect golang.org/x/image v0.1.0 // indirect - golang.org/x/net v0.17.0 // indirect + golang.org/x/net v0.18.0 // indirect golang.org/x/sync v0.1.0 // indirect - golang.org/x/sys v0.13.0 // indirect - golang.org/x/text v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect + golang.org/x/text v0.14.0 // indirect golang.org/x/time v0.0.0-20191024005414-555d28b269f0 // indirect - gopkg.in/ini.v1 v1.56.0 // indirect + gopkg.in/ini.v1 v1.67.0 // indirect stathat.com/c/consistent v1.0.0 // indirect ) diff --git a/server/go.sum b/server/go.sum index e7d4b91..e9edc19 100644 --- a/server/go.sum +++ b/server/go.sum @@ -111,8 +111,11 @@ github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ3 github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f h1:lO4WD4F/rVNCu3HqELle0jiPLLBs70cWOduZpkS1E78= github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f/go.mod h1:cuUVRXasLTGF7a8hSLbxyZXjz+1KgoB3wDUb6vlszIc= +github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkpeCY= +github.com/dustin/go-humanize v1.0.1/go.mod h1:Mu1zIs6XwVuF/gI1OepvI0qD18qycQx+mFykh5fBlto= github.com/eapache/go-resiliency v1.2.0 h1:v7g92e/KSN71Rq7vSThKaWIq68fL4YHvWyiUKorFR1Q= github.com/eapache/go-resiliency v1.2.0/go.mod h1:kFI+JgMyC7bLPUVY133qvEBtVayf5mFgVsvEsIPBvNs= github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21 h1:YEetp8/yCZMuEPMUDHG0CW/brkkEp8mzqk2+ODEitlw= @@ -125,8 +128,8 @@ github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymF github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= -github.com/fatih/color v1.15.0 h1:kOqh6YHBtK8aywxGerMG2Eq3H6Qgoqeo13Bk2Mv/nBs= -github.com/fatih/color v1.15.0/go.mod h1:0h5ZqXfHYED7Bhv2ZJamyIOUej9KtShiJESRwBDUSsw= +github.com/fatih/color v1.16.0 h1:zmkK9Ngbjj+K0yRhTVONQh1p/HknKYSlNT+vZCzyokM= +github.com/fatih/color v1.16.0/go.mod h1:fL2Sau1YI5c0pdGEVCbKQbLXB6edEj1ZgiY4NijnWvE= github.com/fatih/structs v1.1.0 h1:Q7juDM0QtcnhCpeyLGQKyg4TOIghuNXrkL32pHAUMxo= github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M= github.com/forgoer/openssl v1.4.0 h1:rPMnQ92OKuBsKnfY/GmUDunnP72Cy+zviAompWMdC9U= @@ -135,8 +138,8 @@ github.com/fortytw2/leaktest v1.3.0 h1:u8491cBMTQ8ft8aeV+adlcytMZylmA5nnwwkRZjI8 github.com/fortytw2/leaktest v1.3.0/go.mod h1:jDsjWgpAGjm2CA7WthBh/CdZYEPF31XHquHwclZch5g= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= -github.com/fsnotify/fsnotify v1.6.0 h1:n+5WquG0fcWoWp6xPWfHdbskMCQaFnG6PfBrh1Ky4HY= -github.com/fsnotify/fsnotify v1.6.0/go.mod h1:sl3t1tCWJFWoRz9R8WJCbQihKKwmorjAbSClcnxKAGw= +github.com/fsnotify/fsnotify v1.7.0 h1:8JEhPFa5W2WU7YfeZzPNqzMP6Lwt7L2715Ggo0nosvA= +github.com/fsnotify/fsnotify v1.7.0/go.mod h1:40Bi/Hjc2AVfZrqy+aj+yEI+/bRxZnMJyTJwOpGvigM= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= @@ -147,8 +150,8 @@ github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9 github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= -github.com/go-logr/logr v1.2.4 h1:g01GSCwiDw2xSZfjJ2/T9M+S6pFdcNtFYsp+Y43HYDQ= -github.com/go-logr/logr v1.2.4/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= +github.com/go-logr/logr v1.3.0 h1:2y3SDp0ZXuc6/cjLSZ+Q3ir+QB9T/iG5yYRXqsagWSY= +github.com/go-logr/logr v1.3.0/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-ole/go-ole v1.2.6 h1:/Fpf6oFPoeFik9ty7siob0G6Ke8QvQEuVcuChpwXzpY= @@ -167,14 +170,14 @@ github.com/go-sql-driver/mysql v1.7.1 h1:lUIinVbN1DY0xBg0eMOzmmtGoHwWBbvnWubQUrt github.com/go-sql-driver/mysql v1.7.1/go.mod h1:OXbVy3sEdcQ2Doequ6Z5BW6fXNQTmx+9S1MCJN5yJMI= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE= -github.com/gogf/gf/contrib/drivers/mysql/v2 v2.5.5 h1:P1dJmEhyEVVkSXbeP8ge2jxA2lZrch2cZCSOxgTT0X8= -github.com/gogf/gf/contrib/drivers/mysql/v2 v2.5.5/go.mod h1:R6tDeHWP3kpApZtOrVbj/tP7dtwcFHmhFFqnIlQh+yU= -github.com/gogf/gf/contrib/nosql/redis/v2 v2.5.5 h1:c8cv5EQdGHFYAms+7DCHg5p1LLrP2au1eMmfPcuB79o= -github.com/gogf/gf/contrib/nosql/redis/v2 v2.5.5/go.mod h1:2aENeWXI1LRl1cmGmByEn12FlfC2t5PchYvNUTHRIJs= -github.com/gogf/gf/contrib/trace/jaeger/v2 v2.5.5 h1:T9ZQoCqJJq6dIPaTMSuftjtXR7rs3crpPrXjCG+3xZg= -github.com/gogf/gf/contrib/trace/jaeger/v2 v2.5.5/go.mod h1:9Xw3ULCwXc7EO0ZpXAEq7ghJm6O0jc3J/fOLBCzeiZU= -github.com/gogf/gf/v2 v2.5.5 h1:av3xMltrJiZWs4lW5KUTTDh45qg3wUV33W5OebE+pYo= -github.com/gogf/gf/v2 v2.5.5/go.mod h1:17K/gBYrp0bHGC3XYC7bSPoywmZ6MrZHrZakTfh4eIQ= +github.com/gogf/gf/contrib/drivers/mysql/v2 v2.5.7 h1:S6r4QJSoqmOv/Vqhu/gHt4if4dHrNyaQIUbjWc4W7sg= +github.com/gogf/gf/contrib/drivers/mysql/v2 v2.5.7/go.mod h1:1/X4iVHxtSHjOMGYvnmFMTdk5zLLhQ6PEkslKTBcTSI= +github.com/gogf/gf/contrib/nosql/redis/v2 v2.5.7 h1:HgOudyYp8F6iVC6YgbqKhPMKgxQJj4MO8VBdJEMPTpk= +github.com/gogf/gf/contrib/nosql/redis/v2 v2.5.7/go.mod h1:jiRz86SerTb+z4KD4LtxgVw3IEcsWRBnL40FvIAg/sY= +github.com/gogf/gf/contrib/trace/jaeger/v2 v2.5.7 h1:ipIYW9q+Olkg9s86WpdPQ+wTFi1v6rsTiYAZ2ekqxH8= +github.com/gogf/gf/contrib/trace/jaeger/v2 v2.5.7/go.mod h1:KhUqGtEifCUd9pI274UkgSCMByof3aq2nW9GJRbwcOk= +github.com/gogf/gf/v2 v2.5.7 h1:h+JSoD6z3d2q0uGszvtahrSm4DiM2ECyNjyTwKIo8wE= +github.com/gogf/gf/v2 v2.5.7/go.mod h1:x2XONYcI4hRQ/4gMNbWHmZrNzSEIg20s2NULbzom5k0= github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/golang-jwt/jwt/v5 v5.0.0 h1:1n1XNM9hk7O9mnQoNBGolZvzebBQ7p93ULHRc28XJUE= github.com/golang-jwt/jwt/v5 v5.0.0/go.mod h1:pqrtFR0X4osieyHYxtmOUWsAWrfe1Q5UVIyoH402zdk= @@ -225,8 +228,8 @@ github.com/google/go-cmp v0.5.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= +github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-querystring v1.0.0 h1:Xkwi/a1rcvNg1PPYe5vI8GbeBY/jrVuDX5ASuANWTrk= github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= @@ -252,10 +255,10 @@ github.com/gopherjs/gopherjs v0.0.0-20200217142428-fce0ec30dd00/go.mod h1:wJfORR github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= github.com/gorilla/securecookie v1.1.1/go.mod h1:ra0sb63/xPlUeL+yeDciTfxMRAA+MP+HVt/4epWDjd4= github.com/gorilla/sessions v1.2.1/go.mod h1:dk2InVEVJ0sfLlnXv9EAgkf6ecYs/i80K/zI+bUmuGM= -github.com/gorilla/websocket v1.5.0 h1:PPwGk2jz7EePpoHN/+ClbZu8SPxiqlu12wZP/3sWmnc= -github.com/gorilla/websocket v1.5.0/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= -github.com/grokify/html-strip-tags-go v0.0.1 h1:0fThFwLbW7P/kOiTBs03FsJSV9RM2M/Q/MOnCQxKMo0= -github.com/grokify/html-strip-tags-go v0.0.1/go.mod h1:2Su6romC5/1VXOQMaWL2yb618ARB8iVo6/DR99A6d78= +github.com/gorilla/websocket v1.5.1 h1:gmztn0JnHVt9JZquRuzLw3g4wouNVzKL15iLr/zn/QY= +github.com/gorilla/websocket v1.5.1/go.mod h1:x3kM2JMyaluk02fnUJpQuwD2dCS5NDG2ZHL0uE0tcaY= +github.com/grokify/html-strip-tags-go v0.1.0 h1:03UrQLjAny8xci+R+qjCce/MYnpNXCtgzltlQbOBae4= +github.com/grokify/html-strip-tags-go v0.1.0/go.mod h1:ZdzgfHEzAfz9X6Xe5eBLVblWIxXfYSQ40S/VKrAOGpc= github.com/h2non/parth v0.0.0-20190131123155-b4df798d6542 h1:2VTzZjLZBgl62/EtslCrtky5vbi9dd7HrQPQIx6wqiw= github.com/h2non/parth v0.0.0-20190131123155-b4df798d6542/go.mod h1:Ow0tF8D4Kplbc8s8sSb3V2oUCygFHVp8gC3Dn6U4MNI= github.com/hashicorp/errwrap v1.0.0 h1:hLrqtEDnRye3+sgx6z4qVLNuviH3MR5aQ0ykNJa/UYA= @@ -297,8 +300,12 @@ github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8 github.com/kayon/iploc v0.0.0-20200312105652-bda3e968a794 h1:dWJxw+KQOMeVcoyxqG9I5fppPld1hh1FG8ngv0fKNsQ= github.com/kayon/iploc v0.0.0-20200312105652-bda3e968a794/go.mod h1:IwrOeG3O3K9vVXmcVvc9T0XLabw67QePi5pKQt5U+Kw= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= -github.com/klauspost/compress v1.15.6 h1:6D9PcO8QWu0JyaQ2zUMmu16T1T+zjjEpP91guRsvDfY= github.com/klauspost/compress v1.15.6/go.mod h1:PhcZ0MbTNciWF3rruxRgKxI5NkcHHrHUDtV4Yw2GlzU= +github.com/klauspost/compress v1.17.2 h1:RlWWUY/Dr4fL8qk9YG7DTZ7PDgME2V4csBXA8L/ixi4= +github.com/klauspost/compress v1.17.2/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= +github.com/klauspost/cpuid/v2 v2.0.1/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg= +github.com/klauspost/cpuid/v2 v2.2.5 h1:0E5MSMDEoAulmXNFquVs//DdoomxaoTY1kUhbc/qbZg= +github.com/klauspost/cpuid/v2 v2.2.5/go.mod h1:Lcz8mBdAVJIBVzewtcLocK12l3Y+JytZYpaMropDUws= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= @@ -324,8 +331,14 @@ github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m github.com/mattn/go-runewidth v0.0.15 h1:UNAjwbU9l54TA3KzvqLGxwWjHmMgBUVhBiTjelZgg3U= github.com/mattn/go-runewidth v0.0.15/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= +github.com/minio/md5-simd v1.1.2 h1:Gdi1DZK69+ZVMoNHRXJyNcxrMA4dSxoYHZSQbirFg34= +github.com/minio/md5-simd v1.1.2/go.mod h1:MzdKDxYpY2BT9XQFocsiZf/NKVtR7nkE4RoEpN+20RM= +github.com/minio/minio-go/v7 v7.0.63 h1:GbZ2oCvaUdgT5640WJOpyDhhDxvknAJU2/T3yurwcbQ= +github.com/minio/minio-go/v7 v7.0.63/go.mod h1:Q6X7Qjb7WMhvG65qKf4gUgA5XaiSox74kR1uAEjxRS4= github.com/minio/selfupdate v0.6.0 h1:i76PgT0K5xO9+hjzKcacQtO7+MjJ4JKA8Ak8XQ9DDwU= github.com/minio/selfupdate v0.6.0/go.mod h1:bO02GTIPCMQFTEvE5h4DjYB58bCoZ35XLeBf0buTDdM= +github.com/minio/sha256-simd v1.0.1 h1:6kaan5IFmwTNynnKKpDHe6FWHohJOHhCPchzK49dzMM= +github.com/minio/sha256-simd v1.0.1/go.mod h1:Pz6AKMiUdngCLpeTL/RJY1M9rUuPMYujV5xJjtbRSN8= github.com/mitchellh/mapstructure v1.4.3 h1:OVowDSCllw/YjdLkam3/sm7wEtOy59d8ndGgCcyj8cs= github.com/mitchellh/mapstructure v1.4.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -361,8 +374,9 @@ github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1y github.com/onsi/gomega v1.17.0/go.mod h1:HnhC7FXeEQY45zxNK3PPoIUhzk/80Xly9PcubAlGdZY= github.com/onsi/gomega v1.18.1 h1:M1GfJqGRrBrrGGsbxzV5dqM2U2ApXefZCQpkukxYRLE= github.com/onsi/gomega v1.18.1/go.mod h1:0q+aL8jAiMXy9hbwj2mr5GziHiwhAIQpFmmtT5hitRs= -github.com/pierrec/lz4/v4 v4.1.14 h1:+fL8AQEZtz/ijeNnpduH0bROTu0O3NZAlPjQxGn8LwE= github.com/pierrec/lz4/v4 v4.1.14/go.mod h1:gZWDp/Ze/IJXGXf23ltt2EXimqmTUXEy0GFuRQyBid4= +github.com/pierrec/lz4/v4 v4.1.18 h1:xaKrnTkyoqfh1YItXl56+6KJNVYWlEEPuAQW9xsplYQ= +github.com/pierrec/lz4/v4 v4.1.18/go.mod h1:gZWDp/Ze/IJXGXf23ltt2EXimqmTUXEy0GFuRQyBid4= github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= @@ -396,8 +410,8 @@ github.com/qiniu/go-sdk/v7 v7.14.0/go.mod h1:btsaOc8CA3hdVloULfFdDgDc+g4f3TDZEFs github.com/qiniu/x v1.10.5/go.mod h1:03Ni9tj+N2h2aKnAz+6N0Xfl8FwMEDRC2PAlxekASDs= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 h1:N/ElC8H3+5XpJzTSTfLsJV/mx9Q9g7kxmchpfZyxgzM= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= -github.com/redis/go-redis/v9 v9.2.1 h1:WlYJg71ODF0dVspZZCpYmoF1+U1Jjk9Rwd7pq6QmlCg= -github.com/redis/go-redis/v9 v9.2.1/go.mod h1:hdY0cQFCN4fnSYT6TkisLufl/4W5UIXyv0b/CLO2V2M= +github.com/redis/go-redis/v9 v9.3.0 h1:RiVDjmig62jIWp7Kk4XVLs0hzV6pI3PyTnnL0cnn0u0= +github.com/redis/go-redis/v9 v9.3.0/go.mod h1:hdY0cQFCN4fnSYT6TkisLufl/4W5UIXyv0b/CLO2V2M= github.com/richardlehane/mscfb v1.0.4 h1:WULscsljNPConisD5hR0+OyZjwK46Pfyr6mPu5ZawpM= github.com/richardlehane/mscfb v1.0.4/go.mod h1:YzVpcZg9czvAuhk9T+a3avCpcFPMUWm7gK3DypaEsUk= github.com/richardlehane/msoleps v1.0.1 h1:RfrALnSNXzmXLbGct/P2b4xkFz4e8Gmj/0Vj9M9xC1o= @@ -409,6 +423,8 @@ github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFR github.com/rogpeppe/go-internal v1.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc= github.com/rogpeppe/go-internal v1.8.0 h1:FCbCCtXNOY3UtUuHUYaghJg4y7Fd14rXifAYUAtL9R8= github.com/rogpeppe/go-internal v1.8.0/go.mod h1:WmiCO8CzOY8rg0OYDC4/i/2WRWAB6poM+XZ2dLUbcbE= +github.com/rs/xid v1.5.0 h1:mKX4bl4iPYJtEIxp6CYiUuLQ/8DYMoz0PUdtGgMFRVc= +github.com/rs/xid v1.5.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/shirou/gopsutil/v3 v3.23.3 h1:Syt5vVZXUDXPEXpIBt5ziWsJ4LdSAAxF4l/xZeQgSEE= github.com/shirou/gopsutil/v3 v3.23.3/go.mod h1:lSBNN6t3+D6W5e5nXTxc8KIMMVxAcS+6IJlffjRRlMU= @@ -424,8 +440,9 @@ github.com/sirupsen/logrus v1.4.1/go.mod h1:ni0Sbl8bgC9z8RoU9G6nDWqqs/fq4eDPysMB github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= github.com/sirupsen/logrus v1.8.1/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= -github.com/sirupsen/logrus v1.9.0 h1:trlNQbNUG3OdDrDil03MCb1H2o9nJ1x4/5LYw7byDE0= github.com/sirupsen/logrus v1.9.0/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= +github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ= +github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= github.com/smartystreets/assertions v1.1.0 h1:MkTeG1DMwsrdH7QtLXy5W+fUxWq+vmb6cLmyJ7aRtF0= github.com/smartystreets/assertions v1.1.0/go.mod h1:tcbTF8ujkAEcZ8TElKY+i30BzYlVhC/LOxJk7iOWnoo= @@ -450,14 +467,14 @@ github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/ github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.2/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= -github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.194/go.mod h1:7sCQWVkxcsR38nffDW057DRGk8mUjK1Ing/EFOK8s8Y= +github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.563/go.mod h1:7sCQWVkxcsR38nffDW057DRGk8mUjK1Ing/EFOK8s8Y= github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.633 h1:Yj8s35IjbgaHp4Ic9BZLVGWdN2gXBMtwYi1JJ+qYbrc= github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.633/go.mod h1:7sCQWVkxcsR38nffDW057DRGk8mUjK1Ing/EFOK8s8Y= -github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/kms v1.0.194/go.mod h1:yrBKWhChnDqNz1xuXdSbWXG56XawEq0G5j1lg4VwBD4= +github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/kms v1.0.563/go.mod h1:uom4Nvi9W+Qkom0exYiJ9VWJjXwyxtPYTkKkaLMlfE0= github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/sms v1.0.633 h1:rtgRqgZNwDD665V02y2WBtZdVc/OmMNta3CAWgcGiS8= github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/sms v1.0.633/go.mod h1:9q29WcGkZ7R0uQjoY10Tzb8A18C2cNggbq2ZC2HRXZE= -github.com/tencentyun/cos-go-sdk-v5 v0.7.41 h1:iU0Li/Np78H4SBna0ECQoF3mpgi6ImLXU+doGzPFXGc= -github.com/tencentyun/cos-go-sdk-v5 v0.7.41/go.mod h1:4dCEtLHGh8QPxHEkgq+nFaky7yZxQuYwgSJM87icDaw= +github.com/tencentyun/cos-go-sdk-v5 v0.7.45 h1:5/ZGOv846tP6+2X7w//8QjLgH2KcUK+HciFbfjWquFU= +github.com/tencentyun/cos-go-sdk-v5 v0.7.45/go.mod h1:DH9US8nB+AJXqwu/AMOrCFN1COv3dpytXuJWHgdg7kE= github.com/tidwall/gjson v1.2.1/go.mod h1:c/nTNbUr0E0OrXEhq1pwa8iEgc2DOt4ZZqAt1HtCkPA= github.com/tidwall/gjson v1.14.1 h1:iymTbGkQBhveq21bEvAQ81I0LEBork8BFe1CUZXdyuo= github.com/tidwall/gjson v1.14.1/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk= @@ -499,16 +516,16 @@ go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= -go.opentelemetry.io/otel v1.19.0 h1:MuS/TNf4/j4IXsZuJegVzI1cwut7Qc00344rgH7p8bs= -go.opentelemetry.io/otel v1.19.0/go.mod h1:i0QyjOq3UPoTzff0PJB2N66fb4S0+rSbSB15/oyH9fY= +go.opentelemetry.io/otel v1.21.0 h1:hzLeKBZEL7Okw2mGzZ0cc4k/A7Fta0uoPgaJCr8fsFc= +go.opentelemetry.io/otel v1.21.0/go.mod h1:QZzNPQPm1zLX4gZK4cMi+71eaorMSGT3A4znnUvNNEo= go.opentelemetry.io/otel/exporters/jaeger v1.17.0 h1:D7UpUy2Xc2wsi1Ras6V40q806WM07rqoCWzXu7Sqy+4= go.opentelemetry.io/otel/exporters/jaeger v1.17.0/go.mod h1:nPCqOnEH9rNLKqH/+rrUjiMzHJdV1BlpKcTwRTyKkKI= -go.opentelemetry.io/otel/metric v1.19.0 h1:aTzpGtV0ar9wlV4Sna9sdJyII5jTVJEvKETPiOKwvpE= -go.opentelemetry.io/otel/metric v1.19.0/go.mod h1:L5rUsV9kM1IxCj1MmSdS+JQAcVm319EUrDVLrt7jqt8= -go.opentelemetry.io/otel/sdk v1.19.0 h1:6USY6zH+L8uMH8L3t1enZPR3WFEmSTADlqldyHtJi3o= -go.opentelemetry.io/otel/sdk v1.19.0/go.mod h1:NedEbbS4w3C6zElbLdPJKOpJQOrGUJ+GfzpjUvI0v1A= -go.opentelemetry.io/otel/trace v1.19.0 h1:DFVQmlVbfVeOuBRrwdtaehRrWiL1JoVs9CPIQ1Dzxpg= -go.opentelemetry.io/otel/trace v1.19.0/go.mod h1:mfaSyvGyEJEI0nyV2I4qhNQnbBOUUmYZpYojqMnX2vo= +go.opentelemetry.io/otel/metric v1.21.0 h1:tlYWfeo+Bocx5kLEloTjbcDwBuELRrIFxwdQ36PlJu4= +go.opentelemetry.io/otel/metric v1.21.0/go.mod h1:o1p3CA8nNHW8j5yuQLdc1eeqEaPfzug24uvsyIEJRWM= +go.opentelemetry.io/otel/sdk v1.21.0 h1:FTt8qirL1EysG6sTQRZ5TokkU8d0ugCj8htOgThZXQ8= +go.opentelemetry.io/otel/sdk v1.21.0/go.mod h1:Nna6Yv7PWTdgJHVRD9hIYywQBRx7pbox6nwBnZIxl/E= +go.opentelemetry.io/otel/trace v1.21.0 h1:WD9i5gzvoUPuXIXH24ZNBudiarZDKuekPqi/E8fpfLc= +go.opentelemetry.io/otel/trace v1.21.0/go.mod h1:LGbsEB0f9LGjN+OZaQQ26sohbOmiMR+BaslueVtS/qQ= go.uber.org/atomic v1.5.1/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= go.uber.org/atomic v1.7.0 h1:ADUqmZGgLDDfbSL9ZmPxKTybcoEYHgpYfELNoN+7hsw= go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= @@ -528,8 +545,8 @@ golang.org/x/crypto v0.0.0-20211209193657-4570a0811e8b/go.mod h1:IxCIyHEi3zRg3s0 golang.org/x/crypto v0.0.0-20220214200702-86341886e292/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.0.0-20220408190544-5352b0902921/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/crypto v0.14.0 h1:wBqGXzWJW6m1XrIKlAH0Hs1JJ7+9KBwnIO8v66Q9cHc= -golang.org/x/crypto v0.14.0/go.mod h1:MVFd36DqK4CsrnJYDkBA3VC4m2GkXAM0PvzMCn4JQf4= +golang.org/x/crypto v0.15.0 h1:frVn1TEaCEaZcn3Tmd7Y2b5KKPaZ+I32Q2OA3kYp5TA= +golang.org/x/crypto v0.15.0/go.mod h1:4ChreQoLWfG3xLDer1WdlH5NdlQ3+mwnQq1YTKY+72g= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= @@ -607,8 +624,8 @@ golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qx golang.org/x/net v0.0.0-20220407224826-aac1ed45d8e3/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220520000938-2e3eb7b945c2/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= -golang.org/x/net v0.17.0 h1:pVaXccu2ozPjCXewfr1S7xza/zcXTity9cCdXQYSjIM= -golang.org/x/net v0.17.0/go.mod h1:NxSsAGuq816PNPmqtQdLE42eU2Fs7NoRIZrHJAlaCOE= +golang.org/x/net v0.18.0 h1:mIYleuAkSbHh0tCv7RvjL3F6ZVbLjq4+R7zbOn3Kokg= +golang.org/x/net v0.18.0/go.mod h1:/czyP5RqHAH4odGYxBJ1qz0+CE5WZ+2j1YgoEo8F2jQ= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -686,11 +703,11 @@ golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.2.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= @@ -702,8 +719,8 @@ golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= -golang.org/x/text v0.13.0 h1:ablQoSUd0tRdKxZewP80B+BaqeKJuVhuRxj/dkrun3k= -golang.org/x/text v0.13.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= +golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= +golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0 h1:/5xXl8Y5W96D+TtHSlonuFqGHIWVuyCkGJLwGh9JJFs= @@ -846,8 +863,9 @@ gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= gopkg.in/h2non/gock.v1 v1.1.2 h1:jBbHXgGBK/AoPVfJh5x4r/WxIrElvbLel8TCZkkZJoY= gopkg.in/h2non/gock.v1 v1.1.2/go.mod h1:n7UGz/ckNChHiK05rDoiC4MYSunEC/lyaUm2WWaDva0= -gopkg.in/ini.v1 v1.56.0 h1:DPMeDvGTM54DXbPkVIZsp19fp/I2K7zwA/itHYHKo8Y= gopkg.in/ini.v1 v1.56.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= +gopkg.in/ini.v1 v1.67.0 h1:Dgnx+6+nfE+IfzjUEISNeydPJh9AXNNsWbGP9KzCsOA= +gopkg.in/ini.v1 v1.67.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= diff --git a/server/internal/cmd/cmd.go b/server/internal/cmd/cmd.go index 426aaad..4e759ba 100644 --- a/server/internal/cmd/cmd.go +++ b/server/internal/cmd/cmd.go @@ -36,7 +36,9 @@ var ( --------------------------------------------------------------------------------- 工具 >> 释放casbin权限,用于清理无效的权限设置 [go run main.go tools -m=casbin -a1=refresh] - + --------------------------------------------------------------------------------- + 升级更新 + >> 修复菜单关系树 [go run main.go up -m=fix -a1=menuTree] --------------------------------------------------------------------------------- 更多 github地址:https://github.com/bufanyun/hotgo @@ -76,7 +78,7 @@ var ( ) func init() { - if err := Main.AddCommand(All, Http, Queue, Cron, Auth, Tools, Help); err != nil { + if err := Main.AddCommand(All, Http, Queue, Cron, Auth, Tools, Up, Help); err != nil { panic(err) } } diff --git a/server/internal/cmd/http.go b/server/internal/cmd/http.go index 810d938..2496b3b 100644 --- a/server/internal/cmd/http.go +++ b/server/internal/cmd/http.go @@ -10,6 +10,7 @@ import ( "github.com/gogf/gf/v2/frame/g" "github.com/gogf/gf/v2/net/ghttp" "github.com/gogf/gf/v2/os/gcmd" + "github.com/gogf/gf/v2/util/gmode" "hotgo/internal/consts" "hotgo/internal/library/addons" "hotgo/internal/library/casbin" @@ -79,7 +80,9 @@ var ( casbin.InitEnforcer(ctx) // 初始化生成代码配置 - hggen.InIt(ctx) + if !gmode.IsProduct() { + hggen.InIt(ctx) + } // 启动tcp服务 service.TCPServer().Start(ctx) diff --git a/server/internal/cmd/up.go b/server/internal/cmd/up.go new file mode 100644 index 0000000..cbfc045 --- /dev/null +++ b/server/internal/cmd/up.go @@ -0,0 +1,65 @@ +// Package cmd +// @Link https://github.com/bufanyun/hotgo +// @Copyright Copyright (c) 2023 HotGo CLI +// @Author Ms <133814250@qq.com> +// @License https://github.com/bufanyun/hotgo/blob/master/LICENSE +package cmd + +import ( + "context" + "github.com/gogf/gf/v2/errors/gerror" + "github.com/gogf/gf/v2/frame/g" + "github.com/gogf/gf/v2/os/gcmd" + "hotgo/internal/cmd/upgrade/fix" +) + +var ( + Up = &gcmd.Command{ + Name: "up", + Brief: "处理hotgo版本升级更新带来的兼容问题", + Description: ``, + Func: func(ctx context.Context, parser *gcmd.Parser) (err error) { + args := parser.GetOptAll() + g.Log().Debugf(ctx, "up args:%v", args) + if len(args) == 0 { + err = gerror.New("up args cannot be empty.") + return + } + + method, ok := args["m"] + if !ok { + err = gerror.New("up method cannot be empty.") + return + } + + switch method { + case "fix": + err = handleUpgradeFix(ctx, args) + default: + err = gerror.Newf("up method[%v] does not exist", method) + } + + if err == nil { + g.Log().Info(ctx, "up exec successful!") + } + return + }, + } +) + +// handleUpgradeFix 处理修复脚本 +func handleUpgradeFix(ctx context.Context, args map[string]string) (err error) { + a1, ok := args["a1"] + if !ok { + err = gerror.New("fix args cannot be empty.") + return + } + + switch a1 { + case "menuTree": + fix.UpdateAdminMenuTree(ctx) + default: + err = gerror.Newf("fix a1 is invalid, a1:%v", a1) + } + return +} diff --git a/server/internal/cmd/upgrade/fix/admin_menu_tree.go b/server/internal/cmd/upgrade/fix/admin_menu_tree.go new file mode 100644 index 0000000..e5c7d66 --- /dev/null +++ b/server/internal/cmd/upgrade/fix/admin_menu_tree.go @@ -0,0 +1,48 @@ +// Package fix +// @Link https://github.com/bufanyun/hotgo +// @Copyright Copyright (c) 2023 HotGo CLI +// @Author Ms <133814250@qq.com> +// @License https://github.com/bufanyun/hotgo/blob/master/LICENSE +package fix + +import ( + "context" + "github.com/gogf/gf/v2/frame/g" + "github.com/gogf/gf/v2/os/gtime" + "hotgo/internal/dao" + "hotgo/internal/library/hgorm" + "hotgo/internal/model/entity" +) + +// UpdateAdminMenuTree 更新菜单关系树 +// 根据树等级从上到下依次检查,将无效的关系树进行修复更新 +func UpdateAdminMenuTree(ctx context.Context) { + var list []*entity.AdminMenu + err := dao.AdminMenu.Ctx(ctx).OrderAsc("level").Scan(&list) + if err != nil { + g.Log().Fatal(ctx, err) + } + + genUpdateData := func(v *entity.AdminMenu) g.Map { + update := g.Map{"updated_at": gtime.Now()} + if v.Pid <= 0 { + update["level"] = 1 + update["tree"] = "" + return update + } + + // 生成下级关系树 + update["pid"], update["level"], update["tree"], err = hgorm.GenSubTree(ctx, &dao.AdminMenu, v.Pid) + return update + } + + for _, v := range list { + update := genUpdateData(v) + if v.Level == update["level"] && v.Tree == update["tree"] { + continue + } + if _, err = dao.AdminMenu.Ctx(ctx).WherePri(v.Id).Data(genUpdateData(v)).Update(); err != nil { + g.Log().Fatal(ctx, err) + } + } +} diff --git a/server/internal/consts/context.go b/server/internal/consts/context.go index 149e283..38acd81 100644 --- a/server/internal/consts/context.go +++ b/server/internal/consts/context.go @@ -10,5 +10,6 @@ type CtxKey string // ContextKey 上下文 const ( ContextHTTPKey CtxKey = "httpContext" // http上下文变量名称 - ContextKeyCronArgs CtxKey = "cronArgs" // 定时任务参数上下文变量名称 + ContextKeyCronArgs CtxKey = "cronArgs" // 定时任务参数 + ContextKeyCronSn CtxKey = "cronSn" // 定时任务序列号 ) diff --git a/server/internal/consts/upload.go b/server/internal/consts/upload.go index 1b28c96..11ae4c7 100644 --- a/server/internal/consts/upload.go +++ b/server/internal/consts/upload.go @@ -12,4 +12,5 @@ const ( UploadDriveCos = "cos" // 腾讯云cos UploadDriveOss = "oss" // 阿里云oss UploadDriveQiNiu = "qiniu" // 七牛云对象存储 + UploadDriveMinio = "minio" // minio ) diff --git a/server/internal/consts/version.go b/server/internal/consts/version.go index ae97dae..c52eefd 100644 --- a/server/internal/consts/version.go +++ b/server/internal/consts/version.go @@ -7,5 +7,5 @@ package consts // VersionApp HotGo版本 const ( - VersionApp = "2.9.8" + VersionApp = "2.11.5" ) diff --git a/server/internal/controller/admin/common/site.go b/server/internal/controller/admin/common/site.go index 8631fff..379c82c 100644 --- a/server/internal/controller/admin/common/site.go +++ b/server/internal/controller/admin/common/site.go @@ -8,9 +8,11 @@ package common import ( "context" "github.com/gogf/gf/v2/errors/gerror" + "github.com/gogf/gf/v2/frame/g" "github.com/gogf/gf/v2/net/ghttp" "github.com/gogf/gf/v2/text/gstr" "github.com/gogf/gf/v2/util/gconv" + "github.com/gogf/gf/v2/util/gmode" "hotgo/api/admin/common" "hotgo/internal/consts" "hotgo/internal/library/captcha" @@ -35,6 +37,7 @@ func (c *cSite) Config(ctx context.Context, _ *common.SiteConfigReq) (res *commo Version: consts.VersionApp, WsAddr: c.getWsAddr(ctx, request), Domain: c.getDomain(ctx, request), + Mode: gmode.Mode(), } return } @@ -43,7 +46,7 @@ func (c *cSite) getWsAddr(ctx context.Context, request *ghttp.Request) string { // 如果是本地IP访问,则认为是调试模式,走实际请求地址,否则走配置中的地址 ip := ghttp.RequestFromCtx(ctx).GetHeader("hostname") if validate.IsLocalIPAddr(ip) { - return "ws://" + ip + ":" + gstr.StrEx(request.Host, ":") + "/socket" + return "ws://" + ip + ":" + gstr.StrEx(request.Host, ":") + g.Cfg().MustGet(ctx, "router.websocket.prefix").String() } basic, err := service.SysConfig().GetBasic(ctx) diff --git a/server/internal/controller/admin/sys/cron.go b/server/internal/controller/admin/sys/cron.go index 9110ff5..e87e98b 100644 --- a/server/internal/controller/admin/sys/cron.go +++ b/server/internal/controller/admin/sys/cron.go @@ -10,6 +10,7 @@ import ( "github.com/gogf/gf/v2/errors/gerror" "hotgo/api/admin/cron" "hotgo/api/servmsg" + "hotgo/internal/model/input/sysin" "hotgo/internal/service" ) @@ -63,9 +64,13 @@ func (c *cCron) List(ctx context.Context, req *cron.ListReq) (res *cron.ListRes, return } -// Status 更新部门状态 +// Status 更新状态 func (c *cCron) Status(ctx context.Context, req *cron.StatusReq) (res *cron.StatusRes, err error) { - err = service.SysCron().Status(ctx, &req.CronStatusInp) + if req.Id <= 0 { + return nil, gerror.New("定时任务ID不能为空") + } + + err = service.TCPServer().CronStatus(ctx, &servmsg.CronStatusReq{CronStatusInp: &req.CronStatusInp}) return } @@ -78,3 +83,15 @@ func (c *cCron) OnlineExec(ctx context.Context, req *cron.OnlineExecReq) (res *c err = service.TCPServer().CronOnlineExec(ctx, &servmsg.CronOnlineExecReq{OnlineExecInp: &req.OnlineExecInp}) return } + +// DispatchLog 调度日志 +func (c *cCron) DispatchLog(ctx context.Context, req *cron.DispatchLogReq) (res *cron.DispatchLogRes, err error) { + if req.Id <= 0 { + return nil, gerror.New("定时任务ID不能为空") + } + + res = new(cron.DispatchLogRes) + res.DispatchLogModel = new(sysin.DispatchLogModel) + res.Log, err = service.TCPServer().DispatchLog(ctx, &servmsg.CronDispatchLogReq{DispatchLogInp: &req.DispatchLogInp}) + return +} diff --git a/server/internal/controller/admin/sys/curd_demo.go b/server/internal/controller/admin/sys/curd_demo.go index 7842e05..46d673d 100644 --- a/server/internal/controller/admin/sys/curd_demo.go +++ b/server/internal/controller/admin/sys/curd_demo.go @@ -3,7 +3,7 @@ // @Copyright Copyright (c) 2023 HotGo CLI // @Author Ms <133814250@qq.com> // @License https://github.com/bufanyun/hotgo/blob/master/LICENSE -// @AutoGenerate Version 2.9.3 +// @AutoGenerate Version 2.11.5 package sys import ( diff --git a/server/internal/crons/close_order.go b/server/internal/crons/close_order.go index 2b92a30..8dfebe6 100644 --- a/server/internal/crons/close_order.go +++ b/server/internal/crons/close_order.go @@ -31,14 +31,15 @@ func (c *cCloseOrder) GetName() string { } // Execute 执行任务 -func (c *cCloseOrder) Execute(ctx context.Context) { - _, err := service.AdminOrder().Model(ctx). +func (c *cCloseOrder) Execute(ctx context.Context, parser *cron.Parser) (err error) { + _, err = service.AdminOrder().Model(ctx). Where(dao.AdminOrder.Columns().Status, consts.OrderStatusNotPay). WhereLTE(dao.AdminOrder.Columns().CreatedAt, gtime.Now().AddDate(0, 0, -1)). Data(g.Map{ dao.AdminOrder.Columns().Status: consts.OrderStatusClose, }).Update() if err != nil { - cron.Logger().Warning(ctx, "cron CloseOrder Execute err:%+v", err) + parser.Logger.Warning(ctx, "cron CloseOrder Execute err:%+v", err) } + return } diff --git a/server/internal/crons/test.go b/server/internal/crons/test.go index 7d243a6..c207c23 100644 --- a/server/internal/crons/test.go +++ b/server/internal/crons/test.go @@ -27,6 +27,7 @@ func (c *cTest) GetName() string { } // Execute 执行任务 -func (c *cTest) Execute(ctx context.Context) { - cron.Logger().Infof(ctx, "cron test Execute:%v", time.Now()) +func (c *cTest) Execute(ctx context.Context, parser *cron.Parser) (err error) { + parser.Logger.Infof(ctx, "cron test Execute:%v", time.Now()) + return } diff --git a/server/internal/crons/test2.go b/server/internal/crons/test2.go index 139c3bd..c312e13 100644 --- a/server/internal/crons/test2.go +++ b/server/internal/crons/test2.go @@ -7,7 +7,7 @@ package crons import ( "context" - "hotgo/internal/consts" + "github.com/gogf/gf/v2/errors/gerror" "hotgo/internal/library/cron" "time" ) @@ -28,22 +28,18 @@ func (c *cTest2) GetName() string { } // Execute 执行任务 -func (c *cTest2) Execute(ctx context.Context) { - args, ok := ctx.Value(consts.ContextKeyCronArgs).([]string) - if !ok { - cron.Logger().Warning(ctx, "参数解析失败!") - return - } - if len(args) != 3 { - cron.Logger().Warning(ctx, "test2 传入参数不正确!") +func (c *cTest2) Execute(ctx context.Context, parser *cron.Parser) (err error) { + if len(parser.Args) != 3 { + err = gerror.New("传入参数不正确!") return } var ( - name = args[0] - age = args[1] - msg = args[2] + name = parser.Args[0] + age = parser.Args[1] + msg = parser.Args[2] ) - cron.Logger().Infof(ctx, "cron test2 Execute:%v, name:%v, age:%v, msg:%v", time.Now(), name, age, msg) + parser.Logger.Infof(ctx, "cron test2 Execute:%v, name:%v, age:%v, msg:%v", time.Now(), name, age, msg) + return } diff --git a/server/internal/dao/internal/admin_menu.go b/server/internal/dao/internal/admin_menu.go index 81495a5..9a5202a 100644 --- a/server/internal/dao/internal/admin_menu.go +++ b/server/internal/dao/internal/admin_menu.go @@ -22,6 +22,8 @@ type AdminMenuDao struct { type AdminMenuColumns struct { Id string // 菜单ID Pid string // 父菜单ID + Level string // 关系树等级 + Tree string // 关系树 Title string // 菜单名称 Name string // 名称编码 Path string // 路由地址 @@ -39,19 +41,19 @@ type AdminMenuColumns struct { KeepAlive string // 缓存该路由 Hidden string // 是否隐藏 Affix string // 是否固定 - Level string // 关系树等级 - Tree string // 关系树 Sort string // 排序 Remark string // 备注 Status string // 菜单状态 - CreatedAt string // 创建时间 UpdatedAt string // 更新时间 + CreatedAt string // 创建时间 } // adminMenuColumns holds the columns for table hg_admin_menu. var adminMenuColumns = AdminMenuColumns{ Id: "id", Pid: "pid", + Level: "level", + Tree: "tree", Title: "title", Name: "name", Path: "path", @@ -69,13 +71,11 @@ var adminMenuColumns = AdminMenuColumns{ KeepAlive: "keep_alive", Hidden: "hidden", Affix: "affix", - Level: "level", - Tree: "tree", Sort: "sort", Remark: "remark", Status: "status", - CreatedAt: "created_at", UpdatedAt: "updated_at", + CreatedAt: "created_at", } // NewAdminMenuDao creates and returns a new DAO object for table data access. diff --git a/server/internal/dao/internal/sys_cron.go b/server/internal/dao/internal/sys_cron.go index e64818d..6928ddd 100644 --- a/server/internal/dao/internal/sys_cron.go +++ b/server/internal/dao/internal/sys_cron.go @@ -22,9 +22,10 @@ type SysCronDao struct { type SysCronColumns struct { Id string // 任务ID GroupId string // 分组ID - Name string // 任务名称 + Title string // 任务标题 + Name string // 任务方法 Params string // 函数参数 - Pattern string // 定时表达式 + Pattern string // 表达式 Policy string // 策略 Count string // 执行次数 Sort string // 排序 @@ -38,6 +39,7 @@ type SysCronColumns struct { var sysCronColumns = SysCronColumns{ Id: "id", GroupId: "group_id", + Title: "title", Name: "name", Params: "params", Pattern: "pattern", diff --git a/server/internal/global/init.go b/server/internal/global/init.go index 3d71f84..3071c8b 100644 --- a/server/internal/global/init.go +++ b/server/internal/global/init.go @@ -10,6 +10,7 @@ import ( "fmt" "github.com/gogf/gf/contrib/trace/jaeger/v2" "github.com/gogf/gf/v2" + "github.com/gogf/gf/v2/container/gvar" "github.com/gogf/gf/v2/encoding/gjson" "github.com/gogf/gf/v2/frame/g" "github.com/gogf/gf/v2/os/gctx" @@ -17,6 +18,7 @@ import ( "github.com/gogf/gf/v2/os/glog" "github.com/gogf/gf/v2/os/gtime" "github.com/gogf/gf/v2/text/gstr" + "github.com/gogf/gf/v2/util/gmode" "hotgo/internal/consts" "hotgo/internal/library/cache" "hotgo/internal/library/queue" @@ -24,13 +26,17 @@ import ( "hotgo/internal/service" "hotgo/utility/charset" "hotgo/utility/simple" + "hotgo/utility/validate" "runtime" "strings" ) func Init(ctx context.Context) { + // 设置gf运行模式 + SetGFMode(ctx) + // 设置服务日志处理 - g.Log().SetHandlers(LoggingServeLogHandler) + glog.SetDefaultHandler(LoggingServeLogHandler) // 默认上海时区 if err := gtime.SetTimeZone("Asia/Shanghai"); err != nil { @@ -69,6 +75,12 @@ func LoggingServeLogHandler(ctx context.Context, in *glog.HandlerInput) { } }() + // web服务日志不做记录,因为会导致重复记录 + r := g.RequestFromCtx(ctx) + if r != nil && r.Server != nil && in.Logger.GetConfig().Path == r.Server.Logger().GetConfig().Path { + return + } + conf, err := service.SysConfig().GetLoadServeLog(ctx) if err != nil { return @@ -90,10 +102,14 @@ func LoggingServeLogHandler(ctx context.Context, in *glog.HandlerInput) { in.Stack = in.Logger.GetStack() } + if len(in.Content) == 0 { + in.Content = gstr.StrLimit(gvar.New(in.Values).String(), consts.MaxServeLogContentLen) + } + var data entity.SysServeLog data.TraceId = gctx.CtxId(ctx) data.LevelFormat = in.LevelFormat - data.Content = gstr.StrLimit(in.Content, consts.MaxServeLogContentLen) + data.Content = in.Content data.Stack = gjson.New(charset.ParseStack(in.Stack)) data.Line = strings.TrimRight(in.CallerPath, ":") data.TriggerNs = in.Time.UnixNano() @@ -135,3 +151,18 @@ func InitTrace(ctx context.Context) { g.Log().Debug(ctx, "jaeger closed ..") }) } + +// SetGFMode 设置gf运行模式 +func SetGFMode(ctx context.Context) { + mode := g.Cfg().MustGet(ctx, "hotgo.mode").String() + if len(mode) == 0 { + mode = gmode.NOT_SET + } + + var modes = []string{gmode.DEVELOP, gmode.TESTING, gmode.STAGING, gmode.PRODUCT} + + // 如果是有效的运行模式,就进行设置 + if validate.InSlice(modes, mode) { + gmode.Set(mode) + } +} diff --git a/server/internal/library/addons/module.go b/server/internal/library/addons/module.go index cfc0e8d..19b8d39 100644 --- a/server/internal/library/addons/module.go +++ b/server/internal/library/addons/module.go @@ -10,6 +10,7 @@ import ( "github.com/gogf/gf/v2/frame/g" "github.com/gogf/gf/v2/net/ghttp" "github.com/gogf/gf/v2/os/gfile" + "github.com/gogf/gf/v2/os/gres" "github.com/gogf/gf/v2/os/gview" "hotgo/internal/model/input/form" "sort" @@ -157,6 +158,12 @@ func AddStaticPath(ctx context.Context, server *ghttp.Server, p ...string) { for _, module := range filterInstalled() { name := module.GetSkeleton().Name prefix, path := StaticPath(name, basePath) + if !gres.Contains(path) { + if _, err := gfile.Search(path); err != nil { + g.Log().Warningf(ctx, `AddStaticPath failed: %v`, err) + continue + } + } server.AddStaticPath(prefix, path) } } diff --git a/server/internal/library/cache/file/file.go b/server/internal/library/cache/file/file.go index 361dad1..26138ff 100644 --- a/server/internal/library/cache/file/file.go +++ b/server/internal/library/cache/file/file.go @@ -36,6 +36,10 @@ type ( const perm = 0o666 +var ( + CacheExpiredErr = errors.New("cache expired") +) + // NewAdapterFile creates and returns a new memory cache object. func NewAdapterFile(dir string) gcache.Adapter { return &AdapterFile{ @@ -77,7 +81,7 @@ func (c *AdapterFile) Get(ctx context.Context, key interface{}) (*gvar.Var, erro func (c *AdapterFile) GetOrSet(ctx context.Context, key interface{}, value interface{}, duration time.Duration) (result *gvar.Var, err error) { result, err = c.Get(ctx, key) - if err != nil { + if err != nil && !errors.Is(err, CacheExpiredErr) { return nil, err } if result.IsNil() { @@ -88,7 +92,7 @@ func (c *AdapterFile) GetOrSet(ctx context.Context, key interface{}, value inter func (c *AdapterFile) GetOrSetFunc(ctx context.Context, key interface{}, f gcache.Func, duration time.Duration) (result *gvar.Var, err error) { v, err := c.Get(ctx, key) - if err != nil { + if err != nil && !errors.Is(err, CacheExpiredErr) { return nil, err } if v.IsNil() { @@ -160,7 +164,6 @@ func (c *AdapterFile) UpdateExpire(ctx context.Context, key interface{}, duratio return } err = c.Set(ctx, fileKey, v.Val(), duration) - return } @@ -173,7 +176,6 @@ func (c *AdapterFile) GetExpire(ctx context.Context, key interface{}) (time.Dura if content.Duration <= time.Now().Unix() { return -1, nil } - return time.Duration(time.Now().Unix()-content.Duration) * time.Second, nil } @@ -202,7 +204,6 @@ func (c *AdapterFile) createName(key string) string { h := sha256.New() _, _ = h.Write([]byte(key)) hash := hex.EncodeToString(h.Sum(nil)) - return filepath.Join(c.dir, fmt.Sprintf("%s.cache", hash)) } @@ -228,9 +229,8 @@ func (c *AdapterFile) read(key string) (*fileContent, error) { if content.Duration <= time.Now().Unix() { _ = c.Delete(key) - return nil, errors.New("cache expired") + return nil, CacheExpiredErr } - return content, nil } @@ -246,7 +246,6 @@ func (c *AdapterFile) Delete(key string) error { if err != nil && os.IsNotExist(err) { return nil } - return os.Remove(c.createName(key)) } @@ -270,7 +269,6 @@ func (c *AdapterFile) Fetch(key string) (interface{}, error) { if content == nil { return nil, nil } - return content.Data, nil } @@ -282,7 +280,6 @@ func (c *AdapterFile) FetchMulti(keys []string) map[string]interface{} { result[key] = value } } - return result } @@ -302,7 +299,6 @@ func (c *AdapterFile) Flush() error { for _, name := range names { _ = os.Remove(filepath.Join(c.dir, name)) } - return nil } diff --git a/server/internal/library/cron/cron.go b/server/internal/library/cron/cron.go index 1e80ae4..da09b50 100644 --- a/server/internal/library/cron/cron.go +++ b/server/internal/library/cron/cron.go @@ -6,36 +6,55 @@ package cron import ( + "bufio" "context" + "fmt" "github.com/gogf/gf/v2/errors/gerror" "github.com/gogf/gf/v2/frame/g" "github.com/gogf/gf/v2/os/gcron" "github.com/gogf/gf/v2/os/gctx" + "github.com/gogf/gf/v2/os/gfile" "github.com/gogf/gf/v2/os/glog" "github.com/gogf/gf/v2/os/gtime" "hotgo/internal/consts" "hotgo/internal/dao" "hotgo/internal/model/entity" "hotgo/utility/simple" + "os" "strings" "sync" ) var crons = &cronManager{ - tasks: make(map[string]*TaskItem), + tasks: make(map[string]*TaskItem), + loggers: make(map[string]*glog.Logger), } // Cron 定时任务接口 type Cron interface { // GetName 获取任务名称 GetName() string - // Execute 执行一次任务 - Execute(ctx context.Context) + // Execute 执行任务 + Execute(ctx context.Context, parser *Parser) (err error) +} + +// Parser 任务执行参数 +type Parser struct { + Args []string // 任务参数 + Logger *glog.Logger // 日志管理实例 +} + +// Log 任务调度日志 +type Log struct { + FileName string `json:"fileName" dc:"文件名称"` + SizeFormat string `json:"sizeFormat" dc:"文件大小"` + Contents string `json:"contents" dc:"文件内容"` } // consumerManager 任务管理者 type cronManager struct { - tasks map[string]*TaskItem + tasks map[string]*TaskItem + loggers map[string]*glog.Logger sync.RWMutex } @@ -62,7 +81,8 @@ func Register(c Cron) { Logger().Debugf(gctx.GetInitCtx(), "cron.Register name:%v duplicate registration.", name) return } - crons.tasks[name] = &TaskItem{Name: c.GetName(), Fun: c.Execute} + + crons.tasks[name] = &TaskItem{Name: c.GetName(), Fun: GenExecuteFun(c.Execute)} } // StopALL 停止所有任务 @@ -88,27 +108,29 @@ func StartALL(sysCron []*entity.SysCron) (err error) { return gerror.Newf("该任务没有加入任务列表:%v", cron.Name) } + sn := GenCronSn(cron) + // 没有则添加 - if gcron.Search(cron.Name) == nil { + if gcron.Search(sn) == nil { var ( t *gcron.Entry - ctx = context.WithValue(gctx.New(), consts.ContextKeyCronArgs, strings.Split(cron.Params, consts.CronSplitStr)) + ctx = GenCronCtx(cron) ) switch cron.Policy { case consts.CronPolicySame: - t, err = gcron.Add(ctx, cron.Pattern, f.Fun, cron.Name) + t, err = gcron.Add(ctx, cron.Pattern, f.Fun, sn) case consts.CronPolicySingle: - t, err = gcron.AddSingleton(ctx, cron.Pattern, f.Fun, cron.Name) + t, err = gcron.AddSingleton(ctx, cron.Pattern, f.Fun, sn) case consts.CronPolicyOnce: - t, err = gcron.AddOnce(ctx, cron.Pattern, f.Fun, cron.Name) + t, err = gcron.AddOnce(ctx, cron.Pattern, f.Fun, sn) case consts.CronPolicyTimes: if f.Count <= 0 { f.Count = 1 } - t, err = gcron.AddTimes(ctx, cron.Pattern, int(cron.Count), f.Fun, cron.Name) + t, err = gcron.AddTimes(ctx, cron.Pattern, int(cron.Count), f.Fun, sn) default: return gerror.Newf("使用无效的策略, cron.Policy=%v", cron.Policy) @@ -122,7 +144,7 @@ func StartALL(sysCron []*entity.SysCron) (err error) { } } - gcron.Start(cron.Name) + gcron.Start(sn) // 执行完毕,单次和多次执行的任务更新状态 if cron.Policy == consts.CronPolicyOnce || cron.Policy == consts.CronPolicyTimes { @@ -144,14 +166,14 @@ func RefreshStatus(sysCron *entity.SysCron) (err error) { } if sysCron.Status == consts.StatusEnabled { - return Start(sysCron) + return ResetStart(sysCron) } return Stop(sysCron) } // Stop 停止单个任务 func Stop(sysCron *entity.SysCron) (err error) { - cr := gcron.Search(sysCron.Name) + cr := gcron.Search(GenCronSn(sysCron)) if cr == nil { return } @@ -159,6 +181,17 @@ func Stop(sysCron *entity.SysCron) (err error) { return } +// ResetStart 重置任务 +func ResetStart(sysCron *entity.SysCron) (err error) { + if err = Stop(sysCron); err != nil { + return + } + if err = Delete(sysCron); err != nil { + return + } + return Start(sysCron) +} + // Once 立即执行一次某个任务 func Once(ctx context.Context, sysCron *entity.SysCron) error { crons.RLock() @@ -167,7 +200,7 @@ func Once(ctx context.Context, sysCron *entity.SysCron) error { for _, v := range crons.tasks { if v.Name == sysCron.Name { simple.SafeGo(ctx, func(ctx context.Context) { - v.Fun(ctx) + v.Fun(GenCronCtx(sysCron)) }) return nil } @@ -182,7 +215,7 @@ func Delete(sysCron *entity.SysCron) (err error) { } for _, v := range gcron.Entries() { - if v.Name == sysCron.Name { + if v.Name == GenCronSn(sysCron) { gcron.Remove(v.Name) } } @@ -195,10 +228,86 @@ func Start(sysCron *entity.SysCron) (err error) { return } - c := gcron.Search(sysCron.Name) + c := gcron.Search(GenCronSn(sysCron)) if c != nil { c.Start() return } return StartALL([]*entity.SysCron{sysCron}) } + +// DispatchLog 查看指定任务的调度日志 +func DispatchLog(sysCron *entity.SysCron) (log *Log, err error) { + path := fmt.Sprintf("%v/%v", Logger().GetConfig().Path, GenCronSn(sysCron)) + file, err := FindLastModifiedFile(path) + if err != nil { + return nil, err + } + + if len(file) == 0 || !gfile.IsFile(file) { + err = gerror.New("未找到日志!") + return + } + + log = new(Log) + log.FileName = file + log.SizeFormat = gfile.SizeFormat(file) + + if gfile.Size(file) > 1024*50 { + log.Contents, err = ReadLastLines(file, 100) + if err != nil { + return nil, err + } + } else { + log.Contents = gfile.GetContents(file) + } + return +} + +func ReadLastLines(filename string, lineCount int) (string, error) { + file, err := os.Open(filename) + if err != nil { + return "", err + } + defer file.Close() + + scanner := bufio.NewScanner(file) + + lines := make([]string, 0, lineCount) + for scanner.Scan() { + lines = append(lines, scanner.Text()) + if len(lines) > lineCount { + lines = lines[1:] + } + } + + if err = scanner.Err(); err != nil { + return "", err + } + + result := strings.Join(lines, "\n") + return result, nil +} + +func FindLastModifiedFile(dirPath string) (string, error) { + if !gfile.Exists(dirPath) { + return "", gerror.New("该任务暂未产生日志!") + } + + files, err := gfile.ScanDir(dirPath, "*.log", true) + if err != nil { + return "", err + } + + var lastModifiedFile string + var lastModifiedTime int64 = 0 + + for _, file := range files { + modTime := gfile.MTimestamp(file) + if modTime > lastModifiedTime { + lastModifiedTime = modTime + lastModifiedFile = file + } + } + return lastModifiedFile, nil +} diff --git a/server/internal/library/cron/cron_gen.go b/server/internal/library/cron/cron_gen.go new file mode 100644 index 0000000..e159b74 --- /dev/null +++ b/server/internal/library/cron/cron_gen.go @@ -0,0 +1,86 @@ +// Package cron +// @Link https://github.com/bufanyun/hotgo +// @Copyright Copyright (c) 2023 HotGo CLI +// @Author Ms <133814250@qq.com> +// @License https://github.com/bufanyun/hotgo/blob/master/LICENSE +package cron + +import ( + "context" + "fmt" + "github.com/gogf/gf/v2/frame/g" + "github.com/gogf/gf/v2/os/gctx" + "github.com/gogf/gf/v2/os/glog" + "github.com/gogf/gf/v2/os/gtime" + "hotgo/internal/consts" + "hotgo/internal/model/entity" + "strings" +) + +// GenCronSn 生成任务序列号 +func GenCronSn(sysCron *entity.SysCron) string { + return fmt.Sprintf("%s@%d", sysCron.Name, sysCron.Id) +} + +// GenCronCtx 生成任务上下文 +func GenCronCtx(sysCron *entity.SysCron) (ctx context.Context) { + ctx = context.WithValue(gctx.New(), consts.ContextKeyCronArgs, strings.Split(sysCron.Params, consts.CronSplitStr)) + ctx = context.WithValue(ctx, consts.ContextKeyCronSn, GenCronSn(sysCron)) + return ctx +} + +func GenLoggerByCtx(ctx context.Context) *glog.Logger { + sn, ok := ctx.Value(consts.ContextKeyCronSn).(string) + if !ok { + Logger().Panic(ctx, "获取定时任务序列号失败!") + } + + logger, ok := crons.loggers[sn] + if ok { + return logger + } + + logger = glog.New() + if err := logger.SetConfig(Logger().GetConfig()); err != nil { + Logger().Panic(ctx, err) + } + + logger.SetFlags(glog.F_TIME_STD | glog.F_FILE_SHORT) + // 设置子路径 + if err := logger.SetPath(fmt.Sprintf("%v/%v", logger.GetPath(), sn)); err != nil { + Logger().Panic(ctx, err) + } + + crons.Lock() + defer crons.Unlock() + crons.loggers[sn] = logger + return logger +} + +// GenExecuteFun 生成执行过程 +func GenExecuteFun(fun func(ctx context.Context, parser *Parser) (err error)) func(ctx context.Context) { + return func(ctx context.Context) { + args, ok := ctx.Value(consts.ContextKeyCronArgs).([]string) + if !ok { + Logger().Panic(ctx, "执行定时任务时,参数解析失败!") + return + } + parser := new(Parser) + parser.Args = args + parser.Logger = GenLoggerByCtx(ctx) + + st := gtime.Now() + err := g.Try(ctx, func(ctx context.Context) { + if err := fun(ctx, parser); err != nil { + panic(err) + } + }) + + milliseconds := gtime.Now().Sub(st).Milliseconds() // 执行耗时 + if err != nil { + parser.Logger.Errorf(ctx, "execute failed, took %vms, err:%+v", milliseconds, err) + return + } + parser.Logger.Infof(ctx, "execute success, took %vms.", milliseconds) + } +} diff --git a/server/internal/library/hggen/internal/cmd/cmd.go b/server/internal/library/hggen/internal/cmd/cmd.go index 70c6290..b2d0cba 100644 --- a/server/internal/library/hggen/internal/cmd/cmd.go +++ b/server/internal/library/hggen/internal/cmd/cmd.go @@ -55,6 +55,7 @@ func (c cGF) Index(ctx context.Context, in cGFInput) (out *cGFOutput, err error) _, err = Version.Index(ctx, cVersionInput{}) return } + answer := "n" // No argument or option, do installation checks. if data, isInstalled := service.Install.IsInstalled(); !isInstalled { @@ -71,6 +72,7 @@ func (c cGF) Index(ctx context.Context, in cGFInput) (out *cGFOutput, err error) gcmd.Scan("press `Enter` to exit...") return } + // Print help content. gcmd.CommandFromCtx(ctx).Print() return diff --git a/server/internal/library/hggen/internal/cmd/cmd_build.go b/server/internal/library/hggen/internal/cmd/cmd_build.go index 804f2d4..1e3e965 100644 --- a/server/internal/library/hggen/internal/cmd/cmd_build.go +++ b/server/internal/library/hggen/internal/cmd/cmd_build.go @@ -159,7 +159,7 @@ func (c cBuild) Index(ctx context.Context, in cBuildInput) (out *cBuildOutput, e if gfile.Exists("main.go") { file = "main.go" } else { - mlog.Fatal("build file path cannot be empty") + mlog.Fatal("build file path is empty or main.go not found in current working directory") } } if in.Name == "" { @@ -254,17 +254,23 @@ func (c cBuild) Index(ctx context.Context, in cBuildInput) (out *cBuildOutput, e continue } if len(customSystems) == 0 && len(customArches) == 0 { + // Single binary building, output the binary to current working folder. + // For example: + // `gf build` + // `gf build -o main.exe` if runtime.GOOS == "windows" { ext = ".exe" } - // Single binary building, output the binary to current working folder. - output := "" + var outputPath string if len(in.Output) > 0 { - output = "-o " + in.Output + ext + outputPath = "-o " + in.Output } else { - output = "-o " + in.Name + ext + outputPath = "-o " + in.Name + ext } - cmd = fmt.Sprintf(`go build %s -ldflags "%s" %s %s`, output, ldFlags, in.Extra, file) + cmd = fmt.Sprintf( + `go build %s -ldflags "%s" %s %s`, + outputPath, ldFlags, in.Extra, file, + ) } else { // Cross-building, output the compiled binary to specified path. if system == "windows" { @@ -272,11 +278,22 @@ func (c cBuild) Index(ctx context.Context, in cBuildInput) (out *cBuildOutput, e } genv.MustSet("GOOS", system) genv.MustSet("GOARCH", arch) + + var outputPath string + if len(in.Output) > 0 { + outputPath = "-o " + in.Output + } else { + outputPath = fmt.Sprintf( + "-o %s/%s/%s%s", + in.Path, system+"_"+arch, in.Name, ext, + ) + } cmd = fmt.Sprintf( - `go build -o %s/%s/%s%s -ldflags "%s" %s%s`, - in.Path, system+"_"+arch, in.Name, ext, ldFlags, in.Extra, file, + `go build %s -ldflags "%s" %s%s`, + outputPath, ldFlags, in.Extra, file, ) } + mlog.Debug(fmt.Sprintf("build for GOOS=%s GOARCH=%s", system, arch)) mlog.Debug(cmd) // It's not necessary printing the complete command string. cmdShow, _ := gregex.ReplaceString(`\s+(-ldflags ".+?")\s+`, " ", cmd) diff --git a/server/internal/library/hggen/internal/cmd/cmd_version.go b/server/internal/library/hggen/internal/cmd/cmd_version.go index 04c5b84..420d588 100644 --- a/server/internal/library/hggen/internal/cmd/cmd_version.go +++ b/server/internal/library/hggen/internal/cmd/cmd_version.go @@ -7,14 +7,19 @@ package cmd import ( + "bytes" "context" "fmt" + "runtime" + "strings" + "time" "github.com/gogf/gf/v2" "github.com/gogf/gf/v2/errors/gerror" "github.com/gogf/gf/v2/frame/g" "github.com/gogf/gf/v2/os/gbuild" "github.com/gogf/gf/v2/os/gfile" + "github.com/gogf/gf/v2/os/gproc" "github.com/gogf/gf/v2/text/gregex" "github.com/gogf/gf/v2/text/gstr" @@ -25,6 +30,10 @@ var ( Version = cVersion{} ) +const ( + defaultIndent = "{{indent}}" +) + type cVersion struct { g.Meta `name:"version" brief:"show version information of current binary"` } @@ -36,34 +45,90 @@ type cVersionInput struct { type cVersionOutput struct{} func (c cVersion) Index(ctx context.Context, in cVersionInput) (*cVersionOutput, error) { - info := gbuild.Info() - if info.Git == "" { - info.Git = "none" - } - mlog.Printf(`GoFrame CLI Tool %s, https://goframe.org`, gf.VERSION) - gfVersion, err := c.getGFVersionOfCurrentProject() - if err != nil { - gfVersion = err.Error() + detailBuffer := &detailBuffer{} + detailBuffer.WriteString(fmt.Sprintf("%s", gf.VERSION)) + + detailBuffer.appendLine(0, "Welcome to GoFrame!") + + detailBuffer.appendLine(0, "Env Detail:") + goVersion, ok := getGoVersion() + if ok { + detailBuffer.appendLine(1, fmt.Sprintf("Go Version: %s", goVersion)) + detailBuffer.appendLine(1, fmt.Sprintf("GF Version(go.mod): %s", getGoFrameVersion(2))) } else { - gfVersion = gfVersion + " in current go.mod" - } - mlog.Printf(`GoFrame Version: %s`, gfVersion) - mlog.Printf(`CLI Installed At: %s`, gfile.SelfPath()) - if info.GoFrame == "" { - mlog.Print(`Current is a custom installed version, no installation information.`) - return nil, nil + v, err := c.getGFVersionOfCurrentProject() + if err == nil { + detailBuffer.appendLine(1, fmt.Sprintf("GF Version(go.mod): %s", v)) + } else { + detailBuffer.appendLine(1, fmt.Sprintf("GF Version(go.mod): %s", err.Error())) + } } - mlog.Print(gstr.Trim(fmt.Sprintf(` -CLI Built Detail: - Go Version: %s - GF Version: %s - Git Commit: %s - Build Time: %s -`, info.Golang, info.GoFrame, info.Git, info.Time))) + detailBuffer.appendLine(0, "CLI Detail:") + detailBuffer.appendLine(1, fmt.Sprintf("Installed At: %s", gfile.SelfPath())) + info := gbuild.Info() + if info.GoFrame == "" { + detailBuffer.appendLine(1, fmt.Sprintf("Built Go Version: %s", runtime.Version())) + detailBuffer.appendLine(1, fmt.Sprintf("Built GF Version: %s", gf.VERSION)) + } else { + if info.Git == "" { + info.Git = "none" + } + detailBuffer.appendLine(1, fmt.Sprintf("Built Go Version: %s", info.Golang)) + detailBuffer.appendLine(1, fmt.Sprintf("Built GF Version: %s", info.GoFrame)) + detailBuffer.appendLine(1, fmt.Sprintf("Git Commit: %s", info.Git)) + detailBuffer.appendLine(1, fmt.Sprintf("Built Time: %s", info.Time)) + } + + detailBuffer.appendLine(0, "Others Detail:") + detailBuffer.appendLine(1, "Docs: https://goframe.org") + detailBuffer.appendLine(1, fmt.Sprintf("Now : %s", time.Now().Format(time.RFC3339))) + + mlog.Print(detailBuffer.replaceAllIndent(" ")) return nil, nil } +// detailBuffer is a buffer for detail information. +type detailBuffer struct { + bytes.Buffer +} + +// appendLine appends a line to the buffer with given indent level. +func (d *detailBuffer) appendLine(indentLevel int, line string) { + d.WriteString(fmt.Sprintf("\n%s%s", strings.Repeat(defaultIndent, indentLevel), line)) +} + +// replaceAllIndent replaces the tab with given indent string and prints the buffer content. +func (d *detailBuffer) replaceAllIndent(indentStr string) string { + return strings.ReplaceAll(d.String(), defaultIndent, indentStr) +} + +// getGoFrameVersion returns the goframe version of current project using. +func getGoFrameVersion(indentLevel int) (gfVersion string) { + pkgInfo, err := gproc.ShellExec(context.Background(), `go list -f "{{if (not .Main)}}{{.Path}}@{{.Version}}{{end}}" -m all`) + if err != nil { + return "cannot find go.mod" + } + pkgList := gstr.Split(pkgInfo, "\n") + for _, v := range pkgList { + if strings.HasPrefix(v, "github.com/gogf/gf") { + gfVersion += fmt.Sprintf("\n%s%s", strings.Repeat(defaultIndent, indentLevel), v) + } + } + return +} + +// getGoVersion returns the go version +func getGoVersion() (goVersion string, ok bool) { + goVersion, err := gproc.ShellExec(context.Background(), "go version") + if err != nil { + return "", false + } + goVersion = gstr.TrimLeftStr(goVersion, "go version ") + goVersion = gstr.TrimRightStr(goVersion, "\n") + return goVersion, true +} + // getGFVersionOfCurrentProject checks and returns the GoFrame version current project using. func (c cVersion) getGFVersionOfCurrentProject() (string, error) { goModPath := gfile.Join(gfile.Pwd(), "go.mod") diff --git a/server/internal/library/hggen/internal/cmd/cmd_z_init_test.go b/server/internal/library/hggen/internal/cmd/cmd_z_init_test.go new file mode 100644 index 0000000..8ad499f --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/cmd_z_init_test.go @@ -0,0 +1,11 @@ +// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved. +// +// This Source Code Form is subject to the terms of the MIT License. +// If a copy of the MIT was not distributed with this file, +// You can obtain one at https://github.com/gogf/gf. + +package cmd + +import "context" + +var ctx = context.Background() diff --git a/server/internal/library/hggen/internal/cmd/cmd_fix_test.go b/server/internal/library/hggen/internal/cmd/cmd_z_unit_fix_test.go similarity index 100% rename from server/internal/library/hggen/internal/cmd/cmd_fix_test.go rename to server/internal/library/hggen/internal/cmd/cmd_z_unit_fix_test.go diff --git a/server/internal/library/hggen/internal/cmd/cmd_z_unit_gen_ctrl_test.go b/server/internal/library/hggen/internal/cmd/cmd_z_unit_gen_ctrl_test.go new file mode 100644 index 0000000..fb8877d --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/cmd_z_unit_gen_ctrl_test.go @@ -0,0 +1,85 @@ +// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved. +// +// This Source Code Form is subject to the terms of the MIT License. +// If a copy of the MIT was not distributed with this file, +// You can obtain one at https://github.com/gogf/gf. + +package cmd + +import ( + "github.com/gogf/gf/v2/os/gfile" + "github.com/gogf/gf/v2/test/gtest" + "github.com/gogf/gf/v2/util/guid" + "github.com/gogf/gf/v2/util/gutil" + "hotgo/internal/library/hggen/internal/cmd/genctrl" + "path/filepath" + "testing" +) + +func Test_Gen_Ctrl_Default(t *testing.T) { + gtest.C(t, func(t *gtest.T) { + var ( + path = gfile.Temp(guid.S()) + apiFolder = gtest.DataPath("genctrl", "api") + in = genctrl.CGenCtrlInput{ + SrcFolder: apiFolder, + DstFolder: path, + WatchFile: "", + SdkPath: "", + SdkStdVersion: false, + SdkNoV1: false, + Clear: false, + Merge: false, + } + ) + err := gutil.FillStructWithDefault(&in) + t.AssertNil(err) + + err = gfile.Mkdir(path) + t.AssertNil(err) + defer gfile.Remove(path) + + _, err = genctrl.CGenCtrl{}.Ctrl(ctx, in) + if err != nil { + panic(err) + } + + // apiInterface file + var ( + genApi = apiFolder + filepath.FromSlash("/article/article.go") + genApiExpect = apiFolder + filepath.FromSlash("/article/article_expect.go") + ) + defer gfile.Remove(genApi) + t.Assert(gfile.GetContents(genApi), gfile.GetContents(genApiExpect)) + + // files + files, err := gfile.ScanDir(path, "*.go", true) + t.AssertNil(err) + t.Assert(files, []string{ + path + filepath.FromSlash("/article/article.go"), + path + filepath.FromSlash("/article/article_new.go"), + path + filepath.FromSlash("/article/article_v1_create.go"), + path + filepath.FromSlash("/article/article_v1_get_list.go"), + path + filepath.FromSlash("/article/article_v1_get_one.go"), + path + filepath.FromSlash("/article/article_v1_update.go"), + path + filepath.FromSlash("/article/article_v2_create.go"), + path + filepath.FromSlash("/article/article_v2_update.go"), + }) + + // content + testPath := gtest.DataPath("genctrl", "controller") + expectFiles := []string{ + testPath + filepath.FromSlash("/article/article.go"), + testPath + filepath.FromSlash("/article/article_new.go"), + testPath + filepath.FromSlash("/article/article_v1_create.go"), + testPath + filepath.FromSlash("/article/article_v1_get_list.go"), + testPath + filepath.FromSlash("/article/article_v1_get_one.go"), + testPath + filepath.FromSlash("/article/article_v1_update.go"), + testPath + filepath.FromSlash("/article/article_v2_create.go"), + testPath + filepath.FromSlash("/article/article_v2_update.go"), + } + for i := range files { + t.Assert(gfile.GetContents(files[i]), gfile.GetContents(expectFiles[i])) + } + }) +} diff --git a/server/internal/library/hggen/internal/cmd/cmd_gen_dao_test.go b/server/internal/library/hggen/internal/cmd/cmd_z_unit_gen_dao_test.go similarity index 84% rename from server/internal/library/hggen/internal/cmd/cmd_gen_dao_test.go rename to server/internal/library/hggen/internal/cmd/cmd_z_unit_gen_dao_test.go index 0a1bda7..7b3cff0 100644 --- a/server/internal/library/hggen/internal/cmd/cmd_gen_dao_test.go +++ b/server/internal/library/hggen/internal/cmd/cmd_z_unit_gen_dao_test.go @@ -7,8 +7,8 @@ package cmd import ( - "context" "fmt" + "path/filepath" "testing" "github.com/gogf/gf/v2/database/gdb" @@ -20,8 +20,6 @@ import ( "hotgo/internal/library/hggen/internal/cmd/gendao" ) -var ctx = context.Background() - func dropTableWithDb(db gdb.DB, table string) { dropTableStmt := fmt.Sprintf("DROP TABLE IF EXISTS `%s`", table) if _, err := db.Exec(ctx, dropTableStmt); err != nil { @@ -105,18 +103,18 @@ func Test_Gen_Dao_Default(t *testing.T) { files, err := gfile.ScanDir(path, "*.go", true) t.AssertNil(err) t.Assert(files, []string{ - path + "/dao/internal/table_user.go", - path + "/dao/table_user.go", - path + "/model/do/table_user.go", - path + "/model/entity/table_user.go", + filepath.FromSlash(path + "/dao/internal/table_user.go"), + filepath.FromSlash(path + "/dao/table_user.go"), + filepath.FromSlash(path + "/model/do/table_user.go"), + filepath.FromSlash(path + "/model/entity/table_user.go"), }) // content testPath := gtest.DataPath("gendao", "generated_user") expectFiles := []string{ - testPath + "/dao/internal/table_user.go", - testPath + "/dao/table_user.go", - testPath + "/model/do/table_user.go", - testPath + "/model/entity/table_user.go", + filepath.FromSlash(testPath + "/dao/internal/table_user.go"), + filepath.FromSlash(testPath + "/dao/table_user.go"), + filepath.FromSlash(testPath + "/model/do/table_user.go"), + filepath.FromSlash(testPath + "/model/entity/table_user.go"), } for i, _ := range files { t.Assert(gfile.GetContents(files[i]), gfile.GetContents(expectFiles[i])) @@ -209,18 +207,18 @@ func Test_Gen_Dao_TypeMapping(t *testing.T) { files, err := gfile.ScanDir(path, "*.go", true) t.AssertNil(err) t.Assert(files, []string{ - path + "/dao/internal/table_user.go", - path + "/dao/table_user.go", - path + "/model/do/table_user.go", - path + "/model/entity/table_user.go", + filepath.FromSlash(path + "/dao/internal/table_user.go"), + filepath.FromSlash(path + "/dao/table_user.go"), + filepath.FromSlash(path + "/model/do/table_user.go"), + filepath.FromSlash(path + "/model/entity/table_user.go"), }) // content testPath := gtest.DataPath("gendao", "generated_user_type_mapping") expectFiles := []string{ - testPath + "/dao/internal/table_user.go", - testPath + "/dao/table_user.go", - testPath + "/model/do/table_user.go", - testPath + "/model/entity/table_user.go", + filepath.FromSlash(testPath + "/dao/internal/table_user.go"), + filepath.FromSlash(testPath + "/dao/table_user.go"), + filepath.FromSlash(testPath + "/model/do/table_user.go"), + filepath.FromSlash(testPath + "/model/entity/table_user.go"), } for i, _ := range files { t.Assert(gfile.GetContents(files[i]), gfile.GetContents(expectFiles[i])) diff --git a/server/internal/library/hggen/internal/cmd/cmd_z_unit_gen_service_test.go b/server/internal/library/hggen/internal/cmd/cmd_z_unit_gen_service_test.go new file mode 100644 index 0000000..40c181a --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/cmd_z_unit_gen_service_test.go @@ -0,0 +1,72 @@ +// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved. +// +// This Source Code Form is subject to the terms of the MIT License. +// If a copy of the MIT was not distributed with this file, +// You can obtain one at https://github.com/gogf/gf. + +package cmd + +import ( + "github.com/gogf/gf/v2/os/gfile" + "github.com/gogf/gf/v2/test/gtest" + "github.com/gogf/gf/v2/util/guid" + "github.com/gogf/gf/v2/util/gutil" + "hotgo/internal/library/hggen/internal/cmd/genservice" + "path/filepath" + "testing" +) + +func Test_Gen_Service_Default(t *testing.T) { + gtest.C(t, func(t *gtest.T) { + var ( + path = gfile.Temp(guid.S()) + dstFolder = path + filepath.FromSlash("/service") + apiFolder = gtest.DataPath("genservice", "logic") + in = genservice.CGenServiceInput{ + SrcFolder: apiFolder, + DstFolder: dstFolder, + DstFileNameCase: "Snake", + WatchFile: "", + StPattern: "", + Packages: nil, + ImportPrefix: "", + Clear: false, + } + ) + err := gutil.FillStructWithDefault(&in) + t.AssertNil(err) + + err = gfile.Mkdir(path) + t.AssertNil(err) + defer gfile.Remove(path) + + _, err = genservice.CGenService{}.Service(ctx, in) + if err != nil { + panic(err) + } + + // logic file + var ( + genApi = apiFolder + filepath.FromSlash("/logic.go") + genApiExpect = apiFolder + filepath.FromSlash("/logic_expect.go") + ) + defer gfile.Remove(genApi) + t.Assert(gfile.GetContents(genApi), gfile.GetContents(genApiExpect)) + + // files + files, err := gfile.ScanDir(dstFolder, "*.go", true) + t.AssertNil(err) + t.Assert(files, []string{ + dstFolder + filepath.FromSlash("/article.go"), + }) + + // contents + testPath := gtest.DataPath("genservice", "service") + expectFiles := []string{ + testPath + filepath.FromSlash("/article.go"), + } + for i := range files { + t.Assert(gfile.GetContents(files[i]), gfile.GetContents(expectFiles[i])) + } + }) +} diff --git a/server/internal/library/hggen/internal/cmd/genctrl/genctrl.go b/server/internal/library/hggen/internal/cmd/genctrl/genctrl.go index a6f6829..1c34e3a 100644 --- a/server/internal/library/hggen/internal/cmd/genctrl/genctrl.go +++ b/server/internal/library/hggen/internal/cmd/genctrl/genctrl.go @@ -38,7 +38,7 @@ gf gen ctrl ) const ( - PatternApiDefinition = `type\s+(\w+)Req\s+struct\s+{([\s\S]+?)}` + PatternApiDefinition = `type[\s\(]+(\w+)Req\s+struct\s+{([\s\S]+?)}` PatternCtrlDefinition = `func\s+\(.+?\)\s+\w+\(.+?\*(\w+)\.(\w+)Req\)\s+\(.+?\*(\w+)\.(\w+)Res,\s+\w+\s+error\)\s+{` ) diff --git a/server/internal/library/hggen/internal/cmd/genctrl/genctrl_generate_ctrl.go b/server/internal/library/hggen/internal/cmd/genctrl/genctrl_generate_ctrl.go index 5c58e73..a53baf2 100644 --- a/server/internal/library/hggen/internal/cmd/genctrl/genctrl_generate_ctrl.go +++ b/server/internal/library/hggen/internal/cmd/genctrl/genctrl_generate_ctrl.go @@ -8,6 +8,7 @@ package genctrl import ( "fmt" + "path/filepath" "github.com/gogf/gf/v2/container/gset" "github.com/gogf/gf/v2/frame/g" @@ -64,8 +65,8 @@ func (c *controllerGenerator) doGenerateCtrlNewByModuleAndVersion( dstModuleFolderPath, module, version, importPath string, ) (err error) { var ( - moduleFilePath = gfile.Join(dstModuleFolderPath, module+".go") - moduleFilePathNew = gfile.Join(dstModuleFolderPath, module+"_new.go") + moduleFilePath = filepath.FromSlash(gfile.Join(dstModuleFolderPath, module+".go")) + moduleFilePathNew = filepath.FromSlash(gfile.Join(dstModuleFolderPath, module+"_new.go")) ctrlName = fmt.Sprintf(`Controller%s`, gstr.UcFirst(version)) interfaceName = fmt.Sprintf(`%s.I%s%s`, module, gstr.CaseCamel(module), gstr.UcFirst(version)) newFuncName = fmt.Sprintf(`New%s`, gstr.UcFirst(version)) @@ -107,7 +108,7 @@ func (c *controllerGenerator) doGenerateCtrlNewByModuleAndVersion( "{NewFuncName}": newFuncName, "{InterfaceName}": interfaceName, }) - err = gfile.PutContentsAppend(moduleFilePathNew, gstr.TrimLeft(content)) + err = gfile.PutContentsAppend(moduleFilePathNew, content) if err != nil { return err } @@ -119,9 +120,9 @@ func (c *controllerGenerator) doGenerateCtrlItem(dstModuleFolderPath string, ite var ( methodNameSnake = gstr.CaseSnake(item.MethodName) ctrlName = fmt.Sprintf(`Controller%s`, gstr.UcFirst(item.Version)) - methodFilePath = gfile.Join(dstModuleFolderPath, fmt.Sprintf( + methodFilePath = filepath.FromSlash(gfile.Join(dstModuleFolderPath, fmt.Sprintf( `%s_%s_%s.go`, item.Module, item.Version, methodNameSnake, - )) + ))) ) var content string diff --git a/server/internal/library/hggen/internal/cmd/genctrl/genctrl_generate_interface.go b/server/internal/library/hggen/internal/cmd/genctrl/genctrl_generate_interface.go index 4f95015..5c0eb6a 100644 --- a/server/internal/library/hggen/internal/cmd/genctrl/genctrl_generate_interface.go +++ b/server/internal/library/hggen/internal/cmd/genctrl/genctrl_generate_interface.go @@ -8,6 +8,7 @@ package genctrl import ( "fmt" + "path/filepath" "github.com/gogf/gf/v2/container/gmap" "github.com/gogf/gf/v2/container/gset" @@ -39,18 +40,17 @@ func (c *apiInterfaceGenerator) Generate(apiModuleFolderPath string, apiModuleAp func (c *apiInterfaceGenerator) doGenerate(apiModuleFolderPath string, module string, items []apiItem) (err error) { var ( - moduleFilePath = gfile.Join(apiModuleFolderPath, fmt.Sprintf(`%s.go`, module)) + moduleFilePath = filepath.FromSlash(gfile.Join(apiModuleFolderPath, fmt.Sprintf(`%s.go`, module))) importPathMap = gmap.NewListMap() importPaths []string ) // if there's already exist file that with the same but not auto generated go file, // it uses another file name. if !utils.IsFileDoNotEdit(moduleFilePath) { - moduleFilePath = gfile.Join(apiModuleFolderPath, fmt.Sprintf(`%s.if.go`, module)) + moduleFilePath = filepath.FromSlash(gfile.Join(apiModuleFolderPath, fmt.Sprintf(`%s.if.go`, module))) } // all import paths. - importPathMap.Set("\t"+`"context"`, 1) - importPathMap.Set("\t"+``, 1) + importPathMap.Set("\t"+`"context"`+"\n", 1) for _, item := range items { importPathMap.Set(fmt.Sprintf("\t"+`"%s"`, item.Import), 1) } @@ -91,7 +91,7 @@ func (c *apiInterfaceGenerator) doGenerate(apiModuleFolderPath string, module st interfaceDefinition += "\n\n" } interfaceContent = gstr.TrimLeft(gstr.ReplaceByMap(interfaceContent, g.MapStrStr{ - "{Interfaces}": interfaceDefinition, + "{Interfaces}": gstr.TrimRightStr(interfaceDefinition, "\n", 2), })) err = gfile.PutContents(moduleFilePath, interfaceContent) mlog.Printf(`generated: %s`, moduleFilePath) diff --git a/server/internal/library/hggen/internal/cmd/genctrl/genctrl_generate_sdk.go b/server/internal/library/hggen/internal/cmd/genctrl/genctrl_generate_sdk.go index 384c6c1..e4fdbb5 100644 --- a/server/internal/library/hggen/internal/cmd/genctrl/genctrl_generate_sdk.go +++ b/server/internal/library/hggen/internal/cmd/genctrl/genctrl_generate_sdk.go @@ -8,6 +8,7 @@ package genctrl import ( "fmt" + "path/filepath" "github.com/gogf/gf/v2/container/gset" "github.com/gogf/gf/v2/frame/g" @@ -54,7 +55,7 @@ func (c *apiSdkGenerator) Generate(apiModuleApiItems []apiItem, sdkFolderPath st func (c *apiSdkGenerator) doGenerateSdkPkgFile(sdkFolderPath string) (err error) { var ( pkgName = gfile.Basename(sdkFolderPath) - pkgFilePath = gfile.Join(sdkFolderPath, fmt.Sprintf(`%s.go`, pkgName)) + pkgFilePath = filepath.FromSlash(gfile.Join(sdkFolderPath, fmt.Sprintf(`%s.go`, pkgName))) fileContent string ) if gfile.Exists(pkgFilePath) { @@ -79,7 +80,7 @@ func (c *apiSdkGenerator) doGenerateSdkIClient( funcName = gstr.CaseCamel(module) + gstr.UcFirst(version) interfaceName = fmt.Sprintf(`I%s`, funcName) moduleImportPath = gstr.Replace(fmt.Sprintf(`"%s"`, gfile.Dir(versionImportPath)), "\\", "/", -1) - iClientFilePath = gfile.Join(sdkFolderPath, fmt.Sprintf(`%s.iclient.go`, pkgName)) + iClientFilePath = filepath.FromSlash(gfile.Join(sdkFolderPath, fmt.Sprintf(`%s.iclient.go`, pkgName))) interfaceFuncDefinition = fmt.Sprintf( `%s() %s.%s`, gstr.CaseCamel(module)+gstr.UcFirst(version), module, interfaceName, @@ -145,9 +146,9 @@ func (c *apiSdkGenerator) doGenerateSdkImplementer( moduleImportPath = gstr.Replace(gfile.Dir(versionImportPath), "\\", "/", -1) versionPrefix = "" implementerName = moduleNameCamel + gstr.UcFirst(version) - implementerFilePath = gfile.Join(sdkFolderPath, fmt.Sprintf( + implementerFilePath = filepath.FromSlash(gfile.Join(sdkFolderPath, fmt.Sprintf( `%s_%s_%s.go`, pkgName, moduleNameSnake, version, - )) + ))) ) if sdkNoV1 && version == "v1" { implementerName = moduleNameCamel diff --git a/server/internal/library/hggen/internal/cmd/gendao/gendao.go b/server/internal/library/hggen/internal/cmd/gendao/gendao.go index 008dc66..da8d8f1 100644 --- a/server/internal/library/hggen/internal/cmd/gendao/gendao.go +++ b/server/internal/library/hggen/internal/cmd/gendao/gendao.go @@ -9,9 +9,10 @@ package gendao import ( "context" "fmt" - "golang.org/x/mod/modfile" "strings" + "golang.org/x/mod/modfile" + "github.com/gogf/gf/v2/container/garray" "github.com/gogf/gf/v2/database/gdb" "github.com/gogf/gf/v2/frame/g" diff --git a/server/internal/library/hggen/internal/cmd/gendao/gendao_dao.go b/server/internal/library/hggen/internal/cmd/gendao/gendao_dao.go index fca9661..98fad83 100644 --- a/server/internal/library/hggen/internal/cmd/gendao/gendao_dao.go +++ b/server/internal/library/hggen/internal/cmd/gendao/gendao_dao.go @@ -10,6 +10,7 @@ import ( "bytes" "context" "fmt" + "path/filepath" "strings" "github.com/olekukonko/tablewriter" @@ -106,7 +107,7 @@ type generateDaoIndexInput struct { } func generateDaoIndex(in generateDaoIndexInput) { - path := gfile.Join(in.DirPathDao, in.FileName+".go") + path := filepath.FromSlash(gfile.Join(in.DirPathDao, in.FileName+".go")) if in.OverwriteDao || !gfile.Exists(path) { indexContent := gstr.ReplaceByMap( getTemplateFromPathOrDefault(in.TplDaoIndexPath, consts.TemplateGenDaoIndexContent), @@ -136,7 +137,7 @@ type generateDaoInternalInput struct { } func generateDaoInternal(in generateDaoInternalInput) { - path := gfile.Join(in.DirPathDaoInternal, in.FileName+".go") + path := filepath.FromSlash(gfile.Join(in.DirPathDaoInternal, in.FileName+".go")) modelContent := gstr.ReplaceByMap( getTemplateFromPathOrDefault(in.TplDaoInternalPath, consts.TemplateGenDaoInternalContent), g.MapStrStr{ diff --git a/server/internal/library/hggen/internal/cmd/gendao/gendao_do.go b/server/internal/library/hggen/internal/cmd/gendao/gendao_do.go index d801557..035c793 100644 --- a/server/internal/library/hggen/internal/cmd/gendao/gendao_do.go +++ b/server/internal/library/hggen/internal/cmd/gendao/gendao_do.go @@ -9,6 +9,7 @@ package gendao import ( "context" "fmt" + "path/filepath" "strings" "github.com/gogf/gf/v2/frame/g" @@ -22,7 +23,7 @@ import ( ) func generateDo(ctx context.Context, in CGenDaoInternalInput) { - var dirPathDo = gfile.Join(in.Path, in.DoPath) + var dirPathDo = filepath.FromSlash(gfile.Join(in.Path, in.DoPath)) if in.Clear { doClear(ctx, dirPathDo, false) } diff --git a/server/internal/library/hggen/internal/cmd/gendao/gendao_entity.go b/server/internal/library/hggen/internal/cmd/gendao/gendao_entity.go index a6a7140..a9f5494 100644 --- a/server/internal/library/hggen/internal/cmd/gendao/gendao_entity.go +++ b/server/internal/library/hggen/internal/cmd/gendao/gendao_entity.go @@ -8,6 +8,7 @@ package gendao import ( "context" + "path/filepath" "strings" "github.com/gogf/gf/v2/frame/g" @@ -33,7 +34,7 @@ func generateEntity(ctx context.Context, in CGenDaoInternalInput) { var ( newTableName = in.NewTableNames[i] - entityFilePath = gfile.Join(dirPathEntity, gstr.CaseSnake(newTableName)+".go") + entityFilePath = filepath.FromSlash(gfile.Join(dirPathEntity, gstr.CaseSnake(newTableName)+".go")) structDefinition, appendImports = generateStructDefinition(ctx, generateStructDefinitionInput{ CGenDaoInternalInput: in, TableName: tableName, diff --git a/server/internal/library/hggen/internal/cmd/gendao/gendao_structure.go b/server/internal/library/hggen/internal/cmd/gendao/gendao_structure.go index 132f1a1..77d84b6 100644 --- a/server/internal/library/hggen/internal/cmd/gendao/gendao_structure.go +++ b/server/internal/library/hggen/internal/cmd/gendao/gendao_structure.go @@ -10,9 +10,10 @@ import ( "bytes" "context" "fmt" - "github.com/olekukonko/tablewriter" "strings" + "github.com/olekukonko/tablewriter" + "github.com/gogf/gf/v2/database/gdb" "github.com/gogf/gf/v2/frame/g" "github.com/gogf/gf/v2/text/gregex" @@ -70,7 +71,7 @@ func generateStructFieldDefinition( err error localTypeName gdb.LocalType localTypeNameStr string - jsonTag = getJsonTagFromCase(field.Name, in.JsonCase) + jsonTag = gstr.CaseConvert(field.Name, gstr.CaseTypeMatch(in.JsonCase)) ) if in.TypeMapping != nil && len(in.TypeMapping) > 0 { @@ -158,30 +159,3 @@ func formatComment(comment string) string { comment = gstr.Trim(comment) return comment } - -// getJsonTagFromCase call gstr.Case* function to convert the s to specified case. -func getJsonTagFromCase(str, caseStr string) string { - switch gstr.ToLower(caseStr) { - case gstr.ToLower("Camel"): - return gstr.CaseCamel(str) - - case gstr.ToLower("CamelLower"): - return gstr.CaseCamelLower(str) - - case gstr.ToLower("Kebab"): - return gstr.CaseKebab(str) - - case gstr.ToLower("KebabScreaming"): - return gstr.CaseKebabScreaming(str) - - case gstr.ToLower("Snake"): - return gstr.CaseSnake(str) - - case gstr.ToLower("SnakeFirstUpper"): - return gstr.CaseSnakeFirstUpper(str) - - case gstr.ToLower("SnakeScreaming"): - return gstr.CaseSnakeScreaming(str) - } - return str -} diff --git a/server/internal/library/hggen/internal/cmd/genenums/genenums_parser.go b/server/internal/library/hggen/internal/cmd/genenums/genenums_parser.go index e8b5b56..2cacf95 100644 --- a/server/internal/library/hggen/internal/cmd/genenums/genenums_parser.go +++ b/server/internal/library/hggen/internal/cmd/genenums/genenums_parser.go @@ -19,9 +19,10 @@ import ( const pkgLoadMode = 0xffffff type EnumsParser struct { - enums []EnumItem - parsedPkg map[string]struct{} - prefixes []string + enums []EnumItem + parsedPkg map[string]struct{} + prefixes []string + standardPackages map[string]struct{} } type EnumItem struct { @@ -31,23 +32,12 @@ type EnumItem struct { Type string // Pkg.ID + TypeName } -var standardPackages = make(map[string]struct{}) - -//func init() { -// stdPackages, err := packages.Load(nil, "std") -// if err != nil { -// panic(err) -// } -// for _, p := range stdPackages { -// standardPackages[p.ID] = struct{}{} -// } -//} - func NewEnumsParser(prefixes []string) *EnumsParser { return &EnumsParser{ - enums: make([]EnumItem, 0), - parsedPkg: make(map[string]struct{}), - prefixes: prefixes, + enums: make([]EnumItem, 0), + parsedPkg: make(map[string]struct{}), + prefixes: prefixes, + standardPackages: getStandardPackages(), } } @@ -59,7 +49,7 @@ func (p *EnumsParser) ParsePackages(pkgs []*packages.Package) { func (p *EnumsParser) ParsePackage(pkg *packages.Package) { // Ignore std packages. - if _, ok := standardPackages[pkg.ID]; ok { + if _, ok := p.standardPackages[pkg.ID]; ok { return } // Ignore pared packages. @@ -144,3 +134,15 @@ func (p *EnumsParser) Export() string { } return gjson.MustEncodeString(typeEnumMap) } + +func getStandardPackages() map[string]struct{} { + standardPackages := make(map[string]struct{}) + stdPackages, err := packages.Load(nil, "std") + if err != nil { + panic(err) + } + for _, p := range stdPackages { + standardPackages[p.ID] = struct{}{} + } + return standardPackages +} diff --git a/server/internal/library/hggen/internal/cmd/genpbentity/genpbentity.go b/server/internal/library/hggen/internal/cmd/genpbentity/genpbentity.go index fff71e8..8bf14c7 100644 --- a/server/internal/library/hggen/internal/cmd/genpbentity/genpbentity.go +++ b/server/internal/library/hggen/internal/cmd/genpbentity/genpbentity.go @@ -10,6 +10,7 @@ import ( "bytes" "context" "fmt" + "path/filepath" "strings" "github.com/olekukonko/tablewriter" @@ -197,7 +198,7 @@ func doGenPbEntityForArray(ctx context.Context, index int, in CGenPbEntityInput) if len(match) == 3 { gdb.AddConfigNode(tempGroup, gdb.ConfigNode{ Type: gstr.Trim(match[1]), - Link: gstr.Trim(match[2]), + Link: in.Link, }) db, _ = gdb.Instance(tempGroup) } @@ -246,7 +247,7 @@ func generatePbEntityContentFile(ctx context.Context, in CGenPbEntityInternalInp tableNameSnakeCase = gstr.CaseSnake(newTableName) entityMessageDefine = generateEntityMessageDefinition(tableNameCamelCase, fieldMap, in) fileName = gstr.Trim(tableNameSnakeCase, "-_.") - path = gfile.Join(in.Path, fileName+".proto") + path = filepath.FromSlash(gfile.Join(in.Path, fileName+".proto")) ) if gstr.Contains(entityMessageDefine, "google.protobuf.Timestamp") { imports = `import "google/protobuf/timestamp.proto";` diff --git a/server/internal/library/hggen/internal/cmd/genservice/genservice.go b/server/internal/library/hggen/internal/cmd/genservice/genservice.go index 2f3a2e2..534a1bc 100644 --- a/server/internal/library/hggen/internal/cmd/genservice/genservice.go +++ b/server/internal/library/hggen/internal/cmd/genservice/genservice.go @@ -9,6 +9,7 @@ package genservice import ( "context" "fmt" + "path/filepath" "github.com/gogf/gf/v2/container/garray" "github.com/gogf/gf/v2/container/gmap" @@ -93,10 +94,10 @@ const ( ) func (c CGenService) Service(ctx context.Context, in CGenServiceInput) (out *CGenServiceOutput, err error) { - in.SrcFolder = gstr.TrimRight(in.SrcFolder, `\/`) - in.SrcFolder = gstr.Replace(in.SrcFolder, "\\", "/") - in.WatchFile = gstr.TrimRight(in.WatchFile, `\/`) - in.WatchFile = gstr.Replace(in.WatchFile, "\\", "/") + in.SrcFolder = filepath.ToSlash(in.SrcFolder) + in.SrcFolder = gstr.TrimRight(in.SrcFolder, `/`) + in.WatchFile = filepath.ToSlash(in.WatchFile) + in.WatchFile = gstr.TrimRight(in.WatchFile, `/`) // Watch file handling. if in.WatchFile != "" { diff --git a/server/internal/library/hggen/internal/cmd/genservice/genservice_generate.go b/server/internal/library/hggen/internal/cmd/genservice/genservice_generate.go index fd1cf57..c935822 100644 --- a/server/internal/library/hggen/internal/cmd/genservice/genservice_generate.go +++ b/server/internal/library/hggen/internal/cmd/genservice/genservice_generate.go @@ -194,28 +194,9 @@ func (c CGenService) generateInitializationFile(in CGenServiceInput, importSrcPa } // getDstFileNameCase call gstr.Case* function to convert the s to specified case. -func (c CGenService) getDstFileNameCase(str, caseStr string) string { - switch gstr.ToLower(caseStr) { - case gstr.ToLower("Lower"): - return gstr.ToLower(str) - - case gstr.ToLower("Camel"): - return gstr.CaseCamel(str) - - case gstr.ToLower("CamelLower"): - return gstr.CaseCamelLower(str) - - case gstr.ToLower("Kebab"): - return gstr.CaseKebab(str) - - case gstr.ToLower("KebabScreaming"): - return gstr.CaseKebabScreaming(str) - - case gstr.ToLower("SnakeFirstUpper"): - return gstr.CaseSnakeFirstUpper(str) - - case gstr.ToLower("SnakeScreaming"): - return gstr.CaseSnakeScreaming(str) +func (c CGenService) getDstFileNameCase(str, caseStr string) (newStr string) { + if newStr := gstr.CaseConvert(str, gstr.CaseTypeMatch(caseStr)); newStr != str { + return newStr } return gstr.CaseSnake(str) } diff --git a/server/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/article_expect.go b/server/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/article_expect.go new file mode 100644 index 0000000..880d81f --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/article_expect.go @@ -0,0 +1,24 @@ +// ================================================================================= +// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT. +// ================================================================================= + +package article + +import ( + "context" + + "hotgo/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v1" + "hotgo/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v2" +) + +type IArticleV1 interface { + Create(ctx context.Context, req *v1.CreateReq) (res *v1.CreateRes, err error) + Update(ctx context.Context, req *v1.UpdateReq) (res *v1.UpdateRes, err error) + GetList(ctx context.Context, req *v1.GetListReq) (res *v1.GetListRes, err error) + GetOne(ctx context.Context, req *v1.GetOneReq) (res *v1.GetOneRes, err error) +} + +type IArticleV2 interface { + Create(ctx context.Context, req *v2.CreateReq) (res *v2.CreateRes, err error) + Update(ctx context.Context, req *v2.UpdateReq) (res *v2.UpdateRes, err error) +} diff --git a/server/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v1/edit.go b/server/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v1/edit.go new file mode 100644 index 0000000..9e893d8 --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v1/edit.go @@ -0,0 +1,27 @@ +// Copyright GoFrame Author(https://goframe.org). All Rights Reserved. +// +// This Source Code Form is subject to the terms of the MIT License. +// If a copy of the MIT was not distributed with this file, +// You can obtain one at https://github.com/gogf/gf. + +package v1 + +import "github.com/gogf/gf/v2/frame/g" + +type ( + CreateReq struct { + g.Meta `path:"/article/create" method:"post" tags:"ArticleService"` + Title string `v:"required"` + } + + CreateRes struct{} +) + +type ( + UpdateReq struct { + g.Meta `path:"/article/update" method:"post" tags:"ArticleService"` + Title string `v:"required"` + } + + UpdateRes struct{} +) diff --git a/server/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v1/get.go b/server/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v1/get.go new file mode 100644 index 0000000..36134f5 --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v1/get.go @@ -0,0 +1,25 @@ +// Copyright GoFrame Author(https://goframe.org). All Rights Reserved. +// +// This Source Code Form is subject to the terms of the MIT License. +// If a copy of the MIT was not distributed with this file, +// You can obtain one at https://github.com/gogf/gf. + +package v1 + +import "github.com/gogf/gf/v2/frame/g" + +type GetListReq struct { + g.Meta `path:"/article/list" method:"get" tags:"ArticleService"` +} + +type GetListRes struct { + list []struct{} +} + +type GetOneReq struct { + g.Meta `path:"/article/one" method:"get" tags:"ArticleService"` +} + +type GetOneRes struct { + one struct{} +} diff --git a/server/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v2/edit.go b/server/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v2/edit.go new file mode 100644 index 0000000..8e8267a --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v2/edit.go @@ -0,0 +1,23 @@ +// Copyright GoFrame Author(https://goframe.org). All Rights Reserved. +// +// This Source Code Form is subject to the terms of the MIT License. +// If a copy of the MIT was not distributed with this file, +// You can obtain one at https://github.com/gogf/gf. + +package v2 + +import "github.com/gogf/gf/v2/frame/g" + +type CreateReq struct { + g.Meta `path:"/article/create" method:"post" tags:"ArticleService"` + Title string `v:"required"` +} + +type CreateRes struct{} + +type UpdateReq struct { + g.Meta `path:"/article/update" method:"post" tags:"ArticleService"` + Title string `v:"required"` +} + +type UpdateRes struct{} diff --git a/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article.go b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article.go new file mode 100644 index 0000000..4bd478c --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article.go @@ -0,0 +1,5 @@ +// ================================================================================= +// This is auto-generated by GoFrame CLI tool only once. Fill this file as you wish. +// ================================================================================= + +package article diff --git a/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_new.go b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_new.go new file mode 100644 index 0000000..c4ac00e --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_new.go @@ -0,0 +1,21 @@ +// ================================================================================= +// This is auto-generated by GoFrame CLI tool only once. Fill this file as you wish. +// ================================================================================= + +package article + +import ( + "hotgo/internal/library/hggen/internal/cmd/testdata/genctrl/api/article" +) + +type ControllerV1 struct{} + +func NewV1() article.IArticleV1 { + return &ControllerV1{} +} + +type ControllerV2 struct{} + +func NewV2() article.IArticleV2 { + return &ControllerV2{} +} diff --git a/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v1_create.go b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v1_create.go new file mode 100644 index 0000000..1b37e99 --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v1_create.go @@ -0,0 +1,14 @@ +package article + +import ( + "context" + + "github.com/gogf/gf/v2/errors/gcode" + "github.com/gogf/gf/v2/errors/gerror" + + "hotgo/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v1" +) + +func (c *ControllerV1) Create(ctx context.Context, req *v1.CreateReq) (res *v1.CreateRes, err error) { + return nil, gerror.NewCode(gcode.CodeNotImplemented) +} diff --git a/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v1_get_list.go b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v1_get_list.go new file mode 100644 index 0000000..a0f48e8 --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v1_get_list.go @@ -0,0 +1,14 @@ +package article + +import ( + "context" + + "github.com/gogf/gf/v2/errors/gcode" + "github.com/gogf/gf/v2/errors/gerror" + + "hotgo/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v1" +) + +func (c *ControllerV1) GetList(ctx context.Context, req *v1.GetListReq) (res *v1.GetListRes, err error) { + return nil, gerror.NewCode(gcode.CodeNotImplemented) +} diff --git a/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v1_get_one.go b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v1_get_one.go new file mode 100644 index 0000000..e258f06 --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v1_get_one.go @@ -0,0 +1,14 @@ +package article + +import ( + "context" + + "github.com/gogf/gf/v2/errors/gcode" + "github.com/gogf/gf/v2/errors/gerror" + + "hotgo/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v1" +) + +func (c *ControllerV1) GetOne(ctx context.Context, req *v1.GetOneReq) (res *v1.GetOneRes, err error) { + return nil, gerror.NewCode(gcode.CodeNotImplemented) +} diff --git a/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v1_update.go b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v1_update.go new file mode 100644 index 0000000..7919aa2 --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v1_update.go @@ -0,0 +1,14 @@ +package article + +import ( + "context" + + "github.com/gogf/gf/v2/errors/gcode" + "github.com/gogf/gf/v2/errors/gerror" + + "hotgo/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v1" +) + +func (c *ControllerV1) Update(ctx context.Context, req *v1.UpdateReq) (res *v1.UpdateRes, err error) { + return nil, gerror.NewCode(gcode.CodeNotImplemented) +} diff --git a/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v2_create.go b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v2_create.go new file mode 100644 index 0000000..7b435f2 --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v2_create.go @@ -0,0 +1,14 @@ +package article + +import ( + "context" + + "github.com/gogf/gf/v2/errors/gcode" + "github.com/gogf/gf/v2/errors/gerror" + + "hotgo/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v2" +) + +func (c *ControllerV2) Create(ctx context.Context, req *v2.CreateReq) (res *v2.CreateRes, err error) { + return nil, gerror.NewCode(gcode.CodeNotImplemented) +} diff --git a/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v2_update.go b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v2_update.go new file mode 100644 index 0000000..e91a6ac --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/testdata/genctrl/controller/article/article_v2_update.go @@ -0,0 +1,14 @@ +package article + +import ( + "context" + + "github.com/gogf/gf/v2/errors/gcode" + "github.com/gogf/gf/v2/errors/gerror" + + "hotgo/internal/library/hggen/internal/cmd/testdata/genctrl/api/article/v2" +) + +func (c *ControllerV2) Update(ctx context.Context, req *v2.UpdateReq) (res *v2.UpdateRes, err error) { + return nil, gerror.NewCode(gcode.CodeNotImplemented) +} diff --git a/server/internal/library/hggen/internal/cmd/testdata/genservice/logic/article/article.go b/server/internal/library/hggen/internal/cmd/testdata/genservice/logic/article/article.go new file mode 100644 index 0000000..7c88653 --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/testdata/genservice/logic/article/article.go @@ -0,0 +1,33 @@ +// Copyright GoFrame Author(https://goframe.org). All Rights Reserved. +// +// This Source Code Form is subject to the terms of the MIT License. +// If a copy of the MIT was not distributed with this file, +// You can obtain one at https://github.com/gogf/gf. + +package article + +import ( + "context" + "hotgo/internal/library/hggen/internal/cmd/testdata/genservice/service" +) + +type sArticle struct { +} + +func init() { + service.RegisterArticle(&sArticle{}) +} + +// Get article details +func (s *sArticle) Get(ctx context.Context, id uint) (info struct{}, err error) { + return struct{}{}, err +} + +// Create +/** + * create an article. + * @author oldme + */ +func (s *sArticle) Create(ctx context.Context, info struct{}) (id uint, err error) { + return id, err +} diff --git a/server/internal/library/hggen/internal/cmd/testdata/genservice/logic/logic_expect.go b/server/internal/library/hggen/internal/cmd/testdata/genservice/logic/logic_expect.go new file mode 100644 index 0000000..bf9475c --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/testdata/genservice/logic/logic_expect.go @@ -0,0 +1,9 @@ +// ========================================================================== +// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT. +// ========================================================================== + +package logic + +import ( + _ "hotgo/internal/library/hggen/internal/cmd/testdata/genservice/logic/article" +) diff --git a/server/internal/library/hggen/internal/cmd/testdata/genservice/service/article.go b/server/internal/library/hggen/internal/cmd/testdata/genservice/service/article.go new file mode 100644 index 0000000..765a1c8 --- /dev/null +++ b/server/internal/library/hggen/internal/cmd/testdata/genservice/service/article.go @@ -0,0 +1,38 @@ +// ================================================================================ +// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT. +// You can delete these comments if you wish manually maintain this interface file. +// ================================================================================ + +package service + +import ( + "context" +) + +type ( + IArticle interface { + // Get article details + Get(ctx context.Context, id uint) (info struct{}, err error) + // Create + /** + * create an article. + * @author oldme + */ + Create(ctx context.Context, info struct{}) (id uint, err error) + } +) + +var ( + localArticle IArticle +) + +func Article() IArticle { + if localArticle == nil { + panic("implement not found for interface IArticle, forgot register?") + } + return localArticle +} + +func RegisterArticle(i IArticle) { + localArticle = i +} diff --git a/server/internal/library/hggen/internal/consts/consts_gen_ctrl_template.go b/server/internal/library/hggen/internal/consts/consts_gen_ctrl_template.go index a51786d..9197992 100644 --- a/server/internal/library/hggen/internal/consts/consts_gen_ctrl_template.go +++ b/server/internal/library/hggen/internal/consts/consts_gen_ctrl_template.go @@ -12,12 +12,11 @@ const TemplateGenCtrlControllerEmpty = ` // ================================================================================= package {Module} - ` const TemplateGenCtrlControllerNewEmpty = ` // ================================================================================= -// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT. +// This is auto-generated by GoFrame CLI tool only once. Fill this file as you wish. // ================================================================================= package {Module} @@ -25,7 +24,6 @@ package {Module} import ( {ImportPath} ) - ` const TemplateGenCtrlControllerNewFunc = ` @@ -34,7 +32,6 @@ type {CtrlName} struct{} func {NewFuncName}() {InterfaceName} { return &{CtrlName}{} } - ` const TemplateGenCtrlControllerMethodFunc = ` @@ -63,7 +60,7 @@ func (c *{CtrlName}) {MethodName}(ctx context.Context, req *{Version}.{MethodNam const TemplateGenCtrlApiInterface = ` // ================================================================================= -// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT. +// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT. // ================================================================================= package {Module} diff --git a/server/internal/library/hggen/internal/utility/utils/utils.go b/server/internal/library/hggen/internal/utility/utils/utils.go index fc7fa74..8cc2f09 100644 --- a/server/internal/library/hggen/internal/utility/utils/utils.go +++ b/server/internal/library/hggen/internal/utility/utils/utils.go @@ -118,7 +118,7 @@ func GetImportPath(filePath string) string { func GetModPath() string { var ( oldDir = gfile.Pwd() - newDir = gfile.Dir(oldDir) + newDir = oldDir goModName = "go.mod" goModPath string ) @@ -127,11 +127,11 @@ func GetModPath() string { if gfile.Exists(goModPath) { return goModPath } - oldDir = newDir newDir = gfile.Dir(oldDir) if newDir == oldDir { break } + oldDir = newDir } return "" } diff --git a/server/internal/library/hggen/views/column_default.go b/server/internal/library/hggen/views/column_default.go index e00299a..e207d6e 100644 --- a/server/internal/library/hggen/views/column_default.go +++ b/server/internal/library/hggen/views/column_default.go @@ -9,7 +9,6 @@ import ( "github.com/gogf/gf/v2/text/gstr" "hotgo/internal/consts" "hotgo/internal/model/input/sysin" - "strings" ) // 默认表单组件映射 Ts -> 表单组件 @@ -119,7 +118,7 @@ func setDefault(field *sysin.GenCodesColumnListModel) { field.Required = true } - if strings.Contains(field.Index, consts.GenCodesIndexUNI) { + if IsIndexUNI(field.Index) { field.Unique = true } @@ -136,7 +135,7 @@ func setDefault(field *sysin.GenCodesColumnListModel) { func setDefaultEdit(field *sysin.GenCodesColumnListModel) { field.IsEdit = true - if field.Index == consts.GenCodesIndexPK { + if IsIndexPK(field.Index) { field.IsEdit = false return } @@ -258,7 +257,7 @@ func setDefaultExport(field *sysin.GenCodesColumnListModel) { func setDefaultQuery(field *sysin.GenCodesColumnListModel) { field.IsQuery = false - if field.Index == consts.GenCodesIndexPK { + if IsIndexPK(field.Index) { field.IsQuery = true return } diff --git a/server/internal/library/hggen/views/curd_generate_web_edit.go b/server/internal/library/hggen/views/curd_generate_web_edit.go index 6a5fa5a..d8edf6d 100644 --- a/server/internal/library/hggen/views/curd_generate_web_edit.go +++ b/server/internal/library/hggen/views/curd_generate_web_edit.go @@ -11,7 +11,6 @@ import ( "fmt" "github.com/gogf/gf/v2/frame/g" "github.com/gogf/gf/v2/text/gstr" - "hotgo/internal/consts" ) func (l *gCurd) webEditTplData(ctx context.Context, in *CurdPreviewInput) (data g.Map, err error) { @@ -28,7 +27,7 @@ func (l *gCurd) generateWebEditFormItem(ctx context.Context, in *CurdPreviewInpu continue } - if field.Index == consts.GenCodesIndexPK { + if IsIndexPK(field.Index) { continue } diff --git a/server/internal/library/hggen/views/utils.go b/server/internal/library/hggen/views/utils.go index d105dac..f1f331e 100644 --- a/server/internal/library/hggen/views/utils.go +++ b/server/internal/library/hggen/views/utils.go @@ -34,7 +34,7 @@ func (l *gCurd) getPkField(in *CurdPreviewInput) *sysin.GenCodesColumnListModel panic("getPkField masterFields uninitialized.") } for _, field := range in.masterFields { - if field.Index == consts.GenCodesIndexPK { + if IsIndexPK(field.Index) { return field } } @@ -165,3 +165,13 @@ func GetModName(ctx context.Context) (modName string, err error) { } return } + +// IsIndexPK 是否是主键 +func IsIndexPK(index string) bool { + return gstr.ToUpper(index) == gstr.ToUpper(consts.GenCodesIndexPK) +} + +// IsIndexUNI 是否是唯一索引 +func IsIndexUNI(index string) bool { + return gstr.ToUpper(index) == gstr.ToUpper(consts.GenCodesIndexUNI) +} diff --git a/server/internal/library/hgorm/dao.go b/server/internal/library/hgorm/dao.go index 1eefffd..7472a08 100644 --- a/server/internal/library/hgorm/dao.go +++ b/server/internal/library/hgorm/dao.go @@ -14,7 +14,6 @@ import ( "github.com/gogf/gf/v2/frame/g" "github.com/gogf/gf/v2/text/gstr" "hotgo/utility/convert" - "hotgo/utility/tree" ) type daoInstance interface { @@ -117,6 +116,23 @@ func GetPkField(ctx context.Context, dao daoInstance) (string, error) { return "", gerror.New("no primary key") } +// GetFieldsToSlice 获取dao实例中的所有字段 +func GetFieldsToSlice(ctx context.Context, dao daoInstance) ([]string, error) { + fields, err := dao.Ctx(ctx).TableFields(dao.Table()) + if err != nil { + return nil, err + } + if len(fields) == 0 { + return nil, gerror.New("field not found") + } + + var keys []string + for _, field := range fields { + keys = append(keys, field.Name) + } + return keys, nil +} + // IsUnique 是否唯一 func IsUnique(ctx context.Context, dao daoInstance, where g.Map, message string, pkId ...interface{}) error { if len(where) == 0 { @@ -148,40 +164,3 @@ func IsUnique(ctx context.Context, dao daoInstance, where g.Map, message string, } return nil } - -// GenSubTree 生成下级关系树 -func GenSubTree(ctx context.Context, dao daoInstance, oldPid int64) (newPid int64, newLevel int, subTree string, err error) { - // 顶级树 - if oldPid <= 0 { - return 0, 1, "", nil - } - - field, err := GetPkField(ctx, dao) - if err != nil { - return 0, 0, "", err - } - - models, err := dao.Ctx(ctx).Where(field, oldPid).One() - if err != nil { - return 0, 0, "", err - } - - if models.IsEmpty() { - return 0, 0, "", gerror.New("上级信息不存在") - } - - level, ok := models["level"] - if !ok { - return 0, 0, "", gerror.New("表中必须包含`level`字段") - } - - supTree, ok := models["tree"] - if !ok { - return 0, 0, "", gerror.New("表中必须包含`tree`字段") - } - - newPid = oldPid - newLevel = level.Int() + 1 - subTree = tree.GenLabel(supTree.String(), oldPid) - return -} diff --git a/server/internal/library/hgorm/dao_tree.go b/server/internal/library/hgorm/dao_tree.go new file mode 100644 index 0000000..68a2867 --- /dev/null +++ b/server/internal/library/hgorm/dao_tree.go @@ -0,0 +1,146 @@ +// Package hgorm +// @Link https://github.com/bufanyun/hotgo +// @Copyright Copyright (c) 2023 HotGo CLI +// @Author Ms <133814250@qq.com> +// @License https://github.com/bufanyun/hotgo/blob/master/LICENSE +package hgorm + +import ( + "context" + "github.com/gogf/gf/v2/errors/gerror" + "github.com/gogf/gf/v2/frame/g" + "hotgo/internal/model" + "hotgo/utility/tree" + "hotgo/utility/validate" +) + +// GenSubTree 生成下级关系树 +func GenSubTree(ctx context.Context, dao daoInstance, oldPid int64) (newPid int64, newLevel int, subTree string, err error) { + if err = CheckTreeTable(ctx, dao); err != nil { + return + } + + if oldPid <= 0 { + return 0, 1, "", nil + } + + var models *model.DefaultTree + if err = dao.Ctx(ctx).WherePri(oldPid).Scan(&models); err != nil { + return 0, 0, "", err + } + + if models == nil { + return 0, 0, "", gerror.New("上级信息不存在") + } + + newPid = oldPid + newLevel = models.Level + 1 + subTree = tree.GenLabel(models.Tree, oldPid) + return +} + +// CheckTreeTable 检查树表 +func CheckTreeTable(ctx context.Context, dao daoInstance) (err error) { + fields, err := GetFieldsToSlice(ctx, dao) + if err != nil { + return err + } + + if !validate.InSlice(fields, "pid") { + return gerror.New("树表必须包含`pid`字段") + } + + if !validate.InSlice(fields, "level") { + return gerror.New("树表必须包含`level`字段") + } + + if !validate.InSlice(fields, "tree") { + return gerror.New("树表必须包含`tree`字段") + } + return +} + +// AutoUpdateTree 自动更新关系树 +func AutoUpdateTree(ctx context.Context, dao daoInstance, id, pid int64) (newPid int64, newLevel int, newTree string, err error) { + if err = CheckTreeTable(ctx, dao); err != nil { + return + } + + if pid <= 0 { + newPid = 0 + newLevel = 1 + newTree = "" + } else { + var pd *model.DefaultTree + if err = dao.Ctx(ctx).WherePri(pid).Scan(&pd); err != nil { + return 0, 0, "", err + } + + if pd == nil { + return 0, 0, "", gerror.New("未查询到树表上级信息,请检查!") + } + + if id > 0 && validate.InSlice(tree.GetIds(pd.Tree), id) { + return 0, 0, "", gerror.New("上级不能设为自己当前的子级!") + } + + newPid = pid + newLevel = pd.Level + 1 + newTree = tree.GenLabel(pd.Tree, pid) + } + + if id > 0 { + if pid == id { + return 0, 0, "", gerror.New("上级不能是自己!") + } + + var models *model.DefaultTree + if err = dao.Ctx(ctx).WherePri(id).Scan(&models); err != nil { + return 0, 0, "", err + } + + if models == nil { + return 0, 0, "", gerror.New("树表信息不存在,请检查!") + } + + // 上级发生变化时,遍历修改其所有的下级关系树 + if models.Pid != pid { + if err = updateChildrenTree(ctx, dao, models.Id, newLevel, newTree); err != nil { + return + } + } + } + return +} + +// updateChildrenTree 更新下级关系树 +func updateChildrenTree(ctx context.Context, dao daoInstance, pid int64, pLevel int, pTree string) (err error) { + var list []*model.DefaultTree + if err = dao.Ctx(ctx).Where("pid", pid).Scan(&list); err != nil { + return + } + + if len(list) == 0 { + return + } + + newLevel := pLevel + 1 + newTree := tree.GenLabel(pTree, pid) + + var updateIds []int64 + for _, v := range list { + updateIds = append(updateIds, v.Id) + if err = updateChildrenTree(ctx, dao, v.Id, newLevel, newTree); err != nil { + return + } + } + + if len(updateIds) > 0 { + update := g.Map{ + "level": newLevel, + "tree": newTree, + } + _, err = dao.Ctx(ctx).WhereIn("id", updateIds).Data(update).Update() + } + return +} diff --git a/server/internal/library/hgorm/handler/sorter.go b/server/internal/library/hgorm/handler/sorter.go index 9e21c53..a3f7edc 100644 --- a/server/internal/library/hgorm/handler/sorter.go +++ b/server/internal/library/hgorm/handler/sorter.go @@ -104,7 +104,7 @@ func Sorter(in ISorter) func(m *gdb.Model) *gdb.Model { // 不存在排序条件,默认使用主表主键做降序排序 var pk string for name, field := range fields { - if gstr.ContainsI(field.Key, consts.GenCodesIndexPK) { + if gstr.ContainsI(gstr.ToUpper(field.Key), gstr.ToUpper(consts.GenCodesIndexPK)) { pk = name break } diff --git a/server/internal/library/network/tcp/conn.go b/server/internal/library/network/tcp/conn.go index d0ba9f7..3117fd5 100644 --- a/server/internal/library/network/tcp/conn.go +++ b/server/internal/library/network/tcp/conn.go @@ -48,6 +48,10 @@ type Conn struct { var idCounter int64 +var pkgOption = gtcp.PkgOption{ + MaxDataSize: 0x7FFFFFFF, +} + func NewConn(conn *gtcp.Conn, logger *glog.Logger, msgParser *MsgParser) *Conn { tcpConn := new(Conn) tcpConn.CID = atomic.AddInt64(&idCounter, 1) @@ -66,6 +70,7 @@ func NewConn(conn *gtcp.Conn, logger *glog.Logger, msgParser *MsgParser) *Conn { break } if err := conn.SendPkg(b); err != nil { + logger.Errorf(gctx.New(), "SendPkg err:%+v", err) break } } diff --git a/server/internal/library/storager/upload.go b/server/internal/library/storager/upload.go index d4c9dad..5f6a58b 100644 --- a/server/internal/library/storager/upload.go +++ b/server/internal/library/storager/upload.go @@ -50,6 +50,8 @@ func New(name ...string) UploadDrive { drive = &OssDrive{} case consts.UploadDriveQiNiu: drive = &QiNiuDrive{} + case consts.UploadDriveMinio: + drive = &MinioDrive{} default: panic(fmt.Sprintf("暂不支持的存储驱动:%v", driveType)) } @@ -82,6 +84,11 @@ func DoUpload(ctx context.Context, typ string, file *ghttp.UploadFile) (result * err = gerror.Newf("图片大小不能超过%vMB", config.ImageSize) return } + + if len(config.ImageType) > 0 && !validate.InSlice(strings.Split(config.ImageType, `,`), meta.Ext) { + err = gerror.New("上传图片类型未经允许") + return + } case KindDoc: if !IsDocType(meta.Ext) { err = gerror.New("上传的文件不是文档") @@ -110,6 +117,11 @@ func DoUpload(ctx context.Context, typ string, file *ghttp.UploadFile) (result * err = gerror.Newf("文件大小不能超过%vMB", config.FileSize) return } + + if len(config.FileType) > 0 && !validate.InSlice(strings.Split(config.FileType, `,`), meta.Ext) { + err = gerror.New("上传文件类型未经允许") + return + } } result, err = hasFile(ctx, meta.Md5) @@ -148,6 +160,8 @@ func LastUrl(ctx context.Context, fullPath, drive string) string { return config.OssBucketURL + "/" + fullPath case consts.UploadDriveQiNiu: return config.QiNiuDomain + "/" + fullPath + case consts.UploadDriveMinio: + return fmt.Sprintf("%s/%s/%s", config.MinioDomain, config.MinioBucket, fullPath) default: return fullPath } diff --git a/server/internal/library/storager/upload_minio.go b/server/internal/library/storager/upload_minio.go new file mode 100644 index 0000000..2bab918 --- /dev/null +++ b/server/internal/library/storager/upload_minio.go @@ -0,0 +1,64 @@ +// Package storager +// @Link https://github.com/bufanyun/hotgo +// @Copyright Copyright (c) 2023 HotGo CLI +// @Author Ms <133814250@qq.com> +// @License https://github.com/bufanyun/hotgo/blob/master/LICENSE +package storager + +import ( + "context" + "github.com/gogf/gf/v2/errors/gerror" + "github.com/gogf/gf/v2/net/ghttp" + "github.com/gogf/gf/v2/os/gfile" + "github.com/minio/minio-go/v7" + "github.com/minio/minio-go/v7/pkg/credentials" + "github.com/minio/minio-go/v7/pkg/s3utils" + "mime" + "path/filepath" +) + +// MinioDrive minio对象存储驱动 +type MinioDrive struct { +} + +// Upload 上传到minio对象存储 +func (d *MinioDrive) Upload(ctx context.Context, file *ghttp.UploadFile) (fullPath string, err error) { + if config.MinioPath == "" { + err = gerror.New("minio存储驱动必须配置存储路径!") + return + } + + client, err := minio.New(config.MinioEndpoint, &minio.Options{ + Creds: credentials.NewStaticV4(config.MinioAccessKey, config.MinioSecretKey, ""), + Secure: config.MinioUseSSL == 1, + }) + + if err != nil { + return "", err + } + + if err = s3utils.CheckValidBucketName(config.MinioBucket); err != nil { + return + } + + fullPath = GenFullPath(config.MinioPath, gfile.Ext(file.Filename)) + if err = s3utils.CheckValidObjectName(fullPath); err != nil { + return + } + + reader, err := file.Open() + if err != nil { + return "", err + } + defer reader.Close() + + opts := minio.PutObjectOptions{ + ContentType: mime.TypeByExtension(filepath.Ext(file.Filename)), + } + if opts.ContentType == "" { + opts.ContentType = "application/octet-stream" + } + + _, err = client.PutObject(ctx, config.MinioBucket, fullPath, reader, file.Size, opts) + return +} diff --git a/server/internal/logic/admin/member.go b/server/internal/logic/admin/member.go index 5f3155d..51b646e 100644 --- a/server/internal/logic/admin/member.go +++ b/server/internal/logic/admin/member.go @@ -15,7 +15,6 @@ import ( "github.com/gogf/gf/v2/frame/g" "github.com/gogf/gf/v2/os/gtime" "github.com/gogf/gf/v2/text/gstr" - "github.com/gogf/gf/v2/util/gconv" "github.com/gogf/gf/v2/util/grand" "hotgo/internal/consts" "hotgo/internal/dao" @@ -403,28 +402,39 @@ func (s *sAdminMember) VerifyUnique(ctx context.Context, in *adminin.VerifyUniqu // Delete 删除用户 func (s *sAdminMember) Delete(ctx context.Context, in *adminin.MemberDeleteInp) (err error) { - if s.VerifySuperId(ctx, gconv.Int64(in.Id)) { - err = gerror.New("超管账号禁止删除!") - return - } - memberId := contexts.GetUserId(ctx) if memberId <= 0 { err = gerror.New("获取用户信息失败!") return } - var models *entity.AdminMember - if err = s.FilterAuthModel(ctx, memberId).WherePri(in.Id).Scan(&models); err != nil { + var list []*entity.AdminMember + if err = s.FilterAuthModel(ctx, memberId).WherePri(in.Id).Scan(&list); err != nil { err = gerror.Wrap(err, "获取用户信息失败,请稍后重试!") return } - if models == nil { + if len(list) == 0 { err = gerror.New("需要删除的用户不存在或已删除!") return } + for _, v := range list { + if s.VerifySuperId(ctx, v.Id) { + err = gerror.New("超管账号禁止删除!") + return + } + count, err := dao.AdminMember.Ctx(ctx).Where("pid", v.Id).Count() + if err != nil { + err = gerror.Wrap(err, "删除用户检查失败,请稍后重试!") + return err + } + if count > 0 { + err = gerror.Newf("用户[%v]存在下级,请先删除TA的下级用户!", v.Id) + return err + } + } + return g.DB().Transaction(ctx, func(ctx context.Context, tx gdb.TX) (err error) { if _, err = s.FilterAuthModel(ctx, memberId).WherePri(in.Id).Delete(); err != nil { err = gerror.Wrap(err, "删除用户失败,请稍后重试!") @@ -434,6 +444,9 @@ func (s *sAdminMember) Delete(ctx context.Context, in *adminin.MemberDeleteInp) if _, err = dao.AdminMemberPost.Ctx(ctx).Where("member_id", in.Id).Delete(); err != nil { err = gerror.Wrap(err, "删除用户岗位失败,请稍后重试!") } + + // 这里如果需要,可以加入更多删除用户的相关处理 + // ... return }) } @@ -603,6 +616,14 @@ func (s *sAdminMember) List(ctx context.Context, in *adminin.MemberListInp) (lis mod = mod.Where(cols.RoleId, in.RoleId) } + if in.Id > 0 { + mod = mod.Where(cols.Id, in.Id) + } + + if in.Pid > 0 { + mod = mod.Where(cols.Pid, in.Pid) + } + if len(in.CreatedAt) == 2 { mod = mod.WhereBetween(cols.CreatedAt, gtime.New(in.CreatedAt[0]), gtime.New(in.CreatedAt[1])) } diff --git a/server/internal/logic/admin/menu.go b/server/internal/logic/admin/menu.go index dbb6cb8..986dc79 100644 --- a/server/internal/logic/admin/menu.go +++ b/server/internal/logic/admin/menu.go @@ -7,22 +7,23 @@ package admin import ( "context" + "github.com/gogf/gf/v2/database/gdb" "github.com/gogf/gf/v2/errors/gerror" "github.com/gogf/gf/v2/frame/g" - "github.com/gogf/gf/v2/os/gtime" "github.com/gogf/gf/v2/text/gstr" "github.com/gogf/gf/v2/util/gconv" + "github.com/gogf/gf/v2/util/gmode" "hotgo/api/admin/role" "hotgo/internal/consts" "hotgo/internal/dao" "hotgo/internal/library/casbin" "hotgo/internal/library/contexts" "hotgo/internal/library/hgorm" - "hotgo/internal/model/do" "hotgo/internal/model/entity" "hotgo/internal/model/input/adminin" "hotgo/internal/service" "hotgo/utility/convert" + "hotgo/utility/validate" ) type sAdminMenu struct{} @@ -91,44 +92,25 @@ func (s *sAdminMenu) Edit(ctx context.Context, in *adminin.MenuEditInp) (err err return } - var pd *do.AdminMenu - - // 维护菜单等级 - if in.Pid == 0 { - in.Level = 1 - } else { - if err = dao.AdminMenu.Ctx(ctx).Where("id", in.Pid).Scan(&pd); err != nil { - err = gerror.Wrap(err, consts.ErrorORM) + return g.DB().Transaction(ctx, func(ctx context.Context, tx gdb.TX) error { + in.Pid, in.Level, in.Tree, err = hgorm.AutoUpdateTree(ctx, &dao.AdminMenu, in.Id, in.Pid) + if err != nil { return err } - if pd == nil { - return gerror.New("上级菜单信息错误") - } - in.Level = gconv.Int(pd.Level) + 1 - } - // 修改 - in.UpdatedAt = gtime.Now() - if in.Id > 0 { - if in.Pid == in.Id { - return gerror.New("上级菜单不能是当前菜单") - } - - if _, err = dao.AdminMenu.Ctx(ctx).Where("id", in.Id).Data(in).Update(); err != nil { - err = gerror.Wrap(err, "修改菜单失败!") - return err + if in.Id > 0 { + if _, err = dao.AdminMenu.Ctx(ctx).Where("id", in.Id).Data(in).Update(); err != nil { + err = gerror.Wrap(err, "修改菜单失败!") + return err + } + } else { + if _, err = dao.AdminMenu.Ctx(ctx).Data(in).Insert(); err != nil { + err = gerror.Wrap(err, "新增菜单失败!") + return err + } } return casbin.Refresh(ctx) - } - - // 新增 - in.CreatedAt = gtime.Now() - - if _, err = dao.AdminMenu.Ctx(ctx).Data(in).Insert(); err != nil { - err = gerror.Wrap(err, "新增菜单失败!") - return err - } - return casbin.Refresh(ctx) + }) } // List 获取菜单列表 @@ -215,6 +197,18 @@ func (s *sAdminMenu) GetMenuList(ctx context.Context, memberId int64) (res *role return } + // 生产环境下隐藏一些菜单 + if gmode.IsProduct() { + newMenus := make([]*adminin.MenuRouteSummary, 0) + devMenus := []string{"Develops", "doc"} // 如果你还有其他需要在生产环境隐藏的菜单,将菜单别名加入即可 + for _, menu := range allMenus { + if !validate.InSlice(devMenus, menu.Name) { + newMenus = append(newMenus, menu) + } + } + allMenus = newMenus + } + for _, v := range allMenus { treeMap[gconv.String(v.Pid)] = append(treeMap[gconv.String(v.Pid)], v) } diff --git a/server/internal/logic/hook/access_log.go b/server/internal/logic/hook/access_log.go index 0ea56db..6bc6830 100644 --- a/server/internal/logic/hook/access_log.go +++ b/server/internal/logic/hook/access_log.go @@ -27,7 +27,7 @@ func (s *sHook) accessLog(r *ghttp.Request) { } contexts.SetDataMap(ctx, g.Map{ - "request.takeUpTime": gtime.TimestampMilli() - r.EnterTime, + "request.takeUpTime": gtime.Now().Sub(gtime.New(r.EnterTime)).Milliseconds(), // ... }) diff --git a/server/internal/logic/middleware/init.go b/server/internal/logic/middleware/init.go index a1d5215..fd7498d 100644 --- a/server/internal/logic/middleware/init.go +++ b/server/internal/logic/middleware/init.go @@ -63,12 +63,18 @@ func (s *sMiddleware) Ctx(r *ghttp.Request) { r.SetCtx(ctx) } + data := g.Map{ + "request.body": gjson.New(r.GetBodyString()), + } + contexts.Init(r, &model.Context{ - Data: make(g.Map), + Data: data, Module: getModule(r.URL.Path), }) - contexts.SetData(r.Context(), "request.body", gjson.New(r.GetBodyString())) + if len(r.Cookie.GetSessionId()) == 0 { + r.Cookie.SetSessionId(gctx.CtxId(r.Context())) + } r.Middleware.Next() } diff --git a/server/internal/logic/middleware/pre_filter.go b/server/internal/logic/middleware/pre_filter.go index 8a61a10..17e751d 100644 --- a/server/internal/logic/middleware/pre_filter.go +++ b/server/internal/logic/middleware/pre_filter.go @@ -1,7 +1,7 @@ package middleware import ( - "github.com/gogf/gf/v2/errors/gcode" + "github.com/gogf/gf/v2/errors/gerror" "github.com/gogf/gf/v2/net/ghttp" "github.com/gogf/gf/v2/util/gconv" "hotgo/internal/library/response" @@ -68,7 +68,8 @@ func (s *sMiddleware) PreFilter(r *ghttp.Request) { // 先验证基本校验规则 if err := r.Parse(inputObject.Interface()); err != nil { - response.JsonExit(r, gcode.CodeInvalidRequest.Code(), err.Error()) + resp := gerror.Code(err) + response.JsonExit(r, resp.Code(), gerror.Current(err).Error(), resp.Detail()) return } @@ -80,7 +81,8 @@ func (s *sMiddleware) PreFilter(r *ghttp.Request) { // 执行预处理 if err := validate.PreFilter(r.Context(), inputObject.Interface()); err != nil { - response.JsonExit(r, gcode.CodeInvalidParameter.Code(), err.Error()) + resp := gerror.Code(err) + response.JsonExit(r, resp.Code(), gerror.Current(err).Error(), resp.Detail()) return } diff --git a/server/internal/logic/middleware/response.go b/server/internal/logic/middleware/response.go index f41d8b2..beb8493 100644 --- a/server/internal/logic/middleware/response.go +++ b/server/internal/logic/middleware/response.go @@ -87,8 +87,10 @@ func parseResponse(r *ghttp.Request) (code int, message string, resp interface{} code = gerror.Code(err).Code() // 记录异常日志 + // 如果你想对错误做不同的处理,可以通过定义不同的错误码来区分 + // 默认-1为安全可控错误码只记录文件日志,非-1为不可控错误,记录文件日志+服务日志并打印堆栈 if code == gcode.CodeNil.Code() { - g.Log().Stdout(false).Printf(ctx, "exception:%v", err) + g.Log().Stdout(false).Infof(ctx, "exception:%v", err) } else { g.Log().Errorf(ctx, "exception:%v", err) } diff --git a/server/internal/logic/sys/cron.go b/server/internal/logic/sys/cron.go index e88657f..86b0738 100644 --- a/server/internal/logic/sys/cron.go +++ b/server/internal/logic/sys/cron.go @@ -20,7 +20,6 @@ import ( "hotgo/internal/service" "hotgo/utility/simple" "hotgo/utility/validate" - "strings" ) type sSysCron struct{} @@ -90,7 +89,16 @@ func (s *sSysCron) Edit(ctx context.Context, in *sysin.CronEditInp) (err error) } // 新增 - _, err = dao.SysCron.Ctx(ctx).Data(in).Insert() + in.SysCron.Id, err = dao.SysCron.Ctx(ctx).Data(in).InsertAndGetId() + if err != nil || in.SysCron.Id < 1 { + return + } + + if in.SysCron.Status == consts.StatusEnabled { + simple.SafeGo(ctx, func(ctx context.Context) { + _ = cron.Start(&in.SysCron) + }) + } return } @@ -163,6 +171,10 @@ func (s *sSysCron) List(ctx context.Context, in *sysin.CronListInp) (list []*sys mod = mod.WhereLike("name", "%"+in.Name+"%") } + if in.GroupId > 0 { + mod = mod.Where("group_id", in.GroupId) + } + if in.Status > 0 { mod = mod.Where("status", in.Status) } @@ -210,7 +222,22 @@ func (s *sSysCron) OnlineExec(ctx context.Context, in *sysin.OnlineExecInp) (err err = gerror.New("定时任务不存在") return } - - newCtx := context.WithValue(gctx.New(), consts.ContextKeyCronArgs, strings.Split(data.Params, consts.CronSplitStr)) - return cron.Once(newCtx, data) + return cron.Once(gctx.New(), data) +} + +// DispatchLog 查看指定任务的调度日志 +func (s *sSysCron) DispatchLog(ctx context.Context, in *sysin.DispatchLogInp) (res *sysin.DispatchLogModel, err error) { + var data *entity.SysCron + if err = dao.SysCron.Ctx(ctx).Where(dao.SysCron.Columns().Id, in.Id).Scan(&data); err != nil { + return + } + + if data == nil { + err = gerror.New("定时任务不存在") + return + } + + res = new(sysin.DispatchLogModel) + res.Log, err = cron.DispatchLog(data) + return } diff --git a/server/internal/logic/sys/cron_group.go b/server/internal/logic/sys/cron_group.go index 20dd41f..ebd97cc 100644 --- a/server/internal/logic/sys/cron_group.go +++ b/server/internal/logic/sys/cron_group.go @@ -107,6 +107,17 @@ func (s *sSysCronGroup) List(ctx context.Context, in *sysin.CronGroupListInp) (l if err = mod.Page(in.Page, in.PerPage).Order("id desc").Scan(&list); err != nil { err = gerror.Wrap(err, consts.ErrorORM) } + + for _, v := range list { + if v.Pid < 1 { + continue + } + name, err := dao.SysCronGroup.Ctx(ctx).Fields("name").WherePri(v.Pid).Value() + if err != nil { + return nil, 0, err + } + v.SupName = name.String() + } return } diff --git a/server/internal/logic/sys/curd_demo.go b/server/internal/logic/sys/curd_demo.go index 6daa844..8951c21 100644 --- a/server/internal/logic/sys/curd_demo.go +++ b/server/internal/logic/sys/curd_demo.go @@ -3,7 +3,7 @@ // @Copyright Copyright (c) 2023 HotGo CLI // @Author Ms <133814250@qq.com> // @License https://github.com/bufanyun/hotgo/blob/master/LICENSE -// @AutoGenerate Version 2.9.3 +// @AutoGenerate Version 2.11.5 package sys import ( diff --git a/server/internal/logic/tcpclient/cron.go b/server/internal/logic/tcpclient/cron.go index 4e53649..7acfcdb 100644 --- a/server/internal/logic/tcpclient/cron.go +++ b/server/internal/logic/tcpclient/cron.go @@ -66,10 +66,11 @@ func (s *sCronClient) Start(ctx context.Context) { // 注册RPC路由 s.client.RegisterRPCRouter( - s.OnCronDelete, // 删除任务 - s.OnCronEdit, // 编辑任务 - s.OnCronStatus, // 修改任务状态 - s.OnCronOnlineExec, // 执行一次任务 + s.OnCronDelete, // 删除任务 + s.OnCronEdit, // 编辑任务 + s.OnCronStatus, // 修改任务状态 + s.OnCronOnlineExec, // 执行一次任务 + s.OnCronDispatchLog, // 查看调度日志 ) // 注册拦截器 diff --git a/server/internal/logic/tcpclient/cron_handle.go b/server/internal/logic/tcpclient/cron_handle.go index c16cf61..ab62ce2 100644 --- a/server/internal/logic/tcpclient/cron_handle.go +++ b/server/internal/logic/tcpclient/cron_handle.go @@ -34,3 +34,10 @@ func (s *sCronClient) OnCronOnlineExec(ctx context.Context, req *servmsg.CronOnl err = service.SysCron().OnlineExec(ctx, req.OnlineExecInp) return } + +// OnCronDispatchLog 查看调度日志 +func (s *sCronClient) OnCronDispatchLog(ctx context.Context, req *servmsg.CronDispatchLogReq) (res *servmsg.CronDispatchLogRes, err error) { + res = new(servmsg.CronDispatchLogRes) + res.DispatchLogModel, err = service.SysCron().DispatchLog(ctx, req.DispatchLogInp) + return +} diff --git a/server/internal/logic/tcpserver/cron_handle.go b/server/internal/logic/tcpserver/cron_handle.go index d6a5a24..183f93f 100644 --- a/server/internal/logic/tcpserver/cron_handle.go +++ b/server/internal/logic/tcpserver/cron_handle.go @@ -10,6 +10,7 @@ import ( "github.com/gogf/gf/v2/errors/gerror" "hotgo/api/servmsg" "hotgo/internal/consts" + "hotgo/internal/library/cron" ) // CronDelete 删除任务 @@ -95,3 +96,22 @@ func (s *sTCPServer) CronOnlineExec(ctx context.Context, in *servmsg.CronOnlineE } return } + +// DispatchLog 查看调度日志 +func (s *sTCPServer) DispatchLog(ctx context.Context, in *servmsg.CronDispatchLogReq) (log *cron.Log, err error) { + clients := s.serv.GetGroupClients(consts.LicenseGroupCron) + if len(clients) == 0 { + err = gerror.New("没有在线的定时任务服务") + return + } + + var res servmsg.CronDispatchLogRes + if err = s.serv.RequestScan(ctx, clients[0], in, &res); err != nil { + return + } + + if err = res.GetError(); err != nil { + return + } + return res.Log, nil +} diff --git a/server/internal/model/config.go b/server/internal/model/config.go index c6e8cbc..2ada6cb 100644 --- a/server/internal/model/config.go +++ b/server/internal/model/config.go @@ -87,6 +87,14 @@ type UploadConfig struct { QiNiuDomain string `json:"uploadQiNiuDomain"` QiNiuPath string `json:"uploadQiNiuPath"` QiNiuBucket string `json:"uploadQiNiuBucket"` + // minio配置 + MinioAccessKey string `json:"uploadMinioAccessKey"` + MinioSecretKey string `json:"uploadMinioSecretKey"` + MinioEndpoint string `json:"uploadMinioEndpoint"` + MinioUseSSL int `json:"uploadMinioUseSSL"` + MinioPath string `json:"uploadMinioPath"` + MinioBucket string `json:"uploadMinioBucket"` + MinioDomain string `json:"uploadMinioDomain"` } // GeoConfig 地理配置 diff --git a/server/internal/model/do/admin_menu.go b/server/internal/model/do/admin_menu.go index fbbc02f..84fbda5 100644 --- a/server/internal/model/do/admin_menu.go +++ b/server/internal/model/do/admin_menu.go @@ -14,6 +14,8 @@ type AdminMenu struct { g.Meta `orm:"table:hg_admin_menu, do:true"` Id interface{} // 菜单ID Pid interface{} // 父菜单ID + Level interface{} // 关系树等级 + Tree interface{} // 关系树 Title interface{} // 菜单名称 Name interface{} // 名称编码 Path interface{} // 路由地址 @@ -31,11 +33,9 @@ type AdminMenu struct { KeepAlive interface{} // 缓存该路由 Hidden interface{} // 是否隐藏 Affix interface{} // 是否固定 - Level interface{} // 关系树等级 - Tree interface{} // 关系树 Sort interface{} // 排序 Remark interface{} // 备注 Status interface{} // 菜单状态 - CreatedAt *gtime.Time // 创建时间 UpdatedAt *gtime.Time // 更新时间 + CreatedAt *gtime.Time // 创建时间 } diff --git a/server/internal/model/do/sys_cron.go b/server/internal/model/do/sys_cron.go index 241711c..84645e8 100644 --- a/server/internal/model/do/sys_cron.go +++ b/server/internal/model/do/sys_cron.go @@ -14,9 +14,10 @@ type SysCron struct { g.Meta `orm:"table:hg_sys_cron, do:true"` Id interface{} // 任务ID GroupId interface{} // 分组ID - Name interface{} // 任务名称 + Title interface{} // 任务标题 + Name interface{} // 任务方法 Params interface{} // 函数参数 - Pattern interface{} // 定时表达式 + Pattern interface{} // 表达式 Policy interface{} // 策略 Count interface{} // 执行次数 Sort interface{} // 排序 diff --git a/server/internal/model/entity/admin_menu.go b/server/internal/model/entity/admin_menu.go index 83709eb..0e406ce 100644 --- a/server/internal/model/entity/admin_menu.go +++ b/server/internal/model/entity/admin_menu.go @@ -12,6 +12,8 @@ import ( type AdminMenu struct { Id int64 `json:"id" description:"菜单ID"` Pid int64 `json:"pid" description:"父菜单ID"` + Level int `json:"level" description:"关系树等级"` + Tree string `json:"tree" description:"关系树"` Title string `json:"title" description:"菜单名称"` Name string `json:"name" description:"名称编码"` Path string `json:"path" description:"路由地址"` @@ -29,11 +31,9 @@ type AdminMenu struct { KeepAlive int `json:"keepAlive" description:"缓存该路由"` Hidden int `json:"hidden" description:"是否隐藏"` Affix int `json:"affix" description:"是否固定"` - Level int `json:"level" description:"关系树等级"` - Tree string `json:"tree" description:"关系树"` Sort int `json:"sort" description:"排序"` Remark string `json:"remark" description:"备注"` Status int `json:"status" description:"菜单状态"` - CreatedAt *gtime.Time `json:"createdAt" description:"创建时间"` UpdatedAt *gtime.Time `json:"updatedAt" description:"更新时间"` + CreatedAt *gtime.Time `json:"createdAt" description:"创建时间"` } diff --git a/server/internal/model/entity/sys_cron.go b/server/internal/model/entity/sys_cron.go index 5db59d0..db1daa3 100644 --- a/server/internal/model/entity/sys_cron.go +++ b/server/internal/model/entity/sys_cron.go @@ -12,9 +12,10 @@ import ( type SysCron struct { Id int64 `json:"id" description:"任务ID"` GroupId int64 `json:"groupId" description:"分组ID"` - Name string `json:"name" description:"任务名称"` + Title string `json:"title" description:"任务标题"` + Name string `json:"name" description:"任务方法"` Params string `json:"params" description:"函数参数"` - Pattern string `json:"pattern" description:"定时表达式"` + Pattern string `json:"pattern" description:"表达式"` Policy int64 `json:"policy" description:"策略"` Count int64 `json:"count" description:"执行次数"` Sort int `json:"sort" description:"排序"` diff --git a/server/internal/model/input/adminin/member.go b/server/internal/model/input/adminin/member.go index 28162f5..f7e4261 100644 --- a/server/internal/model/input/adminin/member.go +++ b/server/internal/model/input/adminin/member.go @@ -187,6 +187,8 @@ type MemberViewModel struct { type MemberListInp struct { form.PageReq form.StatusReq + Id int64 `json:"id" dc:"用户ID"` + Pid int64 `json:"pid" dc:"上级ID"` RoleId int `json:"roleId" dc:"角色ID"` DeptId int `json:"deptId" dc:"部门ID"` Mobile int `json:"mobile" dc:"手机号"` diff --git a/server/internal/model/input/sysin/cron.go b/server/internal/model/input/sysin/cron.go index 91f21bb..754895f 100644 --- a/server/internal/model/input/sysin/cron.go +++ b/server/internal/model/input/sysin/cron.go @@ -6,6 +6,7 @@ package sysin import ( + "hotgo/internal/library/cron" "hotgo/internal/model/entity" "hotgo/internal/model/input/form" ) @@ -43,9 +44,9 @@ type CronViewModel struct { // CronListInp 获取列表 type CronListInp struct { form.PageReq - form.StatusReq - Name string + GroupId int64 `json:"groupId" description:"分组ID"` + Name string `json:"name" description:"任务名称"` } type CronListModel struct { @@ -64,3 +65,11 @@ type OnlineExecInp struct { entity.SysCron } type OnlineExecModel struct{} + +// DispatchLogInp 查看指定任务的调度日志 +type DispatchLogInp struct { + entity.SysCron +} +type DispatchLogModel struct { + *cron.Log +} diff --git a/server/internal/model/input/sysin/cron_group.go b/server/internal/model/input/sysin/cron_group.go index 3eedb3e..e5e61d3 100644 --- a/server/internal/model/input/sysin/cron_group.go +++ b/server/internal/model/input/sysin/cron_group.go @@ -82,13 +82,13 @@ type CronGroupViewModel struct { // CronGroupListInp 获取列表 type CronGroupListInp struct { form.PageReq - form.StatusReq Name string } type CronGroupListModel struct { entity.SysCronGroup + SupName string `json:"supName" description:"上级分组名称"` } // CronGroupStatusInp 更新状态 diff --git a/server/internal/model/input/sysin/curd_demo.go b/server/internal/model/input/sysin/curd_demo.go index 5b02257..3166dd9 100644 --- a/server/internal/model/input/sysin/curd_demo.go +++ b/server/internal/model/input/sysin/curd_demo.go @@ -3,7 +3,7 @@ // @Copyright Copyright (c) 2023 HotGo CLI // @Author Ms <133814250@qq.com> // @License https://github.com/bufanyun/hotgo/blob/master/LICENSE -// @AutoGenerate Version 2.9.3 +// @AutoGenerate Version 2.11.5 package sysin import ( diff --git a/server/internal/model/tree.go b/server/internal/model/tree.go index 6b34cbd..32128f6 100644 --- a/server/internal/model/tree.go +++ b/server/internal/model/tree.go @@ -3,11 +3,18 @@ // @Copyright Copyright (c) 2023 HotGo CLI // @Author Ms <133814250@qq.com> // @License https://github.com/bufanyun/hotgo/blob/master/LICENSE -// package model import "hotgo/internal/model/entity" +// DefaultTree 默认树表字段 +type DefaultTree struct { + Id int64 `json:"id" description:"ID"` + Pid int64 `json:"pid" description:"父ID"` + Level int `json:"level" description:"关系树等级"` + Tree string `json:"tree" description:"关系树"` +} + // TreeMenu 菜单树 type TreeMenu struct { entity.AdminMenu diff --git a/server/internal/router/genrouter/curd_demo.go b/server/internal/router/genrouter/curd_demo.go index 75f15bb..ab78c2a 100644 --- a/server/internal/router/genrouter/curd_demo.go +++ b/server/internal/router/genrouter/curd_demo.go @@ -3,7 +3,7 @@ // @Copyright Copyright (c) 2023 HotGo CLI // @Author Ms <133814250@qq.com> // @License https://github.com/bufanyun/hotgo/blob/master/LICENSE -// @AutoGenerate Version 2.9.3 +// @AutoGenerate Version 2.11.5 package genrouter import "hotgo/internal/controller/admin/sys" diff --git a/server/internal/service/sys.go b/server/internal/service/sys.go index 60943ac..3a7f081 100644 --- a/server/internal/service/sys.go +++ b/server/internal/service/sys.go @@ -18,107 +18,13 @@ import ( ) type ( - ISysDictType interface { - // Tree 树 - Tree(ctx context.Context) (list []*sysin.DictTypeTree, err error) - // Delete 删除 - Delete(ctx context.Context, in *sysin.DictTypeDeleteInp) (err error) - // Edit 修改/新增 - Edit(ctx context.Context, in *sysin.DictTypeEditInp) (err error) - // TreeSelect 获取类型关系树选项 - TreeSelect(ctx context.Context, in *sysin.DictTreeSelectInp) (list []*sysin.DictTypeTree, err error) - } - ISysProvinces interface { - // Tree 关系树选项列表 - Tree(ctx context.Context) (list []*sysin.ProvincesTree, err error) - // Delete 删除省市区数据 - Delete(ctx context.Context, in *sysin.ProvincesDeleteInp) (err error) - // Edit 修改/新增省市区数据 - Edit(ctx context.Context, in *sysin.ProvincesEditInp) (err error) - // Status 更新省市区状态 - Status(ctx context.Context, in *sysin.ProvincesStatusInp) (err error) - // MaxSort 最大排序 - MaxSort(ctx context.Context, in *sysin.ProvincesMaxSortInp) (res *sysin.ProvincesMaxSortModel, err error) - // View 获取省市区信息 - View(ctx context.Context, in *sysin.ProvincesViewInp) (res *sysin.ProvincesViewModel, err error) - // List 获取列表 - List(ctx context.Context, in *sysin.ProvincesListInp) (list []*sysin.ProvincesListModel, totalCount int, err error) - // ChildrenList 获取省市区下级列表 - ChildrenList(ctx context.Context, in *sysin.ProvincesChildrenListInp) (list []*sysin.ProvincesChildrenListModel, totalCount int, err error) - // UniqueId 获取省市区下级列表 - UniqueId(ctx context.Context, in *sysin.ProvincesUniqueIdInp) (res *sysin.ProvincesUniqueIdModel, err error) - // Select 省市区选项 - Select(ctx context.Context, in *sysin.ProvincesSelectInp) (res *sysin.ProvincesSelectModel, err error) - } - ISysDictData interface { - // Delete 删除 - Delete(ctx context.Context, in *sysin.DictDataDeleteInp) error - // Edit 修改/新增 - Edit(ctx context.Context, in *sysin.DictDataEditInp) (err error) - // List 获取列表 - List(ctx context.Context, in *sysin.DictDataListInp) (list []*sysin.DictDataListModel, totalCount int, err error) - // GetId 获取指定类型的ID - GetId(ctx context.Context, t string) (id int64, err error) - // GetType 获取指定ID的类型标识 - GetType(ctx context.Context, id int64) (types string, err error) - // GetTypes 获取指定ID的所有类型标识,包含下级 - GetTypes(ctx context.Context, id int64) (types []string, err error) - // Select 获取列表 - Select(ctx context.Context, in *sysin.DataSelectInp) (list sysin.DataSelectModel, err error) - } - ISysEmsLog interface { - // Delete 删除 - Delete(ctx context.Context, in *sysin.EmsLogDeleteInp) (err error) - // Edit 修改/新增 - Edit(ctx context.Context, in *sysin.EmsLogEditInp) (err error) - // Status 更新部门状态 - Status(ctx context.Context, in *sysin.EmsLogStatusInp) (err error) - // View 获取指定字典类型信息 - View(ctx context.Context, in *sysin.EmsLogViewInp) (res *sysin.EmsLogViewModel, err error) - // List 获取列表 - List(ctx context.Context, in *sysin.EmsLogListInp) (list []*sysin.EmsLogListModel, totalCount int, err error) - // Send 发送邮件 - Send(ctx context.Context, in *sysin.SendEmsInp) (err error) - // GetTemplate 获取指定邮件模板 - GetTemplate(ctx context.Context, template string, config *model.EmailConfig) (val string, err error) - // AllowSend 是否允许发送 - AllowSend(ctx context.Context, models *entity.SysEmsLog, config *model.EmailConfig) (err error) - // NowDayCount 当天发送次数 - NowDayCount(ctx context.Context, event, email string) (count int, err error) - // VerifyCode 效验验证码 - VerifyCode(ctx context.Context, in *sysin.VerifyEmsCodeInp) (err error) - } - ISysServeLicense interface { - // Model 服务许可证ORM模型 - Model(ctx context.Context, option ...*handler.Option) *gdb.Model - // List 获取服务许可证列表 - List(ctx context.Context, in *sysin.ServeLicenseListInp) (list []*sysin.ServeLicenseListModel, totalCount int, err error) - // Export 导出服务许可证 - Export(ctx context.Context, in *sysin.ServeLicenseListInp) (err error) - // Edit 修改/新增服务许可证 - Edit(ctx context.Context, in *sysin.ServeLicenseEditInp) (err error) - // Delete 删除服务许可证 - Delete(ctx context.Context, in *sysin.ServeLicenseDeleteInp) (err error) - // View 获取服务许可证指定信息 - View(ctx context.Context, in *sysin.ServeLicenseViewInp) (res *sysin.ServeLicenseViewModel, err error) - // Status 更新服务许可证状态 - Status(ctx context.Context, in *sysin.ServeLicenseStatusInp) (err error) - // AssignRouter 分配服务许可证路由 - AssignRouter(ctx context.Context, in *sysin.ServeLicenseAssignRouterInp) (err error) - } - ISysAddons interface { - // List 获取列表 - List(ctx context.Context, in *sysin.AddonsListInp) (list []*sysin.AddonsListModel, totalCount int, err error) - // Selects 选项 - Selects(ctx context.Context, in *sysin.AddonsSelectsInp) (res *sysin.AddonsSelectsModel, err error) - // Build 提交生成 - Build(ctx context.Context, in *sysin.AddonsBuildInp) (err error) - // Install 安装模块 - Install(ctx context.Context, in *sysin.AddonsInstallInp) (err error) - // Upgrade 更新模块 - Upgrade(ctx context.Context, in *sysin.AddonsUpgradeInp) (err error) - // UnInstall 卸载模块 - UnInstall(ctx context.Context, in *sysin.AddonsUnInstallInp) (err error) + ISysAddonsConfig interface { + // GetConfigByGroup 获取指定分组的配置 + GetConfigByGroup(ctx context.Context, in *sysin.GetAddonsConfigInp) (res *sysin.GetAddonsConfigModel, err error) + // ConversionType 转换类型 + ConversionType(ctx context.Context, models *entity.SysAddonsConfig) (value interface{}, err error) + // UpdateConfigByGroup 更新指定分组的配置 + UpdateConfigByGroup(ctx context.Context, in *sysin.UpdateAddonsConfigInp) (err error) } ISysBlacklist interface { // Delete 删除 @@ -140,120 +46,6 @@ type ( // ClusterSync 集群同步 ClusterSync(ctx context.Context, message *gredis.Message) } - ISysCronGroup interface { - // Delete 删除 - Delete(ctx context.Context, in *sysin.CronGroupDeleteInp) (err error) - // Edit 修改/新增 - Edit(ctx context.Context, in *sysin.CronGroupEditInp) (err error) - // Status 更新状态 - Status(ctx context.Context, in *sysin.CronGroupStatusInp) (err error) - // MaxSort 最大排序 - MaxSort(ctx context.Context, in *sysin.CronGroupMaxSortInp) (res *sysin.CronGroupMaxSortModel, err error) - // View 获取指定信息 - View(ctx context.Context, in *sysin.CronGroupViewInp) (res *sysin.CronGroupViewModel, err error) - // List 获取列表 - List(ctx context.Context, in *sysin.CronGroupListInp) (list []*sysin.CronGroupListModel, totalCount int, err error) - // Select 选项 - Select(ctx context.Context, in *sysin.CronGroupSelectInp) (res *sysin.CronGroupSelectModel, err error) - } - ISysCurdDemo interface { - // Model 生成演示ORM模型 - Model(ctx context.Context, option ...*handler.Option) *gdb.Model - // List 获取生成演示列表 - List(ctx context.Context, in *sysin.CurdDemoListInp) (list []*sysin.CurdDemoListModel, totalCount int, err error) - // Export 导出生成演示 - Export(ctx context.Context, in *sysin.CurdDemoListInp) (err error) - // Edit 修改/新增生成演示 - Edit(ctx context.Context, in *sysin.CurdDemoEditInp) (err error) - // Delete 删除生成演示 - Delete(ctx context.Context, in *sysin.CurdDemoDeleteInp) (err error) - // MaxSort 获取生成演示最大排序 - MaxSort(ctx context.Context, in *sysin.CurdDemoMaxSortInp) (res *sysin.CurdDemoMaxSortModel, err error) - // View 获取生成演示指定信息 - View(ctx context.Context, in *sysin.CurdDemoViewInp) (res *sysin.CurdDemoViewModel, err error) - // Status 更新生成演示状态 - Status(ctx context.Context, in *sysin.CurdDemoStatusInp) (err error) - // Switch 更新生成演示开关 - Switch(ctx context.Context, in *sysin.CurdDemoSwitchInp) (err error) - } - ISysGenCodes interface { - // Delete 删除 - Delete(ctx context.Context, in *sysin.GenCodesDeleteInp) (err error) - // Edit 修改/新增 - Edit(ctx context.Context, in *sysin.GenCodesEditInp) (res *sysin.GenCodesEditModel, err error) - // Status 更新部门状态 - Status(ctx context.Context, in *sysin.GenCodesStatusInp) (err error) - // MaxSort 最大排序 - MaxSort(ctx context.Context, in *sysin.GenCodesMaxSortInp) (res *sysin.GenCodesMaxSortModel, err error) - // View 获取指定字典类型信息 - View(ctx context.Context, in *sysin.GenCodesViewInp) (res *sysin.GenCodesViewModel, err error) - // List 获取列表 - List(ctx context.Context, in *sysin.GenCodesListInp) (list []*sysin.GenCodesListModel, totalCount int, err error) - // Selects 选项 - Selects(ctx context.Context, in *sysin.GenCodesSelectsInp) (res *sysin.GenCodesSelectsModel, err error) - // TableSelect 表选项 - TableSelect(ctx context.Context, in *sysin.GenCodesTableSelectInp) (res []*sysin.GenCodesTableSelectModel, err error) - // ColumnSelect 表字段选项 - ColumnSelect(ctx context.Context, in *sysin.GenCodesColumnSelectInp) (res []*sysin.GenCodesColumnSelectModel, err error) - // ColumnList 表字段列表 - ColumnList(ctx context.Context, in *sysin.GenCodesColumnListInp) (res []*sysin.GenCodesColumnListModel, err error) - // Preview 生成预览 - Preview(ctx context.Context, in *sysin.GenCodesPreviewInp) (res *sysin.GenCodesPreviewModel, err error) - // Build 提交生成 - Build(ctx context.Context, in *sysin.GenCodesBuildInp) (err error) - } - ISysLog interface { - // Export 导出 - Export(ctx context.Context, in *sysin.LogListInp) (err error) - // RealWrite 真实写入 - RealWrite(ctx context.Context, log entity.SysLog) (err error) - // AutoLog 根据配置自动记录请求日志 - AutoLog(ctx context.Context) error - // AnalysisLog 解析日志数据 - AnalysisLog(ctx context.Context) entity.SysLog - // View 获取指定字典类型信息 - View(ctx context.Context, in *sysin.LogViewInp) (res *sysin.LogViewModel, err error) - // Delete 删除 - Delete(ctx context.Context, in *sysin.LogDeleteInp) (err error) - // List 列表 - List(ctx context.Context, in *sysin.LogListInp) (list []*sysin.LogListModel, totalCount int, err error) - } - ISysLoginLog interface { - // Model 登录日志Orm模型 - Model(ctx context.Context) *gdb.Model - // List 获取登录日志列表 - List(ctx context.Context, in *sysin.LoginLogListInp) (list []*sysin.LoginLogListModel, totalCount int, err error) - // Export 导出登录日志 - Export(ctx context.Context, in *sysin.LoginLogListInp) (err error) - // Delete 删除登录日志 - Delete(ctx context.Context, in *sysin.LoginLogDeleteInp) (err error) - // View 获取登录日志指定信息 - View(ctx context.Context, in *sysin.LoginLogViewInp) (res *sysin.LoginLogViewModel, err error) - // Push 推送登录日志 - Push(ctx context.Context, in *sysin.LoginLogPushInp) - // RealWrite 真实写入 - RealWrite(ctx context.Context, models entity.SysLoginLog) (err error) - } - ISysAddonsConfig interface { - // GetConfigByGroup 获取指定分组的配置 - GetConfigByGroup(ctx context.Context, in *sysin.GetAddonsConfigInp) (res *sysin.GetAddonsConfigModel, err error) - // ConversionType 转换类型 - ConversionType(ctx context.Context, models *entity.SysAddonsConfig) (value interface{}, err error) - // UpdateConfigByGroup 更新指定分组的配置 - UpdateConfigByGroup(ctx context.Context, in *sysin.UpdateAddonsConfigInp) (err error) - } - ISysAttachment interface { - // Model ORM模型 - Model(ctx context.Context, option ...*handler.Option) *gdb.Model - // Delete 删除附件 - Delete(ctx context.Context, in *sysin.AttachmentDeleteInp) (err error) - // View 获取附件信息 - View(ctx context.Context, in *sysin.AttachmentViewInp) (res *sysin.AttachmentViewModel, err error) - // List 获取附件列表 - List(ctx context.Context, in *sysin.AttachmentListInp) (list []*sysin.AttachmentListModel, totalCount int, err error) - // ClearKind 清空上传类型 - ClearKind(ctx context.Context, in *sysin.AttachmentClearKindInp) (err error) - } ISysConfig interface { // InitConfig 初始化系统配置 InitConfig(ctx context.Context) @@ -296,38 +88,57 @@ type ( // ClusterSync 集群同步 ClusterSync(ctx context.Context, message *gredis.Message) } - ISysCron interface { - StartCron(ctx context.Context) + ISysCronGroup interface { // Delete 删除 - Delete(ctx context.Context, in *sysin.CronDeleteInp) (err error) + Delete(ctx context.Context, in *sysin.CronGroupDeleteInp) (err error) // Edit 修改/新增 - Edit(ctx context.Context, in *sysin.CronEditInp) (err error) + Edit(ctx context.Context, in *sysin.CronGroupEditInp) (err error) // Status 更新状态 - Status(ctx context.Context, in *sysin.CronStatusInp) (err error) + Status(ctx context.Context, in *sysin.CronGroupStatusInp) (err error) // MaxSort 最大排序 - MaxSort(ctx context.Context, in *sysin.CronMaxSortInp) (res *sysin.CronMaxSortModel, err error) + MaxSort(ctx context.Context, in *sysin.CronGroupMaxSortInp) (res *sysin.CronGroupMaxSortModel, err error) // View 获取指定信息 - View(ctx context.Context, in *sysin.CronViewInp) (res *sysin.CronViewModel, err error) + View(ctx context.Context, in *sysin.CronGroupViewInp) (res *sysin.CronGroupViewModel, err error) // List 获取列表 - List(ctx context.Context, in *sysin.CronListInp) (list []*sysin.CronListModel, totalCount int, err error) - // GetName 获取分组名称 - GetName(ctx context.Context, id int64) (name string, err error) - // OnlineExec 在线执行 - OnlineExec(ctx context.Context, in *sysin.OnlineExecInp) (err error) + List(ctx context.Context, in *sysin.CronGroupListInp) (list []*sysin.CronGroupListModel, totalCount int, err error) + // Select 选项 + Select(ctx context.Context, in *sysin.CronGroupSelectInp) (res *sysin.CronGroupSelectModel, err error) } - ISysServeLog interface { - // Model 服务日志Orm模型 - Model(ctx context.Context) *gdb.Model - // List 获取服务日志列表 - List(ctx context.Context, in *sysin.ServeLogListInp) (list []*sysin.ServeLogListModel, totalCount int, err error) - // Export 导出服务日志 - Export(ctx context.Context, in *sysin.ServeLogListInp) (err error) - // Delete 删除服务日志 - Delete(ctx context.Context, in *sysin.ServeLogDeleteInp) (err error) - // View 获取服务日志指定信息 - View(ctx context.Context, in *sysin.ServeLogViewInp) (res *sysin.ServeLogViewModel, err error) + ISysCurdDemo interface { + // Model 生成演示ORM模型 + Model(ctx context.Context, option ...*handler.Option) *gdb.Model + // List 获取生成演示列表 + List(ctx context.Context, in *sysin.CurdDemoListInp) (list []*sysin.CurdDemoListModel, totalCount int, err error) + // Export 导出生成演示 + Export(ctx context.Context, in *sysin.CurdDemoListInp) (err error) + // Edit 修改/新增生成演示 + Edit(ctx context.Context, in *sysin.CurdDemoEditInp) (err error) + // Delete 删除生成演示 + Delete(ctx context.Context, in *sysin.CurdDemoDeleteInp) (err error) + // MaxSort 获取生成演示最大排序 + MaxSort(ctx context.Context, in *sysin.CurdDemoMaxSortInp) (res *sysin.CurdDemoMaxSortModel, err error) + // View 获取生成演示指定信息 + View(ctx context.Context, in *sysin.CurdDemoViewInp) (res *sysin.CurdDemoViewModel, err error) + // Status 更新生成演示状态 + Status(ctx context.Context, in *sysin.CurdDemoStatusInp) (err error) + // Switch 更新生成演示开关 + Switch(ctx context.Context, in *sysin.CurdDemoSwitchInp) (err error) + } + ISysLog interface { + // Export 导出 + Export(ctx context.Context, in *sysin.LogListInp) (err error) // RealWrite 真实写入 - RealWrite(ctx context.Context, models entity.SysServeLog) (err error) + RealWrite(ctx context.Context, log entity.SysLog) (err error) + // AutoLog 根据配置自动记录请求日志 + AutoLog(ctx context.Context) error + // AnalysisLog 解析日志数据 + AnalysisLog(ctx context.Context) entity.SysLog + // View 获取指定字典类型信息 + View(ctx context.Context, in *sysin.LogViewInp) (res *sysin.LogViewModel, err error) + // Delete 删除 + Delete(ctx context.Context, in *sysin.LogDeleteInp) (err error) + // List 列表 + List(ctx context.Context, in *sysin.LogListInp) (list []*sysin.LogListModel, totalCount int, err error) } ISysSmsLog interface { // Delete 删除 @@ -351,128 +162,220 @@ type ( // VerifyCode 效验验证码 VerifyCode(ctx context.Context, in *sysin.VerifyCodeInp) (err error) } + ISysDictType interface { + // Tree 树 + Tree(ctx context.Context) (list []*sysin.DictTypeTree, err error) + // Delete 删除 + Delete(ctx context.Context, in *sysin.DictTypeDeleteInp) (err error) + // Edit 修改/新增 + Edit(ctx context.Context, in *sysin.DictTypeEditInp) (err error) + // TreeSelect 获取类型关系树选项 + TreeSelect(ctx context.Context, in *sysin.DictTreeSelectInp) (list []*sysin.DictTypeTree, err error) + } + ISysEmsLog interface { + // Delete 删除 + Delete(ctx context.Context, in *sysin.EmsLogDeleteInp) (err error) + // Edit 修改/新增 + Edit(ctx context.Context, in *sysin.EmsLogEditInp) (err error) + // Status 更新部门状态 + Status(ctx context.Context, in *sysin.EmsLogStatusInp) (err error) + // View 获取指定字典类型信息 + View(ctx context.Context, in *sysin.EmsLogViewInp) (res *sysin.EmsLogViewModel, err error) + // List 获取列表 + List(ctx context.Context, in *sysin.EmsLogListInp) (list []*sysin.EmsLogListModel, totalCount int, err error) + // Send 发送邮件 + Send(ctx context.Context, in *sysin.SendEmsInp) (err error) + // GetTemplate 获取指定邮件模板 + GetTemplate(ctx context.Context, template string, config *model.EmailConfig) (val string, err error) + // AllowSend 是否允许发送 + AllowSend(ctx context.Context, models *entity.SysEmsLog, config *model.EmailConfig) (err error) + // NowDayCount 当天发送次数 + NowDayCount(ctx context.Context, event, email string) (count int, err error) + // VerifyCode 效验验证码 + VerifyCode(ctx context.Context, in *sysin.VerifyEmsCodeInp) (err error) + } + ISysGenCodes interface { + // Delete 删除 + Delete(ctx context.Context, in *sysin.GenCodesDeleteInp) (err error) + // Edit 修改/新增 + Edit(ctx context.Context, in *sysin.GenCodesEditInp) (res *sysin.GenCodesEditModel, err error) + // Status 更新部门状态 + Status(ctx context.Context, in *sysin.GenCodesStatusInp) (err error) + // MaxSort 最大排序 + MaxSort(ctx context.Context, in *sysin.GenCodesMaxSortInp) (res *sysin.GenCodesMaxSortModel, err error) + // View 获取指定字典类型信息 + View(ctx context.Context, in *sysin.GenCodesViewInp) (res *sysin.GenCodesViewModel, err error) + // List 获取列表 + List(ctx context.Context, in *sysin.GenCodesListInp) (list []*sysin.GenCodesListModel, totalCount int, err error) + // Selects 选项 + Selects(ctx context.Context, in *sysin.GenCodesSelectsInp) (res *sysin.GenCodesSelectsModel, err error) + // TableSelect 表选项 + TableSelect(ctx context.Context, in *sysin.GenCodesTableSelectInp) (res []*sysin.GenCodesTableSelectModel, err error) + // ColumnSelect 表字段选项 + ColumnSelect(ctx context.Context, in *sysin.GenCodesColumnSelectInp) (res []*sysin.GenCodesColumnSelectModel, err error) + // ColumnList 表字段列表 + ColumnList(ctx context.Context, in *sysin.GenCodesColumnListInp) (res []*sysin.GenCodesColumnListModel, err error) + // Preview 生成预览 + Preview(ctx context.Context, in *sysin.GenCodesPreviewInp) (res *sysin.GenCodesPreviewModel, err error) + // Build 提交生成 + Build(ctx context.Context, in *sysin.GenCodesBuildInp) (err error) + } + ISysProvinces interface { + // Tree 关系树选项列表 + Tree(ctx context.Context) (list []*sysin.ProvincesTree, err error) + // Delete 删除省市区数据 + Delete(ctx context.Context, in *sysin.ProvincesDeleteInp) (err error) + // Edit 修改/新增省市区数据 + Edit(ctx context.Context, in *sysin.ProvincesEditInp) (err error) + // Status 更新省市区状态 + Status(ctx context.Context, in *sysin.ProvincesStatusInp) (err error) + // MaxSort 最大排序 + MaxSort(ctx context.Context, in *sysin.ProvincesMaxSortInp) (res *sysin.ProvincesMaxSortModel, err error) + // View 获取省市区信息 + View(ctx context.Context, in *sysin.ProvincesViewInp) (res *sysin.ProvincesViewModel, err error) + // List 获取列表 + List(ctx context.Context, in *sysin.ProvincesListInp) (list []*sysin.ProvincesListModel, totalCount int, err error) + // ChildrenList 获取省市区下级列表 + ChildrenList(ctx context.Context, in *sysin.ProvincesChildrenListInp) (list []*sysin.ProvincesChildrenListModel, totalCount int, err error) + // UniqueId 获取省市区下级列表 + UniqueId(ctx context.Context, in *sysin.ProvincesUniqueIdInp) (res *sysin.ProvincesUniqueIdModel, err error) + // Select 省市区选项 + Select(ctx context.Context, in *sysin.ProvincesSelectInp) (res *sysin.ProvincesSelectModel, err error) + } + ISysServeLog interface { + // Model 服务日志Orm模型 + Model(ctx context.Context) *gdb.Model + // List 获取服务日志列表 + List(ctx context.Context, in *sysin.ServeLogListInp) (list []*sysin.ServeLogListModel, totalCount int, err error) + // Export 导出服务日志 + Export(ctx context.Context, in *sysin.ServeLogListInp) (err error) + // Delete 删除服务日志 + Delete(ctx context.Context, in *sysin.ServeLogDeleteInp) (err error) + // View 获取服务日志指定信息 + View(ctx context.Context, in *sysin.ServeLogViewInp) (res *sysin.ServeLogViewModel, err error) + // RealWrite 真实写入 + RealWrite(ctx context.Context, models entity.SysServeLog) (err error) + } + ISysAddons interface { + // List 获取列表 + List(ctx context.Context, in *sysin.AddonsListInp) (list []*sysin.AddonsListModel, totalCount int, err error) + // Selects 选项 + Selects(ctx context.Context, in *sysin.AddonsSelectsInp) (res *sysin.AddonsSelectsModel, err error) + // Build 提交生成 + Build(ctx context.Context, in *sysin.AddonsBuildInp) (err error) + // Install 安装模块 + Install(ctx context.Context, in *sysin.AddonsInstallInp) (err error) + // Upgrade 更新模块 + Upgrade(ctx context.Context, in *sysin.AddonsUpgradeInp) (err error) + // UnInstall 卸载模块 + UnInstall(ctx context.Context, in *sysin.AddonsUnInstallInp) (err error) + } + ISysAttachment interface { + // Model ORM模型 + Model(ctx context.Context, option ...*handler.Option) *gdb.Model + // Delete 删除附件 + Delete(ctx context.Context, in *sysin.AttachmentDeleteInp) (err error) + // View 获取附件信息 + View(ctx context.Context, in *sysin.AttachmentViewInp) (res *sysin.AttachmentViewModel, err error) + // List 获取附件列表 + List(ctx context.Context, in *sysin.AttachmentListInp) (list []*sysin.AttachmentListModel, totalCount int, err error) + // ClearKind 清空上传类型 + ClearKind(ctx context.Context, in *sysin.AttachmentClearKindInp) (err error) + } + ISysCron interface { + StartCron(ctx context.Context) + // Delete 删除 + Delete(ctx context.Context, in *sysin.CronDeleteInp) (err error) + // Edit 修改/新增 + Edit(ctx context.Context, in *sysin.CronEditInp) (err error) + // Status 更新状态 + Status(ctx context.Context, in *sysin.CronStatusInp) (err error) + // MaxSort 最大排序 + MaxSort(ctx context.Context, in *sysin.CronMaxSortInp) (res *sysin.CronMaxSortModel, err error) + // View 获取指定信息 + View(ctx context.Context, in *sysin.CronViewInp) (res *sysin.CronViewModel, err error) + // List 获取列表 + List(ctx context.Context, in *sysin.CronListInp) (list []*sysin.CronListModel, totalCount int, err error) + // GetName 获取分组名称 + GetName(ctx context.Context, id int64) (name string, err error) + // OnlineExec 在线执行 + OnlineExec(ctx context.Context, in *sysin.OnlineExecInp) (err error) + // DispatchLog 查看指定任务的调度日志 + DispatchLog(ctx context.Context, in *sysin.DispatchLogInp) (res *sysin.DispatchLogModel, err error) + } + ISysDictData interface { + // Delete 删除 + Delete(ctx context.Context, in *sysin.DictDataDeleteInp) error + // Edit 修改/新增 + Edit(ctx context.Context, in *sysin.DictDataEditInp) (err error) + // List 获取列表 + List(ctx context.Context, in *sysin.DictDataListInp) (list []*sysin.DictDataListModel, totalCount int, err error) + // GetId 获取指定类型的ID + GetId(ctx context.Context, t string) (id int64, err error) + // GetType 获取指定ID的类型标识 + GetType(ctx context.Context, id int64) (types string, err error) + // GetTypes 获取指定ID的所有类型标识,包含下级 + GetTypes(ctx context.Context, id int64) (types []string, err error) + // Select 获取列表 + Select(ctx context.Context, in *sysin.DataSelectInp) (list sysin.DataSelectModel, err error) + } + ISysLoginLog interface { + // Model 登录日志Orm模型 + Model(ctx context.Context) *gdb.Model + // List 获取登录日志列表 + List(ctx context.Context, in *sysin.LoginLogListInp) (list []*sysin.LoginLogListModel, totalCount int, err error) + // Export 导出登录日志 + Export(ctx context.Context, in *sysin.LoginLogListInp) (err error) + // Delete 删除登录日志 + Delete(ctx context.Context, in *sysin.LoginLogDeleteInp) (err error) + // View 获取登录日志指定信息 + View(ctx context.Context, in *sysin.LoginLogViewInp) (res *sysin.LoginLogViewModel, err error) + // Push 推送登录日志 + Push(ctx context.Context, in *sysin.LoginLogPushInp) + // RealWrite 真实写入 + RealWrite(ctx context.Context, models entity.SysLoginLog) (err error) + } + ISysServeLicense interface { + // Model 服务许可证ORM模型 + Model(ctx context.Context, option ...*handler.Option) *gdb.Model + // List 获取服务许可证列表 + List(ctx context.Context, in *sysin.ServeLicenseListInp) (list []*sysin.ServeLicenseListModel, totalCount int, err error) + // Export 导出服务许可证 + Export(ctx context.Context, in *sysin.ServeLicenseListInp) (err error) + // Edit 修改/新增服务许可证 + Edit(ctx context.Context, in *sysin.ServeLicenseEditInp) (err error) + // Delete 删除服务许可证 + Delete(ctx context.Context, in *sysin.ServeLicenseDeleteInp) (err error) + // View 获取服务许可证指定信息 + View(ctx context.Context, in *sysin.ServeLicenseViewInp) (res *sysin.ServeLicenseViewModel, err error) + // Status 更新服务许可证状态 + Status(ctx context.Context, in *sysin.ServeLicenseStatusInp) (err error) + // AssignRouter 分配服务许可证路由 + AssignRouter(ctx context.Context, in *sysin.ServeLicenseAssignRouterInp) (err error) + } ) var ( - localSysServeLog ISysServeLog + localSysCurdDemo ISysCurdDemo + localSysLog ISysLog localSysSmsLog ISysSmsLog - localSysAddonsConfig ISysAddonsConfig - localSysAttachment ISysAttachment - localSysConfig ISysConfig - localSysCron ISysCron - localSysDictType ISysDictType localSysProvinces ISysProvinces - localSysDictData ISysDictData + localSysServeLog ISysServeLog + localSysDictType ISysDictType localSysEmsLog ISysEmsLog localSysGenCodes ISysGenCodes - localSysLog ISysLog + localSysDictData ISysDictData localSysLoginLog ISysLoginLog localSysServeLicense ISysServeLicense localSysAddons ISysAddons - localSysBlacklist ISysBlacklist + localSysAttachment ISysAttachment + localSysCron ISysCron localSysCronGroup ISysCronGroup - localSysCurdDemo ISysCurdDemo + localSysAddonsConfig ISysAddonsConfig + localSysBlacklist ISysBlacklist + localSysConfig ISysConfig ) -func SysAttachment() ISysAttachment { - if localSysAttachment == nil { - panic("implement not found for interface ISysAttachment, forgot register?") - } - return localSysAttachment -} - -func RegisterSysAttachment(i ISysAttachment) { - localSysAttachment = i -} - -func SysConfig() ISysConfig { - if localSysConfig == nil { - panic("implement not found for interface ISysConfig, forgot register?") - } - return localSysConfig -} - -func RegisterSysConfig(i ISysConfig) { - localSysConfig = i -} - -func SysCron() ISysCron { - if localSysCron == nil { - panic("implement not found for interface ISysCron, forgot register?") - } - return localSysCron -} - -func RegisterSysCron(i ISysCron) { - localSysCron = i -} - -func SysServeLog() ISysServeLog { - if localSysServeLog == nil { - panic("implement not found for interface ISysServeLog, forgot register?") - } - return localSysServeLog -} - -func RegisterSysServeLog(i ISysServeLog) { - localSysServeLog = i -} - -func SysSmsLog() ISysSmsLog { - if localSysSmsLog == nil { - panic("implement not found for interface ISysSmsLog, forgot register?") - } - return localSysSmsLog -} - -func RegisterSysSmsLog(i ISysSmsLog) { - localSysSmsLog = i -} - -func SysAddonsConfig() ISysAddonsConfig { - if localSysAddonsConfig == nil { - panic("implement not found for interface ISysAddonsConfig, forgot register?") - } - return localSysAddonsConfig -} - -func RegisterSysAddonsConfig(i ISysAddonsConfig) { - localSysAddonsConfig = i -} - -func SysProvinces() ISysProvinces { - if localSysProvinces == nil { - panic("implement not found for interface ISysProvinces, forgot register?") - } - return localSysProvinces -} - -func RegisterSysProvinces(i ISysProvinces) { - localSysProvinces = i -} - -func SysDictType() ISysDictType { - if localSysDictType == nil { - panic("implement not found for interface ISysDictType, forgot register?") - } - return localSysDictType -} - -func RegisterSysDictType(i ISysDictType) { - localSysDictType = i -} - -func SysEmsLog() ISysEmsLog { - if localSysEmsLog == nil { - panic("implement not found for interface ISysEmsLog, forgot register?") - } - return localSysEmsLog -} - -func RegisterSysEmsLog(i ISysEmsLog) { - localSysEmsLog = i -} - func SysDictData() ISysDictData { if localSysDictData == nil { panic("implement not found for interface ISysDictData, forgot register?") @@ -484,61 +387,6 @@ func RegisterSysDictData(i ISysDictData) { localSysDictData = i } -func SysBlacklist() ISysBlacklist { - if localSysBlacklist == nil { - panic("implement not found for interface ISysBlacklist, forgot register?") - } - return localSysBlacklist -} - -func RegisterSysBlacklist(i ISysBlacklist) { - localSysBlacklist = i -} - -func SysCronGroup() ISysCronGroup { - if localSysCronGroup == nil { - panic("implement not found for interface ISysCronGroup, forgot register?") - } - return localSysCronGroup -} - -func RegisterSysCronGroup(i ISysCronGroup) { - localSysCronGroup = i -} - -func SysCurdDemo() ISysCurdDemo { - if localSysCurdDemo == nil { - panic("implement not found for interface ISysCurdDemo, forgot register?") - } - return localSysCurdDemo -} - -func RegisterSysCurdDemo(i ISysCurdDemo) { - localSysCurdDemo = i -} - -func SysGenCodes() ISysGenCodes { - if localSysGenCodes == nil { - panic("implement not found for interface ISysGenCodes, forgot register?") - } - return localSysGenCodes -} - -func RegisterSysGenCodes(i ISysGenCodes) { - localSysGenCodes = i -} - -func SysLog() ISysLog { - if localSysLog == nil { - panic("implement not found for interface ISysLog, forgot register?") - } - return localSysLog -} - -func RegisterSysLog(i ISysLog) { - localSysLog = i -} - func SysLoginLog() ISysLoginLog { if localSysLoginLog == nil { panic("implement not found for interface ISysLoginLog, forgot register?") @@ -571,3 +419,157 @@ func SysAddons() ISysAddons { func RegisterSysAddons(i ISysAddons) { localSysAddons = i } + +func SysAttachment() ISysAttachment { + if localSysAttachment == nil { + panic("implement not found for interface ISysAttachment, forgot register?") + } + return localSysAttachment +} + +func RegisterSysAttachment(i ISysAttachment) { + localSysAttachment = i +} + +func SysCron() ISysCron { + if localSysCron == nil { + panic("implement not found for interface ISysCron, forgot register?") + } + return localSysCron +} + +func RegisterSysCron(i ISysCron) { + localSysCron = i +} + +func SysCronGroup() ISysCronGroup { + if localSysCronGroup == nil { + panic("implement not found for interface ISysCronGroup, forgot register?") + } + return localSysCronGroup +} + +func RegisterSysCronGroup(i ISysCronGroup) { + localSysCronGroup = i +} + +func SysAddonsConfig() ISysAddonsConfig { + if localSysAddonsConfig == nil { + panic("implement not found for interface ISysAddonsConfig, forgot register?") + } + return localSysAddonsConfig +} + +func RegisterSysAddonsConfig(i ISysAddonsConfig) { + localSysAddonsConfig = i +} + +func SysBlacklist() ISysBlacklist { + if localSysBlacklist == nil { + panic("implement not found for interface ISysBlacklist, forgot register?") + } + return localSysBlacklist +} + +func RegisterSysBlacklist(i ISysBlacklist) { + localSysBlacklist = i +} + +func SysConfig() ISysConfig { + if localSysConfig == nil { + panic("implement not found for interface ISysConfig, forgot register?") + } + return localSysConfig +} + +func RegisterSysConfig(i ISysConfig) { + localSysConfig = i +} + +func SysCurdDemo() ISysCurdDemo { + if localSysCurdDemo == nil { + panic("implement not found for interface ISysCurdDemo, forgot register?") + } + return localSysCurdDemo +} + +func RegisterSysCurdDemo(i ISysCurdDemo) { + localSysCurdDemo = i +} + +func SysLog() ISysLog { + if localSysLog == nil { + panic("implement not found for interface ISysLog, forgot register?") + } + return localSysLog +} + +func RegisterSysLog(i ISysLog) { + localSysLog = i +} + +func SysSmsLog() ISysSmsLog { + if localSysSmsLog == nil { + panic("implement not found for interface ISysSmsLog, forgot register?") + } + return localSysSmsLog +} + +func RegisterSysSmsLog(i ISysSmsLog) { + localSysSmsLog = i +} + +func SysProvinces() ISysProvinces { + if localSysProvinces == nil { + panic("implement not found for interface ISysProvinces, forgot register?") + } + return localSysProvinces +} + +func RegisterSysProvinces(i ISysProvinces) { + localSysProvinces = i +} + +func SysServeLog() ISysServeLog { + if localSysServeLog == nil { + panic("implement not found for interface ISysServeLog, forgot register?") + } + return localSysServeLog +} + +func RegisterSysServeLog(i ISysServeLog) { + localSysServeLog = i +} + +func SysDictType() ISysDictType { + if localSysDictType == nil { + panic("implement not found for interface ISysDictType, forgot register?") + } + return localSysDictType +} + +func RegisterSysDictType(i ISysDictType) { + localSysDictType = i +} + +func SysEmsLog() ISysEmsLog { + if localSysEmsLog == nil { + panic("implement not found for interface ISysEmsLog, forgot register?") + } + return localSysEmsLog +} + +func RegisterSysEmsLog(i ISysEmsLog) { + localSysEmsLog = i +} + +func SysGenCodes() ISysGenCodes { + if localSysGenCodes == nil { + panic("implement not found for interface ISysGenCodes, forgot register?") + } + return localSysGenCodes +} + +func RegisterSysGenCodes(i ISysGenCodes) { + localSysGenCodes = i +} diff --git a/server/internal/service/tcpclient.go b/server/internal/service/tcpclient.go index 7f9d83e..be9d54b 100644 --- a/server/internal/service/tcpclient.go +++ b/server/internal/service/tcpclient.go @@ -1,5 +1,5 @@ // ================================================================================ -// Code generated by GoFrame CLI tool. DO NOT EDIT. +// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT. // You can delete these comments if you wish manually maintain this interface file. // ================================================================================ @@ -13,20 +13,35 @@ import ( type ( IAuthClient interface { + // Instance 获取实例 Instance() *tcp.Client + // Start 启动服务 Start(ctx context.Context) + // Stop 停止服务 Stop(ctx context.Context) + // OnResponseAuthSummary 响应授权信息 OnResponseAuthSummary(ctx context.Context, req *servmsg.AuthSummaryRes) + // OnResponseExampleHello 一个tcp请求例子 OnResponseExampleHello(ctx context.Context, req *servmsg.ExampleHelloRes) } ICronClient interface { + // Instance 获取实例 Instance() *tcp.Client + // Start 启动服务 Start(ctx context.Context) + // Stop 停止服务 Stop(ctx context.Context) + // OnCronDelete 删除任务 OnCronDelete(ctx context.Context, req *servmsg.CronDeleteReq) (res *servmsg.CronDeleteRes, err error) + // OnCronEdit 编辑任务 OnCronEdit(ctx context.Context, req *servmsg.CronEditReq) (res *servmsg.CronEditRes, err error) + // OnCronStatus 修改任务状态 OnCronStatus(ctx context.Context, req *servmsg.CronStatusReq) (res *servmsg.CronStatusRes, err error) + // OnCronOnlineExec 执行一次任务 OnCronOnlineExec(ctx context.Context, req *servmsg.CronOnlineExecReq) (res *servmsg.CronOnlineExecRes, err error) + // OnCronDispatchLog 查看调度日志 + OnCronDispatchLog(ctx context.Context, req *servmsg.CronDispatchLogReq) (res *servmsg.CronDispatchLogRes, err error) + // DefaultInterceptor 默认拦截器 DefaultInterceptor(ctx context.Context, msg *tcp.Message) (err error) } ) @@ -36,17 +51,6 @@ var ( localCronClient ICronClient ) -func CronClient() ICronClient { - if localCronClient == nil { - panic("implement not found for interface ICronClient, forgot register?") - } - return localCronClient -} - -func RegisterCronClient(i ICronClient) { - localCronClient = i -} - func AuthClient() IAuthClient { if localAuthClient == nil { panic("implement not found for interface IAuthClient, forgot register?") @@ -57,3 +61,14 @@ func AuthClient() IAuthClient { func RegisterAuthClient(i IAuthClient) { localAuthClient = i } + +func CronClient() ICronClient { + if localCronClient == nil { + panic("implement not found for interface ICronClient, forgot register?") + } + return localCronClient +} + +func RegisterCronClient(i ICronClient) { + localCronClient = i +} diff --git a/server/internal/service/tcpserver.go b/server/internal/service/tcpserver.go index aaa4657..16833d5 100644 --- a/server/internal/service/tcpserver.go +++ b/server/internal/service/tcpserver.go @@ -1,5 +1,5 @@ // ================================================================================ -// Code generated by GoFrame CLI tool. DO NOT EDIT. +// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT. // You can delete these comments if you wish manually maintain this interface file. // ================================================================================ @@ -8,22 +8,37 @@ package service import ( "context" "hotgo/api/servmsg" + "hotgo/internal/library/cron" "hotgo/internal/library/network/tcp" ) type ( ITCPServer interface { + // OnAuthSummary 获取授权信息 OnAuthSummary(ctx context.Context, req *servmsg.AuthSummaryReq) + // CronDelete 删除任务 CronDelete(ctx context.Context, in *servmsg.CronDeleteReq) (err error) + // CronEdit 编辑任务 CronEdit(ctx context.Context, in *servmsg.CronEditReq) (err error) + // CronStatus 修改任务状态 CronStatus(ctx context.Context, in *servmsg.CronStatusReq) (err error) + // CronOnlineExec 执行一次任务 CronOnlineExec(ctx context.Context, in *servmsg.CronOnlineExecReq) (err error) + // DispatchLog 执行一次任务 + DispatchLog(ctx context.Context, in *servmsg.CronDispatchLogReq) (log *cron.Log, err error) + // OnExampleHello 一个tcp请求例子 OnExampleHello(ctx context.Context, req *servmsg.ExampleHelloReq) + // OnExampleRPCHello 一个rpc请求例子 OnExampleRPCHello(ctx context.Context, req *servmsg.ExampleRPCHelloReq) (res *servmsg.ExampleRPCHelloRes, err error) + // Instance 获取实例 Instance() *tcp.Server + // Start 启动服务 Start(ctx context.Context) + // Stop 关闭服务 Stop(ctx context.Context) + // DefaultInterceptor 默认拦截器 DefaultInterceptor(ctx context.Context, msg *tcp.Message) (err error) + // PreFilterInterceptor 预处理 PreFilterInterceptor(ctx context.Context, msg *tcp.Message) (err error) } ) diff --git a/server/manifest/config/config.example.yaml b/server/manifest/config/config.example.yaml index 48f1048..aa6b7ec 100644 --- a/server/manifest/config/config.example.yaml +++ b/server/manifest/config/config.example.yaml @@ -4,25 +4,39 @@ appName: "hotgo" # hotgo配置 hotgo: - # debug开关,开启后接口出现错误时会向前端输出堆栈信息,默认为true + # debug开关,开启后接口出现错误时会向前端输出堆栈信息,可选:false|true,默认为true debug: true + # gf运行模式,可选:not-set|develop|testing|staging|product + mode: "develop" # IP归属地解析方法,可选:cz88|whois,默认为whois ipMethod: "whois" - # 是否为演示系统 false|true + # 是否为演示系统,可选:false|true isDemo: false - # 是否为集群部署 false|true ,默认为false。开启集群必须配置redis,通过redis发布订阅进行集群之间的数据同步 + # 是否为集群部署,可选:false|true 默认为false。开启集群必须配置redis,通过redis发布订阅进行集群之间的数据同步 isCluster: false # 全局请求日志 log: - switch: true # 日志开关,默认为true - queue: true # 是否启用队列,启用时需要配置队列信息,默认为true - module: [ "admin", "api", "default" ] # 需要记录的模块 - skipCode: [ ] # 不记录的状态码,如: ["0", "-1"] + switch: true # 日志开关,可选:false|true,默认为true + queue: true # 是否启用队列,启用时需要配置队列信息,可选:false|true,默认为true + module: [ "admin", "api", "default" ] # 需要记录的模块 + skipCode: [ ] # 不记录的状态码,如: ["0", "-1"] # 系统日志,用于在后台统计异常日志 serveLog: - switch: true # 日志开关,默认为true - queue: true # 是否启用队列,启用时需要配置队列信息,默认为true - levelFormat: ["WARN", "ERRO", "FATA", "PANI"] # 需要记录的等级 + switch: true # 日志开关,可选:false|true,默认为true + queue: true # 是否启用队列,启用时需要配置队列信息,可选:false|true,默认为true + levelFormat: [ "WARN", "ERRO", "FATA", "PANI" ] # 需要记录的等级 + + +# 统一默认日志配置 +defaultLogger: &defaultLogger + level: "all" + flags: 42 + file: "{Y-m-d}.log" # 日志文件格式。默认为"{Y-m-d}.log" + stdoutColorDisabled: false # 关闭终端的颜色打印。可选:false|true,默认false + writerColorEnable: false # 日志文件是否带上颜色。可选:false|true,默认false,表示不带颜色 + rotateExpire: "7d" # 日志保留天数 + rotateBackupLimit: 2 # 最大备份数量 + rotateBackupCompress: 2 # 日志文件压缩级别,0-9,9最高 # gf配置,配置参考:https://goframe.org/pages/viewpage.action?pageId=44449486 @@ -46,11 +60,8 @@ server: pprofPattern: "/pprof" # 开启PProf时有效,表示PProf特性的页面访问路径,对当前Server绑定的所有域名有效。 # 服务日志配置 logger: - level: "all" - flags: 42 - rotateExpire: "7d" # 日志保留天数 - rotateBackupLimit: 2 # 最大备份数量 - rotateBackupCompress: 2 # 日志文件压缩级别,0-9,9最高 + path: "logs/server" # 日志文件路径。默认为空,表示关闭,仅输出到终端 + <<: *defaultLogger tcp: @@ -75,18 +86,6 @@ tcp: secretKey: "123456" # 密钥 -# 统一默认日志配置 -defaultLogger: &defaultLogger - level: "all" - flags: 42 - file: "{Y-m-d}.log" # 日志文件格式。默认为"{Y-m-d}.log" - stdoutColorDisabled: false # 关闭终端的颜色打印。默认开启 - writerColorEnable: false # 日志文件是否带上颜色。默认false,表示不带颜色 - rotateExpire: "7d" # 日志保留天数 - rotateBackupLimit: 2 # 最大备份数量 - rotateBackupCompress: 2 # 日志文件压缩级别,0-9,9最高 - - # 日志配置 logger: # 全局日志:g.Log() @@ -113,15 +112,15 @@ logger: # Viewer. 配置参考:https://goframe.org/pages/viewpage.action?pageId=1114335 viewer: paths: "resource/template" - defaultFile: "index.html" - delimiters: ["@{", "}"] - homeLayout: "home/index.html" + defaultFile: "index.html" + delimiters: [ "@{", "}" ] + homeLayout: "home/index.html" # 内容设置 setting: - title: "HotGo" - keywords: "中后台解决方案,gf框架,vue3" + title: "HotGo" + keywords: "中后台解决方案,gf框架,vue3" description: "hotgo 是一个基于 goframe2,vue3,vite2,TypeScript,uniapp 的中后台解决方案,它可以帮助你快速搭建企业级中后台项目,相信不管是从新技术使用还是其他方面,都能帮助到你,持续更新中。" @@ -155,19 +154,19 @@ router: # 前缀 prefix: "/api" # 不需要验证登录的路由地址 - exceptLogin: [] + exceptLogin: [ ] # websocket websocket: # 前缀 prefix: "/socket" # 不需要验证登录的路由地址 - exceptLogin: [] + exceptLogin: [ ] # 前台页面 home: # 前缀 prefix: "/home" # 不需要验证登录的路由地址 - exceptLogin: [] + exceptLogin: [ ] #缓存 @@ -224,7 +223,8 @@ redis: # Database. 配置参考:https://goframe.org/pages/viewpage.action?pageId=1114245 database: logger: - level: "all" + path: "logs/database" # 日志文件路径。默认为空,表示关闭,仅输出到终端 + <<: *defaultLogger stdout: true default: link: "mysql:hotgo:hg123456.@tcp(127.0.0.1:3306)/hotgo?loc=Local&parseTime=true" @@ -240,10 +240,10 @@ jaeger: # 生成代码 hggen: - allowedIPs: ["127.0.0.1", "*"] # 白名单,*代表所有,只有允许的IP后台才能使用生成代码功能 - selectDbs: [ "default" ] # 可选生成表的数据库配置名称,支持多库 - disableTables : ["hg_sys_gen_codes","hg_admin_role_casbin"] # 禁用的表,禁用以后将不会在选择表中看到 - delimiters: ["@{", "}"] # 模板引擎变量分隔符号 + allowedIPs: [ "127.0.0.1", "*" ] # 白名单,*代表所有,只有允许的IP后台才能使用生成代码功能 + selectDbs: [ "default" ] # 可选生成表的数据库配置名称,支持多库 + disableTables: [ "hg_sys_gen_codes","hg_admin_role_casbin" ] # 禁用的表,禁用以后将不会在选择表中看到 + delimiters: [ "@{", "}" ] # 模板引擎变量分隔符号 # 生成应用模型,所有生成模板允许自定义,可以参考default模板进行改造 application: # CRUD模板 @@ -256,12 +256,12 @@ hggen: templatePath: "./resource/generate/default/curd" # 模板路径 apiPath: "./api/admin" # goApi生成路径 controllerPath: "./internal/controller/admin/sys" # 控制器生成路径 - logicPath : "./internal/logic/sys" # 主要业务生成路径 + logicPath: "./internal/logic/sys" # 主要业务生成路径 inputPath: "./internal/model/input/sysin" # 表单过滤器生成路径 - routerPath : "./internal/router/genrouter" # 生成路由表路径 - sqlPath : "./storage/data/generate" # 生成sql语句路径 + routerPath: "./internal/router/genrouter" # 生成路由表路径 + sqlPath: "./storage/data/generate" # 生成sql语句路径 webApiPath: "../web/src/api" # webApi生成路径 - webViewsPath : "../web/src/views" # web页面生成路径 + webViewsPath: "../web/src/views" # web页面生成路径 # 默认的插件包模板,{$name}会自动替换成实际的插件名称 - group: "addon" # 分组名称 @@ -270,12 +270,12 @@ hggen: templatePath: "./resource/generate/default/curd" # 模板路径 apiPath: "./addons/{$name}/api/admin" # goApi生成路径 controllerPath: "./addons/{$name}/controller/admin/sys" # 控制器生成路径 - logicPath : "./addons/{$name}/logic/sys" # 主要业务生成路径 + logicPath: "./addons/{$name}/logic/sys" # 主要业务生成路径 inputPath: "./addons/{$name}/model/input/sysin" # 表单过滤器生成路径 - routerPath : "./addons/{$name}/router/genrouter" # 生成路由表路径 - sqlPath : "./storage/data/generate/addons" # 生成sql语句路径 + routerPath: "./addons/{$name}/router/genrouter" # 生成路由表路径 + sqlPath: "./storage/data/generate/addons" # 生成sql语句路径 webApiPath: "../web/src/api/addons/{$name}" # webApi生成路径 - webViewsPath : "../web/src/views/addons/{$name}" # web页面生成路径 + webViewsPath: "../web/src/views/addons/{$name}" # web页面生成路径 # 关系树列表模板 tree: diff --git a/server/resource/generate/default/curd/web.index.vue.template b/server/resource/generate/default/curd/web.index.vue.template index e90d872..8fc6782 100644 --- a/server/resource/generate/default/curd/web.index.vue.template +++ b/server/resource/generate/default/curd/web.index.vue.template @@ -26,6 +26,7 @@ :row-key="(row) => row.id" ref="actionRef" :actionColumn="actionColumn" + :checked-row-keys="checkedIds" @update:checked-row-keys="onCheckedRow" :scroll-x="1090" :resizeHeightOffset="-10000" @@ -222,6 +223,8 @@ negativeText: '取消', onPositiveClick: () => { Delete({ id: checkedIds.value }).then((_res) => { + batchDeleteDisabled.value = true; + checkedIds.value = []; message.success('删除成功'); reloadTable(); }); diff --git a/server/storage/data/hotgo.sql b/server/storage/data/hotgo.sql index ae5362a..f819627 100644 --- a/server/storage/data/hotgo.sql +++ b/server/storage/data/hotgo.sql @@ -1,15 +1,13 @@ -- phpMyAdmin SQL Dump --- version 4.9.0.1 --- https://www.phpmyadmin.net/ +-- version 4.4.15.10 +-- https://www.phpmyadmin.net -- --- 主机: localhost:3306 --- 生成日期: 2023-08-11 17:44:16 --- 服务器版本: 5.7.38-log --- PHP 版本: 5.6.40 +-- Host: localhost:3306 +-- Generation Time: 2023-11-25 11:56:04 +-- 服务器版本: 8.0.29 +-- PHP Version: 7.0.33 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; -SET AUTOCOMMIT = 0; -START TRANSACTION; SET time_zone = "+00:00"; @@ -19,7 +17,7 @@ SET time_zone = "+00:00"; /*!40101 SET NAMES utf8mb4 */; -- --- 数据库: `hotgo` +-- Database: `hotgo` -- -- -------------------------------------------------------- @@ -28,9 +26,9 @@ SET time_zone = "+00:00"; -- 表的结构 `hg_addon_hgexample_table` -- -CREATE TABLE `hg_addon_hgexample_table` ( - `id` bigint(20) NOT NULL COMMENT 'ID', - `category_id` bigint(20) NOT NULL COMMENT '分类ID', +CREATE TABLE IF NOT EXISTS `hg_addon_hgexample_table` ( + `id` bigint NOT NULL COMMENT 'ID', + `category_id` bigint NOT NULL COMMENT '分类ID', `flag` json DEFAULT NULL COMMENT '标签', `title` varchar(255) NOT NULL COMMENT '标题', `description` varchar(255) NOT NULL COMMENT '描述', @@ -42,39 +40,42 @@ CREATE TABLE `hg_addon_hgexample_table` ( `map` json DEFAULT NULL COMMENT '动态键值对', `star` decimal(5,1) DEFAULT '0.0' COMMENT '推荐星', `price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '价格', - `views` bigint(20) DEFAULT NULL COMMENT '浏览次数', + `views` bigint DEFAULT NULL COMMENT '浏览次数', `activity_at` date DEFAULT NULL COMMENT '活动时间', `start_at` datetime DEFAULT NULL COMMENT '开启时间', `end_at` datetime DEFAULT NULL COMMENT '结束时间', `switch` tinyint(1) DEFAULT NULL COMMENT '开关', - `sort` int(11) NOT NULL COMMENT '排序', + `sort` int NOT NULL COMMENT '排序', `avatar` varchar(255) DEFAULT '' COMMENT '头像', `sex` tinyint(1) DEFAULT NULL COMMENT '性别', `qq` varchar(20) DEFAULT '' COMMENT 'qq', `email` varchar(60) DEFAULT '' COMMENT '邮箱', `mobile` varchar(20) DEFAULT '' COMMENT '手机号码', `hobby` json DEFAULT NULL COMMENT '爱好', - `channel` int(11) NOT NULL DEFAULT '1' COMMENT '渠道', - `city_id` bigint(20) DEFAULT '0' COMMENT '所在城市', - `pid` bigint(20) NOT NULL COMMENT '上级ID', - `level` int(11) DEFAULT '1' COMMENT '树等级', + `channel` int NOT NULL DEFAULT '1' COMMENT '渠道', + `city_id` bigint DEFAULT '0' COMMENT '所在城市', + `pid` bigint NOT NULL COMMENT '上级ID', + `level` int DEFAULT '1' COMMENT '树等级', `tree` varchar(512) NOT NULL COMMENT '关系树', `remark` varchar(255) DEFAULT NULL COMMENT '备注', `status` tinyint(1) DEFAULT '1' COMMENT '状态', - `created_by` bigint(20) DEFAULT '0' COMMENT '创建者', - `updated_by` bigint(20) DEFAULT '0' COMMENT '更新者', + `created_by` bigint DEFAULT '0' COMMENT '创建者', + `updated_by` bigint DEFAULT '0' COMMENT '更新者', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '修改时间', `deleted_at` datetime DEFAULT NULL COMMENT '删除时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='插件_案例_表格'; +) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb3 COMMENT='插件_案例_表格'; -- -- 转存表中的数据 `hg_addon_hgexample_table` -- INSERT INTO `hg_addon_hgexample_table` (`id`, `category_id`, `flag`, `title`, `description`, `content`, `image`, `images`, `attachfile`, `attachfiles`, `map`, `star`, `price`, `views`, `activity_at`, `start_at`, `end_at`, `switch`, `sort`, `avatar`, `sex`, `qq`, `email`, `mobile`, `hobby`, `channel`, `city_id`, `pid`, `level`, `tree`, `remark`, `status`, `created_by`, `updated_by`, `created_at`, `updated_at`, `deleted_at`) VALUES -(1, 1, '[1, 2]', '测试标题', '描述', '

这是内容............

', 'http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqamvhlq4w3ki6bl.webp', '[\"http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqap5l9brk2lkavu.jpg\", \"http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqaqua7fw8ukbbp5.jpg\"]', 'http://localhost:8000/attachment/2023-07-18/cu54ama4z54oejf5xx.mp3', '[\"http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqawg96ba4cuezvv.xlsx\", \"http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqaup19k9oznyixz.doc\"]', '[{\"key\": \"qwe\", \"value\": \"123\"}, {\"key\": \"asd\", \"value\": \"456\"}]', '3.0', '88.00', 10, '2022-12-23', '2022-12-01 00:00:00', '2022-12-31 23:59:59', 1, 20, '', 15, '133814250', '133814250@qq.com', '15303830571', '[3, 2, 1]', 1, 140406, 0, 1, '', '备注!', 1, 1, 1, '2022-12-15 19:30:14', '2023-07-18 20:05:45', NULL), -(2, 0, '[1]', '测试2', '描述', '

不知道写点啥!


', 'http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqbmxmtaq06gbnqa.jpeg', '[\"http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqborf529kf4cxbm.jpeg\"]', 'http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqawg96ba4cuezvv.xlsx', '[\"http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqaup19k9oznyixz.doc\"]', '{}', '2.5', '10.00', 0, '2023-02-18', NULL, NULL, 2, 30, '', 0, '', '1561561@qq.com', '15303830571', '[2, 1]', 3, 140214, 0, 1, '', '', 1, 1, 1, '2023-02-06 14:17:11', '2023-02-23 13:59:01', NULL); +(1, 1, '[1, 2]', '测试标题', '描述', '

这是内容............

', 'http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqamvhlq4w3ki6bl.webp', '["http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqap5l9brk2lkavu.jpg", "http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqaqua7fw8ukbbp5.jpg"]', 'http://localhost:8000/attachment/2023-07-18/cu54ama4z54oejf5xx.mp3', '["http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqawg96ba4cuezvv.xlsx", "http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqaup19k9oznyixz.doc"]', '[{"key": "qwe", "value": "123"}, {"key": "asd", "value": "456"}]', '3.0', '88.00', 10, '2022-12-23', '2022-12-01 00:00:00', '2022-12-31 23:59:59', 1, 20, '', 15, '133814250', '133814250@qq.com', '15303830571', '[3, 2, 1]', 1, 140406, 0, 1, '', '备注!', 1, 1, 1, '2022-12-15 19:30:14', '2023-07-18 20:05:45', NULL), +(2, 0, '[1]', '测试2', '描述', '

不知道写点啥!


', 'http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqbmxmtaq06gbnqa.jpeg', '["http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqborf529kf4cxbm.jpeg"]', 'http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqawg96ba4cuezvv.xlsx', '["http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqaup19k9oznyixz.doc"]', '{}', '2.5', '10.00', 0, '2023-02-18', NULL, NULL, 2, 30, '', 0, '', '1561561@qq.com', '15303830571', '[2, 1]', 3, 140214, 0, 1, '', '', 1, 1, 1, '2023-02-06 14:17:11', '2023-11-13 17:18:18', NULL), +(3, 0, '[1]', 'AAA', '', '', 'http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqamvhlq4w3ki6bl.webp', '["http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqborf529kf4cxbm.jpeg"]', '', '{}', '{}', '1.0', '10.00', 0, '2023-11-13', NULL, NULL, 1, 40, '', 0, '13311', '1331@qq.cc', '15303830571', '{}', 0, 0, 1, 2, 'tr_1 ', '', 1, 1, 1, '2023-11-13 17:34:42', '2023-11-13 17:55:26', NULL), +(4, 0, '[1]', 'BBB', '', '', 'http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqamvhlq4w3ki6bl.webp', '["http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqborf529kf4cxbm.jpeg"]', '', '{}', '{}', '2.5', '10.00', 0, '2023-11-13', NULL, NULL, 0, 50, '', 0, '12212', '165165@q.cc', '15303830561', '{}', 0, 0, 1, 2, 'tr_1 ', '', 1, 1, 0, '2023-11-13 17:43:58', '2023-11-13 17:43:58', NULL), +(5, 0, '[1]', 'CCC', '', '', 'http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqamvhlq4w3ki6bl.webp', '["http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdqborf529kf4cxbm.jpeg"]', '', '{}', '{}', '1.0', '10.00', 0, '2023-11-13', NULL, NULL, 1, 60, '', 0, '10121212', '122112@qq.cc', '15303830571', '{}', 0, 0, 3, 3, 'tr_1 tr_3 ', '', 1, 1, 1, '2023-11-13 17:45:22', '2023-11-13 17:55:28', NULL); -- -------------------------------------------------------- @@ -82,18 +83,18 @@ INSERT INTO `hg_addon_hgexample_table` (`id`, `category_id`, `flag`, `title`, `d -- 表的结构 `hg_admin_cash` -- -CREATE TABLE `hg_admin_cash` ( - `id` bigint(20) NOT NULL COMMENT 'ID', - `member_id` bigint(20) NOT NULL COMMENT '管理员ID', +CREATE TABLE IF NOT EXISTS `hg_admin_cash` ( + `id` bigint NOT NULL COMMENT 'ID', + `member_id` bigint NOT NULL COMMENT '管理员ID', `money` decimal(10,2) NOT NULL COMMENT '提现金额', `fee` decimal(10,2) NOT NULL COMMENT '手续费', `last_money` decimal(10,2) NOT NULL COMMENT '最终到账金额', `ip` varchar(64) NOT NULL COMMENT '申请人IP', - `status` bigint(20) NOT NULL COMMENT '状态码', + `status` bigint NOT NULL COMMENT '状态码', `msg` varchar(128) NOT NULL COMMENT '处理结果', `handle_at` datetime DEFAULT NULL COMMENT '处理时间', `created_at` datetime NOT NULL COMMENT '申请时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='管理员_提现记录表'; +) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb3 COMMENT='管理员_提现记录表'; -- -- 转存表中的数据 `hg_admin_cash` @@ -108,23 +109,23 @@ INSERT INTO `hg_admin_cash` (`id`, `member_id`, `money`, `fee`, `last_money`, `i -- 表的结构 `hg_admin_credits_log` -- -CREATE TABLE `hg_admin_credits_log` ( - `id` bigint(20) NOT NULL COMMENT '变动ID', - `member_id` bigint(20) DEFAULT '0' COMMENT '管理员ID', - `app_id` varchar(64) CHARACTER SET utf8mb4 DEFAULT '' COMMENT '应用id', - `addons_name` varchar(100) CHARACTER SET utf8mb4 NOT NULL DEFAULT '' COMMENT '插件名称', - `credit_type` varchar(32) CHARACTER SET utf8mb4 NOT NULL DEFAULT '' COMMENT '变动类型', - `credit_group` varchar(32) CHARACTER SET utf8mb4 DEFAULT '' COMMENT '变动组别', +CREATE TABLE IF NOT EXISTS `hg_admin_credits_log` ( + `id` bigint NOT NULL COMMENT '变动ID', + `member_id` bigint DEFAULT '0' COMMENT '管理员ID', + `app_id` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT '' COMMENT '应用id', + `addons_name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NOT NULL DEFAULT '' COMMENT '插件名称', + `credit_type` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NOT NULL DEFAULT '' COMMENT '变动类型', + `credit_group` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT '' COMMENT '变动组别', `before_num` decimal(10,2) DEFAULT '0.00' COMMENT '变动前', `num` decimal(10,2) DEFAULT '0.00' COMMENT '变动数据', `after_num` decimal(10,2) DEFAULT '0.00' COMMENT '变动后', - `remark` varchar(255) CHARACTER SET utf8mb4 DEFAULT '' COMMENT '备注', - `ip` varchar(20) CHARACTER SET utf8mb4 DEFAULT '' COMMENT '操作人IP', - `map_id` bigint(20) DEFAULT '0' COMMENT '关联ID', + `remark` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT '' COMMENT '备注', + `ip` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT '' COMMENT '操作人IP', + `map_id` bigint DEFAULT '0' COMMENT '关联ID', `status` tinyint(1) DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '修改时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='管理员_资产变动表'; +) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb3 COMMENT='管理员_资产变动表'; -- -- 转存表中的数据 `hg_admin_credits_log` @@ -141,22 +142,22 @@ INSERT INTO `hg_admin_credits_log` (`id`, `member_id`, `app_id`, `addons_name`, -- 表的结构 `hg_admin_dept` -- -CREATE TABLE `hg_admin_dept` ( - `id` bigint(20) NOT NULL COMMENT '部门ID', - `pid` bigint(20) DEFAULT '0' COMMENT '父部门ID', +CREATE TABLE IF NOT EXISTS `hg_admin_dept` ( + `id` bigint NOT NULL COMMENT '部门ID', + `pid` bigint DEFAULT '0' COMMENT '父部门ID', `name` varchar(32) DEFAULT NULL COMMENT '部门名称', `code` varchar(255) DEFAULT NULL COMMENT '部门编码', `type` varchar(10) DEFAULT NULL COMMENT '部门类型', `leader` varchar(32) DEFAULT NULL COMMENT '负责人', `phone` varchar(11) DEFAULT NULL COMMENT '联系电话', `email` varchar(64) DEFAULT NULL COMMENT '邮箱', - `level` int(11) NOT NULL COMMENT '关系树等级', + `level` int NOT NULL COMMENT '关系树等级', `tree` varchar(512) DEFAULT NULL COMMENT '关系树', - `sort` int(11) DEFAULT '0' COMMENT '排序', + `sort` int DEFAULT '0' COMMENT '排序', `status` tinyint(1) DEFAULT '1' COMMENT '部门状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='后台_部门'; +) ENGINE=InnoDB AUTO_INCREMENT=110 DEFAULT CHARSET=utf8mb3 COMMENT='后台_部门'; -- -- 转存表中的数据 `hg_admin_dept` @@ -179,27 +180,27 @@ INSERT INTO `hg_admin_dept` (`id`, `pid`, `name`, `code`, `type`, `leader`, `pho -- 表的结构 `hg_admin_member` -- -CREATE TABLE `hg_admin_member` ( - `id` bigint(20) NOT NULL COMMENT '管理员ID', - `dept_id` bigint(20) DEFAULT '0' COMMENT '部门ID', - `role_id` bigint(20) DEFAULT '10' COMMENT '角色ID', +CREATE TABLE IF NOT EXISTS `hg_admin_member` ( + `id` bigint NOT NULL COMMENT '管理员ID', + `dept_id` bigint DEFAULT '0' COMMENT '部门ID', + `role_id` bigint DEFAULT '10' COMMENT '角色ID', `real_name` varchar(32) DEFAULT '' COMMENT '真实姓名', `username` varchar(20) NOT NULL DEFAULT '' COMMENT '帐号', `password_hash` char(32) NOT NULL DEFAULT '' COMMENT '密码', `salt` char(16) NOT NULL COMMENT '密码盐', `password_reset_token` varchar(150) DEFAULT '' COMMENT '密码重置令牌', - `integral` decimal(10,2) UNSIGNED DEFAULT '0.00' COMMENT '积分', - `balance` decimal(10,2) UNSIGNED DEFAULT '0.00' COMMENT '余额', + `integral` decimal(10,2) unsigned DEFAULT '0.00' COMMENT '积分', + `balance` decimal(10,2) unsigned DEFAULT '0.00' COMMENT '余额', `avatar` char(150) DEFAULT '' COMMENT '头像', `sex` tinyint(1) DEFAULT '1' COMMENT '性别', `qq` varchar(20) DEFAULT '' COMMENT 'qq', `email` varchar(60) DEFAULT '' COMMENT '邮箱', `mobile` varchar(20) DEFAULT '' COMMENT '手机号码', `birthday` date DEFAULT NULL COMMENT '生日', - `city_id` bigint(20) DEFAULT '0' COMMENT '城市编码', + `city_id` bigint DEFAULT '0' COMMENT '城市编码', `address` varchar(100) DEFAULT '' COMMENT '联系地址', - `pid` bigint(20) NOT NULL COMMENT '上级管理员ID', - `level` int(11) DEFAULT '1' COMMENT '关系树等级', + `pid` bigint NOT NULL COMMENT '上级管理员ID', + `level` int DEFAULT '1' COMMENT '关系树等级', `tree` varchar(512) NOT NULL COMMENT '关系树', `invite_code` varchar(12) DEFAULT NULL COMMENT '邀请码', `cash` json DEFAULT NULL COMMENT '提现配置', @@ -208,14 +209,14 @@ CREATE TABLE `hg_admin_member` ( `status` tinyint(1) DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '修改时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='管理员_用户表'; +) ENGINE=InnoDB AUTO_INCREMENT=13 DEFAULT CHARSET=utf8mb3 COMMENT='管理员_用户表'; -- -- 转存表中的数据 `hg_admin_member` -- INSERT INTO `hg_admin_member` (`id`, `dept_id`, `role_id`, `real_name`, `username`, `password_hash`, `salt`, `password_reset_token`, `integral`, `balance`, `avatar`, `sex`, `qq`, `email`, `mobile`, `birthday`, `city_id`, `address`, `pid`, `level`, `tree`, `invite_code`, `cash`, `last_active_at`, `remark`, `status`, `created_at`, `updated_at`) VALUES -(1, 100, 1, '孟帅', 'admin', 'a7c588fffeb2c1d99b29879d7fe97c78', '6541561', '', '89.00', '99290.78', 'http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdq8er9nfkchdopav.png', 1, '133814250', '133814250@qq.com', '15303830571', '2016-04-16', 410172, '莲花街001号', 0, 1, '', '111', '{\"name\": \"孟帅\", \"account\": \"15303830571\", \"payeeCode\": \"http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdq8mqal5isvcb58g.jpg\"}', '2023-08-11 17:42:23', NULL, 1, '2021-02-12 17:59:45', '2023-08-11 17:42:23'), +(1, 100, 1, '孟帅', 'admin', 'a7c588fffeb2c1d99b29879d7fe97c78', '6541561', '', '89.00', '99290.78', 'http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdq8er9nfkchdopav.png', 1, '133814250', '133814250@qq.com', '15303830571', '2016-04-16', 410172, '莲花街001号', 0, 1, '', '111', '{"name": "孟帅", "account": "15303830571", "payeeCode": "http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdq8mqal5isvcb58g.jpg"}', '2023-11-25 11:21:38', NULL, 1, '2021-02-12 17:59:45', '2023-11-25 11:21:38'), (3, 100, 2, '测试管理员', 'test', 'a7c588fffeb2c1d99b29879d7fe97c78', '6541561', '', '0.00', '4.00', 'http://alioss.qvnidaye.com//images/2021/03/12/image_1615529198_vMK4kwq2.jpg', 1, '', 'c@qq.cc', '15303888888', '2016-04-13', 371100, '大潮街道666号', 1, 2, 'tr_1 ', '222', NULL, '2023-08-11 17:42:10', '', 1, '2022-02-11 17:59:45', '2023-08-11 17:42:10'), (8, 102, 200, '阿萌', 'ameng', '382df3b083a27886edb94e669a857c33', 'hfuUEb', '', '11.00', '4.22', '', 2, '', '', '', NULL, 0, '', 1, 2, 'tr_1 ', '333', NULL, '2023-08-02 16:31:59', '', 1, '2023-02-03 17:34:31', '2023-08-02 16:31:59'), (9, 100, 206, '黄敏', 'test_finance', '151f5f6bb8b223fc7b589a32effb6f91', 'FhShzw', '', '0.00', '0.00', 'http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdq8er9nfkchdopav.png', 1, '', '', '', NULL, 0, '', 1, 2, 'tr_1 ', '5jZUI3uWLfcj', NULL, NULL, '', 1, '2023-08-02 11:30:45', '2023-08-02 11:31:09'), @@ -228,10 +229,10 @@ INSERT INTO `hg_admin_member` (`id`, `dept_id`, `role_id`, `real_name`, `usernam -- 表的结构 `hg_admin_member_post` -- -CREATE TABLE `hg_admin_member_post` ( - `member_id` bigint(20) NOT NULL COMMENT '管理员ID', - `post_id` bigint(20) NOT NULL COMMENT '岗位ID' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='管理员_用户岗位关联'; +CREATE TABLE IF NOT EXISTS `hg_admin_member_post` ( + `member_id` bigint NOT NULL COMMENT '管理员ID', + `post_id` bigint NOT NULL COMMENT '岗位ID' +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COMMENT='管理员_用户岗位关联'; -- -- 转存表中的数据 `hg_admin_member_post` @@ -251,10 +252,10 @@ INSERT INTO `hg_admin_member_post` (`member_id`, `post_id`) VALUES -- 表的结构 `hg_admin_member_role` -- -CREATE TABLE `hg_admin_member_role` ( - `member_id` bigint(20) NOT NULL COMMENT '管理员ID', - `role_id` bigint(20) NOT NULL COMMENT '角色ID' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='管理员_用户角色关联'; +CREATE TABLE IF NOT EXISTS `hg_admin_member_role` ( + `member_id` bigint NOT NULL COMMENT '管理员ID', + `role_id` bigint NOT NULL COMMENT '角色ID' +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COMMENT='管理员_用户角色关联'; -- -- 转存表中的数据 `hg_admin_member_role` @@ -270,190 +271,191 @@ INSERT INTO `hg_admin_member_role` (`member_id`, `role_id`) VALUES -- 表的结构 `hg_admin_menu` -- -CREATE TABLE `hg_admin_menu` ( - `id` bigint(20) NOT NULL COMMENT '菜单ID', - `pid` bigint(20) DEFAULT '0' COMMENT '父菜单ID', - `title` varchar(64) NOT NULL COMMENT '菜单名称', - `name` varchar(128) NOT NULL COMMENT '名称编码', - `path` varchar(200) DEFAULT NULL COMMENT '路由地址', - `icon` varchar(128) DEFAULT NULL COMMENT '菜单图标', +CREATE TABLE IF NOT EXISTS `hg_admin_menu` ( + `id` bigint NOT NULL COMMENT '菜单ID', + `pid` bigint DEFAULT '0' COMMENT '父菜单ID', + `level` int NOT NULL DEFAULT '1' COMMENT '关系树等级', + `tree` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8_general_ci NOT NULL COMMENT '关系树', + `title` varchar(64) CHARACTER SET utf8mb3 COLLATE utf8_general_ci NOT NULL COMMENT '菜单名称', + `name` varchar(128) CHARACTER SET utf8mb3 COLLATE utf8_general_ci NOT NULL COMMENT '名称编码', + `path` varchar(200) CHARACTER SET utf8mb3 COLLATE utf8_general_ci DEFAULT NULL COMMENT '路由地址', + `icon` varchar(128) CHARACTER SET utf8mb3 COLLATE utf8_general_ci DEFAULT NULL COMMENT '菜单图标', `type` tinyint(1) NOT NULL DEFAULT '1' COMMENT '菜单类型(1目录 2菜单 3按钮)', - `redirect` varchar(255) DEFAULT NULL COMMENT '重定向地址', - `permissions` varchar(255) DEFAULT NULL COMMENT '菜单包含权限集合', - `permission_name` varchar(64) DEFAULT NULL COMMENT '权限名称', - `component` varchar(255) NOT NULL COMMENT '组件路径', + `redirect` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8_general_ci DEFAULT NULL COMMENT '重定向地址', + `permissions` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8_general_ci DEFAULT NULL COMMENT '菜单包含权限集合', + `permission_name` varchar(64) CHARACTER SET utf8mb3 COLLATE utf8_general_ci DEFAULT NULL COMMENT '权限名称', + `component` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8_general_ci NOT NULL COMMENT '组件路径', `always_show` tinyint(1) DEFAULT '0' COMMENT '取消自动计算根路由模式', `active_menu` varchar(255) DEFAULT NULL COMMENT '高亮菜单编码', `is_root` tinyint(1) DEFAULT '0' COMMENT '是否跟路由', `is_frame` tinyint(1) DEFAULT '1' COMMENT '是否内嵌', - `frame_src` varchar(512) DEFAULT NULL COMMENT '内联外部地址', + `frame_src` varchar(512) CHARACTER SET utf8mb3 COLLATE utf8_general_ci DEFAULT NULL COMMENT '内联外部地址', `keep_alive` tinyint(1) DEFAULT '0' COMMENT '缓存该路由', `hidden` tinyint(1) DEFAULT '0' COMMENT '是否隐藏', `affix` tinyint(1) DEFAULT '0' COMMENT '是否固定', - `level` int(11) NOT NULL DEFAULT '1' COMMENT '关系树等级', - `tree` varchar(255) NOT NULL COMMENT '关系树', - `sort` int(11) DEFAULT '0' COMMENT '排序', - `remark` varchar(255) DEFAULT NULL COMMENT '备注', + `sort` int DEFAULT '0' COMMENT '排序', + `remark` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8_general_ci DEFAULT NULL COMMENT '备注', `status` tinyint(1) DEFAULT '1' COMMENT '菜单状态', - `created_at` datetime DEFAULT NULL COMMENT '创建时间', - `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='管理员_菜单权限'; + `updated_at` datetime DEFAULT NULL COMMENT '更新时间', + `created_at` datetime DEFAULT NULL COMMENT '创建时间' +) ENGINE=InnoDB AUTO_INCREMENT=2320 DEFAULT CHARSET=utf8mb3 COMMENT='管理员_菜单权限'; -- -- 转存表中的数据 `hg_admin_menu` -- -INSERT INTO `hg_admin_menu` (`id`, `pid`, `title`, `name`, `path`, `icon`, `type`, `redirect`, `permissions`, `permission_name`, `component`, `always_show`, `active_menu`, `is_root`, `is_frame`, `frame_src`, `keep_alive`, `hidden`, `affix`, `level`, `tree`, `sort`, `remark`, `status`, `created_at`, `updated_at`) VALUES -(2047, 0, 'Dashboard', 'Dashboard', '/dashboard', 'DashboardOutlined', 1, '/dashboard/console', 'dashboard', '控制台', 'LAYOUT', 0, '', 0, 1, '', 0, 0, 0, 1, '', 10, '这是一个备注..', 1, '2022-07-17 11:40:03', '2023-08-08 14:20:30'), -(2048, 2047, '主控台', 'dashboard_console', 'console', '', 2, '', '/console/stat', '主控台', '/dashboard/console/console', 0, '', 0, 1, '', 0, 0, 0, 2, '', 20, '', 1, '2022-07-17 11:45:09', '2022-11-22 11:32:30'), -(2050, 2047, '工作台', 'dashboard_workplace', 'workplace', '', 2, '', 'dashboard_workplace', '工作台', '/dashboard/workplace/workplace', 0, '', 0, 1, '', 0, 0, 0, 2, '', 40, '', 1, '2022-07-17 11:45:09', '2023-07-03 10:06:57'), -(2061, 0, '组织管理', 'Org', '/org', 'AppstoreOutlined', 1, '/org/user', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 1, '', 20, '', 1, '2022-09-16 06:08:19', '2023-07-15 23:07:06'), -(2062, 2061, '后台用户', 'user', 'user', '', 2, '', '/dept/list,/post/list,/role/list,/member/list,/dept/option', '', '/org/user/user', 0, '', 0, 0, '', 0, 0, 0, 2, '', 10, '', 1, '2022-09-16 06:09:25', '2023-07-15 23:02:50'), -(2063, 2061, '部门管理', 'org_dept', 'dept', '', 2, '', '', '', '/org/dept/dept', 0, '', 0, 0, '', 1, 0, 0, 2, '', 20, '', 1, '2022-09-16 14:10:12', '2023-05-16 18:02:11'), -(2064, 2061, '岗位管理', 'org_post', 'post', '', 2, '', '/post/list', '', '/org/post/post', 0, '', 0, 0, '', 1, 0, 0, 2, '', 30, '', 1, '2022-09-16 14:11:05', '2023-07-03 10:13:25'), -(2065, 0, '权限管理', 'Permission', '/permission', 'SafetyCertificateOutlined', 1, '/permission/menu', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 1, '', 40, '', 1, '2022-09-15 22:08:19', '2023-06-25 18:58:43'), -(2066, 2065, '菜单权限', 'permission_menu', 'menu', '', 2, '', '/menu/list', '', '/permission/menu/menu', 0, '', 0, 0, '', 0, 0, 0, 2, '', 10, '', 1, '2022-09-16 06:09:25', '2022-11-22 16:34:12'), -(2067, 2065, '角色权限', 'permission_role', 'role', '', 2, '', '/role/list,/role/dataScope/select,/role/getPermissions', '', '/permission/role/role', 0, '', 0, 0, '', 0, 0, 0, 2, '', 10, '', 1, '2022-09-15 22:09:25', '2023-08-11 14:45:10'), -(2068, 0, '系统设置', 'System', '/system', 'SettingOutlined', 1, '/system/config', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 1, '', 30, '', 1, '2022-09-15 09:17:57', '2023-01-10 17:16:41'), -(2069, 2068, '配置管理', 'system_config', 'config', '', 2, '', '', '', '/system/config/system', 0, '', 0, 0, '', 0, 0, 0, 2, '', 10, '', 1, '2022-09-16 01:19:01', '2023-04-27 23:18:11'), -(2070, 2068, '字典管理', 'system_dict', 'dict', '', 2, '', '', '', '/system/dict/index', 1, '', 0, 0, '', 0, 0, 0, 2, '', 20, '', 1, '2022-09-16 17:33:05', '2023-04-27 23:21:17'), -(2071, 2068, '定时任务', 'system_cron', 'cron', '', 2, '', '', '', '/system/cron/index', 1, '', 0, 0, '', 0, 0, 0, 2, '', 30, '', 1, '2022-09-16 17:33:34', '2022-09-16 17:33:34'), -(2072, 2068, '黑名单', 'system_blacklist', 'blacklist', '', 2, '', '', '', '/system/blacklist/index', 1, '', 0, 0, '', 0, 0, 0, 2, '', 40, '', 1, '2022-09-16 17:34:01', '2022-09-16 17:34:01'), -(2073, 2219, '个人设置', 'home_account', 'account', '', 2, '', '', '', '/home/account/account', 1, '', 0, 0, '', 0, 0, 0, 2, '', 10, '', 1, '2022-09-16 17:34:35', '2023-02-01 15:05:57'), -(2074, 0, '日志管理', 'Logs', '/log', 'UnorderedListOutlined', 1, '', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 1, '', 60, '', 1, '2022-09-16 01:38:32', '2023-01-10 17:19:46'), -(2075, 2074, '全局日志', 'log', 'log', '', 2, '', '/log/list', '', '/log/log/index', 0, '', 0, 0, '', 0, 0, 0, 2, '', 10, '', 1, '2022-09-09 17:39:16', '2023-08-02 14:54:43'), -(2076, 2074, '登录日志', 'login_log', 'login-log', '', 2, '', '', '', '/log/login-log/index', 0, '', 0, 0, '', 1, 0, 0, 2, '', 20, '', 1, '2022-09-15 20:04:20', '2023-07-15 22:53:01'), -(2077, 2074, '全局日志详情', 'log_view', 'view/:id?', '', 2, '', '/log/view', '', '/log/log/view', 0, 'log', 0, 0, '', 0, 1, 0, 2, '', 15, '', 1, '2022-09-14 20:07:04', '2023-07-15 22:57:56'), -(2082, 2076, '登录日志详情', 'loginLogView', 'view/:id?', '', 3, '', '/loginLog/view', '', '/log/login-log/view', 0, 'login_log', 0, 0, '', 0, 1, 0, 3, '', 62, '', 1, '2022-09-14 20:07:04', '2023-07-15 22:53:06'), -(2083, 2076, '登录日志列表', 'login_log_index', 'index', '', 3, '', '/loginLog/list', '', '/log/login-log/index', 0, 'login_log', 0, 0, '', 0, 1, 0, 3, '', 61, '', 1, '2022-09-15 04:38:33', '2023-08-02 14:55:12'), -(2084, 2074, '短信记录', 'sms_log', 'sms', '', 1, '', '/smsLog/list', '', '/log/sms-log/index', 0, '', 0, 0, '', 0, 0, 0, 2, '', 70, '', 1, '2022-09-17 19:13:51', '2023-08-11 14:56:15'), -(2087, 2074, '服务日志', 'monitor_serve_log', 'serve_log', '', 2, '', '', '', '/monitor/serve-log/index', 1, '', 0, 0, '', 0, 0, 0, 2, '', 30, '', 1, '2022-09-18 20:59:28', '2023-07-15 22:48:59'), -(2088, 2087, '服务日志详情', 'monitor_serve_log_view', 'view/:id?', '', 3, '', '/serveLog/view', '', '/monitor/serve-log/view', 0, 'monitor_serve_log', 0, 0, '', 0, 1, 0, 3, '', 62, '', 1, '2022-09-14 20:07:04', '2023-08-11 14:55:53'), -(2089, 2087, '服务日志列表', 'monitor_serve_log_index', 'index', '', 3, '', '/serveLog/list', '', '/monitor/serve-log/index', 0, 'monitor_serve_log', 0, 0, '', 0, 1, 0, 3, '', 61, '', 1, '2022-09-15 04:38:33', '2023-08-11 14:55:27'), -(2090, 0, '系统监控', 'Monitors', '/monitor', 'FundProjectionScreenOutlined', 1, '', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 1, '', 80, '', 1, '2022-09-15 17:38:32', '2023-01-10 17:21:15'), -(2091, 2090, '在线用户', 'monitor_online', 'online', '', 2, '', '/monitor/userOnlineList', '', '/monitor/online/index', 1, '', 0, 0, '', 0, 0, 0, 2, '', 10, '', 1, '2022-09-18 21:23:36', '2023-08-11 14:57:19'), -(2092, 2090, '服务监控', 'monitor_serve_monitor', 'serve_monitor', '', 2, '', '', '', '/monitor/serve-monitor/index', 1, '', 0, 0, '', 0, 0, 0, 2, '', 10, '', 1, '2022-09-18 21:23:36', '2022-09-18 21:23:36'), -(2093, 0, '系统应用', 'Applys', '/apply', 'CodeSandboxOutlined', 1, '/apply/notice', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 1, '', 100, '', 1, '2022-09-18 21:29:53', '2023-01-10 17:27:03'), -(2094, 2093, '通知公告', 'apply_notice', 'notice', '', 2, '', '/notice/list', '', '/apply/notice/index', 1, '', 0, 0, '', 0, 0, 0, 2, '', 10, '', 1, '2022-09-18 21:30:19', '2022-11-23 22:12:51'), -(2095, 2093, '附件管理', 'apply_attachment', 'attachment', '', 2, '', '/attachment/list', '', '/apply/attachment/index', 1, '', 0, 0, '', 0, 0, 0, 2, '', 10, '', 1, '2022-09-18 21:30:40', '2022-11-23 22:13:06'), -(2096, 2093, '地区编码', 'apply_provinces', 'provinces', '', 2, '', '/provinces/list,/provinces/tree,/provinces/childrenList,/provinces/uniqueId', '', '/apply/provinces/index', 1, '', 0, 0, '', 0, 0, 0, 2, '', 10, '', 1, '2022-09-18 21:31:01', '2023-08-11 14:59:38'), -(2097, 0, '开发工具', 'Develops', '/develop', 'CodeOutlined', 1, '/develop/code', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 1, '', 120, '', 1, '2022-09-18 21:32:27', '2023-01-10 17:23:25'), -(2098, 2097, '代码生成', 'develop_code', 'code', '', 2, '', '/genCodes/list,/genCodes/selects,/genCodes/tableSelect', '', '/develop/code/index', 1, '', 0, 0, '', 0, 0, 0, 2, '', 10, '', 1, '2022-09-18 21:32:46', '2023-08-11 15:20:53'), -(2099, 2120, 'API文档', 'apidocs', 'apidocs', '', 1, '', '', '', 'IFRAME', 0, '', 0, 1, 'https://hotgo.facms.cn/swagger', 0, 0, 0, 2, '', 1000, '', 1, '2022-09-18 21:34:09', '2023-07-15 23:14:30'), -(2100, 2120, '使用文档', 'https://github.com/bufanyun/hotgo/tree/v2.0/docs/guide-zh-CN', '/hotgo', '', 1, '', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 2, '', 1100, '', 1, '2022-09-18 21:35:17', '2023-02-22 18:53:21'), -(2102, 0, '关于', 'about', '/about', 'ProjectOutlined', 1, '/about/index', '', '', 'LAYOUT', 1, '', 1, 0, '', 0, 0, 0, 1, '', 9000, '', 1, '2022-09-18 13:37:04', '2023-07-03 11:25:36'), -(2103, 2102, '关于详情', 'about_index', 'index', '', 2, '', '', '', '/about/index', 1, 'about', 0, 0, '', 0, 1, 0, 2, '', 10, '', 1, '2022-09-18 13:38:00', '2023-07-03 11:25:30'), -(2109, 2062, '编辑用户', 'org_user_edit', '', '', 3, '', '/member/edit,/member/view', '', '/', 1, '', 0, 0, '', 0, 1, 0, 3, '', 10, '', 1, '2022-11-22 23:49:17', '2023-04-27 00:02:31'), -(2110, 2062, '删除用户', 'org_user_delete', 'user', '', 3, '', '/member/delete', '', '/', 1, '', 0, 0, '', 0, 1, 0, 3, '', 10, '', 1, '2022-11-23 21:34:51', '2022-11-23 21:51:11'), -(2111, 2062, '修改用户状态', 'org_user_status', 'user', '', 3, '', '/member/status', '', '/', 1, '', 0, 0, '', 0, 1, 0, 3, '', 10, '', 1, '2022-11-23 21:35:48', '2023-01-10 17:39:52'), -(2112, 2063, '编辑部门', 'dept_edit', 'dept', '', 3, '', '/dept/edit', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2022-11-23 21:57:15', '2023-01-10 17:29:26'), -(2113, 2063, '删除部门', 'dept_delete', 'dept', '', 3, '', '/dept/delete', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2022-11-23 21:57:51', '2023-01-10 17:28:55'), -(2114, 2063, '修改部门状态', 'dept_status', 'dept', '', 3, '', '/dept/status', '', '/', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2022-11-23 21:58:40', '2022-11-23 21:58:40'), -(2115, 2064, '编辑岗位', 'post_edit', 'post', '', 3, '', '/post/edit', '', '/', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2022-11-23 21:59:30', '2022-11-23 21:59:30'), -(2116, 2064, '删除岗位', 'post_delete', 'post', '', 3, '', '/post/delete', '', '/', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2022-11-23 22:00:13', '2022-11-23 22:03:06'), -(2117, 2064, '修改岗位状态', 'post_status', 'post', '', 3, '', '/post/status', '', '/', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2022-11-23 22:00:54', '2022-11-23 22:00:54'), -(2118, 2095, '上传附件', 'uploadFile', 'attachment', '', 3, '', '/upload/file', '', '/', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2022-11-23 22:14:19', '2023-08-11 15:15:25'), -(2120, 0, '文档中心', 'doc', 'doc', 'FileTextOutlined', 1, '/doc/apidocs', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 1, '', 2000, '', 1, '2022-11-24 00:08:19', '2023-07-15 23:14:47'), -(2122, 2228, '表格例子', 'hgexample_table_index', 'hgexample_table', '', 2, '', '/hgexample/table/list', '', '/addons/hgexample/table/index', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2022-12-23 15:07:28', '2023-07-18 15:55:46'), -(2124, 2228, '表格详情', 'table_view', 'view/:id?', '', 2, '', '/hgexample/table/view', '', '/addons/hgexample/table/view', 0, 'table_index', 0, 0, '', 0, 1, 0, 2, '', 20, '', 1, '2022-09-14 20:07:04', '2022-09-17 10:43:38'), -(2125, 2097, '生成配置', 'develop_code_deploy', 'deploy/:id?', '', 2, '', '', '', '/develop/code/deploy', 0, 'develop_code', 0, 0, '', 0, 1, 0, 2, '', 20, '', 1, '2022-12-31 17:16:26', '2022-12-31 17:17:46'), -(2198, 2097, '生成演示', 'curdDemo', '/curdDemo', 'MenuOutlined', 1, '', '', '', 'ParentLayout', 1, '', 0, 0, '', 0, 0, 0, 2, '', 200, '', 1, '2023-01-18 15:19:43', '2023-08-11 10:14:17'), -(2199, 2198, '生成演示列表', 'curdDemoIndex', 'index', '', 2, '', '/curdDemo/list', '', '/curdDemo/index', 1, '', 0, 0, '', 0, 0, 0, 2, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2200, 2198, '生成演示详情', 'curdDemoView', 'view/:id?', '', 2, '', '/curdDemo/view', '', '/curdDemo/view', 0, 'curdDemoIndex', 0, 0, '', 0, 1, 0, 2, '', 20, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2201, 2199, '编辑/新增生成演示', 'curdDemoEdit', '', '', 3, '', '/curdDemo/edit', '', '', 1, '', 0, 0, '', 0, 1, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2202, 2201, '获取生成演示最大排序', 'curdDemoMaxSort', '', '', 3, '', '/curdDemo/maxSort', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2203, 2199, '删除生成演示', 'curdDemoDelete', '', '', 3, '', '/curdDemo/delete', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2204, 2199, '修改生成演示状态', 'curdDemoStatus', '', '', 3, '', '/curdDemo/status', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2205, 2199, '操作生成演示开关', 'curdDemoSwitch', '', '', 3, '', '/curdDemo/switch', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2206, 2199, '导出生成演示', 'curdDemoExport', '', '', 3, '', '/curdDemo/export', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2207, 2076, '删除登录日志', 'loginLogDelete', '', '', 3, '', '/loginLog/delete', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-19 21:06:45', '2023-05-11 22:12:05'), -(2208, 2076, '导出登录日志', 'loginLogExport', '', '', 3, '', '/loginLog/export', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-19 21:06:45', '2023-05-11 22:12:21'), -(2209, 2087, '删除服务日志', 'serveLogDelete', '', '', 3, '', '/serveLog/delete', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-20 18:37:50', '2023-01-20 18:37:50'), -(2210, 2087, '导出服务日志', 'serveLogExport', '', '', 3, '', '/serveLog/export', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-20 18:37:50', '2023-01-20 18:37:50'), -(2211, 2094, '获取公告最大排序', 'noticeMaxSort', '', '', 3, '', '/notice/maxSort', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2212, 2094, '删除公告', 'noticeDelete', '', '', 3, '', '/notice/delete', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2213, 2094, '修改公告状态', 'noticeStatus', '', '', 3, '', '/notice/status', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2214, 2094, '操作公告开关', 'noticeSwitch', '', '', 3, '', '/notice/switch', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2215, 2094, '发送/编辑通知', 'noticeEditNotify', '', '', 3, '', '/notice/editNotify', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2216, 2094, '发送/编辑公告', 'noticeEditNotice', '', '', 3, '', '/notice/editNotice', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2217, 2094, '发送/编辑私信', 'noticeEditLetter', '', '', 3, '', '/notice/editLetter', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2218, 2094, '编辑公告', 'noticeEdit', '', '', 3, '', '/notice/edit', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2219, 0, '个人中心', 'home', '/home', 'UserOutlined', 1, '', '', '', 'LAYOUT', 1, '', 0, 2, '', 0, 0, 0, 1, '', 150, '', 1, '2023-02-01 14:59:40', '2023-02-01 15:01:56'), -(2220, 2219, '我的消息', 'home_message', 'message', '', 2, '', '/notice/messageList', '', '/home/message/message', 1, '', 0, 2, '', 0, 0, 0, 2, '', 20, '', 1, '2023-02-01 15:05:17', '2023-08-02 14:54:10'), -(2221, 2122, '获取最大排序', 'testMaxSort', '/test/maxSort', '', 3, '', '/test/maxSort', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-02-06 14:29:42', '2023-02-06 14:29:42'), -(2222, 2122, '导出测试', 'testExport', '', '', 3, '', '/test/export', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-20 18:37:50', '2023-01-20 18:37:50'), -(2223, 2122, '删除测试', 'testDelete', '', '', 3, '', '/test/delete', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2224, 2122, '修改测试状态', 'testStatus', '', '', 3, '', '/test/status', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2225, 2122, '操作测试开关', 'testSwitch', '', '', 3, '', '/test/switch', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2226, 2122, '编辑测试', 'testEdit', '', '', 3, '', '/test/edit', '', '', 1, '', 0, 0, '', 0, 0, 0, 3, '', 10, '', 1, '2023-01-18 15:19:43', '2023-01-18 15:19:43'), -(2227, 0, '插件应用', 'addons', '/addons', 'AppstoreOutlined', 1, '/addons/hgexample/hgexample_portal', '', '', 'LAYOUT', 1, '', 0, 2, '', 0, 0, 0, 1, '', 130, '', 1, '2023-02-17 13:44:27', '2023-07-15 23:06:34'), -(2228, 2227, '功能案例', 'hgexample', '/hgexample', '', 1, '', '', '', '/hgexample', 1, '', 0, 2, '', 0, 0, 0, 2, '', 10, '', 1, '2023-02-17 13:44:27', '2023-02-17 14:21:48'), -(2229, 2097, '插件管理', 'develop_addons', 'addons', '', 2, '', '/addons/selects,/addons/list', '', '/develop/addons/index', 1, '', 0, 0, '', 0, 0, 0, 2, '', 20, '', 1, '2022-09-18 21:32:46', '2023-08-11 15:23:39'), -(2230, 2228, '应用入口', 'hgexample_portal', 'hgexample_portal', '', 2, '', '', '', '/addons/hgexample/portal/index', 1, '', 0, 0, '', 0, 0, 0, 3, '', 5, '', 1, '2022-09-14 20:07:04', '2023-02-18 16:30:05'), -(2231, 2228, '插件配置', 'hgexample_config', 'hgexample_config', '', 2, '', '', '', '/addons/hgexample/config/system', 1, '', 0, 0, '', 0, 0, 0, 3, '', 8, '', 1, '2022-09-14 20:07:04', '2023-02-18 16:30:05'), -(2232, 2237, '在线充值', 'asset_recharge', 'recharge', '', 2, '', '/order/create,/order/option', '', '/asset/recharge/recharge', 1, '', 0, 2, '', 0, 0, 0, 2, '', 10, '', 1, '2023-02-01 15:05:17', '2023-08-02 14:58:27'), -(2235, 2237, '资金变动导出', 'creditsLogExport', '', '', 3, '', '/creditsLog/export', '', '', 1, '', 0, 0, '', 0, 0, 0, 2, '', 10, '', 1, '2023-04-15 15:59:58', '2023-04-18 22:16:52'), -(2236, 2237, '资金变动', 'creditsLogIndex', 'creditsLogIndex', '', 2, '', '/creditsLog/list,/creditsLog/option', '', '/asset/creditsLog/index', 1, '', 0, 0, '', 0, 0, 0, 2, '', 100, '', 1, NULL, '2023-08-02 14:58:02'), -(2237, 0, '资金管理', 'asset', '/asset', 'AccountBookOutlined', 1, '', '', '', 'LAYOUT', 1, '', 0, 2, '', 0, 0, 0, 1, '', 90, '', 1, '2023-04-18 22:16:20', '2023-04-18 22:16:20'), -(2240, 2232, '充值记录', 'asset_recharge_log', '', '', 3, '', '/order/list', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 40, '', 1, '2023-04-18 23:26:01', '2023-04-25 14:25:23'), -(2241, 2232, '受理退款', 'asset_recharge_accept_refund', '', '', 3, '', '/order/acceptRefund', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 40, '', 1, '2023-04-18 23:26:01', '2023-04-25 14:25:23'), -(2242, 2232, '申请退款', 'asset_recharge_apply_refund', '', '', 3, '', '/order/applyRefund', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 40, '', 1, '2023-04-18 23:26:01', '2023-04-25 14:25:23'), -(2243, 2232, '删除关闭订单', 'asset_recharge_order_delete', '', '', 3, '', '/order/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 40, '', 1, '2023-04-18 23:26:01', '2023-04-25 14:25:23'), -(2244, 2237, '提现管理', 'asset_cash', '/cash', '', 2, '', '/cash/list,/cash/apply,/config/getCash', '', '/asset/cash/index', 1, '', 0, 0, '', 0, 0, 0, 2, '', 20, '', 1, '2022-11-29 12:30:00', '2023-08-02 14:57:31'), -(2245, 2244, '申请提现', 'cash_apply', '', '', 3, '', '/cash/apply', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-04-26 21:37:56', '2023-04-26 21:37:56'), -(2246, 2244, '提现打款处理', 'cash_payment', '', '', 3, '', '/cash/payment,/cash/view', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 20, '', 1, '2023-04-26 21:38:25', '2023-04-26 21:40:02'), -(2247, 2062, '变更余额', 'org_user_add_balance', '', '', 3, '', '/member/addBalance', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 40, '', 1, '2023-04-27 22:31:02', '2023-04-27 22:31:02'), -(2248, 2062, '变更积分', 'org_user_add_integral', '', '', 3, '', '/member/addIntegral', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 50, '', 1, '2023-04-27 22:31:43', '2023-04-27 22:31:43'), -(2249, 2062, '重置登录密码', 'member_reset_pwd', '', '', 3, '', '/member/resetPwd', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 60, '', 1, '2023-04-27 22:50:27', '2023-04-27 22:50:27'), -(2250, 2062, '用户列表', 'member_list', '', '', 3, '', '/dept/list,/post/list,/role/list,/member/list,/dept/option', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 0, '', 1, '2023-04-27 23:06:17', '2023-04-27 23:06:17'), -(2251, 2069, '查看配置', 'config_get', '', '', 3, '', '/config/get', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-04-27 23:18:44', '2023-04-27 23:18:44'), -(2252, 2069, '更新配置', 'config_update', '', '', 3, '', '/config/update', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 20, '', 1, '2023-04-27 23:19:14', '2023-04-27 23:19:14'), -(2253, 2070, '查看字典列表', 'dict_data_list', '', '', 3, '', '/dictType/tree,/dictData/list,/config/typeSelect', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-04-27 23:21:47', '2023-04-27 23:32:17'), -(2254, 2070, '编辑字典', 'dict_data_edit', '', '', 3, '', '/dictData/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 20, '', 1, '2023-04-27 23:22:15', '2023-04-27 23:22:15'), -(2255, 2070, '删除字典', 'dict_data_delete', '', '', 3, '', '/dictData/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 30, '', 1, '2023-04-27 23:22:15', '2023-04-27 23:22:15'), -(2256, 2070, '编辑字典类型', 'dict_type_edit', '', '', 3, '', '/dictType/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 40, '', 1, '2023-04-27 23:22:15', '2023-04-27 23:22:15'), -(2257, 2070, '删除字典类型', 'dict_type_delete', '', '', 3, '', '/dictType/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 60, '', 1, '2023-04-27 23:22:15', '2023-04-27 23:22:15'), -(2258, 2071, '任务列表', '/cron/list', '', '', 3, '', '/cron/list', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-04-27 23:25:46', '2023-04-27 23:25:46'), -(2259, 2071, '任务分组列表', '/cronGroup/list', '', '', 3, '', '/cronGroup/select,/cronGroup/list', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 20, '', 1, '2023-04-27 23:26:40', '2023-04-27 23:26:40'), -(2260, 2071, '编辑任务', '/cron/edit', '', '', 3, '', '/cron/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 30, '', 1, '2023-04-27 23:27:07', '2023-04-27 23:27:07'), -(2261, 2071, '删除任务', '/cron/delete', '', '', 3, '', '/cron/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 40, '', 1, '2023-04-27 23:27:59', '2023-04-27 23:27:59'), -(2262, 2071, '修改任务状态', '/cron/status', '', '', 3, '', '/cron/status', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 60, '', 1, '2023-04-27 23:28:16', '2023-04-27 23:28:16'), -(2263, 2071, '在线执行', '/cron/onlineExec', '', '', 3, '', '/cron/onlineExec', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 70, '', 1, '2023-04-27 23:28:32', '2023-04-27 23:28:32'), -(2264, 2071, '编辑任务分组', '/cronGroup/edit', '', '', 3, '', '/cronGroup/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 80, '', 1, '2023-04-27 23:28:55', '2023-04-27 23:28:55'), -(2265, 2071, '删除任务分组', '/cronGroup/delete', '', '', 3, '', '/cronGroup/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 90, '', 1, '2023-04-27 23:29:14', '2023-04-27 23:29:14'), -(2266, 2072, '黑名单列表', '/blacklist/list', '', '', 3, '', '/blacklist/list', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-04-27 23:29:59', '2023-04-27 23:29:59'), -(2267, 2072, '编辑黑名单策略', '/blacklist/edit', '', '', 3, '', '/blacklist/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 20, '', 1, '2023-04-27 23:30:25', '2023-04-27 23:30:25'), -(2268, 2072, '修改策略状态', '/blacklist/status', '', '', 3, '', '/blacklist/status', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 30, '', 1, '2023-04-27 23:31:07', '2023-04-27 23:31:07'), -(2269, 2072, '删除策略', '/blacklist/delete', '', '', 3, '', '/blacklist/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 40, '', 1, '2023-04-27 23:31:21', '2023-04-27 23:31:21'), -(2270, 2073, '修改登录密码', '/member/updatePwd', '', '', 3, '', '/member/updatePwd', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-04-28 16:40:34', '2023-04-28 16:40:34'), -(2271, 2073, '换绑手机号', '/member/updateMobile', '', '', 3, '', '/member/updateMobile', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 20, '', 1, '2023-04-28 16:40:52', '2023-04-28 16:40:52'), -(2272, 2073, '换绑邮箱', '/member/updateEmail', '', '', 3, '', '/member/updateEmail', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 30, '', 1, '2023-04-28 16:41:11', '2023-04-28 16:41:11'), -(2273, 2090, '在线服务', 'monitor_netconn', 'netconn', '', 1, '', '', '', '/monitor/netconn/index', 1, '', 0, 0, '', 0, 0, 0, 2, '', 20, '', 1, '2022-09-18 21:23:36', '2023-07-15 22:47:11'), -(2275, 2273, '服务许可证列表', 'serveLicenseIndex', 'serveLicenseIndex', '', 3, '', '/serveLicense/list', '', '/serveLicense/index', 1, 'monitor_netconn', 0, 0, '', 0, 1, 0, 3, '', 10, '', 1, '2023-07-15 09:36:38', '2023-07-15 22:46:55'), -(2277, 2275, '编辑/新增服务许可证', 'serveLicenseEdit', '', '', 3, '', '/serveLicense/edit', '', '', 1, '', 0, 0, '', 0, 1, 0, 4, '', 10, '', 1, '2023-07-15 09:36:38', '2023-07-15 20:13:43'), -(2278, 2275, '删除服务许可证', 'serveLicenseDelete', '', '', 3, '', '/serveLicense/delete', '', '', 1, '', 0, 0, '', 0, 0, 0, 4, '', 10, '', 1, '2023-07-15 09:36:38', '2023-07-15 20:13:34'), -(2279, 2275, '修改服务许可证状态', 'serveLicenseStatus', '', '', 3, '', '/serveLicense/status', '', '', 1, '', 0, 0, '', 0, 0, 0, 4, '', 10, '', 1, '2023-07-15 09:36:38', '2023-07-15 20:13:27'), -(2280, 2275, '导出服务许可证', 'serveLicenseExport', '', '', 3, '', '/serveLicense/export', '', '', 1, '', 0, 0, '', 0, 0, 0, 4, '', 10, '', 1, '2023-07-15 09:36:38', '2023-07-15 20:13:23'), -(2281, 2275, '分配许可证路由', 'serveLicenseAssignRouter', '', '', 3, '', '/serveLicense/assignRouter', '', '', 1, '', 0, 0, '', 0, 1, 0, 4, '', 10, '', 1, '2023-07-15 09:36:38', '2023-07-15 19:46:30'), -(2282, 2073, '更新基本设置', 'memberUpdateProfile', '', '', 3, '', '/member/updateProfile', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-02 14:52:48', '2023-08-02 14:53:48'), -(2283, 2073, '更新提现设置', 'memberUpdateCash', '', '', 3, '', '/member/updateCash', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-02 14:53:34', '2023-08-02 14:53:34'), -(2292, 2067, '更新菜单权限', 'updatePermissions', '', '', 3, '', '/role/updatePermissions', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 14:45:56', '2023-08-11 14:51:10'), -(2293, 2067, '更新数据权限', 'dataScopeEdit', '', '', 3, '', '/role/dataScope/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 14:51:29', '2023-08-11 14:51:29'), -(2294, 2067, '添加/编辑角色', 'roleEdit', '', '', 3, '', '/role/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 14:52:08', '2023-08-11 14:52:49'), -(2295, 2067, '删除角色', 'roleDelete', '', '', 3, '', '/role/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 14:52:34', '2023-08-11 14:52:34'), -(2296, 2066, '添加/编辑菜单', 'menuEdit', '', '', 3, '', '/menu/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 14:53:24', '2023-08-11 14:53:24'), -(2297, 2066, '删除菜单', 'menuDelete', '', '', 3, '', '/menu/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 14:53:52', '2023-08-11 14:53:52'), -(2298, 2075, '删除全局日志', 'logDelete', '', '', 3, '', '/log/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 14:54:37', '2023-08-11 14:54:37'), -(2299, 2084, '删除短信记录', 'smsLogDelete', '', '', 3, '', '/smsLog/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 14:56:47', '2023-08-11 14:56:47'), -(2300, 2091, '强制退出用户', 'monitorUserOffline', '', '', 3, '', '/monitor/userOffline', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 14:57:52', '2023-08-11 14:57:52'), -(2301, 2096, '添加/编辑省市区', 'provincesEdit', '', '', 3, '', '/provinces/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 15:00:13', '2023-08-11 15:00:13'), -(2302, 2096, '删除省市区', 'provincesDelete', '', '', 3, '', '/provinces/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 15:00:45', '2023-08-11 15:00:45'), -(2305, 2098, '查看生成配置', 'genCodesView', '', '', 3, '', '/genCodes/view', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 15:21:28', '2023-08-11 15:21:28'), -(2306, 2098, '预览代码', 'genCodesPreview', '', '', 3, '', '/genCodes/preview', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 15:22:18', '2023-08-11 15:22:18'), -(2307, 2098, '提交生成', 'genCodesBuild', '', '', 3, '', '/genCodes/build', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 15:22:48', '2023-08-11 15:22:48'), -(2308, 2098, '保存生成配置', 'genCodesEdit', '', '', 3, '', '/genCodes/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 15:23:16', '2023-08-11 15:23:16'), -(2309, 2229, '更新插件配置', 'addonsUpgrade', '', '', 3, '', '/addons/upgrade', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 15:24:11', '2023-08-11 15:24:11'), -(2310, 2229, '卸载插件', 'addonsUninstall', '', '', 3, '', '/addons/uninstall', '', '', 1, '', 0, 2, '', 0, 0, 0, 3, '', 10, '', 1, '2023-08-11 15:24:32', '2023-08-11 15:24:32'); +INSERT INTO `hg_admin_menu` (`id`, `pid`, `level`, `tree`, `title`, `name`, `path`, `icon`, `type`, `redirect`, `permissions`, `permission_name`, `component`, `always_show`, `active_menu`, `is_root`, `is_frame`, `frame_src`, `keep_alive`, `hidden`, `affix`, `sort`, `remark`, `status`, `updated_at`, `created_at`) VALUES +(2047, 0, 1, '', 'Dashboard', 'Dashboard', '/dashboard', 'DashboardOutlined', 1, '/dashboard/console', 'dashboard', '控制台', 'LAYOUT', 0, '', 0, 1, '', 0, 0, 0, 10, '这是一个备注..', 1, '2023-11-13 15:16:58', '2022-07-17 11:40:03'), +(2048, 2047, 2, 'tr_2047 ', '主控台', 'dashboard_console', 'console', '', 2, '', '/console/stat', '主控台', '/dashboard/console/console', 0, '', 0, 1, '', 0, 0, 0, 20, '', 1, '2023-11-13 15:16:58', '2022-07-17 11:45:09'), +(2050, 2047, 2, 'tr_2047 ', '工作台', 'dashboard_workplace', 'workplace', '', 2, '', 'dashboard_workplace', '工作台', '/dashboard/workplace/workplace', 0, '', 0, 1, '', 0, 0, 0, 40, '', 1, '2023-11-13 15:16:58', '2022-07-17 11:45:09'), +(2061, 0, 1, '', '组织管理', 'Org', '/org', 'AppstoreOutlined', 1, '/org/user', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 20, '', 1, '2023-11-13 15:16:58', '2022-09-16 06:08:19'), +(2062, 2061, 2, 'tr_2061 ', '后台用户', 'user', 'user', '', 2, '', '/dept/list,/post/list,/role/list,/member/list,/dept/option', '', '/org/user/user', 0, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-09-16 06:09:25'), +(2063, 2061, 2, 'tr_2061 ', '部门管理', 'org_dept', 'dept', '', 2, '', '', '', '/org/dept/dept', 0, '', 0, 0, '', 1, 0, 0, 20, '', 1, '2023-11-13 15:16:58', '2022-09-16 14:10:12'), +(2064, 2061, 2, 'tr_2061 ', '岗位管理', 'org_post', 'post', '', 2, '', '/post/list', '', '/org/post/post', 0, '', 0, 0, '', 1, 0, 0, 30, '', 1, '2023-11-13 15:16:58', '2022-09-16 14:11:05'), +(2065, 0, 1, '', '权限管理', 'Permission', '/permission', 'SafetyCertificateOutlined', 1, '/permission/menu', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 40, '', 1, '2023-11-13 15:16:58', '2022-09-15 22:08:19'), +(2066, 2065, 2, 'tr_2065 ', '菜单权限', 'permission_menu', 'menu', '', 2, '', '/menu/list', '', '/permission/menu/menu', 0, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-09-16 06:09:25'), +(2067, 2065, 2, 'tr_2065 ', '角色权限', 'permission_role', 'role', '', 2, '', '/role/list,/role/dataScope/select,/role/getPermissions', '', '/permission/role/role', 0, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-09-15 22:09:25'), +(2068, 0, 1, '', '系统设置', 'System', '/system', 'SettingOutlined', 1, '/system/config', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 120, '', 1, '2023-11-17 15:53:10', '2022-09-15 09:17:57'), +(2069, 2068, 2, 'tr_2068 ', '配置管理', 'system_config', 'config', '', 2, '', '', '', '/system/config/system', 0, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-09-16 01:19:01'), +(2070, 2068, 2, 'tr_2068 ', '字典管理', 'system_dict', 'dict', '', 2, '', '', '', '/system/dict/index', 1, '', 0, 0, '', 0, 0, 0, 20, '', 1, '2023-11-13 15:16:58', '2022-09-16 17:33:05'), +(2071, 2068, 2, 'tr_2068 ', '定时任务', 'system_cron', 'cron', '', 2, '', '', '', '/system/cron/index', 1, '', 0, 0, '', 0, 0, 0, 30, '', 1, '2023-11-13 15:16:58', '2022-09-16 17:33:34'), +(2072, 2068, 2, 'tr_2068 ', '黑名单', 'system_blacklist', 'blacklist', '', 2, '', '', '', '/system/blacklist/index', 1, '', 0, 0, '', 0, 0, 0, 40, '', 1, '2023-11-13 15:16:58', '2022-09-16 17:34:01'), +(2073, 2219, 3, 'tr_2093 tr_2219 ', '个人设置', 'home_account', 'account', '', 2, '', '', '', '/home/account/account', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-17 15:27:49', '2022-09-16 17:34:35'), +(2074, 2093, 2, 'tr_2093 ', '日志管理', 'Logs', '/log', '', 1, '', '', '', 'ParentLayout', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-17 15:53:54', '2022-09-16 01:38:32'), +(2075, 2074, 3, 'tr_2093 tr_2074 ', '全局日志', 'log', 'log', '', 2, '', '/log/list', '', '/log/log/index', 0, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-17 15:27:32', '2022-09-09 17:39:16'), +(2076, 2074, 3, 'tr_2093 tr_2074 ', '登录日志', 'login_log', 'login-log', '', 2, '', '', '', '/log/login-log/index', 0, '', 0, 0, '', 1, 0, 0, 20, '', 1, '2023-11-17 15:27:32', '2022-09-15 20:04:20'), +(2077, 2074, 3, 'tr_2093 tr_2074 ', '全局日志详情', 'log_view', 'view/:id?', '', 2, '', '/log/view', '', '/log/log/view', 0, 'log', 0, 0, '', 0, 1, 0, 15, '', 1, '2023-11-17 15:27:32', '2022-09-14 20:07:04'), +(2082, 2076, 4, 'tr_2093 tr_2074 tr_2076 ', '登录日志详情', 'loginLogView', 'view/:id?', '', 3, '', '/loginLog/view', '', '/log/login-log/view', 0, 'login_log', 0, 0, '', 0, 1, 0, 62, '', 1, '2023-11-17 15:27:32', '2022-09-14 20:07:04'), +(2083, 2076, 4, 'tr_2093 tr_2074 tr_2076 ', '登录日志列表', 'login_log_index', 'index', '', 3, '', '/loginLog/list', '', '/log/login-log/index', 0, 'login_log', 0, 0, '', 0, 1, 0, 61, '', 1, '2023-11-17 15:27:32', '2022-09-15 04:38:33'), +(2084, 2074, 3, 'tr_2093 tr_2074 ', '短信记录', 'sms_log', 'sms', '', 1, '', '/smsLog/list', '', '/log/sms-log/index', 0, '', 0, 0, '', 0, 0, 0, 70, '', 1, '2023-11-17 15:27:32', '2022-09-17 19:13:51'), +(2087, 2074, 3, 'tr_2093 tr_2074 ', '服务日志', 'monitor_serve_log', 'serve_log', '', 2, '', '', '', '/monitor/serve-log/index', 1, '', 0, 0, '', 0, 0, 0, 30, '', 1, '2023-11-17 15:27:32', '2022-09-18 20:59:28'), +(2088, 2087, 4, 'tr_2093 tr_2074 tr_2087 ', '服务日志详情', 'monitor_serve_log_view', 'view/:id?', '', 3, '', '/serveLog/view', '', '/monitor/serve-log/view', 0, 'monitor_serve_log', 0, 0, '', 0, 1, 0, 62, '', 1, '2023-11-17 15:27:32', '2022-09-14 20:07:04'), +(2089, 2087, 4, 'tr_2093 tr_2074 tr_2087 ', '服务日志列表', 'monitor_serve_log_index', 'index', '', 3, '', '/serveLog/list', '', '/monitor/serve-log/index', 0, 'monitor_serve_log', 0, 0, '', 0, 1, 0, 61, '', 1, '2023-11-17 15:27:32', '2022-09-15 04:38:33'), +(2090, 0, 1, '', '系统监控', 'Monitors', '/monitor', 'FundProjectionScreenOutlined', 1, '', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 110, '', 1, '2023-11-17 15:34:42', '2022-09-15 17:38:32'), +(2091, 2090, 2, 'tr_2090 ', '在线用户', 'monitor_online', 'online', '', 2, '', '/monitor/userOnlineList', '', '/monitor/online/index', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-09-18 21:23:36'), +(2092, 2090, 2, 'tr_2090 ', '服务监控', 'monitor_serve_monitor', 'serve_monitor', '', 2, '', '', '', '/monitor/serve-monitor/index', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-09-18 21:23:36'), +(2093, 0, 1, '', '系统应用', 'Applys', '/apply', 'CodeSandboxOutlined', 1, '/apply/notice', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 100, '', 1, '2023-11-13 15:16:58', '2022-09-18 21:29:53'), +(2094, 2093, 2, 'tr_2093 ', '通知公告', 'apply_notice', 'notice', '', 2, '', '/notice/list', '', '/apply/notice/index', 1, '', 0, 0, '', 0, 0, 0, 300, '', 1, '2023-11-17 15:28:00', '2022-09-18 21:30:19'), +(2095, 2093, 2, 'tr_2093 ', '附件管理', 'apply_attachment', 'attachment', '', 2, '', '/attachment/list', '', '/apply/attachment/index', 1, '', 0, 0, '', 0, 0, 0, 200, '', 1, '2023-11-17 15:27:58', '2022-09-18 21:30:40'), +(2096, 2093, 2, 'tr_2093 ', '地区编码', 'apply_provinces', 'provinces', '', 2, '', '/provinces/list,/provinces/tree,/provinces/childrenList,/provinces/uniqueId', '', '/apply/provinces/index', 1, '', 0, 0, '', 0, 0, 0, 100, '', 1, '2023-11-17 15:27:55', '2022-09-18 21:31:01'), +(2097, 0, 1, '', '开发工具', 'Develops', '/develop', 'CodeOutlined', 1, '/develop/code', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 210, '', 1, '2023-11-17 15:39:06', '2022-09-18 21:32:27'), +(2098, 2097, 2, 'tr_2097 ', '代码生成', 'develop_code', 'code', '', 2, '', '/genCodes/list,/genCodes/selects,/genCodes/tableSelect', '', '/develop/code/index', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-09-18 21:32:46'), +(2099, 2120, 2, 'tr_2120 ', 'API文档', 'apidocs', 'apidocs', '', 1, '', '', '', 'IFRAME', 0, '', 0, 1, 'https://hotgo.facms.cn/swagger', 0, 0, 0, 1000, '', 1, '2023-11-17 15:38:22', '2022-09-18 21:34:09'), +(2100, 2120, 2, 'tr_2120 ', '使用文档', 'https://github.com/bufanyun/hotgo/tree/v2.0/docs/guide-zh-CN', '/hotgo', '', 1, '', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 1100, '', 1, '2023-11-17 15:38:22', '2022-09-18 21:35:17'), +(2102, 0, 1, '', '关于', 'about', '/about', 'ProjectOutlined', 1, '/about/index', '', '', 'LAYOUT', 1, '', 1, 0, '', 0, 0, 0, 9000, '', 1, '2023-11-13 15:16:58', '2022-09-18 13:37:04'), +(2103, 2102, 2, 'tr_2102 ', '关于详情', 'about_index', 'index', '', 2, '', '', '', '/about/index', 1, 'about', 0, 0, '', 0, 1, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-09-18 13:38:00'), +(2109, 2062, 3, 'tr_2061 tr_2062 ', '编辑用户', 'org_user_edit', '', '', 3, '', '/member/edit,/member/view', '', '/', 1, '', 0, 0, '', 0, 1, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-11-22 23:49:17'), +(2110, 2062, 3, 'tr_2061 tr_2062 ', '删除用户', 'org_user_delete', 'user', '', 3, '', '/member/delete', '', '/', 1, '', 0, 0, '', 0, 1, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-11-23 21:34:51'), +(2111, 2062, 3, 'tr_2061 tr_2062 ', '修改用户状态', 'org_user_status', 'user', '', 3, '', '/member/status', '', '/', 1, '', 0, 0, '', 0, 1, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-11-23 21:35:48'), +(2112, 2063, 3, 'tr_2061 tr_2063 ', '编辑部门', 'dept_edit', 'dept', '', 3, '', '/dept/edit', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-11-23 21:57:15'), +(2113, 2063, 3, 'tr_2061 tr_2063 ', '删除部门', 'dept_delete', 'dept', '', 3, '', '/dept/delete', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-11-23 21:57:51'), +(2114, 2063, 3, 'tr_2061 tr_2063 ', '修改部门状态', 'dept_status', 'dept', '', 3, '', '/dept/status', '', '/', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-11-23 21:58:40'), +(2115, 2064, 3, 'tr_2061 tr_2064 ', '编辑岗位', 'post_edit', 'post', '', 3, '', '/post/edit', '', '/', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-11-23 21:59:30'), +(2116, 2064, 3, 'tr_2061 tr_2064 ', '删除岗位', 'post_delete', 'post', '', 3, '', '/post/delete', '', '/', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-11-23 22:00:13'), +(2117, 2064, 3, 'tr_2061 tr_2064 ', '修改岗位状态', 'post_status', 'post', '', 3, '', '/post/status', '', '/', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-11-23 22:00:54'), +(2118, 2095, 3, 'tr_2093 tr_2095 ', '上传附件', 'uploadFile', 'attachment', '', 3, '', '/upload/file', '', '/', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-11-23 22:14:19'), +(2120, 0, 1, '', '文档中心', 'doc', 'doc', 'FileTextOutlined', 1, '/doc/apidocs', '', '', 'LAYOUT', 1, '', 0, 0, '', 0, 0, 0, 300, '', 1, '2023-11-17 15:38:43', '2022-11-24 00:08:19'), +(2122, 2228, 3, 'tr_2227 tr_2228 ', '表格例子', 'hgexample_table_index', 'hgexample_table', '', 2, '', '/hgexample/table/list', '', '/addons/hgexample/table/index', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2022-12-23 15:07:28'), +(2124, 2228, 3, 'tr_2227 tr_2228 ', '表格详情', 'table_view', 'view/:id?', '', 2, '', '/hgexample/table/view', '', '/addons/hgexample/table/view', 0, 'table_index', 0, 0, '', 0, 1, 0, 20, '', 1, '2023-11-13 15:16:58', '2022-09-14 20:07:04'), +(2125, 2097, 2, 'tr_2097 ', '生成配置', 'develop_code_deploy', 'deploy/:id?', '', 2, '', '', '', '/develop/code/deploy', 0, 'develop_code', 0, 0, '', 0, 1, 0, 20, '', 1, '2023-11-13 15:16:58', '2022-12-31 17:16:26'), +(2198, 2097, 2, 'tr_2097 ', '生成演示', 'curdDemo', '/curdDemo', 'MenuOutlined', 1, '', '', '', 'ParentLayout', 1, '', 0, 0, '', 0, 0, 0, 200, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2199, 2198, 3, 'tr_2097 tr_2198 ', '生成演示列表', 'curdDemoIndex', 'index', '', 2, '', '/curdDemo/list', '', '/curdDemo/index', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2200, 2198, 3, 'tr_2097 tr_2198 ', '生成演示详情', 'curdDemoView', 'view/:id?', '', 2, '', '/curdDemo/view', '', '/curdDemo/view', 0, 'curdDemoIndex', 0, 0, '', 0, 1, 0, 20, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2201, 2199, 4, 'tr_2097 tr_2198 tr_2199 ', '编辑/新增生成演示', 'curdDemoEdit', '', '', 3, '', '/curdDemo/edit', '', '', 1, '', 0, 0, '', 0, 1, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2202, 2201, 5, 'tr_2097 tr_2198 tr_2199 tr_2201 ', '获取生成演示最大排序', 'curdDemoMaxSort', '', '', 3, '', '/curdDemo/maxSort', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2203, 2199, 4, 'tr_2097 tr_2198 tr_2199 ', '删除生成演示', 'curdDemoDelete', '', '', 3, '', '/curdDemo/delete', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2204, 2199, 4, 'tr_2097 tr_2198 tr_2199 ', '修改生成演示状态', 'curdDemoStatus', '', '', 3, '', '/curdDemo/status', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2205, 2199, 4, 'tr_2097 tr_2198 tr_2199 ', '操作生成演示开关', 'curdDemoSwitch', '', '', 3, '', '/curdDemo/switch', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2206, 2199, 4, 'tr_2097 tr_2198 tr_2199 ', '导出生成演示', 'curdDemoExport', '', '', 3, '', '/curdDemo/export', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2207, 2076, 4, 'tr_2093 tr_2074 tr_2076 ', '删除登录日志', 'loginLogDelete', '', '', 3, '', '/loginLog/delete', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-17 15:27:32', '2023-01-19 21:06:45'), +(2208, 2076, 4, 'tr_2093 tr_2074 tr_2076 ', '导出登录日志', 'loginLogExport', '', '', 3, '', '/loginLog/export', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-17 15:27:32', '2023-01-19 21:06:45'), +(2209, 2087, 4, 'tr_2093 tr_2074 tr_2087 ', '删除服务日志', 'serveLogDelete', '', '', 3, '', '/serveLog/delete', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-17 15:27:32', '2023-01-20 18:37:50'), +(2210, 2087, 4, 'tr_2093 tr_2074 tr_2087 ', '导出服务日志', 'serveLogExport', '', '', 3, '', '/serveLog/export', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-17 15:27:32', '2023-01-20 18:37:50'), +(2211, 2094, 3, 'tr_2093 tr_2094 ', '获取公告最大排序', 'noticeMaxSort', '', '', 3, '', '/notice/maxSort', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2212, 2094, 3, 'tr_2093 tr_2094 ', '删除公告', 'noticeDelete', '', '', 3, '', '/notice/delete', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2213, 2094, 3, 'tr_2093 tr_2094 ', '修改公告状态', 'noticeStatus', '', '', 3, '', '/notice/status', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2214, 2094, 3, 'tr_2093 tr_2094 ', '操作公告开关', 'noticeSwitch', '', '', 3, '', '/notice/switch', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2215, 2094, 3, 'tr_2093 tr_2094 ', '发送/编辑通知', 'noticeEditNotify', '', '', 3, '', '/notice/editNotify', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2216, 2094, 3, 'tr_2093 tr_2094 ', '发送/编辑公告', 'noticeEditNotice', '', '', 3, '', '/notice/editNotice', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2217, 2094, 3, 'tr_2093 tr_2094 ', '发送/编辑私信', 'noticeEditLetter', '', '', 3, '', '/notice/editLetter', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2218, 2094, 3, 'tr_2093 tr_2094 ', '编辑公告', 'noticeEdit', '', '', 3, '', '/notice/edit', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2219, 2093, 2, 'tr_2093 ', '个人中心', 'home', '/home', 'UserOutlined', 1, '', '', '', 'ParentLayout', 1, '', 0, 2, '', 0, 1, 0, 3000, '', 1, '2023-11-17 15:33:52', '2023-02-01 14:59:40'), +(2220, 2219, 3, 'tr_2093 tr_2219 ', '我的消息', 'home_message', 'message', '', 2, '', '/notice/messageList', '', '/home/message/message', 1, '', 0, 2, '', 0, 0, 0, 20, '', 1, '2023-11-17 15:27:49', '2023-02-01 15:05:17'), +(2221, 2122, 4, 'tr_2227 tr_2228 tr_2122 ', '获取最大排序', 'testMaxSort', '/test/maxSort', '', 3, '', '/test/maxSort', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-02-06 14:29:42'), +(2222, 2122, 4, 'tr_2227 tr_2228 tr_2122 ', '导出测试', 'testExport', '', '', 3, '', '/test/export', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-20 18:37:50'), +(2223, 2122, 4, 'tr_2227 tr_2228 tr_2122 ', '删除测试', 'testDelete', '', '', 3, '', '/test/delete', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2224, 2122, 4, 'tr_2227 tr_2228 tr_2122 ', '修改测试状态', 'testStatus', '', '', 3, '', '/test/status', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2225, 2122, 4, 'tr_2227 tr_2228 tr_2122 ', '操作测试开关', 'testSwitch', '', '', 3, '', '/test/switch', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2226, 2122, 4, 'tr_2227 tr_2228 tr_2122 ', '编辑测试', 'testEdit', '', '', 3, '', '/test/edit', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-01-18 15:19:43'), +(2227, 0, 1, '', '插件应用', 'addons', '/addons', 'AppstoreOutlined', 1, '/addons/hgexample/hgexample_portal', '', '', 'LAYOUT', 1, '', 0, 2, '', 0, 0, 0, 130, '', 1, '2023-11-13 15:16:58', '2023-02-17 13:44:27'), +(2228, 2227, 2, 'tr_2227 ', '功能案例', 'hgexample', '/hgexample', '', 1, '', '', '', '/hgexample', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-02-17 13:44:27'), +(2229, 2097, 2, 'tr_2097 ', '插件管理', 'develop_addons', 'addons', '', 2, '', '/addons/selects,/addons/list', '', '/develop/addons/index', 1, '', 0, 0, '', 0, 0, 0, 20, '', 1, '2023-11-13 15:16:58', '2022-09-18 21:32:46'), +(2230, 2228, 3, 'tr_2227 tr_2228 ', '应用入口', 'hgexample_portal', 'hgexample_portal', '', 2, '', '', '', '/addons/hgexample/portal/index', 1, '', 0, 0, '', 0, 0, 0, 5, '', 1, '2023-11-13 15:16:58', '2022-09-14 20:07:04'), +(2231, 2228, 3, 'tr_2227 tr_2228 ', '插件配置', 'hgexample_config', 'hgexample_config', '', 2, '', '', '', '/addons/hgexample/config/system', 1, '', 0, 0, '', 0, 0, 0, 8, '', 1, '2023-11-13 15:16:58', '2022-09-14 20:07:04'), +(2232, 2237, 3, 'tr_2093 tr_2237 ', '在线充值', 'asset_recharge', 'recharge', '', 2, '', '/order/create,/order/option', '', '/asset/recharge/recharge', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-17 15:28:23', '2023-02-01 15:05:17'), +(2235, 2237, 3, 'tr_2093 tr_2237 ', '资金变动导出', 'creditsLogExport', '', '', 3, '', '/creditsLog/export', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-17 15:28:23', '2023-04-15 15:59:58'), +(2236, 2237, 3, 'tr_2093 tr_2237 ', '资金变动', 'creditsLogIndex', 'creditsLogIndex', '', 2, '', '/creditsLog/list,/creditsLog/option', '', '/asset/creditsLog/index', 1, '', 0, 0, '', 0, 0, 0, 100, '', 1, '2023-11-17 15:28:23', NULL), +(2237, 2093, 2, 'tr_2093 ', '资金管理', 'asset', '/asset', '', 1, '', '', '', 'ParentLayout', 1, '', 0, 2, '', 0, 0, 0, 20, '', 1, '2023-11-17 15:53:57', '2023-04-18 22:16:20'), +(2240, 2232, 4, 'tr_2093 tr_2237 tr_2232 ', '充值记录', 'asset_recharge_log', '', '', 3, '', '/order/list', '', '', 1, '', 0, 2, '', 0, 0, 0, 40, '', 1, '2023-11-17 15:28:23', '2023-04-18 23:26:01'), +(2241, 2232, 4, 'tr_2093 tr_2237 tr_2232 ', '受理退款', 'asset_recharge_accept_refund', '', '', 3, '', '/order/acceptRefund', '', '', 1, '', 0, 2, '', 0, 0, 0, 40, '', 1, '2023-11-17 15:28:23', '2023-04-18 23:26:01'), +(2242, 2232, 4, 'tr_2093 tr_2237 tr_2232 ', '申请退款', 'asset_recharge_apply_refund', '', '', 3, '', '/order/applyRefund', '', '', 1, '', 0, 2, '', 0, 0, 0, 40, '', 1, '2023-11-17 15:28:23', '2023-04-18 23:26:01'), +(2243, 2232, 4, 'tr_2093 tr_2237 tr_2232 ', '删除关闭订单', 'asset_recharge_order_delete', '', '', 3, '', '/order/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 40, '', 1, '2023-11-17 15:28:23', '2023-04-18 23:26:01'), +(2244, 2237, 3, 'tr_2093 tr_2237 ', '提现管理', 'asset_cash', '/cash', '', 2, '', '/cash/list,/cash/apply,/config/getCash', '', '/asset/cash/index', 1, '', 0, 0, '', 0, 0, 0, 20, '', 1, '2023-11-17 15:28:23', '2022-11-29 12:30:00'), +(2245, 2244, 4, 'tr_2093 tr_2237 tr_2244 ', '申请提现', 'cash_apply', '', '', 3, '', '/cash/apply', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-17 15:28:23', '2023-04-26 21:37:56'), +(2246, 2244, 4, 'tr_2093 tr_2237 tr_2244 ', '提现打款处理', 'cash_payment', '', '', 3, '', '/cash/payment,/cash/view', '', '', 1, '', 0, 2, '', 0, 0, 0, 20, '', 1, '2023-11-17 15:28:23', '2023-04-26 21:38:25'), +(2247, 2062, 3, 'tr_2061 tr_2062 ', '变更余额', 'org_user_add_balance', '', '', 3, '', '/member/addBalance', '', '', 1, '', 0, 2, '', 0, 0, 0, 40, '', 1, '2023-11-13 15:16:58', '2023-04-27 22:31:02'), +(2248, 2062, 3, 'tr_2061 tr_2062 ', '变更积分', 'org_user_add_integral', '', '', 3, '', '/member/addIntegral', '', '', 1, '', 0, 2, '', 0, 0, 0, 50, '', 1, '2023-11-13 15:16:58', '2023-04-27 22:31:43'), +(2249, 2062, 3, 'tr_2061 tr_2062 ', '重置登录密码', 'member_reset_pwd', '', '', 3, '', '/member/resetPwd', '', '', 1, '', 0, 2, '', 0, 0, 0, 60, '', 1, '2023-11-13 15:16:58', '2023-04-27 22:50:27'), +(2250, 2062, 3, 'tr_2061 tr_2062 ', '用户列表', 'member_list', '', '', 3, '', '/dept/list,/post/list,/role/list,/member/list,/dept/option', '', '', 1, '', 0, 2, '', 0, 0, 0, 0, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:06:17'), +(2251, 2069, 3, 'tr_2068 tr_2069 ', '查看配置', 'config_get', '', '', 3, '', '/config/get', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:18:44'), +(2252, 2069, 3, 'tr_2068 tr_2069 ', '更新配置', 'config_update', '', '', 3, '', '/config/update', '', '', 1, '', 0, 2, '', 0, 0, 0, 20, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:19:14'), +(2253, 2070, 3, 'tr_2068 tr_2070 ', '查看字典列表', 'dict_data_list', '', '', 3, '', '/dictType/tree,/dictData/list,/config/typeSelect', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:21:47'), +(2254, 2070, 3, 'tr_2068 tr_2070 ', '编辑字典', 'dict_data_edit', '', '', 3, '', '/dictData/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 20, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:22:15'), +(2255, 2070, 3, 'tr_2068 tr_2070 ', '删除字典', 'dict_data_delete', '', '', 3, '', '/dictData/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 30, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:22:15'), +(2256, 2070, 3, 'tr_2068 tr_2070 ', '编辑字典类型', 'dict_type_edit', '', '', 3, '', '/dictType/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 40, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:22:15'), +(2257, 2070, 3, 'tr_2068 tr_2070 ', '删除字典类型', 'dict_type_delete', '', '', 3, '', '/dictType/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 60, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:22:15'), +(2258, 2071, 3, 'tr_2068 tr_2071 ', '任务列表', '/cron/list', '', '', 3, '', '/cron/list', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:25:46'), +(2259, 2071, 3, 'tr_2068 tr_2071 ', '任务分组列表', '/cronGroup/list', '', '', 3, '', '/cronGroup/select,/cronGroup/list', '', '', 1, '', 0, 2, '', 0, 0, 0, 20, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:26:40'), +(2260, 2071, 3, 'tr_2068 tr_2071 ', '编辑任务', '/cron/edit', '', '', 3, '', '/cron/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 30, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:27:07'), +(2261, 2071, 3, 'tr_2068 tr_2071 ', '删除任务', '/cron/delete', '', '', 3, '', '/cron/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 40, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:27:59'), +(2262, 2071, 3, 'tr_2068 tr_2071 ', '修改任务状态', '/cron/status', '', '', 3, '', '/cron/status', '', '', 1, '', 0, 2, '', 0, 0, 0, 60, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:28:16'), +(2263, 2071, 3, 'tr_2068 tr_2071 ', '在线执行', '/cron/onlineExec', '', '', 3, '', '/cron/onlineExec', '', '', 1, '', 0, 2, '', 0, 0, 0, 70, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:28:32'), +(2264, 2071, 3, 'tr_2068 tr_2071 ', '编辑任务分组', '/cronGroup/edit', '', '', 3, '', '/cronGroup/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 80, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:28:55'), +(2265, 2071, 3, 'tr_2068 tr_2071 ', '删除任务分组', '/cronGroup/delete', '', '', 3, '', '/cronGroup/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 90, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:29:14'), +(2266, 2072, 3, 'tr_2068 tr_2072 ', '黑名单列表', '/blacklist/list', '', '', 3, '', '/blacklist/list', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:29:59'), +(2267, 2072, 3, 'tr_2068 tr_2072 ', '编辑黑名单策略', '/blacklist/edit', '', '', 3, '', '/blacklist/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 20, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:30:25'), +(2268, 2072, 3, 'tr_2068 tr_2072 ', '修改策略状态', '/blacklist/status', '', '', 3, '', '/blacklist/status', '', '', 1, '', 0, 2, '', 0, 0, 0, 30, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:31:07'), +(2269, 2072, 3, 'tr_2068 tr_2072 ', '删除策略', '/blacklist/delete', '', '', 3, '', '/blacklist/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 40, '', 1, '2023-11-13 15:16:58', '2023-04-27 23:31:21'), +(2270, 2073, 4, 'tr_2093 tr_2219 tr_2073 ', '修改登录密码', '/member/updatePwd', '', '', 3, '', '/member/updatePwd', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-17 15:27:49', '2023-04-28 16:40:34'), +(2271, 2073, 4, 'tr_2093 tr_2219 tr_2073 ', '换绑手机号', '/member/updateMobile', '', '', 3, '', '/member/updateMobile', '', '', 1, '', 0, 2, '', 0, 0, 0, 20, '', 1, '2023-11-17 15:27:49', '2023-04-28 16:40:52'), +(2272, 2073, 4, 'tr_2093 tr_2219 tr_2073 ', '换绑邮箱', '/member/updateEmail', '', '', 3, '', '/member/updateEmail', '', '', 1, '', 0, 2, '', 0, 0, 0, 30, '', 1, '2023-11-17 15:27:49', '2023-04-28 16:41:11'), +(2273, 2090, 2, 'tr_2090 ', '在线服务', 'monitor_netconn', 'netconn', '', 1, '', '', '', '/monitor/netconn/index', 1, '', 0, 0, '', 0, 0, 0, 20, '', 1, '2023-11-13 15:16:58', '2022-09-18 21:23:36'), +(2275, 2273, 3, 'tr_2090 tr_2273 ', '服务许可证列表', 'serveLicenseIndex', 'serveLicenseIndex', '', 3, '', '/serveLicense/list', '', '/serveLicense/index', 1, 'monitor_netconn', 0, 0, '', 0, 1, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-07-15 09:36:38'), +(2277, 2275, 4, 'tr_2090 tr_2273 tr_2275 ', '编辑/新增服务许可证', 'serveLicenseEdit', '', '', 3, '', '/serveLicense/edit', '', '', 1, '', 0, 0, '', 0, 1, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-07-15 09:36:38'), +(2278, 2275, 4, 'tr_2090 tr_2273 tr_2275 ', '删除服务许可证', 'serveLicenseDelete', '', '', 3, '', '/serveLicense/delete', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-07-15 09:36:38'), +(2279, 2275, 4, 'tr_2090 tr_2273 tr_2275 ', '修改服务许可证状态', 'serveLicenseStatus', '', '', 3, '', '/serveLicense/status', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-07-15 09:36:38'), +(2280, 2275, 4, 'tr_2090 tr_2273 tr_2275 ', '导出服务许可证', 'serveLicenseExport', '', '', 3, '', '/serveLicense/export', '', '', 1, '', 0, 0, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-07-15 09:36:38'), +(2281, 2275, 4, 'tr_2090 tr_2273 tr_2275 ', '分配许可证路由', 'serveLicenseAssignRouter', '', '', 3, '', '/serveLicense/assignRouter', '', '', 1, '', 0, 0, '', 0, 1, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-07-15 09:36:38'), +(2282, 2073, 4, 'tr_2093 tr_2219 tr_2073 ', '更新基本设置', 'memberUpdateProfile', '', '', 3, '', '/member/updateProfile', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-17 15:27:49', '2023-08-02 14:52:48'), +(2283, 2073, 4, 'tr_2093 tr_2219 tr_2073 ', '更新提现设置', 'memberUpdateCash', '', '', 3, '', '/member/updateCash', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-17 15:27:49', '2023-08-02 14:53:34'), +(2292, 2067, 3, 'tr_2065 tr_2067 ', '更新菜单权限', 'updatePermissions', '', '', 3, '', '/role/updatePermissions', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-08-11 14:45:56'), +(2293, 2067, 3, 'tr_2065 tr_2067 ', '更新数据权限', 'dataScopeEdit', '', '', 3, '', '/role/dataScope/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-08-11 14:51:29'), +(2294, 2067, 3, 'tr_2065 tr_2067 ', '添加/编辑角色', 'roleEdit', '', '', 3, '', '/role/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-08-11 14:52:08'), +(2295, 2067, 3, 'tr_2065 tr_2067 ', '删除角色', 'roleDelete', '', '', 3, '', '/role/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-08-11 14:52:34'), +(2296, 2066, 3, 'tr_2065 tr_2066 ', '添加/编辑菜单', 'menuEdit', '', '', 3, '', '/menu/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-08-11 14:53:24'), +(2297, 2066, 3, 'tr_2065 tr_2066 ', '删除菜单', 'menuDelete', '', '', 3, '', '/menu/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-08-11 14:53:52'), +(2298, 2075, 4, 'tr_2093 tr_2074 tr_2075 ', '删除全局日志', 'logDelete', '', '', 3, '', '/log/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-17 15:27:32', '2023-08-11 14:54:37'), +(2299, 2084, 4, 'tr_2093 tr_2074 tr_2084 ', '删除短信记录', 'smsLogDelete', '', '', 3, '', '/smsLog/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-17 15:27:32', '2023-08-11 14:56:47'), +(2300, 2091, 3, 'tr_2090 tr_2091 ', '强制退出用户', 'monitorUserOffline', '', '', 3, '', '/monitor/userOffline', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-08-11 14:57:52'), +(2301, 2096, 3, 'tr_2093 tr_2096 ', '添加/编辑省市区', 'provincesEdit', '', '', 3, '', '/provinces/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-08-11 15:00:13'), +(2302, 2096, 3, 'tr_2093 tr_2096 ', '删除省市区', 'provincesDelete', '', '', 3, '', '/provinces/delete', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-08-11 15:00:45'), +(2305, 2098, 3, 'tr_2097 tr_2098 ', '查看生成配置', 'genCodesView', '', '', 3, '', '/genCodes/view', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-08-11 15:21:28'), +(2306, 2098, 3, 'tr_2097 tr_2098 ', '预览代码', 'genCodesPreview', '', '', 3, '', '/genCodes/preview', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-08-11 15:22:18'), +(2307, 2098, 3, 'tr_2097 tr_2098 ', '提交生成', 'genCodesBuild', '', '', 3, '', '/genCodes/build', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-08-11 15:22:48'), +(2308, 2098, 3, 'tr_2097 tr_2098 ', '保存生成配置', 'genCodesEdit', '', '', 3, '', '/genCodes/edit', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-08-11 15:23:16'), +(2309, 2229, 3, 'tr_2097 tr_2229 ', '更新插件配置', 'addonsUpgrade', '', '', 3, '', '/addons/upgrade', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-08-11 15:24:11'), +(2310, 2229, 3, 'tr_2097 tr_2229 ', '卸载插件', 'addonsUninstall', '', '', 3, '', '/addons/uninstall', '', '', 1, '', 0, 2, '', 0, 0, 0, 10, '', 1, '2023-11-13 15:16:58', '2023-08-11 15:24:32'), +(2319, 2228, 3, 'tr_2227 tr_2228 ', '树表例子', '/addons/hgexample/table/tree', '/addons/hgexample/table/tree', '', 2, '', '/hgexample/table/tree', '', '/addons/hgexample/treeTable/index', 1, '', 0, 2, '', 0, 0, 0, 15, '', 1, '2023-11-13 17:17:15', '2023-11-13 16:46:58'); -- -------------------------------------------------------- @@ -461,22 +463,22 @@ INSERT INTO `hg_admin_menu` (`id`, `pid`, `title`, `name`, `path`, `icon`, `type -- 表的结构 `hg_admin_notice` -- -CREATE TABLE `hg_admin_notice` ( - `id` bigint(20) NOT NULL COMMENT '公告ID', +CREATE TABLE IF NOT EXISTS `hg_admin_notice` ( + `id` bigint NOT NULL COMMENT '公告ID', `title` varchar(64) NOT NULL COMMENT '公告标题', - `type` bigint(20) NOT NULL COMMENT '公告类型', - `tag` int(11) DEFAULT NULL COMMENT '标签', + `type` bigint NOT NULL COMMENT '公告类型', + `tag` int DEFAULT NULL COMMENT '标签', `content` longtext NOT NULL COMMENT '公告内容', `receiver` json DEFAULT NULL COMMENT '接收者', `remark` varchar(255) DEFAULT NULL COMMENT '备注', - `sort` int(11) NOT NULL DEFAULT '0' COMMENT '排序', + `sort` int NOT NULL DEFAULT '0' COMMENT '排序', `status` tinyint(1) DEFAULT '1' COMMENT '公告状态', - `created_by` bigint(20) DEFAULT NULL COMMENT '发送人', - `updated_by` bigint(20) DEFAULT '0' COMMENT '修改人', + `created_by` bigint DEFAULT NULL COMMENT '发送人', + `updated_by` bigint DEFAULT '0' COMMENT '修改人', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间', `deleted_at` datetime DEFAULT NULL COMMENT '删除时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='管理员_通知公告'; +) ENGINE=InnoDB AUTO_INCREMENT=35 DEFAULT CHARSET=utf8mb3 COMMENT='管理员_通知公告'; -- -- 转存表中的数据 `hg_admin_notice` @@ -485,7 +487,7 @@ CREATE TABLE `hg_admin_notice` ( INSERT INTO `hg_admin_notice` (`id`, `title`, `type`, `tag`, `content`, `receiver`, `remark`, `sort`, `status`, `created_by`, `updated_by`, `created_at`, `updated_at`, `deleted_at`) VALUES (29, '2023年春季学期开学工作通知!', 1, 1, '1.学生:2月11日、2月12日报到,2月13日起安排考试。\n\n2.教职工:2月10日(周五)起正式上班(2月11日、2月12日正常上班)。\n\n3.校内进行的各类社会服务项目,主办部门、单位须关注参与人员的健康状况,如有异常第一时间报告。感染后仍在康复期内的师生,不参加剧烈活动。开学后两周内,原则上不组织各类竞技性较强的体育比赛等活动。\n\n4.全校师生员工要牢固树立健康第一的观念,切实增强个人责任感和防护意识,掌握防护技能,坚持戴口罩、勤洗手等良好卫生习惯,加强身体锻炼,保持健康生活方式,提升健康素养和自我防护能力,当好自身健康第一责任人。符合条件的师生,积极有序接种第二剂次加强针疫苗。', 'null', '', 10, 1, 1, 1, '2023-02-09 12:25:39', '2023-02-09 12:48:08', NULL), (30, '国务院办公厅关于2023年部分节假日安排的通知', 1, 3, '新华社北京12月8日电 国务院办公厅关于2023年部分节假日安排的通知,全文如下:\n\n  各省、自治区、直辖市人民政府,国务院\n\n  各部委、各直属机构:\n\n  经国务院批准,现将2023年元旦、春节、清明节、劳动节、端午节、中秋节和国庆节放假调休日期的具体安排通知如下。\n\n  一、元旦:2022年12月31日至2023年1月2日放假调休,共3天。\n\n  二、春节:1月21日至27日放假调休,共7天。1月28日(星期六)、1月29日(星期日)上班。\n\n  三、清明节:4月5日放假,共1天。\n\n  四、劳动节:4月29日至5月3日放假调休,共5天。4月23日(星期日)、5月6日(星期六)上班。\n\n  五、端午节:6月22日至24日放假调休,共3天。6月25日(星期日)上班。\n\n  六、中秋节、国庆节:9月29日至10月6日放假调休,共8天。10月7日(星期六)、10月8日(星期日)上班。\n\n  节假日期间,各地区、各部门要妥善安排好值班和安全、保卫、疫情防控等工作,遇有重大突发事件,要按规定及时报告并妥善处置,确保人民群众祥和平安度过节日假期。', 'null', '', 20, 1, 1, 1, '2023-02-09 12:32:32', '2023-02-09 12:48:28', NULL), -(31, 'hotgo新版本发布啦!', 2, 4, '


本次更新内容如下:

1. 优化角色权限

2. 优化代码生成

3. ....

', 'null', '', 30, 1, 1, 0, '2023-02-09 12:45:17', '2023-02-09 12:45:17', '2023-06-09 18:04:30'), +(31, 'hotgo新版本发布啦!', 2, 4, '


本次更新内容如下:

1. 优化角色权限

2. 优化代码生成

3. ....

', 'null', '', 30, 1, 1, 0, '2023-02-09 12:45:17', '2023-02-09 12:45:17', '2023-06-09 18:04:30'), (32, '新的好友', 3, 5, '

哈喽,你好呀!

', '[1, 3, 8]', '', 40, 1, 1, 3, '2023-02-09 12:45:54', '2023-08-11 15:19:04', NULL), (33, '1', 2, 0, '', 'null', '', 50, 1, 3, 0, '2023-04-28 16:45:11', '2023-04-28 16:45:11', '2023-04-28 16:45:14'), (34, '1', 1, 0, '1', 'null', '', 50, 1, 3, 0, '2023-04-28 16:45:22', '2023-04-28 16:45:22', '2023-04-28 16:45:26'); @@ -496,14 +498,14 @@ INSERT INTO `hg_admin_notice` (`id`, `title`, `type`, `tag`, `content`, `receive -- 表的结构 `hg_admin_notice_read` -- -CREATE TABLE `hg_admin_notice_read` ( - `id` bigint(20) NOT NULL COMMENT '记录ID', - `notice_id` bigint(20) NOT NULL COMMENT '公告ID', - `member_id` bigint(20) NOT NULL COMMENT '会员ID', - `clicks` int(11) DEFAULT '1' COMMENT '已读次数', +CREATE TABLE IF NOT EXISTS `hg_admin_notice_read` ( + `id` bigint NOT NULL COMMENT '记录ID', + `notice_id` bigint NOT NULL COMMENT '公告ID', + `member_id` bigint NOT NULL COMMENT '会员ID', + `clicks` int DEFAULT '1' COMMENT '已读次数', `updated_at` datetime DEFAULT NULL COMMENT '更新时间', `created_at` datetime DEFAULT NULL COMMENT '阅读时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='管理员_公告已读记录'; +) ENGINE=InnoDB AUTO_INCREMENT=9 DEFAULT CHARSET=utf8mb3 COMMENT='管理员_公告已读记录'; -- -- 转存表中的数据 `hg_admin_notice_read` @@ -511,7 +513,7 @@ CREATE TABLE `hg_admin_notice_read` ( INSERT INTO `hg_admin_notice_read` (`id`, `notice_id`, `member_id`, `clicks`, `updated_at`, `created_at`) VALUES (1, 31, 1, 2, '2023-04-26 22:44:51', '2023-04-25 22:59:16'), -(2, 30, 1, 20, '2023-08-11 16:07:34', '2023-04-25 23:01:27'), +(2, 30, 1, 22, '2023-11-17 15:30:02', '2023-04-25 23:01:27'), (3, 32, 3, 0, '2023-04-28 16:48:41', '2023-04-28 16:48:41'), (4, 29, 3, 4, '2023-08-11 14:42:22', '2023-04-28 16:48:47'), (5, 30, 3, 3, '2023-08-11 15:24:45', '2023-04-28 16:48:47'), @@ -525,9 +527,9 @@ INSERT INTO `hg_admin_notice_read` (`id`, `notice_id`, `member_id`, `clicks`, `u -- 表的结构 `hg_admin_oauth` -- -CREATE TABLE `hg_admin_oauth` ( - `id` bigint(20) NOT NULL COMMENT '主键', - `member_id` bigint(20) DEFAULT '0' COMMENT '用户ID', +CREATE TABLE IF NOT EXISTS `hg_admin_oauth` ( + `id` bigint NOT NULL COMMENT '主键', + `member_id` bigint DEFAULT '0' COMMENT '用户ID', `unionid` varchar(64) DEFAULT '' COMMENT '唯一ID', `oauth_client` varchar(32) DEFAULT NULL COMMENT '授权组别', `oauth_openid` varchar(128) DEFAULT NULL COMMENT '授权开放ID', @@ -541,7 +543,7 @@ CREATE TABLE `hg_admin_oauth` ( `status` tinyint(1) DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime(1) DEFAULT NULL COMMENT '修改时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='管理员_第三方登录'; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COMMENT='管理员_第三方登录'; -- -------------------------------------------------------- @@ -549,20 +551,20 @@ CREATE TABLE `hg_admin_oauth` ( -- 表的结构 `hg_admin_order` -- -CREATE TABLE `hg_admin_order` ( - `id` bigint(20) NOT NULL COMMENT '主键', - `member_id` bigint(20) DEFAULT '0' COMMENT '管理员id', +CREATE TABLE IF NOT EXISTS `hg_admin_order` ( + `id` bigint NOT NULL COMMENT '主键', + `member_id` bigint DEFAULT '0' COMMENT '管理员id', `order_type` varchar(32) NOT NULL COMMENT '订单类型', - `product_id` bigint(20) DEFAULT NULL COMMENT '产品id', + `product_id` bigint DEFAULT NULL COMMENT '产品id', `order_sn` varchar(64) DEFAULT '' COMMENT '关联订单号', `money` decimal(10,2) NOT NULL COMMENT '充值金额', `remark` varchar(255) DEFAULT NULL COMMENT '备注', `refund_reason` varchar(255) DEFAULT NULL COMMENT '退款原因', `reject_refund_reason` varchar(255) DEFAULT NULL COMMENT '拒绝退款原因', - `status` tinyint(4) DEFAULT '1' COMMENT '状态', + `status` tinyint DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '修改时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='管理员_充值订单'; +) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb3 COMMENT='管理员_充值订单'; -- -------------------------------------------------------- @@ -570,16 +572,16 @@ CREATE TABLE `hg_admin_order` ( -- 表的结构 `hg_admin_post` -- -CREATE TABLE `hg_admin_post` ( - `id` bigint(20) NOT NULL COMMENT '岗位ID', +CREATE TABLE IF NOT EXISTS `hg_admin_post` ( + `id` bigint NOT NULL COMMENT '岗位ID', `code` varchar(64) NOT NULL COMMENT '岗位编码', `name` varchar(50) NOT NULL COMMENT '岗位名称', `remark` varchar(500) DEFAULT NULL COMMENT '备注', - `sort` int(11) NOT NULL COMMENT '排序', + `sort` int NOT NULL COMMENT '排序', `status` tinyint(1) NOT NULL COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='管理员_岗位'; +) ENGINE=InnoDB AUTO_INCREMENT=7 DEFAULT CHARSET=utf8mb3 COMMENT='管理员_岗位'; -- -- 转存表中的数据 `hg_admin_post` @@ -598,21 +600,21 @@ INSERT INTO `hg_admin_post` (`id`, `code`, `name`, `remark`, `sort`, `status`, ` -- 表的结构 `hg_admin_role` -- -CREATE TABLE `hg_admin_role` ( - `id` bigint(20) NOT NULL COMMENT '角色ID', +CREATE TABLE IF NOT EXISTS `hg_admin_role` ( + `id` bigint NOT NULL COMMENT '角色ID', `name` varchar(32) NOT NULL COMMENT '角色名称', `key` varchar(128) NOT NULL COMMENT '角色权限字符串', `data_scope` tinyint(1) DEFAULT '1' COMMENT '数据范围', `custom_dept` json DEFAULT NULL COMMENT '自定义部门权限', - `pid` bigint(20) DEFAULT '0' COMMENT '上级角色ID', - `level` int(11) NOT NULL DEFAULT '1' COMMENT '关系树等级', + `pid` bigint DEFAULT '0' COMMENT '上级角色ID', + `level` int NOT NULL DEFAULT '1' COMMENT '关系树等级', `tree` varchar(512) DEFAULT NULL COMMENT '关系树', `remark` varchar(255) DEFAULT NULL COMMENT '备注', - `sort` int(11) NOT NULL DEFAULT '0' COMMENT '排序', + `sort` int NOT NULL DEFAULT '0' COMMENT '排序', `status` tinyint(1) NOT NULL DEFAULT '1' COMMENT '角色状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='管理员_角色信息'; +) ENGINE=InnoDB AUTO_INCREMENT=209 DEFAULT CHARSET=utf8mb3 COMMENT='管理员_角色信息'; -- -- 转存表中的数据 `hg_admin_role` @@ -634,8 +636,8 @@ INSERT INTO `hg_admin_role` (`id`, `name`, `key`, `data_scope`, `custom_dept`, ` -- 表的结构 `hg_admin_role_casbin` -- -CREATE TABLE `hg_admin_role_casbin` ( - `id` bigint(20) NOT NULL, +CREATE TABLE IF NOT EXISTS `hg_admin_role_casbin` ( + `id` bigint NOT NULL, `p_type` varchar(64) DEFAULT NULL, `v0` varchar(256) DEFAULT NULL, `v1` varchar(256) DEFAULT NULL, @@ -643,314 +645,314 @@ CREATE TABLE `hg_admin_role_casbin` ( `v3` varchar(256) DEFAULT NULL, `v4` varchar(256) DEFAULT NULL, `v5` varchar(256) DEFAULT NULL -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='管理员_casbin权限表' ROW_FORMAT=DYNAMIC; +) ENGINE=InnoDB AUTO_INCREMENT=96522 DEFAULT CHARSET=utf8mb3 ROW_FORMAT=DYNAMIC COMMENT='管理员_casbin权限表'; -- -- 转存表中的数据 `hg_admin_role_casbin` -- INSERT INTO `hg_admin_role_casbin` (`id`, `p_type`, `v0`, `v1`, `v2`, `v3`, `v4`, `v5`) VALUES -(79967, 'p', 'manage', 'dashboard', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79968, 'p', 'manage', '/console/stat', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79969, 'p', 'manage', 'dashboard_workplace', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79970, 'p', 'manage', '/dept/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79971, 'p', 'manage', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79972, 'p', 'manage', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79973, 'p', 'manage', '/member/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79974, 'p', 'manage', '/dept/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79975, 'p', 'manage', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79976, 'p', 'manage', '/menu/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79977, 'p', 'manage', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79978, 'p', 'manage', '/role/dataScope/select', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79979, 'p', 'manage', '/role/getPermissions', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79980, 'p', 'manage', '/log/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79981, 'p', 'manage', '/log/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79982, 'p', 'manage', '/loginLog/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79983, 'p', 'manage', '/loginLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79984, 'p', 'manage', '/smsLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79985, 'p', 'manage', '/serveLog/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79986, 'p', 'manage', '/serveLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79987, 'p', 'manage', '/monitor/userOnlineList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79988, 'p', 'manage', '/notice/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79989, 'p', 'manage', '/attachment/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79990, 'p', 'manage', '/provinces/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79991, 'p', 'manage', '/provinces/tree', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79992, 'p', 'manage', '/provinces/childrenList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79993, 'p', 'manage', '/provinces/uniqueId', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79994, 'p', 'manage', '/genCodes/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79995, 'p', 'manage', '/genCodes/selects', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79996, 'p', 'manage', '/genCodes/tableSelect', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79997, 'p', 'manage', '/member/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79998, 'p', 'manage', '/member/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(79999, 'p', 'manage', '/member/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80000, 'p', 'manage', '/member/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80001, 'p', 'manage', '/dept/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80002, 'p', 'manage', '/dept/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80003, 'p', 'manage', '/dept/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80004, 'p', 'manage', '/post/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80005, 'p', 'manage', '/post/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80006, 'p', 'manage', '/post/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80007, 'p', 'manage', '/upload/file', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80008, 'p', 'manage', '/hgexample/table/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80009, 'p', 'manage', '/hgexample/table/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80010, 'p', 'manage', '/curdDemo/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80011, 'p', 'manage', '/curdDemo/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80012, 'p', 'manage', '/curdDemo/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80013, 'p', 'manage', '/curdDemo/maxSort', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80014, 'p', 'manage', '/curdDemo/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80015, 'p', 'manage', '/curdDemo/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80016, 'p', 'manage', '/curdDemo/switch', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80017, 'p', 'manage', '/curdDemo/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80018, 'p', 'manage', '/loginLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80019, 'p', 'manage', '/loginLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80020, 'p', 'manage', '/serveLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80021, 'p', 'manage', '/serveLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80022, 'p', 'manage', '/notice/maxSort', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80023, 'p', 'manage', '/notice/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80024, 'p', 'manage', '/notice/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80025, 'p', 'manage', '/notice/switch', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80026, 'p', 'manage', '/notice/editNotify', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80027, 'p', 'manage', '/notice/editNotice', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80028, 'p', 'manage', '/notice/editLetter', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80029, 'p', 'manage', '/notice/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80030, 'p', 'manage', '/notice/messageList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80031, 'p', 'manage', '/test/maxSort', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80032, 'p', 'manage', '/test/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80033, 'p', 'manage', '/test/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80034, 'p', 'manage', '/test/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80035, 'p', 'manage', '/test/switch', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80036, 'p', 'manage', '/test/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80037, 'p', 'manage', '/addons/selects', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80038, 'p', 'manage', '/addons/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80039, 'p', 'manage', '/order/create', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80040, 'p', 'manage', '/order/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80041, 'p', 'manage', '/creditsLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80042, 'p', 'manage', '/creditsLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80043, 'p', 'manage', '/creditsLog/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80044, 'p', 'manage', '/order/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80045, 'p', 'manage', '/order/acceptRefund', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80046, 'p', 'manage', '/order/applyRefund', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80047, 'p', 'manage', '/order/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80048, 'p', 'manage', '/cash/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80049, 'p', 'manage', '/cash/apply', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80050, 'p', 'manage', '/config/getCash', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80051, 'p', 'manage', '/cash/apply', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80052, 'p', 'manage', '/cash/payment', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80053, 'p', 'manage', '/cash/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80054, 'p', 'manage', '/member/addBalance', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80055, 'p', 'manage', '/member/addIntegral', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80056, 'p', 'manage', '/member/resetPwd', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80057, 'p', 'manage', '/dept/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80058, 'p', 'manage', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80059, 'p', 'manage', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80060, 'p', 'manage', '/member/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80061, 'p', 'manage', '/dept/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80062, 'p', 'manage', '/config/get', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80063, 'p', 'manage', '/config/update', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80064, 'p', 'manage', '/dictType/tree', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80065, 'p', 'manage', '/dictData/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80066, 'p', 'manage', '/config/typeSelect', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80067, 'p', 'manage', '/dictData/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80068, 'p', 'manage', '/dictData/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80069, 'p', 'manage', '/dictType/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80070, 'p', 'manage', '/dictType/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80071, 'p', 'manage', '/cron/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80072, 'p', 'manage', '/cronGroup/select', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80073, 'p', 'manage', '/cronGroup/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80074, 'p', 'manage', '/cron/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80075, 'p', 'manage', '/cron/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80076, 'p', 'manage', '/cron/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80077, 'p', 'manage', '/cron/onlineExec', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80078, 'p', 'manage', '/cronGroup/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80079, 'p', 'manage', '/cronGroup/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80080, 'p', 'manage', '/blacklist/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80081, 'p', 'manage', '/blacklist/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80082, 'p', 'manage', '/blacklist/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80083, 'p', 'manage', '/blacklist/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80084, 'p', 'manage', '/member/updatePwd', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80085, 'p', 'manage', '/member/updateMobile', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80086, 'p', 'manage', '/member/updateEmail', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80087, 'p', 'manage', '/serveLicense/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80088, 'p', 'manage', '/serveLicense/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80089, 'p', 'manage', '/serveLicense/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80090, 'p', 'manage', '/serveLicense/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80091, 'p', 'manage', '/serveLicense/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80092, 'p', 'manage', '/serveLicense/assignRouter', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80093, 'p', 'manage', '/member/updateProfile', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80094, 'p', 'manage', '/member/updateCash', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80095, 'p', 'manage', '/role/updatePermissions', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80096, 'p', 'manage', '/role/dataScope/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80097, 'p', 'manage', '/role/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80098, 'p', 'manage', '/role/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80099, 'p', 'manage', '/menu/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80100, 'p', 'manage', '/menu/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80101, 'p', 'manage', '/log/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80102, 'p', 'manage', '/smsLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80103, 'p', 'manage', '/monitor/userOffline', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80104, 'p', 'manage', '/provinces/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80105, 'p', 'manage', '/provinces/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80106, 'p', 'manage', '/genCodes/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80107, 'p', 'manage', '/genCodes/preview', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80108, 'p', 'manage', '/genCodes/build', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80109, 'p', 'manage', '/genCodes/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80110, 'p', 'manage', '/addons/upgrade', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80111, 'p', 'manage', '/addons/uninstall', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80112, 'p', 'gold_agent', 'dashboard', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80113, 'p', 'gold_agent', '/console/stat', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80114, 'p', 'gold_agent', 'dashboard_workplace', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80115, 'p', 'gold_agent', '/dept/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80116, 'p', 'gold_agent', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80117, 'p', 'gold_agent', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80118, 'p', 'gold_agent', '/member/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80119, 'p', 'gold_agent', '/dept/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80120, 'p', 'gold_agent', '/log/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80121, 'p', 'gold_agent', '/log/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80122, 'p', 'gold_agent', '/loginLog/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80123, 'p', 'gold_agent', '/loginLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80124, 'p', 'gold_agent', '/member/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80125, 'p', 'gold_agent', '/member/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80126, 'p', 'gold_agent', '/member/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80127, 'p', 'gold_agent', '/member/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80128, 'p', 'gold_agent', '/loginLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80129, 'p', 'gold_agent', '/loginLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80130, 'p', 'gold_agent', '/notice/messageList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80131, 'p', 'gold_agent', '/order/create', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80132, 'p', 'gold_agent', '/order/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80133, 'p', 'gold_agent', '/creditsLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80134, 'p', 'gold_agent', '/creditsLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80135, 'p', 'gold_agent', '/creditsLog/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80136, 'p', 'gold_agent', '/order/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80137, 'p', 'gold_agent', '/order/acceptRefund', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80138, 'p', 'gold_agent', '/order/applyRefund', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80139, 'p', 'gold_agent', '/order/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80140, 'p', 'gold_agent', '/cash/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80141, 'p', 'gold_agent', '/cash/apply', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80142, 'p', 'gold_agent', '/config/getCash', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80143, 'p', 'gold_agent', '/cash/apply', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80144, 'p', 'gold_agent', '/cash/payment', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80145, 'p', 'gold_agent', '/cash/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80146, 'p', 'gold_agent', '/member/addBalance', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80147, 'p', 'gold_agent', '/member/addIntegral', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80148, 'p', 'gold_agent', '/member/resetPwd', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80149, 'p', 'gold_agent', '/dept/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80150, 'p', 'gold_agent', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80151, 'p', 'gold_agent', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80152, 'p', 'gold_agent', '/member/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80153, 'p', 'gold_agent', '/dept/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80154, 'p', 'gold_agent', '/member/updatePwd', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80155, 'p', 'gold_agent', '/member/updateMobile', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80156, 'p', 'gold_agent', '/member/updateEmail', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80157, 'p', 'silver_agent', 'dashboard', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80158, 'p', 'silver_agent', '/console/stat', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80159, 'p', 'silver_agent', 'dashboard_workplace', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80160, 'p', 'silver_agent', '/dept/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80161, 'p', 'silver_agent', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80162, 'p', 'silver_agent', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80163, 'p', 'silver_agent', '/member/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80164, 'p', 'silver_agent', '/dept/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80165, 'p', 'silver_agent', '/log/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80166, 'p', 'silver_agent', '/log/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80167, 'p', 'silver_agent', '/loginLog/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80168, 'p', 'silver_agent', '/loginLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80169, 'p', 'silver_agent', '/member/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80170, 'p', 'silver_agent', '/member/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80171, 'p', 'silver_agent', '/member/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80172, 'p', 'silver_agent', '/member/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80173, 'p', 'silver_agent', '/loginLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80174, 'p', 'silver_agent', '/loginLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80175, 'p', 'silver_agent', '/notice/messageList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80176, 'p', 'silver_agent', '/member/addBalance', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80177, 'p', 'silver_agent', '/member/addIntegral', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80178, 'p', 'silver_agent', '/member/resetPwd', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80179, 'p', 'silver_agent', '/dept/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80180, 'p', 'silver_agent', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80181, 'p', 'silver_agent', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80182, 'p', 'silver_agent', '/member/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80183, 'p', 'silver_agent', '/dept/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80184, 'p', 'silver_agent', '/member/updatePwd', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80185, 'p', 'silver_agent', '/member/updateMobile', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80186, 'p', 'silver_agent', '/member/updateEmail', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80187, 'p', 'silver_agent', '/member/updateProfile', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80188, 'p', 'silver_agent', '/member/updateCash', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80189, 'p', 'copper_agent', 'dashboard', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80190, 'p', 'copper_agent', '/console/stat', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80191, 'p', 'copper_agent', 'dashboard_workplace', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80192, 'p', 'copper_agent', '/log/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80193, 'p', 'copper_agent', '/log/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80194, 'p', 'copper_agent', '/loginLog/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80195, 'p', 'copper_agent', '/loginLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80196, 'p', 'copper_agent', '/loginLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80197, 'p', 'copper_agent', '/loginLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80198, 'p', 'copper_agent', '/notice/messageList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80199, 'p', 'copper_agent', '/member/updatePwd', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80200, 'p', 'copper_agent', '/member/updateMobile', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80201, 'p', 'copper_agent', '/member/updateEmail', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80202, 'p', 'copper_agent', '/member/updateProfile', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80203, 'p', 'copper_agent', '/member/updateCash', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80204, 'p', 'finance', 'dashboard', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80205, 'p', 'finance', '/console/stat', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80206, 'p', 'finance', 'dashboard_workplace', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80207, 'p', 'finance', '/dept/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80208, 'p', 'finance', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80209, 'p', 'finance', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80210, 'p', 'finance', '/member/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80211, 'p', 'finance', '/dept/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80212, 'p', 'finance', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80213, 'p', 'finance', '/menu/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80214, 'p', 'finance', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80215, 'p', 'finance', '/role/dataScope/select', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80216, 'p', 'finance', '/role/getPermissions', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80217, 'p', 'finance', '/log/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80218, 'p', 'finance', '/log/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80219, 'p', 'finance', '/loginLog/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80220, 'p', 'finance', '/loginLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80221, 'p', 'finance', '/smsLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80222, 'p', 'finance', '/serveLog/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80223, 'p', 'finance', '/serveLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80224, 'p', 'finance', '/monitor/userOnlineList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80225, 'p', 'finance', '/notice/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80226, 'p', 'finance', '/attachment/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80227, 'p', 'finance', '/provinces/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80228, 'p', 'finance', '/provinces/tree', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80229, 'p', 'finance', '/provinces/childrenList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80230, 'p', 'finance', '/provinces/uniqueId', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80231, 'p', 'finance', '/member/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80232, 'p', 'finance', '/member/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80233, 'p', 'finance', '/member/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80234, 'p', 'finance', '/member/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80235, 'p', 'finance', '/dept/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80236, 'p', 'finance', '/dept/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80237, 'p', 'finance', '/dept/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80238, 'p', 'finance', '/post/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80239, 'p', 'finance', '/post/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80240, 'p', 'finance', '/post/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80241, 'p', 'finance', '/upload/file', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80242, 'p', 'finance', '/hgexample/table/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80243, 'p', 'finance', '/hgexample/table/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80244, 'p', 'finance', '/loginLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80245, 'p', 'finance', '/loginLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80246, 'p', 'finance', '/serveLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80247, 'p', 'finance', '/serveLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80248, 'p', 'finance', '/notice/maxSort', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80249, 'p', 'finance', '/notice/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80250, 'p', 'finance', '/notice/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80251, 'p', 'finance', '/notice/switch', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80252, 'p', 'finance', '/notice/editNotify', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80253, 'p', 'finance', '/notice/editNotice', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80254, 'p', 'finance', '/notice/editLetter', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80255, 'p', 'finance', '/notice/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80256, 'p', 'finance', '/test/maxSort', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80257, 'p', 'finance', '/test/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80258, 'p', 'finance', '/test/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80259, 'p', 'finance', '/test/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80260, 'p', 'finance', '/test/switch', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80261, 'p', 'finance', '/test/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80262, 'p', 'business', 'dashboard', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80263, 'p', 'business', '/console/stat', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80264, 'p', 'business', 'dashboard_workplace', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80265, 'p', 'science', 'dashboard', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80266, 'p', 'science', '/console/stat', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), -(80267, 'p', 'science', 'dashboard_workplace', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''); +(96221, 'p', 'manage', 'dashboard', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96222, 'p', 'manage', '/console/stat', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96223, 'p', 'manage', 'dashboard_workplace', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96224, 'p', 'manage', '/dept/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96225, 'p', 'manage', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96226, 'p', 'manage', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96227, 'p', 'manage', '/member/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96228, 'p', 'manage', '/dept/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96229, 'p', 'manage', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96230, 'p', 'manage', '/menu/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96231, 'p', 'manage', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96232, 'p', 'manage', '/role/dataScope/select', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96233, 'p', 'manage', '/role/getPermissions', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96234, 'p', 'manage', '/log/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96235, 'p', 'manage', '/log/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96236, 'p', 'manage', '/loginLog/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96237, 'p', 'manage', '/loginLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96238, 'p', 'manage', '/smsLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96239, 'p', 'manage', '/serveLog/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96240, 'p', 'manage', '/serveLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96241, 'p', 'manage', '/monitor/userOnlineList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96242, 'p', 'manage', '/notice/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96243, 'p', 'manage', '/attachment/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96244, 'p', 'manage', '/provinces/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96245, 'p', 'manage', '/provinces/tree', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96246, 'p', 'manage', '/provinces/childrenList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96247, 'p', 'manage', '/provinces/uniqueId', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96248, 'p', 'manage', '/genCodes/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96249, 'p', 'manage', '/genCodes/selects', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96250, 'p', 'manage', '/genCodes/tableSelect', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96251, 'p', 'manage', '/member/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96252, 'p', 'manage', '/member/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96253, 'p', 'manage', '/member/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96254, 'p', 'manage', '/member/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96255, 'p', 'manage', '/dept/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96256, 'p', 'manage', '/dept/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96257, 'p', 'manage', '/dept/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96258, 'p', 'manage', '/post/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96259, 'p', 'manage', '/post/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96260, 'p', 'manage', '/post/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96261, 'p', 'manage', '/upload/file', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96262, 'p', 'manage', '/hgexample/table/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96263, 'p', 'manage', '/hgexample/table/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96264, 'p', 'manage', '/curdDemo/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96265, 'p', 'manage', '/curdDemo/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96266, 'p', 'manage', '/curdDemo/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96267, 'p', 'manage', '/curdDemo/maxSort', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96268, 'p', 'manage', '/curdDemo/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96269, 'p', 'manage', '/curdDemo/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96270, 'p', 'manage', '/curdDemo/switch', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96271, 'p', 'manage', '/curdDemo/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96272, 'p', 'manage', '/loginLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96273, 'p', 'manage', '/loginLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96274, 'p', 'manage', '/serveLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96275, 'p', 'manage', '/serveLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96276, 'p', 'manage', '/notice/maxSort', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96277, 'p', 'manage', '/notice/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96278, 'p', 'manage', '/notice/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96279, 'p', 'manage', '/notice/switch', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96280, 'p', 'manage', '/notice/editNotify', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96281, 'p', 'manage', '/notice/editNotice', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96282, 'p', 'manage', '/notice/editLetter', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96283, 'p', 'manage', '/notice/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96284, 'p', 'manage', '/notice/messageList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96285, 'p', 'manage', '/test/maxSort', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96286, 'p', 'manage', '/test/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96287, 'p', 'manage', '/test/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96288, 'p', 'manage', '/test/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96289, 'p', 'manage', '/test/switch', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96290, 'p', 'manage', '/test/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96291, 'p', 'manage', '/addons/selects', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96292, 'p', 'manage', '/addons/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96293, 'p', 'manage', '/order/create', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96294, 'p', 'manage', '/order/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96295, 'p', 'manage', '/creditsLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96296, 'p', 'manage', '/creditsLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96297, 'p', 'manage', '/creditsLog/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96298, 'p', 'manage', '/order/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96299, 'p', 'manage', '/order/acceptRefund', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96300, 'p', 'manage', '/order/applyRefund', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96301, 'p', 'manage', '/order/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96302, 'p', 'manage', '/cash/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96303, 'p', 'manage', '/cash/apply', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96304, 'p', 'manage', '/config/getCash', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96305, 'p', 'manage', '/cash/apply', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96306, 'p', 'manage', '/cash/payment', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96307, 'p', 'manage', '/cash/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96308, 'p', 'manage', '/member/addBalance', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96309, 'p', 'manage', '/member/addIntegral', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96310, 'p', 'manage', '/member/resetPwd', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96311, 'p', 'manage', '/dept/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96312, 'p', 'manage', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96313, 'p', 'manage', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96314, 'p', 'manage', '/member/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96315, 'p', 'manage', '/dept/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96316, 'p', 'manage', '/config/get', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96317, 'p', 'manage', '/config/update', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96318, 'p', 'manage', '/dictType/tree', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96319, 'p', 'manage', '/dictData/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96320, 'p', 'manage', '/config/typeSelect', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96321, 'p', 'manage', '/dictData/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96322, 'p', 'manage', '/dictData/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96323, 'p', 'manage', '/dictType/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96324, 'p', 'manage', '/dictType/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96325, 'p', 'manage', '/cron/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96326, 'p', 'manage', '/cronGroup/select', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96327, 'p', 'manage', '/cronGroup/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96328, 'p', 'manage', '/cron/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96329, 'p', 'manage', '/cron/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96330, 'p', 'manage', '/cron/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96331, 'p', 'manage', '/cron/onlineExec', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96332, 'p', 'manage', '/cronGroup/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96333, 'p', 'manage', '/cronGroup/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96334, 'p', 'manage', '/blacklist/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96335, 'p', 'manage', '/blacklist/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96336, 'p', 'manage', '/blacklist/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96337, 'p', 'manage', '/blacklist/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96338, 'p', 'manage', '/member/updatePwd', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96339, 'p', 'manage', '/member/updateMobile', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96340, 'p', 'manage', '/member/updateEmail', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96341, 'p', 'manage', '/serveLicense/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96342, 'p', 'manage', '/serveLicense/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96343, 'p', 'manage', '/serveLicense/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96344, 'p', 'manage', '/serveLicense/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96345, 'p', 'manage', '/serveLicense/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96346, 'p', 'manage', '/serveLicense/assignRouter', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96347, 'p', 'manage', '/member/updateProfile', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96348, 'p', 'manage', '/member/updateCash', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96349, 'p', 'manage', '/role/updatePermissions', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96350, 'p', 'manage', '/role/dataScope/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96351, 'p', 'manage', '/role/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96352, 'p', 'manage', '/role/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96353, 'p', 'manage', '/menu/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96354, 'p', 'manage', '/menu/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96355, 'p', 'manage', '/log/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96356, 'p', 'manage', '/smsLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96357, 'p', 'manage', '/monitor/userOffline', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96358, 'p', 'manage', '/provinces/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96359, 'p', 'manage', '/provinces/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96360, 'p', 'manage', '/genCodes/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96361, 'p', 'manage', '/genCodes/preview', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96362, 'p', 'manage', '/genCodes/build', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96363, 'p', 'manage', '/genCodes/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96364, 'p', 'manage', '/addons/upgrade', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96365, 'p', 'manage', '/addons/uninstall', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96366, 'p', 'gold_agent', 'dashboard', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96367, 'p', 'gold_agent', '/console/stat', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96368, 'p', 'gold_agent', 'dashboard_workplace', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96369, 'p', 'gold_agent', '/dept/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96370, 'p', 'gold_agent', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96371, 'p', 'gold_agent', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96372, 'p', 'gold_agent', '/member/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96373, 'p', 'gold_agent', '/dept/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96374, 'p', 'gold_agent', '/log/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96375, 'p', 'gold_agent', '/log/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96376, 'p', 'gold_agent', '/loginLog/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96377, 'p', 'gold_agent', '/loginLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96378, 'p', 'gold_agent', '/member/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96379, 'p', 'gold_agent', '/member/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96380, 'p', 'gold_agent', '/member/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96381, 'p', 'gold_agent', '/member/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96382, 'p', 'gold_agent', '/loginLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96383, 'p', 'gold_agent', '/loginLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96384, 'p', 'gold_agent', '/notice/messageList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96385, 'p', 'gold_agent', '/order/create', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96386, 'p', 'gold_agent', '/order/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96387, 'p', 'gold_agent', '/creditsLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96388, 'p', 'gold_agent', '/creditsLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96389, 'p', 'gold_agent', '/creditsLog/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96390, 'p', 'gold_agent', '/order/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96391, 'p', 'gold_agent', '/order/acceptRefund', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96392, 'p', 'gold_agent', '/order/applyRefund', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96393, 'p', 'gold_agent', '/order/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96394, 'p', 'gold_agent', '/cash/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96395, 'p', 'gold_agent', '/cash/apply', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96396, 'p', 'gold_agent', '/config/getCash', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96397, 'p', 'gold_agent', '/cash/apply', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96398, 'p', 'gold_agent', '/cash/payment', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96399, 'p', 'gold_agent', '/cash/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96400, 'p', 'gold_agent', '/member/addBalance', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96401, 'p', 'gold_agent', '/member/addIntegral', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96402, 'p', 'gold_agent', '/member/resetPwd', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96403, 'p', 'gold_agent', '/dept/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96404, 'p', 'gold_agent', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96405, 'p', 'gold_agent', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96406, 'p', 'gold_agent', '/member/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96407, 'p', 'gold_agent', '/dept/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96408, 'p', 'gold_agent', '/member/updatePwd', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96409, 'p', 'gold_agent', '/member/updateMobile', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96410, 'p', 'gold_agent', '/member/updateEmail', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96411, 'p', 'silver_agent', 'dashboard', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96412, 'p', 'silver_agent', '/console/stat', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96413, 'p', 'silver_agent', 'dashboard_workplace', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96414, 'p', 'silver_agent', '/dept/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96415, 'p', 'silver_agent', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96416, 'p', 'silver_agent', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96417, 'p', 'silver_agent', '/member/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96418, 'p', 'silver_agent', '/dept/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96419, 'p', 'silver_agent', '/log/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96420, 'p', 'silver_agent', '/log/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96421, 'p', 'silver_agent', '/loginLog/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96422, 'p', 'silver_agent', '/loginLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96423, 'p', 'silver_agent', '/member/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96424, 'p', 'silver_agent', '/member/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96425, 'p', 'silver_agent', '/member/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96426, 'p', 'silver_agent', '/member/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96427, 'p', 'silver_agent', '/loginLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96428, 'p', 'silver_agent', '/loginLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96429, 'p', 'silver_agent', '/notice/messageList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96430, 'p', 'silver_agent', '/member/addBalance', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96431, 'p', 'silver_agent', '/member/addIntegral', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96432, 'p', 'silver_agent', '/member/resetPwd', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96433, 'p', 'silver_agent', '/dept/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96434, 'p', 'silver_agent', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96435, 'p', 'silver_agent', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96436, 'p', 'silver_agent', '/member/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96437, 'p', 'silver_agent', '/dept/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96438, 'p', 'silver_agent', '/member/updatePwd', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96439, 'p', 'silver_agent', '/member/updateMobile', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96440, 'p', 'silver_agent', '/member/updateEmail', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96441, 'p', 'silver_agent', '/member/updateProfile', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96442, 'p', 'silver_agent', '/member/updateCash', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96443, 'p', 'copper_agent', 'dashboard', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96444, 'p', 'copper_agent', '/console/stat', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96445, 'p', 'copper_agent', 'dashboard_workplace', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96446, 'p', 'copper_agent', '/log/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96447, 'p', 'copper_agent', '/log/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96448, 'p', 'copper_agent', '/loginLog/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96449, 'p', 'copper_agent', '/loginLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96450, 'p', 'copper_agent', '/loginLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96451, 'p', 'copper_agent', '/loginLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96452, 'p', 'copper_agent', '/notice/messageList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96453, 'p', 'copper_agent', '/member/updatePwd', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96454, 'p', 'copper_agent', '/member/updateMobile', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96455, 'p', 'copper_agent', '/member/updateEmail', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96456, 'p', 'copper_agent', '/member/updateProfile', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96457, 'p', 'copper_agent', '/member/updateCash', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96458, 'p', 'finance', 'dashboard', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96459, 'p', 'finance', '/console/stat', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96460, 'p', 'finance', 'dashboard_workplace', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96461, 'p', 'finance', '/dept/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96462, 'p', 'finance', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96463, 'p', 'finance', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96464, 'p', 'finance', '/member/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96465, 'p', 'finance', '/dept/option', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96466, 'p', 'finance', '/post/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96467, 'p', 'finance', '/menu/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96468, 'p', 'finance', '/role/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96469, 'p', 'finance', '/role/dataScope/select', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96470, 'p', 'finance', '/role/getPermissions', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96471, 'p', 'finance', '/log/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96472, 'p', 'finance', '/log/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96473, 'p', 'finance', '/loginLog/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96474, 'p', 'finance', '/loginLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96475, 'p', 'finance', '/smsLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96476, 'p', 'finance', '/serveLog/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96477, 'p', 'finance', '/serveLog/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96478, 'p', 'finance', '/monitor/userOnlineList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96479, 'p', 'finance', '/notice/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96480, 'p', 'finance', '/attachment/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96481, 'p', 'finance', '/provinces/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96482, 'p', 'finance', '/provinces/tree', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96483, 'p', 'finance', '/provinces/childrenList', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96484, 'p', 'finance', '/provinces/uniqueId', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96485, 'p', 'finance', '/member/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96486, 'p', 'finance', '/member/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96487, 'p', 'finance', '/member/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96488, 'p', 'finance', '/member/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96489, 'p', 'finance', '/dept/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96490, 'p', 'finance', '/dept/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96491, 'p', 'finance', '/dept/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96492, 'p', 'finance', '/post/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96493, 'p', 'finance', '/post/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96494, 'p', 'finance', '/post/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96495, 'p', 'finance', '/upload/file', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96496, 'p', 'finance', '/hgexample/table/list', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96497, 'p', 'finance', '/hgexample/table/view', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96498, 'p', 'finance', '/loginLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96499, 'p', 'finance', '/loginLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96500, 'p', 'finance', '/serveLog/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96501, 'p', 'finance', '/serveLog/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96502, 'p', 'finance', '/notice/maxSort', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96503, 'p', 'finance', '/notice/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96504, 'p', 'finance', '/notice/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96505, 'p', 'finance', '/notice/switch', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96506, 'p', 'finance', '/notice/editNotify', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96507, 'p', 'finance', '/notice/editNotice', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96508, 'p', 'finance', '/notice/editLetter', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96509, 'p', 'finance', '/notice/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96510, 'p', 'finance', '/test/maxSort', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96511, 'p', 'finance', '/test/export', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96512, 'p', 'finance', '/test/delete', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96513, 'p', 'finance', '/test/status', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96514, 'p', 'finance', '/test/switch', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96515, 'p', 'finance', '/test/edit', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96516, 'p', 'business', 'dashboard', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96517, 'p', 'business', '/console/stat', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96518, 'p', 'business', 'dashboard_workplace', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96519, 'p', 'science', 'dashboard', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96520, 'p', 'science', '/console/stat', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''), +(96521, 'p', 'science', 'dashboard_workplace', 'GET|POST|PUT|DELETE|PATCH|OPTIONS|HEAD', '', '', ''); -- -------------------------------------------------------- @@ -958,10 +960,10 @@ INSERT INTO `hg_admin_role_casbin` (`id`, `p_type`, `v0`, `v1`, `v2`, `v3`, `v4` -- 表的结构 `hg_admin_role_menu` -- -CREATE TABLE `hg_admin_role_menu` ( - `role_id` bigint(20) NOT NULL COMMENT '角色ID', - `menu_id` bigint(20) NOT NULL COMMENT '菜单ID' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='管理员_角色菜单关联'; +CREATE TABLE IF NOT EXISTS `hg_admin_role_menu` ( + `role_id` bigint NOT NULL COMMENT '角色ID', + `menu_id` bigint NOT NULL COMMENT '菜单ID' +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COMMENT='管理员_角色菜单关联'; -- -- 转存表中的数据 `hg_admin_role_menu` @@ -1334,9 +1336,9 @@ INSERT INTO `hg_admin_role_menu` (`role_id`, `menu_id`) VALUES -- 表的结构 `hg_pay_log` -- -CREATE TABLE `hg_pay_log` ( - `id` bigint(20) NOT NULL COMMENT '主键', - `member_id` bigint(20) DEFAULT '0' COMMENT '会员ID', +CREATE TABLE IF NOT EXISTS `hg_pay_log` ( + `id` bigint NOT NULL COMMENT '主键', + `member_id` bigint DEFAULT '0' COMMENT '会员ID', `app_id` varchar(50) DEFAULT NULL COMMENT '应用ID', `addons_name` varchar(100) DEFAULT '' COMMENT '插件名称', `order_sn` varchar(64) DEFAULT '' COMMENT '关联订单号', @@ -1351,21 +1353,21 @@ CREATE TABLE `hg_pay_log` ( `pay_type` varchar(32) NOT NULL COMMENT '支付类型', `pay_amount` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '支付金额', `actual_amount` decimal(10,2) DEFAULT NULL COMMENT '实付金额', - `pay_status` tinyint(4) DEFAULT '0' COMMENT '支付状态', + `pay_status` tinyint DEFAULT '0' COMMENT '支付状态', `pay_at` datetime DEFAULT NULL COMMENT '支付时间', `trade_type` varchar(16) DEFAULT '' COMMENT '交易类型', `refund_sn` varchar(128) DEFAULT NULL COMMENT '退款单号', - `is_refund` tinyint(4) DEFAULT '0' COMMENT '是否退款 ', + `is_refund` tinyint DEFAULT '0' COMMENT '是否退款 ', `custom` text COMMENT '自定义参数', `create_ip` varchar(30) DEFAULT NULL COMMENT '创建者IP', `pay_ip` varchar(30) DEFAULT NULL COMMENT '支付者IP', `notify_url` varchar(255) DEFAULT NULL COMMENT '支付通知回调地址', `return_url` varchar(255) DEFAULT NULL COMMENT '买家付款成功跳转地址', `trace_ids` json DEFAULT NULL COMMENT '链路ID集合', - `status` tinyint(4) DEFAULT '1' COMMENT '状态', + `status` tinyint DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '修改时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='支付_支付日志'; +) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb3 COMMENT='支付_支付日志'; -- -------------------------------------------------------- @@ -1373,21 +1375,21 @@ CREATE TABLE `hg_pay_log` ( -- 表的结构 `hg_pay_refund` -- -CREATE TABLE `hg_pay_refund` ( - `id` bigint(20) UNSIGNED NOT NULL COMMENT '主键ID', - `member_id` bigint(20) DEFAULT '0' COMMENT '会员ID', +CREATE TABLE IF NOT EXISTS `hg_pay_refund` ( + `id` bigint unsigned NOT NULL COMMENT '主键ID', + `member_id` bigint DEFAULT '0' COMMENT '会员ID', `app_id` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '应用ID', `order_sn` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '业务订单号', `refund_trade_no` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '退款交易号', `refund_money` decimal(10,2) DEFAULT NULL COMMENT '退款金额', - `refund_way` tinyint(4) DEFAULT '1' COMMENT '退款方式', + `refund_way` tinyint DEFAULT '1' COMMENT '退款方式', `ip` varchar(30) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '申请者IP', `reason` varchar(255) DEFAULT NULL COMMENT '申请退款原因', `remark` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '退款备注', - `status` tinyint(4) DEFAULT '1' COMMENT '退款状态', + `status` tinyint DEFAULT '1' COMMENT '退款状态', `created_at` datetime DEFAULT NULL COMMENT '申请时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='订单退款账户记录'; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COMMENT='订单退款账户记录'; -- -------------------------------------------------------- @@ -1395,8 +1397,8 @@ CREATE TABLE `hg_pay_refund` ( -- 表的结构 `hg_sys_addons_config` -- -CREATE TABLE `hg_sys_addons_config` ( - `id` bigint(20) NOT NULL COMMENT '配置ID', +CREATE TABLE IF NOT EXISTS `hg_sys_addons_config` ( + `id` bigint NOT NULL COMMENT '配置ID', `addon_name` varchar(128) NOT NULL COMMENT '插件名称', `group` varchar(128) NOT NULL COMMENT '分组', `name` varchar(100) DEFAULT '' COMMENT '参数名称', @@ -1404,13 +1406,13 @@ CREATE TABLE `hg_sys_addons_config` ( `key` varchar(100) DEFAULT '' COMMENT '参数键名', `value` varchar(500) DEFAULT '' COMMENT '参数键值', `default_value` varchar(500) NOT NULL COMMENT '默认值', - `sort` int(11) NOT NULL DEFAULT '0' COMMENT '排序', + `sort` int NOT NULL DEFAULT '0' COMMENT '排序', `tip` varchar(500) DEFAULT NULL COMMENT '变量描述', `is_default` tinyint(1) DEFAULT '0' COMMENT '是否为系统默认', `status` tinyint(1) DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_插件配置'; +) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb3 COMMENT='系统_插件配置'; -- -- 转存表中的数据 `hg_sys_addons_config` @@ -1425,14 +1427,14 @@ INSERT INTO `hg_sys_addons_config` (`id`, `addon_name`, `group`, `name`, `type`, -- 表的结构 `hg_sys_addons_install` -- -CREATE TABLE `hg_sys_addons_install` ( - `id` bigint(20) NOT NULL COMMENT '主键', +CREATE TABLE IF NOT EXISTS `hg_sys_addons_install` ( + `id` bigint NOT NULL COMMENT '主键', `name` varchar(255) NOT NULL COMMENT '插件名称', `version` varchar(128) NOT NULL DEFAULT '' COMMENT '版本号', `status` tinyint(1) DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_插件安装记录'; +) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb3 COMMENT='系统_插件安装记录'; -- -- 转存表中的数据 `hg_sys_addons_install` @@ -1447,11 +1449,11 @@ INSERT INTO `hg_sys_addons_install` (`id`, `name`, `version`, `status`, `created -- 表的结构 `hg_sys_attachment` -- -CREATE TABLE `hg_sys_attachment` ( - `id` bigint(20) NOT NULL COMMENT '文件ID', +CREATE TABLE IF NOT EXISTS `hg_sys_attachment` ( + `id` bigint NOT NULL COMMENT '文件ID', `app_id` varchar(64) NOT NULL COMMENT '应用ID', - `member_id` bigint(20) DEFAULT '0' COMMENT '管理员ID', - `cate_id` bigint(20) UNSIGNED DEFAULT '0' COMMENT '上传分类', + `member_id` bigint DEFAULT '0' COMMENT '管理员ID', + `cate_id` bigint unsigned DEFAULT '0' COMMENT '上传分类', `drive` varchar(64) DEFAULT NULL COMMENT '上传驱动', `name` varchar(1000) DEFAULT NULL COMMENT '文件原始名', `kind` varchar(16) DEFAULT NULL COMMENT '上传类型', @@ -1459,13 +1461,13 @@ CREATE TABLE `hg_sys_attachment` ( `naive_type` varchar(32) NOT NULL COMMENT 'NaiveUI类型', `path` varchar(1000) DEFAULT NULL COMMENT '本地路径', `file_url` varchar(1000) DEFAULT NULL COMMENT 'url', - `size` bigint(20) DEFAULT '0' COMMENT '文件大小', + `size` bigint DEFAULT '0' COMMENT '文件大小', `ext` varchar(50) DEFAULT NULL COMMENT '扩展名', `md5` varchar(32) DEFAULT NULL COMMENT 'md5校验码', `status` tinyint(1) NOT NULL DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '修改时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_附件管理'; +) ENGINE=InnoDB AUTO_INCREMENT=8 DEFAULT CHARSET=utf8mb3 COMMENT='系统_附件管理'; -- -------------------------------------------------------- @@ -1473,14 +1475,14 @@ CREATE TABLE `hg_sys_attachment` ( -- 表的结构 `hg_sys_blacklist` -- -CREATE TABLE `hg_sys_blacklist` ( - `id` bigint(20) NOT NULL COMMENT '黑名单ID', +CREATE TABLE IF NOT EXISTS `hg_sys_blacklist` ( + `id` bigint NOT NULL COMMENT '黑名单ID', `ip` varchar(100) DEFAULT '' COMMENT 'IP地址', `remark` varchar(500) DEFAULT NULL COMMENT '备注', `status` tinyint(1) DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_访问黑名单'; +) ENGINE=InnoDB AUTO_INCREMENT=8 DEFAULT CHARSET=utf8mb3 COMMENT='系统_访问黑名单'; -- -- 转存表中的数据 `hg_sys_blacklist` @@ -1500,21 +1502,21 @@ INSERT INTO `hg_sys_blacklist` (`id`, `ip`, `remark`, `status`, `created_at`, `u -- 表的结构 `hg_sys_config` -- -CREATE TABLE `hg_sys_config` ( - `id` bigint(20) NOT NULL COMMENT '配置ID', +CREATE TABLE IF NOT EXISTS `hg_sys_config` ( + `id` bigint NOT NULL COMMENT '配置ID', `group` varchar(128) NOT NULL COMMENT '配置分组', `name` varchar(100) DEFAULT '' COMMENT '参数名称', `type` varchar(32) NOT NULL COMMENT '键值类型:string,int,uint,bool,datetime,date', `key` varchar(100) DEFAULT '' COMMENT '参数键名', `value` longtext COMMENT '参数键值', `default_value` varchar(500) NOT NULL COMMENT '默认值', - `sort` int(11) NOT NULL DEFAULT '0' COMMENT '排序', + `sort` int NOT NULL DEFAULT '0' COMMENT '排序', `tip` varchar(500) DEFAULT NULL COMMENT '变量描述', `is_default` tinyint(1) DEFAULT '0' COMMENT '是否为系统默认', `status` tinyint(1) DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_配置'; +) ENGINE=InnoDB AUTO_INCREMENT=129 DEFAULT CHARSET=utf8mb3 COMMENT='系统_配置'; -- -- 转存表中的数据 `hg_sys_config` @@ -1536,56 +1538,56 @@ INSERT INTO `hg_sys_config` (`id`, `group`, `name`, `type`, `key`, `value`, `def (15, 'smtp', 'SMTP密码', 'string', 'smtpPass', '', '', 120, '填写您的密码', 1, 1, '2021-01-30 13:27:43', '2023-02-04 16:59:13'), (16, 'smtp', '发件人名称', 'string', 'smtpSendName', 'HotGo', 'HotGo', 130, '', 1, 1, '2021-01-30 13:27:43', '2023-02-04 16:59:13'), (17, 'smtp', '管理员邮箱', 'string', 'smtpAdminMailbox', '133814250@qq.com', '133814250@qq.com', 140, '', 1, 1, '2021-01-30 13:27:43', '2023-02-04 16:59:13'), -(28, 'upload', '上传驱动', 'string', 'uploadDrive', 'local', '', 300, 'local:本地;ucloud:ucloud;腾讯云:cos', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(29, 'upload', '上传图片大小限制', 'int', 'uploadImageSize', '2', '2', 310, '单位:MB', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(30, 'upload', '上传图片类型限制', 'string', 'uploadImageType', 'jpg,jpeg,gif,npm,png,svg', 'jpg,jpeg,gif,npm,png,svg', 320, '图片上传后缀类型限制', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(31, 'upload', '上传文件大小限制', 'int', 'uploadFileSize', '10', '10', 330, '单位:MB', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(32, 'upload', '上传文件类型限制', 'string', 'uploadFileType', 'doc,docx,zip,xls,xlsx,rar,jpg,jpeg,gif,npm,png,svg', 'doc,docx,zip,xls,xlsx,rar,jpg,jpeg,gif,npm,png,svg', 340, '文件上传后缀类型限制', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(33, 'upload', '本地存储路径', 'string', 'uploadLocalPath', 'attachment/', 'attachment/', 350, '对外访问的相对路径', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(34, 'upload', 'UCloud存储路径', 'string', 'uploadUCloudPath', 'hotgo/attachment/', 'hotgo/attachment/', 360, 'UC对象存储中的相对路径', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(35, 'upload', 'UCloud公钥', 'string', 'uploadUCloudPublicKey', '', '', 370, '获取地址:https://console.ucloud.cn/ufile/token', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(36, 'upload', 'UCloud私钥', 'string', 'uploadUCloudPrivateKey', '', '', 380, '', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(37, 'upload', 'UCloud地域API', 'string', 'uploadUCloudBucketHost', 'api.ucloud.cn', 'api.ucloud.cn', 390, '', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(38, 'upload', 'UCloud存储桶名称', 'string', 'uploadUCloudBucketName', 'bufanyun', '', 400, '存储空间名称', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(39, 'upload', 'UCloud存储桶地域host', 'string', 'uploadUCloudFileHost', 'cn-bj.ufileos.com', 'cn-bj.ufileos.com', 410, '', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(40, 'upload', 'UCloud访问域名', 'string', 'uploadUCloudEndpoint', 'http://bufanyun.cn-bj.ufileos.com', '', 420, '格式,http://abc.com 或 https://abc.com,不可为空', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), +(28, 'upload', '上传驱动', 'string', 'uploadDrive', 'minio', '', 300, 'local:本地;ucloud:ucloud;腾讯云:cos', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(29, 'upload', '上传图片大小限制', 'int', 'uploadImageSize', '1', '2', 310, '单位:MB', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(30, 'upload', '上传图片类型限制', 'string', 'uploadImageType', 'jpg,jpeg,gif,npm,png,svg', 'jpg,jpeg,gif,npm,png,svg', 320, '图片上传后缀类型限制', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(31, 'upload', '上传文件大小限制', 'int', 'uploadFileSize', '5', '10', 330, '单位:MB', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(32, 'upload', '上传文件类型限制', 'string', 'uploadFileType', 'doc,docx,zip,xls,xlsx,rar,jpg,jpeg,gif,npm,png,svg', 'doc,docx,zip,xls,xlsx,rar,jpg,jpeg,gif,npm,png,svg', 340, '文件上传后缀类型限制', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(33, 'upload', '本地存储路径', 'string', 'uploadLocalPath', 'attachment/', 'attachment/', 350, '对外访问的相对路径', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(34, 'upload', 'UCloud存储路径', 'string', 'uploadUCloudPath', 'hotgo/attachment/', 'hotgo/attachment/', 360, 'UC对象存储中的相对路径', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(35, 'upload', 'UCloud公钥', 'string', 'uploadUCloudPublicKey', '', '', 370, '获取地址:https://console.ucloud.cn/ufile/token', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(36, 'upload', 'UCloud私钥', 'string', 'uploadUCloudPrivateKey', '', '', 380, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(37, 'upload', 'UCloud地域API', 'string', 'uploadUCloudBucketHost', 'api.ucloud.cn', 'api.ucloud.cn', 390, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(38, 'upload', 'UCloud存储桶名称', 'string', 'uploadUCloudBucketName', 'bufanyun', '', 400, '存储空间名称', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(39, 'upload', 'UCloud存储桶地域host', 'string', 'uploadUCloudFileHost', 'cn-bj.ufileos.com', 'cn-bj.ufileos.com', 410, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(40, 'upload', 'UCloud访问域名', 'string', 'uploadUCloudEndpoint', 'http://bufanyun.cn-bj.ufileos.com', '', 420, '格式,http://abc.com 或 https://abc.com,不可为空', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), (41, 'geo', '高德Web服务key', 'string', 'geoAmapWebKey', '', '', 500, '申请地址:https://console.amap.com/dev/key/app', 1, 1, '2021-01-30 13:27:43', '2022-12-07 15:48:43'), (42, 'sms', '短信驱动,aliyun:阿里云;tencent:腾讯云', 'string', 'smsDrive', 'tencent', '', 600, '', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), (43, 'sms', '阿里云AccessKeyID', 'string', 'smsAliYunAccessKeyID', '', '', 610, '应用key和密钥你可以通过 https://ram.console.aliyun.com/manage/ak 获取', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), (44, 'sms', '阿里云AccessKeySecret', 'string', 'smsAliYunAccessKeySecret', '', '', 620, '', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), (45, 'sms', '阿里云短信签名', 'string', 'smsAliYunSign', '', '', 630, '申请地址:https://dysms.console.aliyun.com/domestic/text/sign', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), -(46, 'sms', '阿里云短信模板', 'string', 'smsAliYunTemplate', '[{\"key\":\"login\",\"value\":\"SMS_198921686\"},{\"key\":\"register\",\"value\":\"SMS_198921686\"},{\"key\":\"code\",\"value\":\"SMS_198921686\"},{\"key\":\"resetPwd\",\"value\":\"SMS_198921686\"},{\"key\":\"bind\",\"value\":\"SMS_198921686\"},{\"key\":\"cash\",\"value\":\"SMS_198921686\"}]', '', 640, '', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), +(46, 'sms', '阿里云短信模板', 'string', 'smsAliYunTemplate', '[{"key":"login","value":"SMS_198921686"},{"key":"register","value":"SMS_198921686"},{"key":"code","value":"SMS_198921686"},{"key":"resetPwd","value":"SMS_198921686"},{"key":"bind","value":"SMS_198921686"},{"key":"cash","value":"SMS_198921686"}]', '', 640, '', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), (47, 'sms', '最小发送间隔', 'int', 'smsMinInterval', '60', '', 600, '同号码', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), (48, 'sms', 'IP最大发送次数', 'int', 'smsMaxIpLimit', '10', '', 610, '同IP每天最大允许发送次数', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), (49, 'sms', '验证码有效期', 'int', 'smsCodeExpire', '600', '', 610, '单位:秒', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), -(50, 'smtp', '邮件模板', 'string', 'smtpTemplate', '[{\"key\":\"text\",\"value\":\"./resource/template/email/text.html\"},{\"key\":\"login\",\"value\":\"./resource/template/email/code.html\"},{\"key\":\"register\",\"value\":\"./resource/template/email/code.html\"},{\"key\":\"code\",\"value\":\"./resource/template/email/code.html\"},{\"key\":\"resetPwd\",\"value\":\"./resource/template/email/resetPwd.html\"},{\"key\":\"bind\",\"value\":\"./resource/template/email/code.html\"},{\"key\":\"cash\",\"value\":\"./resource/template/email/code.html\"}]', '', 190, '', 1, 1, '2021-01-30 13:27:43', '2023-02-04 16:59:13'), +(50, 'smtp', '邮件模板', 'string', 'smtpTemplate', '[{"key":"text","value":"./resource/template/email/text.html"},{"key":"login","value":"./resource/template/email/code.html"},{"key":"register","value":"./resource/template/email/code.html"},{"key":"code","value":"./resource/template/email/code.html"},{"key":"resetPwd","value":"./resource/template/email/resetPwd.html"},{"key":"bind","value":"./resource/template/email/code.html"},{"key":"cash","value":"./resource/template/email/code.html"}]', '', 190, '', 1, 1, '2021-01-30 13:27:43', '2023-02-04 16:59:13'), (51, 'smtp', '最小发送间隔', 'int', 'smtpMinInterval', '60', '', 150, '同地址', 1, 1, '2021-01-30 13:27:43', '2023-02-04 16:59:13'), (52, 'smtp', 'IP最大发送次数', 'int', 'smtpMaxIpLimit', '10', '', 160, '同IP每天最大允许发送次数', 1, 1, '2021-01-30 13:27:43', '2023-02-04 16:59:13'), (53, 'smtp', '验证码有效期', 'int', 'smtpCodeExpire', '600', '', 170, '单位:秒', 1, 1, '2021-01-30 13:27:43', '2023-02-04 16:59:13'), (54, 'basic', '网站域名', 'string', 'basicDomain', 'https://hotgo.facms.cn', 'https://hotgo.facms.cn', 45, '', 1, 1, '2021-01-30 13:27:43', '2023-08-11 14:44:12'), (55, 'basic', 'websocket地址', 'string', 'basicWsAddr', 'wss://hotgo.facms.cn/socket', 'wss://hotgo.facms.cn/socket', 48, '', 1, 1, '2021-01-30 13:27:43', '2023-08-11 14:44:12'), -(56, 'upload', 'COS存储路径', 'string', 'uploadCosPath', 'hotgo/attachment/', 'hotgo/attachment/', 450, 'COS对象存储中的相对路径', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(57, 'upload', 'COS秘钥ID', 'string', 'uploadCosSecretId', '', '', 460, '子账号密钥获取可参考 https://cloud.tencent.com/document/product/598/37140', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(58, 'upload', 'COS秘钥', 'string', 'uploadCosSecretKey', '', '', 470, '', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(59, 'upload', 'COS访问域名', 'string', 'uploadCosBucketURL', '', 'https://xxx-1253625515.cos.ap-beijing.myqcloud.com', 480, '控制台查看地址:https://console.cloud.tencent.com/cos/bucket', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(60, 'upload', 'OSS存储路径', 'string', 'uploadOssPath', 'hotgo/attachment/', 'hotgo/attachment/', 500, 'OSS对象存储中的相对路径', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(61, 'upload', 'OSS秘钥ID', 'string', 'uploadOssSecretId', '', '', 510, '阿里云账号AccessKey拥有所有API的访问权限,风险很高。强烈建议您创建并使用RAM用户进行API访问或日常运维,请登录RAM控制台创建RAM用户。', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(62, 'upload', 'OSS秘钥', 'string', 'uploadOssSecretKey', '', '', 520, '', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(63, 'upload', 'Bucket 域名', 'string', 'uploadOssBucketURL', 'http://bufanyunoss.oss-cn-qingdao.aliyuncs.com', 'https://xxx.oss-cn-qingdao.aliyuncs.com', 530, 'Bucket 域名', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(64, 'upload', 'OSSEndpoint', 'string', 'uploadOssEndpoint', 'http://oss-cn-qingdao.aliyuncs.com', 'https://oss-cn-qingdao.aliyuncs.com', 540, 'Endpoint(地域节点)', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(65, 'upload', 'OSS存储空间名称', 'string', 'uploadOssBucket', '', '', 550, '存储空间名称,例如examplebucket', 1, 1, '2021-01-30 13:27:43', '2023-03-20 17:41:17'), -(66, 'upload', '七牛云AccessKey', 'string', 'uploadQiNiuAccessKey', '', '', 600, '创建地址:https://portal.qiniu.com/user/key', 1, 1, '2021-01-30 13:27:43', '2023-04-01 14:00:14'), -(67, 'upload', '七牛云SecretKey', 'string', 'uploadQiNiuSecretKey', '', '', 610, '', 1, 1, '2021-01-30 13:27:43', '2023-04-01 14:00:14'), -(68, 'upload', '七牛云储存路径', 'string', 'uploadQiNiuPath', 'hotgo/attachment/', 'hotgo/attachment/', 620, '', 1, 1, '2021-01-30 13:27:43', '2023-04-01 14:00:14'), -(69, 'upload', '七牛云存储空间名称', 'string', 'uploadQiNiuBucket', '', 'bufanyun', 630, '', 1, 1, '2021-01-30 13:27:43', '2023-04-01 14:00:14'), -(70, 'upload', '七牛云访问域名', 'string', 'uploadQiNiuDomain', '', '', 640, '', 1, 1, '2021-01-30 13:27:43', '2023-04-01 14:00:14'), +(56, 'upload', 'COS存储路径', 'string', 'uploadCosPath', 'hotgo/attachment/', 'hotgo/attachment/', 450, 'COS对象存储中的相对路径', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(57, 'upload', 'COS秘钥ID', 'string', 'uploadCosSecretId', '', '', 460, '子账号密钥获取可参考 https://cloud.tencent.com/document/product/598/37140', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(58, 'upload', 'COS秘钥', 'string', 'uploadCosSecretKey', '', '', 470, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(59, 'upload', 'COS访问域名', 'string', 'uploadCosBucketURL', '', 'https://xxx-1253625515.cos.ap-beijing.myqcloud.com', 480, '控制台查看地址:https://console.cloud.tencent.com/cos/bucket', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(60, 'upload', 'OSS存储路径', 'string', 'uploadOssPath', 'hotgo/attachment/', 'hotgo/attachment/', 500, 'OSS对象存储中的相对路径', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(61, 'upload', 'OSS秘钥ID', 'string', 'uploadOssSecretId', '', '', 510, '阿里云账号AccessKey拥有所有API的访问权限,风险很高。强烈建议您创建并使用RAM用户进行API访问或日常运维,请登录RAM控制台创建RAM用户。', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(62, 'upload', 'OSS秘钥', 'string', 'uploadOssSecretKey', '', '', 520, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(63, 'upload', 'Bucket 域名', 'string', 'uploadOssBucketURL', 'http://bufanyunoss.oss-cn-qingdao.aliyuncs.com', 'https://xxx.oss-cn-qingdao.aliyuncs.com', 530, 'Bucket 域名', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(64, 'upload', 'OSSEndpoint', 'string', 'uploadOssEndpoint', 'http://oss-cn-qingdao.aliyuncs.com', 'https://oss-cn-qingdao.aliyuncs.com', 540, 'Endpoint(地域节点)', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(65, 'upload', 'OSS存储空间名称', 'string', 'uploadOssBucket', '', '', 550, '存储空间名称,例如examplebucket', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(66, 'upload', '七牛云AccessKey', 'string', 'uploadQiNiuAccessKey', '', '', 600, '创建地址:https://portal.qiniu.com/user/key', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(67, 'upload', '七牛云SecretKey', 'string', 'uploadQiNiuSecretKey', '', '', 610, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(68, 'upload', '七牛云储存路径', 'string', 'uploadQiNiuPath', 'hotgo/attachment/', 'hotgo/attachment/', 620, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(69, 'upload', '七牛云存储空间名称', 'string', 'uploadQiNiuBucket', '', 'bufanyun', 630, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(70, 'upload', '七牛云访问域名', 'string', 'uploadQiNiuDomain', '', '', 640, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), (78, 'sms', '腾讯云SecretId', 'string', 'smsTencentSecretId', '', '', 650, '获取地址:https://console.cloud.tencent.com/cam/capi', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), (79, 'sms', '腾讯云SecretKey', 'string', 'smsTencentSecretKey', '', '', 660, '', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), (80, 'sms', '腾讯云短信应用ID', 'string', 'smsTencentAppId', '', '', 670, '查看地址:https://console.cloud.tencent.com/smsv2/app-manage', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), (81, 'sms', '腾讯云短信签名', 'string', 'smsTencentSign', '', '', 680, '查看地址:https://console.cloud.tencent.com/smsv2/csms-sign', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), (82, 'sms', '腾讯云接入地域域名', 'string', 'smsTencentEndpoint', 'sms.tencentcloudapi.com', 'sms.tencentcloudapi.com', 690, '默认就近地域接入域名为 sms.tencentcloudapi.com ,也支持指定地域域名访问,例如广州地域的域名为 sms.ap-guangzhou.tencentcloudapi.com', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), (83, 'sms', '腾讯云地域信息', 'string', 'smsTencentRegion', 'ap-guangzhou', 'ap-guangzhou', 695, '支持的地域列表参考 https://cloud.tencent.com/document/api/382/52071#.E5.9C.B0.E5.9F.9F.E5.88.97.E8.A1.A8', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), -(84, 'sms', '腾讯云短信模板', 'string', 'smsTencentTemplate', '[{\"key\":\"login\",\"value\":\"1758990\"},{\"key\":\"register\",\"value\":\"1758990\"},{\"key\":\"code\",\"value\":\"1758990\"},{\"key\":\"resetPwd\",\"value\":\"1758990\"},{\"key\":\"bind\",\"value\":\"1758990\"},{\"key\":\"cash\",\"value\":\"1758990\"}]', '', 698, '', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), +(84, 'sms', '腾讯云短信模板', 'string', 'smsTencentTemplate', '[{"key":"login","value":"1758990"},{"key":"register","value":"1758990"},{"key":"code","value":"1758990"},{"key":"resetPwd","value":"1758990"},{"key":"bind","value":"1758990"},{"key":"cash","value":"1758990"}]', '', 698, '', 1, 1, '2021-01-30 13:27:43', '2023-04-10 13:55:32'), (85, 'pay', 'Debug开关', 'bool', 'payDebug', '1', 'true', 800, '输出请求日志', 1, 1, '2021-01-30 13:27:43', '2023-08-05 14:00:56'), (86, 'pay', '支付宝应用ID', 'string', 'payAliPayAppId', '', '', 810, '', 1, 1, '2021-01-30 13:27:43', '2023-08-05 14:00:56'), (87, 'pay', '支付宝PrivateKey', 'string', 'payAliPayPrivateKey', 'storage/cert/pay/alipay/alipayPrivateKey', '', 820, '应用私钥,支持PKCS1和PKCS8', 1, 1, '2021-01-30 13:27:43', '2023-08-05 14:00:56'), @@ -1615,14 +1617,21 @@ INSERT INTO `hg_sys_config` (`id`, `group`, `name`, `type`, `key`, `value`, `def (111, 'wechat', '开放平台token', 'string', 'openPlatformToken', '', '', 1070, '', 1, 1, '2021-01-30 13:27:43', '2023-07-26 16:06:53'), (112, 'login', '注册开关', 'int', 'loginRegisterSwitch', '1', '1', 1100, '', 1, 1, '2021-09-29 23:51:21', '2023-08-04 17:03:36'), (113, 'login', '验证码开关', 'int', 'loginCaptchaSwitch', '1', '1', 1110, '', 1, 1, '2021-09-29 23:51:21', '2023-08-04 17:03:36'), -(114, 'login', '用户协议', 'string', 'loginProtocol', '

用户协议..

', '', 1120, '', 1, 1, '2021-09-29 23:51:21', '2023-08-04 17:03:36'), -(115, 'login', '隐私权政策', 'string', 'loginPolicy', '

隐私权政策..

', '', 1130, '', 1, 1, '2021-09-29 23:51:21', '2023-08-04 17:03:36'), +(114, 'login', '用户协议', 'string', 'loginProtocol', '

用户协议..

', '', 1120, '', 1, 1, '2021-09-29 23:51:21', '2023-08-04 17:03:36'), +(115, 'login', '隐私权政策', 'string', 'loginPolicy', '

隐私权政策..

', '', 1130, '', 1, 1, '2021-09-29 23:51:21', '2023-08-04 17:03:36'), (116, 'login', '默认注册角色', 'int64', 'loginRoleId', '202', '', 1140, '', 1, 1, '2021-09-29 23:51:21', '2023-08-04 17:03:36'), (117, 'login', '默认注册部门', 'int64', 'loginDeptId', '109', '', 1150, '', 1, 1, '2021-09-29 23:51:21', '2023-08-04 17:03:36'), (118, 'login', '默认注册岗位', '[]int64', 'loginPostIds', '[6]', '', 1160, '', 1, 1, '2021-09-29 23:51:21', '2023-08-04 17:03:36'), (119, 'login', '默认注册头像', 'string', 'loginAvatar', 'http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2023-02-09/cqdq8er9nfkchdopav.png', '', 1170, '', 1, 1, '2021-09-29 23:51:21', '2023-08-04 17:03:36'), (120, 'login', '强制邀请', 'int', 'loginForceInvite', '2', '1', 1190, '', 1, 1, '2021-09-29 23:51:21', '2023-08-04 17:03:36'), -(121, 'login', '自动获取openId', 'int', 'loginAutoOpenId', '2', '1', 1195, '', 1, 1, '2021-09-29 23:51:21', '2023-08-04 17:03:36'); +(121, 'login', '自动获取openId', 'int', 'loginAutoOpenId', '2', '1', 1195, '', 1, 1, '2021-09-29 23:51:21', '2023-08-04 17:03:36'), +(122, 'upload', 'minio AccessKey', 'string', 'uploadMinioAccessKey', '', '', 650, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(123, 'upload', 'minio SecretKey', 'string', 'uploadMinioSecretKey', '', '', 650, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(124, 'upload', 'minio地域节点', 'string', 'uploadMinioEndpoint', '', '', 650, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(125, 'upload', 'minio是否启用SSL', 'int', 'uploadMinioUseSSL', '1', '', 650, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(126, 'upload', 'minio存储路径', 'string', 'uploadMinioPath', 'hotgo/attachment/', '', 650, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(127, 'upload', 'minio桶名称', 'string', 'uploadMinioBucket', '', '', 650, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'), +(128, 'upload', 'minio对外访问域名', 'string', 'uploadMinioDomain', '', '', 650, '', 1, 1, '2021-01-30 13:27:43', '2023-11-11 17:11:51'); -- -------------------------------------------------------- @@ -1630,29 +1639,32 @@ INSERT INTO `hg_sys_config` (`id`, `group`, `name`, `type`, `key`, `value`, `def -- 表的结构 `hg_sys_cron` -- -CREATE TABLE `hg_sys_cron` ( - `id` bigint(20) NOT NULL COMMENT '任务ID', - `group_id` bigint(20) NOT NULL COMMENT '分组ID', - `name` varchar(100) DEFAULT '' COMMENT '任务名称', - `params` varchar(255) DEFAULT '' COMMENT '函数参数', - `pattern` varchar(64) NOT NULL COMMENT '定时表达式', - `policy` bigint(20) NOT NULL DEFAULT '1' COMMENT '策略', - `count` bigint(20) NOT NULL DEFAULT '0' COMMENT '执行次数', - `sort` int(11) DEFAULT '0' COMMENT '排序', - `remark` varchar(500) DEFAULT NULL COMMENT '备注', +CREATE TABLE IF NOT EXISTS `hg_sys_cron` ( + `id` bigint NOT NULL COMMENT '任务ID', + `group_id` bigint NOT NULL COMMENT '分组ID', + `title` varchar(128) NOT NULL COMMENT '任务标题', + `name` varchar(100) CHARACTER SET utf8mb3 COLLATE utf8_general_ci DEFAULT NULL COMMENT '任务方法', + `params` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8_general_ci DEFAULT NULL COMMENT '函数参数', + `pattern` varchar(64) CHARACTER SET utf8mb3 COLLATE utf8_general_ci NOT NULL COMMENT '表达式', + `policy` bigint NOT NULL DEFAULT '1' COMMENT '策略', + `count` bigint NOT NULL DEFAULT '0' COMMENT '执行次数', + `sort` int DEFAULT '0' COMMENT '排序', + `remark` varchar(500) CHARACTER SET utf8mb3 COLLATE utf8_general_ci DEFAULT NULL COMMENT '备注', `status` tinyint(1) DEFAULT '1' COMMENT '任务状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_定时任务'; +) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb3 COMMENT='系统_定时任务'; -- -- 转存表中的数据 `hg_sys_cron` -- -INSERT INTO `hg_sys_cron` (`id`, `group_id`, `name`, `params`, `pattern`, `policy`, `count`, `sort`, `remark`, `status`, `created_at`, `updated_at`) VALUES -(1, 1, 'test', '', '* * * * * *', 1, 3, 10, '测试无参数任务', 2, '2022-10-01 22:02:09', '2023-04-27 23:27:39'), -(2, 1, 'test2', 'hotGo,3,欢迎使用hotGo!', '* * * * * *', 1, 0, 10, '测试有参数任务', 2, '2022-10-01 06:02:09', '2023-02-04 17:39:53'), -(3, 1, 'close_order', '', '0 */10 * * * *', 1, 1, 100, '取消过期订单,10分钟运行一次', 2, '2023-04-22 21:58:47', '2023-04-22 22:00:23'); +INSERT INTO `hg_sys_cron` (`id`, `group_id`, `title`, `name`, `params`, `pattern`, `policy`, `count`, `sort`, `remark`, `status`, `created_at`, `updated_at`) VALUES +(1, 1, '测试任务', 'test', '', '* * * * * *', 1, 3, 10, '测试无参数任务', 2, '2022-10-01 22:02:09', '2023-11-20 10:22:59'), +(2, 1, '测试带参数', 'test2', 'hotGo,3,欢迎使用hotGo!', '* * * * * *', 1, 0, 10, '测试有参数任务', 2, '2022-10-01 06:02:09', '2023-11-17 18:38:49'), +(3, 1, '测试带参数-多任务', 'test2', 'hotGo,3,这是同一个执行方法开多个定时任务的实例!', '* * * * * *', 1, 1, 10, '相同的执行方法,可以开启多个任务', 2, '2023-11-17 16:12:26', '2023-11-20 10:11:47'), +(4, 1, '测试带参数-错误', 'test2', '666', '* * * * * *', 1, 1, 10, '参入一个错误的参数格式,来模拟执行出错示例', 2, '2023-11-17 18:23:39', '2023-11-17 18:39:59'), +(5, 1, '关闭过期订单', 'close_order', '', '0 */10 * * * *', 1, 1, 100, '取消过期订单,10分钟运行一次', 2, '2023-04-22 21:58:47', '2023-11-18 11:54:07'); -- -------------------------------------------------------- @@ -1660,17 +1672,17 @@ INSERT INTO `hg_sys_cron` (`id`, `group_id`, `name`, `params`, `pattern`, `polic -- 表的结构 `hg_sys_cron_group` -- -CREATE TABLE `hg_sys_cron_group` ( - `id` bigint(20) NOT NULL COMMENT '任务分组ID', - `pid` bigint(20) NOT NULL COMMENT '父类任务分组ID', +CREATE TABLE IF NOT EXISTS `hg_sys_cron_group` ( + `id` bigint NOT NULL COMMENT '任务分组ID', + `pid` bigint NOT NULL COMMENT '父类任务分组ID', `name` varchar(100) DEFAULT '' COMMENT '分组名称', `is_default` tinyint(1) DEFAULT '0' COMMENT '是否默认', - `sort` int(11) DEFAULT '0' COMMENT '排序', + `sort` int DEFAULT '0' COMMENT '排序', `remark` varchar(500) DEFAULT NULL COMMENT '备注', `status` tinyint(1) DEFAULT '1' COMMENT '分组状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_定时任务分组'; +) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb3 COMMENT='系统_定时任务分组'; -- -- 转存表中的数据 `hg_sys_cron_group` @@ -1686,20 +1698,20 @@ INSERT INTO `hg_sys_cron_group` (`id`, `pid`, `name`, `is_default`, `sort`, `rem -- 表的结构 `hg_sys_dict_data` -- -CREATE TABLE `hg_sys_dict_data` ( - `id` bigint(20) NOT NULL COMMENT '字典数据ID', +CREATE TABLE IF NOT EXISTS `hg_sys_dict_data` ( + `id` bigint NOT NULL COMMENT '字典数据ID', `label` varchar(100) DEFAULT NULL COMMENT '字典标签', `value` varchar(100) DEFAULT NULL COMMENT '字典键值', `value_type` varchar(255) NOT NULL DEFAULT 'string' COMMENT '键值数据类型:string,int,uint,bool,datetime,date', `type` varchar(100) DEFAULT NULL COMMENT '字典类型', `list_class` varchar(100) DEFAULT NULL COMMENT '表格回显样式', `is_default` tinyint(1) DEFAULT '2' COMMENT '是否为系统默认', - `sort` int(11) DEFAULT '0' COMMENT '字典排序', + `sort` int DEFAULT '0' COMMENT '字典排序', `remark` varchar(500) DEFAULT NULL COMMENT '备注', `status` tinyint(1) DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_字典数据'; +) ENGINE=InnoDB AUTO_INCREMENT=158 DEFAULT CHARSET=utf8mb3 COMMENT='系统_字典数据'; -- -- 转存表中的数据 `hg_sys_dict_data` @@ -1784,7 +1796,8 @@ INSERT INTO `hg_sys_dict_data` (`id`, `label`, `value`, `value_type`, `type`, `l (153, '富文本', 'text', 'string', 'config_ems_template', 'default', 0, 0, '自定义编辑邮件内容时使用', 1, '2023-01-21 10:29:36', '2023-05-29 14:30:49'), (154, '腾讯云', 'cos', 'string', 'config_upload_drive', 'info', 1, 30, '', 1, '2022-12-30 17:58:26', '2022-12-30 17:58:26'), (155, '阿里云', 'oss', 'string', 'config_upload_drive', 'info', 1, 40, '', 1, '2022-12-30 17:58:26', '2022-12-30 17:58:26'), -(156, '七牛云', 'qiniu', 'string', 'config_upload_drive', 'success', 1, 50, '', 1, '2022-12-30 17:58:26', '2022-12-30 17:58:26'); +(156, '七牛云', 'qiniu', 'string', 'config_upload_drive', 'success', 1, 50, '', 1, '2022-12-30 17:58:26', '2022-12-30 17:58:26'), +(157, 'minio', 'minio', 'string', 'config_upload_drive', 'default', 0, 60, '', 1, '2023-11-11 16:45:12', '2023-11-11 16:45:12'); -- -------------------------------------------------------- @@ -1792,17 +1805,17 @@ INSERT INTO `hg_sys_dict_data` (`id`, `label`, `value`, `value_type`, `type`, `l -- 表的结构 `hg_sys_dict_type` -- -CREATE TABLE `hg_sys_dict_type` ( - `id` bigint(20) NOT NULL COMMENT '字典类型ID', - `pid` bigint(20) NOT NULL COMMENT '父类字典类型ID', +CREATE TABLE IF NOT EXISTS `hg_sys_dict_type` ( + `id` bigint NOT NULL COMMENT '字典类型ID', + `pid` bigint NOT NULL COMMENT '父类字典类型ID', `name` varchar(100) DEFAULT '' COMMENT '字典类型名称', `type` varchar(100) DEFAULT '' COMMENT '字典类型', - `sort` int(11) DEFAULT '0' COMMENT '排序', + `sort` int DEFAULT '0' COMMENT '排序', `remark` varchar(500) DEFAULT NULL COMMENT '备注', `status` tinyint(1) DEFAULT '1' COMMENT '字典类型状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_字典类型'; +) ENGINE=InnoDB AUTO_INCREMENT=39 DEFAULT CHARSET=utf8mb3 COMMENT='系统_字典类型'; -- -- 转存表中的数据 `hg_sys_dict_type` @@ -1840,25 +1853,25 @@ INSERT INTO `hg_sys_dict_type` (`id`, `pid`, `name`, `type`, `sort`, `remark`, ` -- 表的结构 `hg_sys_ems_log` -- -CREATE TABLE `hg_sys_ems_log` ( - `id` bigint(20) NOT NULL COMMENT '主键', +CREATE TABLE IF NOT EXISTS `hg_sys_ems_log` ( + `id` bigint NOT NULL COMMENT '主键', `event` varchar(64) NOT NULL COMMENT '事件', `email` varchar(512) NOT NULL COMMENT '邮箱地址,多个用;隔开', `code` varchar(256) DEFAULT '' COMMENT '验证码', - `times` bigint(20) NOT NULL COMMENT '验证次数', + `times` bigint NOT NULL COMMENT '验证次数', `content` longtext COMMENT '邮件内容', `ip` varchar(128) DEFAULT NULL COMMENT 'ip地址', `status` tinyint(1) DEFAULT '1' COMMENT '状态(1未验证,2已验证)', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_邮件发送记录'; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COMMENT='系统_邮件发送记录'; -- -- 转存表中的数据 `hg_sys_ems_log` -- INSERT INTO `hg_sys_ems_log` (`id`, `event`, `email`, `code`, `times`, `content`, `ip`, `status`, `created_at`, `updated_at`) VALUES -(4, 'bind', '133814250@qq.com', '8793', 1, '\r\n\r\n\r\n \r\n \r\n \r\n \r\n 验证码邮件\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 这是你发送的验证码吗?\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n Windows 10
\r\n 保留地址 (estimated)
\r\n IP 地址: 127**.0.1\r\n

\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 如果是,请输入验证码:\r\n

\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 8793\r\n

\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 该验证码10分钟内有效,请不要告诉于他人!\r\n

\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n', '39.165.245.100', 2, '2023-02-04 16:49:39', '2023-02-04 16:56:24'); +(4, 'bind', '133814250@qq.com', '8793', 1, '\r\n\r\n\r\n \r\n \r\n \r\n \r\n 验证码邮件\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 这是你发送的验证码吗?\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n Windows 10
\r\n 保留地址 (estimated)
\r\n IP 地址: 127**.0.1\r\n

\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 如果是,请输入验证码:\r\n

\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 8793\r\n

\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 该验证码10分钟内有效,请不要告诉于他人!\r\n

\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n', '39.165.245.100', 2, '2023-02-04 16:49:39', '2023-02-04 16:56:24'); -- -------------------------------------------------------- @@ -1866,10 +1879,10 @@ INSERT INTO `hg_sys_ems_log` (`id`, `event`, `email`, `code`, `times`, `content` -- 表的结构 `hg_sys_gen_codes` -- -CREATE TABLE `hg_sys_gen_codes` ( - `id` bigint(20) NOT NULL COMMENT '生成ID', - `gen_type` int(10) UNSIGNED NOT NULL COMMENT '生成类型', - `gen_template` int(11) DEFAULT '0' COMMENT '生成模板', +CREATE TABLE IF NOT EXISTS `hg_sys_gen_codes` ( + `id` bigint NOT NULL COMMENT '生成ID', + `gen_type` int unsigned NOT NULL COMMENT '生成类型', + `gen_template` int DEFAULT '0' COMMENT '生成模板', `var_name` varchar(255) NOT NULL COMMENT '实体命名', `options` json DEFAULT NULL COMMENT '配置选项', `db_name` varchar(128) DEFAULT NULL COMMENT '数据库名称', @@ -1881,14 +1894,14 @@ CREATE TABLE `hg_sys_gen_codes` ( `status` tinyint(1) DEFAULT '1' COMMENT '生成状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_代码生成记录'; +) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb3 COMMENT='系统_代码生成记录'; -- -- 转存表中的数据 `hg_sys_gen_codes` -- INSERT INTO `hg_sys_gen_codes` (`id`, `gen_type`, `gen_template`, `var_name`, `options`, `db_name`, `table_name`, `table_comment`, `dao_name`, `master_columns`, `addon_name`, `status`, `created_at`, `updated_at`) VALUES -(1, 10, 0, 'CurdDemo', '{\"join\": [{\"uuid\": \"pgJsFoqfaGjqgKjy\", \"alias\": \"testCategory\", \"field\": \"id\", \"columns\": [{\"dc\": \"分类ID\", \"id\": 1, \"name\": \"id\", \"extra\": \"auto_increment\", \"index\": \"PRI\", \"goName\": \"TestCategoryId\", \"goType\": \"int64\", \"isEdit\": false, \"isList\": false, \"isSort\": false, \"length\": 0, \"tsName\": \"testCategoryId\", \"tsType\": \"number\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"bigint(20)\", \"dataType\": \"bigint\", \"dictType\": 0, \"formMode\": \"\", \"formRole\": \"\", \"isExport\": false, \"required\": false, \"queryWhere\": \"=\", \"isAllowNull\": \"NO\", \"defaultValue\": 0}, {\"dc\": \"分类名称\", \"id\": 2, \"name\": \"name\", \"extra\": \"\", \"index\": \"\", \"goName\": \"TestCategoryName\", \"goType\": \"string\", \"isEdit\": false, \"isList\": true, \"isSort\": false, \"length\": 255, \"tsName\": \"testCategoryName\", \"tsType\": \"string\", \"unique\": false, \"isQuery\": true, \"sqlType\": \"varchar(255)\", \"dataType\": \"varchar\", \"dictType\": 0, \"formMode\": \"\", \"formRole\": \"\", \"isExport\": true, \"required\": false, \"queryWhere\": \"LIKE\", \"isAllowNull\": \"NO\", \"defaultValue\": \"\"}, {\"dc\": \"描述\", \"id\": 3, \"name\": \"description\", \"extra\": \"\", \"index\": \"\", \"goName\": \"TestCategoryDescription\", \"goType\": \"string\", \"isEdit\": false, \"isList\": false, \"isSort\": false, \"length\": 255, \"tsName\": \"testCategoryDescription\", \"tsType\": \"string\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"varchar(255)\", \"dataType\": \"varchar\", \"dictType\": 0, \"formMode\": \"\", \"formRole\": \"\", \"isExport\": false, \"required\": false, \"queryWhere\": \"LIKE\", \"isAllowNull\": \"YES\", \"defaultValue\": \"\"}, {\"dc\": \"排序\", \"id\": 4, \"name\": \"sort\", \"extra\": \"\", \"index\": \"\", \"goName\": \"TestCategorySort\", \"goType\": \"int\", \"isEdit\": false, \"isList\": false, \"isSort\": false, \"length\": 0, \"tsName\": \"testCategorySort\", \"tsType\": \"number\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"int(11)\", \"dataType\": \"int\", \"dictType\": 0, \"formMode\": \"\", \"formRole\": \"\", \"isExport\": false, \"required\": false, \"queryWhere\": \"=\", \"isAllowNull\": \"NO\", \"defaultValue\": 0}, {\"dc\": \"备注\", \"id\": 5, \"name\": \"remark\", \"extra\": \"\", \"index\": \"\", \"goName\": \"TestCategoryRemark\", \"goType\": \"string\", \"isEdit\": false, \"isList\": false, \"isSort\": false, \"length\": 255, \"tsName\": \"testCategoryRemark\", \"tsType\": \"string\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"varchar(255)\", \"dataType\": \"varchar\", \"dictType\": 0, \"formMode\": \"\", \"formRole\": \"\", \"isExport\": false, \"required\": false, \"queryWhere\": \"LIKE\", \"isAllowNull\": \"YES\", \"defaultValue\": \"\"}, {\"dc\": \"状态\", \"id\": 6, \"name\": \"status\", \"extra\": \"\", \"index\": \"\", \"goName\": \"TestCategoryStatus\", \"goType\": \"int\", \"isEdit\": false, \"isList\": false, \"isSort\": false, \"length\": 0, \"tsName\": \"testCategoryStatus\", \"tsType\": \"number\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"tinyint(1)\", \"dataType\": \"tinyint\", \"dictType\": 0, \"formMode\": \"\", \"formRole\": \"\", \"isExport\": false, \"required\": false, \"queryWhere\": \"=\", \"isAllowNull\": \"YES\", \"defaultValue\": 1}, {\"dc\": \"创建时间\", \"id\": 7, \"name\": \"created_at\", \"extra\": \"\", \"index\": \"\", \"goName\": \"TestCategoryCreatedAt\", \"goType\": \"*gtime.Time\", \"isEdit\": false, \"isList\": false, \"isSort\": false, \"length\": 0, \"tsName\": \"testCategoryCreatedAt\", \"tsType\": \"string\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"datetime\", \"dataType\": \"datetime\", \"dictType\": 0, \"formMode\": \"\", \"formRole\": \"\", \"isExport\": false, \"required\": false, \"queryWhere\": \"=\", \"isAllowNull\": \"YES\", \"defaultValue\": \"\"}, {\"dc\": \"修改时间\", \"id\": 8, \"name\": \"updated_at\", \"extra\": \"\", \"index\": \"\", \"goName\": \"TestCategoryUpdatedAt\", \"goType\": \"*gtime.Time\", \"isEdit\": false, \"isList\": false, \"isSort\": false, \"length\": 0, \"tsName\": \"testCategoryUpdatedAt\", \"tsType\": \"string\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"datetime\", \"dataType\": \"datetime\", \"dictType\": 0, \"formMode\": \"\", \"formRole\": \"\", \"isExport\": false, \"required\": false, \"queryWhere\": \"=\", \"isAllowNull\": \"YES\", \"defaultValue\": \"\"}, {\"dc\": \"删除时间\", \"id\": 9, \"name\": \"deleted_at\", \"extra\": \"\", \"index\": \"\", \"goName\": \"TestCategoryDeletedAt\", \"goType\": \"*gtime.Time\", \"isEdit\": false, \"isList\": false, \"isSort\": false, \"length\": 0, \"tsName\": \"testCategoryDeletedAt\", \"tsType\": \"string\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"datetime\", \"dataType\": \"datetime\", \"dictType\": 0, \"formMode\": \"\", \"formRole\": \"\", \"isExport\": false, \"required\": false, \"queryWhere\": \"=\", \"isAllowNull\": \"YES\", \"defaultValue\": \"\"}], \"daoName\": \"TestCategory\", \"linkMode\": 1, \"linkTable\": \"hg_test_category\", \"masterField\": \"category_id\"}], \"menu\": {\"pid\": 2097, \"icon\": \"MenuOutlined\", \"sort\": 200}, \"autoOps\": [\"genMenuPermissions\", \"runDao\", \"runService\", \"forcedCover\"], \"headOps\": [\"add\", \"batchDel\", \"export\"], \"columnOps\": [\"edit\", \"del\", \"view\", \"status\", \"switch\", \"check\"]}', 'default', 'hg_sys_gen_curd_demo', '生成演示', 'SysGenCurdDemo', '[{\"dc\": \"ID\", \"id\": 1, \"name\": \"id\", \"extra\": \"auto_increment\", \"index\": \"PRI\", \"goName\": \"Id\", \"goType\": \"int64\", \"isEdit\": false, \"isList\": true, \"isSort\": true, \"length\": 0, \"tsName\": \"id\", \"tsType\": \"number\", \"unique\": false, \"isQuery\": true, \"sqlType\": \"bigint(20)\", \"dataType\": \"bigint\", \"dictType\": 0, \"formMode\": \"InputNumber\", \"formRole\": \"none\", \"isExport\": true, \"required\": true, \"queryWhere\": \"=\", \"isAllowNull\": \"NO\", \"defaultValue\": 0}, {\"dc\": \"分类ID\", \"id\": 2, \"name\": \"category_id\", \"extra\": \"\", \"index\": \"\", \"goName\": \"CategoryId\", \"goType\": \"int64\", \"isEdit\": true, \"isList\": true, \"isSort\": false, \"length\": 0, \"tsName\": \"categoryId\", \"tsType\": \"number\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"bigint(20)\", \"dataType\": \"bigint\", \"dictType\": 0, \"formMode\": \"InputNumber\", \"formRole\": \"none\", \"isExport\": true, \"required\": true, \"queryWhere\": \"=\", \"isAllowNull\": \"NO\", \"defaultValue\": 0}, {\"dc\": \"标题\", \"id\": 3, \"name\": \"title\", \"extra\": \"\", \"index\": \"\", \"goName\": \"Title\", \"goType\": \"string\", \"isEdit\": true, \"isList\": true, \"isSort\": false, \"length\": 64, \"tsName\": \"title\", \"tsType\": \"string\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"varchar(64)\", \"dataType\": \"varchar\", \"dictType\": 0, \"formMode\": \"Input\", \"formRole\": \"none\", \"isExport\": true, \"required\": true, \"queryWhere\": \"LIKE\", \"isAllowNull\": \"NO\", \"defaultValue\": \"\"}, {\"dc\": \"描述\", \"id\": 4, \"name\": \"description\", \"extra\": \"\", \"index\": \"\", \"goName\": \"Description\", \"goType\": \"string\", \"isEdit\": true, \"isList\": true, \"isSort\": false, \"length\": 255, \"tsName\": \"description\", \"tsType\": \"string\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"varchar(255)\", \"dataType\": \"varchar\", \"dictType\": 0, \"formMode\": \"InputTextarea\", \"formRole\": \"none\", \"isExport\": true, \"required\": true, \"queryWhere\": \"LIKE\", \"isAllowNull\": \"NO\", \"defaultValue\": \"\"}, {\"dc\": \"内容\", \"id\": 5, \"name\": \"content\", \"extra\": \"\", \"index\": \"\", \"goName\": \"Content\", \"goType\": \"string\", \"isEdit\": true, \"isList\": false, \"isSort\": false, \"length\": 65535, \"tsName\": \"content\", \"tsType\": \"string\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"text\", \"dataType\": \"text\", \"dictType\": 0, \"formMode\": \"InputEditor\", \"formRole\": \"none\", \"isExport\": false, \"required\": true, \"queryWhere\": \"LIKE %...%\", \"isAllowNull\": \"NO\", \"defaultValue\": \"\"}, {\"dc\": \"单图\", \"id\": 6, \"name\": \"image\", \"extra\": \"\", \"index\": \"\", \"goName\": \"Image\", \"goType\": \"string\", \"isEdit\": true, \"isList\": true, \"isSort\": false, \"length\": 255, \"tsName\": \"image\", \"tsType\": \"string\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"varchar(255)\", \"dataType\": \"varchar\", \"dictType\": 0, \"formMode\": \"UploadImage\", \"formRole\": \"none\", \"isExport\": true, \"required\": false, \"queryWhere\": \"LIKE\", \"isAllowNull\": \"YES\", \"defaultValue\": \"\"}, {\"dc\": \"附件\", \"id\": 7, \"name\": \"attachfile\", \"extra\": \"\", \"index\": \"\", \"goName\": \"Attachfile\", \"goType\": \"string\", \"isEdit\": true, \"isList\": true, \"isSort\": false, \"length\": 255, \"tsName\": \"attachfile\", \"tsType\": \"string\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"varchar(255)\", \"dataType\": \"varchar\", \"dictType\": 0, \"formMode\": \"UploadFile\", \"formRole\": \"none\", \"isExport\": true, \"required\": false, \"queryWhere\": \"LIKE\", \"isAllowNull\": \"YES\", \"defaultValue\": \"\"}, {\"dc\": \"所在城市\", \"id\": 8, \"name\": \"city_id\", \"extra\": \"\", \"index\": \"\", \"goName\": \"CityId\", \"goType\": \"int64\", \"isEdit\": true, \"isList\": true, \"isSort\": false, \"length\": 0, \"tsName\": \"cityId\", \"tsType\": \"number\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"bigint(20)\", \"dataType\": \"bigint\", \"dictType\": 0, \"formMode\": \"CitySelector\", \"formRole\": \"none\", \"isExport\": true, \"required\": false, \"queryWhere\": \"=\", \"isAllowNull\": \"YES\", \"defaultValue\": 0}, {\"dc\": \"显示开关\", \"id\": 9, \"name\": \"switch\", \"extra\": \"\", \"index\": \"\", \"goName\": \"Switch\", \"goType\": \"int\", \"isEdit\": true, \"isList\": true, \"isSort\": false, \"length\": 0, \"tsName\": \"switch\", \"tsType\": \"number\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"int(11)\", \"dataType\": \"int\", \"dictType\": 0, \"formMode\": \"Switch\", \"formRole\": \"none\", \"isExport\": true, \"required\": false, \"queryWhere\": \"=\", \"isAllowNull\": \"YES\", \"defaultValue\": 1}, {\"dc\": \"排序\", \"id\": 10, \"name\": \"sort\", \"extra\": \"\", \"index\": \"\", \"goName\": \"Sort\", \"goType\": \"int\", \"isEdit\": true, \"isList\": true, \"isSort\": true, \"length\": 0, \"tsName\": \"sort\", \"tsType\": \"number\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"int(11)\", \"dataType\": \"int\", \"dictType\": 0, \"formMode\": \"InputNumber\", \"formRole\": \"none\", \"isExport\": true, \"required\": true, \"queryWhere\": \"=\", \"isAllowNull\": \"NO\", \"defaultValue\": 0}, {\"dc\": \"状态\", \"id\": 11, \"name\": \"status\", \"extra\": \"\", \"index\": \"\", \"goName\": \"Status\", \"goType\": \"int\", \"isEdit\": true, \"isList\": true, \"isSort\": false, \"length\": 0, \"tsName\": \"status\", \"tsType\": \"number\", \"unique\": false, \"isQuery\": true, \"sqlType\": \"tinyint(1)\", \"dataType\": \"tinyint\", \"dictType\": 3, \"formMode\": \"Select\", \"formRole\": \"none\", \"isExport\": true, \"required\": false, \"queryWhere\": \"=\", \"isAllowNull\": \"YES\", \"defaultValue\": 1}, {\"dc\": \"创建者\", \"id\": 12, \"name\": \"created_by\", \"extra\": \"\", \"index\": \"\", \"goName\": \"CreatedBy\", \"goType\": \"int64\", \"isEdit\": false, \"isList\": true, \"isSort\": false, \"length\": 0, \"tsName\": \"createdBy\", \"tsType\": \"number\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"bigint(20)\", \"dataType\": \"bigint\", \"dictType\": 0, \"formMode\": \"InputNumber\", \"formRole\": \"none\", \"isExport\": true, \"required\": false, \"queryWhere\": \"=\", \"isAllowNull\": \"YES\", \"defaultValue\": 0}, {\"dc\": \"更新者\", \"id\": 13, \"name\": \"updated_by\", \"extra\": \"\", \"index\": \"\", \"goName\": \"UpdatedBy\", \"goType\": \"int64\", \"isEdit\": false, \"isList\": true, \"isSort\": false, \"length\": 0, \"tsName\": \"updatedBy\", \"tsType\": \"number\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"bigint(20)\", \"dataType\": \"bigint\", \"dictType\": 0, \"formMode\": \"InputNumber\", \"formRole\": \"none\", \"isExport\": true, \"required\": false, \"queryWhere\": \"=\", \"isAllowNull\": \"YES\", \"defaultValue\": 0}, {\"dc\": \"创建时间\", \"id\": 14, \"name\": \"created_at\", \"extra\": \"\", \"index\": \"\", \"goName\": \"CreatedAt\", \"goType\": \"*gtime.Time\", \"isEdit\": false, \"isList\": true, \"isSort\": false, \"length\": 0, \"tsName\": \"createdAt\", \"tsType\": \"string\", \"unique\": false, \"isQuery\": true, \"sqlType\": \"datetime\", \"dataType\": \"datetime\", \"dictType\": 0, \"formMode\": \"TimeRange\", \"formRole\": \"none\", \"isExport\": true, \"required\": false, \"queryWhere\": \"BETWEEN\", \"isAllowNull\": \"YES\", \"defaultValue\": \"\"}, {\"dc\": \"修改时间\", \"id\": 15, \"name\": \"updated_at\", \"extra\": \"\", \"index\": \"\", \"goName\": \"UpdatedAt\", \"goType\": \"*gtime.Time\", \"isEdit\": false, \"isList\": true, \"isSort\": false, \"length\": 0, \"tsName\": \"updatedAt\", \"tsType\": \"string\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"datetime\", \"dataType\": \"datetime\", \"dictType\": 0, \"formMode\": \"Time\", \"formRole\": \"none\", \"isExport\": true, \"required\": false, \"queryWhere\": \"=\", \"isAllowNull\": \"YES\", \"defaultValue\": \"\"}, {\"dc\": \"删除时间\", \"id\": 16, \"name\": \"deleted_at\", \"extra\": \"\", \"index\": \"\", \"goName\": \"DeletedAt\", \"goType\": \"*gtime.Time\", \"isEdit\": false, \"isList\": false, \"isSort\": false, \"length\": 0, \"tsName\": \"deletedAt\", \"tsType\": \"string\", \"unique\": false, \"isQuery\": false, \"sqlType\": \"datetime\", \"dataType\": \"datetime\", \"dictType\": 0, \"formMode\": \"Time\", \"formRole\": \"none\", \"isExport\": false, \"required\": false, \"queryWhere\": \"=\", \"isAllowNull\": \"YES\", \"defaultValue\": \"\"}]', '', 1, '2023-01-18 11:51:22', '2023-07-20 15:25:46'); +(1, 10, 0, 'CurdDemo', '{"join": [{"uuid": "pgJsFoqfaGjqgKjy", "alias": "testCategory", "field": "id", "columns": [{"dc": "分类ID", "id": 1, "name": "id", "extra": "auto_increment", "index": "PRI", "goName": "TestCategoryId", "goType": "int64", "isEdit": false, "isList": false, "isSort": false, "length": 0, "tsName": "testCategoryId", "tsType": "number", "unique": false, "isQuery": false, "sqlType": "bigint(20)", "dataType": "bigint", "dictType": 0, "formMode": "", "formRole": "", "isExport": false, "required": false, "queryWhere": "=", "isAllowNull": "NO", "defaultValue": 0}, {"dc": "分类名称", "id": 2, "name": "name", "extra": "", "index": "", "goName": "TestCategoryName", "goType": "string", "isEdit": false, "isList": true, "isSort": false, "length": 255, "tsName": "testCategoryName", "tsType": "string", "unique": false, "isQuery": true, "sqlType": "varchar(255)", "dataType": "varchar", "dictType": 0, "formMode": "", "formRole": "", "isExport": true, "required": false, "queryWhere": "LIKE", "isAllowNull": "NO", "defaultValue": ""}, {"dc": "描述", "id": 3, "name": "description", "extra": "", "index": "", "goName": "TestCategoryDescription", "goType": "string", "isEdit": false, "isList": false, "isSort": false, "length": 255, "tsName": "testCategoryDescription", "tsType": "string", "unique": false, "isQuery": false, "sqlType": "varchar(255)", "dataType": "varchar", "dictType": 0, "formMode": "", "formRole": "", "isExport": false, "required": false, "queryWhere": "LIKE", "isAllowNull": "YES", "defaultValue": ""}, {"dc": "排序", "id": 4, "name": "sort", "extra": "", "index": "", "goName": "TestCategorySort", "goType": "int", "isEdit": false, "isList": false, "isSort": false, "length": 0, "tsName": "testCategorySort", "tsType": "number", "unique": false, "isQuery": false, "sqlType": "int(11)", "dataType": "int", "dictType": 0, "formMode": "", "formRole": "", "isExport": false, "required": false, "queryWhere": "=", "isAllowNull": "NO", "defaultValue": 0}, {"dc": "备注", "id": 5, "name": "remark", "extra": "", "index": "", "goName": "TestCategoryRemark", "goType": "string", "isEdit": false, "isList": false, "isSort": false, "length": 255, "tsName": "testCategoryRemark", "tsType": "string", "unique": false, "isQuery": false, "sqlType": "varchar(255)", "dataType": "varchar", "dictType": 0, "formMode": "", "formRole": "", "isExport": false, "required": false, "queryWhere": "LIKE", "isAllowNull": "YES", "defaultValue": ""}, {"dc": "状态", "id": 6, "name": "status", "extra": "", "index": "", "goName": "TestCategoryStatus", "goType": "int", "isEdit": false, "isList": false, "isSort": false, "length": 0, "tsName": "testCategoryStatus", "tsType": "number", "unique": false, "isQuery": false, "sqlType": "tinyint(1)", "dataType": "tinyint", "dictType": 0, "formMode": "", "formRole": "", "isExport": false, "required": false, "queryWhere": "=", "isAllowNull": "YES", "defaultValue": 1}, {"dc": "创建时间", "id": 7, "name": "created_at", "extra": "", "index": "", "goName": "TestCategoryCreatedAt", "goType": "*gtime.Time", "isEdit": false, "isList": false, "isSort": false, "length": 0, "tsName": "testCategoryCreatedAt", "tsType": "string", "unique": false, "isQuery": false, "sqlType": "datetime", "dataType": "datetime", "dictType": 0, "formMode": "", "formRole": "", "isExport": false, "required": false, "queryWhere": "=", "isAllowNull": "YES", "defaultValue": ""}, {"dc": "修改时间", "id": 8, "name": "updated_at", "extra": "", "index": "", "goName": "TestCategoryUpdatedAt", "goType": "*gtime.Time", "isEdit": false, "isList": false, "isSort": false, "length": 0, "tsName": "testCategoryUpdatedAt", "tsType": "string", "unique": false, "isQuery": false, "sqlType": "datetime", "dataType": "datetime", "dictType": 0, "formMode": "", "formRole": "", "isExport": false, "required": false, "queryWhere": "=", "isAllowNull": "YES", "defaultValue": ""}, {"dc": "删除时间", "id": 9, "name": "deleted_at", "extra": "", "index": "", "goName": "TestCategoryDeletedAt", "goType": "*gtime.Time", "isEdit": false, "isList": false, "isSort": false, "length": 0, "tsName": "testCategoryDeletedAt", "tsType": "string", "unique": false, "isQuery": false, "sqlType": "datetime", "dataType": "datetime", "dictType": 0, "formMode": "", "formRole": "", "isExport": false, "required": false, "queryWhere": "=", "isAllowNull": "YES", "defaultValue": ""}], "daoName": "TestCategory", "linkMode": 1, "linkTable": "hg_test_category", "masterField": "category_id"}], "menu": {"pid": 2097, "icon": "MenuOutlined", "sort": 200}, "autoOps": ["genMenuPermissions", "runDao", "runService", "forcedCover"], "headOps": ["add", "batchDel", "export"], "columnOps": ["edit", "del", "view", "status", "switch", "check"]}', 'default', 'hg_sys_gen_curd_demo', '生成演示', 'SysGenCurdDemo', '[{"dc": "ID", "id": 1, "name": "id", "extra": "auto_increment", "index": "PRI", "goName": "Id", "goType": "int64", "isEdit": false, "isList": true, "isSort": true, "length": 0, "tsName": "id", "tsType": "number", "unique": false, "isQuery": true, "sqlType": "bigint(20)", "dataType": "bigint", "dictType": 0, "formMode": "InputNumber", "formRole": "none", "isExport": true, "required": true, "queryWhere": "=", "isAllowNull": "NO", "defaultValue": 0}, {"dc": "分类ID", "id": 2, "name": "category_id", "extra": "", "index": "", "goName": "CategoryId", "goType": "int64", "isEdit": true, "isList": true, "isSort": false, "length": 0, "tsName": "categoryId", "tsType": "number", "unique": false, "isQuery": false, "sqlType": "bigint(20)", "dataType": "bigint", "dictType": 0, "formMode": "InputNumber", "formRole": "none", "isExport": true, "required": true, "queryWhere": "=", "isAllowNull": "NO", "defaultValue": 0}, {"dc": "标题", "id": 3, "name": "title", "extra": "", "index": "", "goName": "Title", "goType": "string", "isEdit": true, "isList": true, "isSort": false, "length": 64, "tsName": "title", "tsType": "string", "unique": false, "isQuery": false, "sqlType": "varchar(64)", "dataType": "varchar", "dictType": 0, "formMode": "Input", "formRole": "none", "isExport": true, "required": true, "queryWhere": "LIKE", "isAllowNull": "NO", "defaultValue": ""}, {"dc": "描述", "id": 4, "name": "description", "extra": "", "index": "", "goName": "Description", "goType": "string", "isEdit": true, "isList": true, "isSort": false, "length": 255, "tsName": "description", "tsType": "string", "unique": false, "isQuery": false, "sqlType": "varchar(255)", "dataType": "varchar", "dictType": 0, "formMode": "InputTextarea", "formRole": "none", "isExport": true, "required": true, "queryWhere": "LIKE", "isAllowNull": "NO", "defaultValue": ""}, {"dc": "内容", "id": 5, "name": "content", "extra": "", "index": "", "goName": "Content", "goType": "string", "isEdit": true, "isList": false, "isSort": false, "length": 65535, "tsName": "content", "tsType": "string", "unique": false, "isQuery": false, "sqlType": "text", "dataType": "text", "dictType": 0, "formMode": "InputEditor", "formRole": "none", "isExport": false, "required": true, "queryWhere": "LIKE %...%", "isAllowNull": "NO", "defaultValue": ""}, {"dc": "单图", "id": 6, "name": "image", "extra": "", "index": "", "goName": "Image", "goType": "string", "isEdit": true, "isList": true, "isSort": false, "length": 255, "tsName": "image", "tsType": "string", "unique": false, "isQuery": false, "sqlType": "varchar(255)", "dataType": "varchar", "dictType": 0, "formMode": "UploadImage", "formRole": "none", "isExport": true, "required": false, "queryWhere": "LIKE", "isAllowNull": "YES", "defaultValue": ""}, {"dc": "附件", "id": 7, "name": "attachfile", "extra": "", "index": "", "goName": "Attachfile", "goType": "string", "isEdit": true, "isList": true, "isSort": false, "length": 255, "tsName": "attachfile", "tsType": "string", "unique": false, "isQuery": false, "sqlType": "varchar(255)", "dataType": "varchar", "dictType": 0, "formMode": "UploadFile", "formRole": "none", "isExport": true, "required": false, "queryWhere": "LIKE", "isAllowNull": "YES", "defaultValue": ""}, {"dc": "所在城市", "id": 8, "name": "city_id", "extra": "", "index": "", "goName": "CityId", "goType": "int64", "isEdit": true, "isList": true, "isSort": false, "length": 0, "tsName": "cityId", "tsType": "number", "unique": false, "isQuery": false, "sqlType": "bigint(20)", "dataType": "bigint", "dictType": 0, "formMode": "CitySelector", "formRole": "none", "isExport": true, "required": false, "queryWhere": "=", "isAllowNull": "YES", "defaultValue": 0}, {"dc": "显示开关", "id": 9, "name": "switch", "extra": "", "index": "", "goName": "Switch", "goType": "int", "isEdit": true, "isList": true, "isSort": false, "length": 0, "tsName": "switch", "tsType": "number", "unique": false, "isQuery": false, "sqlType": "int(11)", "dataType": "int", "dictType": 0, "formMode": "Switch", "formRole": "none", "isExport": true, "required": false, "queryWhere": "=", "isAllowNull": "YES", "defaultValue": 1}, {"dc": "排序", "id": 10, "name": "sort", "extra": "", "index": "", "goName": "Sort", "goType": "int", "isEdit": true, "isList": true, "isSort": true, "length": 0, "tsName": "sort", "tsType": "number", "unique": false, "isQuery": false, "sqlType": "int(11)", "dataType": "int", "dictType": 0, "formMode": "InputNumber", "formRole": "none", "isExport": true, "required": true, "queryWhere": "=", "isAllowNull": "NO", "defaultValue": 0}, {"dc": "状态", "id": 11, "name": "status", "extra": "", "index": "", "goName": "Status", "goType": "int", "isEdit": true, "isList": true, "isSort": false, "length": 0, "tsName": "status", "tsType": "number", "unique": false, "isQuery": true, "sqlType": "tinyint(1)", "dataType": "tinyint", "dictType": 3, "formMode": "Select", "formRole": "none", "isExport": true, "required": false, "queryWhere": "=", "isAllowNull": "YES", "defaultValue": 1}, {"dc": "创建者", "id": 12, "name": "created_by", "extra": "", "index": "", "goName": "CreatedBy", "goType": "int64", "isEdit": false, "isList": true, "isSort": false, "length": 0, "tsName": "createdBy", "tsType": "number", "unique": false, "isQuery": false, "sqlType": "bigint(20)", "dataType": "bigint", "dictType": 0, "formMode": "InputNumber", "formRole": "none", "isExport": true, "required": false, "queryWhere": "=", "isAllowNull": "YES", "defaultValue": 0}, {"dc": "更新者", "id": 13, "name": "updated_by", "extra": "", "index": "", "goName": "UpdatedBy", "goType": "int64", "isEdit": false, "isList": true, "isSort": false, "length": 0, "tsName": "updatedBy", "tsType": "number", "unique": false, "isQuery": false, "sqlType": "bigint(20)", "dataType": "bigint", "dictType": 0, "formMode": "InputNumber", "formRole": "none", "isExport": true, "required": false, "queryWhere": "=", "isAllowNull": "YES", "defaultValue": 0}, {"dc": "创建时间", "id": 14, "name": "created_at", "extra": "", "index": "", "goName": "CreatedAt", "goType": "*gtime.Time", "isEdit": false, "isList": true, "isSort": false, "length": 0, "tsName": "createdAt", "tsType": "string", "unique": false, "isQuery": true, "sqlType": "datetime", "dataType": "datetime", "dictType": 0, "formMode": "TimeRange", "formRole": "none", "isExport": true, "required": false, "queryWhere": "BETWEEN", "isAllowNull": "YES", "defaultValue": ""}, {"dc": "修改时间", "id": 15, "name": "updated_at", "extra": "", "index": "", "goName": "UpdatedAt", "goType": "*gtime.Time", "isEdit": false, "isList": true, "isSort": false, "length": 0, "tsName": "updatedAt", "tsType": "string", "unique": false, "isQuery": false, "sqlType": "datetime", "dataType": "datetime", "dictType": 0, "formMode": "Time", "formRole": "none", "isExport": true, "required": false, "queryWhere": "=", "isAllowNull": "YES", "defaultValue": ""}, {"dc": "删除时间", "id": 16, "name": "deleted_at", "extra": "", "index": "", "goName": "DeletedAt", "goType": "*gtime.Time", "isEdit": false, "isList": false, "isSort": false, "length": 0, "tsName": "deletedAt", "tsType": "string", "unique": false, "isQuery": false, "sqlType": "datetime", "dataType": "datetime", "dictType": 0, "formMode": "Time", "formRole": "none", "isExport": false, "required": false, "queryWhere": "=", "isAllowNull": "YES", "defaultValue": ""}]', '', 1, '2023-01-18 11:51:22', '2023-11-16 11:00:11'); -- -------------------------------------------------------- @@ -1896,31 +1909,42 @@ INSERT INTO `hg_sys_gen_codes` (`id`, `gen_type`, `gen_template`, `var_name`, `o -- 表的结构 `hg_sys_gen_curd_demo` -- -CREATE TABLE `hg_sys_gen_curd_demo` ( - `id` bigint(20) NOT NULL COMMENT 'ID', - `category_id` bigint(20) NOT NULL COMMENT '分类ID', +CREATE TABLE IF NOT EXISTS `hg_sys_gen_curd_demo` ( + `id` bigint NOT NULL COMMENT 'ID', + `category_id` bigint NOT NULL COMMENT '分类ID', `title` varchar(64) NOT NULL COMMENT '标题', `description` varchar(255) NOT NULL COMMENT '描述', `content` text NOT NULL COMMENT '内容', `image` varchar(255) DEFAULT NULL COMMENT '单图', `attachfile` varchar(255) DEFAULT NULL COMMENT '附件', - `city_id` bigint(20) DEFAULT '0' COMMENT '所在城市', - `switch` int(11) DEFAULT '1' COMMENT '显示开关', - `sort` int(11) NOT NULL COMMENT '排序', + `city_id` bigint DEFAULT '0' COMMENT '所在城市', + `switch` int DEFAULT '1' COMMENT '显示开关', + `sort` int NOT NULL COMMENT '排序', `status` tinyint(1) DEFAULT '1' COMMENT '状态', - `created_by` bigint(20) DEFAULT '0' COMMENT '创建者', - `updated_by` bigint(20) DEFAULT '0' COMMENT '更新者', + `created_by` bigint DEFAULT '0' COMMENT '创建者', + `updated_by` bigint DEFAULT '0' COMMENT '更新者', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '修改时间', `deleted_at` datetime DEFAULT NULL COMMENT '删除时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_生成curd演示'; +) ENGINE=InnoDB AUTO_INCREMENT=13 DEFAULT CHARSET=utf8mb3 COMMENT='系统_生成curd演示'; -- -- 转存表中的数据 `hg_sys_gen_curd_demo` -- INSERT INTO `hg_sys_gen_curd_demo` (`id`, `category_id`, `title`, `description`, `content`, `image`, `attachfile`, `city_id`, `switch`, `sort`, `status`, `created_by`, `updated_by`, `created_at`, `updated_at`, `deleted_at`) VALUES -(1, 1, '测试标题', '描述', '

不知道写点啥!



', 'https://bufanyun.cn-bj.ufileos.com/hotgo/logo.sig.png', 'http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2022-12-30/cpf1x44idoycrtajf2.xlsx', 110102, 1, 10, 1, 0, 1, '2022-12-15 19:30:14', '2023-07-06 20:31:29', NULL); +(1, 1, '测试标题', '描述', '

不知道写点啥!



', 'https://bufanyun.cn-bj.ufileos.com/hotgo/logo.sig.png', 'http://bufanyun.cn-bj.ufileos.com/hotgo/attachment/2022-12-30/cpf1x44idoycrtajf2.xlsx', 110102, 1, 10, 1, 0, 1, '2022-12-15 19:30:14', '2023-10-21 14:34:27', NULL), +(2, 0, '1', '1', '

1

', '', '', 150404, 1, 20, 1, 1, 0, '2023-11-16 10:08:29', '2023-11-16 10:08:29', '2023-11-16 10:09:20'), +(3, 0, '1221', '212', '

1

', '', '', 0, 1, 30, 1, 1, 0, '2023-11-16 10:09:07', '2023-11-16 10:09:07', '2023-11-16 10:09:15'), +(4, 0, '12', '12', '

12

', '', '', 120101, 1, 20, 1, 1, 0, '2023-11-16 10:09:45', '2023-11-16 10:09:45', '2023-11-16 10:10:12'), +(5, 0, '12', '1212', '

1221

', '', '', 150421, 1, 30, 1, 1, 0, '2023-11-16 10:09:56', '2023-11-16 10:09:56', '2023-11-16 10:10:08'), +(6, 0, '1', '1', '

1

', '', '', 0, 1, 20, 1, 1, 0, '2023-11-16 10:12:46', '2023-11-16 10:12:46', '2023-11-16 10:14:11'), +(7, 0, '1', '1', '

1


', '', '', 0, 1, 30, 1, 1, 0, '2023-11-16 10:12:51', '2023-11-16 10:12:51', '2023-11-16 10:13:04'), +(8, 0, '1', '1', '

1

', '', '', 0, 1, 30, 1, 1, 0, '2023-11-16 10:13:56', '2023-11-16 10:13:56', '2023-11-16 10:14:06'), +(9, 0, '1', '1', '

1

', '', '', 0, 1, 20, 1, 1, 0, '2023-11-16 10:29:10', '2023-11-16 10:29:10', '2023-11-16 10:29:54'), +(10, 0, '11', '1', '

1

', '', '', 0, 1, 30, 1, 1, 0, '2023-11-16 10:29:14', '2023-11-16 10:29:14', '2023-11-16 10:29:46'), +(11, 0, '1', '1', '

1

', '', '', 0, 1, 20, 1, 1, 0, '2023-11-16 11:01:07', '2023-11-16 11:01:07', '2023-11-16 11:01:33'), +(12, 0, '1', '1', '

1

', '', '', 0, 1, 30, 1, 1, 0, '2023-11-16 11:01:11', '2023-11-16 11:01:11', '2023-11-16 11:01:27'); -- -------------------------------------------------------- @@ -1928,12 +1952,12 @@ INSERT INTO `hg_sys_gen_curd_demo` (`id`, `category_id`, `title`, `description`, -- 表的结构 `hg_sys_log` -- -CREATE TABLE `hg_sys_log` ( - `id` bigint(20) NOT NULL COMMENT '日志ID', +CREATE TABLE IF NOT EXISTS `hg_sys_log` ( + `id` bigint NOT NULL COMMENT '日志ID', `req_id` varchar(50) DEFAULT NULL COMMENT '对外ID', `app_id` varchar(50) DEFAULT '' COMMENT '应用ID', - `merchant_id` bigint(20) UNSIGNED DEFAULT '0' COMMENT '商户ID', - `member_id` bigint(20) DEFAULT '0' COMMENT '用户ID', + `merchant_id` bigint unsigned DEFAULT '0' COMMENT '商户ID', + `member_id` bigint DEFAULT '0' COMMENT '用户ID', `method` varchar(20) DEFAULT NULL COMMENT '提交类型', `module` varchar(50) DEFAULT NULL COMMENT '访问模块', `url` varchar(1000) DEFAULT NULL COMMENT '提交url', @@ -1941,18 +1965,18 @@ CREATE TABLE `hg_sys_log` ( `post_data` json DEFAULT NULL COMMENT 'post数据', `header_data` json DEFAULT NULL COMMENT 'header数据', `ip` varchar(64) DEFAULT NULL COMMENT 'IP地址', - `province_id` bigint(20) NOT NULL DEFAULT '0' COMMENT '省编码', - `city_id` bigint(20) NOT NULL DEFAULT '0' COMMENT '市编码', - `error_code` int(11) DEFAULT '0' COMMENT '报错code', + `province_id` bigint NOT NULL DEFAULT '0' COMMENT '省编码', + `city_id` bigint NOT NULL DEFAULT '0' COMMENT '市编码', + `error_code` int DEFAULT '0' COMMENT '报错code', `error_msg` longtext COMMENT '对外错误提示', `error_data` json DEFAULT NULL COMMENT '报错日志', `user_agent` varchar(512) DEFAULT NULL COMMENT 'UA信息', - `take_up_time` bigint(20) DEFAULT '0' COMMENT '请求耗时', - `timestamp` bigint(20) DEFAULT '0' COMMENT '响应时间', + `take_up_time` bigint DEFAULT '0' COMMENT '请求耗时', + `timestamp` bigint DEFAULT '0' COMMENT '响应时间', `status` tinyint(1) NOT NULL DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '修改时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_全局日志'; +) ENGINE=InnoDB AUTO_INCREMENT=2036 DEFAULT CHARSET=utf8mb3 COMMENT='系统_全局日志'; -- -------------------------------------------------------- @@ -1960,10 +1984,10 @@ CREATE TABLE `hg_sys_log` ( -- 表的结构 `hg_sys_login_log` -- -CREATE TABLE `hg_sys_login_log` ( - `id` bigint(20) NOT NULL COMMENT '日志ID', +CREATE TABLE IF NOT EXISTS `hg_sys_login_log` ( + `id` bigint NOT NULL COMMENT '日志ID', `req_id` varchar(50) DEFAULT NULL COMMENT '请求ID', - `member_id` bigint(20) DEFAULT '0' COMMENT '用户ID', + `member_id` bigint DEFAULT '0' COMMENT '用户ID', `username` varchar(64) DEFAULT NULL COMMENT '用户名', `response` json DEFAULT NULL COMMENT '响应数据', `login_at` datetime DEFAULT NULL COMMENT '登录时间', @@ -1972,7 +1996,7 @@ CREATE TABLE `hg_sys_login_log` ( `status` tinyint(1) NOT NULL DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '修改时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_登录日志'; +) ENGINE=InnoDB AUTO_INCREMENT=54 DEFAULT CHARSET=utf8mb3 COMMENT='系统_登录日志'; -- -------------------------------------------------------- @@ -1980,20 +2004,20 @@ CREATE TABLE `hg_sys_login_log` ( -- 表的结构 `hg_sys_provinces` -- -CREATE TABLE `hg_sys_provinces` ( - `id` bigint(20) NOT NULL COMMENT '省市区ID', +CREATE TABLE IF NOT EXISTS `hg_sys_provinces` ( + `id` bigint NOT NULL COMMENT '省市区ID', `title` varchar(50) NOT NULL DEFAULT '' COMMENT '栏目名称', `pinyin` varchar(100) DEFAULT '' COMMENT '拼音', `lng` varchar(20) DEFAULT '' COMMENT '经度', `lat` varchar(20) DEFAULT '' COMMENT '纬度', - `pid` bigint(20) NOT NULL DEFAULT '0' COMMENT '父栏目', - `level` int(11) NOT NULL DEFAULT '1' COMMENT '关系树等级', + `pid` bigint NOT NULL DEFAULT '0' COMMENT '父栏目', + `level` int NOT NULL DEFAULT '1' COMMENT '关系树等级', `tree` varchar(200) NOT NULL COMMENT '关系', - `sort` int(11) DEFAULT '0' COMMENT '排序', + `sort` int DEFAULT '0' COMMENT '排序', `status` tinyint(1) NOT NULL DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT='系统_省市区编码'; +) ENGINE=MyISAM DEFAULT CHARSET=utf8mb3 COMMENT='系统_省市区编码'; -- -- 转存表中的数据 `hg_sys_provinces` @@ -5680,15 +5704,15 @@ INSERT INTO `hg_sys_provinces` (`id`, `title`, `pinyin`, `lng`, `lat`, `pid`, `l -- 表的结构 `hg_sys_serve_license` -- -CREATE TABLE `hg_sys_serve_license` ( - `id` bigint(20) NOT NULL COMMENT '许可ID', +CREATE TABLE IF NOT EXISTS `hg_sys_serve_license` ( + `id` bigint NOT NULL COMMENT '许可ID', `group` varchar(50) NOT NULL COMMENT '分组', `name` varchar(128) NOT NULL COMMENT '许可名称', `appid` varchar(64) NOT NULL COMMENT '应用ID', `secret_key` varchar(255) DEFAULT NULL COMMENT '应用秘钥', `remote_addr` varchar(64) DEFAULT NULL COMMENT '最后连接地址', - `online_limit` int(11) DEFAULT '1' COMMENT '在线限制', - `login_times` bigint(20) DEFAULT NULL COMMENT '登录次数', + `online_limit` int DEFAULT '1' COMMENT '在线限制', + `login_times` bigint DEFAULT NULL COMMENT '登录次数', `last_login_at` datetime DEFAULT NULL COMMENT '最后登录时间', `last_active_at` datetime DEFAULT NULL COMMENT '最后心跳', `routes` json DEFAULT NULL COMMENT '路由表,空使用默认分组路由', @@ -5698,15 +5722,15 @@ CREATE TABLE `hg_sys_serve_license` ( `status` tinyint(1) DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '修改时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_服务许可证'; +) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb3 COMMENT='系统_服务许可证'; -- -- 转存表中的数据 `hg_sys_serve_license` -- INSERT INTO `hg_sys_serve_license` (`id`, `group`, `name`, `appid`, `secret_key`, `remote_addr`, `online_limit`, `login_times`, `last_login_at`, `last_active_at`, `routes`, `allowed_ips`, `end_at`, `remark`, `status`, `created_at`, `updated_at`) VALUES -(1, 'cron', '定时任务', '1002', 'hotgo', '127.0.0.1:55870', 1, 42, '2023-08-11 17:29:23', '2023-08-11 17:29:23', NULL, '127.0.0.1', '2033-03-09 00:00:00', '这是默认的定时任务TCP客户端授权凭证。', 1, '2023-03-11 00:00:00', '2023-08-11 17:29:23'), -(2, 'auth', '授权服务', 'mengshuai', '123456', '127.0.0.1:50640', 1, 12, '2023-07-26 17:05:30', '2023-07-26 17:07:01', '[\"ExampleRPCHelloReq\", \"ExampleHelloReq\", \"AuthSummaryReq\"]', '127.0.0.1', '2033-03-09 00:00:00', '这是一个测试的授权服务,可以为第三方平台提供授权支持。', 1, '2023-03-11 00:00:00', '2023-07-26 17:07:01'); +(1, 'cron', '定时任务', '1002', 'hotgo', '127.0.0.1:55402', 1, 46, '2023-11-20 10:27:23', '2023-11-20 10:27:23', NULL, '127.0.0.1', '2033-03-09 00:00:00', '这是默认的定时任务TCP客户端授权凭证。', 1, '2023-03-11 00:00:00', '2023-11-20 10:27:23'), +(2, 'auth', '授权服务', 'mengshuai', '123456', '127.0.0.1:50640', 1, 12, '2023-07-26 17:05:30', '2023-07-26 17:07:01', '["ExampleRPCHelloReq", "ExampleHelloReq", "AuthSummaryReq"]', '127.0.0.1', '2033-03-09 00:00:00', '这是一个测试的授权服务,可以为第三方平台提供授权支持。', 1, '2023-03-11 00:00:00', '2023-07-26 17:07:01'); -- -------------------------------------------------------- @@ -5714,18 +5738,18 @@ INSERT INTO `hg_sys_serve_license` (`id`, `group`, `name`, `appid`, `secret_key` -- 表的结构 `hg_sys_serve_log` -- -CREATE TABLE `hg_sys_serve_log` ( - `id` bigint(20) NOT NULL COMMENT '日志ID', +CREATE TABLE IF NOT EXISTS `hg_sys_serve_log` ( + `id` bigint NOT NULL COMMENT '日志ID', `trace_id` varchar(50) DEFAULT NULL COMMENT '链路ID', `level_format` varchar(32) DEFAULT NULL COMMENT '日志级别', `content` text COMMENT '日志内容', `stack` json DEFAULT NULL COMMENT '打印堆栈', `line` varchar(255) NOT NULL COMMENT '调用行', - `trigger_ns` bigint(20) DEFAULT NULL COMMENT '触发时间(ns)', + `trigger_ns` bigint DEFAULT NULL COMMENT '触发时间(ns)', `status` tinyint(1) NOT NULL DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '修改时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_服务日志'; +) ENGINE=InnoDB AUTO_INCREMENT=146 DEFAULT CHARSET=utf8mb3 COMMENT='系统_服务日志'; -- -------------------------------------------------------- @@ -5733,17 +5757,17 @@ CREATE TABLE `hg_sys_serve_log` ( -- 表的结构 `hg_sys_sms_log` -- -CREATE TABLE `hg_sys_sms_log` ( - `id` bigint(20) NOT NULL COMMENT '主键', +CREATE TABLE IF NOT EXISTS `hg_sys_sms_log` ( + `id` bigint NOT NULL COMMENT '主键', `event` varchar(64) NOT NULL COMMENT '事件', `mobile` varchar(20) NOT NULL DEFAULT '' COMMENT '手机号', `code` varchar(256) DEFAULT '' COMMENT '验证码或短信内容', - `times` bigint(20) NOT NULL COMMENT '验证次数', + `times` bigint NOT NULL COMMENT '验证次数', `ip` varchar(128) DEFAULT NULL COMMENT 'ip地址', `status` tinyint(1) DEFAULT '1' COMMENT '状态(1未验证,2已验证)', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '更新时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='系统_短信发送记录'; +) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb3 COMMENT='系统_短信发送记录'; -- -- 转存表中的数据 `hg_sys_sms_log` @@ -5759,17 +5783,17 @@ INSERT INTO `hg_sys_sms_log` (`id`, `event`, `mobile`, `code`, `times`, `ip`, `s -- 表的结构 `hg_test_category` -- -CREATE TABLE `hg_test_category` ( - `id` bigint(20) NOT NULL COMMENT '分类ID', +CREATE TABLE IF NOT EXISTS `hg_test_category` ( + `id` bigint NOT NULL COMMENT '分类ID', `name` varchar(255) NOT NULL COMMENT '分类名称', `description` varchar(255) DEFAULT NULL COMMENT '描述', - `sort` int(11) NOT NULL COMMENT '排序', + `sort` int NOT NULL COMMENT '排序', `remark` varchar(255) DEFAULT NULL COMMENT '备注', `status` tinyint(1) DEFAULT '1' COMMENT '状态', `created_at` datetime DEFAULT NULL COMMENT '创建时间', `updated_at` datetime DEFAULT NULL COMMENT '修改时间', `deleted_at` datetime DEFAULT NULL COMMENT '删除时间' -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='测试分类'; +) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8mb3 COMMENT='测试分类'; -- -- 转存表中的数据 `hg_test_category` @@ -5787,38 +5811,38 @@ INSERT INTO `hg_test_category` (`id`, `name`, `description`, `sort`, `remark`, ` (9, '网站建站3', '7', 60, NULL, 1, '2023-01-03 00:00:00', '2023-01-03 00:00:00', NULL); -- --- 转储表的索引 +-- Indexes for dumped tables -- -- --- 表的索引 `hg_addon_hgexample_table` +-- Indexes for table `hg_addon_hgexample_table` -- ALTER TABLE `hg_addon_hgexample_table` ADD PRIMARY KEY (`id`); -- --- 表的索引 `hg_admin_cash` +-- Indexes for table `hg_admin_cash` -- ALTER TABLE `hg_admin_cash` ADD PRIMARY KEY (`id`), ADD KEY `admin_id` (`member_id`); -- --- 表的索引 `hg_admin_credits_log` +-- Indexes for table `hg_admin_credits_log` -- ALTER TABLE `hg_admin_credits_log` ADD PRIMARY KEY (`id`), ADD KEY `member_id` (`member_id`); -- --- 表的索引 `hg_admin_dept` +-- Indexes for table `hg_admin_dept` -- ALTER TABLE `hg_admin_dept` ADD PRIMARY KEY (`id`), ADD KEY `pid` (`pid`); -- --- 表的索引 `hg_admin_member` +-- Indexes for table `hg_admin_member` -- ALTER TABLE `hg_admin_member` ADD PRIMARY KEY (`id`), @@ -5827,19 +5851,19 @@ ALTER TABLE `hg_admin_member` ADD KEY `pid` (`pid`); -- --- 表的索引 `hg_admin_member_post` +-- Indexes for table `hg_admin_member_post` -- ALTER TABLE `hg_admin_member_post` ADD PRIMARY KEY (`member_id`,`post_id`); -- --- 表的索引 `hg_admin_member_role` +-- Indexes for table `hg_admin_member_role` -- ALTER TABLE `hg_admin_member_role` ADD PRIMARY KEY (`member_id`,`role_id`); -- --- 表的索引 `hg_admin_menu` +-- Indexes for table `hg_admin_menu` -- ALTER TABLE `hg_admin_menu` ADD PRIMARY KEY (`id`), @@ -5849,20 +5873,20 @@ ALTER TABLE `hg_admin_menu` ADD KEY `type` (`type`); -- --- 表的索引 `hg_admin_notice` +-- Indexes for table `hg_admin_notice` -- ALTER TABLE `hg_admin_notice` ADD PRIMARY KEY (`id`); -- --- 表的索引 `hg_admin_notice_read` +-- Indexes for table `hg_admin_notice_read` -- ALTER TABLE `hg_admin_notice_read` ADD PRIMARY KEY (`id`), ADD UNIQUE KEY `notice_id` (`notice_id`,`member_id`); -- --- 表的索引 `hg_admin_oauth` +-- Indexes for table `hg_admin_oauth` -- ALTER TABLE `hg_admin_oauth` ADD PRIMARY KEY (`id`), @@ -5870,7 +5894,7 @@ ALTER TABLE `hg_admin_oauth` ADD KEY `member_id` (`member_id`); -- --- 表的索引 `hg_admin_order` +-- Indexes for table `hg_admin_order` -- ALTER TABLE `hg_admin_order` ADD PRIMARY KEY (`id`), @@ -5878,31 +5902,31 @@ ALTER TABLE `hg_admin_order` ADD KEY `member_id` (`member_id`); -- --- 表的索引 `hg_admin_post` +-- Indexes for table `hg_admin_post` -- ALTER TABLE `hg_admin_post` ADD PRIMARY KEY (`id`); -- --- 表的索引 `hg_admin_role` +-- Indexes for table `hg_admin_role` -- ALTER TABLE `hg_admin_role` ADD PRIMARY KEY (`id`); -- --- 表的索引 `hg_admin_role_casbin` +-- Indexes for table `hg_admin_role_casbin` -- ALTER TABLE `hg_admin_role_casbin` ADD PRIMARY KEY (`id`) USING BTREE; -- --- 表的索引 `hg_admin_role_menu` +-- Indexes for table `hg_admin_role_menu` -- ALTER TABLE `hg_admin_role_menu` ADD PRIMARY KEY (`role_id`,`menu_id`); -- --- 表的索引 `hg_pay_log` +-- Indexes for table `hg_pay_log` -- ALTER TABLE `hg_pay_log` ADD PRIMARY KEY (`id`), @@ -5910,14 +5934,14 @@ ALTER TABLE `hg_pay_log` ADD KEY `member_id` (`member_id`); -- --- 表的索引 `hg_pay_refund` +-- Indexes for table `hg_pay_refund` -- ALTER TABLE `hg_pay_refund` ADD PRIMARY KEY (`id`), ADD KEY `order_sn` (`order_sn`); -- --- 表的索引 `hg_sys_addons_config` +-- Indexes for table `hg_sys_addons_config` -- ALTER TABLE `hg_sys_addons_config` ADD PRIMARY KEY (`id`), @@ -5926,28 +5950,28 @@ ALTER TABLE `hg_sys_addons_config` ADD KEY `addon_name_3` (`addon_name`,`group`); -- --- 表的索引 `hg_sys_addons_install` +-- Indexes for table `hg_sys_addons_install` -- ALTER TABLE `hg_sys_addons_install` ADD PRIMARY KEY (`id`) USING BTREE, ADD UNIQUE KEY `name` (`name`); -- --- 表的索引 `hg_sys_attachment` +-- Indexes for table `hg_sys_attachment` -- ALTER TABLE `hg_sys_attachment` ADD PRIMARY KEY (`id`), ADD KEY `md5` (`md5`); -- --- 表的索引 `hg_sys_blacklist` +-- Indexes for table `hg_sys_blacklist` -- ALTER TABLE `hg_sys_blacklist` ADD PRIMARY KEY (`id`) USING BTREE, ADD UNIQUE KEY `name` (`ip`); -- --- 表的索引 `hg_sys_config` +-- Indexes for table `hg_sys_config` -- ALTER TABLE `hg_sys_config` ADD PRIMARY KEY (`id`), @@ -5955,53 +5979,52 @@ ALTER TABLE `hg_sys_config` ADD KEY `key` (`key`); -- --- 表的索引 `hg_sys_cron` +-- Indexes for table `hg_sys_cron` -- ALTER TABLE `hg_sys_cron` - ADD PRIMARY KEY (`id`) USING BTREE, - ADD UNIQUE KEY `name` (`name`); + ADD PRIMARY KEY (`id`) USING BTREE; -- --- 表的索引 `hg_sys_cron_group` +-- Indexes for table `hg_sys_cron_group` -- ALTER TABLE `hg_sys_cron_group` ADD PRIMARY KEY (`id`) USING BTREE; -- --- 表的索引 `hg_sys_dict_data` +-- Indexes for table `hg_sys_dict_data` -- ALTER TABLE `hg_sys_dict_data` ADD PRIMARY KEY (`id`), ADD KEY `dict_data_idx` (`type`); -- --- 表的索引 `hg_sys_dict_type` +-- Indexes for table `hg_sys_dict_type` -- ALTER TABLE `hg_sys_dict_type` ADD PRIMARY KEY (`id`) USING BTREE, ADD UNIQUE KEY `dict_type` (`type`); -- --- 表的索引 `hg_sys_ems_log` +-- Indexes for table `hg_sys_ems_log` -- ALTER TABLE `hg_sys_ems_log` ADD PRIMARY KEY (`id`) USING BTREE, ADD KEY `email` (`email`); -- --- 表的索引 `hg_sys_gen_codes` +-- Indexes for table `hg_sys_gen_codes` -- ALTER TABLE `hg_sys_gen_codes` ADD PRIMARY KEY (`id`) USING BTREE; -- --- 表的索引 `hg_sys_gen_curd_demo` +-- Indexes for table `hg_sys_gen_curd_demo` -- ALTER TABLE `hg_sys_gen_curd_demo` ADD PRIMARY KEY (`id`); -- --- 表的索引 `hg_sys_log` +-- Indexes for table `hg_sys_log` -- ALTER TABLE `hg_sys_log` ADD PRIMARY KEY (`id`), @@ -6009,7 +6032,7 @@ ALTER TABLE `hg_sys_log` ADD KEY `req_id` (`req_id`); -- --- 表的索引 `hg_sys_login_log` +-- Indexes for table `hg_sys_login_log` -- ALTER TABLE `hg_sys_login_log` ADD PRIMARY KEY (`id`), @@ -6017,21 +6040,21 @@ ALTER TABLE `hg_sys_login_log` ADD KEY `req_id` (`req_id`); -- --- 表的索引 `hg_sys_provinces` +-- Indexes for table `hg_sys_provinces` -- ALTER TABLE `hg_sys_provinces` ADD PRIMARY KEY (`id`), ADD KEY `pid` (`pid`); -- --- 表的索引 `hg_sys_serve_license` +-- Indexes for table `hg_sys_serve_license` -- ALTER TABLE `hg_sys_serve_license` ADD PRIMARY KEY (`id`), ADD UNIQUE KEY `appid` (`appid`); -- --- 表的索引 `hg_sys_serve_log` +-- Indexes for table `hg_sys_serve_log` -- ALTER TABLE `hg_sys_serve_log` ADD PRIMARY KEY (`id`), @@ -6039,221 +6062,187 @@ ALTER TABLE `hg_sys_serve_log` ADD KEY `traceid` (`trace_id`); -- --- 表的索引 `hg_sys_sms_log` +-- Indexes for table `hg_sys_sms_log` -- ALTER TABLE `hg_sys_sms_log` ADD PRIMARY KEY (`id`) USING BTREE, ADD KEY `mobile` (`mobile`); -- --- 表的索引 `hg_test_category` +-- Indexes for table `hg_test_category` -- ALTER TABLE `hg_test_category` ADD PRIMARY KEY (`id`); -- --- 在导出的表使用AUTO_INCREMENT +-- AUTO_INCREMENT for dumped tables -- -- --- 使用表AUTO_INCREMENT `hg_addon_hgexample_table` +-- AUTO_INCREMENT for table `hg_addon_hgexample_table` -- ALTER TABLE `hg_addon_hgexample_table` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT 'ID', AUTO_INCREMENT=3; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT 'ID',AUTO_INCREMENT=6; -- --- 使用表AUTO_INCREMENT `hg_admin_cash` +-- AUTO_INCREMENT for table `hg_admin_cash` -- ALTER TABLE `hg_admin_cash` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT 'ID', AUTO_INCREMENT=2; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT 'ID',AUTO_INCREMENT=2; -- --- 使用表AUTO_INCREMENT `hg_admin_credits_log` +-- AUTO_INCREMENT for table `hg_admin_credits_log` -- ALTER TABLE `hg_admin_credits_log` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '变动ID', AUTO_INCREMENT=4; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '变动ID',AUTO_INCREMENT=4; -- --- 使用表AUTO_INCREMENT `hg_admin_dept` +-- AUTO_INCREMENT for table `hg_admin_dept` -- ALTER TABLE `hg_admin_dept` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '部门ID', AUTO_INCREMENT=110; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '部门ID',AUTO_INCREMENT=110; -- --- 使用表AUTO_INCREMENT `hg_admin_member` +-- AUTO_INCREMENT for table `hg_admin_member` -- ALTER TABLE `hg_admin_member` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '管理员ID', AUTO_INCREMENT=13; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '管理员ID',AUTO_INCREMENT=13; -- --- 使用表AUTO_INCREMENT `hg_admin_menu` +-- AUTO_INCREMENT for table `hg_admin_menu` -- ALTER TABLE `hg_admin_menu` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '菜单ID', AUTO_INCREMENT=2311; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '菜单ID',AUTO_INCREMENT=2320; -- --- 使用表AUTO_INCREMENT `hg_admin_notice` +-- AUTO_INCREMENT for table `hg_admin_notice` -- ALTER TABLE `hg_admin_notice` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '公告ID', AUTO_INCREMENT=35; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '公告ID',AUTO_INCREMENT=35; -- --- 使用表AUTO_INCREMENT `hg_admin_notice_read` +-- AUTO_INCREMENT for table `hg_admin_notice_read` -- ALTER TABLE `hg_admin_notice_read` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '记录ID', AUTO_INCREMENT=9; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '记录ID',AUTO_INCREMENT=9; -- --- 使用表AUTO_INCREMENT `hg_admin_oauth` +-- AUTO_INCREMENT for table `hg_admin_oauth` -- ALTER TABLE `hg_admin_oauth` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键'; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键'; -- --- 使用表AUTO_INCREMENT `hg_admin_order` +-- AUTO_INCREMENT for table `hg_admin_order` -- ALTER TABLE `hg_admin_order` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键', AUTO_INCREMENT=2; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键',AUTO_INCREMENT=2; -- --- 使用表AUTO_INCREMENT `hg_admin_post` +-- AUTO_INCREMENT for table `hg_admin_post` -- ALTER TABLE `hg_admin_post` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '岗位ID', AUTO_INCREMENT=7; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '岗位ID',AUTO_INCREMENT=7; -- --- 使用表AUTO_INCREMENT `hg_admin_role` +-- AUTO_INCREMENT for table `hg_admin_role` -- ALTER TABLE `hg_admin_role` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '角色ID', AUTO_INCREMENT=209; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '角色ID',AUTO_INCREMENT=209; -- --- 使用表AUTO_INCREMENT `hg_admin_role_casbin` +-- AUTO_INCREMENT for table `hg_admin_role_casbin` -- ALTER TABLE `hg_admin_role_casbin` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=80268; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=96522; -- --- 使用表AUTO_INCREMENT `hg_pay_log` +-- AUTO_INCREMENT for table `hg_pay_log` -- ALTER TABLE `hg_pay_log` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键', AUTO_INCREMENT=2; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键',AUTO_INCREMENT=2; -- --- 使用表AUTO_INCREMENT `hg_pay_refund` +-- AUTO_INCREMENT for table `hg_pay_refund` -- ALTER TABLE `hg_pay_refund` - MODIFY `id` bigint(20) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '主键ID'; - + MODIFY `id` bigint unsigned NOT NULL AUTO_INCREMENT COMMENT '主键ID'; -- --- 使用表AUTO_INCREMENT `hg_sys_addons_config` +-- AUTO_INCREMENT for table `hg_sys_addons_config` -- ALTER TABLE `hg_sys_addons_config` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '配置ID', AUTO_INCREMENT=2; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '配置ID',AUTO_INCREMENT=2; -- --- 使用表AUTO_INCREMENT `hg_sys_addons_install` +-- AUTO_INCREMENT for table `hg_sys_addons_install` -- ALTER TABLE `hg_sys_addons_install` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键', AUTO_INCREMENT=2; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键',AUTO_INCREMENT=2; -- --- 使用表AUTO_INCREMENT `hg_sys_attachment` +-- AUTO_INCREMENT for table `hg_sys_attachment` -- ALTER TABLE `hg_sys_attachment` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '文件ID', AUTO_INCREMENT=5; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '文件ID',AUTO_INCREMENT=8; -- --- 使用表AUTO_INCREMENT `hg_sys_blacklist` +-- AUTO_INCREMENT for table `hg_sys_blacklist` -- ALTER TABLE `hg_sys_blacklist` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '黑名单ID', AUTO_INCREMENT=8; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '黑名单ID',AUTO_INCREMENT=8; -- --- 使用表AUTO_INCREMENT `hg_sys_config` +-- AUTO_INCREMENT for table `hg_sys_config` -- ALTER TABLE `hg_sys_config` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '配置ID', AUTO_INCREMENT=122; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '配置ID',AUTO_INCREMENT=129; -- --- 使用表AUTO_INCREMENT `hg_sys_cron` +-- AUTO_INCREMENT for table `hg_sys_cron` -- ALTER TABLE `hg_sys_cron` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '任务ID', AUTO_INCREMENT=4; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '任务ID',AUTO_INCREMENT=14; -- --- 使用表AUTO_INCREMENT `hg_sys_cron_group` +-- AUTO_INCREMENT for table `hg_sys_cron_group` -- ALTER TABLE `hg_sys_cron_group` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '任务分组ID', AUTO_INCREMENT=3; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '任务分组ID',AUTO_INCREMENT=5; -- --- 使用表AUTO_INCREMENT `hg_sys_dict_data` +-- AUTO_INCREMENT for table `hg_sys_dict_data` -- ALTER TABLE `hg_sys_dict_data` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '字典数据ID', AUTO_INCREMENT=157; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '字典数据ID',AUTO_INCREMENT=158; -- --- 使用表AUTO_INCREMENT `hg_sys_dict_type` +-- AUTO_INCREMENT for table `hg_sys_dict_type` -- ALTER TABLE `hg_sys_dict_type` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '字典类型ID', AUTO_INCREMENT=39; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '字典类型ID',AUTO_INCREMENT=39; -- --- 使用表AUTO_INCREMENT `hg_sys_ems_log` +-- AUTO_INCREMENT for table `hg_sys_ems_log` -- ALTER TABLE `hg_sys_ems_log` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键', AUTO_INCREMENT=5; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键',AUTO_INCREMENT=5; -- --- 使用表AUTO_INCREMENT `hg_sys_gen_codes` +-- AUTO_INCREMENT for table `hg_sys_gen_codes` -- ALTER TABLE `hg_sys_gen_codes` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '生成ID', AUTO_INCREMENT=3; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '生成ID',AUTO_INCREMENT=4; -- --- 使用表AUTO_INCREMENT `hg_sys_gen_curd_demo` +-- AUTO_INCREMENT for table `hg_sys_gen_curd_demo` -- ALTER TABLE `hg_sys_gen_curd_demo` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT 'ID', AUTO_INCREMENT=2; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT 'ID',AUTO_INCREMENT=13; -- --- 使用表AUTO_INCREMENT `hg_sys_log` +-- AUTO_INCREMENT for table `hg_sys_log` -- ALTER TABLE `hg_sys_log` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '日志ID', AUTO_INCREMENT=1312; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '日志ID',AUTO_INCREMENT=2036; -- --- 使用表AUTO_INCREMENT `hg_sys_login_log` +-- AUTO_INCREMENT for table `hg_sys_login_log` -- ALTER TABLE `hg_sys_login_log` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '日志ID', AUTO_INCREMENT=50; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '日志ID',AUTO_INCREMENT=54; -- --- 使用表AUTO_INCREMENT `hg_sys_serve_license` +-- AUTO_INCREMENT for table `hg_sys_serve_license` -- ALTER TABLE `hg_sys_serve_license` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '许可ID', AUTO_INCREMENT=3; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '许可ID',AUTO_INCREMENT=3; -- --- 使用表AUTO_INCREMENT `hg_sys_serve_log` +-- AUTO_INCREMENT for table `hg_sys_serve_log` -- ALTER TABLE `hg_sys_serve_log` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '日志ID', AUTO_INCREMENT=31; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '日志ID',AUTO_INCREMENT=146; -- --- 使用表AUTO_INCREMENT `hg_sys_sms_log` +-- AUTO_INCREMENT for table `hg_sys_sms_log` -- ALTER TABLE `hg_sys_sms_log` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键', AUTO_INCREMENT=3; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键',AUTO_INCREMENT=3; -- --- 使用表AUTO_INCREMENT `hg_test_category` +-- AUTO_INCREMENT for table `hg_test_category` -- ALTER TABLE `hg_test_category` - MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '分类ID', AUTO_INCREMENT=10; -COMMIT; - + MODIFY `id` bigint NOT NULL AUTO_INCREMENT COMMENT '分类ID',AUTO_INCREMENT=10; /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; diff --git a/web/package.json b/web/package.json index fa2aa0d..a55dc1f 100644 --- a/web/package.json +++ b/web/package.json @@ -1,6 +1,6 @@ { "name": "hotgo", - "version": "2.9.8", + "version": "2.11.5", "author": { "name": "MengShuai", "email": "133814250@qq.com", diff --git a/web/src/api/addons/hgexample/treeTable/index.ts b/web/src/api/addons/hgexample/treeTable/index.ts new file mode 100644 index 0000000..cd3e226 --- /dev/null +++ b/web/src/api/addons/hgexample/treeTable/index.ts @@ -0,0 +1,76 @@ +import { http, jumpExport } from '@/utils/http/axios'; + +// 列表 +export function List(params) { + return http.request({ + url: '/hgexample/treeTable/list', + method: 'get', + params, + }); +} + +// 删除/批量删除 +export function Delete(params) { + return http.request({ + url: '/hgexample/treeTable/delete', + method: 'POST', + params, + }); +} + +// 添加/编辑 +export function Edit(params) { + return http.request({ + url: '/hgexample/treeTable/edit', + method: 'POST', + params, + }); +} + +// 修改状态 +export function Status(params) { + return http.request({ + url: '/hgexample/treeTable/status', + method: 'POST', + params, + }); +} + +// 操作开关 +export function Switch(params) { + return http.request({ + url: '/hgexample/treeTable/switch', + method: 'POST', + params, + }); +} + +// 详情 +export function View(params) { + return http.request({ + url: '/hgexample/treeTable/view', + method: 'GET', + params, + }); +} + +// 获取最大排序 +export function MaxSort() { + return http.request({ + url: '/hgexample/treeTable/maxSort', + method: 'GET', + }); +} + +// 树形选项 +export function Select() { + return http.request({ + url: '/hgexample/treeTable/select', + method: 'get', + }); +} + +// 导出 +export function Export(params) { + jumpExport('/hgexample/treeTable/export', params); +} diff --git a/web/src/api/sys/cron.ts b/web/src/api/sys/cron.ts index f41f2f5..6a8fd9a 100644 --- a/web/src/api/sys/cron.ts +++ b/web/src/api/sys/cron.ts @@ -95,3 +95,11 @@ export function OnlineExec(params) { params, }); } + +export function DispatchLog(params) { + return http.request({ + url: '/cron/dispatchLog', + method: 'POST', + params, + }); +} diff --git a/web/src/components/Form/src/BasicForm.vue b/web/src/components/Form/src/BasicForm.vue index 098cf3b..b8692e6 100644 --- a/web/src/components/Form/src/BasicForm.vue +++ b/web/src/components/Form/src/BasicForm.vue @@ -52,6 +52,13 @@ + ) { return new VAxios( deepMerge( { - timeout: 10 * 1000, + timeout: 30 * 1000, authenticationScheme: '', // 接口前缀 prefixUrl: urlPrefix, diff --git a/web/src/utils/index.ts b/web/src/utils/index.ts index 7b183fc..f64d223 100644 --- a/web/src/utils/index.ts +++ b/web/src/utils/index.ts @@ -192,16 +192,12 @@ export function getTreeItem(data: any[], key?: string | number): any { return result; } -/** - * 找到所有节点 - * */ -const treeAll: any[] = []; - export function getTreeAll(data: any[]): any[] { + const treeAll: any[] = []; data.map((item) => { treeAll.push(item.key); if (item.children && item.children.length) { - getTreeAll(item.children); + treeAll.push(...getTreeAll(item.children)); } }); return treeAll; diff --git a/web/src/views/addons/hgexample/table/index.vue b/web/src/views/addons/hgexample/table/index.vue index a073fb7..492b4ef 100644 --- a/web/src/views/addons/hgexample/table/index.vue +++ b/web/src/views/addons/hgexample/table/index.vue @@ -25,6 +25,7 @@ :row-key="(row) => row.id" ref="actionRef" :actionColumn="actionColumn" + :checked-row-keys="checkedIds" @update:checked-row-keys="onCheckedRow" :scroll-x="1090" :resizeHeightOffset="-10000" @@ -227,6 +228,8 @@ negativeText: '取消', onPositiveClick: () => { Delete({ id: checkedIds.value }).then((_res) => { + batchDeleteDisabled.value = true; + checkedIds.value = []; message.success('删除成功'); reloadTable(); }); diff --git a/web/src/views/addons/hgexample/treeTable/edit.vue b/web/src/views/addons/hgexample/treeTable/edit.vue new file mode 100644 index 0000000..793d11e --- /dev/null +++ b/web/src/views/addons/hgexample/treeTable/edit.vue @@ -0,0 +1,249 @@ + + + + + diff --git a/web/src/views/addons/hgexample/treeTable/index.vue b/web/src/views/addons/hgexample/treeTable/index.vue new file mode 100644 index 0000000..5852c42 --- /dev/null +++ b/web/src/views/addons/hgexample/treeTable/index.vue @@ -0,0 +1,232 @@ + + diff --git a/web/src/views/addons/hgexample/treeTable/list.vue b/web/src/views/addons/hgexample/treeTable/list.vue new file mode 100644 index 0000000..fba5127 --- /dev/null +++ b/web/src/views/addons/hgexample/treeTable/list.vue @@ -0,0 +1,250 @@ + + + + + diff --git a/web/src/views/addons/hgexample/treeTable/model.ts b/web/src/views/addons/hgexample/treeTable/model.ts new file mode 100644 index 0000000..6a76282 --- /dev/null +++ b/web/src/views/addons/hgexample/treeTable/model.ts @@ -0,0 +1,529 @@ +import { h, ref } from 'vue'; +import { NAvatar, NImage, NTag, NSwitch, NRate } from 'naive-ui'; +import { cloneDeep } from 'lodash-es'; +import { FormSchema } from '@/components/Form'; +import { Dicts } from '@/api/dict/dict'; +import { Switch } from '@/api/addons/hgexample/table'; +import { isNullObject } from '@/utils/is'; +import { getFileExt } from '@/utils/urlUtils'; +import { defRangeShortcuts, defShortcuts, formatToDate } from '@/utils/dateUtil'; +import { validate } from '@/utils/validateUtil'; +import { errorImg, getOptionLabel, getOptionTag, Options } from '@/utils/hotgo'; +const $message = window['$message']; +export interface State { + id: number; + memberId: number; + categoryId: number; + flag: number[] | null; + title: string; + content: string; + image: string; + images: string[] | null; + attachfile: string; + attachfiles: string[] | null; + map: unknown[] | null; + star: number; + description: string; + price: number; + views: number; + activityAt: string; + startAt: null; + endAt: null; + switch: number; + sort: number; + avatar: string; + sex: number; + qq: string; + email: string; + mobile: string; + channel: number; + cityId: number; + hobby: string[] | null; + pid: number; + level: number; + tree: string; + remark: string; + status: number; + createdBy: number; + createdAt: string; + updatedAt: string; +} + +export const defaultState = { + id: 0, + memberId: 0, + categoryId: 0, + flag: [1], + title: '', + content: '', + image: '', + images: null, + attachfile: '', + attachfiles: null, + map: null, + star: 0, + description: '', + price: 0, + views: 0, + activityAt: '', + startAt: null, + endAt: null, + switch: 0, + sort: 0, + avatar: '', + sex: 0, + qq: '', + email: '', + mobile: '', + channel: 0, + cityId: 0, + hobby: null, + pid: 0, + level: 1, + tree: '', + remark: '', + status: 1, + createdBy: 0, + createdAt: '', + updatedAt: '', +}; + +export function newState(state: State | null): State { + if (state !== null) { + return cloneDeep(state); + } + return cloneDeep(defaultState); +} + +export const options = ref({ + sys_normal_disable: [], + sys_user_sex: [], + sys_notice_type: [], + sys_user_channel: [], + sys_user_hobby: [], + sys_switch: [], +}); + +export const rules = { + title: { + required: true, + trigger: ['blur', 'input'], + message: '请输入标题', + }, + price: { + required: true, + trigger: ['blur', 'input'], + validator: validate.amount, + }, + qq: { + required: false, + trigger: ['blur', 'input'], + validator: validate.qq, + }, + email: { + required: true, + trigger: ['blur', 'input'], + validator: validate.email, + }, + mobile: { + required: true, + trigger: ['blur', 'input'], + validator: validate.phone, + }, +}; + +export const schemas = ref([ + { + field: 'title', + component: 'NInput', + label: '标题', + componentProps: { + placeholder: '请输入标题', + onUpdateValue: (e: any) => { + console.log(e); + }, + }, + rules: [{ message: '请输入标题', trigger: ['blur'] }], + }, + { + field: 'content', + component: 'NInput', + label: '内容', + componentProps: { + placeholder: '请输入内容关键词', + showButton: false, + onUpdateValue: (e: any) => { + console.log(e); + }, + }, + }, + { + field: 'price', + labelMessage: '我是自定义提示', + component: 'NInput', + label: '价格', + componentProps: { + pair: true, + separator: '-', + clearable: true, + placeholder: ['从', '到'], + onInput: (e: any) => { + console.log(e); + }, + }, + }, + { + field: 'activityAt', + component: 'NDatePicker', + label: '活动时间', + componentProps: { + type: 'date', + clearable: true, + shortcuts: defShortcuts(), + onUpdateValue: (e: any) => { + console.log(e); + }, + }, + }, + { + field: 'createdAt', + component: 'NDatePicker', + label: '创建时间', + componentProps: { + type: 'datetimerange', + clearable: true, + shortcuts: defRangeShortcuts(), + onUpdateValue: (e: any) => { + console.log(e); + }, + }, + }, + { + field: 'flag', + component: 'NCheckbox', + label: '标签', + giProps: { + span: 1, + }, + componentProps: { + placeholder: '请选择标签', + options: [], + onUpdateChecked: (e: any) => { + console.log(e); + }, + }, + }, + { + field: 'switch', + component: 'NRadioGroup', + label: '开关', + giProps: { + //span: 24, + }, + componentProps: { + options: [], + onUpdateChecked: (e: any) => { + console.log(e); + }, + }, + }, + { + field: 'hobby', + component: 'NSelect', + label: '爱好', + defaultValue: null, + componentProps: { + multiple: true, + placeholder: '请选择爱好', + options: [], + onUpdateValue: (e: any) => { + console.log(e); + }, + }, + }, + { + field: 'status', + component: 'NSelect', + label: '状态', + defaultValue: null, + componentProps: { + placeholder: '请选择类型', + options: [], + onUpdateValue: (e: any) => { + console.log(e); + }, + }, + }, +]); + +export const columns = [ + { + title: 'ID', + key: 'id', + sorter: true, // 单列排序 + }, + { + title: '标题', + key: 'title', + render(row) { + return row.title; + }, + sorter: { + multiple: 1, // 为多列排序的优先级,越高优先级越高 + }, + }, + { + title: '标签', + key: 'flag', + render(row) { + if (isNullObject(row.flag)) { + return ``; + } + return row.flag.map((tagKey) => { + return h( + NTag, + { + style: { + marginRight: '6px', + }, + type: getOptionTag(options.value.sys_notice_type, tagKey), + bordered: false, + }, + { + default: () => getOptionLabel(options.value.sys_notice_type, tagKey), + } + ); + }); + }, + }, + { + title: '单图', + key: 'image', + render(row) { + return h(NImage, { + width: 32, + height: 32, + src: row.image, + fallbackSrc: errorImg, + style: { + width: '32px', + height: '32px', + 'max-width': '100%', + 'max-height': '100%', + }, + }); + }, + }, + { + title: '多图', + key: 'images', + render(row) { + if (isNullObject(row.images)) { + return ``; + } + return row.images.map((image) => { + return h(NImage, { + width: 32, + height: 32, + src: image, + fallbackSrc: errorImg, + style: { + width: '32px', + height: '32px', + 'max-width': '100%', + 'max-height': '100%', + 'margin-left': '2px', + }, + }); + }); + }, + }, + { + title: '附件', + key: 'attachfile', + render(row) { + if (row.attachfile === '') { + return ``; + } + return h( + NAvatar, + { + size: 'small', + }, + { + default: () => getFileExt(row.attachfile), + } + ); + }, + }, + { + title: '多附件', + key: 'attachfiles', + render(row) { + if (isNullObject(row.attachfiles)) { + return ``; + } + return row.attachfiles.map((attachfile) => { + return h( + NAvatar, + { + size: 'small', + style: { + 'margin-left': '2px', + }, + }, + { + default: () => getFileExt(attachfile), + } + ); + }); + }, + }, + { + title: '推荐星', + key: 'star', + // width: 180, + render(row) { + return h(NRate, { + allowHalf: true, + readonly: true, + defaultValue: row.star, + }); + }, + }, + { + title: '描述', + key: 'description', + }, + { + title: '价格', + key: 'price', + sorter: { + multiple: 2, // 为多列排序的优先级,越高优先级越高 + }, + render(row) { + return h( + NTag, + { + style: { + marginRight: '6px', + }, + type: 'success', + bordered: false, + }, + { + default: () => row.price.toFixed(2), + } + ); + }, + }, + { + title: '开关', + key: 'switch', + width: 100, + render(row) { + return h(NSwitch, { + value: row.switch === 1, + checked: '开启', + unchecked: '关闭', + onUpdateValue: function (e) { + row.switch = e ? 1 : 2; + Switch({ id: row.id, key: 'switch', value: row.switch }).then((_res) => { + $message.success('操作成功'); + }); + }, + }); + }, + }, + // { + // title: '排序', + // key: 'sort', + // }, + { + title: '状态', + key: 'status', + render(row) { + if (isNullObject(row.status)) { + return ``; + } + return h( + NTag, + { + style: { + marginRight: '6px', + }, + type: getOptionTag(options.value.sys_normal_disable, row.status), + bordered: false, + }, + { + default: () => getOptionLabel(options.value.sys_normal_disable, row.status), + } + ); + }, + }, + { + title: '爱好', + key: 'hobby', + render(row) { + if (isNullObject(row.hobby)) { + return ``; + } + return row.hobby.map((tagKey) => { + return h( + NTag, + { + style: { + marginRight: '6px', + }, + type: getOptionTag(options.value.sys_user_hobby, tagKey), + bordered: false, + }, + { + default: () => getOptionLabel(options.value.sys_user_hobby, tagKey), + } + ); + }); + }, + }, + { + title: '活动时间', + key: 'activityAt', + render(row) { + return formatToDate(row.activityAt); + }, + sorter: { + multiple: 3, // 为多列排序的优先级,越高优先级越高 + }, + }, +]; + +async function loadOptions() { + options.value = await Dicts({ + types: [ + 'sys_normal_disable', + 'sys_user_sex', + 'sys_notice_type', + 'sys_switch', + 'sys_user_hobby', + 'sys_user_channel', + ], + }); + for (const item of schemas.value) { + switch (item.field) { + case 'status': + item.componentProps.options = options.value.sys_normal_disable; + break; + case 'flag': + item.componentProps.options = options.value.sys_notice_type; + break; + case 'switch': + item.componentProps.options = options.value.sys_switch; + break; + case 'hobby': + item.componentProps.options = options.value.sys_user_hobby; + break; + } + } +} + +await loadOptions(); diff --git a/web/src/views/curdDemo/index.vue b/web/src/views/curdDemo/index.vue index 59d8355..3c6b606 100644 --- a/web/src/views/curdDemo/index.vue +++ b/web/src/views/curdDemo/index.vue @@ -26,6 +26,7 @@ :row-key="(row) => row.id" ref="actionRef" :actionColumn="actionColumn" + :checked-row-keys="checkedIds" @update:checked-row-keys="onCheckedRow" :scroll-x="1090" :resizeHeightOffset="-10000" @@ -63,7 +64,7 @@ type="primary" @click="handleExport" class="min-left-space" - v-if="hasPermission(['/curdDemo/delete'])" + v-if="hasPermission(['/curdDemo/export'])" > - + diff --git a/web/src/views/system/cron/modal/columns.ts b/web/src/views/system/cron/modal/columns.ts index ff31257..7774dcf 100644 --- a/web/src/views/system/cron/modal/columns.ts +++ b/web/src/views/system/cron/modal/columns.ts @@ -8,34 +8,33 @@ export const columns = [ key: 'id', width: 100, }, - { - title: '上级ID', - dataIndex: 'pid', - key: 'pid', - width: 100, - }, { title: '分组名称', dataIndex: 'name', key: 'name', - width: 200, + width: 150, }, { - title: '是否默认', + title: '上级分组', + dataIndex: 'supName', + key: 'supName', + width: 150, + render(row) { + if (row.supName == ''){ + return '顶级分组'; + } + return row.supName; + }, + }, + { + title: '默认', dataIndex: 'isDefault', key: 'isDefault', render(row) { - return row.is_default === 1 ? '是' : '否'; + return row.isDefault === 1 ? '是' : '否'; }, - width: 100, + width: 80, }, - { - title: '排序', - dataIndex: 'sort', - key: 'sort', - width: 100, - }, - { title: '状态', dataIndex: 'status', @@ -57,6 +56,12 @@ export const columns = [ }, width: 150, }, + // { + // title: '排序', + // dataIndex: 'sort', + // key: 'sort', + // width: 100, + // }, { title: '备注', dataIndex: 'remark', diff --git a/web/src/views/system/cron/modal/index.vue b/web/src/views/system/cron/modal/index.vue index 4d4af93..8e6a1df 100644 --- a/web/src/views/system/cron/modal/index.vue +++ b/web/src/views/system/cron/modal/index.vue @@ -40,16 +40,11 @@ :default-value="formParams.pid" @update:value="handleUpdateValue" /> - - - - - + + + + @@ -87,7 +86,7 @@ import { statusOptions } from '@/enums/optionsiEnum'; const emit = defineEmits(['reloadGroupOption']); - const optionTreeData = ref([]); + const optionTreeData = ref([]); const message = useMessage(); const statusValue = ref(1); const defaultValueRef = () => ({ @@ -140,7 +139,7 @@ const formRef = ref({}); const actionColumn = reactive({ - width: 220, + width: 150, title: '操作', key: 'action', // fixed: 'right', @@ -213,10 +212,16 @@ async function setDictSelect() { const tmp = await getSelect({}); - optionTreeData.value = tmp.list; - if (optionTreeData.value === undefined || optionTreeData.value === null) { - optionTreeData.value = []; - } + optionTreeData.value = [ + { + id: 0, + key: 0, + label: '顶级分组', + pid: 0, + name: '顶级分组', + }, + ]; + optionTreeData.value = optionTreeData.value.concat(tmp.list); } onMounted(async () => { diff --git a/web/src/views/system/cron/modal/modal.vue b/web/src/views/system/cron/modal/modal.vue index 1e457b0..d851f78 100644 --- a/web/src/views/system/cron/modal/modal.vue +++ b/web/src/views/system/cron/modal/modal.vue @@ -18,7 +18,7 @@ const emit = defineEmits(['reloadGroupOption']); const showModal = ref(false); - const title = ref('管理分组'); + const title = ref('任务分组'); function openDrawer() { showModal.value = true;