support filter file extension in open file dialog

This commit is contained in:
MaysWind 2018-11-19 22:47:22 +08:00
parent c8229e93cf
commit 6bab712d54

View file

@ -73,6 +73,10 @@
element = angular.element('<input type="file" style="display: none"/>');
}
if (options.fileFilter) {
element.attr('accept', options.fileFilter);
}
element.val('');
if (element.attr('data-ariang-file-initialized') !== 'true') {