timesheetsdb

package
v0.0.0-...-35b29b9 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2026 License: AGPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Departments

type Departments struct {
	ot.Fact[any]

	Dept_id uuid.UUID `fact:"key"`

	Dept_name string

	Description string

	Headcount_budget int
}

func NewDepartments

func NewDepartments(Dept_id uuid.UUID, Dept_name string, Description string, Headcount_budget int, gc bool) *Departments

func (Departments) Keys

func (t Departments) Keys() []any

func (Departments) ToBytes

func (p Departments) ToBytes() []byte

type Employees

type Employees struct {
	ot.Fact[any]

	Employee_id uuid.UUID `fact:"key"`

	Dept_id uuid.UUID

	First_name string

	Last_name string

	Work_email string

	Phone string

	Job_title string

	Salary float64

	Hire_date time.Time

	Is_active bool
}

func NewEmployees

func NewEmployees(Employee_id uuid.UUID, Dept_id uuid.UUID, First_name string, Last_name string, Work_email string, Phone string, Job_title string, Salary float64, Hire_date time.Time, Is_active bool, gc bool) *Employees

func (Employees) Keys

func (t Employees) Keys() []any

func (Employees) ToBytes

func (p Employees) ToBytes() []byte

type Timesheets

type Timesheets struct {
	ot.Fact[any]

	Timesheet_id uuid.UUID `fact:"key"`

	Employee_id uuid.UUID

	Work_date time.Time

	Hours_worked int

	Task_description string

	Is_approved bool
}

func NewTimesheets

func NewTimesheets(Timesheet_id uuid.UUID, Employee_id uuid.UUID, Work_date time.Time, Hours_worked int, Task_description string, Is_approved bool, gc bool) *Timesheets

func (Timesheets) Keys

func (t Timesheets) Keys() []any

func (Timesheets) ToBytes

func (p Timesheets) ToBytes() []byte

type Timesheetsdb

type Timesheetsdb struct {
	Queries    map[string]*query
	SubQueries map[string]*subquery
	Db         *mayfairdb.DataSortDb
	// contains filtered or unexported fields
}

func NewTimesheetsdb

func NewTimesheetsdb(db *mayfairdb.DataSortDb) *Timesheetsdb

func (*Timesheetsdb) Generate

func (b *Timesheetsdb) Generate()

func (*Timesheetsdb) GenerateQueries

func (b *Timesheetsdb) GenerateQueries()

func (*Timesheetsdb) GenerateSubQueries

func (b *Timesheetsdb) GenerateSubQueries()

GenerateSubQueries will produce the necessary basic queries like 'SELECT id FROM tracks WHERE track.country = "USA"' There are subqueries that are part of a query, possibly combined through a set operation like UNION, INTERSECT, etc. These queries will have an id like 'sql2.sq.434'

Other types of subqueries are used in other subqueries like in 'SELECT id FROM (SELECT * FROM tracks WHERE track.country = "USA")' these will have an id different from the query's subqueries, e.g. 'sql36.ta.456'

Jump to

Keyboard shortcuts

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