settingsmodel

package
v0.14.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 31, 2025 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SettingsModel

type SettingsModel struct {
	DB *domain.DB
	// contains filtered or unexported fields
}

SettingsModel represents the model for settings

func (*SettingsModel) DeleteTSNet added in v0.14.0

func (m *SettingsModel) DeleteTSNet() error

func (*SettingsModel) Get

func (m *SettingsModel) Get() (domain.Settings, error)

Get returns the settings except for tsnet

func (*SettingsModel) GetTSNet added in v0.14.0

func (m *SettingsModel) GetTSNet() (domain.TSNetCommon, error)

func (*SettingsModel) PrepareStatements

func (m *SettingsModel) PrepareStatements()

PrepareStatements prepares the statements

func (*SettingsModel) SetRegistrationOpen

func (m *SettingsModel) SetRegistrationOpen(open bool) error

SetRegistrationOpen sets the registration open column in settings row

func (*SettingsModel) SetTSNet added in v0.14.0

func (m *SettingsModel) SetTSNet(config domain.TSNetCommon) error

func (*SettingsModel) SetTSNetConnect added in v0.14.0

func (m *SettingsModel) SetTSNetConnect(connect bool) error

type TSNetConfig added in v0.14.0

type TSNetConfig struct {
	ControlURL string `db:"tsnet_control_url"`
	Hostname   string `db:"tsnet_hostname"`
	Connect    bool   `db:"tsnet_connect"`
}

TSNetConfig is domain.TSNetCommon but with different db struct tags

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL