feat: workflow run status & time

This commit is contained in:
Fu Diwei
2025-01-04 22:07:01 +08:00
parent b686579acc
commit 3b9a7fe805
29 changed files with 505 additions and 181 deletions

View File

@@ -15,19 +15,19 @@ func NewSettingsRepository() *SettingsRepository {
}
func (s *SettingsRepository) GetByName(ctx context.Context, name string) (*domain.Settings, error) {
resp, err := app.GetApp().Dao().FindFirstRecordByFilter("settings", "name={:name}", dbx.Params{"name": name})
record, err := app.GetApp().Dao().FindFirstRecordByFilter("settings", "name={:name}", dbx.Params{"name": name})
if err != nil {
return nil, err
}
rs := &domain.Settings{
Meta: domain.Meta{
Id: resp.GetString("id"),
CreatedAt: resp.GetTime("created"),
UpdatedAt: resp.GetTime("updated"),
Id: record.GetId(),
CreatedAt: record.GetCreated().Time(),
UpdatedAt: record.GetUpdated().Time(),
},
Name: resp.GetString("name"),
Content: resp.GetString("content"),
Name: record.GetString("name"),
Content: record.GetString("content"),
}
return rs, nil