Skip to content

Commit 8e18064

Browse files
Closes smartstore#1673 Product attributes: multiple attributes of type 'file upload' not working simultaneously
1 parent 59fc725 commit 8e18064

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

src/Presentation/SmartStore.Web/Views/Shared/ChoiceTemplates/Choice.FileUpload.cshtml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
var result = data.result;
3636
3737
if (result.downloadGuid) {
38-
setUploadedFile(result.downloadGuid, data.files[0].name);
38+
setUploadedFile(result.downloadGuid, data.files[0].name, "@(containerId)");
3939
}
4040
4141
if (result.message) {
@@ -48,14 +48,14 @@
4848
$('#@containerId .uploaded-file').empty().hide();
4949
}
5050
51-
function setUploadedFile(downloadGuid, fileName) {
51+
function setUploadedFile(downloadGuid, fileName, containerId) {
5252
if (!_.isEmpty(downloadGuid) && downloadGuid !== '0') {
53-
$('#@containerId .hidden').val(downloadGuid);
53+
$('#' + containerId + ' .hidden').val(downloadGuid);
5454
5555
var downloadLink = "@storeUrl" + "download/getfileupload/?downloadId=" + downloadGuid;
5656
var fileLink = '<a href="' + downloadLink + '" class="fileuploadattribute" rel="nofollow">' + fileName + '</a>';
5757
58-
$('#@containerId .uploaded-file').html(fileLink).show();
58+
$('#' + containerId + ' .uploaded-file').html(fileLink).show();
5959
}
6060
}
6161

0 commit comments

Comments
 (0)