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

create with multiple attachments #12

Closed
temiotu opened this issue Feb 10, 2021 · 8 comments
Closed

create with multiple attachments #12

temiotu opened this issue Feb 10, 2021 · 8 comments

Comments

@temiotu
Copy link

temiotu commented Feb 10, 2021

When i upload multiple attachments to uvdesk, it only uploads the last file in the set of files sent, and discards the rest.
It does not accept an array of files when creating a ticket or replying to a ticket. It only takes one.

@papnoisanjeev
Copy link
Contributor

papnoisanjeev commented Feb 11, 2021

@temiotu

For create ticket attachment issue locate path in your project:
vendor/uvdesk/api-bundle/API/Tickets.php

Open Tickets.php and replace Tickets.php code from here.


For Ticket Reply attachment issue:
vendor/uvdesk/api-bundle/API/Threads.php

Open Threads.php and replace Threads.php code from here.

And make a try it will work.

@papnoisanjeev
Copy link
Contributor

@temiotu

Hope issue is fixed so closing it if still exist you can reopen it.

@papnoisanjeev
Copy link
Contributor

@phenomenalDenzel

Please check below screen shots after update:

For single attachment Using postman:

https://prnt.sc/zbkpc5

SingleAttachmentPostman

For multiple attachment Using postman:

https://prnt.sc/zbl4s2

MultipleAttachment

Make a try again and verify data first and request as we are doing from postman.

@phenomenalDenzel
Copy link

Yes I did the that still ends up uploading just one file.

The Request:
Screen Shot 2021-02-13 at 11 05 47 AM

Verified data on uvdesk UI:
Screen Shot 2021-02-13 at 11 06 20 AM

Also after getting the newly created ticket with the API route "localhost:8000/api/v1/ticket/77", it shows the ticket has only one attachment.
Screen Shot 2021-02-13 at 11 17 07 AM

@papnoisanjeev
Copy link
Contributor

@phenomenalDenzel

attachments[] (we have shown this to you with our multiple attachment screenshot) try this when sending more than one file it should be a array.

@phenomenalDenzel
Copy link

@papnoisanjeev
Ok Sorry about that, Let me quickly try that with the array symbol

@phenomenalDenzel
Copy link

@papnoisanjeev

Thank you very much. It works now

@papnoisanjeev
Copy link
Contributor

@papnoisanjeev

Thank you very much. It works now

Glad to know it's working for you.
stay tuned with us here for updates.

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

No branches or pull requests

3 participants