fix: some api bug

This commit is contained in:
wwweww
2026-03-31 22:12:06 +08:00
parent c5ff4f0216
commit e7970ac25f
219 changed files with 16195 additions and 2126 deletions
+4 -4
View File
@@ -268,7 +268,7 @@ func (c *WalletClient) UpdateOne(_m *Wallet) *WalletUpdateOne {
}
// UpdateOneID returns an update builder for the given id.
func (c *WalletClient) UpdateOneID(id int) *WalletUpdateOne {
func (c *WalletClient) UpdateOneID(id int64) *WalletUpdateOne {
mutation := newWalletMutation(c.config, OpUpdateOne, withWalletID(id))
return &WalletUpdateOne{config: c.config, hooks: c.Hooks(), mutation: mutation}
}
@@ -285,7 +285,7 @@ func (c *WalletClient) DeleteOne(_m *Wallet) *WalletDeleteOne {
}
// DeleteOneID returns a builder for deleting the given entity by its id.
func (c *WalletClient) DeleteOneID(id int) *WalletDeleteOne {
func (c *WalletClient) DeleteOneID(id int64) *WalletDeleteOne {
builder := c.Delete().Where(wallet.ID(id))
builder.mutation.id = &id
builder.mutation.op = OpDeleteOne
@@ -302,12 +302,12 @@ func (c *WalletClient) Query() *WalletQuery {
}
// Get returns a Wallet entity by its id.
func (c *WalletClient) Get(ctx context.Context, id int) (*Wallet, error) {
func (c *WalletClient) Get(ctx context.Context, id int64) (*Wallet, error) {
return c.Query().Where(wallet.ID(id)).Only(ctx)
}
// GetX is like Get, but panics if an error occurs.
func (c *WalletClient) GetX(ctx context.Context, id int) *Wallet {
func (c *WalletClient) GetX(ctx context.Context, id int64) *Wallet {
obj, err := c.Get(ctx, id)
if err != nil {
panic(err)