v1
This commit is contained in:
17
internal/erpserver/model/dto/authorize_user.go
Normal file
17
internal/erpserver/model/dto/authorize_user.go
Normal file
@@ -0,0 +1,17 @@
|
||||
package dto
|
||||
|
||||
import (
|
||||
"github.com/google/uuid"
|
||||
)
|
||||
|
||||
type AuthorizeUser struct {
|
||||
ID int32 `json:"id"`
|
||||
Uuid uuid.UUID `json:"uuid"`
|
||||
Email string `json:"email"`
|
||||
Username string `json:"username"`
|
||||
RoleID int32 `json:"role_id"`
|
||||
RoleName string `json:"role_name"`
|
||||
OS string `json:"os"`
|
||||
IP string `json:"ip"`
|
||||
Browser string `json:"browser"`
|
||||
}
|
||||
11
internal/erpserver/model/dto/menu_ui_dto.go
Normal file
11
internal/erpserver/model/dto/menu_ui_dto.go
Normal file
@@ -0,0 +1,11 @@
|
||||
package dto
|
||||
|
||||
type MenuUIDto struct {
|
||||
ID string `json:"id"`
|
||||
Title string `json:"title"`
|
||||
Icon string `json:"icon"`
|
||||
Type int `json:"type"`
|
||||
OpenType string `json:"openType"`
|
||||
Href string `json:"href"`
|
||||
Children []*MenuUIDto `json:"children"`
|
||||
}
|
||||
65
internal/erpserver/model/dto/pear.go
Normal file
65
internal/erpserver/model/dto/pear.go
Normal file
@@ -0,0 +1,65 @@
|
||||
package dto
|
||||
|
||||
type PearConfig struct {
|
||||
Logo Logo `json:"logo"`
|
||||
Menu Menu `json:"menu"`
|
||||
Tab Tab `json:"tab"`
|
||||
Theme Theme `json:"theme"`
|
||||
Colors []Colors `json:"colors"`
|
||||
Other Other `json:"other"`
|
||||
Header Header `json:"header"`
|
||||
}
|
||||
|
||||
type Logo struct {
|
||||
Title string `json:"title"`
|
||||
Image string `json:"image"`
|
||||
}
|
||||
|
||||
type Menu struct {
|
||||
Data string `json:"data"`
|
||||
Method string `json:"method"`
|
||||
Accordion bool `json:"accordion"`
|
||||
Collapse bool `json:"collapse"`
|
||||
Control bool `json:"control"`
|
||||
Select string `json:"select"`
|
||||
Async bool `json:"async"`
|
||||
}
|
||||
|
||||
type Index struct {
|
||||
Id string `json:"id"`
|
||||
Href string `json:"href"`
|
||||
Title string `json:"title"`
|
||||
}
|
||||
|
||||
type Tab struct {
|
||||
Enable bool `json:"enable"`
|
||||
KeepState bool `json:"keepState"`
|
||||
Session bool `json:"session"`
|
||||
Preload bool `json:"preload"`
|
||||
Max string `json:"max"`
|
||||
Index Index `json:"index"`
|
||||
}
|
||||
|
||||
type Theme struct {
|
||||
DefaultColor string `json:"defaultColor"`
|
||||
DefaultMenu string `json:"defaultMenu"`
|
||||
DefaultHeader string `json:"defaultHeader"`
|
||||
AllowCustom bool `json:"allowCustom"`
|
||||
Banner bool `json:"banner"`
|
||||
}
|
||||
|
||||
type Colors struct {
|
||||
Id string `json:"id"`
|
||||
Color string `json:"color"`
|
||||
Second string `json:"second"`
|
||||
}
|
||||
|
||||
type Other struct {
|
||||
KeepLoad string `json:"keepLoad"`
|
||||
AutoHead bool `json:"autoHead"`
|
||||
Footer bool `json:"footer"`
|
||||
}
|
||||
|
||||
type Header struct {
|
||||
Message string `json:"message"`
|
||||
}
|
||||
16
internal/erpserver/model/dto/search.go
Normal file
16
internal/erpserver/model/dto/search.go
Normal file
@@ -0,0 +1,16 @@
|
||||
package dto
|
||||
|
||||
type SearchDto struct {
|
||||
SearchTimeBegin string `json:"searchTimeBegin"`
|
||||
SearchTimeEnd string `json:"searchTimeEnd"`
|
||||
SearchStatus int `json:"searchStatus"`
|
||||
SearchEmail string `json:"searchEmail"`
|
||||
SearchPhone string `json:"searchPhone"`
|
||||
SearchName string `json:"searchName"`
|
||||
SearchID int64 `json:"searchID"`
|
||||
SearchKey string `json:"searchKey"`
|
||||
SearchParentID int `json:"searchParentId"`
|
||||
SearchDepartmentID int `json:"searchDepartmentId"`
|
||||
Page int `json:"page"`
|
||||
Rows int `json:"rows"`
|
||||
}
|
||||
26
internal/erpserver/model/dto/set_menu_dto.go
Normal file
26
internal/erpserver/model/dto/set_menu_dto.go
Normal file
@@ -0,0 +1,26 @@
|
||||
package dto
|
||||
|
||||
type SetMenuDto struct {
|
||||
ID int32
|
||||
Name string
|
||||
Link string
|
||||
IsList bool
|
||||
IsSelect bool
|
||||
Items []*SetMenuDto
|
||||
}
|
||||
|
||||
type OwnerMenuDto struct {
|
||||
ID int32 `json:"id"`
|
||||
// 显示名称
|
||||
DisplayName string `json:"display_name"`
|
||||
// 菜单url
|
||||
Url string `json:"url"`
|
||||
// 上级id
|
||||
ParentID int32 `json:"parent_id"`
|
||||
// 菜单图标
|
||||
Avatar string `json:"avatar"`
|
||||
// 菜单样式
|
||||
Style string `json:"style"`
|
||||
// 是否列表
|
||||
IsList bool `json:"is_list"`
|
||||
}
|
||||
56
internal/erpserver/model/dto/system.go
Normal file
56
internal/erpserver/model/dto/system.go
Normal file
@@ -0,0 +1,56 @@
|
||||
package dto
|
||||
|
||||
import "time"
|
||||
|
||||
type SysDepartmentDto struct {
|
||||
ID int32 `json:"id"`
|
||||
// 部门名称
|
||||
Name string `json:"name"`
|
||||
// 上级id
|
||||
ParentID int32 `json:"parent_id"`
|
||||
// 树路径
|
||||
ParentPath string `json:"parent_path"`
|
||||
// 状态
|
||||
Status int32 `json:"status"`
|
||||
// 排序
|
||||
Sort int32 `json:"sort"`
|
||||
// 创建时间
|
||||
CreatedAt time.Time `json:"created_at"`
|
||||
// 更新时间
|
||||
UpdatedAt time.Time `json:"updated_at"`
|
||||
Children []*SysDepartmentDto `json:"children"`
|
||||
}
|
||||
|
||||
type SysMenuDto struct {
|
||||
ID int32 `json:"id"`
|
||||
// 名称
|
||||
Name string `json:"name"`
|
||||
// 显示名称
|
||||
DisplayName string `json:"display_name"`
|
||||
// 菜单url
|
||||
Url string `json:"url"`
|
||||
// 菜单类型(node, menu, btn)
|
||||
Type string `json:"type"`
|
||||
// 上级id
|
||||
ParentID int32 `json:"parent_id"`
|
||||
// 树路径
|
||||
ParentPath string `json:"parent_path"`
|
||||
// 菜单图标
|
||||
Avatar string `json:"avatar"`
|
||||
// 菜单样式
|
||||
Style string `json:"style"`
|
||||
// 是否可见
|
||||
Visible bool `json:"visible"`
|
||||
// 是否列表
|
||||
IsList bool `json:"is_list"`
|
||||
// 状态
|
||||
Status int32 `json:"status"`
|
||||
// 排序
|
||||
Sort int32 `json:"sort"`
|
||||
// 创建时间
|
||||
CreatedAt time.Time `json:"created_at"`
|
||||
// 更新时间
|
||||
UpdatedAt time.Time `json:"updated_at"`
|
||||
|
||||
Children []*SysMenuDto `json:"children"`
|
||||
}
|
||||
18
internal/erpserver/model/dto/tree.go
Normal file
18
internal/erpserver/model/dto/tree.go
Normal file
@@ -0,0 +1,18 @@
|
||||
package dto
|
||||
|
||||
type TreeDto struct {
|
||||
ID int `json:"id"`
|
||||
Title string `json:"title"`
|
||||
|
||||
Children []*TreeDto `json:"children"`
|
||||
}
|
||||
|
||||
type DTreeDto struct {
|
||||
ID string `json:"id"`
|
||||
Title string `json:"title"`
|
||||
Last bool `json:"last"`
|
||||
ParentId string `json:"parentId"`
|
||||
Spread bool `json:"spread"`
|
||||
|
||||
Children []*DTreeDto `json:"children"`
|
||||
}
|
||||
27
internal/erpserver/model/dto/xm_select.go
Normal file
27
internal/erpserver/model/dto/xm_select.go
Normal file
@@ -0,0 +1,27 @@
|
||||
package dto
|
||||
|
||||
type XmSelectDto struct {
|
||||
Name string `json:"name"`
|
||||
Value int `json:"value"`
|
||||
}
|
||||
|
||||
type XmSelectInt64Dto struct {
|
||||
Name string `json:"name"`
|
||||
Value int64 `json:"value"`
|
||||
}
|
||||
|
||||
type XmSelectInt32Dto struct {
|
||||
Name string `json:"name"`
|
||||
Value int32 `json:"value"`
|
||||
}
|
||||
|
||||
type XmSelectStrDto struct {
|
||||
Name string `json:"name"`
|
||||
Value string `json:"value"`
|
||||
}
|
||||
|
||||
type XmSelectTreeDto struct {
|
||||
Name string `json:"name"`
|
||||
Value string `json:"value"`
|
||||
Children []*XmSelectTreeDto `json:"children"`
|
||||
}
|
||||
@@ -7,7 +7,7 @@ import (
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"management/internal/db/model/dto"
|
||||
"management/internal/erpserver/model/dto"
|
||||
)
|
||||
|
||||
type AuditLogRepository interface {
|
||||
|
||||
@@ -4,7 +4,7 @@ import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
"management/internal/db/model/dto"
|
||||
"management/internal/erpserver/model/dto"
|
||||
)
|
||||
|
||||
type ConfigRepository interface {
|
||||
|
||||
@@ -4,7 +4,7 @@ import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
"management/internal/db/model/dto"
|
||||
"management/internal/erpserver/model/dto"
|
||||
)
|
||||
|
||||
type DepartmentRepository interface {
|
||||
|
||||
@@ -4,7 +4,7 @@ import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
"management/internal/db/model/dto"
|
||||
"management/internal/erpserver/model/dto"
|
||||
)
|
||||
|
||||
type LoginLogRepository interface {
|
||||
|
||||
@@ -4,7 +4,7 @@ import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
"management/internal/db/model/dto"
|
||||
"management/internal/erpserver/model/dto"
|
||||
)
|
||||
|
||||
type RoleRepository interface {
|
||||
|
||||
@@ -4,7 +4,7 @@ import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
"management/internal/db/model/dto"
|
||||
"management/internal/erpserver/model/dto"
|
||||
|
||||
"github.com/google/uuid"
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user