Skip to content

Commit

Permalink
feat: support to define auto recap rates (#182)
Browse files Browse the repository at this point in the history
* feat: support to define auto recap rates
* chore: fix tests, update ent, fix lint

---------

Signed-off-by: Neko Ayaka <[email protected]>
  • Loading branch information
nekomeowww authored Dec 10, 2023
1 parent 90a5005 commit e48122a
Show file tree
Hide file tree
Showing 26 changed files with 899 additions and 182 deletions.
11 changes: 8 additions & 3 deletions ent/client.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions ent/migrate/schema.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

89 changes: 88 additions & 1 deletion ent/mutation.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 6 additions & 2 deletions ent/runtime.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions ent/runtime/runtime.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions ent/schema/telegramchatautorecapsoptions.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ func (TelegramChatRecapsOptions) Fields() []ent.Field {
field.Int64("chat_id").Unique(),
field.Int("auto_recap_send_mode").Default(0),
field.Int64("manual_recap_rate_per_seconds").Default(0),
field.Int("auto_recap_rates_per_day").Default(0),
field.Int64("created_at").DefaultFunc(func() int64 { return time.Now().UnixMilli() }),
field.Int64("updated_at").DefaultFunc(func() int64 { return time.Now().UnixMilli() }),
}
Expand Down
16 changes: 16 additions & 0 deletions ent/slackoauthcredentials_update.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

48 changes: 48 additions & 0 deletions ent/telegramchatfeatureflags_update.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 12 additions & 1 deletion ent/telegramchatrecapsoptions.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit e48122a

Please sign in to comment.