Skip to content
This repository was archived by the owner on Mar 13, 2025. It is now read-only.

UI Fix - change connect ID from a text field to a dropdown #443

Closed
jmgasper opened this issue May 17, 2022 · 0 comments
Closed

UI Fix - change connect ID from a text field to a dropdown #443

jmgasper opened this issue May 17, 2022 · 0 comments
Milestone

Comments

@jmgasper
Copy link
Collaborator

Ref (you don't need to access the link)

https://topcoder.atlassian.net/browse/PLAT-1028

Issue reported

We had a support ticket where a few tasks were created using topcoder-x. The connect project associated with the github repo used for the tasks was wrong and hence the tasks payments were made from the incorrect project. To avoid such scenarios, we should make a check that the user creating the tasks has access to the connect project the tasks are associated with.

Fix

When adding / editing a project, instead of taking the connect ID as a string ID, we want to make this a dropdown.

The dropdown will be populated from the list of active Connect projects the user has access to.

Screen_Shot_2022-05-17_at_2_44_02_pm

API call

You can see what sort of API call connect makes to fill in the list of projects. We should make one similar, tweaking the fields list to be what is needed in the dropdown. The dropdown should include the name of the project, the status, and the ID. The ID will be what's saved to the backend.

https://api.topcoder-dev.com/v5/projects/?fields=id,name,description,members,invites,status,type,actualPrice,estimatedPrice,createdAt,updatedAt,createdBy,updatedBy,details,lastActivityAt,lastActivityUserId,version,templateId&sort=lastActivityAt+desc&perPage=20&page=1

Migrating data

It's anticipated that we won't need to change the data model, allowing us to just save the connect ID as we do now, but restricting the allowable values.

If we do need to change the model, we'll have to include details on how to migrate the current data over to the new structure so that this is a seamless change for copilots.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant