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

Assigning the TaskType to DashboardListItem.ID #46

Open
SoftAdviceJR opened this issue Oct 28, 2021 · 3 comments
Open

Assigning the TaskType to DashboardListItem.ID #46

SoftAdviceJR opened this issue Oct 28, 2021 · 3 comments
Labels
enhancement New feature or request

Comments

@SoftAdviceJR
Copy link
Contributor

When editing a specific task's DashboardListItem I'm going through the items returned by this.TaskManager.GetDashboardContent(this.TaskQueueResolver) and then matching by Title. This adds some unnecessary boilerplate as now I also put the Title inside a const string.

Could we perhaps assign the TaskType string to DashboardListItem.ID?
This string is already used to "look up" the TaskProcessor so this seems like a more natural way to match the DashboardListItem.

@CraigHawker
Copy link
Collaborator

That sounds potentially reasonable. Can you give me some more information on why exactly you're trying to find these list items, though? I'm interested to see whether we should architect access/generation differently to make it more accessible in the first place (rather than having to post-process).

@CraigHawker CraigHawker added the enhancement New feature or request label Oct 28, 2021
@SoftAdviceJR
Copy link
Contributor Author

Sometimes I like to add additional commands to the task on the dashboard. For example: we have a service tool that does some mass manipulation of properties based on a configured filter and such. I've also added a "Count" command so that we can check that the amount of objects found matches expectations.

@CraigHawker
Copy link
Collaborator

The approach that the current code takes (by using extension methods to generate everything) was quick to implement, but isn't very flexible or extensible, and I don't like the idea of people having to post-process items.

What if we looked to migrate some of this into "Generator" classes/interfaces (IDashboardTaskProcessorGenerator / IDashboardTaskGenerator)? You could then easily extend these classes and add whatever functionality you need, or even create your own implementations if you wanted..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants