This involves a lot of copy-pasta of code from the previous version of this logic in another code base. It'll need to be cleaned up, but for now I need something sooner rather than later.
4029 lines
134 KiB
Go
4029 lines
134 KiB
Go
// Code generated by BobGen psql v0.41.1. DO NOT EDIT.
|
|
// This file is meant to be re-generated in place and/or deleted at any time.
|
|
|
|
package factory
|
|
|
|
import (
|
|
"context"
|
|
"testing"
|
|
|
|
models "github.com/Gleipnir-Technology/nidus-sync/models"
|
|
"github.com/aarondl/opt/null"
|
|
"github.com/aarondl/opt/omit"
|
|
"github.com/aarondl/opt/omitnull"
|
|
"github.com/jaswdr/faker/v2"
|
|
"github.com/stephenafamo/bob"
|
|
)
|
|
|
|
type HistoryMosquitoinspectionMod interface {
|
|
Apply(context.Context, *HistoryMosquitoinspectionTemplate)
|
|
}
|
|
|
|
type HistoryMosquitoinspectionModFunc func(context.Context, *HistoryMosquitoinspectionTemplate)
|
|
|
|
func (f HistoryMosquitoinspectionModFunc) Apply(ctx context.Context, n *HistoryMosquitoinspectionTemplate) {
|
|
f(ctx, n)
|
|
}
|
|
|
|
type HistoryMosquitoinspectionModSlice []HistoryMosquitoinspectionMod
|
|
|
|
func (mods HistoryMosquitoinspectionModSlice) Apply(ctx context.Context, n *HistoryMosquitoinspectionTemplate) {
|
|
for _, f := range mods {
|
|
f.Apply(ctx, n)
|
|
}
|
|
}
|
|
|
|
// HistoryMosquitoinspectionTemplate is an object representing the database table.
|
|
// all columns are optional and should be set by mods
|
|
type HistoryMosquitoinspectionTemplate struct {
|
|
OrganizationID func() null.Val[int32]
|
|
Actiontaken func() null.Val[string]
|
|
Activity func() null.Val[string]
|
|
Adultact func() null.Val[string]
|
|
Avetemp func() null.Val[float64]
|
|
Avglarvae func() null.Val[float64]
|
|
Avgpupae func() null.Val[float64]
|
|
Breeding func() null.Val[string]
|
|
Cbcount func() null.Val[int16]
|
|
Comments func() null.Val[string]
|
|
Containercount func() null.Val[int16]
|
|
Creationdate func() null.Val[int64]
|
|
Creator func() null.Val[string]
|
|
Domstage func() null.Val[string]
|
|
Eggs func() null.Val[int16]
|
|
Enddatetime func() null.Val[int64]
|
|
Editdate func() null.Val[int64]
|
|
Editor func() null.Val[string]
|
|
Fieldspecies func() null.Val[string]
|
|
Fieldtech func() null.Val[string]
|
|
Globalid func() null.Val[string]
|
|
Jurisdiction func() null.Val[string]
|
|
Larvaepresent func() null.Val[int16]
|
|
Linelocid func() null.Val[string]
|
|
Locationname func() null.Val[string]
|
|
Lstages func() null.Val[string]
|
|
Numdips func() null.Val[int16]
|
|
Objectid func() int32
|
|
Personalcontact func() null.Val[int16]
|
|
Pointlocid func() null.Val[string]
|
|
Polygonlocid func() null.Val[string]
|
|
Posdips func() null.Val[int16]
|
|
Positivecontainercount func() null.Val[int16]
|
|
Pupaepresent func() null.Val[int16]
|
|
Raingauge func() null.Val[float64]
|
|
Recordstatus func() null.Val[int16]
|
|
Reviewed func() null.Val[int16]
|
|
Reviewedby func() null.Val[string]
|
|
Revieweddate func() null.Val[int64]
|
|
Sdid func() null.Val[string]
|
|
Sitecond func() null.Val[string]
|
|
Srid func() null.Val[string]
|
|
Startdatetime func() null.Val[int64]
|
|
Tirecount func() null.Val[int16]
|
|
Totlarvae func() null.Val[int16]
|
|
Totpupae func() null.Val[int16]
|
|
Visualmonitoring func() null.Val[int16]
|
|
Vmcomments func() null.Val[string]
|
|
Winddir func() null.Val[string]
|
|
Windspeed func() null.Val[float64]
|
|
Zone func() null.Val[string]
|
|
Zone2 func() null.Val[string]
|
|
CreatedDate func() null.Val[int64]
|
|
CreatedUser func() null.Val[string]
|
|
GeometryX func() null.Val[float64]
|
|
GeometryY func() null.Val[float64]
|
|
LastEditedDate func() null.Val[int64]
|
|
LastEditedUser func() null.Val[string]
|
|
Adminaction func() null.Val[string]
|
|
Ptaid func() null.Val[string]
|
|
Version func() int32
|
|
|
|
r historyMosquitoinspectionR
|
|
f *Factory
|
|
|
|
alreadyPersisted bool
|
|
}
|
|
|
|
type historyMosquitoinspectionR struct {
|
|
Organization *historyMosquitoinspectionROrganizationR
|
|
}
|
|
|
|
type historyMosquitoinspectionROrganizationR struct {
|
|
o *OrganizationTemplate
|
|
}
|
|
|
|
// Apply mods to the HistoryMosquitoinspectionTemplate
|
|
func (o *HistoryMosquitoinspectionTemplate) Apply(ctx context.Context, mods ...HistoryMosquitoinspectionMod) {
|
|
for _, mod := range mods {
|
|
mod.Apply(ctx, o)
|
|
}
|
|
}
|
|
|
|
// setModelRels creates and sets the relationships on *models.HistoryMosquitoinspection
|
|
// according to the relationships in the template. Nothing is inserted into the db
|
|
func (t HistoryMosquitoinspectionTemplate) setModelRels(o *models.HistoryMosquitoinspection) {
|
|
if t.r.Organization != nil {
|
|
rel := t.r.Organization.o.Build()
|
|
rel.R.HistoryMosquitoinspections = append(rel.R.HistoryMosquitoinspections, o)
|
|
o.OrganizationID = null.From(rel.ID) // h2
|
|
o.R.Organization = rel
|
|
}
|
|
}
|
|
|
|
// BuildSetter returns an *models.HistoryMosquitoinspectionSetter
|
|
// this does nothing with the relationship templates
|
|
func (o HistoryMosquitoinspectionTemplate) BuildSetter() *models.HistoryMosquitoinspectionSetter {
|
|
m := &models.HistoryMosquitoinspectionSetter{}
|
|
|
|
if o.OrganizationID != nil {
|
|
val := o.OrganizationID()
|
|
m.OrganizationID = omitnull.FromNull(val)
|
|
}
|
|
if o.Actiontaken != nil {
|
|
val := o.Actiontaken()
|
|
m.Actiontaken = omitnull.FromNull(val)
|
|
}
|
|
if o.Activity != nil {
|
|
val := o.Activity()
|
|
m.Activity = omitnull.FromNull(val)
|
|
}
|
|
if o.Adultact != nil {
|
|
val := o.Adultact()
|
|
m.Adultact = omitnull.FromNull(val)
|
|
}
|
|
if o.Avetemp != nil {
|
|
val := o.Avetemp()
|
|
m.Avetemp = omitnull.FromNull(val)
|
|
}
|
|
if o.Avglarvae != nil {
|
|
val := o.Avglarvae()
|
|
m.Avglarvae = omitnull.FromNull(val)
|
|
}
|
|
if o.Avgpupae != nil {
|
|
val := o.Avgpupae()
|
|
m.Avgpupae = omitnull.FromNull(val)
|
|
}
|
|
if o.Breeding != nil {
|
|
val := o.Breeding()
|
|
m.Breeding = omitnull.FromNull(val)
|
|
}
|
|
if o.Cbcount != nil {
|
|
val := o.Cbcount()
|
|
m.Cbcount = omitnull.FromNull(val)
|
|
}
|
|
if o.Comments != nil {
|
|
val := o.Comments()
|
|
m.Comments = omitnull.FromNull(val)
|
|
}
|
|
if o.Containercount != nil {
|
|
val := o.Containercount()
|
|
m.Containercount = omitnull.FromNull(val)
|
|
}
|
|
if o.Creationdate != nil {
|
|
val := o.Creationdate()
|
|
m.Creationdate = omitnull.FromNull(val)
|
|
}
|
|
if o.Creator != nil {
|
|
val := o.Creator()
|
|
m.Creator = omitnull.FromNull(val)
|
|
}
|
|
if o.Domstage != nil {
|
|
val := o.Domstage()
|
|
m.Domstage = omitnull.FromNull(val)
|
|
}
|
|
if o.Eggs != nil {
|
|
val := o.Eggs()
|
|
m.Eggs = omitnull.FromNull(val)
|
|
}
|
|
if o.Enddatetime != nil {
|
|
val := o.Enddatetime()
|
|
m.Enddatetime = omitnull.FromNull(val)
|
|
}
|
|
if o.Editdate != nil {
|
|
val := o.Editdate()
|
|
m.Editdate = omitnull.FromNull(val)
|
|
}
|
|
if o.Editor != nil {
|
|
val := o.Editor()
|
|
m.Editor = omitnull.FromNull(val)
|
|
}
|
|
if o.Fieldspecies != nil {
|
|
val := o.Fieldspecies()
|
|
m.Fieldspecies = omitnull.FromNull(val)
|
|
}
|
|
if o.Fieldtech != nil {
|
|
val := o.Fieldtech()
|
|
m.Fieldtech = omitnull.FromNull(val)
|
|
}
|
|
if o.Globalid != nil {
|
|
val := o.Globalid()
|
|
m.Globalid = omitnull.FromNull(val)
|
|
}
|
|
if o.Jurisdiction != nil {
|
|
val := o.Jurisdiction()
|
|
m.Jurisdiction = omitnull.FromNull(val)
|
|
}
|
|
if o.Larvaepresent != nil {
|
|
val := o.Larvaepresent()
|
|
m.Larvaepresent = omitnull.FromNull(val)
|
|
}
|
|
if o.Linelocid != nil {
|
|
val := o.Linelocid()
|
|
m.Linelocid = omitnull.FromNull(val)
|
|
}
|
|
if o.Locationname != nil {
|
|
val := o.Locationname()
|
|
m.Locationname = omitnull.FromNull(val)
|
|
}
|
|
if o.Lstages != nil {
|
|
val := o.Lstages()
|
|
m.Lstages = omitnull.FromNull(val)
|
|
}
|
|
if o.Numdips != nil {
|
|
val := o.Numdips()
|
|
m.Numdips = omitnull.FromNull(val)
|
|
}
|
|
if o.Objectid != nil {
|
|
val := o.Objectid()
|
|
m.Objectid = omit.From(val)
|
|
}
|
|
if o.Personalcontact != nil {
|
|
val := o.Personalcontact()
|
|
m.Personalcontact = omitnull.FromNull(val)
|
|
}
|
|
if o.Pointlocid != nil {
|
|
val := o.Pointlocid()
|
|
m.Pointlocid = omitnull.FromNull(val)
|
|
}
|
|
if o.Polygonlocid != nil {
|
|
val := o.Polygonlocid()
|
|
m.Polygonlocid = omitnull.FromNull(val)
|
|
}
|
|
if o.Posdips != nil {
|
|
val := o.Posdips()
|
|
m.Posdips = omitnull.FromNull(val)
|
|
}
|
|
if o.Positivecontainercount != nil {
|
|
val := o.Positivecontainercount()
|
|
m.Positivecontainercount = omitnull.FromNull(val)
|
|
}
|
|
if o.Pupaepresent != nil {
|
|
val := o.Pupaepresent()
|
|
m.Pupaepresent = omitnull.FromNull(val)
|
|
}
|
|
if o.Raingauge != nil {
|
|
val := o.Raingauge()
|
|
m.Raingauge = omitnull.FromNull(val)
|
|
}
|
|
if o.Recordstatus != nil {
|
|
val := o.Recordstatus()
|
|
m.Recordstatus = omitnull.FromNull(val)
|
|
}
|
|
if o.Reviewed != nil {
|
|
val := o.Reviewed()
|
|
m.Reviewed = omitnull.FromNull(val)
|
|
}
|
|
if o.Reviewedby != nil {
|
|
val := o.Reviewedby()
|
|
m.Reviewedby = omitnull.FromNull(val)
|
|
}
|
|
if o.Revieweddate != nil {
|
|
val := o.Revieweddate()
|
|
m.Revieweddate = omitnull.FromNull(val)
|
|
}
|
|
if o.Sdid != nil {
|
|
val := o.Sdid()
|
|
m.Sdid = omitnull.FromNull(val)
|
|
}
|
|
if o.Sitecond != nil {
|
|
val := o.Sitecond()
|
|
m.Sitecond = omitnull.FromNull(val)
|
|
}
|
|
if o.Srid != nil {
|
|
val := o.Srid()
|
|
m.Srid = omitnull.FromNull(val)
|
|
}
|
|
if o.Startdatetime != nil {
|
|
val := o.Startdatetime()
|
|
m.Startdatetime = omitnull.FromNull(val)
|
|
}
|
|
if o.Tirecount != nil {
|
|
val := o.Tirecount()
|
|
m.Tirecount = omitnull.FromNull(val)
|
|
}
|
|
if o.Totlarvae != nil {
|
|
val := o.Totlarvae()
|
|
m.Totlarvae = omitnull.FromNull(val)
|
|
}
|
|
if o.Totpupae != nil {
|
|
val := o.Totpupae()
|
|
m.Totpupae = omitnull.FromNull(val)
|
|
}
|
|
if o.Visualmonitoring != nil {
|
|
val := o.Visualmonitoring()
|
|
m.Visualmonitoring = omitnull.FromNull(val)
|
|
}
|
|
if o.Vmcomments != nil {
|
|
val := o.Vmcomments()
|
|
m.Vmcomments = omitnull.FromNull(val)
|
|
}
|
|
if o.Winddir != nil {
|
|
val := o.Winddir()
|
|
m.Winddir = omitnull.FromNull(val)
|
|
}
|
|
if o.Windspeed != nil {
|
|
val := o.Windspeed()
|
|
m.Windspeed = omitnull.FromNull(val)
|
|
}
|
|
if o.Zone != nil {
|
|
val := o.Zone()
|
|
m.Zone = omitnull.FromNull(val)
|
|
}
|
|
if o.Zone2 != nil {
|
|
val := o.Zone2()
|
|
m.Zone2 = omitnull.FromNull(val)
|
|
}
|
|
if o.CreatedDate != nil {
|
|
val := o.CreatedDate()
|
|
m.CreatedDate = omitnull.FromNull(val)
|
|
}
|
|
if o.CreatedUser != nil {
|
|
val := o.CreatedUser()
|
|
m.CreatedUser = omitnull.FromNull(val)
|
|
}
|
|
if o.GeometryX != nil {
|
|
val := o.GeometryX()
|
|
m.GeometryX = omitnull.FromNull(val)
|
|
}
|
|
if o.GeometryY != nil {
|
|
val := o.GeometryY()
|
|
m.GeometryY = omitnull.FromNull(val)
|
|
}
|
|
if o.LastEditedDate != nil {
|
|
val := o.LastEditedDate()
|
|
m.LastEditedDate = omitnull.FromNull(val)
|
|
}
|
|
if o.LastEditedUser != nil {
|
|
val := o.LastEditedUser()
|
|
m.LastEditedUser = omitnull.FromNull(val)
|
|
}
|
|
if o.Adminaction != nil {
|
|
val := o.Adminaction()
|
|
m.Adminaction = omitnull.FromNull(val)
|
|
}
|
|
if o.Ptaid != nil {
|
|
val := o.Ptaid()
|
|
m.Ptaid = omitnull.FromNull(val)
|
|
}
|
|
if o.Version != nil {
|
|
val := o.Version()
|
|
m.Version = omit.From(val)
|
|
}
|
|
|
|
return m
|
|
}
|
|
|
|
// BuildManySetter returns an []*models.HistoryMosquitoinspectionSetter
|
|
// this does nothing with the relationship templates
|
|
func (o HistoryMosquitoinspectionTemplate) BuildManySetter(number int) []*models.HistoryMosquitoinspectionSetter {
|
|
m := make([]*models.HistoryMosquitoinspectionSetter, number)
|
|
|
|
for i := range m {
|
|
m[i] = o.BuildSetter()
|
|
}
|
|
|
|
return m
|
|
}
|
|
|
|
// Build returns an *models.HistoryMosquitoinspection
|
|
// Related objects are also created and placed in the .R field
|
|
// NOTE: Objects are not inserted into the database. Use HistoryMosquitoinspectionTemplate.Create
|
|
func (o HistoryMosquitoinspectionTemplate) Build() *models.HistoryMosquitoinspection {
|
|
m := &models.HistoryMosquitoinspection{}
|
|
|
|
if o.OrganizationID != nil {
|
|
m.OrganizationID = o.OrganizationID()
|
|
}
|
|
if o.Actiontaken != nil {
|
|
m.Actiontaken = o.Actiontaken()
|
|
}
|
|
if o.Activity != nil {
|
|
m.Activity = o.Activity()
|
|
}
|
|
if o.Adultact != nil {
|
|
m.Adultact = o.Adultact()
|
|
}
|
|
if o.Avetemp != nil {
|
|
m.Avetemp = o.Avetemp()
|
|
}
|
|
if o.Avglarvae != nil {
|
|
m.Avglarvae = o.Avglarvae()
|
|
}
|
|
if o.Avgpupae != nil {
|
|
m.Avgpupae = o.Avgpupae()
|
|
}
|
|
if o.Breeding != nil {
|
|
m.Breeding = o.Breeding()
|
|
}
|
|
if o.Cbcount != nil {
|
|
m.Cbcount = o.Cbcount()
|
|
}
|
|
if o.Comments != nil {
|
|
m.Comments = o.Comments()
|
|
}
|
|
if o.Containercount != nil {
|
|
m.Containercount = o.Containercount()
|
|
}
|
|
if o.Creationdate != nil {
|
|
m.Creationdate = o.Creationdate()
|
|
}
|
|
if o.Creator != nil {
|
|
m.Creator = o.Creator()
|
|
}
|
|
if o.Domstage != nil {
|
|
m.Domstage = o.Domstage()
|
|
}
|
|
if o.Eggs != nil {
|
|
m.Eggs = o.Eggs()
|
|
}
|
|
if o.Enddatetime != nil {
|
|
m.Enddatetime = o.Enddatetime()
|
|
}
|
|
if o.Editdate != nil {
|
|
m.Editdate = o.Editdate()
|
|
}
|
|
if o.Editor != nil {
|
|
m.Editor = o.Editor()
|
|
}
|
|
if o.Fieldspecies != nil {
|
|
m.Fieldspecies = o.Fieldspecies()
|
|
}
|
|
if o.Fieldtech != nil {
|
|
m.Fieldtech = o.Fieldtech()
|
|
}
|
|
if o.Globalid != nil {
|
|
m.Globalid = o.Globalid()
|
|
}
|
|
if o.Jurisdiction != nil {
|
|
m.Jurisdiction = o.Jurisdiction()
|
|
}
|
|
if o.Larvaepresent != nil {
|
|
m.Larvaepresent = o.Larvaepresent()
|
|
}
|
|
if o.Linelocid != nil {
|
|
m.Linelocid = o.Linelocid()
|
|
}
|
|
if o.Locationname != nil {
|
|
m.Locationname = o.Locationname()
|
|
}
|
|
if o.Lstages != nil {
|
|
m.Lstages = o.Lstages()
|
|
}
|
|
if o.Numdips != nil {
|
|
m.Numdips = o.Numdips()
|
|
}
|
|
if o.Objectid != nil {
|
|
m.Objectid = o.Objectid()
|
|
}
|
|
if o.Personalcontact != nil {
|
|
m.Personalcontact = o.Personalcontact()
|
|
}
|
|
if o.Pointlocid != nil {
|
|
m.Pointlocid = o.Pointlocid()
|
|
}
|
|
if o.Polygonlocid != nil {
|
|
m.Polygonlocid = o.Polygonlocid()
|
|
}
|
|
if o.Posdips != nil {
|
|
m.Posdips = o.Posdips()
|
|
}
|
|
if o.Positivecontainercount != nil {
|
|
m.Positivecontainercount = o.Positivecontainercount()
|
|
}
|
|
if o.Pupaepresent != nil {
|
|
m.Pupaepresent = o.Pupaepresent()
|
|
}
|
|
if o.Raingauge != nil {
|
|
m.Raingauge = o.Raingauge()
|
|
}
|
|
if o.Recordstatus != nil {
|
|
m.Recordstatus = o.Recordstatus()
|
|
}
|
|
if o.Reviewed != nil {
|
|
m.Reviewed = o.Reviewed()
|
|
}
|
|
if o.Reviewedby != nil {
|
|
m.Reviewedby = o.Reviewedby()
|
|
}
|
|
if o.Revieweddate != nil {
|
|
m.Revieweddate = o.Revieweddate()
|
|
}
|
|
if o.Sdid != nil {
|
|
m.Sdid = o.Sdid()
|
|
}
|
|
if o.Sitecond != nil {
|
|
m.Sitecond = o.Sitecond()
|
|
}
|
|
if o.Srid != nil {
|
|
m.Srid = o.Srid()
|
|
}
|
|
if o.Startdatetime != nil {
|
|
m.Startdatetime = o.Startdatetime()
|
|
}
|
|
if o.Tirecount != nil {
|
|
m.Tirecount = o.Tirecount()
|
|
}
|
|
if o.Totlarvae != nil {
|
|
m.Totlarvae = o.Totlarvae()
|
|
}
|
|
if o.Totpupae != nil {
|
|
m.Totpupae = o.Totpupae()
|
|
}
|
|
if o.Visualmonitoring != nil {
|
|
m.Visualmonitoring = o.Visualmonitoring()
|
|
}
|
|
if o.Vmcomments != nil {
|
|
m.Vmcomments = o.Vmcomments()
|
|
}
|
|
if o.Winddir != nil {
|
|
m.Winddir = o.Winddir()
|
|
}
|
|
if o.Windspeed != nil {
|
|
m.Windspeed = o.Windspeed()
|
|
}
|
|
if o.Zone != nil {
|
|
m.Zone = o.Zone()
|
|
}
|
|
if o.Zone2 != nil {
|
|
m.Zone2 = o.Zone2()
|
|
}
|
|
if o.CreatedDate != nil {
|
|
m.CreatedDate = o.CreatedDate()
|
|
}
|
|
if o.CreatedUser != nil {
|
|
m.CreatedUser = o.CreatedUser()
|
|
}
|
|
if o.GeometryX != nil {
|
|
m.GeometryX = o.GeometryX()
|
|
}
|
|
if o.GeometryY != nil {
|
|
m.GeometryY = o.GeometryY()
|
|
}
|
|
if o.LastEditedDate != nil {
|
|
m.LastEditedDate = o.LastEditedDate()
|
|
}
|
|
if o.LastEditedUser != nil {
|
|
m.LastEditedUser = o.LastEditedUser()
|
|
}
|
|
if o.Adminaction != nil {
|
|
m.Adminaction = o.Adminaction()
|
|
}
|
|
if o.Ptaid != nil {
|
|
m.Ptaid = o.Ptaid()
|
|
}
|
|
if o.Version != nil {
|
|
m.Version = o.Version()
|
|
}
|
|
|
|
o.setModelRels(m)
|
|
|
|
return m
|
|
}
|
|
|
|
// BuildMany returns an models.HistoryMosquitoinspectionSlice
|
|
// Related objects are also created and placed in the .R field
|
|
// NOTE: Objects are not inserted into the database. Use HistoryMosquitoinspectionTemplate.CreateMany
|
|
func (o HistoryMosquitoinspectionTemplate) BuildMany(number int) models.HistoryMosquitoinspectionSlice {
|
|
m := make(models.HistoryMosquitoinspectionSlice, number)
|
|
|
|
for i := range m {
|
|
m[i] = o.Build()
|
|
}
|
|
|
|
return m
|
|
}
|
|
|
|
func ensureCreatableHistoryMosquitoinspection(m *models.HistoryMosquitoinspectionSetter) {
|
|
if !(m.Objectid.IsValue()) {
|
|
val := random_int32(nil)
|
|
m.Objectid = omit.From(val)
|
|
}
|
|
if !(m.Version.IsValue()) {
|
|
val := random_int32(nil)
|
|
m.Version = omit.From(val)
|
|
}
|
|
}
|
|
|
|
// insertOptRels creates and inserts any optional the relationships on *models.HistoryMosquitoinspection
|
|
// according to the relationships in the template.
|
|
// any required relationship should have already exist on the model
|
|
func (o *HistoryMosquitoinspectionTemplate) insertOptRels(ctx context.Context, exec bob.Executor, m *models.HistoryMosquitoinspection) error {
|
|
var err error
|
|
|
|
isOrganizationDone, _ := historyMosquitoinspectionRelOrganizationCtx.Value(ctx)
|
|
if !isOrganizationDone && o.r.Organization != nil {
|
|
ctx = historyMosquitoinspectionRelOrganizationCtx.WithValue(ctx, true)
|
|
if o.r.Organization.o.alreadyPersisted {
|
|
m.R.Organization = o.r.Organization.o.Build()
|
|
} else {
|
|
var rel0 *models.Organization
|
|
rel0, err = o.r.Organization.o.Create(ctx, exec)
|
|
if err != nil {
|
|
return err
|
|
}
|
|
err = m.AttachOrganization(ctx, exec, rel0)
|
|
if err != nil {
|
|
return err
|
|
}
|
|
}
|
|
|
|
}
|
|
|
|
return err
|
|
}
|
|
|
|
// Create builds a historyMosquitoinspection and inserts it into the database
|
|
// Relations objects are also inserted and placed in the .R field
|
|
func (o *HistoryMosquitoinspectionTemplate) Create(ctx context.Context, exec bob.Executor) (*models.HistoryMosquitoinspection, error) {
|
|
var err error
|
|
opt := o.BuildSetter()
|
|
ensureCreatableHistoryMosquitoinspection(opt)
|
|
|
|
m, err := models.HistoryMosquitoinspections.Insert(opt).One(ctx, exec)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
if err := o.insertOptRels(ctx, exec, m); err != nil {
|
|
return nil, err
|
|
}
|
|
return m, err
|
|
}
|
|
|
|
// MustCreate builds a historyMosquitoinspection and inserts it into the database
|
|
// Relations objects are also inserted and placed in the .R field
|
|
// panics if an error occurs
|
|
func (o *HistoryMosquitoinspectionTemplate) MustCreate(ctx context.Context, exec bob.Executor) *models.HistoryMosquitoinspection {
|
|
m, err := o.Create(ctx, exec)
|
|
if err != nil {
|
|
panic(err)
|
|
}
|
|
return m
|
|
}
|
|
|
|
// CreateOrFail builds a historyMosquitoinspection and inserts it into the database
|
|
// Relations objects are also inserted and placed in the .R field
|
|
// It calls `tb.Fatal(err)` on the test/benchmark if an error occurs
|
|
func (o *HistoryMosquitoinspectionTemplate) CreateOrFail(ctx context.Context, tb testing.TB, exec bob.Executor) *models.HistoryMosquitoinspection {
|
|
tb.Helper()
|
|
m, err := o.Create(ctx, exec)
|
|
if err != nil {
|
|
tb.Fatal(err)
|
|
return nil
|
|
}
|
|
return m
|
|
}
|
|
|
|
// CreateMany builds multiple historyMosquitoinspections and inserts them into the database
|
|
// Relations objects are also inserted and placed in the .R field
|
|
func (o HistoryMosquitoinspectionTemplate) CreateMany(ctx context.Context, exec bob.Executor, number int) (models.HistoryMosquitoinspectionSlice, error) {
|
|
var err error
|
|
m := make(models.HistoryMosquitoinspectionSlice, number)
|
|
|
|
for i := range m {
|
|
m[i], err = o.Create(ctx, exec)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
}
|
|
|
|
return m, nil
|
|
}
|
|
|
|
// MustCreateMany builds multiple historyMosquitoinspections and inserts them into the database
|
|
// Relations objects are also inserted and placed in the .R field
|
|
// panics if an error occurs
|
|
func (o HistoryMosquitoinspectionTemplate) MustCreateMany(ctx context.Context, exec bob.Executor, number int) models.HistoryMosquitoinspectionSlice {
|
|
m, err := o.CreateMany(ctx, exec, number)
|
|
if err != nil {
|
|
panic(err)
|
|
}
|
|
return m
|
|
}
|
|
|
|
// CreateManyOrFail builds multiple historyMosquitoinspections and inserts them into the database
|
|
// Relations objects are also inserted and placed in the .R field
|
|
// It calls `tb.Fatal(err)` on the test/benchmark if an error occurs
|
|
func (o HistoryMosquitoinspectionTemplate) CreateManyOrFail(ctx context.Context, tb testing.TB, exec bob.Executor, number int) models.HistoryMosquitoinspectionSlice {
|
|
tb.Helper()
|
|
m, err := o.CreateMany(ctx, exec, number)
|
|
if err != nil {
|
|
tb.Fatal(err)
|
|
return nil
|
|
}
|
|
return m
|
|
}
|
|
|
|
// HistoryMosquitoinspection has methods that act as mods for the HistoryMosquitoinspectionTemplate
|
|
var HistoryMosquitoinspectionMods historyMosquitoinspectionMods
|
|
|
|
type historyMosquitoinspectionMods struct{}
|
|
|
|
func (m historyMosquitoinspectionMods) RandomizeAllColumns(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModSlice{
|
|
HistoryMosquitoinspectionMods.RandomOrganizationID(f),
|
|
HistoryMosquitoinspectionMods.RandomActiontaken(f),
|
|
HistoryMosquitoinspectionMods.RandomActivity(f),
|
|
HistoryMosquitoinspectionMods.RandomAdultact(f),
|
|
HistoryMosquitoinspectionMods.RandomAvetemp(f),
|
|
HistoryMosquitoinspectionMods.RandomAvglarvae(f),
|
|
HistoryMosquitoinspectionMods.RandomAvgpupae(f),
|
|
HistoryMosquitoinspectionMods.RandomBreeding(f),
|
|
HistoryMosquitoinspectionMods.RandomCbcount(f),
|
|
HistoryMosquitoinspectionMods.RandomComments(f),
|
|
HistoryMosquitoinspectionMods.RandomContainercount(f),
|
|
HistoryMosquitoinspectionMods.RandomCreationdate(f),
|
|
HistoryMosquitoinspectionMods.RandomCreator(f),
|
|
HistoryMosquitoinspectionMods.RandomDomstage(f),
|
|
HistoryMosquitoinspectionMods.RandomEggs(f),
|
|
HistoryMosquitoinspectionMods.RandomEnddatetime(f),
|
|
HistoryMosquitoinspectionMods.RandomEditdate(f),
|
|
HistoryMosquitoinspectionMods.RandomEditor(f),
|
|
HistoryMosquitoinspectionMods.RandomFieldspecies(f),
|
|
HistoryMosquitoinspectionMods.RandomFieldtech(f),
|
|
HistoryMosquitoinspectionMods.RandomGlobalid(f),
|
|
HistoryMosquitoinspectionMods.RandomJurisdiction(f),
|
|
HistoryMosquitoinspectionMods.RandomLarvaepresent(f),
|
|
HistoryMosquitoinspectionMods.RandomLinelocid(f),
|
|
HistoryMosquitoinspectionMods.RandomLocationname(f),
|
|
HistoryMosquitoinspectionMods.RandomLstages(f),
|
|
HistoryMosquitoinspectionMods.RandomNumdips(f),
|
|
HistoryMosquitoinspectionMods.RandomObjectid(f),
|
|
HistoryMosquitoinspectionMods.RandomPersonalcontact(f),
|
|
HistoryMosquitoinspectionMods.RandomPointlocid(f),
|
|
HistoryMosquitoinspectionMods.RandomPolygonlocid(f),
|
|
HistoryMosquitoinspectionMods.RandomPosdips(f),
|
|
HistoryMosquitoinspectionMods.RandomPositivecontainercount(f),
|
|
HistoryMosquitoinspectionMods.RandomPupaepresent(f),
|
|
HistoryMosquitoinspectionMods.RandomRaingauge(f),
|
|
HistoryMosquitoinspectionMods.RandomRecordstatus(f),
|
|
HistoryMosquitoinspectionMods.RandomReviewed(f),
|
|
HistoryMosquitoinspectionMods.RandomReviewedby(f),
|
|
HistoryMosquitoinspectionMods.RandomRevieweddate(f),
|
|
HistoryMosquitoinspectionMods.RandomSdid(f),
|
|
HistoryMosquitoinspectionMods.RandomSitecond(f),
|
|
HistoryMosquitoinspectionMods.RandomSrid(f),
|
|
HistoryMosquitoinspectionMods.RandomStartdatetime(f),
|
|
HistoryMosquitoinspectionMods.RandomTirecount(f),
|
|
HistoryMosquitoinspectionMods.RandomTotlarvae(f),
|
|
HistoryMosquitoinspectionMods.RandomTotpupae(f),
|
|
HistoryMosquitoinspectionMods.RandomVisualmonitoring(f),
|
|
HistoryMosquitoinspectionMods.RandomVmcomments(f),
|
|
HistoryMosquitoinspectionMods.RandomWinddir(f),
|
|
HistoryMosquitoinspectionMods.RandomWindspeed(f),
|
|
HistoryMosquitoinspectionMods.RandomZone(f),
|
|
HistoryMosquitoinspectionMods.RandomZone2(f),
|
|
HistoryMosquitoinspectionMods.RandomCreatedDate(f),
|
|
HistoryMosquitoinspectionMods.RandomCreatedUser(f),
|
|
HistoryMosquitoinspectionMods.RandomGeometryX(f),
|
|
HistoryMosquitoinspectionMods.RandomGeometryY(f),
|
|
HistoryMosquitoinspectionMods.RandomLastEditedDate(f),
|
|
HistoryMosquitoinspectionMods.RandomLastEditedUser(f),
|
|
HistoryMosquitoinspectionMods.RandomAdminaction(f),
|
|
HistoryMosquitoinspectionMods.RandomPtaid(f),
|
|
HistoryMosquitoinspectionMods.RandomVersion(f),
|
|
}
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) OrganizationID(val null.Val[int32]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.OrganizationID = func() null.Val[int32] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) OrganizationIDFunc(f func() null.Val[int32]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.OrganizationID = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetOrganizationID() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.OrganizationID = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomOrganizationID(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.OrganizationID = func() null.Val[int32] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int32(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomOrganizationIDNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.OrganizationID = func() null.Val[int32] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int32(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Actiontaken(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Actiontaken = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) ActiontakenFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Actiontaken = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetActiontaken() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Actiontaken = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomActiontaken(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Actiontaken = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomActiontakenNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Actiontaken = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Activity(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Activity = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) ActivityFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Activity = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetActivity() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Activity = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomActivity(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Activity = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomActivityNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Activity = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Adultact(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Adultact = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) AdultactFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Adultact = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetAdultact() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Adultact = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomAdultact(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Adultact = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomAdultactNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Adultact = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Avetemp(val null.Val[float64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Avetemp = func() null.Val[float64] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) AvetempFunc(f func() null.Val[float64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Avetemp = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetAvetemp() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Avetemp = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomAvetemp(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Avetemp = func() null.Val[float64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_float64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomAvetempNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Avetemp = func() null.Val[float64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_float64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Avglarvae(val null.Val[float64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Avglarvae = func() null.Val[float64] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) AvglarvaeFunc(f func() null.Val[float64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Avglarvae = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetAvglarvae() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Avglarvae = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomAvglarvae(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Avglarvae = func() null.Val[float64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_float64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomAvglarvaeNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Avglarvae = func() null.Val[float64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_float64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Avgpupae(val null.Val[float64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Avgpupae = func() null.Val[float64] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) AvgpupaeFunc(f func() null.Val[float64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Avgpupae = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetAvgpupae() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Avgpupae = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomAvgpupae(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Avgpupae = func() null.Val[float64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_float64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomAvgpupaeNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Avgpupae = func() null.Val[float64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_float64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Breeding(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Breeding = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) BreedingFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Breeding = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetBreeding() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Breeding = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomBreeding(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Breeding = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomBreedingNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Breeding = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Cbcount(val null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Cbcount = func() null.Val[int16] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) CbcountFunc(f func() null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Cbcount = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetCbcount() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Cbcount = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomCbcount(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Cbcount = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomCbcountNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Cbcount = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Comments(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Comments = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) CommentsFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Comments = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetComments() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Comments = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomComments(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Comments = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomCommentsNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Comments = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Containercount(val null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Containercount = func() null.Val[int16] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) ContainercountFunc(f func() null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Containercount = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetContainercount() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Containercount = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomContainercount(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Containercount = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomContainercountNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Containercount = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Creationdate(val null.Val[int64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Creationdate = func() null.Val[int64] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) CreationdateFunc(f func() null.Val[int64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Creationdate = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetCreationdate() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Creationdate = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomCreationdate(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Creationdate = func() null.Val[int64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomCreationdateNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Creationdate = func() null.Val[int64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Creator(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Creator = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) CreatorFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Creator = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetCreator() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Creator = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomCreator(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Creator = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomCreatorNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Creator = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Domstage(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Domstage = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) DomstageFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Domstage = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetDomstage() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Domstage = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomDomstage(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Domstage = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomDomstageNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Domstage = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Eggs(val null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Eggs = func() null.Val[int16] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) EggsFunc(f func() null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Eggs = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetEggs() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Eggs = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomEggs(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Eggs = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomEggsNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Eggs = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Enddatetime(val null.Val[int64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Enddatetime = func() null.Val[int64] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) EnddatetimeFunc(f func() null.Val[int64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Enddatetime = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetEnddatetime() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Enddatetime = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomEnddatetime(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Enddatetime = func() null.Val[int64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomEnddatetimeNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Enddatetime = func() null.Val[int64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Editdate(val null.Val[int64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Editdate = func() null.Val[int64] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) EditdateFunc(f func() null.Val[int64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Editdate = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetEditdate() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Editdate = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomEditdate(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Editdate = func() null.Val[int64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomEditdateNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Editdate = func() null.Val[int64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Editor(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Editor = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) EditorFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Editor = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetEditor() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Editor = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomEditor(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Editor = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomEditorNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Editor = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Fieldspecies(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Fieldspecies = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) FieldspeciesFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Fieldspecies = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetFieldspecies() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Fieldspecies = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomFieldspecies(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Fieldspecies = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomFieldspeciesNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Fieldspecies = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Fieldtech(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Fieldtech = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) FieldtechFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Fieldtech = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetFieldtech() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Fieldtech = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomFieldtech(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Fieldtech = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomFieldtechNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Fieldtech = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Globalid(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Globalid = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) GlobalidFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Globalid = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetGlobalid() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Globalid = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomGlobalid(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Globalid = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomGlobalidNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Globalid = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Jurisdiction(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Jurisdiction = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) JurisdictionFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Jurisdiction = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetJurisdiction() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Jurisdiction = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomJurisdiction(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Jurisdiction = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomJurisdictionNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Jurisdiction = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Larvaepresent(val null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Larvaepresent = func() null.Val[int16] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) LarvaepresentFunc(f func() null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Larvaepresent = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetLarvaepresent() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Larvaepresent = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomLarvaepresent(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Larvaepresent = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomLarvaepresentNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Larvaepresent = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Linelocid(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Linelocid = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) LinelocidFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Linelocid = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetLinelocid() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Linelocid = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomLinelocid(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Linelocid = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomLinelocidNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Linelocid = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Locationname(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Locationname = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) LocationnameFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Locationname = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetLocationname() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Locationname = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomLocationname(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Locationname = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomLocationnameNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Locationname = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Lstages(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Lstages = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) LstagesFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Lstages = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetLstages() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Lstages = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomLstages(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Lstages = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomLstagesNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Lstages = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Numdips(val null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Numdips = func() null.Val[int16] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) NumdipsFunc(f func() null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Numdips = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetNumdips() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Numdips = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomNumdips(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Numdips = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomNumdipsNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Numdips = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Objectid(val int32) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Objectid = func() int32 { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) ObjectidFunc(f func() int32) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Objectid = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetObjectid() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Objectid = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
func (m historyMosquitoinspectionMods) RandomObjectid(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Objectid = func() int32 {
|
|
return random_int32(f)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Personalcontact(val null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Personalcontact = func() null.Val[int16] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) PersonalcontactFunc(f func() null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Personalcontact = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetPersonalcontact() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Personalcontact = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomPersonalcontact(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Personalcontact = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomPersonalcontactNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Personalcontact = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Pointlocid(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Pointlocid = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) PointlocidFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Pointlocid = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetPointlocid() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Pointlocid = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomPointlocid(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Pointlocid = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomPointlocidNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Pointlocid = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Polygonlocid(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Polygonlocid = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) PolygonlocidFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Polygonlocid = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetPolygonlocid() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Polygonlocid = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomPolygonlocid(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Polygonlocid = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomPolygonlocidNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Polygonlocid = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Posdips(val null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Posdips = func() null.Val[int16] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) PosdipsFunc(f func() null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Posdips = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetPosdips() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Posdips = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomPosdips(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Posdips = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomPosdipsNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Posdips = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Positivecontainercount(val null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Positivecontainercount = func() null.Val[int16] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) PositivecontainercountFunc(f func() null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Positivecontainercount = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetPositivecontainercount() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Positivecontainercount = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomPositivecontainercount(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Positivecontainercount = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomPositivecontainercountNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Positivecontainercount = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Pupaepresent(val null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Pupaepresent = func() null.Val[int16] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) PupaepresentFunc(f func() null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Pupaepresent = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetPupaepresent() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Pupaepresent = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomPupaepresent(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Pupaepresent = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomPupaepresentNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Pupaepresent = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Raingauge(val null.Val[float64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Raingauge = func() null.Val[float64] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) RaingaugeFunc(f func() null.Val[float64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Raingauge = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetRaingauge() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Raingauge = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomRaingauge(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Raingauge = func() null.Val[float64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_float64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomRaingaugeNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Raingauge = func() null.Val[float64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_float64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Recordstatus(val null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Recordstatus = func() null.Val[int16] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) RecordstatusFunc(f func() null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Recordstatus = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetRecordstatus() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Recordstatus = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomRecordstatus(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Recordstatus = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomRecordstatusNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Recordstatus = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Reviewed(val null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Reviewed = func() null.Val[int16] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) ReviewedFunc(f func() null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Reviewed = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetReviewed() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Reviewed = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomReviewed(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Reviewed = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomReviewedNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Reviewed = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Reviewedby(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Reviewedby = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) ReviewedbyFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Reviewedby = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetReviewedby() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Reviewedby = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomReviewedby(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Reviewedby = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomReviewedbyNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Reviewedby = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Revieweddate(val null.Val[int64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Revieweddate = func() null.Val[int64] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) RevieweddateFunc(f func() null.Val[int64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Revieweddate = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetRevieweddate() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Revieweddate = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomRevieweddate(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Revieweddate = func() null.Val[int64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomRevieweddateNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Revieweddate = func() null.Val[int64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Sdid(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Sdid = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) SdidFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Sdid = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetSdid() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Sdid = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomSdid(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Sdid = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomSdidNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Sdid = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Sitecond(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Sitecond = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) SitecondFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Sitecond = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetSitecond() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Sitecond = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomSitecond(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Sitecond = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomSitecondNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Sitecond = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Srid(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Srid = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) SridFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Srid = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetSrid() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Srid = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomSrid(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Srid = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomSridNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Srid = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Startdatetime(val null.Val[int64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Startdatetime = func() null.Val[int64] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) StartdatetimeFunc(f func() null.Val[int64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Startdatetime = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetStartdatetime() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Startdatetime = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomStartdatetime(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Startdatetime = func() null.Val[int64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomStartdatetimeNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Startdatetime = func() null.Val[int64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Tirecount(val null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Tirecount = func() null.Val[int16] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) TirecountFunc(f func() null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Tirecount = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetTirecount() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Tirecount = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomTirecount(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Tirecount = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomTirecountNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Tirecount = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Totlarvae(val null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Totlarvae = func() null.Val[int16] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) TotlarvaeFunc(f func() null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Totlarvae = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetTotlarvae() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Totlarvae = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomTotlarvae(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Totlarvae = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomTotlarvaeNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Totlarvae = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Totpupae(val null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Totpupae = func() null.Val[int16] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) TotpupaeFunc(f func() null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Totpupae = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetTotpupae() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Totpupae = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomTotpupae(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Totpupae = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomTotpupaeNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Totpupae = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Visualmonitoring(val null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Visualmonitoring = func() null.Val[int16] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) VisualmonitoringFunc(f func() null.Val[int16]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Visualmonitoring = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetVisualmonitoring() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Visualmonitoring = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomVisualmonitoring(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Visualmonitoring = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomVisualmonitoringNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Visualmonitoring = func() null.Val[int16] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int16(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Vmcomments(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Vmcomments = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) VmcommentsFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Vmcomments = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetVmcomments() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Vmcomments = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomVmcomments(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Vmcomments = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomVmcommentsNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Vmcomments = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Winddir(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Winddir = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) WinddirFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Winddir = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetWinddir() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Winddir = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomWinddir(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Winddir = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomWinddirNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Winddir = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Windspeed(val null.Val[float64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Windspeed = func() null.Val[float64] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) WindspeedFunc(f func() null.Val[float64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Windspeed = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetWindspeed() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Windspeed = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomWindspeed(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Windspeed = func() null.Val[float64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_float64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomWindspeedNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Windspeed = func() null.Val[float64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_float64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Zone(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Zone = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) ZoneFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Zone = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetZone() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Zone = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomZone(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Zone = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomZoneNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Zone = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Zone2(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Zone2 = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) Zone2Func(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Zone2 = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetZone2() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Zone2 = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomZone2(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Zone2 = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomZone2NotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Zone2 = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) CreatedDate(val null.Val[int64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.CreatedDate = func() null.Val[int64] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) CreatedDateFunc(f func() null.Val[int64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.CreatedDate = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetCreatedDate() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.CreatedDate = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomCreatedDate(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.CreatedDate = func() null.Val[int64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomCreatedDateNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.CreatedDate = func() null.Val[int64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) CreatedUser(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.CreatedUser = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) CreatedUserFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.CreatedUser = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetCreatedUser() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.CreatedUser = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomCreatedUser(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.CreatedUser = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomCreatedUserNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.CreatedUser = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) GeometryX(val null.Val[float64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.GeometryX = func() null.Val[float64] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) GeometryXFunc(f func() null.Val[float64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.GeometryX = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetGeometryX() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.GeometryX = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomGeometryX(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.GeometryX = func() null.Val[float64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_float64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomGeometryXNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.GeometryX = func() null.Val[float64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_float64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) GeometryY(val null.Val[float64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.GeometryY = func() null.Val[float64] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) GeometryYFunc(f func() null.Val[float64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.GeometryY = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetGeometryY() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.GeometryY = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomGeometryY(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.GeometryY = func() null.Val[float64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_float64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomGeometryYNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.GeometryY = func() null.Val[float64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_float64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) LastEditedDate(val null.Val[int64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.LastEditedDate = func() null.Val[int64] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) LastEditedDateFunc(f func() null.Val[int64]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.LastEditedDate = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetLastEditedDate() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.LastEditedDate = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomLastEditedDate(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.LastEditedDate = func() null.Val[int64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomLastEditedDateNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.LastEditedDate = func() null.Val[int64] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_int64(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) LastEditedUser(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.LastEditedUser = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) LastEditedUserFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.LastEditedUser = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetLastEditedUser() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.LastEditedUser = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomLastEditedUser(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.LastEditedUser = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomLastEditedUserNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.LastEditedUser = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Adminaction(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Adminaction = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) AdminactionFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Adminaction = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetAdminaction() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Adminaction = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomAdminaction(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Adminaction = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomAdminactionNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Adminaction = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Ptaid(val null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Ptaid = func() null.Val[string] { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) PtaidFunc(f func() null.Val[string]) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Ptaid = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetPtaid() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Ptaid = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is sometimes null
|
|
func (m historyMosquitoinspectionMods) RandomPtaid(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Ptaid = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
// The generated value is never null
|
|
func (m historyMosquitoinspectionMods) RandomPtaidNotNull(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Ptaid = func() null.Val[string] {
|
|
if f == nil {
|
|
f = &defaultFaker
|
|
}
|
|
|
|
val := random_string(f)
|
|
return null.From(val)
|
|
}
|
|
})
|
|
}
|
|
|
|
// Set the model columns to this value
|
|
func (m historyMosquitoinspectionMods) Version(val int32) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Version = func() int32 { return val }
|
|
})
|
|
}
|
|
|
|
// Set the Column from the function
|
|
func (m historyMosquitoinspectionMods) VersionFunc(f func() int32) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Version = f
|
|
})
|
|
}
|
|
|
|
// Clear any values for the column
|
|
func (m historyMosquitoinspectionMods) UnsetVersion() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Version = nil
|
|
})
|
|
}
|
|
|
|
// Generates a random value for the column using the given faker
|
|
// if faker is nil, a default faker is used
|
|
func (m historyMosquitoinspectionMods) RandomVersion(f *faker.Faker) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(_ context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.Version = func() int32 {
|
|
return random_int32(f)
|
|
}
|
|
})
|
|
}
|
|
|
|
func (m historyMosquitoinspectionMods) WithParentsCascading() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(ctx context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
if isDone, _ := historyMosquitoinspectionWithParentsCascadingCtx.Value(ctx); isDone {
|
|
return
|
|
}
|
|
ctx = historyMosquitoinspectionWithParentsCascadingCtx.WithValue(ctx, true)
|
|
{
|
|
|
|
related := o.f.NewOrganizationWithContext(ctx, OrganizationMods.WithParentsCascading())
|
|
m.WithOrganization(related).Apply(ctx, o)
|
|
}
|
|
})
|
|
}
|
|
|
|
func (m historyMosquitoinspectionMods) WithOrganization(rel *OrganizationTemplate) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(ctx context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.r.Organization = &historyMosquitoinspectionROrganizationR{
|
|
o: rel,
|
|
}
|
|
})
|
|
}
|
|
|
|
func (m historyMosquitoinspectionMods) WithNewOrganization(mods ...OrganizationMod) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(ctx context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
related := o.f.NewOrganizationWithContext(ctx, mods...)
|
|
|
|
m.WithOrganization(related).Apply(ctx, o)
|
|
})
|
|
}
|
|
|
|
func (m historyMosquitoinspectionMods) WithExistingOrganization(em *models.Organization) HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(ctx context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.r.Organization = &historyMosquitoinspectionROrganizationR{
|
|
o: o.f.FromExistingOrganization(em),
|
|
}
|
|
})
|
|
}
|
|
|
|
func (m historyMosquitoinspectionMods) WithoutOrganization() HistoryMosquitoinspectionMod {
|
|
return HistoryMosquitoinspectionModFunc(func(ctx context.Context, o *HistoryMosquitoinspectionTemplate) {
|
|
o.r.Organization = nil
|
|
})
|
|
}
|