mirror of
https://github.com/aykhans/slash-e.git
synced 2025-07-06 21:22:36 +00:00
fix: list activities
This commit is contained in:
@ -274,8 +274,8 @@ func (s *APIV2Service) GetShortcutAnalytics(ctx context.Context, request *apiv2p
|
||||
}
|
||||
|
||||
activities, err := s.Store.ListActivities(ctx, &store.FindActivity{
|
||||
Type: store.ActivityShortcutView,
|
||||
Where: []string{fmt.Sprintf("json_extract(payload, '$.shortcutId') = %d", shortcut.Id)},
|
||||
Type: store.ActivityShortcutView,
|
||||
PayloadShortcutID: &shortcut.Id,
|
||||
})
|
||||
if err != nil {
|
||||
return nil, status.Errorf(codes.Internal, "failed to get activities, err: %v", err)
|
||||
@ -404,9 +404,9 @@ func (s *APIV2Service) convertShortcutFromStorepb(ctx context.Context, shortcut
|
||||
}
|
||||
|
||||
activityList, err := s.Store.ListActivities(ctx, &store.FindActivity{
|
||||
Type: store.ActivityShortcutView,
|
||||
Level: store.ActivityInfo,
|
||||
Where: []string{fmt.Sprintf("json_extract(payload, '$.shortcutId') = %d", composedShortcut.Id)},
|
||||
Type: store.ActivityShortcutView,
|
||||
Level: store.ActivityInfo,
|
||||
PayloadShortcutID: &composedShortcut.Id,
|
||||
})
|
||||
if err != nil {
|
||||
return nil, errors.Wrap(err, "Failed to list activities")
|
||||
|
Reference in New Issue
Block a user