[importer_direct_upload_size] putting the limit (200KB) on size of file uploaded
@@ -3185,6 +3185,10 @@ ${ commonheader(_("Importer"), "indexer", user, request, "60px") | n,unicode }
var files = $('#inputfile')[0].files[0];
fd.append('inputfile', files);
var file_size = files.size;
+ if (file_size > 200000) {
+ $.jHueNotify.warn("${ _('File size exceeds the supported size (200 KB).') }");
+ }
+ else {
$.ajax({
url:"/indexer/api/indexer/upload_local_file",
type: 'post',
@@ -3196,6 +3200,7 @@ ${ commonheader(_("Importer"), "indexer", user, request, "60px") | n,unicode }
viewModel.createWizard.source.path(response['local_file_url']);
}
});
+ }
};
$('.importer-droppable').droppable({
