2024-03-25 16:24:48: merge [main:72a62d1996eb71f9a1ab21643bf294148b87ae99];

This commit is contained in:
txix committed 2024-03-25 16:24:48 +03:00
1 parent 0669c6ec0a
commit ed8a4eef5d
85 files changed
+7671 -93

No files matched your search

+36
View File
@@ -0,0 +1,36 @@
package entity
import (
"database/sql/driver"
"time"
"github.com/integration-system/isp-kit/json"
)
const (
GroupOperationAdd = "ADD"
GroupOperationDelete = "DELETE"
)
type Role struct {
Id int
Name string
ExternalGroup string
Permissions PermList
Immutable bool
Exclusive bool
CreatedAt time.Time
UpdatedAt time.Time
}
type PermList []string
// nolint
func (p *PermList) Scan(src any) error {
return json.Unmarshal(src.([]byte), p)
}
func (p PermList) Value() (driver.Value, error) {
bytes, err := json.Marshal(p)
return driver.Value(bytes), err
}