Browse Source

Fix #1648: New plugin method `getFilesSize` to return sum of bytes of all files

Kartik Visweswaran 4 years ago
parent
commit
1bcb988abf
3 changed files with 5 additions and 1 deletions
  1. 2 1
      CHANGE.md
  2. 3 0
      js/fileinput.js
  3. 0 0
      js/fileinput.min.js

+ 2 - 1
CHANGE.md

@@ -5,9 +5,10 @@ Change Log: `bootstrap-fileinput`
 
 **Date**: _under development_
 
-- (enh #1652): Correct thumb parsing error for events when `showPreview` is false.
+- (bug #1652): Correct thumb parsing error for events when `showPreview` is false.
 - (enh #1651): Pass file id in `fileuploaded` event for non-resumable ajax async uploads.
 - (enh #1650): Update Ukranian Translations.
+- (enh #1648): New plugin method `getFilesSize` to return sum of bytes of all files.
 - (enh #1645): Update Polish Translations.
 
 ## version 5.1.3

+ 3 - 0
js/fileinput.js

@@ -5131,6 +5131,9 @@
         getFileList: function () {
             return this.fileManager.list();
         },
+        getFilesSize: function() {
+            return this.fileManager.getTotalSize();
+        },
         getFilesCount: function (includeInitial) {
             var self = this, len = self.isAjaxUpload ? self.fileManager.count() : self._inputFileCount();
             if (includeInitial) {

File diff suppressed because it is too large
+ 0 - 0
js/fileinput.min.js


Some files were not shown because too many files changed in this diff