added chat messages

This commit is contained in:
2022-01-29 19:32:13 +01:00
parent 2e6c94de81
commit b036275665
48 changed files with 4167 additions and 353 deletions

View File

@@ -7,6 +7,7 @@ import (
"csgowtfd/ent/matchplayer"
"csgowtfd/ent/predicate"
"csgowtfd/ent/weapon"
"errors"
"fmt"
"entgo.io/ent/dialect/sql"
@@ -35,7 +36,7 @@ func (wu *WeaponUpdate) SetVictim(u uint64) *WeaponUpdate {
}
// AddVictim adds u to the "victim" field.
func (wu *WeaponUpdate) AddVictim(u uint64) *WeaponUpdate {
func (wu *WeaponUpdate) AddVictim(u int64) *WeaponUpdate {
wu.mutation.AddVictim(u)
return wu
}
@@ -48,7 +49,7 @@ func (wu *WeaponUpdate) SetDmg(u uint) *WeaponUpdate {
}
// AddDmg adds u to the "dmg" field.
func (wu *WeaponUpdate) AddDmg(u uint) *WeaponUpdate {
func (wu *WeaponUpdate) AddDmg(u int) *WeaponUpdate {
wu.mutation.AddDmg(u)
return wu
}
@@ -299,7 +300,7 @@ func (wuo *WeaponUpdateOne) SetVictim(u uint64) *WeaponUpdateOne {
}
// AddVictim adds u to the "victim" field.
func (wuo *WeaponUpdateOne) AddVictim(u uint64) *WeaponUpdateOne {
func (wuo *WeaponUpdateOne) AddVictim(u int64) *WeaponUpdateOne {
wuo.mutation.AddVictim(u)
return wuo
}
@@ -312,7 +313,7 @@ func (wuo *WeaponUpdateOne) SetDmg(u uint) *WeaponUpdateOne {
}
// AddDmg adds u to the "dmg" field.
func (wuo *WeaponUpdateOne) AddDmg(u uint) *WeaponUpdateOne {
func (wuo *WeaponUpdateOne) AddDmg(u int) *WeaponUpdateOne {
wuo.mutation.AddDmg(u)
return wuo
}
@@ -447,7 +448,7 @@ func (wuo *WeaponUpdateOne) sqlSave(ctx context.Context) (_node *Weapon, err err
}
id, ok := wuo.mutation.ID()
if !ok {
return nil, &ValidationError{Name: "ID", err: fmt.Errorf("missing Weapon.ID for update")}
return nil, &ValidationError{Name: "id", err: errors.New(`ent: missing "Weapon.id" for update`)}
}
_spec.Node.ID.Value = id
if fields := wuo.fields; len(fields) > 0 {