[F3] upgrade to gof3 50a6e740ac04

Add new methods GetIDString() & SetIDString() & ToFormatInterface()
Change the prototype of the fixture function
This commit is contained in:
Earl Warren 2023-06-28 15:57:57 +02:00
commit d7b263ff8b
No known key found for this signature in database
GPG key ID: 0579CB2928A78A00
16 changed files with 154 additions and 4 deletions

View file

@ -31,6 +31,10 @@ func (o Milestone) GetID() int64 {
return o.ID
}
func (o Milestone) GetIDString() string {
return fmt.Sprintf("%d", o.GetID())
}
func (o Milestone) GetName() string {
return o.Name
}
@ -39,6 +43,10 @@ func (o *Milestone) SetID(id int64) {
o.ID = id
}
func (o *Milestone) SetIDString(id string) {
o.SetID(util.ParseInt(id))
}
func (o *Milestone) IsNil() bool {
return o.ID == 0
}
@ -47,6 +55,10 @@ func (o *Milestone) Equals(other *Milestone) bool {
return o.Name == other.Name
}
func (o *Milestone) ToFormatInterface() format.Interface {
return o.ToFormat()
}
func (o *Milestone) ToFormat() *format.Milestone {
milestone := &format.Milestone{
Common: format.NewCommon(o.ID),