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

Check for existing project name #1285

Merged
merged 2 commits into from
Feb 27, 2024
Merged

Conversation

Sujanadh
Copy link
Collaborator

What type of PR is this? (check all applicable)

  • πŸ• Feature
  • πŸ› Bug Fix
  • πŸ“ Documentation Update
  • 🎨 Style
  • πŸ§‘β€πŸ’» Code Refactor
  • πŸ”₯ Performance Improvements
  • βœ… Test
  • πŸ€– Build
  • πŸ” CI
  • πŸ“¦ Chore (Release)
  • ⏩ Revert

Related Issue

Describe this PR

This change checks for the project name if it already exists or not. If exists, it returns message "Project already exists with the name {project_name}"

Screenshots

N/A

Checklist before requesting a review

[optional] What gif best describes this PR or how it makes you feel?

@Sujanadh Sujanadh self-assigned this Feb 27, 2024
@github-actions github-actions bot added the backend Related to backend code label Feb 27, 2024
@Sujanadh Sujanadh marked this pull request as draft February 27, 2024 05:23
@Sujanadh Sujanadh marked this pull request as ready for review February 27, 2024 05:41
Copy link
Member

@spwoodcock spwoodcock left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice πŸ‘

@spwoodcock
Copy link
Member

spwoodcock commented Feb 27, 2024

One future addition to UX would be to wrap this logic in a crud function instead, then use it both here, and in a small endpoint in routes too.

When the user inputs the name at the start of the workflow we can call the endpoint to check if the name exists on blur (clicking outside the box).

It's frustrating if the user gets to the end of the creation and then has the name rejected.

@spwoodcock spwoodcock merged commit 45c3238 into development Feb 27, 2024
5 checks passed
@spwoodcock spwoodcock deleted the feat/check-project-name branch February 27, 2024 08:07
@Sujanadh
Copy link
Collaborator Author

agree πŸ‘

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend Related to backend code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Restrict projects to have same names
2 participants