Reimplement
This commit is contained in:
1 parent
5e72ec3864
commit
4e96b7a930
91 files changed
+1774
-7627
No files matched your search
@@ -1,46 +0,0 @@
|
||||
package entity
|
||||
|
||||
import (
|
||||
"time"
|
||||
|
||||
"github.com/integration-system/isp-lib/v2/config/schema"
|
||||
)
|
||||
|
||||
type ConfigData map[string]interface{}
|
||||
|
||||
type Config struct {
|
||||
//nolint
|
||||
tableName string `pg:"?db_schema.configs" json:"-"`
|
||||
Id string `json:"id"`
|
||||
Name string `json:"name" valid:"required~Required"`
|
||||
CommonConfigs []string `json:"commonConfigs" pg:",array"`
|
||||
Description string `json:"description"`
|
||||
ModuleId string `json:"moduleId" valid:"required~Required"`
|
||||
Version int32 `json:"version" pg:",null"`
|
||||
Active bool `json:"active" pg:",null"`
|
||||
CreatedAt time.Time `json:"createdAt" pg:",null"`
|
||||
UpdatedAt time.Time `json:"updatedAt" pg:",null"`
|
||||
Data ConfigData `json:"data,omitempty" pg:",notnull"`
|
||||
}
|
||||
|
||||
type CommonConfig struct {
|
||||
//nolint
|
||||
tableName string `pg:"?db_schema.common_configs" json:"-"`
|
||||
Id string `json:"id"`
|
||||
Name string `json:"name" valid:"required~Required"`
|
||||
Description string `json:"description"`
|
||||
CreatedAt time.Time `json:"createdAt" pg:",null"`
|
||||
UpdatedAt time.Time `json:"updatedAt" pg:",null"`
|
||||
Data ConfigData `json:"data" pg:",notnull"`
|
||||
}
|
||||
|
||||
type ConfigSchema struct {
|
||||
//nolint
|
||||
tableName string `pg:"?db_schema.config_schemas" json:"-"`
|
||||
Id string `json:"id"`
|
||||
Version string
|
||||
ModuleId string
|
||||
Schema schema.Schema
|
||||
CreatedAt time.Time
|
||||
UpdatedAt time.Time
|
||||
}
|
||||
+8
-8
@@ -1,13 +1,13 @@
|
||||
package entity
|
||||
|
||||
import "time"
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
||||
type Module struct {
|
||||
//nolint
|
||||
tableName string `pg:"?db_schema.modules" json:"-"`
|
||||
Id string `json:"id"`
|
||||
Name string `json:"name" valid:"required~Required"`
|
||||
CreatedAt time.Time `json:"createdAt" pg:",null"`
|
||||
LastConnectedAt time.Time `json:"lastConnectedAt"`
|
||||
LastDisconnectedAt time.Time `json:"lastDisconnectedAt"`
|
||||
Id string
|
||||
Name string
|
||||
LastConnectedAt time.Time
|
||||
LastDisconnectedAt time.Time
|
||||
Created time.Time
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
package entity
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
||||
type VersionConfig struct {
|
||||
//nolint
|
||||
tableName string `pg:"?db_schema.version_config" json:"-"`
|
||||
Id string
|
||||
ConfigId string
|
||||
ConfigVersion int32
|
||||
Data ConfigData `json:"data,omitempty" pg:",notnull"`
|
||||
CreatedAt time.Time
|
||||
}
|
||||
Reference in new issue
Block a user