added vac/gameban marker for matches
This commit is contained in:
@@ -160,6 +160,34 @@ func (mu *MatchUpdate) SetNillableDemoParsed(b *bool) *MatchUpdate {
|
||||
return mu
|
||||
}
|
||||
|
||||
// SetVacPresent sets the "vac_present" field.
|
||||
func (mu *MatchUpdate) SetVacPresent(b bool) *MatchUpdate {
|
||||
mu.mutation.SetVacPresent(b)
|
||||
return mu
|
||||
}
|
||||
|
||||
// SetNillableVacPresent sets the "vac_present" field if the given value is not nil.
|
||||
func (mu *MatchUpdate) SetNillableVacPresent(b *bool) *MatchUpdate {
|
||||
if b != nil {
|
||||
mu.SetVacPresent(*b)
|
||||
}
|
||||
return mu
|
||||
}
|
||||
|
||||
// SetGamebanPresent sets the "gameban_present" field.
|
||||
func (mu *MatchUpdate) SetGamebanPresent(b bool) *MatchUpdate {
|
||||
mu.mutation.SetGamebanPresent(b)
|
||||
return mu
|
||||
}
|
||||
|
||||
// SetNillableGamebanPresent sets the "gameban_present" field if the given value is not nil.
|
||||
func (mu *MatchUpdate) SetNillableGamebanPresent(b *bool) *MatchUpdate {
|
||||
if b != nil {
|
||||
mu.SetGamebanPresent(*b)
|
||||
}
|
||||
return mu
|
||||
}
|
||||
|
||||
// AddStatIDs adds the "stats" edge to the Stats entity by IDs.
|
||||
func (mu *MatchUpdate) AddStatIDs(ids ...int) *MatchUpdate {
|
||||
mu.mutation.AddStatIDs(ids...)
|
||||
@@ -426,6 +454,20 @@ func (mu *MatchUpdate) sqlSave(ctx context.Context) (n int, err error) {
|
||||
Column: match.FieldDemoParsed,
|
||||
})
|
||||
}
|
||||
if value, ok := mu.mutation.VacPresent(); ok {
|
||||
_spec.Fields.Set = append(_spec.Fields.Set, &sqlgraph.FieldSpec{
|
||||
Type: field.TypeBool,
|
||||
Value: value,
|
||||
Column: match.FieldVacPresent,
|
||||
})
|
||||
}
|
||||
if value, ok := mu.mutation.GamebanPresent(); ok {
|
||||
_spec.Fields.Set = append(_spec.Fields.Set, &sqlgraph.FieldSpec{
|
||||
Type: field.TypeBool,
|
||||
Value: value,
|
||||
Column: match.FieldGamebanPresent,
|
||||
})
|
||||
}
|
||||
if mu.mutation.StatsCleared() {
|
||||
edge := &sqlgraph.EdgeSpec{
|
||||
Rel: sqlgraph.O2M,
|
||||
@@ -684,6 +726,34 @@ func (muo *MatchUpdateOne) SetNillableDemoParsed(b *bool) *MatchUpdateOne {
|
||||
return muo
|
||||
}
|
||||
|
||||
// SetVacPresent sets the "vac_present" field.
|
||||
func (muo *MatchUpdateOne) SetVacPresent(b bool) *MatchUpdateOne {
|
||||
muo.mutation.SetVacPresent(b)
|
||||
return muo
|
||||
}
|
||||
|
||||
// SetNillableVacPresent sets the "vac_present" field if the given value is not nil.
|
||||
func (muo *MatchUpdateOne) SetNillableVacPresent(b *bool) *MatchUpdateOne {
|
||||
if b != nil {
|
||||
muo.SetVacPresent(*b)
|
||||
}
|
||||
return muo
|
||||
}
|
||||
|
||||
// SetGamebanPresent sets the "gameban_present" field.
|
||||
func (muo *MatchUpdateOne) SetGamebanPresent(b bool) *MatchUpdateOne {
|
||||
muo.mutation.SetGamebanPresent(b)
|
||||
return muo
|
||||
}
|
||||
|
||||
// SetNillableGamebanPresent sets the "gameban_present" field if the given value is not nil.
|
||||
func (muo *MatchUpdateOne) SetNillableGamebanPresent(b *bool) *MatchUpdateOne {
|
||||
if b != nil {
|
||||
muo.SetGamebanPresent(*b)
|
||||
}
|
||||
return muo
|
||||
}
|
||||
|
||||
// AddStatIDs adds the "stats" edge to the Stats entity by IDs.
|
||||
func (muo *MatchUpdateOne) AddStatIDs(ids ...int) *MatchUpdateOne {
|
||||
muo.mutation.AddStatIDs(ids...)
|
||||
@@ -974,6 +1044,20 @@ func (muo *MatchUpdateOne) sqlSave(ctx context.Context) (_node *Match, err error
|
||||
Column: match.FieldDemoParsed,
|
||||
})
|
||||
}
|
||||
if value, ok := muo.mutation.VacPresent(); ok {
|
||||
_spec.Fields.Set = append(_spec.Fields.Set, &sqlgraph.FieldSpec{
|
||||
Type: field.TypeBool,
|
||||
Value: value,
|
||||
Column: match.FieldVacPresent,
|
||||
})
|
||||
}
|
||||
if value, ok := muo.mutation.GamebanPresent(); ok {
|
||||
_spec.Fields.Set = append(_spec.Fields.Set, &sqlgraph.FieldSpec{
|
||||
Type: field.TypeBool,
|
||||
Value: value,
|
||||
Column: match.FieldGamebanPresent,
|
||||
})
|
||||
}
|
||||
if muo.mutation.StatsCleared() {
|
||||
edge := &sqlgraph.EdgeSpec{
|
||||
Rel: sqlgraph.O2M,
|
||||
|
Reference in New Issue
Block a user