-
Notifications
You must be signed in to change notification settings - Fork 372
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
Location/ Bed Management issue ( District Lab Admin Account) #7102
Comments
Working on it! |
Hi, @gigincg, @nihal467, @khavinshankar, @mathew-alex, @aparnacoronasafe, This issue has been automatically marked as stale because it has not had any recent activity. |
Hey @SamakshAgarwal1112 any updates on this? |
Hello @rithviknishad, could you please assign me this issue? I'm eager to work on it. |
Hey @shramanpaul Feel free to make a PR on this once the changes requested for #7200 is completed |
@rithviknishad Could you explain to me why this issue is throwing a 403 error?
|
Have you set the Authorization headers when making the request? |
I'm not sure, this is the stuff I cached from the browser. |
@rithviknishad @balaji-sivasakthi i tried using the same front-end on my local backend it does not show this error. do we have some sort of waf or any firewall this passes through that could be the issue here pls correct me if i am wrong, also this does not exist in https://care.ohc.network/ |
@rithviknishad I would like to work on this. Can you assign me this issue? |
@balaji-sivasakthi that 403 error is because there is no authentication details. I tried to find the method associated with the url in the care backend repo but I'm unable to find it |
Has anyone checked with a different account? I believe the account listed below may be broken in terms of roles.
|
please assign this issues to me, I want to contribute here |
@rithviknishad I would like to work on this. Can you assign me this issue? |
i tried on my local using devdistrict admin, staff and doc everything works fine, i feel like this is some sort of configuration or firewall setting for some apis |
Have you tried creating a district lab admin user type user and tried replicating the issue with that user? |
Yes I did |
"District Lab Admin" is the user type. Not "District Admin" Also, I'm able to replicate this issue. To replicate this, you'll need to go directly to the URL instead of navigating to the location page through Care. ![]() There seems to be multiple permission issues:
cc: @sainak |
Yes @rithviknishad this is a permission issue, it needs to be restricted on the backend |
can you assign this to me ? @rithviknishad @sainak |
@rithviknishad can you pls explain what do you mean by this as on what basis do we need to validate if user has access to these facilities ? |
Refer Facility Permissions here: https://github.com/coronasafe/care/blob/master/care/facility/api/viewsets/facility.py#L50-L61 |
if the issue is not resolved , i can work on this @rithviknishad |
i am working on it @Thanush19 |
lets close this issue @rithviknishad |
----Describe the bug----
Error Message coming up "You don't have permission to perform this action" but still allowed to create and manage beds using district lab admin account
----Steps to reproduce----
1- Log in using provided credential
2- Click on https://care.coronasafe.in/facility/42d0dbbd-e3e1-4d64-88ff-f606b90975b0/location
3- Click on "manage beds" from any existing location
4- add new bed
----Login Credentials----
Username: district_lab123
Password: Lilo@123
----Screenshots----
![IMG_20240125_003827.jpg](https://private-user-images.githubusercontent.com/144016088/299429630-d0a54e07-3d87-4af2-8d6b-765f27bdcf0a.jpg?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjYxNDQ0MTUsIm5iZiI6MTcyNjE0NDExNSwicGF0aCI6Ii8xNDQwMTYwODgvMjk5NDI5NjMwLWQwYTU0ZTA3LTNkODctNGFmMi04ZDZiLTc2NWYyN2JkY2YwYS5qcGc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwOTEyJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDkxMlQxMjI4MzVaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT01NzQ3MTgyMzZjZWEzYjBhZDcxZGQwMWQ3MjE4MmQ4ZDA0Mzk4ZGYxODg3YzY4ZjFhYzdiYWU3N2MzMWUzNDM4JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.qWrUjXwOFc6tl3GByl61KPbyoQTx9qohoW9RbSo9pDk)
The text was updated successfully, but these errors were encountered: