Some checks failed
CI / build-and-test (push) Failing after -31m25s
* Update project creation and retrieval to use generated models * Modify skill addition and listing to utilize generated models * Refactor thought handling to incorporate generated models * Adjust tool annotations to align with new model structure * Update API calls in the UI to use new ResolveSpec-based endpoints * Enhance stats retrieval logic to aggregate thought metadata
67 lines
2.6 KiB
Go
67 lines
2.6 KiB
Go
// Code generated by relspecgo. DO NOT EDIT.
|
|
package generatedmodels
|
|
|
|
import (
|
|
"fmt"
|
|
resolvespec_common "github.com/bitechdev/ResolveSpec/pkg/spectypes"
|
|
"github.com/uptrace/bun"
|
|
)
|
|
|
|
type ModelPublicImportantDates struct {
|
|
bun.BaseModel `bun:"table:public.important_dates,alias:important_dates"`
|
|
ID resolvespec_common.SqlUUID `bun:"id,type:uuid,pk,default:gen_random_uuid()," json:"id"`
|
|
CreatedAt resolvespec_common.SqlTimeStamp `bun:"created_at,type:timestamptz,default:now(),notnull," json:"created_at"`
|
|
DateValue resolvespec_common.SqlDate `bun:"date_value,type:date,notnull," json:"date_value"`
|
|
FamilyMemberID resolvespec_common.SqlUUID `bun:"family_member_id,type:uuid,nullzero," json:"family_member_id"`
|
|
Notes resolvespec_common.SqlString `bun:"notes,type:text,nullzero," json:"notes"`
|
|
RecurringYearly bool `bun:"recurring_yearly,type:boolean,default:false,notnull," json:"recurring_yearly"`
|
|
ReminderDaysBefore resolvespec_common.SqlInt32 `bun:"reminder_days_before,type:int,default:7,notnull," json:"reminder_days_before"`
|
|
Title resolvespec_common.SqlString `bun:"title,type:text,notnull," json:"title"`
|
|
RelFamilyMemberID *ModelPublicFamilyMembers `bun:"rel:has-one,join:family_member_id=id" json:"relfamilymemberid,omitempty"` // Has one ModelPublicFamilyMembers
|
|
}
|
|
|
|
// TableName returns the table name for ModelPublicImportantDates
|
|
func (m ModelPublicImportantDates) TableName() string {
|
|
return "public.important_dates"
|
|
}
|
|
|
|
// TableNameOnly returns the table name without schema for ModelPublicImportantDates
|
|
func (m ModelPublicImportantDates) TableNameOnly() string {
|
|
return "important_dates"
|
|
}
|
|
|
|
// SchemaName returns the schema name for ModelPublicImportantDates
|
|
func (m ModelPublicImportantDates) SchemaName() string {
|
|
return "public"
|
|
}
|
|
|
|
// GetID returns the primary key value
|
|
func (m ModelPublicImportantDates) GetID() int64 {
|
|
return m.ID.Int64()
|
|
}
|
|
|
|
// GetIDStr returns the primary key as a string
|
|
func (m ModelPublicImportantDates) GetIDStr() string {
|
|
return fmt.Sprintf("%v", m.ID)
|
|
}
|
|
|
|
// SetID sets the primary key value
|
|
func (m ModelPublicImportantDates) SetID(newid int64) {
|
|
m.UpdateID(newid)
|
|
}
|
|
|
|
// UpdateID updates the primary key value
|
|
func (m *ModelPublicImportantDates) UpdateID(newid int64) {
|
|
m.ID.FromString(fmt.Sprintf("%d", newid))
|
|
}
|
|
|
|
// GetIDName returns the name of the primary key column
|
|
func (m ModelPublicImportantDates) GetIDName() string {
|
|
return "id"
|
|
}
|
|
|
|
// GetPrefix returns the table prefix
|
|
func (m ModelPublicImportantDates) GetPrefix() string {
|
|
return "IDM"
|
|
}
|