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

feat: Add CRUD apis for role, permission, user #1801

Merged
merged 31 commits into from
Apr 12, 2022

Conversation

mayurnewase
Copy link
Contributor

@mayurnewase mayurnewase commented Feb 9, 2022

Description

Add permission, role, user CRUD apis.

ADDITIONAL INFORMATION

  • Has associated issue:
  • Is CRUD MVC related.
  • Is Auth, RBAC security related.
  • Changes the security db schema.
  • Introduces new feature
  • Removes existing feature

@mayurnewase mayurnewase changed the title Add CRUD apis for role, permission, user feat: Add CRUD apis for role, permission, user Feb 9, 2022
@codecov
Copy link

codecov bot commented Feb 10, 2022

Codecov Report

Merging #1801 (172ed09) into master (f6f66fc) will increase coverage by 0.99%.
The diff coverage is 96.94%.

❗ Current head 172ed09 differs from pull request most recent head 4e483a6. Consider uploading reports for the commit 4e483a6 to get more accurate results

@@            Coverage Diff             @@
##           master    #1801      +/-   ##
==========================================
+ Coverage   77.08%   78.07%   +0.99%     
==========================================
  Files          56       70      +14     
  Lines        8226     8488     +262     
==========================================
+ Hits         6341     6627     +286     
+ Misses       1885     1861      -24     
Flag Coverage Δ
python 78.07% <96.94%> (+0.99%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
flask_appbuilder/security/sqla/apis/user/api.py 93.10% <93.10%> (ø)
flask_appbuilder/security/sqla/apis/role/api.py 96.42% <96.42%> (ø)
flask_appbuilder/security/sqla/apis/__init__.py 100.00% <100.00%> (ø)
...pbuilder/security/sqla/apis/permission/__init__.py 100.00% <100.00%> (ø)
...sk_appbuilder/security/sqla/apis/permission/api.py 100.00% <100.00%> (ø)
...ecurity/sqla/apis/permission_view_menu/__init__.py 100.00% <100.00%> (ø)
...der/security/sqla/apis/permission_view_menu/api.py 100.00% <100.00%> (ø)
...ask_appbuilder/security/sqla/apis/role/__init__.py 100.00% <100.00%> (ø)
flask_appbuilder/security/sqla/apis/role/schema.py 100.00% <100.00%> (ø)
...ask_appbuilder/security/sqla/apis/user/__init__.py 100.00% <100.00%> (ø)
... and 8 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 06664bd...4e483a6. Read the comment docs.

@mayurnewase mayurnewase marked this pull request as draft February 17, 2022 14:46
@mayurnewase mayurnewase marked this pull request as ready for review February 20, 2022 07:20
Copy link
Owner

@dpgaspar dpgaspar left a comment

Choose a reason for hiding this comment

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

Looking very good

flask_appbuilder/security/sqla/apis/__init__.py Outdated Show resolved Hide resolved
flask_appbuilder/security/sqla/apis/user/schema.py Outdated Show resolved Hide resolved
flask_appbuilder/security/sqla/apis/user/user.py Outdated Show resolved Hide resolved
flask_appbuilder/security/sqla/apis/user/user.py Outdated Show resolved Hide resolved
flask_appbuilder/security/sqla/apis/user/user.py Outdated Show resolved Hide resolved
flask_appbuilder/security/sqla/apis/user/user.py Outdated Show resolved Hide resolved
flask_appbuilder/tests/test_api.py Outdated Show resolved Hide resolved
flask_appbuilder/tests/test_api.py Outdated Show resolved Hide resolved
flask_appbuilder/tests/test_api.py Outdated Show resolved Hide resolved
@mayurnewase mayurnewase reopened this Feb 26, 2022
Copy link
Owner

@dpgaspar dpgaspar left a comment

Choose a reason for hiding this comment

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

Looking good, gave it another quick review and tried things out. ping me if you have any blockers

flask_appbuilder/security/sqla/apis/permission/api.py Outdated Show resolved Hide resolved
flask_appbuilder/security/sqla/apis/role/api.py Outdated Show resolved Hide resolved
flask_appbuilder/security/sqla/apis/role/api.py Outdated Show resolved Hide resolved
flask_appbuilder/security/sqla/apis/role/api.py Outdated Show resolved Hide resolved
flask_appbuilder/security/sqla/apis/role/api.py Outdated Show resolved Hide resolved
flask_appbuilder/security/sqla/apis/user/api.py Outdated Show resolved Hide resolved
Copy link
Owner

@dpgaspar dpgaspar left a comment

Choose a reason for hiding this comment

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

Looking great! left a couple of comments, thank you for your patience ;)

flask_appbuilder/tests/test_security_api.py Outdated Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants