uvdesk / community-skeleton

UVdesk Opensource Community Helpdesk Project built for all to make a Full Ticketing Support System along with many more other features.
https://www.uvdesk.com
MIT License
8.72k stars 461 forks source link

can't view file upload in ticket after Add Attachment #700

Closed chonnuchajo closed 11 months ago

chonnuchajo commented 11 months ago

i have a problem with func.Add Attachment

i'm not sure miss someany config it

komal-sh-27 commented 11 months ago

@chonnuchajo ,

We have noticed this error in the latest release uvdesk. We have fixed this issue but changes wiil be reflect on the next release. At this moment you can change the some code in your project. Please follow the below steps:

Step 1: Go to your project, open and change the code in below mentioned file path:

your-project-folder/vendor/uvdesk/core-framework/FileSystem/FileSystem.php

Add a code like this as shown the below screenshot:

$scheme = $this->container->get('router')->getContext()->getScheme();
$host = $this->container->get('router')->getContext()->getHost();
$baseUrl = "$scheme://$host";
$assetDetails['downloadURL'] = $baseUrl.$assetDetails['downloadURL'];

image

Reference from here.

Step 2: Now change some code in the mentioned below file path:

your-project-folder/vendor/uvdesk/core-framework/Controller/Ticket.php

$response->headers->set('Content-length', filesize($zipname)); Another line:

readfile($path);

image

Reference from here:

https://github.com/uvdesk/core-framework/pull/652/commits/ad4ab27f009426c635932a403983a2b04eb1302e

https://github.com/uvdesk/core-framework/pull/652/commits/dfd98fa3971df42ebdc7ab8265c502af8517b2cc

Step 3: After change the both files you will be cleared cache of your project using the below command in your project root directory:

$ php bin/console c:c

If you are facing the same issue then let us know.

Kind Respects, Uvdesk team

chonnuchajo commented 11 months ago

thank you so much .

komal-sh-27 commented 11 months ago

@chonnuchajo ,

Thanks for the update here. These changes wiil be reflect on the future release. For now we are closing this issue. Thanks for your time and patience!!!

Kind Respects, Uvdesk Team