Documentation
¶
Index ¶
- Variables
- func AskJSON(tid, uid NodeID, mk MK, plr io.ReadCloser) (pl any, err error)
- func CloseDB() (err error)
- func CreateUser(nm, email, pwd string) error
- func FileExists(fn string) bool
- func GenerateSecret(l int) ([]byte, error)
- func InitTree(sdb string, rp RootParms) (err error)
- func RunGUIClient(uid NodeID, c *websocket.Conn) (err error)
- func Stop() (err error)
- type DC
- type E
- type GUINode
- type GroupNode
- type H
- type HF
- type Head
- type MK
- type Msg
- type NK
- type Node
- type NodeID
- type ParmModel
- type Pipe
- type RootNode
- type RootParms
- type SK
- type Tag
- type TreeEntry
- type TreeUpdaterNode
- type UserNode
- type UserParms
- type UsersNode
- type UsersParms
- type WSMK
Constants ¶
This section is empty.
Variables ¶
View Source
var Db *gorm.DB
View Source
var JwtKey []byte
View Source
var LogLevel = new(slog.LevelVar)
View Source
var LogLevelNames = map[string]slog.Level{ "info": slog.LevelInfo, "debug": slog.LevelDebug, "warn": slog.LevelWarn, "error": slog.LevelError, }
View Source
var MKNames = map[MK]string{ M_OK: "OK", M_Error: "Error", M_Create: "Create", M_Rename: "Rename", M_Delete: "Delete", M_Get_Parms: "Get_Parms", M_Get_Auth: "Get_Auth", M_Get_Tree: "Get_Tree", M_Get_Display: "Get_Display", M_Get_Child: "Get_Child", M_Update_Parms: "Update_Parms", M_Refresh_Node: "Refresh_Node", M_Refresh_Tree: "Refresh_Tree", M_Subscribe: "Subscribe", M_Unsubscribe: "Unsubscribe", M_Stop: "Stop", M_UpdatePath: "UpdatePath", }
MNames is exported for logging purposes.
View Source
var NKNames = map[NK]string{ NK_Root: "Root", NK_Group: "Group", NK_User: "User", NK_Account: "Account", NK_Trader: "Broker", NK_TreeUpdater: "TreeUpdater", NK_Users: "Users", NK_GUI: "GUI", }
TODO: We need to rename this to NNames.
System user is a special user that can do anything.
View Source
var Tree = nodeTree{ // contains filtered or unexported fields }
Functions ¶
func CreateUser ¶
func FileExists ¶
func GenerateSecret ¶
Types ¶
type Msg ¶
func NewErrorMsg ¶
type RootParms ¶
func GetServerParms ¶
type Tag ¶
type TreeUpdaterNode ¶
type TreeUpdaterNode struct {
*Head
// contains filtered or unexported fields
}
type UsersNode ¶
type UsersNode struct {
*Head
Parms *UsersParms
}
type UsersParms ¶
Click to show internal directories.
Click to hide internal directories.