Permission Error When Viewing Uploaded Image

Hi Everyone,

I’m facing an issue with a custom Doctype called PettyCash, where users are required to upload images.

The problem occurs when a user uploads an image, and a senior user (with higher privileges) tries to view it from their account. In such cases, the following error appears:

Forbidden
You don’t have permission to access this file.

Interestingly, this issue happens only with the first entry — all subsequent images can be viewed normally. Also, when accessed from the Administrator account, the image opens without any problem.

Thanks in advance for your help!

Hi

you have to customize doctype to set attachments as public so that senior user can have access to those files. it looks like while uploading those files, user is declaring them as private.

Hi,
i have already done this, as i mentioned this issue occurs mostly with the first file (Image)

Thank You