File tree Expand file tree Collapse file tree 2 files changed +7
-0
lines changed
view/base/web/js/form/element Expand file tree Collapse file tree 2 files changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -202,3 +202,4 @@ CSV,CSV
202
202
"Please enter at least {0} characters.","Please enter at least {0} characters."
203
203
"Please enter a value between {0} and {1} characters long.","Please enter a value between {0} and {1} characters long."
204
204
"Please enter a value between {0} and {1}.","Please enter a value between {0} and {1}."
205
+ "The file upload field is disabled.","The file upload field is disabled."
Original file line number Diff line number Diff line change @@ -328,6 +328,12 @@ define([
328
328
allowed = this . isFileAllowed ( file ) ,
329
329
target = $ ( e . target ) ;
330
330
331
+ if ( this . disabled ( ) ) {
332
+ this . notifyError ( $t ( 'The file upload field is disabled.' ) ) ;
333
+
334
+ return ;
335
+ }
336
+
331
337
if ( allowed . passed ) {
332
338
target . on ( 'fileuploadsend' , function ( event , postData ) {
333
339
postData . data . append ( 'param_name' , this . paramName ) ;
You can’t perform that action at this time.
0 commit comments