Documentation
¶
Index ¶
- Variables
- func ClearDown(ctx context.Context) error
- func Count() (int, error)
- func CountWhere(field string, value any) (int, error)
- func Delete(ctx context.Context, id int, note string) error
- func DeleteBy(ctx context.Context, field string, value any, note string) error
- func DeleteByKey(ctx context.Context, key string, note string) error
- func Drop() error
- func Export(message string)
- func ExportCSV() error
- func FetchDatabaseInstances() func() ([]*database.DB, error)
- func GetDefaultLookup() (lookup.Lookup, error)
- func GetLookup(field, value string) (lookup.Lookup, error)
- func ImportCSV() error
- func Initialise(ctx context.Context, isolateDB bool)
- type Password_Store
- func GetAll() ([]Password_Store, error)
- func GetAllWhere(field string, value any) ([]Password_Store, error)
- func GetBy(field string, value any) (Password_Store, error)
- func GetById(id any) (Password_Store, error)
- func GetByKey(key any) (Password_Store, error)
- func New(ctx context.Context, userKey, password string) (Password_Store, error)
- func PostGet(recordList *[]Password_Store) ([]Password_Store, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( FIELD_ID = "ID" FIELD_Key = "Key" FIELD_Raw = "Raw" FIELD_UserKey = "UserKey" FIELD_Password = "Password" FIELD_Audit = "Audit" )
Define the field set as names
Functions ¶
func FetchDatabaseInstances ¶
FetchDatabaseInstances returns a function that fetches the current database instances.
This function is used to retrieve the active database instances being used by the application. It returns a function that, when called, returns a slice of pointers to `database.DB` and an error.
Returns:
func() ([]*database.DB, error): A function that returns a slice of pointers to `database.DB` and an error.
Example usage:
fetchDBFunc := FetchDatabaseInstances() dbInstances, err := fetchDBFunc() if err != nil { logHandler.ErrorLogger.Printf("Error fetching database instances: %v", err) } for _, db := range dbInstances { fmt.Printf("Database instance: %v\n", db) }
func GetDefaultLookup ¶
func Initialise ¶
Types ¶
type Password_Store ¶
type Password_Store struct { ID int `csv:"-" storm:"id,increment=100000"` // primary key with auto increment Key string `csv:"-" storm:"unique"` // key Raw string `csv:"-" storm:"unique"` // raw ID before encoding UserKey string `csv:"-" storm:"index"` // user key Password string `csv:"-"` Expired dao.StormBool `csv:"-" storm:"index"` // is expired Audit audit.Audit `csv:"-"` // audit data }
Password_Store represents a Password_Store entity.
func GetAll ¶
func GetAll() ([]Password_Store, error)
func GetAllWhere ¶
func GetAllWhere(field string, value any) ([]Password_Store, error)
func GetById ¶
func GetById(id any) (Password_Store, error)
func GetByKey ¶
func GetByKey(key any) (Password_Store, error)
func PostGet ¶
func PostGet(recordList *[]Password_Store) ([]Password_Store, error)
func (*Password_Store) Export ¶
func (record *Password_Store) Export(name string)
func (*Password_Store) PostGet ¶
func (s *Password_Store) PostGet() error
func (*Password_Store) Spew ¶
func (record *Password_Store) Spew()
func (*Password_Store) Update ¶
func (record *Password_Store) Update(ctx context.Context, note string) error
func (*Password_Store) Validate ¶
func (record *Password_Store) Validate() error
Click to show internal directories.
Click to hide internal directories.