-
New Feature
-
Resolution: Done
-
Normal
-
8.0.2
-
None
-
Security Level: Jimmy
-
None
-
ZK 8.0.3 S7, ZK 8.0.3 S9, ZK 8.0.3 S10
-
None
requirement spec
Dropupload (or file upload) can provide an attribute "maxFileCount" to limit the maximal file count to upload.
- if the file number users try to upload (drop) exceeds the limitation, popup a warning message
- default value is no limitation
- users can customize the warning message
psuedo code
zk.afterLoad('zkmax.wgt', function() { var _origDropuploadImpl = {}; zk.override(zkmax.wgt.Dropupload.prototype, _origDropuploadImpl, { _dropAction : function(event) { event.stop(); if (event.originalEvent.dataTransfer.files.length > maxFileAllowed) { jq.alert(msgzk.MESSAGE_FILE_OVER_LIMITATION, {icon:'ERROR'}); this.setVisible(false); return; } _origDropuploadImpl._dropAction.apply(this, arguments) } }); });
- relates to
-
ZK-3277 Implement a Fileupload (using modern APIs)
- Closed