Skip to content

Commit ce4eb5c

Browse files
committed
upgrade Uploadify to 3.1.1
fixes #8221 test plan: no user visible changes in behavior, so this is a regression test. repeat this test plan once for s3 files and once for local files: * verify file uploads on /courses/X/files and /dashboard/files * upload to other folders * upload multiple files * zip uploads * weird characters in filenames, duplicate filenames * verify other places we upload files like content imports and sis imports Change-Id: I01b7805eb947097b250bf9be944a9347ecc4ff5e
1 parent f240b83 commit ce4eb5c

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

57 files changed

+1148
-10791
lines changed
+1-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
require ['full_files', 'uploadify']
1+
require ['full_files', 'use!uploadify']
22

app/models/attachment.rb

+4-2
Original file line numberDiff line numberDiff line change
@@ -507,10 +507,13 @@ def ajax_upload_params(pseudonym, local_upload_url, s3_success_url, options = {}
507507
{'key' => sanitized_filename},
508508
{'acl' => 'private'},
509509
['starts-with', '$Filename', ''],
510-
['starts-with', '$folder', ''],
511510
['content-length-range', 1, (options[:max_size] || CONTENT_LENGTH_RANGE)]
512511
]
513512
}
513+
if res[:upload_params]['folder'].present?
514+
policy['conditions'] << ['starts-with', '$folder', '']
515+
end
516+
514517
extras = []
515518
if options[:no_redirect]
516519
extras << {'success_action_status' => '201'}
@@ -538,7 +541,6 @@ def ajax_upload_params(pseudonym, local_upload_url, s3_success_url, options = {}
538541
res[:id] = id
539542
res[:upload_params].merge!({
540543
'Filename' => '',
541-
'folder' => '',
542544
'key' => sanitized_filename,
543545
'acl' => 'private',
544546
'Policy' => policy_encoded,

app/views/layouts/facebook.html.erb

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
paths: {
2929
common: 'compiled/bundles/common',
3030
jqueryui: 'vendor/jqueryui',
31-
uploadify: '../flash/uploadify/jquery.uploadify.v2.1.4'
31+
uploadify: '../flash/uploadify/jquery.uploadify-3.1.min'
3232
}
3333
};
3434
</script>

lib/canvas/require_js.rb

+7-2
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,8 @@ def paths
5050
@paths ||= {
5151
:common => 'compiled/bundles/common',
5252
:jqueryui => 'vendor/jqueryui',
53-
:uploadify => '../flash/uploadify/jquery.uploadify.v2.1.4',
5453
:use => 'vendor/use',
54+
:uploadify => '../flash/uploadify/jquery.uploadify-3.1.min'
5555
}.update(plugin_paths).to_json.gsub(/([,{])/, "\\1\n ")
5656
end
5757

@@ -95,10 +95,15 @@ def shims
9595
'vendor/slickgrid/plugins/slick.rowselectionmodel': {
9696
deps: ['use!vendor/slickgrid/slick.core'],
9797
attach: 'Slick'
98+
},
99+
100+
'uploadify' : {
101+
deps: ['jquery'],
102+
attach: '$'
98103
}
99104
}
100105
JS
101106
end
102107
end
103108
end
104-
end
109+
end

public/flash/swf_upload/Core Changelog.txt

-283
This file was deleted.

0 commit comments

Comments
 (0)