Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add "hidden" flag to TradingPosition records that should be hidden in the UI #1041

Open
kenkunz opened this issue Sep 18, 2024 · 0 comments
Open
Assignees
Labels
enhancement New feature or request priority: P2 Default priority. An issue might not yet be fixed in the next release. size: S A small task that can be completed in less than a day

Comments

@kenkunz
Copy link

kenkunz commented Sep 18, 2024

Goal

As a strategy admin, I want to be able to hide specific positions from non-admin users on frontend, in order to prevent them from being confused by erroneous data.

Background

See tradingstrategy-ai/frontend#812

As a short-term work around, positions are bing hidden in frontend by adding hiddenPositions array to the frontend strategy configuration (found in strategies.json on prod). This is not a scalable solution and is problematic b/c the strategy configuration is not defined in a single, consistent location.

Note the question under How to flag position as hidden? in the ticket description. This ticket assumes we are going with the recommendation in that section. If there is a better approach, update the ticket accordingly.

Acceptance criteria

  1. Position records (found under state.portfolio.[status]_positions) include a new flags property.
  2. The flags property includes a list of values, taken from an enumeration of valid position flags
  3. One of the valid position flags is hidden
  4. This position includes the hidden flag.
@kenkunz kenkunz added enhancement New feature or request priority: P2 Default priority. An issue might not yet be fixed in the next release. size: S A small task that can be completed in less than a day labels Sep 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request priority: P2 Default priority. An issue might not yet be fixed in the next release. size: S A small task that can be completed in less than a day
Projects
None yet
Development

No branches or pull requests

2 participants