removed unneeded field, fixed not setting spent amount
This commit is contained in:
@@ -160,38 +160,6 @@ func (mu *MatchUpdate) SetNillableDemoParsed(b *bool) *MatchUpdate {
|
||||
return mu
|
||||
}
|
||||
|
||||
// SetEco sets the "eco" field.
|
||||
func (mu *MatchUpdate) SetEco(s struct {
|
||||
Rounds []*struct {
|
||||
Team int "json:\"team\""
|
||||
Bank int "json:\"bank\""
|
||||
Equipment int "json:\"equipment\""
|
||||
} "json:\"rounds\""
|
||||
}) *MatchUpdate {
|
||||
mu.mutation.SetEco(s)
|
||||
return mu
|
||||
}
|
||||
|
||||
// SetNillableEco sets the "eco" field if the given value is not nil.
|
||||
func (mu *MatchUpdate) SetNillableEco(s *struct {
|
||||
Rounds []*struct {
|
||||
Team int "json:\"team\""
|
||||
Bank int "json:\"bank\""
|
||||
Equipment int "json:\"equipment\""
|
||||
} "json:\"rounds\""
|
||||
}) *MatchUpdate {
|
||||
if s != nil {
|
||||
mu.SetEco(*s)
|
||||
}
|
||||
return mu
|
||||
}
|
||||
|
||||
// ClearEco clears the value of the "eco" field.
|
||||
func (mu *MatchUpdate) ClearEco() *MatchUpdate {
|
||||
mu.mutation.ClearEco()
|
||||
return mu
|
||||
}
|
||||
|
||||
// AddStatIDs adds the "stats" edge to the Stats entity by IDs.
|
||||
func (mu *MatchUpdate) AddStatIDs(ids ...int) *MatchUpdate {
|
||||
mu.mutation.AddStatIDs(ids...)
|
||||
@@ -458,19 +426,6 @@ func (mu *MatchUpdate) sqlSave(ctx context.Context) (n int, err error) {
|
||||
Column: match.FieldDemoParsed,
|
||||
})
|
||||
}
|
||||
if value, ok := mu.mutation.Eco(); ok {
|
||||
_spec.Fields.Set = append(_spec.Fields.Set, &sqlgraph.FieldSpec{
|
||||
Type: field.TypeJSON,
|
||||
Value: value,
|
||||
Column: match.FieldEco,
|
||||
})
|
||||
}
|
||||
if mu.mutation.EcoCleared() {
|
||||
_spec.Fields.Clear = append(_spec.Fields.Clear, &sqlgraph.FieldSpec{
|
||||
Type: field.TypeJSON,
|
||||
Column: match.FieldEco,
|
||||
})
|
||||
}
|
||||
if mu.mutation.StatsCleared() {
|
||||
edge := &sqlgraph.EdgeSpec{
|
||||
Rel: sqlgraph.O2M,
|
||||
@@ -729,38 +684,6 @@ func (muo *MatchUpdateOne) SetNillableDemoParsed(b *bool) *MatchUpdateOne {
|
||||
return muo
|
||||
}
|
||||
|
||||
// SetEco sets the "eco" field.
|
||||
func (muo *MatchUpdateOne) SetEco(s struct {
|
||||
Rounds []*struct {
|
||||
Team int "json:\"team\""
|
||||
Bank int "json:\"bank\""
|
||||
Equipment int "json:\"equipment\""
|
||||
} "json:\"rounds\""
|
||||
}) *MatchUpdateOne {
|
||||
muo.mutation.SetEco(s)
|
||||
return muo
|
||||
}
|
||||
|
||||
// SetNillableEco sets the "eco" field if the given value is not nil.
|
||||
func (muo *MatchUpdateOne) SetNillableEco(s *struct {
|
||||
Rounds []*struct {
|
||||
Team int "json:\"team\""
|
||||
Bank int "json:\"bank\""
|
||||
Equipment int "json:\"equipment\""
|
||||
} "json:\"rounds\""
|
||||
}) *MatchUpdateOne {
|
||||
if s != nil {
|
||||
muo.SetEco(*s)
|
||||
}
|
||||
return muo
|
||||
}
|
||||
|
||||
// ClearEco clears the value of the "eco" field.
|
||||
func (muo *MatchUpdateOne) ClearEco() *MatchUpdateOne {
|
||||
muo.mutation.ClearEco()
|
||||
return muo
|
||||
}
|
||||
|
||||
// AddStatIDs adds the "stats" edge to the Stats entity by IDs.
|
||||
func (muo *MatchUpdateOne) AddStatIDs(ids ...int) *MatchUpdateOne {
|
||||
muo.mutation.AddStatIDs(ids...)
|
||||
@@ -1051,19 +974,6 @@ func (muo *MatchUpdateOne) sqlSave(ctx context.Context) (_node *Match, err error
|
||||
Column: match.FieldDemoParsed,
|
||||
})
|
||||
}
|
||||
if value, ok := muo.mutation.Eco(); ok {
|
||||
_spec.Fields.Set = append(_spec.Fields.Set, &sqlgraph.FieldSpec{
|
||||
Type: field.TypeJSON,
|
||||
Value: value,
|
||||
Column: match.FieldEco,
|
||||
})
|
||||
}
|
||||
if muo.mutation.EcoCleared() {
|
||||
_spec.Fields.Clear = append(_spec.Fields.Clear, &sqlgraph.FieldSpec{
|
||||
Type: field.TypeJSON,
|
||||
Column: match.FieldEco,
|
||||
})
|
||||
}
|
||||
if muo.mutation.StatsCleared() {
|
||||
edge := &sqlgraph.EdgeSpec{
|
||||
Rel: sqlgraph.O2M,
|
||||
|
Reference in New Issue
Block a user