Help us shape the future of Go! Take the 2026 Go Developer Survey

dbaudit

package module
v0.8.2 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2019 License: MIT Imports: 3 Imported by: 1

README

dbaudit

Module for tracking create and update audit attributes for database records

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Audit

type Audit struct {
	CreateClientID  uuid.UUID
	CreatePersonID  uuid.UUID
	CreateTimestamp time.Time
	UpdateClientID  uuid.UUID
	UpdatePersonID  uuid.UUID
	UpdateTimestamp time.Time
}

Audit represents fields meant to track when an action was taken and by whom

func NewForCreate added in v0.6.4

func NewForCreate(clientID uuid.UUID, personID uuid.UUID) *Audit

NewForCreate is a constructor that takes a Client and User and populates CreateClient, CreateUser, UpdateClient and UpdateUser (as they all should be the same)

func (Audit) Valid added in v0.6.0

func (a Audit) Valid() error

Valid ensures that CreateClient, CreateUser, UpdateClient and UpdateUser are populated

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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