I have a file uploader:
<kendo-upload
#templateUploader
id=
"document"
[multiple]=
"false"
[saveUrl]=
"uploadSaveUrl"
[removeUrl]=
"uploadRemoveUrl"
[autoUpload]=
"false"
[disabled]=
"!templateTypeSelected"
[restrictions]=
"fileRestrictions"
(remove)=
"removeEventHandler($event)"
(success)=
"successEventHandler($event)"
(upload)=
"uploadEventHandler($event)"
>
</kendo-upload>
And I need to dynamically change fileRestrictions.allowedExtensions when I select a different document type from a drop down list:
templateTypeSelectionChange(documentType: NcDocumentTypeDto) {
this
.templateTypeSelected =
true
;
this
.selectedNcDocumentCategory.documentTemplate.ncDocumentTypeId = documentType.id;
this
.fileRestrictions.allowedExtensions = documentType.extensions.split(
','
);
}
The string array is set correctly but the component is not updated with new file restrictions. What is the problem?