fix(helpdesk): resolve contactNo from ticket for SOAP file authorization
BC's GetTicketFile requires a valid contactNo for authorization. The endpoint now accepts ticketNo, loads the ticket via OData to get Current_Contact_Name, looks up the contact's No, and passes it to the SOAP call. Frontend includes ticketNo in the file download URL. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -118,7 +118,7 @@ export function renderCommunicationFeed(entries, options = {}) {
|
||||
// File attachment: render download link and inline image for images
|
||||
if (typeVariant === 'file' && fileDownloadUrl && entry.file_entry_no) {
|
||||
const fileName = entry.file_name || 'attachment';
|
||||
const fileUrl = fileDownloadUrl + '?entryNo=' + encodeURIComponent(entry.file_entry_no) + '&filename=' + encodeURIComponent(fileName);
|
||||
const fileUrl = fileDownloadUrl + '?entryNo=' + encodeURIComponent(entry.file_entry_no) + '&ticketNo=' + encodeURIComponent(ticketNo) + '&filename=' + encodeURIComponent(fileName);
|
||||
const ext = fileName.includes('.') ? fileName.split('.').pop().toLowerCase() : '';
|
||||
const imageExts = ['jpg', 'jpeg', 'png', 'gif', 'bmp'];
|
||||
const isImage = imageExts.includes(ext);
|
||||
|
||||
Reference in New Issue
Block a user