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

Issue with upload profile picture #1336

Closed
Tracked by #1465
mahalakshme opened this issue Sep 13, 2024 · 9 comments
Closed
Tracked by #1465

Issue with upload profile picture #1336

mahalakshme opened this issue Sep 13, 2024 · 9 comments
Assignees

Comments

@mahalakshme
Copy link
Contributor

mahalakshme commented Sep 13, 2024

https://avni.freshdesk.com/a/tickets/3776

AC:

  • Uploading icons for report cards, subject type, individual profile picture should be possible if the user has corresponding privilege for the entity. ie. 'Edit offline dashboard and report card', 'Edit subject type' and 'Register subject' resp., The same for uploading image when creating a news broadcast
  • it should not require 'Edit Organisation Configuration' privilege.

Technical:

It is happening because we have one save upload image endpoint which is used from different places and it should require appropriate privilege.

@mahalakshme
Copy link
Contributor Author

@petmongrels the second issue( 2. the other issue i noticed was that, in dea after uploading if I go back in the wizard then the image is not shown. ) u had mentioned in the ticket seems to be for the same reason:- it is happening bcoz image upload didnt happen.

or am I missing something?

@mahalakshme mahalakshme moved this from In Analysis to In Analysis Review in Avni Product Sep 17, 2024
@petmongrels
Copy link
Contributor

petmongrels commented Sep 17, 2024 via email

@mahalakshme mahalakshme moved this from In Analysis Review to Ready in Avni Product Sep 17, 2024
@1t5j0y 1t5j0y self-assigned this Sep 17, 2024
1t5j0y added a commit to avniproject/avni-server that referenced this issue Sep 18, 2024
…ileges

- Fixed access to news write APIs to check EditNews privilege
1t5j0y added a commit that referenced this issue Sep 18, 2024
…ofile pic for subject

- Minor refactoring for variables named 'bucket' which were actually referring to folders in line with changes made on server
@1t5j0y
Copy link
Contributor

1t5j0y commented Sep 19, 2024

Additional commit: avniproject/avni-server@b9a82de

@1t5j0y
Copy link
Contributor

1t5j0y commented Sep 19, 2024

Changes:

  • Refactoring to change incorrectly named API params and variables which referred to 'bucket' when the intent was 'folder'.
  • Writes to news entities fixed to require EditNews privilege and not EditOrganisationConfiguration
  • Enforced RegisterSubject or EditSubject access check on Subject save from DEA
  • Enforced media sub folder level access for uploads via POST /media/saveImage?folderName=
    -- no folderName specified - error condition
    -- folderName is 'icons' - EditSubjectType or EditOfflineDashboardAndReportCard
    -- folderName is 'news' - EditNews
    -- folderName is 'profile-pics' - RegisterSubject or EditSubject (any subject type)
  • Fixed transactional entity specific access check to only consider non voided group_privileges

@1t5j0y 1t5j0y moved this from In Progress to Code Review Ready in Avni Product Sep 19, 2024
@petmongrels petmongrels moved this from In Code Review to QA Ready in Avni Product Sep 27, 2024
@AchalaBelokar AchalaBelokar self-assigned this Oct 23, 2024
@AchalaBelokar
Copy link

AchalaBelokar commented Oct 23, 2024

  • I login with maha@apfodisha_uat and I created a individual and save it after that it is giving me error.this is hapenning on prerelease

@AchalaBelokar AchalaBelokar moved this from In QA to QA Failed in Avni Product Oct 24, 2024
@1t5j0y
Copy link
Contributor

1t5j0y commented Oct 24, 2024

@AchalaBelokar please share details of the error.

@AchalaBelokar
Copy link

AchalaBelokar commented Oct 24, 2024

Image

@AchalaBelokar
Copy link

AchalaBelokar commented Oct 24, 2024

@1t5j0y
Copy link
Contributor

1t5j0y commented Oct 25, 2024

Unable to simulate either issue. Moving back to QA ready - verified with QA that it is no longer happening for them either.

@1t5j0y 1t5j0y moved this from In Progress to QA Ready in Avni Product Oct 25, 2024
@AchalaBelokar AchalaBelokar moved this from In QA to Done in Avni Product Oct 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

No branches or pull requests

5 participants