add roles

This commit is contained in:
guwandyk committed 2026-07-07 18:06:50 +05:00
1 parent 41471694d5
commit 4d1942d7fe
12 files changed
+450 -12

No files matched your search

+35
View File
@@ -0,0 +1,35 @@
package role
import "time"
type RoleDTO struct {
Id int64 `json:"id"`
Code string `json:"code"`
Name string `json:"name"`
GuardName string `json:"guardName"`
CreatedAt time.Time `json:"createdAt"`
UpdatedAt time.Time `json:"updatedAt"`
}
type CreateRoleDTO struct {
Code string `json:"code" binding:"required"`
Name string `json:"name" binding:"required"`
GuardName string `json:"guardName" binding:"required"`
}
type UpdateRoleDTO struct {
Code string `json:"code" binding:"required"`
Name string `json:"name" binding:"required"`
GuardName string `json:"guardName" binding:"required"`
}
type ListFilter struct {
RoleName string
Page int
Limit int
}
type ListRoleDTO struct {
Count int64 `json:"count"`
Roles []RoleDTO `json:"roles"`
}