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 the ability to disable sign-in/sign-up in the UI #7348

Merged

Conversation

Marishka17
Copy link
Contributor

Motivation and context

How has this been tested?

Checklist

  • I submit my changes into the develop branch
  • I have created a changelog fragment
  • I have updated the documentation accordingly
  • I have added tests to cover my changes
  • I have linked related issues (see GitHub docs)
  • I have increased versions of npm packages if it is necessary
    (cvat-canvas,
    cvat-core,
    cvat-data and
    cvat-ui)

License

  • I submit my code changes under the same MIT License that covers the project.
    Feel free to contact the maintainers if that's a concern.

@Marishka17 Marishka17 changed the title [WIP] Add the ability to disable sign-in/sign-up in the UI Add the ability to disable sign-in/sign-up in the UI Jan 11, 2024
@Marishka17 Marishka17 requested review from klakhov and removed request for bsekachev January 11, 2024 15:04
Copy link

codecov bot commented Jan 11, 2024

Codecov Report

Merging #7348 (659d1a6) into develop (b7cc562) will increase coverage by 0.13%.
Report is 13 commits behind head on develop.
The diff coverage is 88.18%.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #7348      +/-   ##
===========================================
+ Coverage    83.42%   83.56%   +0.13%     
===========================================
  Files          374      375       +1     
  Lines        39779    39762      -17     
  Branches      3729     3734       +5     
===========================================
+ Hits         33186    33226      +40     
+ Misses        6593     6536      -57     
Components Coverage Δ
cvat-ui 79.46% <85.55%> (+0.18%) ⬆️
cvat-server 87.34% <100.00%> (+0.09%) ⬆️

cvat-ui/src/reducers/index.ts Outdated Show resolved Hide resolved
cvat-ui/src/reducers/server-api-reducer.ts Outdated Show resolved Hide resolved
cvat-core/src/server-proxy.ts Show resolved Hide resolved
Copy link
Member

@bsekachev bsekachev left a comment

Choose a reason for hiding this comment

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

LGTM, just several minor comments

cvat-core/src/api-implementation.ts Outdated Show resolved Hide resolved
@@ -65,6 +65,7 @@ export default interface CVATCore {
setAuthData: any;
removeAuthData: any;
installedApps: any;
apiSchema: any;
Copy link
Member

Choose a reason for hiding this comment

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

Will it be possible to add something more specific than any?

Copy link
Member

Choose a reason for hiding this comment

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

We do not need to define precise type for the whole scheme, but at least what we should do it for things we use on client

Comment on lines +570 to +576
{isPasswordResetEnabled && (
<Route
exact
path='/auth/password/reset/confirm'
component={ResetPasswordPageConfirmComponent}
/>
)}
Copy link
Member

Choose a reason for hiding this comment

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

These routes still rendered below (lines 577-582)

@Marishka17 Marishka17 merged commit ad60b82 into develop Feb 12, 2024
34 checks passed
@Marishka17 Marishka17 deleted the mk/add_ability_to_disable_sign_in_sign_up_on_client branch February 12, 2024 14:39
@egeekial
Copy link

Now that this has been merged, how can I disable sign-ups in the UI?

@UUVtQD
Copy link

UUVtQD commented Apr 2, 2024

I have the same question - could either of you provide guidance on disabling self sign-up, or direct us to the relevant section in the documentation? @Marishka17 @bsekachev
Thanks!

@davidblom603
Copy link

Would also like to know how to disable the self sign up

@Marishka17
Copy link
Contributor Author

Hello, @egeekial, @UUVtQD, @davidblom603, you can just comment out the corresponding endpoint on the server and rebuild CVAT from the source (docker compose -f docker-compose.yml -f docker-compose.dev.yml build).

@davidblom603
Copy link

Thanks! Works great.

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

Successfully merging this pull request may close these issues.

6 participants